It's an android Application to measure Temperature and Humidity of room and give you real time updates
- This android application works on IoT
- We have deployed our hardware on NodeMCu. We are detecting Temperatute and Humidity data from DHT11 sensor.
- then these values are parced into JSON Array.
- Host a webserver at port 80 from nodemcu
- Print JSON array to webserver. You can find the ESP32 application espAndroid2.ino
- At android part we are reading the JSON array from web server
- deserialize JSON Array to get useful values
- refresh it
- You can find the apk in repo IoTemperature
- connect to following url:
url =new URL("http://192.168.1.102/Feed");
- open the url connection using
HttpUrlConnection:
JSONObject jsonObject = new JSONObject(s);
JSONArray jsonArray = jsonObject.getJSONArray("temp");
Our JSON contains two arrays temp store temperature values and humid store humidity values:
{
"device": "NodeMcu-12E",
"sensorType": "DHT11",
"temp": [
"29.0"
],
"humid": [
"80.0"
]
}
