ESC stuff
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

testtool.ino 284B

1234567891011121314151617181920
  1. #include <Servo.h>
  2. #define PIN_ESC 5
  3. Servo esc;
  4. void setup() {
  5. Serial.begin(115200);
  6. Serial.setTimeout(10);
  7. esc.attach(PIN_ESC);
  8. }
  9. void loop() {
  10. String s = Serial.readString();
  11. if (s == "")
  12. return;
  13. esc.writeMicroseconds(s.toInt());
  14. Serial.println(s.toInt());
  15. }