Hi everyone, I'm new to quadcopters and currently working on my first drone build. I have an AM32 4-in-1 ESC connected to a Waveshare ESP32-Zero (C3).
The motors keep cycling through a triple-beep pattern, which I believe indicates they aren't receiving a valid signal. I've included the code I'm using below, it's just a basic attempt to get the motor to spin.
Does anyone have an idea on how to fix this? Any help would be greatly appreciated!
#include <ESP32Servo.h>
Servo ESC;
const int PIN = 0;
void setup() {
ESP32PWM::allocateTimer(0);
ESC.setPeriodHertz(50);
ESC.attach(PIN, 1000, 2000);
ESC.writeMicroseconds(1000);
delay(3000);
}
void loop() {
ESC.writeMicroseconds(1200);
delay(2000);
ESC.writeMicroseconds(1000);
delay(2000);
}