mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
committed by
Peter Johnson
parent
120ceb3427
commit
5ca00dddbe
@@ -43,10 +43,15 @@ void TimedRobot::SetPeriod(double period) {
|
||||
m_period = period;
|
||||
|
||||
if (m_startLoop) {
|
||||
m_loop->StartPeriodic(m_period);
|
||||
m_loop->StartPeriodic(period);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get time period between calls to Periodic() functions.
|
||||
*/
|
||||
double TimedRobot::GetPeriod() const { return m_period; }
|
||||
|
||||
TimedRobot::TimedRobot() {
|
||||
m_loop = std::make_unique<Notifier>(&TimedRobot::LoopFunc, this);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user