Program ESP32-S2 Using Arduino IDE (Unofficial)

Although no official support for ESP32-S2 on Arduino, you still can do it.

Introduction

Espressif, the company behind the extremely popular ESP8266 and ESP32 microcontrollers has just announced their latest chip, ESP32-S2, last year. Compared to the ESP32, S2 have extra I/O, USB-OTG, low power and more secure. As a maker (not a hacker), of course we would like to try it using the most popular microcontroller platform – Arduino. But until now, they still don’t have provide an official support for Arduino IDE. However, you still can try it through GitHub branch called esp32s2. How to do it? Let’s watch the video!

Video

This video shows how to program ESP32-S2 WiFi module using Arduino IDE (unofficial).

Hardware Preparation

This is the list of hardware used in the video.

OR

Sample Program

This is Arduino sample program to control built-in WS2812B RGB LED on Cucumber board. You need to install Adafruit Neopixel library from library manager.

/*
Tutorial: Program ESP32-S2 Using Arduino IDE (Unofficial)
Board: ESP32S2 (Cucumber from Gravitech)
External libraries:
– Adafruit NeoPixel V1.5.0 (Manager)
*/
#include <Adafruit_NeoPixel.h>
#define PIN 18
#define NUMPIXELS 1
Adafruit_NeoPixel pixels(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);
enum {NONE, RED, GREEN, BLUE};
int ledColor = NONE;
void setup()
{
pixels.begin();
}
void loop()
{
switch (ledColor) {
case NONE:
pixels.setPixelColor(0, pixels.Color(0, 0, 0));
pixels.show();
break;
case RED:
pixels.setPixelColor(0, pixels.Color(20, 0, 0));
pixels.show();
break;
case GREEN:
pixels.setPixelColor(0, pixels.Color(0, 20, 0));
pixels.show();
break;
case BLUE:
pixels.setPixelColor(0, pixels.Color(0, 0, 20));
pixels.show();
break;
default:
break;
}
ledColor++;
if (ledColor == 4) {
ledColor = NONE;
}
delay(1000);
}

view raw
ESP32S2Neopixel.ino
hosted with ❤ by GitHub

Thank You

References:

Thanks for reading this tutorial. If you have any technical inquiries, please post at Cytron Technical Forum.

Please be reminded, this tutorial is prepared for you to try and learn.
You are encouraged to improve the code for better application.

1 thought on “Program ESP32-S2 Using Arduino IDE (Unofficial)”

Leave a Comment

Your email address will not be published.

Share this Tutorial

Share on facebook
Share on whatsapp
Share on email
Share on print
Share on twitter
Share on pinterest
Share on facebook
Share on whatsapp
Share on email
Share on print
Share on twitter
Share on pinterest

Latest Tutorial

Send Data to Firebase Using Arduino Uno WiFi Rev2
Simple Alarm System Using Maker Nano
Program Cucumber ESP32-S2 Using CircuitPython
Face Recognition Using OpenCV on Raspberry Pi 400
Turned Your Tablet as a Display for the Raspberry Pi 400
Scroll to Top