Home | pfodApps/pfodDevices | WebStringTemplates | Java/J2EE | Unix | Torches | Superannuation | | About Us
 

Forward Logo (image)      

pfodApp controlled Portable IR Temperature Meter
Android/Arduino based InfarRed(IR) Temperature Meter

by Matthew Ford 16th August 2016 (original 9th September 2013)
© Forward Computing and Control Pty. Ltd. NSW Australia
All rights reserved.

Data Logging, Portable, Arduino based IR Temperature Meter
controlled from your Andriod
TM mobile using pfodApp.
NO Android Programming required.

Introduction

These pages describes projects based on freetronics IR Temperature module which can measure temperatures in the range -33 to 220°C (-27 to 428°F) with readings at more then 1 per second.

Unlike other IR temperature modules the freetronics IR Temperature module comes complete with a metal reflector 'lens' that provides a 53deg measurement angle. I have not found non-Australian supplier of this module but fortunately freetronics has an overseas shipping option.

The IRTemp Arduino Projects

IRTemp Meter Terminal – The projects described here start with a simple computer based IR Temperature meter that just logs the readings to a terminal program on your computer.

The next two stages of this project add Bluetooth to connect to an Android mobile. You can make these units portable by adding a 9V battery as described here.
pfodApp IRTemp Meter (Android Bluetooth) – Extends the IRTemp Meter Terminal by adding a bluetooth module to display and save the IR temperature data on your Android mobile using pfodApp.
No Android programming required.
pfodApp IRTemp Meter with menus – The next stage add menus to select between Fahrenheit and Centigrade and to display an averaged reading. A sub-menu lets you select the number of reading to be averaged.
No Android programming required.

The final stage is to transfer the code and the IR Sensor to a FioV3 board which can be powered from a USB rechargeable battery.
pfodApp Portable IRTemp Meter – Finally small a fully portable version is described. This is battery powered (USB rechargeable) and uses a FioV3 board and is controlled from your Android mobile either by bluetooth or over the internet via wifi. The wifi connection has the option of adding 128 bit security to protect against someone else taking control of your IR module. (Under Construction)

IRTemp Meter Terminal.

The first project consists on an Uno Arduino board, a protoype shield and the IR Temperature Sensor. See the IRTempMeterTerminal parts list for details.

Mounting the IRTemp Sensor.

Half inch internal diameter clear plastic tubing pushed over the sensor makes a suitable mounting. (Note: Do the wiring first, the tubing does not come off once pushed on.)

(click for full size image)

For the sensor wires, 26 AWG Teflon insulated wires provides a very tough and heat resistant connection. (See the IRTempMeterTerminal parts list for a source of Teflon wire.) A nylon cord attached to the plastic tubing, provides strain relief. Teflon insulated wire is very hard to strip without cutting the strands of wires. The recommended method is to use a wire stripper, like the one listed in the parts list and close the wire stripper on the wire then open and remove the wire stripper and pull the cut insulation off by hand. Using the wire stripper to pull off the insulation tends to cut the wire.

Wiring the IRTemp Sensor

The IR Temperature Sensor wiring is straight forward. There are 5 wires that need to be connected. (see IRTEMP Infra-Red Temperature Sensor Quickstart Guide)

V (VCC) connected to Arduino 5V.
G (GND) connected to Arduino GND.
D (Data) connected to Arduino digital pin D2.
C (Clock) connected to Arduino digital pin D3.
A (Acquire) connected to Arduino digital pin D4.

The photo below shows the prototype board wired to the connectors.

(click for full size image)

The IRTemp Terminal Code

freetronics provides a sample Arduino library for this IR Temperature Sensor, but their library has a major problem. It makes the Arduino micro-processor spend almost all its processing time in a tight loop waiting for the sensor to return a reading. A re-written library is available here that avoids this problem. This revised library leaves the micro free to handle other tasks such as communication to and from your mobile.

Download the pfodIRTemp.zip file and and unzip it to your Arduino library directory. All the sketches for the projects described here are included as examples.
Open the Arduino IDE and choose File → Examples → pfodIRTemp → UnoIRTempTerminal.

   #include "pfodIRTemp.h" 
   pfodIRTemp irTemp;  // construct class to handle sensor
   
   bool fahrenheit = false; // set to true for Farinheit instead of Celsius
   void setup() {
     Serial.begin(9600);
   }
   
   void loop() {
     irTemp.triggerSensor();
     int reading = irTemp.getIRTemperature();
     if (reading != pfodIRTemp::NO_DATA) {  // have a reading
       Serial.print(millis()/1000.0); // output secs since restart
       Serial.print(F(",Sec,"));  // csv comma separator
       if (reading <  pfodIRTemp::NO_DATA) {
          Serial.println(F(" ,Invalid Reading"));
       } else {
          if (fahrenheit) {
            Serial.print(irTemp.convertToFahrenheit(reading)); 
            Serial.println(F(",F")); 
          } else {  
            Serial.print(irTemp.convertToCelsius(reading));
            Serial.println(F(",C"));
          }  
       }
     }  
   } 

This is the complete sketch. If you want your readings in Fahrenheit then edit it to
bool fahrenheit = true;

Running the IRTemp Terminal

Compile and upload the sketch to your Uno board. Then open the Arduino SerialMonitor to see the seconds since restart and temperature readings. To save these readings to a file, close the Arduino SerialMonitor and open a Terminal program that has a log file option, i.e. TeraTerm for Windows or CoolTermMac for Mac, and save the data to a log file.


The readings are in CSV comma delimited format so they are easily loaded into a spreadsheet for manipulation and plotting.

The next stage in the project, pfodApp IRTemp Meter (Android Bluetooth), is to add a Bluetooth module to display and save the IR temperature data on your Android mobile using pfodApp. No Android programming required.



AndroidTM is a trademark of Google Inc. For use of the Arduino name see http://arduino.cc/en/Main/FAQ


The General Purpose Android/Arduino Control App.
pfodDevice™ and pfodApp™ are trade marks of Forward Computing and Control Pty. Ltd.


Forward home page link (image)

Contact Forward Computing and Control by
©Copyright 1996-2020 Forward Computing and Control Pty. Ltd. ACN 003 669 994