Public Member Functions | Static Public Attributes | Private Types | Private Attributes

openjaus::mobility::SetLocalVector Class Reference

SetLocalVector Message Implementation. More...

#include <SetLocalVector.h>

Inherits openjaus::model::Message.

List of all members.

Public Member Functions

 SetLocalVector ()
 SetLocalVector (model::Message *message)
 ~SetLocalVector ()
virtual int to (system::Buffer *dst)
 Pack this message to the given openjaus::system::Buffer.
virtual int from (system::Buffer *src)
 Unpack this message from the given openjaus::system::Buffer.
virtual int length ()
 Get the number of bytes this message would occupy in a serialized buffer.
std::string toXml (unsigned char level=0) const
 Used to serialize the runtime state of the message to an XML format.
void setPresenceVector (uint8_t value)
uint8_t getPresenceVector (void) const
bool isSpeedEnabled (void) const
void enableSpeed (void)
void disableSpeed (void)
bool isAltitudeEnabled (void) const
void enableAltitude (void)
void disableAltitude (void)
bool isHeadingEnabled (void) const
void enableHeading (void)
void disableHeading (void)
bool isRollEnabled (void) const
void enableRoll (void)
void disableRoll (void)
bool isPitchEnabled (void) const
void enablePitch (void)
void disablePitch (void)
double getSpeed_mps (void)
void setSpeed_mps (double value)
double getAltitude_m (void)
void setAltitude_m (double value)
double getHeading_rad (void)
void setHeading_rad (double value)
double getRoll_rad (void)
void setRoll_rad (double value)
double getPitch_rad (void)
void setPitch_rad (double value)

Static Public Attributes

static const uint16_t ID = 0x0408

Private Types

enum  pvEnum {
  SPEED_MPS = 0, ALTITUDE_M = 1, HEADING_RAD = 2, ROLL_RAD = 3,
  PITCH_RAD = 4
}

Private Attributes

LinearSpeedScaledInteger speed_mps
JausAltitudeScaledInteger altitude_m
OrientationScaledInteger heading_rad
OrientationScaledInteger roll_rad
OrientationScaledInteger pitch_rad
uint8_t presenceVector

Detailed Description

This message is used to set the driving vector based on the local coordinate system. Field #2 sets the desired speed of the platform. The desired heading angle is set in field #4 and is defined in a right hand sense about the Z axis of the local coordinate system (the Z axis points downward) where zero degrees defines a heading that is parallel to the X axis of the local coordinate system.


Member Enumeration Documentation

Enumerator:
SPEED_MPS 
ALTITUDE_M 
HEADING_RAD 
ROLL_RAD 
PITCH_RAD 

Constructor & Destructor Documentation

openjaus::mobility::SetLocalVector::SetLocalVector (  ) 
openjaus::mobility::SetLocalVector::SetLocalVector ( model::Message message  ) 
openjaus::mobility::SetLocalVector::~SetLocalVector (  ) 

Member Function Documentation

void openjaus::mobility::SetLocalVector::disableAltitude ( void   ) 
void openjaus::mobility::SetLocalVector::disableHeading ( void   ) 
void openjaus::mobility::SetLocalVector::disablePitch ( void   ) 
void openjaus::mobility::SetLocalVector::disableRoll ( void   ) 
void openjaus::mobility::SetLocalVector::disableSpeed ( void   ) 
void openjaus::mobility::SetLocalVector::enableAltitude ( void   ) 
void openjaus::mobility::SetLocalVector::enableHeading ( void   ) 
void openjaus::mobility::SetLocalVector::enablePitch ( void   ) 
void openjaus::mobility::SetLocalVector::enableRoll ( void   ) 
void openjaus::mobility::SetLocalVector::enableSpeed ( void   ) 
int openjaus::mobility::SetLocalVector::from ( system::Buffer src  )  [virtual]

src - The source openjaus::system::Buffer from which this message will be unpacked.

Returns:
The number of bytes unpacked from the source buffer

Reimplemented from openjaus::model::Message.

double openjaus::mobility::SetLocalVector::getAltitude_m ( void   ) 
double openjaus::mobility::SetLocalVector::getHeading_rad ( void   ) 
double openjaus::mobility::SetLocalVector::getPitch_rad ( void   ) 
uint8_t openjaus::mobility::SetLocalVector::getPresenceVector ( void   )  const
double openjaus::mobility::SetLocalVector::getRoll_rad ( void   ) 
double openjaus::mobility::SetLocalVector::getSpeed_mps ( void   ) 
bool openjaus::mobility::SetLocalVector::isAltitudeEnabled ( void   )  const
bool openjaus::mobility::SetLocalVector::isHeadingEnabled ( void   )  const
bool openjaus::mobility::SetLocalVector::isPitchEnabled ( void   )  const
bool openjaus::mobility::SetLocalVector::isRollEnabled ( void   )  const
bool openjaus::mobility::SetLocalVector::isSpeedEnabled ( void   )  const
int openjaus::mobility::SetLocalVector::length ( void   )  [virtual]

The number of bytes this message would occupy in a buffer

Reimplemented from openjaus::model::Message.

void openjaus::mobility::SetLocalVector::setAltitude_m ( double  value  ) 
void openjaus::mobility::SetLocalVector::setHeading_rad ( double  value  ) 
void openjaus::mobility::SetLocalVector::setPitch_rad ( double  value  ) 
void openjaus::mobility::SetLocalVector::setPresenceVector ( uint8_t  value  ) 
void openjaus::mobility::SetLocalVector::setRoll_rad ( double  value  ) 
void openjaus::mobility::SetLocalVector::setSpeed_mps ( double  value  ) 
int openjaus::mobility::SetLocalVector::to ( system::Buffer dst  )  [virtual]

dst - The destination openjaus::system::Buffer to which this message will be packed.

Returns:
The number of bytes packed into the destination buffer

Reimplemented from openjaus::model::Message.

std::string openjaus::mobility::SetLocalVector::toXml ( unsigned char  level = 0  )  const

level - Used to determine how many tabs are inserted per line for pretty formating.

Returns:
The serialized XML string

Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines