53 for (
size_t i = 0; i < Outputs; i++)
55 auto label = prefix +
" #" + std::to_string(i + 1);
57 oneDuration[0].
fill(
"DURATION",
"Duration (ms)",
"%.0f", 0, 60000, 100, 0);
66 for (
auto i = 0; i < Outputs; i++)
68 auto name =
"DIGITAL_OUTPUT_" + std::to_string(i + 1);
69 auto label = prefix +
" #" + std::to_string(i + 1);
72 oneLabel.
fill(name, label, label);
84 for (
size_t i = 0; i < Outputs; i++)
86 auto name =
"DIGITAL_OUTPUT_" + std::to_string(i + 1);
87 auto label = prefix +
" #" + std::to_string(i + 1);
141 if (oldState != newState)
239 oneDuration.save(fp);
Class to provide extended functionality for devices in addition to the functionality provided by INDI...
bool processNumber(const char *dev, const char *name, double values[], char *names[], int n)
Process number properties.
void initProperties(const char *groupName, uint8_t outputs, const std::string &prefix="Output")
Initialize filter wheel properties. It is recommended to call this function within initProperties() o...
bool processSwitch(const char *dev, const char *name, ISState states[], char *names[], int n)
Process switch properties.
OutputInterface(DefaultDevice *defaultDevice)
OutputInterface Initiailize Output Interface.
bool saveConfigItems(FILE *fp)
saveConfigItems save Filter Names in config file
std::vector< INDI::PropertySwitch > DigitalOutputsSP
bool processText(const char *dev, const char *name, char *texts[], char *names[], int n)
Process text properties.
virtual bool CommandOutput(uint32_t index, OutputState command)=0
Send command to output.
INDI::PropertyText DigitalOutputLabelsTP
std::vector< INDI::PropertyNumber > PulseDurationNP
bool updateProperties()
updateProperties Defines or Delete properties based on default device connection status
bool m_DigitalOutputLabelsConfig
DefaultDevice * m_defaultDevice
bool load()
load Attempt to load property values from configuration file.
void fill(const char *device, const char *name, const char *label, const char *group, IPerm permission, double timeout, IPState state)
void fill(const char *device, const char *name, const char *label, const char *group, IPerm permission, ISRule rule, double timeout, IPState state)
static void singleShot(int msec, const std::function< void()> &callback)
This static function calls a the given function after a given time interval.
*brief user defined string literal for JSON values *sa std::size_t n
Namespace to encapsulate INDI client, drivers, and mediator classes.
INDI::WidgetViewText WidgetText
void fill(const char *name, const char *label, const char *initialText)