178 void initProperties(
const char *groupName,
size_t nPowerPorts = 0,
size_t nDewPorts = 0,
size_t nVariablePorts = 0,
179 size_t nAutoDewPorts = 0,
size_t nUSBPorts = 0);
188 bool processNumber(
const char *dev,
const char *name,
double values[],
char *names[],
int n);
194 bool processText(
const char *dev,
const char *name,
char *texts[],
char *names[],
int n);
211 virtual bool SetDewPort(
size_t port,
bool enabled,
double dutyCycle);
220 virtual bool SetVariablePort(
size_t port,
bool enabled,
double voltage);
248 virtual bool SetUSBPort(
size_t port,
bool enabled);
Class to provide extended functionality for devices in addition to the functionality provided by INDI...
virtual bool SetUSBPort(size_t port, bool enabled)
SetUSBPort Set USB port on/off.
virtual bool CyclePower()
CyclePower Cycle power to all ports.
INDI::PropertySwitch PowerCycleAllSP
INDI::PropertySwitch DewChannelsSP
bool saveConfigItems(FILE *fp)
saveConfigItems Save power properties in config file
virtual bool SetAutoDewEnabled(size_t port, bool enabled)
SetAutoDewEnabled Enable/disable automatic dew control.
INDI::PropertySwitch AutoDewSP
virtual bool SetDewPort(size_t port, bool enabled, double dutyCycle)
SetDewPort Set DEW/Dew port duty cycle.
INDI::PropertyNumber VariableChannelVoltsNP
INDI::PropertyNumber OverVoltageProtectionNP
virtual bool SetVariablePort(size_t port, bool enabled, double voltage)
SetVariablePort Set variable voltage port.
bool HasOverVoltageProtection()
void SetCapability(uint32_t cap)
SetPowerCapability sets the Power capabilities. All capabilities must be initialized.
@ POWER_HAS_VOLTAGE_SENSOR
@ POWER_HAS_OVERALL_CURRENT
@ POWER_HAS_OVER_VOTALGE_PROTECTION
@ POWER_OFF_ON_DISCONNECT
@ POWER_HAS_PER_PORT_CURRENT
@ POWER_HAS_OVER_VOLTAGE_PROTECTION
INDI::PropertyNumber PowerSensorsNP
INDI::PropertyText VariableChannelLabelsTP
INDI::PropertyNumber PowerChannelCurrentNP
virtual bool SetPowerPort(size_t port, bool enabled)
SetPowerPort Set power port on/off.
virtual bool SetLEDEnabled(bool enabled)
SetLEDEnabled Enable/disable power LEDs.
INDI::PropertyNumber DewChannelCurrentNP
bool processNumber(const char *dev, const char *name, double values[], char *names[], int n)
Process Power number properties.
void initProperties(const char *groupName, size_t nPowerPorts=0, size_t nDewPorts=0, size_t nVariablePorts=0, size_t nAutoDewPorts=0, size_t nUSBPorts=0)
Initialize Power properties. It is recommended to call this function within initProperties() of your ...
INDI::PropertyText PowerChannelLabelsTP
bool processText(const char *dev, const char *name, char *texts[], char *names[], int n)
Process Power text properties.
bool processSwitch(const char *dev, const char *name, ISState *states, char *names[], int n)
Process Power switch properties.
INDI::PropertySwitch PowerChannelsSP
const char * VARIABLE_TAB
INDI::PropertySwitch USBPortSP
INDI::PropertyNumber DewChannelDutyCycleNP
INDI::PropertyText USBPortLabelsTP
bool updateProperties()
updateProperties Define or Delete Power properties based on the connection status of the base device
INDI::PropertySwitch LEDControlSP
INDI::PropertySwitch VariableChannelsSP
DefaultDevice * m_defaultDevice
uint32_t GetCapability() const
GetPowerCapability returns the capability of the Power device.
enum INDI::PowerInterface::@462 PowerCapability
bool ShouldPowerOffOnDisconnect()
INDI::PropertyText DewChannelLabelsTP
INDI::PropertySwitch PowerOffOnDisconnectSP
Namespace to encapsulate INDI client, drivers, and mediator classes.