Instrument Neutral Distributed Interface INDI  2.0.2
Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
IOPv3::Driver Class Reference

#include <ioptronv3driver.h>

Public Member Functions

 Driver (const char *deviceName)
 
 ~Driver ()=default
 
bool sendCommand (const char *command, int count=1, char *response=nullptr, uint8_t timeout=IOP_TIMEOUT, uint8_t debugLog=INDI::Logger::DBG_DEBUG)
 
bool sendCommandOk (const char *command)
 
bool checkConnection (int fd)
 
bool getStatus (IOPInfo *info)
 
bool getFirmwareInfo (FirmwareInfo *info)
 
bool getCoords (double *ra, double *de, IOP_PIER_STATE *pierState, IOP_CW_STATE *cwState)
 
bool getUTCDateTime (double *JD, int *utcOffsetMinutes, bool *dayLightSaving)
 
bool startMotion (IOP_DIRECTION dir)
 
bool stopMotion (IOP_DIRECTION dir)
 
bool setSlewRate (IOP_SLEW_RATE rate)
 
bool setCustomRATrackRate (double rate)
 
bool setTrackMode (IOP_TRACK_RATE rate)
 
bool setTrackEnabled (bool enabled)
 
bool setPECEnabled (bool enabled)
 
bool setPETEnabled (bool enabled)
 
bool getPETEnabled (bool enabled)
 
bool abort ()
 
bool slewNormal ()
 
bool slewCWUp ()
 
bool sync ()
 
bool setRA (double ra)
 
bool setDE (double de)
 
bool findHome ()
 
bool gotoHome ()
 
bool setCurrentHome ()
 
bool park ()
 
bool unpark ()
 
bool setParkAz (double az)
 
bool setParkAlt (double alt)
 
bool setGuideRate (double RARate, double DERate)
 
bool getGuideRate (double *RARate, double *DERate)
 
bool startGuide (IOP_DIRECTION dir, uint32_t ms)
 
bool setMeridianBehavior (IOP_MB_STATE action, uint8_t degrees)
 
bool getMeridianBehavior (IOP_MB_STATE &action, uint8_t &degrees)
 
bool setLongitude (double longitude)
 
bool setLatitude (double latitude)
 
bool setUTCDateTime (double JD)
 
bool setUTCOffset (int offsetMinutes)
 
bool setDaylightSaving (bool enabled)
 
void setDebug (bool enable)
 
void setSimulation (bool enable)
 
void setSimGPSstatus (IOP_GPS_STATUS value)
 
void setSimSytemStatus (IOP_SYSTEM_STATUS value)
 
void setSimTrackRate (IOP_TRACK_RATE value)
 
void setSimSlewRate (IOP_SLEW_RATE value)
 
void setSimTimeSource (IOP_TIME_SOURCE value)
 
void setSimHemisphere (IOP_HEMISPHERE value)
 
void setSimRA (double ra)
 
void setSimDE (double de)
 
void setSimLongLat (double longitude, double latitude)
 
void setSimGuideRate (double raRate, double deRate)
 

Static Public Attributes

static const std::map< std::string, std::string > models
 
static const uint16_t IOP_SLEW_RATES [] = {1, 2, 8, 16, 64, 128, 256, 512, 1024}
 

Protected Member Functions

bool getMainFirmware (std::string &mainFirmware, std::string &controllerFirmware)
 
bool getRADEFirmware (std::string &RAFirmware, std::string &DEFirmware)
 
bool getModel (std::string &model)
 

Protected Attributes

struct {
   double   ra
 
   double   de
 
   double   ra_guide_rate
 
   double   de_guide_rate
 
   double   JD
 
   int   utc_offset_minutes
 
   bool   day_light_saving
 
   uint8_t   mb_limit
 
   IOP_PIER_STATE   pier_state
 
   IOP_CW_STATE   cw_state
 
   IOP_MB_STATE   mb_state
 
