We'll want the pod to be able to report reasons for faults to the control station. We can emit the reason along with the socket event and display those in the console.
Remove socket emit from enter_faulted and instead emit the fault event within the conditions of running_periodic before returning State::Faulted
This currently happens in three situations: pressure drops, LIM overheats, or the lidar detects an obstruction although more may arise
Provide a descriptive message to emit as the reason, e.g. value A exceeded threshold B
In practice, it may be more efficient to declare enumerated message formats, but strings should be fine for now
Add a new entry to ServerToClientEvents for the fault event
Add a new onFault handler to PodSocketClient to include the reason in the console messages
Currently blocked by #56 which will connect podData to the Console component
We'll want the pod to be able to report reasons for faults to the control station. We can emit the reason along with the socket event and display those in the console.
enter_faulted
and instead emit thefault
event within the conditions ofrunning_periodic
before returningState::Faulted
ServerToClientEvents
for thefault
eventonFault
handler toPodSocketClient
to include the reason in the console messagespodData
to theConsole
component