Instrument Neutral Distributed Interface INDI  2.0.2
Public Types | Public Member Functions | Protected Member Functions | List of all members
SkySafariClient Class Reference

#include <skysafariclient.h>

Inheritance diagram for SkySafariClient:
INDI::BaseClient INDI::AbstractBaseClient INDI::BaseMediator

Public Types

enum  GotoMode { SLEW , TRACK , SYNC }
 

Public Member Functions

 SkySafariClient ()
 
 ~SkySafariClient ()
 
bool isConnected ()
 
void setMount (const std::string &value)
 
INDI::PropertyViewNumbergetEquatorialCoords ()
 
bool sendEquatorialCoords ()
 
INDI::PropertyViewNumbergetGeographiCoords ()
 
bool sendGeographicCoords ()
 
INDI::PropertyViewSwitchgetGotoMode ()
 
bool sendGotoMode ()
 
INDI::PropertyViewSwitchgetMotionNS ()
 
bool setMotionNS ()
 
INDI::PropertyViewSwitchgetMotionWE ()
 
bool setMotionWE ()
 
bool parkMount ()
 
IPState getMountParkState ()
 
bool setSlewRate (int slewRate)
 
bool abort ()
 
INDI::PropertyViewTextgetTimeUTC ()
 
bool setTimeUTC ()
 
- Public Member Functions inherited from INDI::BaseClient
 BaseClient ()
 
virtual ~BaseClient ()
 
bool connectServer () override
 Connect to INDI server. More...
 
bool disconnectServer (int exit_code=0) override
 Disconnect from INDI server. Any devices previously created will be deleted and memory cleared. More...
 
void enableDirectBlobAccess (const char *dev=nullptr, const char *prop=nullptr)
 activate zero-copy delivering of the blob content. When enabled, all blob copy will be avoided when possible (depending on the connection). This changes how the IBLOB.data field : More...
 
- Public Member Functions inherited from INDI::AbstractBaseClient
 AbstractBaseClient ()=delete
 
virtual ~AbstractBaseClient ()
 
void setServer (const char *hostname, unsigned int port)
 Set the server host name and port. More...
 
const char * getHost () const
 Get the server host name. More...
 
int getPort () const
 Get the port number. More...
 
bool isServerConnected () const
 Get status of the connection. More...
 
void setConnectionTimeout (uint32_t seconds, uint32_t microseconds)
 setConnectionTimeout Set connection timeout. By default it is 3 seconds. More...
 
void setVerbose (bool enable)
 setVerbose Set verbose mode More...
 
bool isVerbose () const
 isVerbose Is client in verbose mode? More...
 
void watchDevice (const char *deviceName)
 Add a device to the watch list. More...
 
void watchDevice (const char *deviceName, const std::function< void(BaseDevice)> &callback)
 
void watchProperty (const char *deviceName, const char *propertyName)
 watchProperties Add a property to the watch list. When communicating with INDI server. More...
 
void connectDevice (const char *deviceName)
 Disconnect INDI driver. More...
 
void disconnectDevice (const char *deviceName)
 Disconnect INDI driver. More...
 
INDI::BaseDevice getDevice (const char *deviceName)
 
std::vector< INDI::BaseDevicegetDevices () const
 
bool getDevices (std::vector< INDI::BaseDevice > &deviceList, uint16_t driverInterface)
 getDevices Returns list of devices that belong to a particular DRIVER_INTERFACE class. More...
 
void setBLOBMode (BLOBHandling blobH, const char *dev, const char *prop=nullptr)
 Set Binary Large Object policy mode. More...
 
BLOBHandling getBLOBMode (const char *dev, const char *prop=nullptr)
 getBLOBMode Get Binary Large Object policy mode IF set previously by setBLOBMode More...
 
void sendNewProperty (INDI::Property pp)
 Send new Property command to server. More...
 
void sendNewText (INDI::Property pp)
 Send new Text command to server. More...
 
void sendNewText (const char *deviceName, const char *propertyName, const char *elementName, const char *text)
 Send new Text command to server. More...
 
