[hal] Add more shutdown checks and motor safety shutdown (#4510)

This commit is contained in:
Thad House
2022-10-23 21:59:04 -07:00
committed by GitHub
parent 023a5989f8
commit ba850bac3b
4 changed files with 51 additions and 3 deletions

View File

@@ -21,6 +21,9 @@ namespace frc {
int RunHALInitialization();
namespace impl {
#ifndef __FRC_ROBORIO__
void ResetMotorSafety();
#endif
template <class Robot>
void RunRobot(wpi::mutex& m, Robot** robot) {
@@ -103,6 +106,9 @@ int StartRobot() {
impl::RunRobot<Robot>(m, &robot);
}
#ifndef __FRC_ROBORIO__
frc::impl::ResetMotorSafety();
#endif
HAL_Shutdown();
return 0;