Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed-dev FastPWM3
Revision 58:636e46484432, committed 2021-06-18
- Comitter:
- WinnieLiu
- Date:
- Fri Jun 18 15:58:03 2021 +0000
- Parent:
- 57:ae8105f28fbf
- Child:
- 59:d53a7ccaae9a
- Commit message:
- refresh motor pid parameters after modifying on the setup menu and reload from the register
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Fri Jun 18 15:13:31 2021 +0000
+++ b/main.cpp Fri Jun 18 15:58:03 2021 +0000
@@ -344,7 +344,12 @@
if (!prefs.ready()) prefs.open();
prefs.flush(); // Write new prefs to flash
prefs.close();
- prefs.load();
+ prefs.load();
+ /*----- change new pid controller parameter -----*/
+ //controller.kp = MOTOR_KP;
+ controller.ki = MOTOR_KI;
+ controller.kd = MOTOR_KD;
+
state_change = 1;
char_count = 0;
cmd_id = 0;