version 1.1

This commit is contained in:
cally22
2023-07-09 20:04:44 +02:00
parent c55b7fc4ed
commit 2547e14592
7 changed files with 42 additions and 40 deletions
+9 -9
View File
@@ -29,10 +29,10 @@ void setup() {
}
// set drone motorPins
drone.setPinESC(6, MotorPosition::FR);
drone.setPinESC(7, MotorPosition::FL);
drone.setPinESC(5, MotorPosition::BR);
drone.setPinESC(8, MotorPosition::BL);
drone.setPinESC(6, MotorPosition::FR, 70); // 1080
drone.setPinESC(7, MotorPosition::FL, 120); // 1130
drone.setPinESC(5, MotorPosition::BR, 30); // 1040
drone.setPinESC(8, MotorPosition::BL, 190); // 1200
lastReceivedMessage = millis();
@@ -93,7 +93,7 @@ void loop() {
drone.update();
// drone.update();
delay(10);
// delay(1000);
@@ -109,10 +109,10 @@ void manualMotorSpeed() {
}
}
if (val < MOTOR().minSpeed)
val = MOTOR().minSpeed;
else if (val > MOTOR().maxSpeed)
val = MOTOR().maxSpeed;
// if (val < MOTOR().getMinSpeed())
// val = MOTOR().getMinSpeed();
// else if (val > MOTOR().getMaxSpeed())
// val = MOTOR().getMaxSpeed();
if ((millis() - startTime) >= delayTime && gotSerialData == true) {
drone.setSpeed(val, MotorPosition::FR);