Under block settings,
Change Block Title to Button Value
Change Gauge Min Value to 0, the
button's state when it's off
Change Gauge Max Value to 1, the button's
state when it's on
Click Create block
Your dashboard should look like the following:
Code Usage
For this example, you will need to open theadafruitio_26_led_btnexample included
with theAdafruit IO Arduinolibrary. In the Arduino IDE, navigate to File -> Examples ->
Adafruit IO Arduino -> adafruitio_26_led_btn.
Before uploading this code to the ESP32-S2/S3, you'll need to add your network and
Adafruit IO credentials. Click on the config.h tab in the sketch.
Obtain your Adafruit IO Credentials from navigating to io.adafruit.com and clicking My
Key(). Copy and paste these credentials next to IO_USERNAME and IO_KEY .
©Adafruit Industries Page 228 of 263