Watchdog: use units::second_t instead of double (#1863)

Fixes #1827.
This commit is contained in:
Tyler Veness
2019-09-03 15:58:31 -07:00
committed by Peter Johnson
parent 761bc3ef85
commit 7112add67f
7 changed files with 63 additions and 25 deletions

View File

@@ -25,7 +25,7 @@ void TimedRobot::StartCompetition() {
// Tell the DS that the robot is ready to be enabled
HAL_ObserveUserProgramStarting();
m_expirationTime = Timer::GetFPGATimestamp() + m_period;
m_expirationTime = units::second_t{Timer::GetFPGATimestamp()} + m_period;
UpdateAlarm();
// Loop forever, calling the appropriate mode-dependent function