10 #include <units/units.h>
11 #include <wpi/deprecated.h>
12 #include <wpi/mutex.h>
15 #include "frc2/Timer.h"
29 void Wait(
double seconds);
57 virtual ~
Timer() =
default;
136 static const double kRolloverTime;
Timer()
Create a new timer object.
void Reset()
Reset the timer by setting the time to 0.
void Start()
Start the timer running.
static double GetMatchTime()
Return the approximate match time.
A wrapper for the frc::Timer class that returns unit-typed values.
Definition: Timer.h:40
void Stop()
Stop the timer.
Timer objects measure accumulated time in seconds.
Definition: Timer.h:47
bool HasPeriodPassed(double period)
Check if the period specified has passed and if it has, advance the start time by that period.
double GetTime()
Gives real-time clock system time with nanosecond resolution.
A class that enforces constraints on the differential drive kinematics.
Definition: SPIAccelerometerSim.h:16
double Get() const
Get the current time from the timer.
void Wait(double seconds)
Pause the task for a specified time.
static double GetFPGATimestamp()
Return the FPGA system clock time in seconds.