SunFounder ESP32 Starter Kit
// Replace the next variables with your SSID/Password combination
const char* ssid = "<SSID>";
const char* password = "<PASSWORD>";
5. Find the next line and modify your unique_identifier. Guarantee that your unique_identifier is truly
unique as any IDs that are identical trying to log in to the same MQTT Broker may result in a login failure.
// Add your MQTT Broker address:
const char* mqtt_server = "mqtt.cheerlights.com";
const char* unique_identifier = "sunfounder-client-sdgvsasdda";
6. After selecting the correct board (ESP32 Dev Module) and port, click the Upload button.
7. At this point, you can see that your RGB strip is displaying a certain color. Place it on your desk and you will
notice that it periodically changes colors. This is because other @CheerLights followers are changing the color
of your lights!
8. Open the Serial Monitor. You will see messages similar to the following:
WiFi connected
IP address:
192.168.18.77
Attempting MQTT connection...connected
Message arrived on topic: cheerlights.
Message: oldlace
Changing color to oldlace
Control global @CheerLights devices
1. Join the and utilize the CheerLights bot to set the color. Simply type /cheerlights in any of the channels on
the CheerLights Discord Server to activate the bot.
2. Follow the instructions provided by the bot to set the color. This will allow you to control CheerLights devices
globally.
188 Chapter 1. For Arduino User