Description
Thinking about semi-stable parameters like the pedal voltage limits which change upon reassembly. Not stable values like vehicle track width.
These values are currently compiled into the firmware (see FrontController/physical.hpp) which makes it difficult to update.
We should store these values in a separate region of flash so they can be updated on the fly.
Sample procedure:
-
Driver enters a "calibration mode" through the dashboard.
-
Dashboard displays the current parameters. Modifiable ones have a button "recalibrate"
-
User selects a parameter, say "accelerator pedal range"
-
Dashboard guides the user through a calibration sequence, like "fully press the pedal, hold, now fully release, hold. repeat 5x"
-
Dashboard calculates the new parameter values (ex max value=avg max voltage of the 5 cycles)
-
Dashboard tells front controller to update the value in flash memory
-
Front controller now uses this value
LittleFS would help with this