Yuta Togashi / PID

Dependents:   Tourobo2022_TBCMotorDriver

Revision:
6:4074aded9b9d
Parent:
5:a3aa705d9023
diff -r a3aa705d9023 -r 4074aded9b9d Pid.cpp
--- a/Pid.cpp	Wed Mar 25 11:15:15 2020 +0000
+++ b/Pid.cpp	Thu Dec 30 16:07:37 2021 +0000
@@ -51,6 +51,8 @@
 
 void Pid::reset() {
     duty = 0.0f;   
+    now = 0.0f;
+    before = 0.0f;
 }
 
 float Pid::getDuty() {