28#define GPS_TAB "Extended GPS Features"
47 IUFillSwitchVector(&
GPSPowerSP,
GPSPowerS, 2,
getDeviceName(),
"GPS Power",
"",
GPS_TAB,
IP_RW,
ISR_1OFMANY, 0,
53 IUFillSwitchVector(&
GPSStatusSP,
GPSStatusS, 3,
getDeviceName(),
"GPS Status",
"",
GPS_TAB,
IP_RW,
ISR_1OFMANY, 0,
58 IUFillSwitchVector(&
GPSUpdateSP,
GPSUpdateS, 2,
getDeviceName(),
"GPS System",
"",
GPS_TAB,
IP_RW,
ISR_1OFMANY, 0,
63 IUFillSwitchVector(&
AltDecPecSP,
AltDecPecS, 2,
getDeviceName(),
"Alt/Dec PEC",
"",
GPS_TAB,
IP_RW,
ISR_1OFMANY, 0,
68 IUFillSwitchVector(&
AzRaPecSP,
AzRaPecS, 2,
getDeviceName(),
"Az/RA PEC",
"",
GPS_TAB,
IP_RW,
ISR_1OFMANY, 0,
84 IUFillSwitchVector(&
OTAUpdateSP,
OTAUpdateS, 1,
getDeviceName(),
"OTA Update",
"",
GPS_TAB,
IP_RW,
ISR_ATMOST1, 0,
90 GuideRateNP[0].
fill(
"GUIDE_RATE_WE",
"W/E Rate",
"%g", 0, 2, 0.05, 0.5);
91 GuideRateNP[1].
fill(
"GUIDE_RATE_NS",
"N/S Rate",
"%g", 0, 2, 0.05, 0.5);
201 strncpy(msg,
"GPS system is in sleep mode.", 64);
206 strncpy(msg,
"GPS system is reactivated.", 64);
211 strncpy(msg,
"GPS system is restarting...", 64);
269 strncpy(msg,
"Alt/Dec Compensation Enabled.", 64);
274 strncpy(msg,
"Alt/Dec Compensation Disabled.", 64);
297 strncpy(msg,
"Ra/Az Compensation Enabled.", 64);
302 strncpy(msg,
"Ra/Az Compensation Disabled.", 64);
366 JD = ln_get_julian_day(utc);
370 ln_date_to_zonedate(utc, <m, utc_offset * 3600);
372 LOGF_DEBUG(
"Local time is %02d:%02d:%02g", ltm.hours, ltm.minutes, ltm.seconds);
377 LOG_ERROR(
"Error setting local time time.");
382 if (
setLocalDate(utc->days, utc->months, utc->years) ==
false)
396 LOG_INFO(
"Time updated, updating planetary data...");
403 if (strcmp(name,
"GUIDE_RATE") == 0)
408 LOG_INFO(
"Guide rate set in INDI driver, please check mount is set to the same values");
virtual bool deleteProperty(const char *propertyName)
Delete a property and unregister it. It will also be deleted from all clients.
void defineProperty(INumberVectorProperty *property)
bool isSimulation() const
void setState(IPState state)
void apply(const char *format,...) const ATTRIBUTE_FORMAT_PRINTF(2
void save(FILE *f) const
save Save property to configuration file.
void fill(const char *device, const char *name, const char *label, const char *group, IPerm permission, double timeout, IPState state)
TelescopeStatus TrackState
void SetTelescopeCapability(uint32_t cap, uint8_t slewRateCount)
SetTelescopeCapability sets the Telescope capabilities. All capabilities must be initialized.
virtual void SetParked(bool isparked)
SetParked Change the mount parking status. The data park file (stored in ~/.indi/ParkData....
@ TELESCOPE_CAN_CONTROL_TRACK
uint32_t GetTelescopeCapability() const
GetTelescopeCapability returns the capability of the Telescope.
virtual bool updateProperties() override
Called when connected state changes, to add/remove properties.
virtual bool initProperties() override
Called to initialize basic properties required all the time.
bool updateProperties()
Called when connected state changes, to add/remove properties.
ISwitch AltDecBacklashS[1]
INumberVectorProperty OTATempNP
void ISGetProperties(const char *dev)
define the driver's properties to the client. Usually, only a minimum set of properties are defined t...
ISwitchVectorProperty AzRaPecSP
ISwitchVectorProperty AltDecPecSP
ISwitchVectorProperty AzRaBacklashSP
INDI::PropertyNumber GuideRateNP
virtual bool ISNewNumber(const char *dev, const char *name, double values[], char *names[], int n)
Process the client newNumber command.
ISwitchVectorProperty AltDecBacklashSP
ISwitchVectorProperty GPSStatusSP
virtual bool UnPark()
Unpark the telescope if already parked.
ISwitchVectorProperty GPSPowerSP
virtual bool saveConfigItems(FILE *fp)
saveConfigItems Save specific properties in the provide config file handler. Child class usually over...
bool ISNewSwitch(const char *dev, const char *name, ISState *states, char *names[], int n)
Process the client newSwitch command.
bool initProperties()
Called to initialize basic properties required all the time.
ISwitchVectorProperty GPSUpdateSP
ISwitchVectorProperty OTAUpdateSP
const char * getDefaultName()
virtual bool updateTime(ln_date *utc, double utc_offset)
Update telescope time, date, and UTC offset.
ISwitchVectorProperty SelenSyncSP
virtual bool ISNewNumber(const char *dev, const char *name, double values[], char *names[], int n) override
Process the client newNumber command.
virtual bool sendScopeLocation()
virtual bool saveConfigItems(FILE *fp) override
saveConfigItems Save specific properties in the provide config file handler. Child class usually over...
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 ISNewSwitch(const char *dev, const char *name, ISState *states, char *names[], int n) override
Process the client newSwitch command.
virtual bool sendScopeTime()
virtual bool setLocalDate(uint8_t days, uint8_t months, uint16_t years)
virtual bool setLocalTime24(uint8_t hour, uint8_t minute, uint8_t second)
virtual bool setUTCOffset(double offset)
const char * MOTION_TAB
MOTION_TAB Where all the motion control properties of the device are located.
INDI::PropertySwitch MountTypeSP
void IUFillNumberVector(INumberVectorProperty *nvp, INumber *np, int nnp, const char *dev, const char *name, const char *label, const char *group, IPerm p, double timeout, IPState s)
Assign attributes for a number vector property. The vector's auxiliary elements will be set to NULL.
int IUFindOnSwitchIndex(const ISwitchVectorProperty *svp)
Returns the index of first ON switch it finds in the vector switch property.
void IUResetSwitch(ISwitchVectorProperty *svp)
Reset all switches in a switch vector property to OFF.
void IUFillSwitch(ISwitch *sp, const char *name, const char *label, ISState s)
Assign attributes for a switch property. The switch's auxiliary elements will be set to NULL.
void IUFillNumber(INumber *np, const char *name, const char *label, const char *format, double min, double max, double step, double value)
Assign attributes for a number property. The number's auxiliary elements will be set to NULL.
void IUFillSwitchVector(ISwitchVectorProperty *svp, ISwitch *sp, int nsp, const char *dev, const char *name, const char *label, const char *group, IPerm p, ISRule r, double timeout, IPState s)
Assign attributes for a switch vector property. The vector's auxiliary elements will be set to NULL.
int IUUpdateSwitch(ISwitchVectorProperty *svp, ISState *states, char *names[], int n)
Update all switches in a switch vector property.
void IDSetNumber(const INumberVectorProperty *nvp, const char *fmt,...)
void IDSetSwitch(const ISwitchVectorProperty *svp, const char *fmt,...)
#define LOGF_DEBUG(fmt,...)
#define LOG_ERROR(txt)
Shorter logging macros. In order to use these macros, the function (or method) "getDeviceName()" must...
int getOTATemp(int fd, double *value)
#define enableRaAzPec(fd)
#define activateAltDecAntiBackSlash(fd)
#define initTelescope(fd)
#define disableDecAltPec(fd)
#define enableDecAltPec(fd)
#define updateGPS_System(fd)
#define disableRaAzPec(fd)
#define activateAzRaAntiBackSlash(fd)