DIY Non Contact IR Thermometer V1.0

18,449

151

52

Introduction: DIY Non Contact IR Thermometer V1.0

About: I am a DIY hobbyist by passion and Power Engineer by profession. Most of my works are related to Solar Energy and Arduino. Apart from Electronics I love 3D printing, Woodworking and to make crafts from used …

Currently, we are chasing an invisible monster named Corona Virus ( COVID-19 ) and we are going through the biggest health crisis in our time due to a sharp increase in infection cases. One of the main symptoms of the COVID-19 infected person is an increase in body temperature, in addition to other symptoms such as pain in the body, difficulty in breathing.

It is very essential to monitor continuously the body temperature to detect a corona patient at a very early stage so that proper medication may be taken for fast recovery.

The normal IR thermometer can measure the temperature of a covid patient and also may spread the virus. The main drawback of the handheld thermometer is its performance depends on the operator and the distance to the forehead. To address these problems, a device is made that can be mounted on the wall for fever screening in public areas without an operator. The hardware can measure human body temperature automatically when the distance between the sensor and forehead is adequate.

🔴 My Instagram link: https://www.instagram.com/opengreenenergy/

🔴 My website link: www.opengreenenergy.com

Video Tutorial:

Credit :

The main source of inspiration for this project is from the project iThermowall, I will give full credit to the authors of this project.

I thought this project is very useful in this critical time and I can use my skill to write a DIY guide by including precise instruction and good pictures for illustration so that anyone can recreate it easily.

Supplies

Components Required

1. Arduino Nano ( Amazon )

2. GY-906 Temperature Sensor ( Amazon )

3. OLED Display ( Amazon )

4. Infrared Proximity Sensor ( Amazon )

5. TP4056 Charger Module ( Amazon )

6. 18650 Battery ( Banggood )

7. 18650 Battery Holder ( Amazon )

8. 5 V DC-DC Step-Up Converter ( Amazon )

9. Rocker Switch -15 × 21 mm ( Amazon)

10. 5 mm Green LED ( Amazon )

11. 5 mm RED LED ( Amazon )

12. 2 x 330 Ohm Resistors ( Amazon )

13. Piezo Buzzer ( Amazon )

14. Prototype Board ( Amazon )

15. Header Pins ( Amazon )

16. 22 AWG Wires ( Amazon )

17. Jumper Wires ( Amazon )

Tools Used:

1. Soldering Iron ( Amazon / Banggood )

2. Wire Cutter ( Amazon / Banggood )

3. Wire Stripper ( Amazon / Banggood )

4. 3D Printer ( Amazon / Banggood )

5. Hot Air Blower ( Amazon )

Step 1: How It Works ?

The working principle is very simple, the infrared thermometer sensor MLX90614 reads the human body temperature when the distance ( measured by IR sensor ) between the forehead and the sensor matches a set value. The sensor reading is sent to Arduino for processing and the processed value is displayed on a 0.96" OLED Display.

Apart from OLED display, two LED and one buzzer is used to indicate the output.

1. When the body temperature is normal, Green LED ( LED1 ) will turn on and the buzzer will beep.

2. When the body temperature is higher than 104 degF, Red LED ( LED2 ) will be ON and the buzzer will beep for a longer time.

Step 2: Power Supply

The power required for the entire circuit is provided by two 18650 batteries. The two batteries are connected in parallel for making a higher capacity battery pack to get a longer backup. The battery pack is charged by a TP4056 charger module.

The battery pack voltage is stepped up to 7V by using a boost converter module ( MT3608 ). Then the out from the boost converter is connected to Arduino's Vin pin.

A rocker switch is placed in between the charger module TP4056 output and the boost converter.

Step 3: Prepare the Arduino and Temperature Sensor Board

To keep costs down, the manufacturer often sends you the board and headers pin but expects you to solder them to the board. I have received the Arduino Nano and MLX 90614 sensor without soldering the header pins.

To solder pin headers to a board, first put the pin headers in a breadboard. That's optional, but it's a great way to make sure the pin headers will be perpendicular to the board and parallel to each other, making it easy to insert the board elsewhere. Place the board on top of the headers with the pins going through the holes in the board.

Use a soldering iron with a fine tip since you'll be working with small parts that are close together. The soldering result should be a cone-shaped bit of solder covering both the circular pad and the bottom part of the pin. There should not be any solder connecting two pins together.

Step 4: MLX90614 Infrared Temperature Sensor

