.

Dependencies:   L432KC_SPI_Pey_Lal

Revision:
115:156b8234f2de
Parent:
113:2f8f255e99f2
diff -r c1f7be27aa5d -r 156b8234f2de asservissement.cpp
--- a/asservissement.cpp	Wed May 18 16:12:59 2022 +0000
+++ b/asservissement.cpp	Wed May 18 18:07:09 2022 +0000
@@ -13,4 +13,10 @@
     double correction = kp * error + ki * errorIntegral;
     double correctionPWM = SPEED_TO_PWM_TRANSFORM(correction);
     return limitToInterval(correctionPWM, 1000, 1500);
+}
+
+void setPIDParameters(double kp_, double ki_)
+{
+    kp = kp_;
+    ki = ki_;
 }
\ No newline at end of file