43 virtual bool ISNewText(
const char *dev,
const char *name,
char *texts[],
char *names[],
int n)
override;
44 virtual bool ISNewSwitch(
const char *dev,
const char *name,
ISState *states,
char *names[],
int n)
override;
51 virtual bool Connect()
override;
58 void processCommand(std::string
cmd);
62 bool startDiscovery();
64 void handleDiscovery();
66 bool sendSkySafari(
const char *message);
68 void sendGeographicCoords();
69 void sendUTCtimedate();
71 template <
typename Out>
72 void split(
const std::string &s,
char delim, Out result);
73 std::vector<std::string> split(
const std::string &s,
char delim);
77 IText SettingsT[3] {};
87 IText ActiveDeviceT[1] {};
107 SKYFI_DISCOVERY_ENABLE,
108 SKYFI_DISCOVERY_DISABLE
112 std::unique_ptr<SkySafariClient> skySafariClient;
114 int lsocket = -1, clientFD = -1, discoverySocket = -1;
115 unsigned short serverPort = 0;
117 bool isSkySafariConnected =
false, haveLatitude =
false, haveLongitude =
false;
118 bool haveUTCoffset =
false, haveUTCtime =
false, haveUTCdate =
false;
120 double siteLatitude = 0, siteLongitude = 0;
121 double RA = 0, DE = 0;
122 double timeUTCOffset = 0;
123 int timeYear = 0, timeMonth = 0, timeDay = 0, timeHour = 0, timeMin = 0, timeSec = 0;
Class to provide extended functionality for devices in addition to the functionality provided by INDI...
virtual bool initProperties() override
Initialize properties initial state and value. The child class must implement this function.
virtual void ISGetProperties(const char *dev) override
define the driver's properties to the client. Usually, only a minimum set of properties are defined t...
virtual bool Connect() override
Connect to the device. INDI::DefaultDevice implementation connects to appropriate connection interfac...
virtual void TimerHit() override
Callback function to be called once SetTimer duration elapses.
virtual const char * getDefaultName() override
virtual bool ISNewText(const char *dev, const char *name, char *texts[], char *names[], int n) override
Process the client newSwitch command.
virtual bool saveConfigItems(FILE *fp) override
saveConfigItems Save specific properties in the provide config file handler. Child class usually over...
virtual bool ISNewSwitch(const char *dev, const char *name, ISState *states, char *names[], int n) override
Process the client newSwitch command.
virtual bool Disconnect() override
Disconnect from device.
struct _ISwitchVectorProperty ISwitchVectorProperty
struct _ITextVectorProperty ITextVectorProperty
*brief user defined string literal for JSON values *sa std::size_t n