Homeowners and residential communities are increasingly interested in solutions to improve their day-to-day efficiencies and safety. This project gives a solution to this.
This project aims at services such as intelligent street lighting, intelligent trash collection and gas monitoring in a residential area.
Sensors placed at strategic positions will collect the data through the subsystems and send it to the main node through serial communication. These collected data is transferred over the internet to an IoT platform where these collected data is processed and necessary actions will be taken according to the conditions.
|Classification||Part Name||Parts link|
|sensor||MQ5 Gas sensor||https://www.amazon.in/Robo-India-MQ05-Gas-Sensor/dp/B01C1JE4TU|
|sensor||HC-SR04 Ultrasonic Distance Sensor Module||https://www.amazon.in/Electronics-HC-SR04-Ultrasonic-Distance-Sensor/dp/B078J3L8LD/ref=sr_1_5?s=industrial&ie=UTF8&qid=1537248472&sr=1-5&keywords=ultrasonic+sensor|
|sensor||PIR Sensor Hc-Sr501 Motion Sensor||https://www.amazon.in/ePro-Labs-SEN-0021-Sensor-Hc-Sr501/dp/B019U78F8C/ref=sr_1_8?s=industrial&ie=UTF8&qid=1537248649&sr=1-8&keywords=pir+sensor|
|sensor||LDR – Light Dependent Register- Photo Resistor||https://www.amazon.in/Component7-LDR-Dependent-Register-Resistor/dp/B018LJPI76/ref=sr_1_5?s=industrial&ie=UTF8&qid=1537249334&sr=1-5&keywords=ldr+sensors|
Welcome to the demo of Resident community management. Resident community management aims at providing services such as intelligent street lighting, intelligent trash collection and gas monitoring (home) in a residential area.
In this project, all the sensors and actuators are integrated with Wiznet Wizwiki W7500. The collected sensor data is transferred serially (UART) to NodeMCU (ESP82366). The NodeMCU is connected with the Ubidots (IOT Platform). To transmit the data from NodeMCU to Ubidots we are using MQTT protocol. We can use HTTP protocol also but the MQTT protocol is lightly weighted protocol and it has three level of service (QoS).
In intelligent trash collection, we have sensors such as PIR sensor, Ultrasonic sensor and a servo motor. The PIR(Passive Infrared) sensor detects the person approaching the waste bin. When a motion is detected by the PIR sensor then the ultrasonic sensor checks whether the waste bin is full or not by measuring the depth of the waste bin. This reading is sent to the Ubidots (IoT platform) through NodeMCU and is displayed in the Dashboard for an authorized person. If the bin is not full (above threshold value – more space) the lid of the waste bin will be opened by the servo motor for a given time so the person can put the garbage into the bin and then it closes automatically. If the waste bin is full (less space) then the bin won’t open. For authorities to remove the waste from the bin they can open and close the bin manually (Switches).
Every house in the resident community will have the gas sensor to detect the gas leak. The sensor (MQ 5) has a high sensitivity to LPG and natural gas. The gas sensor continuously monitors the house. This reading is sent to the Ubidots (IoT platform) through NodeMCU and is displayed in the authorized person’s Dashboard. If a gas leak is detected (value crosses the threshold) an SMS will be sent to the authorized person and an indicator displays it in the Ubidots dashboard.
The intelligent street lighting consists of LDR which continuously monitors the light intensity and sends it to Ubidots (IoT platform) through NodeMCU and is displayed in the Dashboard for an authorized person. When the light intensity is less than a threshold value the street lights will be switched on automatically. Also, it switches off the light when the light intensity is above the threshold value.
Hardware connection Diagram:
Steps to work on Ubidots IOT development Platform:
- Create an account (https://app.ubidots.com)
- Create device
3. Device created
4. Add Variable
5. Widget creation – Go to Dashboard
6. Widget created
7. Event Creation based on the device response
Work on Node MCU(esp8266):
Download the “ubidots-mqtt-esp” library from:
MQTT library for connecting to Ubidots using MQTT protocol and an ESP8266 chip.
- Go to the Arduino IDE, click on Files -> Preferences and enter http://arduino.esp8266.com/stable/package_esp8266com_index.json into Additional Board Manager URLs field. You can add multiple URLs, separating them with commas
- Open Boards Manager from Tools -> Board menu and install esp8266 platform (and don’t forget to select your ESP8266 board from Tools > Board menu after installation)
- Download this library as .zip
- Now, click on Sketch -> Include Library -> Add .ZIP Library
- Select the ZIP file that you have just downloaded and then “Accept” or “Choose”
- Go to Sketch/Program -> Include Library -> Library Manager and install the PubSubClient library
- Close the Arduino IDE and open it again.
- If you are using windows, please install the appropriate driver for your ESP board (CH340G if you are using a LoLin board or CP2102 if you are using an AMICA board.
Note: add the token from your Ubidots account
- Go to Ubidots account
- Go to API credentials
- Copy the default token and add it in your project
Work on wiznet w7500:
- For the first time, the user should create the online mbed account (https://os.mbed.com/)
- got to the right corner and select the device WIZwiki-w7500p Import the program using the below link https://os.mbed.com/users/Albinarackal/code/SmartAgri-WIZ750SR/
- Compile the code
- save the bin file and load the bin file to the device