This is implementing a task that handles directing the state machine. It will handle checking for valid transitions and actually executing the transitions.
I made a lot of the stuff static, only providing developers the functions to retrieve and queue up states. All the processing is handled internally, so the user doesn't have to worry about much.
Notes
I think that we might need to play around with message priorities inside of queues. I think that it means that a message with a higher priority is processed first, which might be really beneficial for state handling (i.e. transition to faulted is high priority). This also might be useful for other message queues like the CAN queue.
Test Cases
Made sure it built, that is essentially it sadly
To Do
[x] Actually implement the state transitions (or how to signal them)
[ ] Test state transitions on renode
[x] Initialize task in main
Checklist
It can be helpful to check the Checks and Files changed tabs.
Please reach out to your Project Lead if anything is unclear.
Please request reviewers and ping on slack only after you've gone through this whole checklist.
[x] No merge conflicts
[x] All checks passing
[x] Remove any non-applicable sections of this template
Changes
This is implementing a task that handles directing the state machine. It will handle checking for valid transitions and actually executing the transitions.
I made a lot of the stuff static, only providing developers the functions to retrieve and queue up states. All the processing is handled internally, so the user doesn't have to worry about much.
Notes
I think that we might need to play around with message priorities inside of queues. I think that it means that a message with a higher priority is processed first, which might be really beneficial for state handling (i.e. transition to faulted is high priority). This also might be useful for other message queues like the CAN queue.
Test Cases
Made sure it built, that is essentially it sadly
To Do
Checklist
It can be helpful to check the
Checks
andFiles changed
tabs. Please reach out to your Project Lead if anything is unclear. Please request reviewers and ping on slack only after you've gone through this whole checklist.