mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[wpilib, hal] High Level REV PH changes (#3792)
More functionality was implemented at the HAL level, so expose that to the wpilib level. This also does units changes for all the PH related functionality.
This commit is contained in:
@@ -48,10 +48,14 @@ bool Compressor::GetPressureSwitchValue() const {
|
||||
return m_module->GetPressureSwitch();
|
||||
}
|
||||
|
||||
double Compressor::GetCurrent() const {
|
||||
units::ampere_t Compressor::GetCurrent() const {
|
||||
return m_module->GetCompressorCurrent();
|
||||
}
|
||||
|
||||
units::volt_t Compressor::GetAnalogVoltage() const {
|
||||
return m_module->GetAnalogVoltage(0);
|
||||
}
|
||||
|
||||
void Compressor::Disable() {
|
||||
m_module->DisableCompressor();
|
||||
}
|
||||
@@ -60,13 +64,13 @@ void Compressor::EnableDigital() {
|
||||
m_module->EnableCompressorDigital();
|
||||
}
|
||||
|
||||
void Compressor::EnableAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void Compressor::EnableAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) {
|
||||
m_module->EnableCompressorAnalog(minAnalogVoltage, maxAnalogVoltage);
|
||||
}
|
||||
|
||||
void Compressor::EnableHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void Compressor::EnableHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) {
|
||||
m_module->EnableCompressorHybrid(minAnalogVoltage, maxAnalogVoltage);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user