//neo pixel interfacing
#include <Adafruit_NeoPixel.h>
#define NUMPIXLES 1
#define PIN_NEOPIXEL 4
Adafruit_NeoPixel pixels(NUMPIXLES,PIN_NEOPIXEL,NEO_GRB + NEO_KHZ800);
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
pixels.begin();
pixels.setBrightness(200);
Serial.println("Hello, ESP32!");
}
void loop() {
pixels.fill(0xFF0000);functionR();//RED
pixels.fill(0x00FF00);functionR();//GREEN
pixels.fill(0x0000FF);functionR();//BLUE
pixels.fill(0x000000);functionR();//WHITE
pixels.fill(0xFFC0CB);functionR();//PINK
// put your main code here, to run repeatedly:
delay(10); // this speeds up the simulation
}
void functionR () {
pixels.show();
delay(500);
}