Skip to main content
Andreas Fischer
Associate II
January 4, 2017
Question

Inexplicable offset on internal temperature sensor of STM32F446

  • January 4, 2017
  • 13 replies
  • 2694 views
Posted on January 04, 2017 at 13:19

I have a Nucleo-F446RE Eval Board with a STM32F446 RET6U. The internal temperature sensor shows valid values of about 34°C with constant cpu load.

With the same program code on a STM32F446 RET6 soldered on the target hardware the internal temperature sensor shows a value of about -200 °C.

Both µCs have a factory-calibrated temperature value in the corresponding register, which is used for the temperature calculation. At the Eval board and the target hardware all supply voltages are basically the same. Why is there an difference? At several identical hardware versions, the temperature sensor shows always this behavior.

    This topic has been closed for replies.

    13 replies

    waclawek.jan
    Super User
    January 4, 2017
    Posted on January 04, 2017 at 13:23

    What are the raw readings and the calib values?

    Andreas Fischer
    Associate II
    January 4, 2017
    Posted on January 04, 2017 at 13:42

    Nucleo-F446RE Eval Board STM32F446 RET6U:

     

    TS_CAL1: TS ADC raw data acquired at temperature of 30 °C, VDDA= 3.3 V

    Reg: 0x1FFF7A2C Val: 0x04B003B6

    Reg: 0x1FFF7A2D Val: 0x0104B003

     

    TS_CAL2: TS ADC raw data acquired at temperature of 110 °C, VDDA= 3.3 V

    Reg: 0x1FFF7A2E Val: 0x400104B0

    Reg: 0x1FFF7A2F Val: 0x66400104

     

     

    STM32F446 RET6 soldered on the target hardware:

     

    TS_CAL1: TS ADC raw data acquired at temperature of 30 °C, VDDA= 3.3 V

    Reg: 0x1FFF7A2C Val: 0x04AD03AF

    Reg: 0x1FFF7A2D Val: 0x0204AD03

     

    TS_CAL2: TS ADC raw data acquired at temperature of 110 °C, VDDA= 3.3 V

    Reg: 0x1FFF7A2E Val: 0x400204AD

    Reg: 0x1FFF7A2F Val: 0x66400204
    Andreas Fischer
    Associate II
    January 4, 2017
    Posted on January 04, 2017 at 13:58

    ADC Data Register

    0x40000000 + 0x00010000 + 0x2000 = 0x40012000

     

    Offset:

    0x40012000 + 0x4C = 0x4001204C

    RAW Data of ADC data register of STM32F446 RET6 on target hardware (several read outs):

    0x000000F6

    0x000000F7

    0x000000F1

    0x000000EF

    0x000000F4

    0x000000F3

    0x000000ED

     

     

    RAW Data of ADC data register of Nucleo-F446RE Eval Board with a STM32F446 RET6U (several read outs):

    0x000003CB

    0x000003CF

    0x000003D1

    0x000003CF

    0x000003D0

    0x000003CF

    0x000003D1
    waclawek.jan
    Super User
    January 4, 2017
    Posted on January 04, 2017 at 14:07

    The raw data are way off. They should be around 0x3Bx.

    Don't you use the ADC in non-12-bit mode?

    Seb
    ST Employee
    January 4, 2017
    Posted on January 04, 2017 at 17:34

    If the software is the same, other possible root cause could be :

    - If the package has Vref supply pin, it might be different voltage than Nucleo (or not connected)

    - The supply voltage of the MCU is unstable or has big ripples

    - The pinout of the 2 boards are different and the ADC channel is wrong.

    -  Quick oscilloscope probing of all the pins on Nucleo (including supplies and oscillators) vs Target board might show clues

    Good luck!

    Mert Karadeniz
    Visitor II
    December 11, 2017
    Posted on December 11, 2017 at 13:53

    Hi,

    I have the same problem and I tried the everything that is mentioned above. Is there anybody know what the actual problem is?

    Kind regards,

    Mert.

    waclawek.jan
    Super User
    December 11, 2017
    Posted on December 11, 2017 at 15:02

    What are the raw readings and the calib values?

    Mert Karadeniz
    Visitor II
    December 11, 2017
    Posted on December 11, 2017 at 16:46

    Hi,

    Calibration values

    TEMP30_CAL_ADDR = 0x3b1

    TEMP110_CAL_ADDR = 0x4ad

    Raw values

    0x492

    0x48e

    0x491

    0x492

    0x493

    0x48e