Hi everyone,
I use a joystick to control brushless DC through an ESC . I use ESC-12A, Brushless DC motor 1104 -4300kV, arduino Nano. I have calibrated the brushless DC motor to control it through ESC with max and min PWM, 1000us and 2000us. When I push up the joystick slowly to increase the speed of motor, it works normally and the motor can run with max and min speed. But sometimes when I control the joystick too fast or too slow, the motor stops working and I hear three beeps from ESC. So this can cause a big problem that suddenly stop the motor if I do not control the joystick properly . Anyone can suggest any solution to solve this problem. The code posted below used to control brushless DC motor :
#include <Servo.h>
Servo ESC; // create servo object to control the ESC
int potValue; // value from the analog pin
void setup() {
Serial.begin(9600);
ESC.attach(3,1000,2000); // (pin, min pulse width, max pulse width in microseconds)
}
void loop() {
int potValue=analogRead(A0);
potValue=map(potValue,550,1023,0,180);
ESC.write(potValue); // Send the signal to the ESC
Serial.println(potValue);
}
I use pin 3 of arduino nano to generate PWM, the power supplied to ESC is from a power adapter (5V-2A).
Thank so much to help me solve out this problem.
I use a joystick to control brushless DC through an ESC . I use ESC-12A, Brushless DC motor 1104 -4300kV, arduino Nano. I have calibrated the brushless DC motor to control it through ESC with max and min PWM, 1000us and 2000us. When I push up the joystick slowly to increase the speed of motor, it works normally and the motor can run with max and min speed. But sometimes when I control the joystick too fast or too slow, the motor stops working and I hear three beeps from ESC. So this can cause a big problem that suddenly stop the motor if I do not control the joystick properly . Anyone can suggest any solution to solve this problem. The code posted below used to control brushless DC motor :
#include <Servo.h>
Servo ESC; // create servo object to control the ESC
int potValue; // value from the analog pin
void setup() {
Serial.begin(9600);
ESC.attach(3,1000,2000); // (pin, min pulse width, max pulse width in microseconds)
}
void loop() {
int potValue=analogRead(A0);
potValue=map(potValue,550,1023,0,180);
ESC.write(potValue); // Send the signal to the ESC
Serial.println(potValue);
}
I use pin 3 of arduino nano to generate PWM, the power supplied to ESC is from a power adapter (5V-2A).
Thank so much to help me solve out this problem.