RoboidControl
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
Passer::RoboidControl::Roboid Class Reference

A Roboid is used to control autonomous robots. More...

#include <Roboid.h>

Public Member Functions

 Roboid ()
 Default constructor for a Roboid.
 
 Roboid (Perception *perception, Propulsion *propulsion=nullptr)
 Creates a Roboid with Perception and Propulsion abilities.
 
 Roboid (Perception *perception, ServoMotor *actuationRoot)
 
 Roboid (ServoMotor *actuationRoot)
 
void Update (float currentTimeMs)
 Update the state of the Roboid.
 
virtual Vector3 GetPosition ()
 Retrieve the current position of the roboid.
 
Vector2 GetPosition2D ()
 
virtual Quaternion GetOrientation ()
 Retrieve the current orientation of the roboid.
 
float GetOrientation2D ()
 
virtual void SetPosition (Vector3 worldPosition)
 Update the current position of the roboid.
 
virtual void SetOrientation (Quaternion worldOrientation)
 Update the current orientation of the roboid.
 
void SetOrientation2D (float angle)
 

Public Attributes

Perceptionperception = nullptr
 The Perception module of this Roboid.
 
Propulsionpropulsion = nullptr
 The Propulsion module of this Roboid.
 
ServoMotor * actuationRoot = nullptr
 
NetworkSyncnetworkSync = nullptr
 The reference to the module to synchronize states across a network.
 

Detailed Description

A Roboid is used to control autonomous robots.

Constructor & Destructor Documentation

◆ Roboid() [1/4]

Roboid::Roboid ( )

Default constructor for a Roboid.

◆ Roboid() [2/4]

Roboid::Roboid ( Perception perception,
Propulsion propulsion = nullptr 
)

Creates a Roboid with Perception and Propulsion abilities.

Parameters
perceptionThe Perception implementation to use for this Roboid
propulsionThe Propulsion implementation to use for this Roboid

◆ Roboid() [3/4]

Roboid::Roboid ( Perception perception,
ServoMotor *  actuationRoot 
)

◆ Roboid() [4/4]

Roboid::Roboid ( ServoMotor *  actuationRoot)

Member Function Documentation

◆ Update()

void Roboid::Update ( float  currentTimeMs)

Update the state of the Roboid.

Parameters
currentTimeMsThe time in milliseconds when calling this function

◆ GetPosition()

Vector3 Roboid::GetPosition ( )
virtual

Retrieve the current position of the roboid.

Returns
The position in carthesian coordinates in world space

The origin and units of the position depends on the position tracking system used. This value will be Vector3::zero unless a position is received through network synchronisation

◆ GetPosition2D()

Vector2 Roboid::GetPosition2D ( )

◆ GetOrientation()

Quaternion Roboid::GetOrientation ( )
virtual

Retrieve the current orientation of the roboid.

Returns
The orientation quaternion in world space

The origin orientation depends on the position tracking system used. This value will be Quaternion::identity unless an orientation is received though network synchronization

◆ GetOrientation2D()

float Roboid::GetOrientation2D ( )

◆ SetPosition()

void Roboid::SetPosition ( Vector3  worldPosition)
virtual

Update the current position of the roboid.

Parameters
worldPositionThe position of the roboid in carthesian coordinates in world space

The use of this function will also update the positions and orientations of the perceived objects by the roboid (roboid->perception->perceivedObjects), as these are local to the roboid's position.

◆ SetOrientation()

void Roboid::SetOrientation ( Quaternion  worldOrientation)
virtual

Update the current orientation of the roboid.

Parameters
worldOrientationThe orientation of the roboid in world space

The use of this function will also update the orientations of the perceived objects by the roboid (roboid->perception->perceivedObjets), as these are local to the roboid' orientation.

◆ SetOrientation2D()

void Roboid::SetOrientation2D ( float  angle)

Member Data Documentation

◆ perception

Perception* Passer::RoboidControl::Roboid::perception = nullptr

The Perception module of this Roboid.

◆ propulsion

Propulsion* Passer::RoboidControl::Roboid::propulsion = nullptr

The Propulsion module of this Roboid.

◆ actuationRoot

ServoMotor* Passer::RoboidControl::Roboid::actuationRoot = nullptr

◆ networkSync

NetworkSync* Passer::RoboidControl::Roboid::networkSync = nullptr

The reference to the module to synchronize states across a network.


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