Simple controller class for Stinger Robot without using Robotics Connection board.

Embed: (wiki syntax)

« Back to documentation index

Robot Class Reference

Robot class. More...

#include <Robot.h>

Public Member Functions

 Robot ()
 Constructor.
virtual ~Robot ()
 Destructor.
void MoveStraightPulses (float s, int clix)
 Move Straight.
void MoveStraightInches (float speed, float in)
 Move Straight.
void MoveStraightRotations (float speed, float rotations)
 Move Straight.
void StopLeft ()
 Stop Left Wheel.
void StopRight ()
 Stop Right Wheel.
void Stop ()
 Stop.
void PivetLeft (float deg)
 Pivet left.
void PivetRight (float deg)
 Pivet right.
int IsBusy ()
 Returns 0 if robot is not moving Returns 1 otherwise.

Protected Member Functions

void Call ()
 Ticker function.

Detailed Description

Robot class.

Definition at line 30 of file Robot.h.


Constructor & Destructor Documentation

Robot (  )

Constructor.

Definition at line 17 of file Robot.cpp.

~Robot (  ) [virtual]

Destructor.

Definition at line 36 of file Robot.cpp.


Member Function Documentation

void Call (  ) [protected]

Ticker function.

Definition at line 156 of file Robot.cpp.

int IsBusy (  )

Returns 0 if robot is not moving Returns 1 otherwise.

Returns:
flat

Definition at line 151 of file Robot.cpp.

void MoveStraightInches ( float  speed,
float  in 
)

Move Straight.

Parameters:
speedspeed between -1.0 and 1.0
inNumber of inches to move

Definition at line 64 of file Robot.cpp.

void MoveStraightPulses ( float  s,
int  clix 
)

Move Straight.

Parameters:
sspeed between -1.0 and 1.0
clixNumber of pulses to move

Definition at line 48 of file Robot.cpp.

void MoveStraightRotations ( float  speed,
float  rotations 
)

Move Straight.

Parameters:
seedspeed between -1.0 and 1.0
rotationsNumber of wheel rotations to move

Definition at line 68 of file Robot.cpp.

void PivetLeft ( float  deg )

Pivet left.

Parameters:
degdegrees

Definition at line 117 of file Robot.cpp.

void PivetRight ( float  deg )

Pivet right.

Parameters:
degdegrees

Definition at line 134 of file Robot.cpp.

void Stop (  )

Stop.

Definition at line 72 of file Robot.cpp.

void StopLeft (  )

Stop Left Wheel.

Definition at line 77 of file Robot.cpp.

void StopRight (  )

Stop Right Wheel.

Definition at line 88 of file Robot.cpp.