Introduction: Temperature Sensor Output Values on Android Smartphone

This is project of temperature sensor, value of temperature will be transmitted on Android smartphone via Bluetooth and displayed on its screen, with RemoteXY library used. Such a temperature sensor can be placed in an inaccessible location, such as behind the window, in the refrigerator.

Step 1: Electrical Part

For making of the electrical part of the device, you need any Arduino board, the thermistor 1K, resistor 1K. Above image is a diagram of connections of all structural elements. The thermistor circuit is included in the voltage divider, a second shoulder which is constant resistance. The midpoint of the voltage divider we have connected to an analog input of the Arduino with the number A5.

Step 2: Calibration

The development of the program we will start with calibration of the sensor. Calibration we perform two-point, and to do this we need the reference temperature. This, subsequently, to calculate the current temperature will use linear interpolation.

For calibration, we need to determine what value input Arduino ADC with temperature sensor that we have chosen the reference. Use Serial and port monitor, to transmit the ADC value on the computer that we could see what it is when our reference temperatures. To do this we need the following simple Arduino sketch.

void setup()   {    
	Serial.begin(9600);    
}

void loop()   {
	int sensorValue = analogRead(A5);
	Serial.println(sensorValue);   
	delay(1);  
}

For example, we obtained the following calibration values:

T = 25,0 ° C ADC = 580

T = 36,6 ° C ADC = 514

Step 3: RemoteXY Library

Go to online editor RemoteXY and create the management interface. It consists of a text field, through which is transmitted the measured temperature, and a text label. See above image.

Selected in the RemoteXY project settings of the target platform Arduino (SoftwareSerial), library version and the generated source code of our interface. Don't forget to download RemoteXY library and import it to the Arduino IDE (Sketch/Import library/Add library...).

For transmit the value of temperature on the smartphone screen we need to get the current value of the ADC, to get the value of the current temperature using a linear interpolation on the two known points, convert the received value into a string and write it in the field text_1 patterns RemoteXY.

Full version of result sketch for Arduino IDE is attached. In this code, you must change the defined values SENS_1_VAL, SENS_1_TMP, SENS_2_VAL, SENS_2_TMP, substituting them your that you got when you measured values for calibration.

Step 4: Download Android App

Download to your smartphone or tablet RemoteXY app. And can control the temperature when you are away from your sensor, using Bluetooth.