   IOPInfo   simInfo
 
simData
 

Detailed Description

Definition at line 81 of file ioptronv3driver.h.

Constructor & Destructor Documentation

◆ Driver()

IOPv3::Driver::Driver ( const char *  deviceName)
explicit

Definition at line 64 of file ioptronv3driver.cpp.

◆ ~Driver()

IOPv3::Driver::~Driver ( )
default

Member Function Documentation

◆ abort()

bool IOPv3::Driver::abort ( )

Definition at line 584 of file ioptronv3driver.cpp.

◆ checkConnection()

bool IOPv3::Driver::checkConnection ( int  fd)

Definition at line 135 of file ioptronv3driver.cpp.

◆ findHome()

bool IOPv3::Driver::findHome ( )

Definition at line 386 of file ioptronv3driver.cpp.

◆ getCoords()

bool IOPv3::Driver::getCoords ( double *  ra,
double *  de,
IOP_PIER_STATE pierState,
IOP_CW_STATE cwState 
)

Get RA/DEC

Definition at line 706 of file ioptronv3driver.cpp.

◆ getFirmwareInfo()

bool IOPv3::Driver::getFirmwareInfo ( FirmwareInfo info)

Get All firmware informatin in addition to mount model

Definition at line 283 of file ioptronv3driver.cpp.

◆ getGuideRate()

bool IOPv3::Driver::getGuideRate ( double *  RARate,
double *  DERate 
)

Definition at line 494 of file ioptronv3driver.cpp.

◆ getMainFirmware()

bool IOPv3::Driver::getMainFirmware ( std::string &  mainFirmware,
std::string &  controllerFirmware 
)
protected

Get mainboard and controller firmware only

Definition at line 311 of file ioptronv3driver.cpp.

◆ getMeridianBehavior()

bool IOPv3::Driver::getMeridianBehavior ( IOP_MB_STATE action,
uint8_t &  degrees 
)

Definition at line 788 of file ioptronv3driver.cpp.

◆ getModel()

bool IOPv3::Driver::getModel ( std::string &  model)
protected

Get Mount model

Definition at line 294 of file ioptronv3driver.cpp.

◆ getPETEnabled()

bool IOPv3::Driver::getPETEnabled ( bool  enabled)

Definition at line 412 of file ioptronv3driver.cpp.

◆ getRADEFirmware()

bool IOPv3::Driver::getRADEFirmware ( std::string &  RAFirmware,
std::string &  DEFirmware 
)
protected

Get RA and DEC firmware info

Definition at line 330 of file ioptronv3driver.cpp.

◆ getStatus()

bool IOPv3::Driver::getStatus ( IOPInfo info)

Get iEQ current status info

Definition at line 241 of file ioptronv3driver.cpp.

◆ getUTCDateTime()

bool IOPv3::Driver::getUTCDateTime ( double *  JD,
int *  utcOffsetMinutes,
bool *  dayLightSaving 
)

Get UTC JD plus utc offset and whether daylight savings is active or not

Definition at line 747 of file ioptronv3driver.cpp.

◆ gotoHome()

bool IOPv3::Driver::gotoHome ( )

Definition at line 391 of file ioptronv3driver.cpp.

◆ park()

bool IOPv3::Driver::park ( )

Definition at line 547 of file ioptronv3driver.cpp.

◆ sendCommand()

bool IOPv3::Driver::sendCommand ( const char *  command,
int  count = 1,
char *  response = nullptr,
uint8_t  timeout = IOP_TIMEOUT,
uint8_t  debugLog = INDI::Logger::DBG_DEBUG 
)

Definition at line 76 of file ioptronv3driver.cpp.

◆ sendCommandOk()

bool IOPv3::Driver::sendCommandOk ( const char *  command)

Definition at line 66 of file ioptronv3driver.cpp.

◆ setCurrentHome()

bool IOPv3::Driver::setCurrentHome ( )

Definition at line 396 of file ioptronv3driver.cpp.

◆ setCustomRATrackRate()

bool IOPv3::Driver::setCustomRATrackRate ( double  rate)

Definition at line 472 of file ioptronv3driver.cpp.

◆ setDaylightSaving()

bool IOPv3::Driver::setDaylightSaving ( bool  enabled)

Definition at line 696 of file ioptronv3driver.cpp.

◆ setDE()

bool IOPv3::Driver::setDE ( double  de)

Definition at line 636 of file ioptronv3driver.cpp.

◆ setDebug()

void IOPv3::Driver::setDebug ( bool  enable)

Definition at line 161 of file ioptronv3driver.cpp.

◆ setGuideRate()

bool IOPv3::Driver::setGuideRate ( double  RARate,
double  DERate 
)

Definition at line 483 of file ioptronv3driver.cpp.

◆ setLatitude()

bool IOPv3::Driver::setLatitude ( double  latitude)

Definition at line 662 of file ioptronv3driver.cpp.

◆ setLongitude()

bool IOPv3::Driver::setLongitude ( double  longitude)

Definition at line 650 of file ioptronv3driver.cpp.

◆ setMeridianBehavior()

bool IOPv3::Driver::setMeridianBehavior ( IOP_MB_STATE  action,
uint8_t  degrees 
)

Definition at line 811 of file ioptronv3driver.cpp.

◆ setParkAlt()

bool IOPv3::Driver::setParkAlt ( double  alt)

Definition at line 572 of file ioptronv3driver.cpp.

◆ setParkAz()

bool IOPv3::Driver::setParkAz ( double  az)

Definition at line 560 of file ioptronv3driver.cpp.

◆ setPECEnabled()

bool IOPv3::Driver::setPECEnabled ( bool  enabled)

Definition at line 402 of file ioptronv3driver.cpp.

◆ setPETEnabled()

bool IOPv3::Driver::setPETEnabled ( bool  enabled)

Definition at line 407 of file ioptronv3driver.cpp.

◆ setRA()

bool IOPv3::Driver::setRA ( double  ra)

Definition at line 622 of file ioptronv3driver.cpp.

◆ setSimDE()

void IOPv3::Driver::setSimDE ( double  de)

Definition at line 224 of file ioptronv3driver.cpp.

◆ setSimGPSstatus()

void IOPv3::Driver::setSimGPSstatus ( IOP_GPS_STATUS  value)

Definition at line 189 of file ioptronv3driver.cpp.

◆ setSimGuideRate()

void IOPv3::Driver::setSimGuideRate ( double  raRate,
double  deRate 
)

Definition at line 229 of file ioptronv3driver.cpp.

◆ setSimHemisphere()

void IOPv3::Driver::setSimHemisphere ( IOP_HEMISPHERE  value)

Definition at line 214 of file ioptronv3driver.cpp.

◆ setSimLongLat()

void IOPv3::Driver::setSimLongLat ( double  longitude,
double  latitude 
)

Definition at line 235 of file ioptronv3driver.cpp.

◆ setSimRA()

void IOPv3::Driver::setSimRA ( double  ra)

Definition at line 219 of file ioptronv3driver.cpp.

◆ setSimSlewRate()

void IOPv3::Driver::setSimSlewRate ( IOP_SLEW_RATE  value)

Definition at line 204 of file ioptronv3driver.cpp.

◆ setSimSytemStatus()

void IOPv3::Driver::setSimSytemStatus ( IOP_SYSTEM_STATUS  value)

Definition at line 194 of file ioptronv3driver.cpp.

◆ setSimTimeSource()

void IOPv3::Driver::setSimTimeSource ( IOP_TIME_SOURCE  value)

Definition at line 209 of file ioptronv3driver.cpp.

◆ setSimTrackRate()

void IOPv3::Driver::setSimTrackRate ( IOP_TRACK_RATE  value)

Definition at line 199 of file ioptronv3driver.cpp.

◆ setSimulation()

void IOPv3::Driver::setSimulation ( bool  enable)

Definition at line 166 of file ioptronv3driver.cpp.

◆ setSlewRate()

bool IOPv3::Driver::setSlewRate ( IOP_SLEW_RATE  rate)

Definition at line 441 of file ioptronv3driver.cpp.

◆ setTrackEnabled()

bool IOPv3::Driver::setTrackEnabled ( bool  enabled)

Definition at line 613 of file ioptronv3driver.cpp.

◆ setTrackMode()

bool IOPv3::Driver::setTrackMode ( IOP_TRACK_RATE  rate)

Definition at line 451 of file ioptronv3driver.cpp.

◆ setUTCDateTime()

bool IOPv3::Driver::setUTCDateTime ( double  JD)

Definition at line 674 of file ioptronv3driver.cpp.

◆ setUTCOffset()

bool IOPv3::Driver::setUTCOffset ( int  offsetMinutes)

Definition at line 686 of file ioptronv3driver.cpp.

◆ slewCWUp()

bool IOPv3::Driver::slewCWUp ( )

Definition at line 600 of file ioptronv3driver.cpp.

◆ slewNormal()

bool IOPv3::Driver::slewNormal ( )

Definition at line 592 of file ioptronv3driver.cpp.

◆ startGuide()

bool IOPv3::Driver::startGuide ( IOP_DIRECTION  dir,
uint32_t  ms 
)

Definition at line 514 of file ioptronv3driver.cpp.

◆ startMotion()

bool IOPv3::Driver::startMotion ( IOP_DIRECTION  dir)

Definition at line 349 of file ioptronv3driver.cpp.

◆ stopMotion()

bool IOPv3::Driver::stopMotion ( IOP_DIRECTION  dir)

Definition at line 370 of file ioptronv3driver.cpp.

◆ sync()

bool IOPv3::Driver::sync ( )

Definition at line 608 of file ioptronv3driver.cpp.

◆ unpark()

bool IOPv3::Driver::unpark ( )

Definition at line 552 of file ioptronv3driver.cpp.

Member Data Documentation

◆ cw_state

IOP_CW_STATE IOPv3::Driver::cw_state

Definition at line 215 of file ioptronv3driver.h.

◆ day_light_saving

bool IOPv3::Driver::day_light_saving

Definition at line 212 of file ioptronv3driver.h.

◆ de

double IOPv3::Driver::de

Definition at line 207 of file ioptronv3driver.h.

◆ de_guide_rate

double IOPv3::Driver::de_guide_rate

Definition at line 209 of file ioptronv3driver.h.

◆ IOP_SLEW_RATES

const uint16_t IOPv3::Driver::IOP_SLEW_RATES = {1, 2, 8, 16, 64, 128, 256, 512, 1024}
static

Definition at line 92 of file ioptronv3driver.h.

◆ JD

double IOPv3::Driver::JD

Definition at line 210 of file ioptronv3driver.h.

◆ mb_limit

uint8_t IOPv3::Driver::mb_limit

Definition at line 213 of file ioptronv3driver.h.

◆ mb_state

IOP_MB_STATE IOPv3::Driver::mb_state

Definition at line 216 of file ioptronv3driver.h.

◆ models

const std::map< std::string, std::string > IOPv3::Driver::models
static
Initial value:
=
{
{"0010", "Cube II EQ"},
{"0011", "SmartEQ Pro+"},
{"0025", "CEM25"},
{"0026", "CEM26"},
{"0027", "CEM26-EC"},
{"0028", "GEM28"},
{"0029", "GEM28-EC"},
{"0030", "iEQ30 Pro"},
{"0040", "CEM40"},
{"0041", "CEM40-EC"},
{"0043", "GEM45"},
{"0045", "iEQ45 Pro EQ"},
{"0046", "iEQ45 Pro AA"},
{"0060", "CEM60"},
{"0061", "CEM60-EC"},
{"0070", "CEM70"},
{"0071", "CEM70-EC"},
{"0120", "CEM120"},
{"0121", "CEM120-EC"},
{"0122", "CEM120-EC2"},
{"5010", "Cube II AA"},
{"5035", "AZ Mount Pro"},
{"5045", "iEQ45 Pro AA"}
}

Definition at line 89 of file ioptronv3driver.h.

◆ pier_state

IOP_PIER_STATE IOPv3::Driver::pier_state

Definition at line 214 of file ioptronv3driver.h.

◆ ra

double IOPv3::Driver::ra

Definition at line 206 of file ioptronv3driver.h.

◆ ra_guide_rate

double IOPv3::Driver::ra_guide_rate

Definition at line 208 of file ioptronv3driver.h.

◆ 

struct { ... } IOPv3::Driver::simData

◆ simInfo

IOPInfo IOPv3::Driver::simInfo

Definition at line 218 of file ioptronv3driver.h.

◆ utc_offset_minutes

int IOPv3::Driver::utc_offset_minutes

Definition at line 211 of file ioptronv3driver.h.


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