The MLX90614 is an infrared thermometer for non-contact temperature measurements capable of measuring temperatures between -70 to 380°C. The sensor uses IR sensitive thermopile detector chip and the signal conditioning ASIC integrated into a single chip. It works based on Stefan-Boltzmann's law which states that all objects emit IR energy and the intensity of this energy will be directly proportional to the temperature of that object. The sensing unit in the sensor measures how much IR energy is emitted by a targeted object and the computational unit converts it into temperature value using a 17-bit in-built ADC and outputs the data through an I2C communication protocol.

The sensor measures both the object temperature and ambient temperature to calibrate the object temperature value. The MLX 90614 sensor can read the ambient temperature in the range of -40 to 125 ˚C (-40 to 257 °F) and object temperature in the range of -70 to 380 ˚C (-94 to 716 °F).

The connection of the infrared thermometer with Arduino is very simple since it uses the I2C communication interface like many other components.
The MLX90614 thermometer has 4 pins: VIN, GND, SCL, and SDA.

The connections should be as follows:

Arduino --> MLX 90614

5V ---> VIN

GND --> GND

A5 ----> SCL

A4 ----> SDA

Step 5: Prepare the Battery Pack

We have to connect the two 18650 batteries in parallel. The battery slot that I have used is a two slot holder with independent terminal for connection. To make the parallel connection, connect two terminals on each side together by using a piece of wire.

First apply small amount of flux to the terminals, then short them by using the wire.

Next solder red extension wire to the positive terminal and black wire to the negative terminal of the battery holder.

Step 6: Infrared Proximity Sensor

Currently, handheld thermometers are quite popular for screening the fever. However, the handheld thermometer performance depends on the operator and the distance to the forehead. To overcome these problems, an Infrared proximity sensor is used to measure the distance between the sensor and the forehead, when the distance is adequate, the temperature reading will be sensed and displayed. In this way, the accuracy of the measurement is improved.

You can set the detection distance from proximity sensor to object by adjusting the potentiometer on the sensor module. Rotating the potentiometer clockwise will increase detection distance and counter-clockwise will reduce the detection distance. I have set this distance to approximately 50 mm.

The connections should be as follows:

Arduino --> IR Sensor
3.3V ---> VCC

GND --> GND

D9 ----> OUT

Step 7: OLED Display

To display the body temperature, a 0.96" OLED display is used. It has 128x64 resolution and uses an I2C bus to communicate with the Arduino. Two pins SCL (A5), SDA (A4) in Arduino Nanno are used for communication.

I am using the Adafruit_SSD1306 library to display the parameters.

First, you have to download the Adafruit_SSD1306. Then install it.

The connections should be as follows:

Arduino --> OLED

5V --->VCC

GND -->GND

A4----> SDA

A5----> SCL

Step 8: LED Indication

Two LEDs are used to indicate whether the body temperature is normal or abnormal. The green LED indicate when the body temperature is normal and RED LED indicates the abnormal condition ( when the temperature is above 104 degF)

The green LED ( LED1 ) is connected to Arduino digital pin D3 and Red LED ( LED2 ) is connected to D5. To limit the current of the led, two 330 Ω resistors are used. Solder the resistor to the positive terminal of LEDs. The longer leg of the LED indicates the positive terminal.

Connect 4 jumper wires to the LEDs as shown above. Here I have to use female-female jumper wires for easier connection.

Step 9: Buzzer for Alert

To provide alerts during the screening of the human body, a piezo buzzer is used. The buzzer has two terminals, the longer one is positive and the shorter leg is negative. The sticker on the new buzzer has also " + " marked to indicate the positive terminal.

You can solder wires to the Buzzer pins or you may use female jumper wires as I have used here.

The connections should be as follows:

Arduino --> Buzzer

D7 --> Positive terminal

GND --> Negative terminal

Step 10: Prepare an Extension Board

Most of the modules and components are connected to Arduino pin 5V and GND. Unfortunately, the Arduino Nano has only one 5V pin and two GND pins, but in reality, we need more such pins for connecting the components. To overcome this challenge, I have prepared an extension board by using a small piece of the prototype board.

Apart from the 5V and GND pins we need two SDA and SCL pins for connecting the MLX 90614 sensor and OLED display.

Here I have use right angle and straight male header pins. You can easily make it by following the above picture. In each row, all the pins are shorted.

Step 11: Make the Circuit

