Hi. all,
I'm using Flir Lepton 3 with Pi 0. The SDK is LeptonSDKEmb64PUB posted around July 2017.
I pack a set of 160x120 pixel value read from valid segment into a linear array called frame buffer[19680].
This frame buffer should contain the individual pixel value above or below 8192, according to the sdk and datasheet. Using best curve fitting mechanism, some users have come up with a best curve fitting equation to derive a coefficient of about 0.0217. This will help plot out a series of pixel values. And the equation for converting the pixel value into a temperature in Celsius that I adapt to use is:
compensated_tempC = 0.0217 * (frameBuffer[i] - 8192) +
(k_temp/100) - 272.15)
For example, 0.0217 * (8290-8291) + 304 - 272.15 = 2.126 + 304 - 272.15 = 33.98 degree C.
0.0217 is the curve fitting coefficient. The index 'i' is the location of the pixel within a frame.
In the second term, k_temp is the camera temperature (in scale of 100) obtained from sdk function LEP_GetSysFpaTemperatureKelvin(). And it subtracts the constant value to get Kelvin to Celsius conversion (1K ~= -272.15 C). ie., k_temp of 30400 represents 304 Kelvin.
Now I point the camera centered to the dull grey color target having a temperature about 36 C measured by an external temperature gauge. And I observed over an hour. The k_temp varies around 30250 +/- 70. And the frameBuffer[i] value varies around 8250 +/- 70.
Ideally I should see the result of this equation rendering 36 C +- 1 degree (that's a precision I care). Well, the result from the equation is only 34 degree C!
For every 80 seconds I call the sdk to do FFC calibration.
Nevertheless, I don't know if the frameBuffer[I] or the k_temp value or both is off for some reason that might have cause to render lower result value. Any takers to explain?
Tom