the setup = setup{} (in arduino C)
transmitter (cant calibrate with a joystick)( the motor has to keep spinning at the same speed)
programming mode of the ESC .
#include <Servo.h>
#define MAX_SIGNAL 2000 #define MIN_SIGNAL 700
Servo myServo,ondermotor,achtermotor; // create a servo object
int angle;
int Servoo = 3;
int Achter = 4;
int ch1; //servo op ch1
int ch2=8;
int led = 13;
int kracht = 160; // regelen wanneer de hovercraft gebouwt is
int snelheid;
void setup() {
myServo.attach(10);// servo op pwm10
ondermotor.attach(11);// ondermotor op pwm1
achtermotor.attach(12);
pinMode(ch1, INPUT); // Set our input and output pins as such
pinMode(ch2, INPUT); // Set our input and output pins as such
ondermotor.writeMicroseconds(MAX_SIGNAL);
delay(2000);
ondermotor.writeMicroseconds(MIN_SIGNAL);
Serial.begin(9600); //initialise serial
}
Serial.print("Channel 1:"); // Printing the value of
Serial.print(ch1); // each channel
Serial.print("\t");
Serial.print("Channel 2:"); // Printing the value of
Serial.print(ch2); // each channel
Serial.print("\t");
//Degree 0............90.............180 ,Speed -%100...........%0............+%100 (- and + shows the direction of motor)
How about the servo's power supply? How is this connected?
As a double check you could add an led blink with a delay to check it is definitely the setup routine it returns to not a problem with the servo algorithm.