M-File Help: RobotArm | View code for RobotArm

# RobotArm

Serial-link robot arm class

A subclass of SerialLink than includes an interface to a physical robot.

## Methods

plot | display graphical representation of robot
teach | drive the physical and graphical robots
mirror | use the robot as a slave to drive graphics
jmove | joint space motion of the physical robot
cmove | Cartesian space motion of the physical robot

plus all other methods of SerialLink

## Properties

as per SerialLink class

## Note

- the interface to a physical robot, the machine, should be an abstract

superclass but right now it isn't

- RobotArm is a subclass of SerialLink.
- RobotArm is a reference (handle subclass) object.
- RobotArm objects can be used in vectors and arrays

## Reference

- http://www.petercorke.com/doc/robotarm.pdf
- Robotics, Vision & Control, Chaps 7-9, P. Corke, Springer 2011.
- Robot, Modeling & Control, M.Spong, S. Hutchinson & M. Vidyasagar, Wiley 2006.

## See also

Machine, SerialLink, Link, DHFactor

# RobotArm.RobotArm

Construct a RobotArm object

ra = RobotArm(L, m, options) is a robot object defined by a vector of Link objects L with a physical robot interface m represented by an object of class Machine.

## Options

'name', name | set robot name property
'comment', comment | set robot comment property
'manufacturer', manuf | set robot manufacturer property
'base', base | set base transformation matrix property
'tool', tool | set tool transformation matrix property
'gravity', g | set gravity vector property
'plotopt', po | set plotting options property

## See also

SerialLink.SerialLink, Arbotix.Arbotix

# RobotArm.cmove

Cartesian space move

RA.cmove(T) moves the robot arm to the pose specified by the homogeneous transformation (4x4).

## Notes

- A joint-space trajectory is computed from the current configuration to QD using the jmove() method.
- If the robot is 6-axis with a spherical wrist inverse kinematics are computed using ikine6s() otherwise numerically using ikine().

## See also

RobotArm.jmove, Arbotix.setpath

# RobotArm.delete

Destroy the RobotArm object

RA.delete() closes and destroys the machine interface object and the RobotArm object.

# RobotArm.getq

Get the robot joint angles

q = RA.getq() is a vector (1xN) of robot joint angles.

## Notes

- If the robot has a gripper, its value is not included in this vector.

# RobotArm.gripper

Control the robot gripper

RA.gripper(C) sets the robot gripper according to C which is 0 for closed and 1 for open.

## Notes

- Not all robots have a gripper.
- The gripper is assumed to be the last servo motor in the chain.

# RobotArm.jmove

Joint space move

RA.jmove(qd) moves the robot arm to the configuration specified by the joint angle vector qd (1xN).

RA.jmove(qd, T) as above but the total move takes T seconds.

## Notes

- A joint-space trajectory is computed from the current configuration to QD.

## See also

RobotArm.cmove, Arbotix.setpath

# RobotArm.mirror

Mirror the robot pose to graphics

RA.mirror() places the robot arm in relaxed mode, and as it is moved by hand the graphical animation follows.

## See also

SerialLink.teach, SerialLink.plot

# RobotArm.teach

Teach the robot

RA.teach() invokes a simple GUI to allow joint space motion, as well as showing an animation of the robot on screen.

## See also

SerialLink.teach, SerialLink.plot

© 1990-2014 Peter Corke.