Step 5: Programming and Final Assembly

Inspired by the Public Laboratory and having just finished a round of college applications, I decided to experiment with thermal imaging on the cheap.

Thermal cameras are expensive. Even at low resolutions, it is not uncommon for a decent thermal camera to cost over $10,000. However, for only $20, you can buy an infrared thermometer that reads the average temperature over a small area. If we could turn that single area into a color and use a long exposure photography to "paint" the scene with that color, we could create something very similar to a proper thermal image.

This is not a new idea. The Public Laboratory has come out with a design for something that does this, but I have yet to see one make its way off of a breadboard. I decided to take the project to the next level and make a real, bona fide thermal flashlight. Here's how I did it.

Step 1: Materials

8 RGB LEDsNote: Previously, and in the images in this instructable, you will see me using common cathode (negative) LEDs. To make your life easier with the transistors, use common anode LEDs like the ones now linked.

I love this instructable, but it hits one pet peeve near the end - please don't put whole Arduino boards into a small project that doesn't need to be interfaced with a PC, or encourage other people to do so. It's a wasteful abuse of the board's functions. Development boards are meant for programming microcontrollers, such as the ATMega on that Arduino board, and prototyping circuits controlled by it. <br>You should get a single ATMega for that function (it'll probably just cost you a couple of dollars over there), use the Arduino to program it, then take it out and connect it to your perfboard. <br> <br>See http://arduino.cc/en/Tutorial/ArduinoToBreadboard for an example of how to do this, and http://arduino.cc/en/Hacking/PinMapping168 for the corresponding uC pins to connect to.

<p>can i ask something?<br>you mentiond that atmega168 is recommend, can i use atmega32u4?<br>https://www.arduino.cc/en/Products/Compare</p>

I completely agree! In fact, I had a standalone ATMega328 on some perfboard ready to embed in the project; I just didn't have a 3.3v regulator on hand for the IR sensor and didn't feel like running to the store in the middle of the project. But 99% I completely agree with you.

<strong>Congrats! You are putting the power of engineering into the hands of hobbyists.&nbsp; </strong><br> (I still need to learn how to make a dedicated processor and am looking forward to learning how to make this with the ATMega chip previously mentioned.)

go to www.thermal.com for thermal cameras for around $200. They connect to smart phones with a .32 megapixel image.

this is really nice project ,i am starting to collect the material to make this. I would like to ask if i could use<a href="http://www.google.gr/imgres?um=1&hl=el&tbo=d&biw=1301&bih=778&tbm=isch&tbnid=Tb_9nwbo5kVRjM:&imgrefurl=http://www.eurocosm.com/Application/Products/solar-powered/solar-panel-lighting-GB.asp&docid=0p0Q_-qc9kjftM&imgurl=http://www.eurocosm.com/Application/Images/solar-cells/12V-movement-sensor-lg.jpg&w=800&h=698&ei=vE_zUOrCPMel0AXMg4DYCw&zoom=1&iact=rc&dur=369&sig=118251334608778532035&page=1&tbnh=137&tbnw=150&start=0&ndsp=32&ved=1t:429,r:0,s:0,i:78&tx=71&ty=56" rel="nofollow"> this</a> or <a href="http://www.google.gr/imgres?um=1&hl=el&tbo=d&biw=1301&bih=778&tbm=isch&tbnid=6G9EgvRxWYYAGM:&imgrefurl=http://www.broadenedhorizons.com/talksafe-motion-sensor&docid=nFzJ4BdwWywY4M&imgurl=http://www.broadenedhorizons.com/media/catalog/product/cache/1/image/800x800/5e06319eda06f020e43594a9c230972d/t/a/talksafe_motion_sensor_434/TalkSafe-Motion-Sensor-31.jpg&w=800&h=800&ei=vE_zUOrCPMel0AXMg4DYCw&zoom=1&iact=rc&dur=363&sig=118251334608778532035&page=3&tbnh=135&tbnw=134&start=73&ndsp=39&ved=1t:429,r:80,s:0,i:323&tx=62&ty=52" rel="nofollow">this </a>instead of the thermal sensor because i have some sensor movement from some alarm control system .

Awesome!

This looks a great project, but can I just check something? You aren't trying to drive 8 LEDs in parallel directly off your Arduino are you? I don't see any transistors listed in your BoM but since an LED typically draws up to 20mA (per colour) and your Ardu' can source up to 40mA per pin max, you can't drive more than two off a pin without either sacrificing brightness or burning up your controller. <br> <br>For 8 LEDs, you want something that can drive at least 8 x 20 = 160 mA per colour so a standard 2N3904 (200mA) per channel should be fine. My guess is that it will be much brighter using these because the Arduino is probably limiting your current at the moment. <br> <br>Hope I'm not just being dense and missing something in the write-up! <br> <br>Fab' project BTW. <br> <br>Ugi.

Wow - you've caught me making the most n00bish mistake I've made in a while! You're totally right. I actually calculated the necessary current for the LEDs a while ago, but I thought that the Arduino could handle much, much more than 40mA. I'm updating the instructable to use three transistors. Thanks! Especially embarrassing since I'm designing a standalone PCB for this project...

Glad to help - and good to catch that before the PCB goes to the fab' shop! <br>Ugi

What is the size of the 'cone of vision' of that sensor? ie...do you have to put the flashlight within 1 foot of a wall you want to paint with light, or can you stand further away and it will still work? Thank you for posting this!

SUPER FREAKIN AWESOME! it looks like your getting a bit of distortion. Have u thought of polishing the LEDs flat?

Undoubtedly a great idea and instructable. <br>However, it appears the people that already &quot;know about Thermal measurement&quot; are the ones jumping up and down in joy. <br>For the rest of us,,,,, well,,,,, after spending some time investigating now I understand the theory and purpose. <br>So, question #1: do I also need a camera? which type of film? <br>question #2: does this work if I point it to my house at night and see the thermal situation? or is it too large an object for this device? <br>As somebody else suggested, you need to explain the theory and purpose, the construction (you did), and the practical application or usage of your &lsquo;able. <br>Otherwise it is like &ldquo;preaching to the choir&rdquo;, everybody else may be left out&hellip;. <br>

Hi there! I talk about the theory a bit in the intro step. There is no special camera or type of film you need, as long as it has a long shutter speed mode (around 25-30 seconds is usually ideal). As for your second question, the sensor has a cone of vision that reads the average temperature inside the cone. The sensor could read the average temperature of your house, but the LEDs would not be bright enough to &quot;paint&quot; the whole thing at once (you would have to do it piece by piece). It doesn't seem like many people feel &quot;left out&quot; -- just look at the other comments!

Thanks for your reply. <br>could anyone describe, if you have done it, the experience in doing a full external house thermal study? That would be of great help and enticement. <br>If you could document it with some pics or video, great.

This is supercool! Next, sync it up with the bulb setting on your camera to take pictures with the /perfect/ amount of exposure time!

Ooh that's a really good idea.

I love this! It would be so cool to take several of the and form a hanging ball lamp for a party! The changing colors according to temperature plus several of them hanging outside would look awesome!

Awesome! When I find time I want to make one of these bad boys. Nice job!

Wow stunning, very smart!

Love it! This is probably the most useful thing I've found on this website. Thanks so much for posting this! Can't wait to make it!

Thanks! I really appreciate that.

Black and Decker has sold essentially the same device for $49 since 2008: <br> <br>http://www.blackanddecker.com/power-tools/TLD100.aspx#

Everyone keeps posting this, but in reality they are very different. <br> <br>The thermal flashlight produces a gradation of colors. The Black and Decker device is either red or blue. If you look at the main image of this post, it would be impossible to reproduce with the Black and Decker device -- there are simply far too many colors. The B&amp;D device also has a much more narrow beam.

How about using a laser temperature sensor. That'd make the color of light correspond to the temperature of what they illuminate

Great 'ible! <br>For years I was thinking of doing something similar - but using an X-Y stepper controlled carrier that would have a an MLX90614 mounted in a tube, staring forward, and build an IR image by raster scanning, but this is a lot simpler. <br>If someone can find a good source of IR-transparent Fresnel lenses, you could greatly increase the resolution.. <br>Again, Great project and nice description. <br>

Excellent adaption! <br>Great Job! I will definitely make one!

Truly stunning... Brillant project.

I have to say, the pictures produced by your design are way better quality than any of the ones on Public Laboratory's site. Nice work. It would be helpful if you could preface this instructable with a little theory of operation, for those who are unfamiliar with the process of taking a long exposure light painted thermal image.

I'm hoping to build one of these next weekend. I've got some wicked cold spots in my house that I'd like to fix. I was looking at the other variants of the thermopile sensor on DigiKey and see that there are some (more expensive) ones that have a narrower field of view. Does the flashlight cast a very wide footprint of light? I'm thinking that with the more focused sensor and a more focused light you could get higher resolution images.

Any chance of uploading a video of this working?

Don't think you'll have any problems with those College apps! Awesome job.

Excellent instructable! I have often wondered about trying the TPA82 8x1 thermopile array sensor and making an RGB LED thermal persistence-of-vision wand.

A-m-a-z-i-n-g! It took me a while to understand the concept but by the fifth step I got it and it's soooo great! Great for finding where the cold is creeping in from!

This is awesome. You should make more of these.

nyc work

What a cool project! :) <br>I like the simplicity of it: Just point at a thing and see the color of illumination to determine the temperature. Sweet! <br> <br>Also an idea here: If you add a paper-tube on the sensor, it gets a more narrow field of view and you can pinpoint it better. <br>Add a laser-dot or laser-cross (4$ @ http://dx.com/p/red-laser-module-focused-cross-3-5v-4-5v-16mm-5mw-5942) and you can even point the things you want to measure. However, be sure you dial the power down on the laser...

How do you operate it? Point it as stuff and if it's cold the color is blue and if it is hot the color is red, that kind of thing?

Was this on some magazine or something? I feel like I've seen it before.