State machine
The system is always persisting in one of its allowed states. These states are also called modes and are visible as a state variable inside the system as a number.
The mode is variable /mode in the root.
| MODE name | MODE number | Description |
|---|---|---|
| MODE_STOP | 0 | Driver or common block is in error. Check /driver/error and /common/error. |
| MODE_WAIT | 10 | Delayed startup in action |
| MODE_IDLE | 100 | Idle_level and idle_cmd is applied. Input is 0. |
| MODE_CAN | 120 | Driver mode is controlled by CAN |
| MODE_WORKING | 110 | Driver cmd is non zero |
| MODE_OVERRIDEN | 200 | Driver is overriden by driver API |