UniversalServo Class Reference

PID Servo motor for universal joints. More...

#include <universalservo.h>

Collaboration diagram for UniversalServo:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 UniversalServo (UniversalJoint *joint, double min1, double max1, double power1, double min2, double max2, double power2)
 min and max values are understood as travel bounds.
void set (double position1, double position2)
 sets the set point of the servo.
double get1 ()
 returns the position of the hinge in ranges [-1, 1] (scaled by min, max)
double get2 ()
 returns the position of the hinge in ranges [-1, 1] (scaled by min, max)
void get (double &p1, double &p2)
 returns the position of the hinge in ranges [-1, 1] (scaled by min, max)
void setPower (double power1, double power2)

Private Attributes

PID pid1
PID pid2
double min1
double max1
double min2
double max2
UniversalJointjoint

Detailed Description

PID Servo motor for universal joints.


Constructor & Destructor Documentation

UniversalServo UniversalJoint joint,
double  min1,
double  max1,
double  power1,
double  min2,
double  max2,
double  power2
 

min and max values are understood as travel bounds.

power is the power of the servo


Member Function Documentation

void get double &  p1,
double &  p2
 

returns the position of the hinge in ranges [-1, 1] (scaled by min, max)

double get1  ) 
 

returns the position of the hinge in ranges [-1, 1] (scaled by min, max)

double get2  ) 
 

returns the position of the hinge in ranges [-1, 1] (scaled by min, max)

void set double  position1,
double  position2
 

sets the set point of the servo.

Position must be between -1 and 1. It is scaled to fit into min, max

void setPower double  power1,
double  power2
 


Member Data Documentation

UniversalJoint* joint [private]
 

double max1 [private]
 

double max2 [private]
 

double min1 [private]
 

double min2 [private]
 

PID pid1 [private]
 

PID pid2 [private]
 


The documentation for this class was generated from the following files:
Generated on Tue Jan 16 02:14:50 2007 for Robotsystem of the Robot Group Leipzig by doxygen 1.3.8