Requirements
- Publish a message from ESP32
- Subscribe a topic
Software
Download MQTT Client Opensource Code
Clone source code from https://github.com/knolleary/pubsubclient.git.
Copy PubSubClient.cpp and PubSubClient.h from the original src/ to your ESP32 project’s src/.
Program Yourself Code
1 |
|
Test
If you can’t open Youtube, Pls click this link.