My Project
 All Classes Files Functions Variables Enumerations Enumerator Friends Macros Pages
gcp::antenna::control::ServoComms Class Reference
Inheritance diagram for gcp::antenna::control::ServoComms:
gcp::antenna::control::Board

Public Member Functions

 ServoComms (SpecificShare *share, std::string name, bool sim)
 
 ServoComms ()
 
 ~ServoComms ()
 
void setAzEl (gcp::util::Angle &az, gcp::util::Angle &el)
 
void hardStopAntenna ()
 
void haltAntenna ()
 
void calibrateEncoders ()
 
void initializeAntenna (int antNum=1)
 
void queryStatus ()
 
void queryStatus (gcp::util::TimeVal &currTime)
 
void queryAntPositions ()
 
void queryAntPositions (gcp::util::TimeVal &currTime)
 
bool readPosition (AxisPositions *axes, Model *model)
 
void commandNewPosition (PmacTarget *pmac)
 
void setMaxAzVel (int antNum, float vMax)
 
void finishInitialization ()
 
void fillUtc (gcp::util::TimeVal &currTime)
 
bool connect ()
 
void disconnect ()
 
bool servoIsConnected ()
 
void sendCommand (ServoCommand &command)
 
int readResponse (ServoCommand &command)
 
bool isBusy ()
 
bool isPpsPresent ()
 
bool isCalibrated ()
 
int checkTrackLoop ()
 
unsigned readPositionFault ()
 
int writeString (std::string message)
 
- Public Member Functions inherited from gcp::antenna::control::Board
 Board (SpecificShare *share, std::string name)
 
 Board (SpecificShare *share, gcp::util::AntNum ant)
 
 Board (SpecificShare *share)
 
 Board ()
 
virtual ~Board ()
 
RegMapBlock * findReg (char *name)
 
bool isReachable ()
 
virtual void reset ()
 
int getIndex ()
 
virtual void readRegNoLock (RegMapBlock *blk, unsigned int first, unsigned int nreg, unsigned int *value)
 
virtual void readReg (RegMapBlock *blk, unsigned int first, unsigned int nreg, unsigned int *value)
 
virtual void readReg (RegMapBlock *blk, unsigned int first, unsigned int nreg, float *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, signed char *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned char *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, signed short *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned short *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, int *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned int *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, float *value)
 
virtual void writeRegNoLock (RegMapBlock *blk, unsigned first, unsigned nreg, double *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, signed char *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned char *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, signed short *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned short *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, int *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, unsigned int *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, float *value)
 
virtual void writeReg (RegMapBlock *blk, unsigned first, unsigned nreg, double *value)
 

Public Attributes

int inactiveCount_
 
ServoCommand command_
 

Additional Inherited Members

- Protected Attributes inherited from gcp::antenna::control::Board
SpecificShareshare_
 
RegMapBoard * board_
 
bool hasBoard_
 

Constructor & Destructor Documentation

gcp::antenna::control::ServoComms::ServoComms ( SpecificShare share,
std::string  name,
bool  sim 
)

Constructor with pointer to shared resources.

ServoComms::ServoComms ( )

Constructor.

....................................................................... Constructor with no shared resources.

ServoComms::~ServoComms ( )

Destructor.

....................................................................... Destructor

Member Function Documentation

bool ServoComms::connect ( )

Connect to the servo.

Returns true on success.

....................................................................... Connect to the servo port.

void ServoComms::disconnect ( )

Disconnect from the servo.

....................................................................... Disconnect from the servo port.

void gcp::antenna::control::ServoComms::fillUtc ( gcp::util::TimeVal currTime)

Fill the utc register with the time stamps appropriate for the data just read back from the servo box

void gcp::antenna::control::ServoComms::finishInitialization ( )

last few steps of the initialization

int ServoComms::readResponse ( ServoCommand command)

Read a response from the SERVO. Does not check that a response is available, and may block waiting for one, depending on how the socket was configured.

....................................................................... Private version to read a response into our internal message container.

void ServoComms::sendCommand ( ServoCommand command)

Send a single command to the SERVO.

....................................................................... Send a command to the servo.

bool ServoComms::servoIsConnected ( )

Return true if the servo is connected.

....................................................................... Return true if we are connected to the servo.

void gcp::antenna::control::ServoComms::setAzEl ( gcp::util::Angle az,
gcp::util::Angle el 
)

Command set – commands called by higher functions

void gcp::antenna::control::ServoComms::setMaxAzVel ( int  antNum,
float  vMax 
)

set maximum velocity

int ServoComms::writeString ( std::string  message)

write message to serial port

....................................................................... write a message to the port

Member Data Documentation

ServoCommand gcp::antenna::control::ServoComms::command_

A not-so-private message container used for sending and receiving data from the SERVO. need it to be public to check the presence of 1PPS

int gcp::antenna::control::ServoComms::inactiveCount_

Count of how many consecutive messages communications have hung on


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