PID用ライブラリ ※位置型PIDと速度型PIDの選択式

Dependents:   Tourobo2022_TBCMotorDriver

Files at this revision

API Documentation at this revision

Comitter:
YutaTogashi
Date:
Thu Dec 30 16:07:37 2021 +0000
Parent:
5:a3aa705d9023
Commit message:
20211231 add resetFunction now=0.0f,before=0.0f

Changed in this revision

Pid.cpp Show annotated file Show diff for this revision Revisions of this file
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() {