de.jaetzold.art.platform
Interface ServoPeer

All Superinterfaces:
ActuatorPeer, MotorPeer, SensorPeer, StepperMotorPeer

public interface ServoPeer
extends StepperMotorPeer

A Peer representing a servo motor.

A Servo is a device which has control over the absolute position of an axle. It is calibrated so that it knows what one turn of the axle means and where a specific angle is. It is possible (and for a usual servo motor very likely) that not all angles are reachable.


Method Summary
 void calibrate()
          Give the servo a chance to calibrate.
 AngleSensor getAngleSensor()
          The AngleSensor for measuring the position.
 void setAngleSensor(AngleSensor sensor)
          Set's the AngleSensor to use for measuring the position.
 
Methods inherited from interface de.jaetzold.art.platform.StepperMotorPeer
getCountSensor, getSpeed, setCountSensor, setSpeed, step
 
Methods inherited from interface de.jaetzold.art.platform.MotorPeer
getBackward, getPower, isOn, setBackward, setOn, setPower
 
Methods inherited from interface de.jaetzold.art.platform.ActuatorPeer
setValue, setValue
 
Methods inherited from interface de.jaetzold.art.platform.SensorPeer
addPropertyChangeListener, disableEvent, enableEvent, getDeliversFloatingPoint, getPrecision, getValue, isConnected, processEvent, removePropertyChangeListener, update
 

Method Detail

getAngleSensor

public AngleSensor getAngleSensor()
The AngleSensor for measuring the position.

setAngleSensor

public void setAngleSensor(AngleSensor sensor)
Set's the AngleSensor to use for measuring the position. This may involve a substancial decrease in speed and precision and is therefore not a good idea for now. It is more for a future use.

calibrate

public void calibrate()
Give the servo a chance to calibrate. This is meant as a hint that it would do no harm if it takes some time now to calibrate if necessary. If the Peer can't decide by itself whether calibration is necessary this should also be interpreted as a hint that the precision is getting worse.