Progress: 65,6% Hardware: v9 Code: v9.8
Change-log:
- implemented AMG8833 8x8px Thermal Cam
- added Button2 library for Interrupt double-click detection
- enabled INA260 Interrupt low voltage alarm to trigger system power off through Buck converter EN pin
- removed pull-up resistors on all I2C sensors, keeping 10k main I2C pull-ups
- bug fixes
Issues:
- detecting SD unmount or error inside Loop() not working anymore
- removed MPU9250 for AMG8833 to work (I2C addresses)
AMG8833 Functions:
Using Algorithm from the Adafruit AMG88xx Library.
Screen shows: Center Point Value, Max Value, Min Value, fps, Interpolation Time
- LowRes Mode 30x28 Pixels Interpolated, 12 fps
- HighRes Mode 120x111 pixels Interpolated, 1 fps (+Auto-Exposure)
- Full Screen burst mode collects the highest value out of the full array
- Center Point burst mode collects the highest value out of the 2 center pixels
Button Single-Click: Trigger Burst Measurement (small 0.49" screen shows 3-sec countdown)
Button Double-Click: Toggle Measurement Area (Center Point, Full Screen)
In HighRes mode i maxed out the Resolution so the frame Rate drops to 1. The Colour Temperatures are mapped to onscreen Min and Max Temps. Kinda works like a simple exposure compensation in a normal camera. The adjusted values get passed on to the LowRes mode if switched. Default temperature scale is 22C - 33C.
It features a Burst Mode (Averaging Mode) to get a more accurate reading with the 8 bit sensor values, by averaging 50 samples over 3 seconds. Measurement will always be taken from the highest temperature seen by the Sensors inside the selected Measurement Area (Full Screen (64px) or Center Point (2px)).
Issue: i can't, for the life of me, figure out how to access the full color spectrum to have smooth color transitions. I tried using the eSPI colors and a conversion method, but could only get it to work by accident with smooth colors going from dark blue to purple, and dropping 6 fps. no good. Could have something to do with the 16bit color mapping and how they are arranged in the array, since the actual 8x8 sensor values are 8-Bit, but the array only holds about 32 or 64 colors it looks like. i don't understand how to map the array correctly, or where to get a premade one.
Burst Measurement Mode Full Screen:
In LowRes mode measurement happens while displaying. In HiRes mode no displaying is happening during measuring, because we are displaying at 1 fps. So it is a true burst reading, only acquiring data and then going back to displaying, and is much faster because of that (ca 1 sec, 50 samples). Temp Numbers are still being updated and last image stays on screen.
maxTemp = pixels[64]; // find biggest value
for (idx = 1; idx < 64; ++idx) {
if (pixels[idx] > maxTemp) maxTemp = pixels[idx];
}
minTemp = pixels[0]; // find smallest value
for (idx = 1; idx < 64; ++idx) {
if (pixels[idx] < minTemp) minTemp = pixels[idx];
}
the bit of code that finds the highest and lowest value and index of the 64 pixel array.
i know, it's just a simple for loop, but haven't used it like this before. then again, i'm pretty new to this.
Burst Measurement ModeCenter Point
Small 0.49" Screen Shows Burst measurement reading. this picture is from earlier in the process
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.