37 isReady = mountOnline =
false;
67 mountParkSP =
property.getSwitch();
68 else if (property.
isNameMatch(
"EQUATORIAL_EOD_COORD"))
69 eqCoordsNP =
property.getNumber();
71 geoCoordsNP =
property.getNumber();
73 gotoModeSP =
property.getSwitch();
74 else if (property.
isNameMatch(
"TELESCOPE_ABORT_MOTION"))
75 abortSP =
property.getSwitch();
76 else if (property.
isNameMatch(
"TELESCOPE_SLEW_RATE"))
77 slewRateSP =
property.getSwitch();
78 else if (property.
isNameMatch(
"TELESCOPE_MOTION_NS"))
79 motionNSSP =
property.getSwitch();
80 else if (property.
isNameMatch(
"TELESCOPE_MOTION_WE"))
81 motionWESP =
property.getSwitch();
83 timeUTC =
property.getText();
100 if (mountParkSP ==
nullptr)
108 mountParkSP->
reset();
131 if (eqCoordsNP ==
nullptr)
144 if (geoCoordsNP ==
nullptr)
157 if (gotoModeSP ==
nullptr)
169 if (abortSP ==
nullptr)
183 if (slewRateSP ==
nullptr)
186 int maxSlewRate = slewRateSP->
count() - 1;
188 int finalSlewRate = slewRate;
191 if (slewRate > 0 && slewRate < maxSlewRate)
192 finalSlewRate =
static_cast<int>(ceil(slewRate * maxSlewRate / 3.0));
195 slewRateSP->
at(finalSlewRate)->setState(
ISS_ON);
207 if (motionNSSP ==
nullptr)
220 if (motionWESP ==
nullptr)
233 if (timeUTC ==
nullptr)
void sendNewSwitch(INDI::Property pp)
Send new Switch command to server.
void watchDevice(const char *deviceName)
Add a device to the watch list.
void sendNewNumber(INDI::Property pp)
Send new Number command to server.
void sendNewText(INDI::Property pp)
Send new Text command to server.
Class to provide basic INDI device functionality.
const char * getDeviceName() const
bool isDeviceNameMatch(const char *otherName) const
Check that the device name matches the argument.
Provides generic container for INDI properties.
bool isNameMatch(const char *otherName) const
bool setSlewRate(int slewRate)
bool sendGeographicCoords()
virtual void newProperty(INDI::Property property) override
Emmited when a new property is created for an INDI driver.
IPState getMountParkState()
virtual void newDevice(INDI::BaseDevice dp) override
Emmited when a new device is created from INDI server.
void setMount(const std::string &value)
bool sendEquatorialCoords()
void IDLog(const char *fmt,...)
WidgetType * at(size_t index) const
void setState(IPState state)
WidgetType * findWidgetByName(const char *name) const