Skip to content

Temperature monitor powered by an ESP32 in Access Point mode with WebSockets communication

Notifications You must be signed in to change notification settings

rlawisch/esp32_websocket_temperature_monitor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ESP32 WebSocket temperature monitor

This project implements a WebSocket server inside a WiFi network provided via ESP32 access point. With the appropriate (and very polite) messages, it will respond with the current temperature readings and turn on/off a green and a red LEDs every 2s (somewhat arbitrary time, but long enough for the DHT readings to work). It was done as a project for the Distributed & Real Time Systems class from Unisinos' Computer Engineering course, as an exercise of defining and implementing a tiny protocol. As per initial definition, the current protocol doesn't have an acknowledgement (ACK) and retry mechanism, making it very fragile. A good exercise would be implementing it accordingly.

Technologies used

Dependencies

There are a few external dependencies to be installed:

  • DHT-22: Open the Arduino IDE's Library Manager (Tools > Manage Libraries...) and install Adafruit Unified Sensor and DHT sensor library libraries
  • AsyncTCP and ESPAsyncWebServer: Download the libraries' ZIP files from Github (AsyncTCP, ESPAsyncWebServer), then add them through Arduino IDE (Sketch > Include Library > Add .ZIP Library...)

Connections diagram

circuit_diagram

Flowcharts

flowchart Flowchart made on the awesome Whimsical tool.

Credits

This project was a stitch from various tutorials I've found. For the ESP32 as a WebSocket server, I was backed up by this tutorial. For the Access Point, this tutorial made the trick. The temperature measurement I've found on this tutorial, and so I must give huge thanks to the Random Nerd Tutorials team.

About

Temperature monitor powered by an ESP32 in Access Point mode with WebSockets communication

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published