2012-12-23 07:29 PM
hi,
how can I use the STM32 built-in temperature sensor? the STLM20_ReadTemp() function stops the program and I really need to get this to work.thanks #stm32 #stlm202012-12-24 08:58 AM
The Standard Peripheral Library has a temperature sensor example. What are you doing differently from that ?
The temperature sensor has a long initialization time (see the data sheet). Have you allowed for that ? Cheers, Hal2012-12-24 11:08 AM
When I use the eaxmple from stendard peripheral library, it works, The problem appears when I try to insert the code into the ZigBee example which also uses the HAL driver. Then STLM20_ReadTemp() function stops the program and doesn't allow to start again.
About the initialization time - can you point me to that document? i couldn't see that in the STLM20 document from ST.com2012-12-24 12:05 PM
Reset everything I said.
The STLM20 is not the STM32Fxxx built-in temperature sensor. I presume you are using some evaluation or Discovery board with this sensor on the board. It has a simple analog input to the processor ADC, which provides the sensor data in the ReadTemp function. My guess is that the combined code has a conflict in interrupt priorities. Without knowledge of the board part number, and without seeing the combined code, guessing is all that can be expected. Cheers, Hal2012-12-24 01:14 PM
I'm using mb950 board from stm32w-rfckit.
I guess I have to face it myself and join the code in a different way. Thank for your help.