LMT-01 Questions

LMT01

_images/lmt01-device-info.jpg

The Circuit

As used in F0 Disco Lmt01 Gema

_images/f0-disco-lmt01-gema.jpg

I have used this sensor in a number of demo projects linked below and along the way, some interesting observations/questions about this sensor have been raised.

F0 Disco Lmt01 Gema

A Blue Pill LMT01 Temperature Sensor

Project: LMT01 Temperature Sensor

Temperature Sensor Simple

Q&A

Q1: Is there a MINIMUM reset time ?

The technical manual gives no details about any minimum reset time in the Timing Diagrams or the Maximum Parameters, but there is a interesting paragraph in the text which says:

“The LMT01 can be powered down at any time to conserve system power. Take care to ensure that a minimum power-down wait time of 50 ms is used before the device is turned on again.”

So are Ti claiming that the MINIMUM RESET TIME = 50mS. ?

I use, and I’m very fond of this sensor due to the ease of use and accuracy. It’s the best temperature sensor I have ever seen.

So I want to know, IS there a MINIMUM RESET TIME ? A good question so obviously a test is needed to confirm.

Forth is Interactive

So its very easy to acquire the data in whatever format is needed. In this case Tests 1 - 3 were run in F0 Disco Lmt01 Gema, and the data graphed by Gnuplot.

The Test Criteria

  1. Apply power (a logic one) to the LMT01 for intervals from 50 - 66 milliseconds (in 1 millisecond intervals), counting the pulses each time.

  2. At the end of each interval in 1. above remove power by applying a logic 0 for 10 mS which RESETS the LMT01.

  3. At the end of each interval in 2. above reapply power (logic 1) to the LMT01 and count the pulses for 43 millseconds

The rationale here is that if there is a capacitor that stays charged after a 10mS removal of power within the 50mS pulse cycle, then we should see the remaining pulses when power is applied, UNLESS the act of removing power to the LMT01 causes the device to reset.

Example Code

: test-print ( -- )
   . ." "
;

: sensor-capacitor-test-1 ( -- )   \ LMT01 on for 50 - 66 mS in 1mS increments.Off for 10 mS.
   66 50 do
   clear-lmt01-counter
   enable-comparators              \ Receive lmt01 pulses into TIM2
   lmt01-on
   i ms.delay i test-print         \ Step 1.
   lmt01.count? test-print cr      \ print count
   lmt01-off                       \ Step 2.
   clear-lmt01-counter             \ Step 2.
   10 ms.delay                     \ Step 2.
   lmt01-on                        \ Step 3.
   43 ms.delay                     \ Step 3.
   lmt01.count?                    \ Step 3.
   lmt01-off
   disable-comparators
   loop
;

Output

50 1
51 103
52 191
53 278
54 366
55 454
56 541
57 629
58 717
59 804
60 892
61 980
62 1067
63 1155
64 1219
65 1220

The Results

In this graph the X axis (50 - 70) is the period in milliseconds that power is applied in 1. above.

The Y axis (-100 - 1300) is the total number of pulses counted each time. These represent the temperature.

Test1, the PURPLE line are the pulses counted in 1. above

Test2, are the pulses counted in 3. above

Test3, is a derived value of what Test2 WOULD be, if the LMT01 retained the remaining pulses after the RESET in 2. above.

Does all this make sense ? please let me know if it doesn’t ?

_images/lmt01-reset-test-graph.jpg

Conclusion

It would seem from these tests that there IS NO 50 MS RESET TIME REQUIRED as claimed in the technical manual text, which would also explain why it is not shown in the timing diagrams, maximum electrical parameters or mentioned anywhere else. In other words, if there were a valid 50mS reset, the GREEN line would be overlaid on the BLUE line.

Joey Shepard asked “What use is one test, perhaps other units behave differently ?” and he’s right. At least my test has proven that the claim “The LMT01 can be powered down at any time to conserve system power. Take care to ensure that a minimum power-down wait time of 50 ms is used before the device is turned on again.” is not always true.

So my conclusion is this:

If reset time is not an issue for your design, “ensure that a minimum power-down wait time of 50 ms is used before the device is turned on again” but if it is, reduce the reset time and test the device resets over the range of temperature and voltage you’re using.

Q2: What is a MINIMUM power cycle so that no pulses are generated ?

Q1 shows that it’s 50mS

Q3: Why is the powerup pulse spike not mentioned ?

I found that when I applied power to the LMT01, I always had one pulse counted by the counter. This occurred at the same instant power was applied.

I guess this is due to the pcb layout and how fast power is applied, and it can be easily ignored in software.

Could this be a internal PSU capacitor charging up ?

_images/lmt01-startup-spike.png