Example Code for Arduino - Getting Started

This guide helps first-time users get started with the ESP32 development board, covering Arduino IDE setup, board configuration, and running a basic LED blink example.

Tutorial - First Time Use

Arduino IDE Configuration

When you use the ESP32 for the first time, you need to know the following steps:

  1. Add the ESP32 development board in Arduino IDE (How to add the ESP32 board to Arduino IDE?)
  2. Select the development board and serial port
  3. Burn the program

Select Development Board

  1. Click Tools->Board, select "ESP32S3 Dev Module".

    set board

  2. The development board needs to be set before burning the code:

  • USB CDC On Boot:
    • Enabled: Print serial port data through the USB interface
    • Disabled: Print serial port data through TX and RX
  • Partition Scheme: Disk partitioning scheme. Please select the appropriate storage space according to the Flash of the development board.
  • Port: Development board port (Just make sure the COM number is correct, which has nothing to do with the subsequent chip model.)

Select Development Board

LED Blinking

  • Copy the code into the window and click "Upload" to upload the code.
int led = 3;
void setup() {
  pinMode(led,OUTPUT);
}

void loop() {
  digitalWrite(led,HIGH);
  delay(1000);
  digitalWrite(led,LOW);
  delay(1000);
}

LED Blinking

  • Wait for the burning to complete, and you can see the on-board LED light start to flash.
    - If the LED light does not flash, reset the development board.
    - If the burning fails, please check Frequently Asked Questions.

LED Blinking

Was this article helpful?

TOP