Revert "Suppress Watchdog's generic timeout message in MotorSafety (#1486)"

This reverts commit 41596608cc.
This commit is contained in:
Peter Johnson
2018-12-29 16:19:04 -08:00
parent 75cc09a9e4
commit 7c35355d29
5 changed files with 5 additions and 45 deletions

View File

@@ -51,12 +51,10 @@ void Watchdog::Thread::Main() {
auto now = hal::fpga_clock::now();
if (now - watchdog->m_lastTimeoutPrintTime > kMinPrintPeriod) {
watchdog->m_lastTimeoutPrintTime = now;
if (!watchdog->m_suppressTimeoutMessage) {
wpi::outs() << "Watchdog not fed within "
<< wpi::format("%.6f",
watchdog->m_timeout.count() / 1.0e6)
<< "s\n";
}
wpi::outs() << "Watchdog not fed within "
<< wpi::format("%.6f",
watchdog->m_timeout.count() / 1.0e6)
<< "s\n";
}
lock.unlock();
watchdog->m_callback();
@@ -161,10 +159,6 @@ void Watchdog::Disable() {
thr->m_cond.notify_all();
}
void Watchdog::SuppressTimeoutMessage(bool suppress) {
m_suppressTimeoutMessage = suppress;
}
bool Watchdog::operator>(const Watchdog& rhs) {
return m_expirationTime > rhs.m_expirationTime;
}