Code Along - Chapter 20

ESP32: First Sketch

Start Serial at the ESP32 speed of 115200 and blink the LED on GPIO 2.

Estimated time 10 minExercises passed 0 / 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

Not started

ESP32 sketches start Serial at 115200, not 9600. Change the speed, then print Hello ESP32.

Sample output
Hello ESP32
void setup() {
  Serial.begin(9600);        // change 9600 to the ESP32 speed
  // Print: Hello ESP32

}

void loop() {
}

Turn on JavaScript to edit, run and test this code in the browser.