3.7 Temperature Test

The principle of the ultrasonic distance measurement depends on the velocity of the ultrasonic wave in the air. The velocity of the ultrasonic wave in the air is influenced by the air temperature. In strict applications, consider the temperature factor in the distance calculation to achieve a more accurate result.

Figure 3-11. NTC Measurement

As shown in the figure above, a low-cost NTC resistor is used in this design. See the tables below for more details about the resistor.

Table 3-3. NTC Resistor Pin Map
Part NameManufacturer Part NumberSignal NamePin in MCU
NTC resistorNCP15WF104F03RCTempPB4

The table below shows the accurate relationship between the temperature, NTC resistance, and voltage at the NTC resistor.

Table 3-4. Detail Parameters for the NTC
Temperature [°C]Resistance [kΩ]Rtemp=Rth*R108/(Rth+R108) [kΩ]Vtemp=3.3*Rtemp/(Rtemp+R105) [V]
-404397.11997.776354151.631448664
-353088.59996.86382641.623714387
-302197.22595.646921831.613288055
-251581.88194.054276131.599444843
-201151.03792.00663131.58130936
-15846.57989.43564141.557983569
-10628.98886.282353071.528495644
-5471.63282.506227781.491842525
0357.01278.118736491.447303274
5272.573.154362421.394186047
10209.7167.711730331.332337992
15162.65161.926663141.262040385
20127.0855.962656331.184108877
25100501.1
3079.22244.203278621.01156382
3563.16738.713097620.920988893
4050.67733.632870310.830547692
4540.90429.029693980.742449177
5033.19524.922106690.658353867
5527.09121.316222230.579836168
6022.22418.183008250.507720425
6518.32315.485577610.442500329
7015.18413.182386440.384351988
7512.63511.217649930.332845055
8010.5669.5562831250.287849619
858.8738.1498626840.248678511
907.4816.960299960.214743133
956.3375.9593556340.185598275
1005.3845.1089349430.160400116
1054.5944.3922213510.138844928
1103.9343.7850943870.120352653
1153.383.2694911980.104477332
1202.9162.8333786780.09092524
1252.5222.4599598140.079229656