Make the circuit by following the schematic diagram given in the above picture. I have already explained the connection details of each component and module. To make it simpler, I have prepared a breadboard circuit for you.

Step 12: PCB Design

After making the circuit, I realized that the wiring connection is really messy. To make the wiring cleaner and simpler, I have designed a custom PCB for this project. You are free to use my PCB Gerber files.

Thank You NextPCB:

This project is successfully completed because of the help and support from NextPCB. Guys if you have a PCB project, please visit their website and get exciting discounts and coupons.

Only 0$ for 5-10pcs PCB Prototypes:https://www.nextpcb.com/?code=greenenergy

Register and get $100 from NextPCB: https://www.nextpcb.com/register?code=greenenergy...

See more info about PCB Assembly Capabilities: https://www.nextpcb.com/register?code=greenenergy...

Step 13: Software and Libraries

First, download the Arduino sketch and installed all the libraries.

Download and Install the following Libraries:

1. Adafruit-MLX90614-Library: https://github.com/adafruit/Adafruit-MLX90614-Lib...

2. Adafruit_SSD1306 Library: https://github.com/adafruit/Adafruit_SSD1306

3. millisDelay: https://github.com/ansonhe97/millisDelay

Plugin the USB cable into the Arduino Nano with your laptop or desktop PC.

Set the correct board and COM Port number and upload the code into the Arduino.

Step 14: 3D Printed Enclosure

The enclosure has two parts:

1. Front Case

2. Back Case.

You need a support structure for printing the front case. I have printed it in the wrong way. The correct way to print the enclosure is the reverse way as shown above.

I have used my Creality CR-10 printer and 1.75 mm PLA filaments to print the parts.
My settings are:

1. Print Speed: 60 mm/s

2. Layer Height: 0.2mm ( 0.3 also works well)

3. Fill Density: 30%

4. Extruder Temperature: 200 deg C

5. Bed Temp: 65 deg C

As I have printed the front case in the wrong way, most of the mounting standoffs got broken. So I have used hot glue or double-sided tape to mount the parts.

Step 15: Assembling

Now you can install all the components to their respective slots. All the parts are installed on the front case, but the battery holder will be installed in the back case.

I have used hot glue and double-sided tape to mount all the parts.

After installing the parts, close the back case and secure the 4 screws at the corner.

Now our device is ready to use.

Step 16: Mounting and Testing

Before first use, I will suggest charging the device with a micro USB cable. You can use any 5V / 1A charger, it will work for you. The red led on TP4056 indicates batteries are charging, and the blue led indicates fully charged.

Now, switch on the rocker switch, you will notice the OLED display will start with the message " initializing ".

You can test it by placing your hand in front of the sensor, when the distance is adequate, the body temperature will be displayed on the OLED display, LED will turn on and you will also hear a beep sound.

To simulate the high temperature, I have placed the soldering iron tip in front of the sensor, you will notice that the red LED will turn on and hear a long beep sound from the buzzer.

Once it is confirmed that the device is working as per our planning, you may install it in a suitable location. The height of the sensor shall be approximately equal to the height of your forehead from the ground.

If you enjoyed this article, don’t forget to pass it along!
Follow me for more DIY projects and ideas. Thank you !!!

Arduino Contest

This is an entry in the
Arduino Contest