void sendNewNumber (INDI::Property pp)
 Send new Number command to server. More...
 
void sendNewNumber (const char *deviceName, const char *propertyName, const char *elementName, double value)
 Send new Number command to server. More...
 
void sendNewSwitch (INDI::Property pp)
 Send new Switch command to server. More...
 
void sendNewSwitch (const char *deviceName, const char *propertyName, const char *elementName)
 Send new Switch command to server. More...
 
void startBlob (const char *devName, const char *propName, const char *timestamp)
 Send opening tag for BLOB command to server. More...
 
void sendOneBlob (IBLOB *bp)
 Send ONE blob content to server. The BLOB data in raw binary format and will be converted to base64 and sent to server. More...
 
void sendOneBlob (INDI::WidgetViewBlob *blob)
 
void sendOneBlob (const char *blobName, unsigned int blobSize, const char *blobFormat, void *blobBuffer)
 Send ONE blob content to server. The BLOB data in raw binary format and will be converted to base64 and sent to server. More...
 
void finishBlob ()
 Send closing tag for BLOB command to server. More...
 
void sendPingRequest (const char *uid)
 Send one ping request, the server will answer back with the same uuid. More...
 
void sendPingReply (const char *uid)
 Send a ping reply for the given uuid. More...
 
- Public Member Functions inherited from INDI::BaseMediator
virtual ~BaseMediator ()=default
 
virtual void removeDevice (INDI::BaseDevice baseDevice)
 Emmited when a device is deleted from INDI server. More...
 
virtual void updateProperty (INDI::Property property)
 Emmited when a new property value arrives from INDI server. More...
 
virtual void removeProperty (INDI::Property property)
 Emmited when a property is deleted for an INDI driver. More...
 
virtual void newMessage (INDI::BaseDevice baseDevice, int messageID)
 Emmited when a new message arrives from INDI server. More...
 
virtual void serverConnected ()
 Emmited when the server is connected. More...
 
virtual void serverDisconnected (int exit_code)
 Emmited when the server gets disconnected. More...
 
virtual void newDevice (INDI::BaseDevice *dp)
 Emmited when a new device is created from INDI server. More...
 
virtual void removeDevice (INDI::BaseDevice *dp)
 Emmited when a device is deleted from INDI server. More...
 
virtual void newProperty (INDI::Property *property)
 Emmited when a new property is created for an INDI driver. More...
 
virtual void removeProperty (INDI::Property *property)
 Emmited when a property is deleted for an INDI driver. More...
 
virtual void newSwitch (ISwitchVectorProperty *svp)
 Emmited when a new switch value arrives from INDI server. More...
 
virtual void newNumber (INumberVectorProperty *nvp)
 Emmited when a new number value arrives from INDI server. More...
 
virtual void newText (ITextVectorProperty *tvp)
 Emmited when a new text value arrives from INDI server. More...
 
virtual void newLight (ILightVectorProperty *lvp)
 Emmited when a new light value arrives from INDI server. More...
 
virtual void newBLOB (IBLOB *bp)
 Emmited when a new property value arrives from INDI server. More...
 
virtual void newMessage (INDI::BaseDevice *dp, int messageID)
 Emmited when a new message arrives from INDI server. More...
 

Protected Member Functions

virtual void newDevice (INDI::BaseDevice dp) override
 Emmited when a new device is created from INDI server. More...
 
virtual void newProperty (INDI::Property property) override
 Emmited when a new property is created for an INDI driver. More...
 
- Protected Member Functions inherited from INDI::AbstractBaseClient
virtual void newPingReply (std::string uid)
 pingReply are sent by the server on response to pingReply (see above). More...
 
virtual void newUniversalMessage (std::string message)
 newUniversalMessage Universal messages are sent from INDI server without a specific device. It is addressed to the client overall. More...
 
 AbstractBaseClient (std::unique_ptr< AbstractBaseClientPrivate > &&dd)
 

Additional Inherited Members

