mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-28 02:11: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);
|
||||
}
|
||||
|
||||
|
||||
@@ -52,6 +52,7 @@ class PneumaticHub::DataStore {
|
||||
bool m_compressorReserved{false};
|
||||
wpi::mutex m_reservedLock;
|
||||
PneumaticHub m_moduleObject{HAL_kInvalidHandle, 0};
|
||||
std::array<units::second_t, 16> m_oneShotDurMs{0_s};
|
||||
};
|
||||
|
||||
PneumaticHub::PneumaticHub()
|
||||
@@ -76,69 +77,69 @@ PneumaticHub::PneumaticHub(HAL_REVPHHandle handle, int module)
|
||||
bool PneumaticHub::GetCompressor() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetREVPHCompressor(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return result;
|
||||
}
|
||||
|
||||
void PneumaticHub::DisableCompressor() {
|
||||
int32_t status = 0;
|
||||
HAL_SetREVPHClosedLoopControlDisabled(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticHub::EnableCompressorDigital() {
|
||||
int32_t status = 0;
|
||||
HAL_SetREVPHClosedLoopControlDigital(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticHub::EnableCompressorAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void PneumaticHub::EnableCompressorAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) {
|
||||
int32_t status = 0;
|
||||
HAL_SetREVPHClosedLoopControlAnalog(m_handle, minAnalogVoltage,
|
||||
maxAnalogVoltage, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
HAL_SetREVPHClosedLoopControlAnalog(m_handle, minAnalogVoltage.value(),
|
||||
maxAnalogVoltage.value(), &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticHub::EnableCompressorHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void PneumaticHub::EnableCompressorHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) {
|
||||
int32_t status = 0;
|
||||
HAL_SetREVPHClosedLoopControlHybrid(m_handle, minAnalogVoltage,
|
||||
maxAnalogVoltage, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
HAL_SetREVPHClosedLoopControlHybrid(m_handle, minAnalogVoltage.value(),
|
||||
maxAnalogVoltage.value(), &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
CompressorConfigType PneumaticHub::GetCompressorConfigType() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetREVPHCompressorConfig(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return static_cast<CompressorConfigType>(result);
|
||||
}
|
||||
|
||||
bool PneumaticHub::GetPressureSwitch() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetREVPHPressureSwitch(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return result;
|
||||
}
|
||||
|
||||
double PneumaticHub::GetCompressorCurrent() const {
|
||||
units::ampere_t PneumaticHub::GetCompressorCurrent() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetREVPHCompressorCurrent(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
return result;
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::ampere_t{result};
|
||||
}
|
||||
|
||||
void PneumaticHub::SetSolenoids(int mask, int values) {
|
||||
int32_t status = 0;
|
||||
HAL_SetREVPHSolenoids(m_handle, mask, values, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
int PneumaticHub::GetSolenoids() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetREVPHSolenoids(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -147,27 +148,26 @@ int PneumaticHub::GetModuleNumber() const {
|
||||
}
|
||||
|
||||
int PneumaticHub::GetSolenoidDisabledList() const {
|
||||
return 0;
|
||||
// TODO Fix me
|
||||
// int32_t status = 0;
|
||||
// auto result = HAL_GetREVPHSolenoidDisabledList(m_handle, &status);
|
||||
// FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
// return result;
|
||||
int32_t status = 0;
|
||||
HAL_REVPHStickyFaults faults;
|
||||
std::memset(&faults, 0, sizeof(faults));
|
||||
HAL_GetREVPHStickyFaults(m_handle, &faults, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
uint32_t intFaults = 0;
|
||||
static_assert(sizeof(faults) == sizeof(intFaults));
|
||||
std::memcpy(&intFaults, &faults, sizeof(faults));
|
||||
return intFaults & 0xFFFF;
|
||||
}
|
||||
|
||||
void PneumaticHub::FireOneShot(int index) {
|
||||
// TODO Fix me
|
||||
// int32_t status = 0;
|
||||
// HAL_FireREVPHOneShot(m_handle, index, &status);
|
||||
// FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
int32_t status = 0;
|
||||
HAL_FireREVPHOneShot(m_handle, index,
|
||||
m_dataStore->m_oneShotDurMs[index].value(), &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticHub::SetOneShotDuration(int index, units::second_t duration) {
|
||||
// TODO Fix me
|
||||
// int32_t status = 0;
|
||||
// units::millisecond_t millis = duration;
|
||||
// HAL_SetREVPHOneShotDuration(m_handle, index, millis.to<int32_t>(),
|
||||
// &status); FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
m_dataStore->m_oneShotDurMs[index] = duration;
|
||||
}
|
||||
|
||||
bool PneumaticHub::CheckSolenoidChannel(int channel) const {
|
||||
@@ -203,6 +203,89 @@ void PneumaticHub::UnreserveCompressor() {
|
||||
m_dataStore->m_compressorReserved = false;
|
||||
}
|
||||
|
||||
PneumaticHub::Version PneumaticHub::GetVersion() const {
|
||||
int32_t status = 0;
|
||||
HAL_REVPHVersion halVersions;
|
||||
std::memset(&halVersions, 0, sizeof(halVersions));
|
||||
HAL_GetREVPHVersion(m_handle, &halVersions, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
PneumaticHub::Version versions;
|
||||
static_assert(sizeof(halVersions) == sizeof(versions));
|
||||
static_assert(std::is_standard_layout_v<decltype(versions)>);
|
||||
static_assert(std::is_trivial_v<decltype(versions)>);
|
||||
std::memcpy(&versions, &halVersions, sizeof(versions));
|
||||
return versions;
|
||||
}
|
||||
|
||||
PneumaticHub::Faults PneumaticHub::GetFaults() const {
|
||||
int32_t status = 0;
|
||||
HAL_REVPHFaults halFaults;
|
||||
std::memset(&halFaults, 0, sizeof(halFaults));
|
||||
HAL_GetREVPHFaults(m_handle, &halFaults, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
PneumaticHub::Faults faults;
|
||||
static_assert(sizeof(halFaults) == sizeof(faults));
|
||||
static_assert(std::is_standard_layout_v<decltype(faults)>);
|
||||
static_assert(std::is_trivial_v<decltype(faults)>);
|
||||
std::memcpy(&faults, &halFaults, sizeof(faults));
|
||||
return faults;
|
||||
}
|
||||
|
||||
PneumaticHub::StickyFaults PneumaticHub::GetStickyFaults() const {
|
||||
int32_t status = 0;
|
||||
HAL_REVPHStickyFaults halStickyFaults;
|
||||
std::memset(&halStickyFaults, 0, sizeof(halStickyFaults));
|
||||
HAL_GetREVPHStickyFaults(m_handle, &halStickyFaults, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
PneumaticHub::StickyFaults stickyFaults;
|
||||
static_assert(sizeof(halStickyFaults) == sizeof(stickyFaults));
|
||||
static_assert(std::is_standard_layout_v<decltype(stickyFaults)>);
|
||||
static_assert(std::is_trivial_v<decltype(stickyFaults)>);
|
||||
std::memcpy(&stickyFaults, &halStickyFaults, sizeof(stickyFaults));
|
||||
return stickyFaults;
|
||||
}
|
||||
|
||||
void PneumaticHub::ClearStickyFaults() {
|
||||
int32_t status = 0;
|
||||
HAL_ClearREVPHStickyFaults(m_handle, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
units::volt_t PneumaticHub::GetInputVoltage() const {
|
||||
int32_t status = 0;
|
||||
auto voltage = HAL_GetREVPHVoltage(m_handle, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::volt_t{voltage};
|
||||
}
|
||||
|
||||
units::volt_t PneumaticHub::Get5VRegulatedVoltage() const {
|
||||
int32_t status = 0;
|
||||
auto voltage = HAL_GetREVPH5VVoltage(m_handle, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::volt_t{voltage};
|
||||
}
|
||||
|
||||
units::ampere_t PneumaticHub::GetSolenoidsTotalCurrent() const {
|
||||
int32_t status = 0;
|
||||
auto current = HAL_GetREVPHSolenoidCurrent(m_handle, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::ampere_t{current};
|
||||
}
|
||||
|
||||
units::volt_t PneumaticHub::GetSolenoidsVoltage() const {
|
||||
int32_t status = 0;
|
||||
auto voltage = HAL_GetREVPHSolenoidVoltage(m_handle, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::volt_t{voltage};
|
||||
}
|
||||
|
||||
units::volt_t PneumaticHub::GetAnalogVoltage(int channel) const {
|
||||
int32_t status = 0;
|
||||
auto voltage = HAL_GetREVPHAnalogVoltage(m_handle, channel, &status);
|
||||
FRC_ReportError(status, "Module {}", m_module);
|
||||
return units::volt_t{voltage};
|
||||
}
|
||||
|
||||
Solenoid PneumaticHub::MakeSolenoid(int channel) {
|
||||
return Solenoid{m_module, PneumaticsModuleType::REVPH, channel};
|
||||
}
|
||||
|
||||
@@ -96,15 +96,15 @@ void PneumaticsControlModule::EnableCompressorDigital() {
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticsControlModule::EnableCompressorAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void PneumaticsControlModule::EnableCompressorAnalog(
|
||||
units::volt_t minAnalogVoltage, units::volt_t maxAnalogVoltage) {
|
||||
int32_t status = 0;
|
||||
HAL_SetCTREPCMClosedLoopControl(m_handle, true, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
}
|
||||
|
||||
void PneumaticsControlModule::EnableCompressorHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) {
|
||||
void PneumaticsControlModule::EnableCompressorHybrid(
|
||||
units::volt_t minAnalogVoltage, units::volt_t maxAnalogVoltage) {
|
||||
int32_t status = 0;
|
||||
HAL_SetCTREPCMClosedLoopControl(m_handle, true, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
@@ -125,11 +125,11 @@ bool PneumaticsControlModule::GetPressureSwitch() const {
|
||||
return result;
|
||||
}
|
||||
|
||||
double PneumaticsControlModule::GetCompressorCurrent() const {
|
||||
units::ampere_t PneumaticsControlModule::GetCompressorCurrent() const {
|
||||
int32_t status = 0;
|
||||
auto result = HAL_GetCTREPCMCompressorCurrent(m_handle, &status);
|
||||
FRC_CheckErrorStatus(status, "Module {}", m_module);
|
||||
return result;
|
||||
return units::ampere_t{result};
|
||||
}
|
||||
|
||||
bool PneumaticsControlModule::GetCompressorCurrentTooHighFault() const {
|
||||
@@ -261,6 +261,10 @@ void PneumaticsControlModule::UnreserveCompressor() {
|
||||
m_dataStore->m_compressorReserved = false;
|
||||
}
|
||||
|
||||
units::volt_t PneumaticsControlModule::GetAnalogVoltage(int channel) const {
|
||||
return units::volt_t{0};
|
||||
}
|
||||
|
||||
Solenoid PneumaticsControlModule::MakeSolenoid(int channel) {
|
||||
return Solenoid{m_module, PneumaticsModuleType::CTREPCM, channel};
|
||||
}
|
||||
|
||||
@@ -95,7 +95,14 @@ class Compressor : public wpi::Sendable,
|
||||
*
|
||||
* @return The current through the compressor, in amps
|
||||
*/
|
||||
double GetCurrent() const;
|
||||
units::ampere_t GetCurrent() const;
|
||||
|
||||
/**
|
||||
* Query the analog input voltage (on channel 0) (if supported).
|
||||
*
|
||||
* @return The analog input voltage, in volts
|
||||
*/
|
||||
units::volt_t GetAnalogVoltage() const;
|
||||
|
||||
/**
|
||||
* Disable the compressor.
|
||||
@@ -115,7 +122,8 @@ class Compressor : public wpi::Sendable,
|
||||
* @param minAnalogVoltage The minimum voltage to enable compressor
|
||||
* @param maxAnalogVoltage The maximum voltage to disable compressor
|
||||
*/
|
||||
void EnableAnalog(double minAnalogVoltage, double maxAnalogVoltage);
|
||||
void EnableAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage);
|
||||
|
||||
/**
|
||||
* Enable compressor closed loop control using hybrid input.
|
||||
@@ -125,7 +133,8 @@ class Compressor : public wpi::Sendable,
|
||||
* @param minAnalogVoltage The minimum voltage to enable compressor
|
||||
* @param maxAnalogVoltage The maximum voltage to disable compressor
|
||||
*/
|
||||
void EnableHybrid(double minAnalogVoltage, double maxAnalogVoltage);
|
||||
void EnableHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage);
|
||||
|
||||
CompressorConfigType GetConfigType() const;
|
||||
|
||||
|
||||
@@ -26,17 +26,17 @@ class PneumaticHub : public PneumaticsBase {
|
||||
|
||||
void EnableCompressorDigital() override;
|
||||
|
||||
void EnableCompressorAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) override;
|
||||
void EnableCompressorAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) override;
|
||||
|
||||
void EnableCompressorHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) override;
|
||||
void EnableCompressorHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) override;
|
||||
|
||||
CompressorConfigType GetCompressorConfigType() const override;
|
||||
|
||||
bool GetPressureSwitch() const override;
|
||||
|
||||
double GetCompressorCurrent() const override;
|
||||
units::ampere_t GetCompressorCurrent() const override;
|
||||
|
||||
void SetSolenoids(int mask, int values) override;
|
||||
|
||||
@@ -65,6 +65,68 @@ class PneumaticHub : public PneumaticsBase {
|
||||
int reverseChannel) override;
|
||||
Compressor MakeCompressor() override;
|
||||
|
||||
struct Version {
|
||||
uint32_t FirmwareMajor;
|
||||
uint32_t FirmwareMinor;
|
||||
uint32_t FirmwareFix;
|
||||
uint32_t HardwareMinor;
|
||||
uint32_t HardwareMajor;
|
||||
uint32_t UniqueId;
|
||||
};
|
||||
|
||||
Version GetVersion() const;
|
||||
|
||||
struct Faults {
|
||||
uint32_t Channel0Fault : 1;
|
||||
uint32_t Channel1Fault : 1;
|
||||
uint32_t Channel2Fault : 1;
|
||||
uint32_t Channel3Fault : 1;
|
||||
uint32_t Channel4Fault : 1;
|
||||
uint32_t Channel5Fault : 1;
|
||||
uint32_t Channel6Fault : 1;
|
||||
uint32_t Channel7Fault : 1;
|
||||
uint32_t Channel8Fault : 1;
|
||||
uint32_t Channel9Fault : 1;
|
||||
uint32_t Channel10Fault : 1;
|
||||
uint32_t Channel11Fault : 1;
|
||||
uint32_t Channel12Fault : 1;
|
||||
uint32_t Channel13Fault : 1;
|
||||
uint32_t Channel14Fault : 1;
|
||||
uint32_t Channel15Fault : 1;
|
||||
uint32_t CompressorOverCurrent : 1;
|
||||
uint32_t CompressorOpen : 1;
|
||||
uint32_t SolenoidOverCurrent : 1;
|
||||
uint32_t Brownout : 1;
|
||||
uint32_t CanWarning : 1;
|
||||
uint32_t HardwareFault : 1;
|
||||
};
|
||||
|
||||
Faults GetFaults() const;
|
||||
|
||||
struct StickyFaults {
|
||||
uint32_t CompressorOverCurrent : 1;
|
||||
uint32_t CompressorOpen : 1;
|
||||
uint32_t SolenoidOverCurrent : 1;
|
||||
uint32_t Brownout : 1;
|
||||
uint32_t CanWarning : 1;
|
||||
uint32_t CanBusOff : 1;
|
||||
uint32_t HasReset : 1;
|
||||
};
|
||||
|
||||
StickyFaults GetStickyFaults() const;
|
||||
|
||||
void ClearStickyFaults();
|
||||
|
||||
units::volt_t GetInputVoltage() const;
|
||||
|
||||
units::volt_t Get5VRegulatedVoltage() const;
|
||||
|
||||
units::ampere_t GetSolenoidsTotalCurrent() const;
|
||||
|
||||
units::volt_t GetSolenoidsVoltage() const;
|
||||
|
||||
units::volt_t GetAnalogVoltage(int channel) const override;
|
||||
|
||||
private:
|
||||
class DataStore;
|
||||
friend class DataStore;
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include <units/current.h>
|
||||
#include <units/time.h>
|
||||
#include <units/voltage.h>
|
||||
|
||||
#include "frc/CompressorConfigType.h"
|
||||
#include "frc/PneumaticsModuleType.h"
|
||||
@@ -23,17 +25,17 @@ class PneumaticsBase {
|
||||
|
||||
virtual bool GetPressureSwitch() const = 0;
|
||||
|
||||
virtual double GetCompressorCurrent() const = 0;
|
||||
virtual units::ampere_t GetCompressorCurrent() const = 0;
|
||||
|
||||
virtual void DisableCompressor() = 0;
|
||||
|
||||
virtual void EnableCompressorDigital() = 0;
|
||||
|
||||
virtual void EnableCompressorAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) = 0;
|
||||
virtual void EnableCompressorAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) = 0;
|
||||
|
||||
virtual void EnableCompressorHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) = 0;
|
||||
virtual void EnableCompressorHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) = 0;
|
||||
|
||||
virtual CompressorConfigType GetCompressorConfigType() const = 0;
|
||||
|
||||
@@ -59,6 +61,8 @@ class PneumaticsBase {
|
||||
|
||||
virtual void UnreserveCompressor() = 0;
|
||||
|
||||
virtual units::volt_t GetAnalogVoltage(int channel) const = 0;
|
||||
|
||||
virtual Solenoid MakeSolenoid(int channel) = 0;
|
||||
virtual DoubleSolenoid MakeDoubleSolenoid(int forwardChannel,
|
||||
int reverseChannel) = 0;
|
||||
|
||||
@@ -26,17 +26,17 @@ class PneumaticsControlModule : public PneumaticsBase {
|
||||
|
||||
void EnableCompressorDigital() override;
|
||||
|
||||
void EnableCompressorAnalog(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) override;
|
||||
void EnableCompressorAnalog(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) override;
|
||||
|
||||
void EnableCompressorHybrid(double minAnalogVoltage,
|
||||
double maxAnalogVoltage) override;
|
||||
void EnableCompressorHybrid(units::volt_t minAnalogVoltage,
|
||||
units::volt_t maxAnalogVoltage) override;
|
||||
|
||||
CompressorConfigType GetCompressorConfigType() const override;
|
||||
|
||||
bool GetPressureSwitch() const override;
|
||||
|
||||
double GetCompressorCurrent() const override;
|
||||
units::ampere_t GetCompressorCurrent() const override;
|
||||
|
||||
bool GetCompressorCurrentTooHighFault() const;
|
||||
bool GetCompressorCurrentTooHighStickyFault() const;
|
||||
@@ -72,6 +72,8 @@ class PneumaticsControlModule : public PneumaticsBase {
|
||||
|
||||
void UnreserveCompressor() override;
|
||||
|
||||
units::volt_t GetAnalogVoltage(int channel) const override;
|
||||
|
||||
Solenoid MakeSolenoid(int channel) override;
|
||||
DoubleSolenoid MakeDoubleSolenoid(int forwardChannel,
|
||||
int reverseChannel) override;
|
||||
|
||||
Reference in New Issue
Block a user