Be the First to Share

    Recommendations

    • Make it Real Student Design Challenge #3

      Make it Real Student Design Challenge #3
    • Arduino Contest

      Arduino Contest
    • Toys & Games Contest

      Toys & Games Contest

    52 Comments

    0
    Acarolinensis
    Acarolinensis

    2 days ago

    Cool project! One concern: where did you get 104°F as a threshold temperature for Covid-19 infection? I'm no medical expert but the general advice I've heard is that a body temperature of 103°F is serious and over 104°F is heading into convulsions and death territory - definitely time to be in a hospital. The go/no go casual Covid-19 temperature screening threshold for most businesses seems to be around 100°F.

    0
    Build_it_Bob
    Build_it_Bob

    5 days ago

    Awesome follow through and design (as always), thanks so much for sharing all your creations!
    Bob D

    0
    huynhkyanhhuy1983
    huynhkyanhhuy1983

    Question 5 days ago

    I have one question. If i want the code display the temperature in Celcius degree, which parts of the code i should change?

    0
    taki2007
    taki2007

    Question 5 days ago

    Why do you step the voltage up to 7V?
    The arduino needs only 5V, which the TP4056 already provides (with over discharge protection) with a stable value, if I'm not mistaken?

    0
    taki2007
    taki2007

    Answer 5 days ago

    (Moreover, the Arduino steps it down to 5V through a linear regulator so it is wasted anyway?)

    0
    paul13Z
    paul13Z

    6 days ago on Step 13

    While this is a good project there is a flaw that will produce false positives.
    The MLX90614 is set to a emissivity of one at the factory. The emissivity of human skin is .95 to .98. If the emissivity of the object tested is lower than the set point of the sensor the temperature reading will be higher. There is a register on the MLX90614 (0x04) which can be used to set the emissivity to the correct value. If the emissivity is set to one (1) than all the readings will be too high. The result could be a serious problem for those individuals. They would waste time and money testing for something that did not exist.

    The other point is the temperature of the human is not a reliable method to detect if someone has Covid. Multiple studies thorough out last year conducted by NIH and others have shown that out of 5000 people that were positive for Covid less than 20% presented a temperature increase.

    Paul M PHD, MD

    0
    huynhkyanhhuy1983
    huynhkyanhhuy1983

    6 days ago

    If i don’t use the PCB. Can i made This project following your circuit?thanks

    1
    lathajay
    lathajay

    7 days ago

    If you could post total cost of this project, it would be helpfull.

    0
    ArturZ9
    ArturZ9

    Reply 7 days ago

    The cost mostly depends on where are you sourcing components from.
    My local DIY store charges twice (at least) the Amazon price and the Amazon is often twice as expensive as aliexpress.com
    Plus 3d printed shell and PCB can vary in price widely.
    The electronics for this project can be obtained for under 20 bucks easily if you are ready to wait for shipment coming from overseas.

    0
    lathajay
    lathajay

    Reply 6 days ago

    Thanks for the prompt reply.

    0
    morleidre
    morleidre

    6 days ago

    Fantastic instructions. If only everyone was so clear in their instructions. Please keep posting.

    0
    diego.gargamel
    diego.gargamel

    7 days ago on Step 16

    Hola buen dia, muy lindo proyecto, le solicito permiso para implementarlo en una escuela de chicos especiales, con fines educativos, desde ya muchas gracias y saludos cordiales

    0
    opengreenenergy
    opengreenenergy

    Reply 6 days ago

    Hi,
    You can use it for education. Please share some pictures, when you will make it.

    0
    diego.gargamel
    diego.gargamel

    Reply 6 days ago

    OHH muchas gracias, muchas gracias, presentare este proyecto en la escuela donde trabajo, si me lo aceptan lo haremos, construire este proyecto y le estare enviando las fotos, muchas gracias, un gusto que tenga lindo dia

    0
    denniscj7
    denniscj7

    7 days ago

    I don't see the 5-10k pullup resistors for the I2C lines.

    0
    ArturZ9
    ArturZ9

    Reply 6 days ago

    These are usually included on a breakout boards of I2C components you are using.
    Indeed would be good to add them where bare components are used.

    0
    lbeck37
    lbeck37

    7 days ago

    Super cool! I've been working with ESP32's using the Arduino platform, and since the ESP32 has WiFi and some low power sleep and hibernate modes, I wonder if it could be used for giving your battery powered device WiFi so it could push data to the internet.
    Thank you very much for posting this build!

    0
    ArturZ9
    ArturZ9

    Reply 7 days ago

    That is exactly what I am doing at the moment: the battery powered remote temperature sensor based on MLX90615 and ESP32.
    I have all the parts tested in separate sketches, the integration is what takes most of the time, as usual :)
    What I am doing is using 2 cell lipo, resistor based voltage divides to measure the individual cell voltages, the power regulator built into the ESP32 prototyping board and SD card for data logging and storing the configuration.
    I guess, I should make an instructable article once I am ready with the project, but not sure how long does it take :)

    0
    lbeck37
    lbeck37

    Reply 7 days ago

    When you get that working, I would love to see your code. I've been fooling around using Firebase to communicate between an ESP8266 (or better, an ESP32) and an Android cellphone app. The ESP writes data to, and reads commands from the database. The Android app reads that data or writes commands to the ESP. I've got the code for the cell phone going, but the code I had working previously on the ESP8266 stopped working (library changes, I think) and I haven't completed the full loop, and other projects came up. It seems like it would be a neat way to communicate between objects w/o having to have a lot of coupling (knowing about the other) between them and easily supporting many ESP devices and phones at the same time.