Code Along - Chapter 20
ESP32: First Sketch
Start Serial at the ESP32 speed of 115200 and blink the LED on GPIO 2.
ESP32 code on the virtual board
The virtual board is an Uno, not an ESP32, so there is no Wi-Fi here. You practise the code around it. A pot reading is a pretend number in a variable, like int reading = 2048;. The LED on GPIO 2 works the same; the test list calls it pin D2.
Exercise 20.1
Hello at the ESP32 speed
ESP32 sketches start Serial at 115200, not 9600. Change the speed, then print Hello ESP32.
Sample output
Hello ESP32
Exercise 20.2
Blink the LED on GPIO 2
The LED is on GPIO 2. Make it blink: half a second on, half a second off. Add four lines in loop().