Nice video, well done. I made a MLX based thermal camera and use automatic gain control to maximize the range from the min temperature to the max temp of any scene. Then I use 255 values in my color map to display the scene. In this way I can use the camera to find hot spots in electrical circuits and electrical panels or motors or anything that heats up. The camera always maximizes the gain so that whatever it sees, it uses 255 different color values to display. As an added feature I have a setting to add a contrast curve to the display to expand either the low range (for looking at cold objects) or expand the high range (to get more detail out of hot objects). Yes the FLIR based sensors are better, more resolution is always better, but nothing beats the joy of using a gadget of your own making!
Good video, thanks Andreas. Having had some experience with thermal cameras I have found that to overcome the emmissivity problems, stick some black electrician tape on the surface you want to measure, always consistent result. Cheap and easy. Merry Christmas
Thanks for the tip. For finding heated parts in a circuit this is probably not necessary because if you know it, it is enough. But for applications where you are interested in exact temperatures, this is a must.
To be more accurate, they work in the FIR (far infrared) region of the spectrum. NIR (near infrared) is actually very easy to detect with a normal camera sensor. The problem is that most cameras have IR filters for a better image, but phone cameras and webcams can detect strong sources of NIR, like a remote control. And if you remove the IR filter and add some IR LEDs, you can make a night vision camera!
@@AndreasSpiess, I use my cellphone for quick checks to see if IR remotes are working properly. The remotes are close enough to visible light and the phone cameras are close enough to IR detection that even with the IR lens filters they still show the IR of the remotes. I also use the cellphone camera for live video to see what I'm doing when playing with free-air IR laser communications.
The MLX module that M5stack sells is the most expensive I could find. The breakout boards from pimoroni are a little cheaper (56€) and work just as well. You can also use them with their pi breakout garden hat. As to the usefulness, I would say that you could maybe scan your house for heat leaks. Concerning the M5Stack, I never had any problems programming it either with the Arduino or the ESP32 IDF. I also use the M5 SDupdater library, so that I can store all my programs on an sd card and just load it into the M5Stack when needed.
Thanks for the link to Pimironi. As I mentioned in the video: Maybe they changed the design. Mine is one of hte first series. And maybe I just was not lucky...
@@AndreasSpiess The MLX from Pimoroni was a lot of fun to use: twitter.com/DavidGlaude/status/1018379593667969025 It confirmed to me that dogs do use the mouth and feet to get rid of the heat.
I also had no problem with the m5stack programming. The new cloud-based IDE is amazing because you can program wirelessly. The new product is the m5stick which is only about $15 including shipping. This smaller unit includes an OLED display. I have a couple on order and I'm looking forward to use them.
Thank you for the useful information on some interesting sensors. You are right that they are not FLIR quality cameras but can be useful as PIR sensors in limited functions. Both you and your wife have a Happy Christmas and a Blesed New Year!
Andreas, if you haven't done it already, a video on the simplest pir circuit you showed would be a guaranteed success after your difficulties here. I have a little Phillips battery led light with pir which I use as a bedside light. Great, just wave a hand over the bedside table. Trouble is it has a fixed on time which is very short and I don't know how to modify it. Simple mindedly, I could put a small torch beside it. It will let me see the torch. But if you have a way of combining the two functions and maybe giving the "torch" (manual override) a long timeout in case of forgetfulness, that would be very nice. Oh and battery powered please, believe it or not I don't have mains in my bedroom!
Most of the devices have a sensor and some sort of logic. The logic decides how long the lamp is on. In my case, it is built into Node-Red. In your case, it is a capacitor and a resistor which determines the time.
I've been working on a person detector using the GridEYE sensors, they are really neat. With some math and computer vision it's really good at spotting people in a room. You need to do some fairly sophisticated processing to smooth the sensor values and correlate the background to maximize the sensitivity, but there is a paper on the algorithm. Without the processing it's limited to a couple meters max, but with the extra analysis you can easily see a person at 5 meters or more (and it will dynamically adjust background, so the false alarm rate is low). These sensors work extremely well for person detection, but their low resolution means it takes some expertise to use them. I'd like to eventually release the code I'm working on, but I'm not sure if it's suitable because it requires a pretty complex procedure to calibrate the filters (the coefficients are the main detail that the paper leaves out). The algorithm is basically Kalman filtering on the pixel values to smooth the noise, plus online regression between the built in temperature sensor and the pixel readings to estimate the scene background, followed by a statistical hypothesis test to determine if a pixel has a person in it or not. I can find the paper if you're interested, though it leaves a lot of details out. I think Sharp also has a demo program for people detection, but I don't think it's quite so sophisticated and I never could find the source.
@Undefined Lastname GridEYE is the AMG8833 mentioned in the video. 8x8 PIR sensor. The statistical test is pretty simple, just a logistic test comparing a sensor reading to the predicted background. It doesn't distinguish people from other heat sources, but it can distinguish foreground from background so it can compensate for static heat sources. Paper is here file.scirp.org/Html/2-1730560_74726.htm It's really vague about some important details and kinda poorly written, but it does work quite well if you can fill in the blanks. I may write about it some day, but I don't have a lot of time at the moment.
@Undefined Lastname It fits the background to each pixel individually, correlating it with the temperature sensor via fitting a linear model. All of the filtering and tests are per pixel. This is not my algorithm, it's other people's work. It doesn't really deal with movement tracking, it's for maximizing the signal to noise ratio to make it easier to distinguish hot objects. You could implement movement tracking on top of it, if you wished. Of course, it relies on body temperature being significantly different from background. It can distinguish multiple people, but it depends on how close they are and the distance to the sensor (resolution decreases with distance). It is not suited for outdoor use. No single sensor will be perfectly reliable for detecting people in all situations. If you want the most comprehensive detector possible, you'll need to do sensor fusion of multiple different types of sensor (e.g., motion, thermal, vibration, sound, camera etc). This is fairly cutting edge, probably getting a little beyond what's accessible to a hobbyist currently.
I bought an HT-02 for about $250 and I like it. What I don't understand is, why none of these (even expensive ones), align the video camera image and IR camera image, through digital processing, so that the images line up on the LCD display. As a result, I switched of the video portion, and only rely on the IR image on the LCD to locate the hot spots.
Talking about the MStack. How hard would it be to recreate that module? An ES32, battery charger/battery, screen and box/buttons - seems like something we could all do.
If you don't need and ESP32, I build most of my Wemos D1 Mini modules with the "stackable" headers (except power supply ones, which always go on the bottom. And displays, which always go on top). Not as pretty as the MStack, but functional.
If you look on aliexpress, you will find some esp32 modules with vary similar specs from TTGO. They only lack the modularity, which is a nice aspect, but certainly can also be done.
Marcus Metzler, hey, can you provide a link? Sometimes is not the base price of the thing but the price start point so not to deal with the customs (time and money not so well spent).thx
Ok, my mistake, it was on banggood: www.banggood.com/Wemos-ESP32-TS-V1_2-MPU9250-1_8-Inch-TFT-Bluetooth-Wifi-MicroSD-Card-Slot-Speakers-Module-p-1287887.html
It’s easy to recreate the M5Stack but how much is your time worth? With targeting a standardized platform, your projects will reach more people. I’m surprised more companies (Adafruit) don’t offer a complete/expandable “system” for Makers. But Andreas is right, the price should be lower.
The one pixel PIR sensors use a lens that focuses an array of "hot spots". So when the subject moves, he enters and exits the various hot spots, causing a variable signal that is easy to detect. That's why the lens looks a bit like an insect's compound eye.
Very impressive video, Andreas - you obviously laid down a lot of work here. Thank you and please keep on! I now signed up on Patreon and became a supporter.
Well this is something new... Usualy after watching one of your videos my wallet goes dry, but this time I feel like you saved me a couple of bucks and a lot of disapointment! Thank you Swiss Wizard and have a Merry Christmas!
I wanted for Christmas a Thermal Camera, but the budget did not allow for the camera I would like to have so I am holding my "points" for next few years, so I can get the one that would work as I like it to perform. But I enjoy your comparisons and it gave me a better understanding of the "future" Thermal Camera. I hope someone will send you some reasonably priced camera but with a very high resolution and options that would make me reconsider my position. Thanks again Andreas!
Maybe already next Christmas. Or the year after. These cameras for sure will also become cheaper over time. For the moment it is not for hobby usage. I had a neighbor which had one for business and I used it once to check my house.
Im building a thermal camera with an ESP32 Cam and the MLX90640, not sure how im gonna combine the VIS with the IR, but either way many thanks for the fixed version of their repo, I will defo be using it when the mlx arrives
@@AndreasSpiessHey, just a quick question, where can i find M5Stack.h? Im trying to program using the arduino IDE, and it keeps throwing an error for that, even when i try to download it from the m5stack github, just doesnt work.
The AMG seems like a fairly good deal tbh for image recognition and tracking. Especially if you blend the image with a cheap visible light camera like the expensive one does.
I like diy stuff. I like making something useful in real life. When i saw this video, i think i would try it. But when i learn it little deeper, what i can do is buy that sensor, put positive and negative current. And if it don't work i will throw it to trash bin. I don't know where these guys learn about all those stuff, they are so clever, know everything what they need to solve their problems. I just don't know where to start 😑 The one makes me harder to learn was speaking in english, i'm indonesian, i'm so sorry if theres mistakes in my words. Respect sent from indonesia sir.
Would be interesting to see Terahertz cameras or spectrometers that could be made cheaply. We can practically make a tricorder with that. Cannot find any small terahertz source .... maybe you know Andreas?
Thanks for yet another stellar review of available technologies! It really helps to know what to expect BEFORE plunking one's hard-earned money down for products that may ultimately disappoint. Now I know what to expect from each sensor and I'm not tempted to fire up my debit card & soldering station to create a diy thermal imaging device that really won't solve any of the application problems that I might want to tackle. Unfortunately, one really has no choice but to save up for a FLIR or similar commercial device to get something really useful. (As usual, you get what you pay for...) Thanks Andreas!
I think the third sensor could be fine but with additional camera, little bit more code to combine images and also "little" code for additional image processing. There are algorithm like superresolution but they need obviously better MCU/DSP to perform in the real time. It will be nice and success project but obviously not cheaper like commercial solution. :)
I've been in the electronics business for many years. It seems like people with few to many years of comparable experience manage to get it wrong and promulgate it far and wide. PIR is not an initialism for Passive Infrared Sensor. A PIR is an active device. The correct term is Pyroelectric Infrared Sensor, that is what PIR is an initialism for. Do not quote me Wikipedia, they are wrong. Pyroelectric infrared sensors detect infrared rays using the pyroelectric effect of pyroelectric ceramics, a kind of piezoelectric ceramic. And, do not call PIR an acronym, it is not, it is an initialism. RADAR and SONAR are acronyms as they are an abbreviation formed from the initial letters of other words and pronounced as a word. PIR is not a PURH, which is what a cat does when it is happy.
@@AndreasSpiess I agree, whether PIR is short for Pyroelectric Infrared or Passive Infrared doesn't make much difference unless the result would be worth mentioning and for the task at hand they're just not the proper tool. Very useful for other applications but not as thermal cameras.
Very well analyzed topic. By the way almost all the devices you address are thermopiles invented by a neighbour PhD in Italy in 1835. I've used the MLX90640 on an ESP32 and remoting to another and TFT using ESP Now. Your video could show better display results I think with interpolation and colour mapping changes. You could detect human presence or movement by blob detection, at least indoors. I2C I think you found is problematic for both this sensor and esp32; there is a wire code fork on GIT which nicely addresses. Your basic pir is a dual element thermopile which differences and band passes areas in the field of view. There are nice cheap digital versions which give more control of parameters.
AFAIK the sketch used interpolation and mapping. I think it is possible to detect humans if they are close to the sensor. This was visible in the picture taken by the camera in the video. My point was that I think it is not easy if they are somewhere in the room. At least with my 110 degrees sensor.
@@AndreasSpiess Yes it boils down to "pixels on target" and background resolution. This chip has about +/-2C resolution depending on frame rate. Panasonic claim 7m. human range in their video so the -40 chip and 778 versus 64 pixels and similar FOV should be about twice this range? But more pixels means slower data rates and processing. I've got to about 3m. tracking with the 16x4 mlx90620 chip as used in the"Garage Proto" thermal cam. I expect another future, tutorial on .the new $10 Esp32 2MP cams could get into this?:) Merry Xmas.
3 Meters seems to be the maximum for the 110 degrees camera and I would expect quite a few false triggers... I am not sure if the ESP and image processing is a good fit. I will concentrate more on the RPI for that as you get more software there.
One has to write a translator for "Swiss judgments". After doing business (selling technology to Swiss companies) I got some understanding: Swiss => English "Worst ever" => "Bad, but could be fixed" "Not acceptable at all" => "Okay, with flaws". "Not acceptable" => "Quite okay". [...] "Okay" => "Really super great" "Good" => "The best thing ever which existed in space and time"
The mlx sensor really needs a good external lens if the technology is going to impress. The aperture is just too damn small to be very useful. (Though placing it right next to a visual camera and doing the overlay trick would probably make it look quite passable when compared to the fair) If there could be hot or cold mirror so the cameras could be aligned it would be amazing.
@@AndreasSpiess if I remember correctly they flir takes a highpass of the visual and then do the overlay. The smaller sensor, tiny cellphone camera, and add a surface mount lidar for distance and you could have something that could compete in the low cost market.
Robert Szasz I am trying the exact same thing but with a raspberry and the mlx90640 and the picam. They both have a similar fov and i want to program it in opencv c++ but installing opencv is a challenge in itself.
@@Lackenboden if you can, you might want to just add a flat "cold mirror" (the material they use for thermal lenses could work well) that would reflect visual light to the vis camera and let thermal energy through to the sensor. That would allow you to allign the two cameras views mechanically (Sort of like they did with 3ccd color video cameras back in the day) at the expense of a larger footprint. (Two camera modules next to each other is a Way thinner package)
@@Lackenboden and Open CV might not be the right tool. You mostly want to do a simple transformation of the video, then either make it B/W and overlay the temperature as color, or just run a high pass to keep edges and put the color on top. If you want to get better registration of the thermal to visual image don't use computer vision techniques, just shift the image based on how far the object is (start with setting things up for far away then use a resistor or something similar to act as a small visual and thermal target to figure out how much you need to shift the image.
This is exactly why I watch your videos, (beyond just enjoying following a knowledgeable and methodical mind.) You show us the state of the tech consumer market for useful, or not so useful sensor, communications, and controller devices, along with all of the associated details, the little 'gotchas' that make or break a project. Thank you.
From what I can see on ebay, you can buy a 60x60 thermal camera for 170$, so it seems it is not worth building one yourself. The biggest problem it seems is that all the sensors are very expensive, maybe in future their price will fall down.
I am sure the prices will come down. My conclusion, as always with electronics, is based on today. Let's hope in one or two years from now we get a usable camera for 100$.
Are those 60x60 real pixels or they're doing some interpolation in between? The cheapest sensor you could get that has that sort of resolution isn't from FLIR, there are other manufacturers, less known - I only managed to found one from Turkey backed by french capital but their site is very limited and can't order any products so no joy experimenting further. So there are other sensors, but the biggest resolution aside from FLIR Lepton based devices I could find is 32x40 which sounds awfully like the MLX90640 with a little interpolation. So until FLIR manage to get their Leptons 3.5 down in price to below $100 there isn't any prospect of "for the masses" thermovision. Also please remember that most manufacturers of this kind of devices normally target the military, law enforcement, security setups. They aren't gonna make available to anyone sensors to be tinkered with and eventually to find a way to overcome them, not that it's that difficult to hide from a thermal camera - just use a sheet of paper, plastic or glass. There's a reason we use glass on our windows to shield from the heat in summer and keep it inside during winter :D
Yes I get the sketch on the stack by pressing the on/off button a couple of times when the bootloader part start. After that I use OTA ruclips.net/video/OpFEUbWgiWs/видео.html
Lustig: ich hab mir gerade eine 30$ Messpistole gekauft. Super als Kochhilfe und zum Suchen von Kältebrücken. Das erste Pixel ist am wertvollsten 😊 Dir und Deiner Frau eine ganz schöne Weihnacht!
Ich hab von meiner Frau einen Thermomix mit eingebautem Temperatursensor bekommen (ist vermutlich etwas teurer als deine Lösung). Eine Freundin hat ihr gesagt, dass sie damit ihren Mann zum Kochen gebracht hat ;-) Sie hat immer noich Hoffnungen. Ebenfalls Frohe Weihnachten und einen guten Rutsch!
Any thoughts on the Walabot? Aliexpress has a $70 Melexis MLX90640? The $70 M5stick T-Lite Thermal Camera Dev Kit (MLX90640) seems to be an integrated M5Stack solution!
Thank you so much Andreas for doing these. I've been interested in this technology for a long time, but they are just so expensive to try & learn them all. Again with many thanks & Happy Holidays.
Interesting and yes I suppose disappointing project Andreas. Still not in the hands of the masses just yet. Thank you for all your content this year. Wishing you and Mrs Hacker a lovely Christmas and wonderful new year.
Thank you for taking the time to evaluate these lower cost IR solutions, your video was very informative. Have you checked out the Seek Thermal camera? It costs less than the Flir unit (around US $170 on Amazon), and has higher resolution (206 X 156). They have versions for both Android and IOS phones, and they now have standalone versions. I've had one of the original release units for a few years and it works well for chasing down heat leaks around the house, which was my justification for buying it, and I feel it has paid for itself several times over in just energy savings. My only complaint with it is that I have to remove the protective case from my phone to use it because it gets in the way of the way it plugs directly into the USB port. Thanks again for the post. -Jim-
I used the FLIR device just to show the difference. I have it for a few years now and back then I got the impression that I got the best for the buck (if I remember right, Seek also was a contender). I do not use it often and for sure will not replace it soon.
You should look into the old cat S60 phones as they have a flir camera built in....the mic died on mine years ago but I've still got it to strip out the camera parts for use with a raspberry pi or something one day as I found it pretty useful but honestly I'd love the newest cat phone as they're awesome
You forgot one kind of intermediate sensors, the spot temperature sensors like the ones used in IR thermometers. They only have 1 pixel, but can detect temperature accurately. For example, the MLX90614.
@@AndreasSpiess Well, yeah, I think the spot temperature sensors should have been there instead of the PIR sensor, which would need calibration to get accurate results. And there are people who made slow, but cheap, thermal cameras with this kind of sensor and two motors, either moving the sensor directly or moving two mirrors (which are just polished aluminium). And this could also be a way to improve the resolution of higher resolution thermal imaging sensors.
If the M5Stack seems to refuse the connection with Arduino as you have shown, just hold the red reset button for at least one second. Then the connection will work. At least, it has worked for me with my gray M5Stack.
3D printed case for the AMG8833 and a 2.8" TFT screen: www.thingiverse.com/thing:2799023 Mounting adapter for the AMG8833 bought from Aliexpress: www.thingiverse.com/thing:3066479 Code for the ESP8266, which enables you to save image data to SD and create images on your PC: github.com/wilhelmzeuschner/arduino_thermal_camera_with_sd_and_img_processing
Technically the simple PIR-sensor has two pixels and your explanation is somewhat wrong. It does not compare a reading with any "last" measurement. It looks at two pixels at the same time, and a difference between the two pixels is what triggers it. :)
Exactly, its output is the differential signal between two series wired but opposing ir detectors. The lens also has a role to play in motion detection. Hint: Mask of half of that IR window with foil tape.
@@noisyaudio it still measures time-variance, i.e. motion. Using two pixels and a lens to distribute the signal on to both pixels increases gain dramatically while rejecting common temperature changes, but it still only detects changes in the signal above a certain frequency. For example, if you stand still, one Pixel will see a higher temperature, but it will still not trigger, unless a fast temperature change, i.e. movement is detected. It's a simple differentiator at the output.
I also looked it up and it seems they use the two pixels to get a two times larger signal. And the lens helps to get two opposite signals with a higher probability. Still, they seem to need time to detect the difference.
The PIR sensor detects changes in background temperature, as well as changes from the scene. In a single element detector, two PIR pixels (one of which is blind) are subtracted from each other, the difference being the energy from the scene. Multiple lenses are used where each lens sees a narrow strip of the scene, with blind gaps between the strips. Moving objects move in and out of the blind gaps, causing temperature changes in the PIR. The PIR material itself takes time to heat and cool. The PIR material acts like an unpolarized nano capacitor - heating or cooling the PIR acts to charge it up one way or the other. The charge itself persists for some time, depending on the design it may be discharged on read, or decay naturally through leakage.
i got a Freetronics IRTemp sensor a few months ago and was thinking about something like this... unfortunatly the IRTemp sensor is only one pixel..its only good for reading surface temps at a spot ratio of 1:1 and has a 1 second response time! thanks for showing me the way Andreas! Merry Xmas to you and yours :)
People were playing with the IR camera sensor from the Wii remote controllers some years ago to track moving objects. I remember that sensor was very narrow angle (about 20 degree or so) and required I2C to communicate. You still may want to try it.
If you use a high-enough resolution camera, with motion-detection software, you'll "see" almost anyone who isn't sleeping or meditating: even when just sitting at a computer or watching TV, few people sit _perfectly_ still. Not something you'd attach to an Arduino or ESP8266, but the odds are good that, if you're doing something that sophisticated, there's a central PC you can network the camera to.
@@AndreasSpiess another "trick" to get an accurate reading since emissivity varies widely by material is to put a piece of black 3M electrical tape on the surface being measured. It has an emissivity of almost 1. Then you can compare readings to get emissivity of the material.
Will the MLX90640 work best if I put it as a smart watch? Or it need to have some distances to work properly? Also what material for casing so the sensor is not measuring the casing? Sorry for a lot of question, I really excited to explore this amazing channel!
I am asking what kind of plastic will pass infrared emitted by MLX sensor, like that is used in ordinary PIR .. "Lenses are 0.015 inch thick and made of a plastic that passes infrared in the wavelength range of 8 to 15 microns which is most sensitive to human body radiation. These are not wide angle lenses. "
Also replace the USB lead. I had to try 5 leads to get a good reliable one and that cost me £12! The supplied usb cable is just useless. Also of note: Arduino is no the preferred environment, they want users to use IDF (which I don't understand )
I did not use their cable. And knowing how ESP32 programming works I doubt it will be different with a different programming environment. But others wrote they fixed it in the current design.
Thanks for making this video. You saved me some time and money. I will wait a few more years for the higher resolution, higher precision and accuracy, as well as higher frame-rate tech to come down to the sub one hundred dollar consumer range. Right now the military is kind of hogging all the good IR tech. Thanks again, Regards,
Great video! I don't know about these i2c IR sensor arrays, they looks promising. I think, 32x24 sensor picture can be a little better, if color palette will be auto ir manually adjusted - in video, all soldering iron was just red. I think, sensor should see different temperatures there, but due to palette we see only solid red... BTW, please try to set programming speed in Arduino IDE to lowest possible (115200?), this helped to me with downloading to board problem...
Seems like it might be more useful to use one of those laser thermometers, and either raster it to build an image, and/or use multiple of them at once to collect more pixels faster. And instead of the normal back and forth rectangular rastering, use polar-coordinate rastering (like a spirograph or a rhodonea curve) so that the center of vision has the most fidelity, while still having some peripheral vision. With these thermal vision things the center of vision is always the most important.
@@AndreasSpiess ne, wir hatten in unserem Bataillon Kameras die zur thermalen Aufklärung eingesetzt wurden. Ich vermisse deren Leistung im Punkt Auflösung und FPS für den zivilen Bereich :/
Can a higher quality sensor be used in a DIY build? I have several FLIR thermal cameras where the IR sensor, camera, board are fine but the screen is broken. Can the sensors be pulled off the board and repurposed?
Thank you for this thermal camera review. I was wondering if 2 could be connected by Bluetooth or wifi to a smartphone (in one of those cheap VR headsets) to create a type of night vision goggles. I figure a USB or lightning connection could be prohibitively difficult or expensive.
Seeing the mxl90640 popular now in 2023 as a £70 camera with touch screen. some claiming 320x240 untruthfully, 32x24 pixels. the Lepton is a nicer resolution, which is 320x240.
I probably would mix the rather cheap (compared to FLIR) sensor with a Pi camera module and see, if calibrated correctly, how that performs. A quadcore SoC should also be able to do the heavylifting of imagemanipulation far better.
Dear Andreas, I need to localize a ants nest in my caravan walls. So behind a plywood. Do you think that a AMG8833 could help me detecting these little critters?
Hello. I agree with the fact that it's a bit hard to modify the MLX90640 to display a different range of temperatures but this is only if you are looking in the wrong place. Also, I checked the temperatures with my Raspberry Pi Zero and 3 and they were pretty much spot on so maybe updated the driver? Or the Pi might work better with it? Either way, below I'll leave the way to modify the MLX90640 to display the temperature range you want. After copying the library to your Pi, you u need to go to: /pi/mlx90640-library/examples/src/ and use a C++ editor (Rasbian has Geany) to edit the file you want (using hotspot as an example) Just scroll down to where you'll see: vmin=5.0 vmax=50.0 Just change these to whatever temperature range you want and save the file. In terminal, go to the mlx90640-library folder and compile the file you just modified by writing: sudo make Then run them with: sudo ./examples/the_file_you_want. I
Very informative, as usual, but one could argue that a quick view of an operating PCB, whatever you had handy in the lab, would have given a much better idea of whether the less expensive PIR sensors would be useful for finding PCB problems. Since the more capable FLIR sensor is a close call for many people (compared to pointing a $15 IR thermometer gun), chances are the cheaper sensors wouldn't make the cut, but it would still be interesting to see the results...
Dear Andreas, that problem with M5 esp32 board is often a problem for us makers when working with standalone ESP based systems. Do you have any standalone version that always accept programming?
Usefull/interesting... of course. It gives me much more insight on the topic and so I've decided... to wait untill better products show up on the market.
Thank you for the video. I was considering MLX90640 (110 degree version) for human detection (as an additional sensor for a visible spectrum camera, street conditions), but it looks useless beyond 2 or 3 meters. This is a disappointment, but still a useful result.
You mentioned that we can feel IR with our skin but I think it's not correct when we feel heat by for example radiation of a fire we're actually feeling the heat which is absorbed by the skin
Well I’m a little late to the party but if I may suggest: Turn your phone around 180 degrees. So the camera is where it would “normally” be for a right handed person.
Thank you for this nice explanation on the cheap thermal options, but it seems if you need a real image then the price goes up with min around 500. Thanks for your useful investment! If the ongoing development is going the go way, let us know! Thanks again
This is really cool, thank you very much. I was missing Heimann Sensor thermopile array in this comparison. Maybe you can try one of their arrays, too.
Imo only the FLIR product quality level make it use able...unless you are building a security system..then just a few read dots in a circle or in a line is enough for the software to set the alarm.
Great video as always. Sadly for now I will stick to my caveman thermal detection method: putting the device close to my lips and moving it around. Seems the lips have better response time and resolution than the finger, but only really work well for SMD boards :))
Very nicely done video as always. I appreciate the efficient education you provide. You should check out the new m5stick. Smaller OLED display. Costs around $15 with shipping. Keep up the good work! Thanks!
Excellent video. I was looking into it some time ago but was not ready to shell out the cash for an experiment. You covered all my interest in the topic in under 15 min for free. Can't beat that. Thank you sir.
Thanks. Could you test, if it's ok, if it get see water pipe leaks through tiles and walls (no hot water running, just regular water)? Thank you. God bless, Rev. 21:4
@@AndreasSpiess Hi thanks. I mean, could it see through the walls and tiles, see the pipes in it (even without the leak, just regular water running through the pipes)
Nice video, well done. I made a MLX based thermal camera and use automatic gain control to maximize the range from the min temperature to the max temp of any scene. Then I use 255 values in my color map to display the scene. In this way I can use the camera to find hot spots in electrical circuits and electrical panels or motors or anything that heats up. The camera always maximizes the gain so that whatever it sees, it uses 255 different color values to display. As an added feature I have a setting to add a contrast curve to the display to expand either the low range (for looking at cold objects) or expand the high range (to get more detail out of hot objects). Yes the FLIR based sensors are better, more resolution is always better, but nothing beats the joy of using a gadget of your own making!
I am glad you found a useful application. I agree, building something is more fun than just buying it.
Good video, thanks Andreas. Having had some experience with thermal cameras I have found that to overcome the emmissivity problems, stick some black electrician tape on the surface you want to measure, always consistent result. Cheap and easy. Merry Christmas
Thanks for the tip. For finding heated parts in a circuit this is probably not necessary because if you know it, it is enough. But for applications where you are interested in exact temperatures, this is a must.
To be more accurate, they work in the FIR (far infrared) region of the spectrum. NIR (near infrared) is actually very easy to detect with a normal camera sensor. The problem is that most cameras have IR filters for a better image, but phone cameras and webcams can detect strong sources of NIR, like a remote control. And if you remove the IR filter and add some IR LEDs, you can make a night vision camera!
You are right. I use "night vision" cameras on my Pi to detect the beam of IR diodes.
@@AndreasSpiess, I use my cellphone for quick checks to see if IR remotes are working properly. The remotes are close enough to visible light and the phone cameras are close enough to IR detection that even with the IR lens filters they still show the IR of the remotes. I also use the cellphone camera for live video to see what I'm doing when playing with free-air IR laser communications.
The MLX module that M5stack sells is the most expensive I could find. The breakout boards from pimoroni are a little cheaper (56€) and work just as well. You can also use them with their pi breakout garden hat. As to the usefulness, I would say that you could maybe scan your house for heat leaks. Concerning the M5Stack, I never had any problems programming it either with the Arduino or the ESP32 IDF. I also use the M5 SDupdater library, so that I can store all my programs on an sd card and just load it into the M5Stack when needed.
Thanks for the link to Pimironi. As I mentioned in the video: Maybe they changed the design. Mine is one of hte first series. And maybe I just was not lucky...
@@AndreasSpiess The MLX from Pimoroni was a lot of fun to use: twitter.com/DavidGlaude/status/1018379593667969025
It confirmed to me that dogs do use the mouth and feet to get rid of the heat.
I also had no problem with the m5stack programming. The new cloud-based IDE is amazing because you can program wirelessly. The new product is the m5stick which is only about $15 including shipping. This smaller unit includes an OLED display. I have a couple on order and I'm looking forward to use them.
Thank you for the useful information on some interesting sensors. You are right that they are not FLIR quality cameras but can be useful as PIR sensors in limited functions. Both you and your wife have a Happy Christmas and a Blesed New Year!
Thank you. Merry Christmas to you, too!
Thankyou, you successfully deflated my dreams and enthusiasm for building a IR imager using of the shelf chips..oh well, maybe in a few years.
Same here...
Was about to buy the AMG8833 , but did a search on YT first. Glad I did. Money saved. Thanks!
You are welcome!
Andreas, if you haven't done it already, a video on the simplest pir circuit you showed would be a guaranteed success after your difficulties here. I have a little Phillips battery led light with pir which I use as a bedside light. Great, just wave a hand over the bedside table. Trouble is it has a fixed on time which is very short and I don't know how to modify it. Simple mindedly, I could put a small torch beside it. It will let me see the torch. But if you have a way of combining the two functions and maybe giving the "torch" (manual override) a long timeout in case of forgetfulness, that would be very nice. Oh and battery powered please, believe it or not I don't have mains in my bedroom!
Most of the devices have a sensor and some sort of logic. The logic decides how long the lamp is on. In my case, it is built into Node-Red. In your case, it is a capacitor and a resistor which determines the time.
I replaced the flash chip in my m5 stack and it improved the programmability a lot
Thank you for the tip.
I've been working on a person detector using the GridEYE sensors, they are really neat. With some math and computer vision it's really good at spotting people in a room. You need to do some fairly sophisticated processing to smooth the sensor values and correlate the background to maximize the sensitivity, but there is a paper on the algorithm. Without the processing it's limited to a couple meters max, but with the extra analysis you can easily see a person at 5 meters or more (and it will dynamically adjust background, so the false alarm rate is low). These sensors work extremely well for person detection, but their low resolution means it takes some expertise to use them. I'd like to eventually release the code I'm working on, but I'm not sure if it's suitable because it requires a pretty complex procedure to calibrate the filters (the coefficients are the main detail that the paper leaves out).
The algorithm is basically Kalman filtering on the pixel values to smooth the noise, plus online regression between the built in temperature sensor and the pixel readings to estimate the scene background, followed by a statistical hypothesis test to determine if a pixel has a person in it or not. I can find the paper if you're interested, though it leaves a lot of details out. I think Sharp also has a demo program for people detection, but I don't think it's quite so sophisticated and I never could find the source.
@Undefined Lastname GridEYE is the AMG8833 mentioned in the video. 8x8 PIR sensor. The statistical test is pretty simple, just a logistic test comparing a sensor reading to the predicted background. It doesn't distinguish people from other heat sources, but it can distinguish foreground from background so it can compensate for static heat sources.
Paper is here file.scirp.org/Html/2-1730560_74726.htm It's really vague about some important details and kinda poorly written, but it does work quite well if you can fill in the blanks. I may write about it some day, but I don't have a lot of time at the moment.
Thanks for your comments. Can you share the name of the paper you refer to?
@Undefined Lastname It fits the background to each pixel individually, correlating it with the temperature sensor via fitting a linear model. All of the filtering and tests are per pixel.
This is not my algorithm, it's other people's work. It doesn't really deal with movement tracking, it's for maximizing the signal to noise ratio to make it easier to distinguish hot objects. You could implement movement tracking on top of it, if you wished. Of course, it relies on body temperature being significantly different from background. It can distinguish multiple people, but it depends on how close they are and the distance to the sensor (resolution decreases with distance). It is not suited for outdoor use.
No single sensor will be perfectly reliable for detecting people in all situations. If you want the most comprehensive detector possible, you'll need to do sensor fusion of multiple different types of sensor (e.g., motion, thermal, vibration, sound, camera etc). This is fairly cutting edge, probably getting a little beyond what's accessible to a hobbyist currently.
@@mtarquinio Paper is linked in my reply above.
I bought an HT-02 for about $250 and I like it.
What I don't understand is, why none of these (even expensive ones), align the video camera image and IR camera image, through digital processing, so that the images line up on the LCD display.
As a result, I switched of the video portion, and only rely on the IR image on the LCD to locate the hot spots.
I can align the two pictures in the app. That part works ok for me.
Thank you, you prevented me from wasting some money. As always, you do good work. I hope you and your family have a happy and safe holiday.
Merry Christmas to you, too!
Talking about the MStack. How hard would it be to recreate that module? An ES32, battery charger/battery, screen and box/buttons - seems like something we could all do.
If you don't need and ESP32, I build most of my Wemos D1 Mini modules with the "stackable" headers (except power supply ones, which always go on the bottom. And displays, which always go on top). Not as pretty as the MStack, but functional.
If you look on aliexpress, you will find some esp32 modules with vary similar specs from TTGO. They only lack the modularity, which is
a nice aspect, but certainly can also be done.
Marcus Metzler, hey, can you provide a link? Sometimes is not the base price of the thing but the price start point so not to deal with the customs (time and money not so well spent).thx
Ok, my mistake, it was on banggood: www.banggood.com/Wemos-ESP32-TS-V1_2-MPU9250-1_8-Inch-TFT-Bluetooth-Wifi-MicroSD-Card-Slot-Speakers-Module-p-1287887.html
It’s easy to recreate the M5Stack but how much is your time worth? With targeting a standardized platform, your projects will reach more people. I’m surprised more companies (Adafruit) don’t offer a complete/expandable “system” for Makers. But Andreas is right, the price should be lower.
The one pixel PIR sensors use a lens that focuses an array of "hot spots". So when the subject moves, he enters and exits the various hot spots, causing a variable signal that is easy to detect. That's why the lens looks a bit like an insect's compound eye.
Thank you for clarification.
Thanks for exploring for us and have a wonderful Christmas!
Merry Christmas to you, too!
Very impressive video, Andreas - you obviously laid down a lot of work here. Thank you and please keep on! I now signed up on Patreon and became a supporter.
Thank you for your support! Like that, I can spend some money on such videos.
Well this is something new... Usualy after watching one of your videos my wallet goes dry, but this time I feel like you saved me a couple of bucks and a lot of disapointment! Thank you Swiss Wizard and have a Merry Christmas!
I know the feeling..... Andreas ruined my Visa account more than once....
Merry Christmas, too!
I wanted for Christmas a Thermal Camera, but the budget did not allow for the camera I would like to have so I am holding my "points" for next few years, so I can get the one that would work as I like it to perform. But I enjoy your comparisons and it gave me a better understanding of the "future" Thermal Camera. I hope someone will send you some reasonably priced camera but with a very high resolution and options that would make me reconsider my position. Thanks again Andreas!
Maybe already next Christmas. Or the year after. These cameras for sure will also become cheaper over time. For the moment it is not for hobby usage. I had a neighbor which had one for business and I used it once to check my house.
Im building a thermal camera with an ESP32 Cam and the MLX90640, not sure how im gonna combine the VIS with the IR, but either way many thanks for the fixed version of their repo, I will defo be using it when the mlx arrives
Enjoy your project!
@@AndreasSpiessHey, just a quick question, where can i find M5Stack.h? Im trying to program using the arduino IDE, and it keeps throwing an error for that, even when i try to download it from the m5stack github, just doesnt work.
The AMG seems like a fairly good deal tbh for image recognition and tracking. Especially if you blend the image with a cheap visible light camera like the expensive one does.
Good to know. Thanks!
I like diy stuff. I like making something useful in real life.
When i saw this video, i think i would try it.
But when i learn it little deeper, what i can do is buy that sensor, put positive and negative current.
And if it don't work i will throw it to trash bin.
I don't know where these guys learn about all those stuff, they are so clever, know everything what they need to solve their problems.
I just don't know where to start 😑
The one makes me harder to learn was speaking in english, i'm indonesian, i'm so sorry if theres mistakes in my words.
Respect sent from indonesia sir.
Your English is good enough to do what you want! How do we know all the things? By doing it, making lots of mistakes, and klearn.
@@AndreasSpiess @ got it sir, i'll try from the easiest i can. Thanks for share those creative ideas. It help us so much.
Would be interesting to see Terahertz cameras or spectrometers that could be made cheaply. We can practically make a tricorder with that. Cannot find any small terahertz source .... maybe you know Andreas?
Terrahertz iis infrared. So you should be able to use any heat source.
Great Video! Master piece in selling: making the best out of your frustration and still delivering high value information plus entertainment!
Thank you! So my short time as a salesman was not completely useless ;-)
Thanks for yet another stellar review of available technologies! It really helps to know what to expect BEFORE plunking one's hard-earned money down for products that may ultimately disappoint.
Now I know what to expect from each sensor and I'm not tempted to fire up my debit card & soldering station to create a diy thermal imaging device that really won't solve any of the application problems that I might want to tackle. Unfortunately, one really has no choice but to save up for a FLIR or similar commercial device to get something really useful. (As usual, you get what you pay for...)
Thanks Andreas!
Many things are already cheap and good. These cameras obviously not yet...
I think the third sensor could be fine but with additional camera, little bit more code to combine images and also "little" code for additional image processing. There are algorithm like superresolution but they need obviously better MCU/DSP to perform in the real time. It will be nice and success project but obviously not cheaper like commercial solution. :)
I also found the combination of the two cameras useful. The algorithms probably are not simple ;-)
I've been in the electronics business for many years. It seems like people with few to many years of comparable experience manage to get it wrong and promulgate it far and wide.
PIR is not an initialism for Passive Infrared Sensor. A PIR is an active device.
The correct term is Pyroelectric Infrared Sensor, that is what PIR is an initialism for.
Do not quote me Wikipedia, they are wrong.
Pyroelectric infrared sensors detect infrared rays using the pyroelectric effect of pyroelectric ceramics, a kind of piezoelectric ceramic.
And, do not call PIR an acronym, it is not, it is an initialism.
RADAR and SONAR are acronyms as they are an abbreviation formed from the initial letters of other words and pronounced as a word. PIR is not a PURH, which is what a cat does when it is happy.
Maybe you are right. I do not care too much about abbreviations as most of my viewers understand if I talk about PIR.
@@AndreasSpiess I agree, whether PIR is short for Pyroelectric Infrared or Passive Infrared doesn't make much difference unless the result would be worth mentioning and for the task at hand they're just not the proper tool.
Very useful for other applications but not as thermal cameras.
Very well analyzed topic. By the way almost all the devices you address are thermopiles invented by a neighbour PhD in Italy in 1835. I've used the MLX90640 on an ESP32 and remoting to another and TFT using ESP Now. Your video could show better display results I think with interpolation and colour mapping changes. You could detect human presence or movement by blob detection, at least indoors. I2C I think you found is problematic for both this sensor and esp32; there is a wire code fork on GIT which nicely addresses.
Your basic pir is a dual element thermopile which differences and band passes areas in the field of view. There are nice cheap digital versions which give more control of parameters.
AFAIK the sketch used interpolation and mapping. I think it is possible to detect humans if they are close to the sensor. This was visible in the picture taken by the camera in the video.
My point was that I think it is not easy if they are somewhere in the room. At least with my 110 degrees sensor.
@@AndreasSpiess Yes it boils down to "pixels on target" and background resolution. This chip has about +/-2C resolution depending on frame rate. Panasonic claim 7m. human range in their video so the -40 chip and 778 versus 64 pixels and similar FOV should be about twice this range? But more pixels means slower data rates and processing. I've got to about 3m. tracking with the 16x4 mlx90620 chip as used in the"Garage Proto" thermal cam.
I expect another future, tutorial on .the new $10 Esp32 2MP cams could get into this?:)
Merry Xmas.
3 Meters seems to be the maximum for the 110 degrees camera and I would expect quite a few false triggers...
I am not sure if the ESP and image processing is a good fit. I will concentrate more on the RPI for that as you get more software there.
One has to write a translator for "Swiss judgments". After doing business (selling technology to Swiss companies) I got some understanding:
Swiss => English
"Worst ever" => "Bad, but could be fixed"
"Not acceptable at all" => "Okay, with flaws".
"Not acceptable" => "Quite okay".
[...]
"Okay" => "Really super great"
"Good" => "The best thing ever which existed in space and time"
You are right. The same judgement is applied for our own work ;-)
The mlx sensor really needs a good external lens if the technology is going to impress. The aperture is just too damn small to be very useful. (Though placing it right next to a visual camera and doing the overlay trick would probably make it look quite passable when compared to the fair)
If there could be hot or cold mirror so the cameras could be aligned it would be amazing.
The overlay trick is really useful. I assume not simple to get the right "blend" between the two images.
@@AndreasSpiess if I remember correctly they flir takes a highpass of the visual and then do the overlay. The smaller sensor, tiny cellphone camera, and add a surface mount lidar for distance and you could have something that could compete in the low cost market.
Robert Szasz I am trying the exact same thing but with a raspberry and the mlx90640 and the picam. They both have a similar fov and i want to program it in opencv c++ but installing opencv is a challenge in itself.
@@Lackenboden if you can, you might want to just add a flat "cold mirror" (the material they use for thermal lenses could work well) that would reflect visual light to the vis camera and let thermal energy through to the sensor. That would allow you to allign the two cameras views mechanically
(Sort of like they did with 3ccd color video cameras back in the day) at the expense of a larger footprint. (Two camera modules next to each other is a Way thinner package)
@@Lackenboden and Open CV might not be the right tool. You mostly want to do a simple transformation of the video, then either make it B/W and overlay the temperature as color, or just run a high pass to keep edges and put the color on top. If you want to get better registration of the thermal to visual image don't use computer vision techniques, just shift the image based on how far the object is (start with setting things up for far away then use a resistor or something similar to act as a small visual and thermal target to figure out how much you need to shift the image.
This is exactly why I watch your videos, (beyond just enjoying following a knowledgeable and methodical mind.) You show us the state of the tech consumer market for useful, or not so useful sensor, communications, and controller devices, along with all of the associated details, the little 'gotchas' that make or break a project. Thank you.
Glad my channel is helpful (and sometimes saves money)
Any suggestion for a sensor for body temperature? It requires small temperature range but high accuracy.
I never looked at this topic.
From what I can see on ebay, you can buy a 60x60 thermal camera for 170$, so it seems it is not worth building one yourself. The biggest problem it seems is that all the sensors are very expensive, maybe in future their price will fall down.
I am sure the prices will come down. My conclusion, as always with electronics, is based on today. Let's hope in one or two years from now we get a usable camera for 100$.
@@AndreasSpiess I got an older Flir One for just over $100, but that requires an iPad to work.
Are those 60x60 real pixels or they're doing some interpolation in between? The cheapest sensor you could get that has that sort of resolution isn't from FLIR, there are other manufacturers, less known - I only managed to found one from Turkey backed by french capital but their site is very limited and can't order any products so no joy experimenting further. So there are other sensors, but the biggest resolution aside from FLIR Lepton based devices I could find is 32x40 which sounds awfully like the MLX90640 with a little interpolation.
So until FLIR manage to get their Leptons 3.5 down in price to below $100 there isn't any prospect of "for the masses" thermovision.
Also please remember that most manufacturers of this kind of devices normally target the military, law enforcement, security setups. They aren't gonna make available to anyone sensors to be tinkered with and eventually to find a way to overcome them, not that it's that difficult to hide from a thermal camera - just use a sheet of paper, plastic or glass. There's a reason we use glass on our windows to shield from the heat in summer and keep it inside during winter :D
Andreas I program the M5Stack over the air. That way it works every time.
Yes I get the sketch on the stack by pressing the on/off button a couple of times when the bootloader part start. After that I use OTA ruclips.net/video/OpFEUbWgiWs/видео.html
I do a lot of OTA, we even have IOTappstory.com as a service for that purpose. But still, to try out some examples it always takes some time.
Lustig: ich hab mir gerade eine 30$ Messpistole gekauft. Super als Kochhilfe und zum Suchen von Kältebrücken.
Das erste Pixel ist am wertvollsten 😊
Dir und Deiner Frau eine ganz schöne Weihnacht!
Ich hab von meiner Frau einen Thermomix mit eingebautem Temperatursensor bekommen (ist vermutlich etwas teurer als deine Lösung). Eine Freundin hat ihr gesagt, dass sie damit ihren Mann zum Kochen gebracht hat ;-) Sie hat immer noich Hoffnungen.
Ebenfalls Frohe Weihnachten und einen guten Rutsch!
Any thoughts on the Walabot? Aliexpress has a $70 Melexis MLX90640?
The $70 M5stick T-Lite Thermal Camera Dev Kit (MLX90640) seems to be an integrated M5Stack solution!
I never had a usage for the Walabot, so I do not know if it is good.
Thank you so much Andreas for doing these. I've been interested in this technology for a long time, but they are just so expensive to try & learn them all. Again with many thanks & Happy Holidays.
Merry Christmas to you, too!
Interesting and yes I suppose disappointing project Andreas. Still not in the hands of the masses just yet. Thank you for all your content this year. Wishing you and Mrs Hacker a lovely Christmas and wonderful new year.
You are welcome. And Merry Christmas, too!
Thank you for taking the time to evaluate these lower cost IR solutions, your video was very informative. Have you checked out the Seek Thermal camera? It costs less than the Flir unit (around US $170 on Amazon), and has higher resolution (206 X 156). They have versions for both Android and IOS phones, and they now have standalone versions. I've had one of the original release units for a few years and it works well for chasing down heat leaks around the house, which was my justification for buying it, and I feel it has paid for itself several times over in just energy savings. My only complaint with it is that I have to remove the protective case from my phone to use it because it gets in the way of the way it plugs directly into the USB port. Thanks again for the post. -Jim-
I used the FLIR device just to show the difference. I have it for a few years now and back then I got the impression that I got the best for the buck (if I remember right, Seek also was a contender). I do not use it often and for sure will not replace it soon.
You should look into the old cat S60 phones as they have a flir camera built in....the mic died on mine years ago but I've still got it to strip out the camera parts for use with a raspberry pi or something one day as I found it pretty useful but honestly I'd love the newest cat phone as they're awesome
Good to know. So far I never looked at those CAT phones...
I still use amg8833, good enough for finding faults in the things i fix from time to time
Cool!
You forgot one kind of intermediate sensors, the spot temperature sensors like the ones used in IR thermometers. They only have 1 pixel, but can detect temperature accurately. For example, the MLX90614.
The topic of the video was a camera and the single pixel just to show the difference. The MLX90614 is maybe a topic for another video...
@@AndreasSpiess Well, yeah, I think the spot temperature sensors should have been there instead of the PIR sensor, which would need calibration to get accurate results. And there are people who made slow, but cheap, thermal cameras with this kind of sensor and two motors, either moving the sensor directly or moving two mirrors (which are just polished aluminium). And this could also be a way to improve the resolution of higher resolution thermal imaging sensors.
Thank you for the ongoing series of great videos. Could you tell us the name of the node editor you are using at 5:16 in the video?
It is node-red and there are a few videos about it on this channel.
If the M5Stack seems to refuse the connection with Arduino as you have shown, just hold the red reset button for at least one second. Then the connection will work. At least, it has worked for me with my gray M5Stack.
Unfortunately I cannot do remote debugging :-(
3D printed case for the AMG8833 and a 2.8" TFT screen:
www.thingiverse.com/thing:2799023
Mounting adapter for the AMG8833 bought from Aliexpress:
www.thingiverse.com/thing:3066479
Code for the ESP8266, which enables you to save image data to SD and create images on your PC:
github.com/wilhelmzeuschner/arduino_thermal_camera_with_sd_and_img_processing
Thank you for the links.
Technically the simple PIR-sensor has two pixels and your explanation is somewhat wrong. It does not compare a reading with any "last" measurement. It looks at two pixels at the same time, and a difference between the two pixels is what triggers it. :)
The two pixels are still used to detect time-variations in the signal, not simply compare the temperature each pixel detects.
Exactly, its output is the differential signal between two series wired but opposing ir detectors. The lens also has a role to play in motion detection. Hint: Mask of half of that IR window with foil tape.
@@noisyaudio it still measures time-variance, i.e. motion. Using two pixels and a lens to distribute the signal on to both pixels increases gain dramatically while rejecting common temperature changes, but it still only detects changes in the signal above a certain frequency. For example, if you stand still, one Pixel will see a higher temperature, but it will still not trigger, unless a fast temperature change, i.e. movement is detected. It's a simple differentiator at the output.
I also looked it up and it seems they use the two pixels to get a two times larger signal. And the lens helps to get two opposite signals with a higher probability. Still, they seem to need time to detect the difference.
The PIR sensor detects changes in background temperature, as well as changes from the scene. In a single element detector, two PIR pixels (one of which is blind) are subtracted from each other, the difference being the energy from the scene. Multiple lenses are used where each lens sees a narrow strip of the scene, with blind gaps between the strips. Moving objects move in and out of the blind gaps, causing temperature changes in the PIR. The PIR material itself takes time to heat and cool. The PIR material acts like an unpolarized nano capacitor - heating or cooling the PIR acts to charge it up one way or the other. The charge itself persists for some time, depending on the design it may be discharged on read, or decay naturally through leakage.
FLIR also sells a sensor which can be used for DIY, I am just not sure how it compares with the others
AFAIK they sell higher end components. But I did not investigate.
@@AndreasSpiess there are more of them (www.flir.com/products/lepton/), this is just one: www.sparkfun.com/products/13233
Saved us time and effort. Good video.
Glad to hear it!
i got a Freetronics IRTemp sensor a few months ago and was thinking about something like this... unfortunatly the IRTemp sensor is only one pixel..its only good for reading surface temps at a spot ratio of 1:1 and has a 1 second response time!
thanks for showing me the way Andreas! Merry Xmas to you and yours :)
Merry Christmas to you, too!
Pretty sure the web page says 1° is normal accuracy for the mlx. Accuracy for extended range is on page 47 of the datasheet
Thank you for the hint. the 1.5 degrees on page 47 is flagged as an "example". I don't know the value of such a number ;-)
People were playing with the IR camera sensor from the Wii remote controllers some years ago to track moving objects. I remember that sensor was very narrow angle (about 20 degree or so) and required I2C to communicate. You still may want to try it.
AFAIK they did not measure temperature and had an IR LED built-in. Maybe an overkill, but they most probably would do the job.
Andreas, is there a presence sensor to detect a person without movement?
what do you think about it?
PIR sensor only responds to movement
just use image/facial recognition via standard color camera..
@@WacKEDmaN yes, you right, but it is very expensive
@@LegantmarESP32 esp-idf has face detection and recognition framework! github.com/espressif/esp-who
If you use a high-enough resolution camera, with motion-detection software, you'll "see" almost anyone who isn't sleeping or meditating: even when just sitting at a computer or watching TV, few people sit _perfectly_ still.
Not something you'd attach to an Arduino or ESP8266, but the odds are good that, if you're doing something that sophisticated, there's a central PC you can network the camera to.
@@rantalbott6963 Raspberry PI can handle 5MP :)
Very informative video about various options. Can I ask, though, what is the largest distance at which MLX (the 110°C) still detects a warm body?
I do not know :-(
Emissivity of 1.0 means the registered temp is at least as high as what is shown. Reducing emissivity value increases the displayed temp.
Thank you for clarification.
@@AndreasSpiess another "trick" to get an accurate reading since emissivity varies widely by material is to put a piece of black 3M electrical tape on the surface being measured. It has an emissivity of almost 1. Then you can compare readings to get emissivity of the material.
Will the MLX90640 work best if I put it as a smart watch?
Or it need to have some distances to work properly?
Also what material for casing so the sensor is not measuring the casing?
Sorry for a lot of question, I really excited to explore this amazing channel!
I am asking what kind of plastic will pass infrared emitted by MLX sensor, like that is used in ordinary PIR ..
"Lenses are 0.015 inch thick and made of a plastic that passes infrared in the wavelength range of 8 to 15 microns which is most sensitive to human body radiation. These are not wide angle lenses.
"
I have no idea. of smart watches. And these sensors are pretty expensive PIRs. But they can be used.
I think the frame rate is an important thing to consider if you would like to measure dynamics of heating/heat flow
You are right. But if you do not see any detail, frame rate is not so important ;-)
Also replace the USB lead. I had to try 5 leads to get a good reliable one and that cost me £12!
The supplied usb cable is just useless.
Also of note: Arduino is no the preferred environment, they want users to use IDF (which I don't understand )
I did not use their cable. And knowing how ESP32 programming works I doubt it will be different with a different programming environment. But others wrote they fixed it in the current design.
@@AndreasSpiess The MK1 Core and MK1 camera both suffer.
The MK2 camera (in case) is more reliable but still hit and miss with leads.
Thanks for spending the money and sharing your experience. Great!
You are welcome!
Good enough for my lil robot. Thanks for show them ...and merry Christmas :)
Merry Christmas, too!
I think these would be perfect for diy robotics
It would at least be a nice additional sensor to add in
@@E4S65 Indeed, for robots doing indoors SAR or thermal inspection these are perfect
Thanks for making this video.
You saved me some time and money.
I will wait a few more years for the higher resolution, higher precision and accuracy, as well as higher frame-rate tech to come down to the sub one hundred dollar consumer range.
Right now the military is kind of hogging all the good IR tech.
Thanks again,
Regards,
Good decision!
Great video! I don't know about these i2c IR sensor arrays, they looks promising.
I think, 32x24 sensor picture can be a little better, if color palette will be auto ir manually adjusted - in video, all soldering iron was just red. I think, sensor should see different temperatures there, but due to palette we see only solid red...
BTW, please try to set programming speed in Arduino IDE to lowest possible (115200?), this helped to me with downloading to board problem...
I tried all sorts of things, also to reduce the speed. Nothing helped, unfortunately.
Seems like it might be more useful to use one of those laser thermometers, and either raster it to build an image, and/or use multiple of them at once to collect more pixels faster.
And instead of the normal back and forth rectangular rastering, use polar-coordinate rastering (like a spirograph or a rhodonea curve) so that the center of vision has the most fidelity, while still having some peripheral vision. With these thermal vision things the center of vision is always the most important.
I do not know the opening angle of those sensors. But they have to be quite small for that purpose. And the reading speed has to be quite fast.
I'm missing the cameras we've had in military, they were really neat! But I guess they also were very costy..
If you refer to night vision cameras: I am not sure if they use the same principle.
@@AndreasSpiess ne, wir hatten in unserem Bataillon Kameras die zur thermalen Aufklärung eingesetzt wurden. Ich vermisse deren Leistung im Punkt Auflösung und FPS für den zivilen Bereich :/
Can a higher quality sensor be used in a DIY build?
I have several FLIR thermal cameras where the IR sensor, camera, board are fine but the screen is broken.
Can the sensors be pulled off the board and repurposed?
I do not know if there are projects with those chips and I do not know if they published datasheets.
Thank you for this thermal camera review.
I was wondering if 2 could be connected by Bluetooth or wifi to a smartphone (in one of those cheap VR headsets) to create a type of night vision goggles. I figure a USB or lightning connection could be prohibitively difficult or expensive.
Maybe it could be dome. You decide if it would be worth the effort.
Seeing the mxl90640 popular now in 2023 as a £70 camera with touch screen. some claiming 320x240 untruthfully, 32x24 pixels. the Lepton is a nicer resolution, which is 320x240.
They probably use the LCD resolution for their claims :-(
Very well thought-out and presented; thank you very much.
Glad it was helpful!
Excellent video with useful feedback for the amateur user (like me !).
Thank you!
Could you sometime do a video on peltier tiles....
So far I have no plans for that.
If you haven't seen it yet this video goes into peltier devices with reasonable depth. ruclips.net/video/YWUhwmmZa7A/видео.html
I probably would mix the rather cheap (compared to FLIR) sensor with a Pi camera module and see, if calibrated correctly, how that performs. A quadcore SoC should also be able to do the heavylifting of imagemanipulation far better.
I do not think you can change the problem of low resolution with your proposals.
Great information... I need to detect water on room surface.....can you suggest me, which sensor will be better for this purpose?
I have no idea :-(
Dear Andreas, I need to localize a ants nest in my caravan walls. So behind a plywood. Do you think that a AMG8833 could help me detecting these little critters?
I do not know if they are warm enough.
Hello. I agree with the fact that it's a bit hard to modify the MLX90640 to display a different range of temperatures but this is only if you are looking in the wrong place. Also, I checked the temperatures with my Raspberry Pi Zero and 3 and they were pretty much spot on so maybe updated the driver? Or the Pi might work better with it?
Either way, below I'll leave the way to modify the MLX90640 to display the temperature range you want.
After copying the library to your Pi, you u need to go to:
/pi/mlx90640-library/examples/src/
and use a C++ editor (Rasbian has Geany) to edit the file you want (using hotspot as an example) Just scroll down to where you'll see:
vmin=5.0
vmax=50.0
Just change these to whatever temperature range you want and save the file.
In terminal, go to the mlx90640-library folder and compile the file you just modified by writing:
sudo make
Then run them with:
sudo ./examples/the_file_you_want.
I
Thank you for your code. I had no problem with the temperatures shown. My problem was more the extremely low resolution of the chip.
Very informative, as usual, but one could argue that a quick view of an operating PCB, whatever you had handy in the lab, would have given a much better idea of whether the less expensive PIR sensors would be useful for finding PCB problems. Since the more capable FLIR sensor is a close call for many people (compared to pointing a $15 IR thermometer gun), chances are the cheaper sensors wouldn't make the cut, but it would still be interesting to see the results...
You are right. Maybe I was a little too frustrated ;-)
Dear Andreas, that problem with M5 esp32 board is often a problem for us makers when working with standalone ESP based systems. Do you have any standalone version that always accept programming?
I have many different ESP32 boards which work fine.
Usefull/interesting... of course. It gives me much more insight on the topic and so I've decided... to wait untill better products show up on the market.
Good decision :-)
You skipped the accuracy section in Flir. What does it mean? Does it mean that surfaces within 3 degrees from each will be same colour?
I never tested the accuracy of the Flir :-( I assume you find it in their specifications.
@@AndreasSpiess it shows in your video +-3 degrees. But I don't understand what they mean. Does it mean sensitivity?
@@solidfuel0 I no more remember every detail 😞
Thank you. It was both useful and interesting
You are welcome!
Thank you for the video. I was considering MLX90640 (110 degree version) for human detection (as an additional sensor for a visible spectrum camera, street conditions), but it looks useless beyond 2 or 3 meters.
This is a disappointment, but still a useful result.
Better know it before...
@@AndreasSpiess Yes, absolutely!
Thanks for the video. You definitely saved me some money.
You are welcome!
You mentioned that we can feel IR with our skin but I think it's not correct when we feel heat by for example radiation of a fire we're actually feeling the heat which is absorbed by the skin
I am only an electronic Engineer. If you are an expert, I assume you are right.
Merry Christmas and thanks for the Videos :)
You are welcome. And Merry Christmas, too
At 2:30 , I can clearly see that the lens of the PIR is transparent to visible light
Why not?
Thank you for your hard work.
You are welcome!
Well I’m a little late to the party but if I may suggest: Turn your phone around 180 degrees. So the camera is where it would “normally” be for a right handed person.
I am left handed ;-)
Thank you for this nice explanation on the cheap thermal options, but it seems if you need a real image then the price goes up with min around 500. Thanks for your useful investment! If the ongoing development is going the go way, let us know! Thanks again
You are welcome!
Any update/ thoughts on this? Is there any move on thermal cameras?
I never checked since then
This is really cool, thank you very much.
I was missing Heimann Sensor thermopile array in this comparison. Maybe you can try one of their arrays, too.
Hi, thanks for your sharing, did you try Flir Lepton? Maybe the result is similar to Flir one?
I only have a Flir one. These instruments are prety expensive :-(
@@AndreasSpiess yes, I am planning to make a diy thermal camera and thinking of using Flir lepton, but I am wondering about the result..
Imo only the FLIR product quality level make it use able...unless you are building a security system..then just a few read dots in a circle or in a line is enough for the software to set the alarm.
Thanks! You do fantastic videos
You are welcome!
Very helpful - thank you for your good work.
You're welcome!
Great video as always. Sadly for now I will stick to my caveman thermal detection method: putting the device close to my lips and moving it around.
Seems the lips have better response time and resolution than the finger, but only really work well for SMD boards :))
you should try this on high voltage circuits
@@D4no00 yea, on one of those stun gun transformers :))
An easier trick is to put some alcohol on the PCB. It'll evaporate where the heat is.
:-))
Great job!! Thanks for the video. Have you tried the OMRON D6T thermal sensor, just for human presence detection ?
No, I do not have them in the lab.
Many thanks!!
It was quite useful!
Glad it helped!
Very nicely done video as always. I appreciate the efficient education you provide. You should check out the new m5stick. Smaller OLED display. Costs around $15 with shipping. Keep up the good work! Thanks!
For the moment I have enough M5 :-( The battery of the M5stick seems to be very, very small.
Can you calibrate the temperature range to read hotter surfaces or do you just need a better sensor?
You can calibrate the values. But you have to read the data sheet for max temperature. I do not remember the value.
Andreas Spiess so just recode the mlx sensor ?
What sort of range could one get out of these sensors? Or even an array of the MLX sensor? Say 4x4 into one single lens?
I think you saw it in the video. A few meters depending on the size of the object.
@@AndreasSpiess I need 150-200m
Excellent video. I was looking into it some time ago but was not ready to shell out the cash for an experiment. You covered all my interest in the topic in under 15 min for free. Can't beat that. Thank you sir.
Thank you! That was the goal of the video.
Thanks. Could you test, if it's ok, if it get see water pipe leaks through tiles and walls (no hot water running, just regular water)?
Thank you.
God bless, Rev. 21:4
Unfortunately I have no leaking pipes here:-(
@@AndreasSpiess Hi thanks. I mean, could it see through the walls and tiles, see the pipes in it (even without the leak, just regular water running through the pipes)
It measures temperatures. That is all.
May be for checking the Heat distribution on a 3D Printer Heat Bed?
This would be possible, I think if you do not need a good resolution.
@@AndreasSpiess Take a look £103 UK pounds heat camera (cheaper still on eBay)
ruclips.net/video/g57r_4OQvqI/видео.html
It uses one of the chips I tested.