Disclaimer: The IR sensor for this activity is not medical grade. It cannot serve diagnostic purposes. If at any point you are concerned about your temperature, use a medical thermometer. If you are still concerned, consider consulting your family physician.
What you will need for this activity:
You should already have completed the regular IR Touchless Temp Sensor Activity.
Use the button below to go to that activity if you need to look back at that activity.
Use the button below to go to that activity if you need to look back at that activity.
Wiring the Sensors
Both Sensors connect to the same part of the Arduino Board. Use jumper wires to connect one of them to the breadboard, and then put the other device's pins on the same breadboard rows.
The wiring for the sensors is as follows:
1) Vin to breadboard to 5V on Arduino
2) GND to breadboard to GND on Arduino
3) SCL to breadboard to A5 on Arduino
4) SDA to breadboard to A4 on Arduino
The wiring for the sensors is as follows:
1) Vin to breadboard to 5V on Arduino
2) GND to breadboard to GND on Arduino
3) SCL to breadboard to A5 on Arduino
4) SDA to breadboard to A4 on Arduino
Coding for Two Devices
To code for two devices, you really should have done each one on its own successfully first.
Here are buttons to take you to the independent lessons to check if you have already done them.
Here are buttons to take you to the independent lessons to check if you have already done them.
Compare the Two Old Codes
Here are the two independent codes that we need to combine to get both devices to work.
We need to combine those 3 main parts to make this code work.
I highly recommend loading up one of your old codes and then making a new save file.
This way you are starting with something you know works, and then have less to add to finish this.
I highly recommend loading up one of your old codes and then making a new save file.
This way you are starting with something you know works, and then have less to add to finish this.
An Example of Combining the Code
There are many ways we could combine these two coding examples to make it work
"Calibrating" the sensor
Is your Serial Monitor displaying temperatures that are lower or higher than your actual body's temperature? If so, then you can calibrate the sensor by adding a "correction factor" to your code.
Self Paced add on: Touchless temp sense gun
If you have a 3D printer at home, the items you just learned how to use can be put in a 3D print to make a touchless temp sensor. Here are steps for that. It uses the Arduino Nano (a smaller board) but those are only about 7$.
3D print files: https://www.thingiverse.com/thing:3901662
touchless temp sensor gun lesson: https://www.instructables.com/Arduino-Laser-Infrared-Thermometer/
3D print files: https://www.thingiverse.com/thing:3901662
touchless temp sensor gun lesson: https://www.instructables.com/Arduino-Laser-Infrared-Thermometer/