Skip to content

Commit ba8f3ea

Browse files
committed
Update change-PID.ino
1 parent 6edafcc commit ba8f3ea

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

Arduino/MycobotBasic/examples/change-PID/change-PID.ino

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,12 @@ void change_mode2(){
9191
delay(50);
9292
myCobot.setServoData(i, 23, I);//I
9393
delay(50);
94+
myCobot.setServoData(i, 24, 0);//I
95+
delay(50);
96+
myCobot.setServoData(i, 26, 3);//I
97+
delay(50);
98+
myCobot.setServoData(i, 27, 3);//I
99+
delay(50);
94100
}
95101
M5.Lcd.println("CHANGE PID to Mode 2");
96102
M5.Lcd.println();
@@ -120,7 +126,12 @@ void change_mode1(){
120126
delay(50);
121127
myCobot.setServoData(i, 23, I);//I
122128
delay(50);
123-
129+
myCobot.setServoData(i, 24, 0);//I
130+
delay(50);
131+
myCobot.setServoData(i, 26, 3);//I
132+
delay(50);
133+
myCobot.setServoData(i, 27, 3);//I
134+
delay(50);
124135
}
125136
M5.Lcd.println("Servo CHANGE PID to Mode 1");
126137
M5.Lcd.println();

0 commit comments

Comments
 (0)