Software interface: standard port names for hardware devices
From Wiki for RobotCub and Friends
Contents |
Motor Control and Encoders
We have identified 6 robot parts: head, left_arm, right_arm, torso, left_leg and right_leg.
Each part has three ports for: rpc, straming input, streaming output.
All ports have are named using a prefix, followed by rpc:i, command:i, state:o respectively for rpc, streaming input and streaming output.
Prefixes for each part are:
/icub/head /icub/left_arm /icub/right_arm /icub/torso /icub/left_leg /icub/right_leg
More information about the robot joints and parts are reported here: ICub_joints
Motor encoders
Motor encoders are streamed on the port:
/icub/<part>/state:o
Data format: a vector containing all joints of the part (see ICub_joints), units are degrees.
Sensors
Cameras
Images from the two eyes are available in rgb format from the ports:
/icub/cam/left /icub/cam/right
Data format: Yarp ImageOf<PixelRgb>, size depending on the framegrabber resolution.
Microphones
Data from the microphones is available on the port:
/icub/mics
Inertial sensor
Data from the inertial sensor is available on the port:
/icub/inertial
Data format: a vector of 12 values:
0:2 :euler angles roll, pitch yaw (degrees) 3:5 :calibrated acceleration along X,Y,Z (m/s^2) 6:8 :calibrated rate of turn (gyro), along X,Y,Z axes (rad/s) 9:11 :calibrated magnetic field X,Y,Z (arbitrary units)
More information about the sensor, data format and reference system are reported here: MTx specs.
Force/Torque Sensor
Six axis torque sensors on the arms (available only on iCub 1.1) are streamed on:
/icub/left_arm/analog:o /icub/right_arm/analog:o
Data format: a vector of 6 floating point numbers.
0:2 :forces 3:5 :torques
Reference frames to be determined.
Skin
Important: the skin interface is still under development and subject to changes.
If your robot is equipped with tactile sensors this information is available through ports. In particular the ports:
/icub/skin/lefthand /icub/skin/righthand
stream the most recent reading of the 102 sensors in each hands.
To visualize the data from the skin you can use the SkinGui tool (see documentation http://eris.liralab.it/iCub/dox/html/group__icub__iCubSkinGui.html).
Other actuators and sensors
Finger encoders
On each hand finger positions are streamed out on the following ports (available only on iCub 1.1):
/icub/right_hand/analog:o /icub/left_hand/analog:o
A vector of 15 floating point numbers, each corresponding to finger joints.
Facial expressions
Facial expressions are accessible through the following ports:
/icub/face/raw: low level interface /icub/face/emotions: high level interface
Low level interface
On /icub/face/raw you have access to the low level interface. This port accepts rpc commands to control individual devices (eyelids, mounth ...).
We skip details here, more can be found in Expression control.
High level interface
On /icub/face/emotions you have access through rpc to a higher level interface that allows controlling all devices together to produce facial expressions.
We report here a short summary:
rpc commands to /icub/face/emotions are
set <subsystem> <emotion> get <subsystem>
<subsystem> can be: mou, eli, leb, reb, all
<emotion> can be: neu, tal, hap, sad, sur ,evi, ang, shy, cun
For example:
yarp rpc /icub/face/emotions set mou hap set eli hap set all sad
More details are available here Expression control.

