PhidgetAdvancedServo |
A class for controlling a PhidgetAdvancedServo. See your product manual for more specific API details, supported functionality, units, etc.
| PhidgetAdvancedServo | A class for controlling a PhidgetAdvancedServo. |
| Events | Events supported by PhidgetAdvancedServo. |
| Constants | |
| Servo Types | These are the some predefined servo motors. |
| Properties | |
| MotorCount | Gets the number of motors supported by this controller. |
| Functions | |
| getAccelerationMin | Gets the minimum settable acceleration for a motor. |
| getAccelerationMax | Gets the maximum settable acceleration for a motor. |
| getPositionMin | Gets the minimum position that a motor can go to. |
| getPositionMax | Gets the maximum position that a motor can go to. |
| getVelocityMin | Gets the minimum velocity that a motor can be set to. |
| getVelocityMax | Gets the maximum velocity that a motor can be set to. |
| getAcceleration | Gets the last acceleration that a motor was set to. |
| getVelocity | Gets the current velocity of a motor |
| getVelocityLimit | Gets the last velocity limit that a motor was set to. |
| getCurrent | Gets the current current that a motor is drawing. |
| getPosition | Gets the current position of a motor. |
| getEngaged | Gets the engaged state of a motor. |
| getStopped | Gets the stopped state of a motor. |
| getSpeedRampingOn | Gets the speed ramping state of the motor. |
| getServoType | Gets the servo motor type. |
| setAcceleration | Sets the acceleration of a motor. |
| setVelocityLimit | Sets the velocity limit of a motor. |
| setPosition | Sets the position of a motor. |
| setPositionMax | Sets the maximum position that a motor can be set to. |
| setPositionMin | Sets the minimum position that a motor can be set to. |
| setEngaged | Sets the engaged state of a motor. |
| setSpeedRampingOn | Sets the speed ramping state of a motor. |
| setServoType | Sets the servo type |
| setServoParameters | Sets the servo parameters |
These are the some predefined servo motors. Setting one of these will set degree-PCM ratio, min and max angle, and max velocity. Custom servo parameters can be set with the setServoParameters function.
public function setServoParameters( index: int, minUs: Number, maxUs: Number, degrees: Number, velocityMax: Number ):void
Sets the servo parameters
| index | motor index |
| minUs | minimum PCM in microseconds |
| maxUs | maximum PCM in microseconds |
| degrees | total range of motion in degrees |
| velocityMax | maximum velocity of servo in degrees/second |
Gets the number of motors supported by this controller.
public function get MotorCount():int
Gets the minimum settable acceleration for a motor.
public function getAccelerationMin( index: int ):Number
Gets the maximum settable acceleration for a motor.
public function getAccelerationMax( index: int ):Number
Gets the minimum position that a motor can go to.
public function getPositionMin( index: int ):Number
Gets the maximum position that a motor can go to.
public function getPositionMax( index: int ):Number
Gets the minimum velocity that a motor can be set to.
public function getVelocityMin( index: int ):Number
Gets the maximum velocity that a motor can be set to.
public function getVelocityMax( index: int ):Number
Gets the last acceleration that a motor was set to.
public function getAcceleration( index: int ):Number
Gets the current velocity of a motor
public function getVelocity( index: int ):Number
Gets the last velocity limit that a motor was set to.
public function getVelocityLimit( index: int ):Number
Gets the current current that a motor is drawing.
public function getCurrent( index: int ):Number
Gets the current position of a motor.
public function getPosition( index: int ):Number
Gets the engaged state of a motor.
public function getEngaged( index: int ):Boolean
Gets the stopped state of a motor.
public function getStopped( index: int ):Boolean
Gets the speed ramping state of the motor.
public function getSpeedRampingOn( index: int ):Boolean
Gets the servo motor type.
public function getServoType( index: int ):int
Sets the acceleration of a motor.
public function setAcceleration( index: int, val: Number ):void
Sets the velocity limit of a motor.
public function setVelocityLimit( index: int, val: Number ):void
Sets the position of a motor.
public function setPosition( index: int, val: Number ):void
Sets the maximum position that a motor can be set to.
public function setPositionMax( index: int, val: Number ):void
Sets the minimum position that a motor can be set to.
public function setPositionMin( index: int, val: Number ):void
Sets the engaged state of a motor.
public function setEngaged( index: int, val: Boolean ):void
Sets the speed ramping state of a motor.
public function setSpeedRampingOn( index: int, val: Boolean ):void
Sets the servo type
public function setServoType( index: int, val: int ):void
Sets the servo parameters
public function setServoParameters( index: int, minUs: Number, maxUs: Number, degrees: Number, velocityMax: Number ):void