Basic implementation of transferring DHT values through UDP connection and Arduino Uno.
Using Arduino Uno to collect DHT sensor values and send them through UDP protocol to local server on my laptop device.
- Python local server
- Arduino IDE
- Wifly
- AndroidJson
- DHT
- socket
- json Note: unlike Arduino libraries, it is enough here to just import the libraries in the code (there is no need to download anything)
After connecting all pieces together, just upload the Arduino code to the Arduino and then run the python code using the command python recieve.py
. You will then watch the data printed in the console.
The DHT sensor collects data, these data are packaged using json generator and send through UDP protocol to the local python server to parse the json object and show the data on console.