- Protected Attributes inherited from INDI::AbstractBaseClient
std::unique_ptr< AbstractBaseClientPrivated_ptr_indi
 

Detailed Description

Definition at line 32 of file skysafariclient.h.

Member Enumeration Documentation

◆ GotoMode

Enumerator
SLEW 
TRACK 
SYNC 

Definition at line 35 of file skysafariclient.h.

Constructor & Destructor Documentation

◆ SkySafariClient()

SkySafariClient::SkySafariClient ( )

Definition at line 35 of file skysafariclient.cpp.

◆ ~SkySafariClient()

SkySafariClient::~SkySafariClient ( )

Definition at line 43 of file skysafariclient.cpp.

Member Function Documentation

◆ abort()

bool SkySafariClient::abort ( )

Definition at line 167 of file skysafariclient.cpp.

◆ getEquatorialCoords()

INDI::PropertyViewNumber* SkySafariClient::getEquatorialCoords ( )
inline

Definition at line 47 of file skysafariclient.h.

◆ getGeographiCoords()

INDI::PropertyViewNumber* SkySafariClient::getGeographiCoords ( )
inline

Definition at line 53 of file skysafariclient.h.

◆ getGotoMode()

INDI::PropertyViewSwitch* SkySafariClient::getGotoMode ( )
inline

Definition at line 59 of file skysafariclient.h.

◆ getMotionNS()

INDI::PropertyViewSwitch* SkySafariClient::getMotionNS ( )
inline

Definition at line 65 of file skysafariclient.h.

◆ getMotionWE()

INDI::PropertyViewSwitch* SkySafariClient::getMotionWE ( )
inline

Definition at line 71 of file skysafariclient.h.

◆ getMountParkState()

IPState SkySafariClient::getMountParkState ( )

Definition at line 121 of file skysafariclient.cpp.

◆ getTimeUTC()

INDI::PropertyViewText* SkySafariClient::getTimeUTC ( )
inline

Definition at line 84 of file skysafariclient.h.

◆ isConnected()

bool SkySafariClient::isConnected ( )
inline

Definition at line 40 of file skysafariclient.h.

◆ newDevice()

void SkySafariClient::newDevice ( INDI::BaseDevice  baseDevice)
overrideprotectedvirtual

Emmited when a new device is created from INDI server.

Parameters
baseDeviceBaseDevice instance.

Reimplemented from INDI::BaseMediator.

Definition at line 50 of file skysafariclient.cpp.

◆ newProperty()

void SkySafariClient::newProperty ( INDI::Property  property)
overrideprotectedvirtual

Emmited when a new property is created for an INDI driver.

Parameters
propertyProperty container.

Reimplemented from INDI::BaseMediator.

Definition at line 64 of file skysafariclient.cpp.

◆ parkMount()

bool SkySafariClient::parkMount ( )

Definition at line 98 of file skysafariclient.cpp.

◆ sendEquatorialCoords()

bool SkySafariClient::sendEquatorialCoords ( )

Definition at line 129 of file skysafariclient.cpp.

◆ sendGeographicCoords()

bool SkySafariClient::sendGeographicCoords ( )

Definition at line 142 of file skysafariclient.cpp.

◆ sendGotoMode()

bool SkySafariClient::sendGotoMode ( )

Definition at line 155 of file skysafariclient.cpp.

◆ setMotionNS()

bool SkySafariClient::setMotionNS ( )

Definition at line 205 of file skysafariclient.cpp.

◆ setMotionWE()

bool SkySafariClient::setMotionWE ( )

Definition at line 218 of file skysafariclient.cpp.

◆ setMount()

void SkySafariClient::setMount ( const std::string &  value)

Definition at line 89 of file skysafariclient.cpp.

◆ setSlewRate()

bool SkySafariClient::setSlewRate ( int  slewRate)

Definition at line 181 of file skysafariclient.cpp.

◆ setTimeUTC()

bool SkySafariClient::setTimeUTC ( )

Definition at line 231 of file skysafariclient.cpp.


The documentation for this class was generated from the following files: