13class PowerDistribution;
Class for getting voltage, current, temperature, power and energy from the CTRE Power Distribution Pa...
Definition: PowerDistribution.h:18
Class to control a simulated Power Distribution Panel (PowerDistribution).
Definition: PowerDistributionSim.h:20
bool GetInitialized() const
Check whether the PowerDistribution has been initialized.
void ResetData()
Reset all PowerDistribution simulation data.
std::unique_ptr< CallbackStore > RegisterCurrentCallback(int channel, NotifyCallback callback, bool initialNotify)
Register a callback to be run whenever the current of a specific channel changes.
std::unique_ptr< CallbackStore > RegisterInitializedCallback(NotifyCallback callback, bool initialNotify)
Register a callback to be run when the PowerDistribution is initialized.
void SetVoltage(double voltage)
Set the PowerDistribution voltage.
void SetAllCurrents(const double *currents, int length)
Change the current in all of the PowerDistribution channels.
void SetInitialized(bool initialized)
Define whether the PowerDistribution has been initialized.
void SetTemperature(double temperature)
Define the PowerDistribution temperature.
std::unique_ptr< CallbackStore > RegisterVoltageCallback(NotifyCallback callback, bool initialNotify)
Register a callback to be run whenever the PowerDistribution voltage changes.
double GetVoltage() const
Check the PowerDistribution voltage.
std::unique_ptr< CallbackStore > RegisterTemperatureCallback(NotifyCallback callback, bool initialNotify)
Register a callback to be run whenever the PowerDistribution temperature changes.
PowerDistributionSim(int module=0)
Constructs from a PowerDistribution module number (CAN ID).
void GetAllCurrents(double *currents, int length) const
Read the current of all of the PowerDistribution channels.
double GetTemperature() const
Check the temperature of the PowerDistribution.
void SetCurrent(int channel, double current)
Change the current in the given channel.
PowerDistributionSim(const PowerDistribution &pdp)
Constructs from a PowerDistribution object.
double GetCurrent(int channel) const
Read the current in one of the PowerDistribution channels.
std::function< void(std::string_view, const HAL_Value *)> NotifyCallback
Definition: CallbackStore.h:14
Definition: AprilTagPoseEstimator.h:15