Using Lepton 3.5 at high temperatures

624 views
Skip to first unread message

Max Lipitz

unread,
Nov 18, 2021, 6:53:00 PM11/18/21
to Flir Lepton

The Gist.

Do you know why our Lepton 3.5 in the radiometric mode set at low gain can only register temperatures up to 454.37º C (45437-pixel count) even though the manufacture clearly says a maximum of 400º C low gain mode? 

Introduction:

Hi, My name is Max, and I am a college student in Rochester, NY working with the Lepton 3.5 for deployments in wildfire research. Our setup is a pi zero with the FLIR Lepton Breakout Board v1.4 by GetLab (see link 1). We are also using a custom printed circuit board to connect the GPIO on the pi to the SPI pins of the breakout board. The code we are using to get the images onto the pi is a straightforward c program I found online(see link 2). We got the Lepton 3.5 specifically for its 400º C radiometric output in low gain mode. However, we have had much trouble in getting to that 400ºC output. The problem we are having is that the maximum radiometric value is always 45437 or 454.37º K = 181.22º C = 358.196º F. No matter how we change the gain, it is always the same maximum value. 

This was discovered when testing the Lepton with a black body thermal target (addendum 1) with a maximum temperature of 400º C. We have tried multiple techniques(see below) and gone over the documentation many times, all to no avail. We hope that someone in this group knows some little detail or a trick  

The Things we have tried include 

Setting the Gain to Low:

Of course, this would be the first method and the one most recommended to boost the maximum temperature value. The code we are using is this package written for part of a bachelor’s thesis at the Brno University of Technology in the Czech Republic (see link 3). The lepton control code that is part of the package works great. You tell it to close the shutter, it closes the shutter, you suggest it disable radiometric mode, it disables it. However, we have found that there is no change in maximum readout value when changing the gain mode from high(default) to low. 

Change the T Linear scale:

This is another technique recommended online, changing the T linear scale from 0.01 to 0.1. However, this seems to only change the maximum radiometric value from 45437(454.37º K) to 4543(454.3º K). 

Rebooting after changing settings:

The first rule of I.T. is to turn it off and turn it back on. This has never affected the max value.

Switching off radiometric mode: 

We have found that switching off radiometric mode can increase the maximum temperature before the 14-bit full count of 16,383 is reached, although this is nowhere near 400ºC. We are more than capable of calibrating the Leptons ourselves; however, it is a step we would like to avoid if possible. 

Shouting and Various Threats: 

Also, since we have purchased multiple Leptons, we have threatened to dump those cameras into acid unless the Lepton we are testing with cooperates with us. In an attempt to get the Lepton to cooperate, we have shouted various hurtful statements at it. We thought these techniques would work best given that all the Leptons came from the same a 

Things we have ruled out 

     1. The custom printed circuit 
    • All it is seven wires to connect the two boards in a space-efficient manor. It has no microprocessor on it.
       2. Inaccurate Temperature readings from the Black Body.
    • Although extremely unlikely that such a well-calibrated device would be off, we independently verified with both a laser thermometer and another thermal camera that the black body was at the temperature specified.

Things we have NOT ruled out 

     1. The c code we are using.

    • We are still not sure how the c code is getting the image out of the Lepton, so there is quite possibly something caping the radiometric output at 45437. 

     2. Using the wrong breakout board.
    • In the past, we have used older model Leptons 2 or 2.5 for our wildfire probes. In making the new generation of probes, we have recycled the breakout boards from the old probes. So, Is the FLIR Lepton Breakout Board v1.4 by GetLab we used for the Lepton 2 and 2.5 affecting the Lepton 3.5?
      3. Our control code is not changing the gain. 
    • Although our control code seems to be working with the visible result when changing other settings such as a t-linear and radiometric mode, there never seems to be any change in maximum value when we change the gain setting. What technique do you use for changing the settings on IC2?
      4. Something on the Raspberry PI zero:
    • Possible something in the Raspberry Pi Zero is causing a value cap?
        5. Some settings in the raw14 format output:
    • Is there some obscure setting regarding the raw14 out that would fix our problems?

Final Notes

We understand that it will not be possible to get up to 400º C. This is, of course, due to 400ºC in kelvin being 673.15 or 67315 in pixel values which would be higher than the maximum 16 bit out of 65535 382.2º C. However, any knowledge you could share with us to increase the maximum radiometric temperature output above 45437 would be invaluable and potentially life-saving for the millions at risk of wildfires every year. 


Thank you for taking the time to read this, and we will be happy to answer any clarification questions you have. Hope to hear from you soon.

Max Lipitz

Robert Kremens PH.D


Addendum 1:

To put it simply, a black body thermal target is an exceptionally well-calibrated hot plate. It is a thermal target that can precisely control its temperature to a high accuracy for use in calibrating thermal responses in an imaging system. 


Links:

Link 1:

Link 2:

Link 3:








Max Lipitz

unread,
Nov 19, 2021, 10:04:04 AM11/19/21
to Flir Lepton
A brief correction  in the Gist I say 454.37º C "(45437-pixel count) " what I meant was 454.37º K. Apologies for any confusion.

Max Lipitz

unread,
Dec 17, 2021, 4:58:32 PM12/17/21
to Flir Lepton
An update a very, very, very, helpful individual pointed out to me the issue. As it turns out it was a typo in the control code.  On line 130 of the file control.py under the file v4l2lepton3(see link). 
sys_gain_mode': Lepton3GetSetCommand(Lepton3Command.Module.SYS, 0x1C, {'high': [0x00, 0x00], 'low': [0x00, 0x01], 'auto': [0x00, 0x02]}),

Change 0x1C to 0x48 and it will work like a charm!

Now am I kicking myself for missing something that simple yes. Do I wish future Max had come back in time and told me? Absolutely not because then I would have leaned nothing. 

Always remember the  universe is conspiring in your favor. 

Max

link to line that needs mixin and fixin. 
Reply all
Reply to author
Forward
0 new messages