A temperature sensore using DHT11 and SIM800L that replies back to you with SMS.
Explore the docs »
Report Bug
·
Request Feature
- Table of Contents
- About The Project
- Getting Started
- Usage
- Roadmap
- Contributing
- License
- Contact
- Acknowledgements
This project is a POC while researching for a bigger project that will be a GPS tracker. The idea is to have a device that will be able to send SMS messages with the current temperature and humidity of the place where it is installed. It can be connected to a solar panel and a battery to be able to work off the grid.
We are using a simple GSM module (SIM800L) and a temperature sensor (DHT11) to get the temperature and humidity of the place where the device is installed.
The simplicity of the SIM800L is that is using RX/TX serial communication and it is small in size that can be easily integrated in a small device.
The DHT11 is a simple temperature sensor that is using a single wire to communicate with the microcontroller. Worth mentioning that the readings are not very accurate. It can be updated with a DHT22 sensor that is more accurate.
- Hardware
- ESP8266
- SIM800L
- DHT11
- USB ( for the ESP8266 )
- Jumper wires
- Breadboard (optional but recommended)
- Software
- Arduino IDE
- Arduino ESP8266 Core
- DHT Sensor Library
Clone the repo
git clone git@github.com:stiliajohny/hardware-sms-temperature-sensor.git
Then open the project in the Arduino IDE make some edits as follows:
- In the SIM800L_DHT.ino file change the phone number to your phone number:
The number needs to follow the international format. For example: +447123456789
const String PHONE = "+447572785067";
- In the SIM800L_DHT.ino file change the serial baud rate to the one that you are using:
The SIM800L module is using 9600 baud rate by default. If you are using a different baud rate you need to change it in the code.
The default baud rate for the ESP8266 is 115200
int SerialBaudRate = 115200;
int sms800BaudRate = 9600;
After uploading the code to the ESP8266 you can connect to the serial port and see the output of the device. Now you need to observe the reception LED on the SIM800L module.
After the device is connected to the cellular network you can send an SMS to the device with the following message:
get temperature
The device will reply back with the current temperature and humidity.
See the open issues for a list of proposed features (and known issues).
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the GPLv3 License. See LICENSE
for more information.
John Stilia - stilia.johny@gmail.com