Skip to content
Adam Lukomski edited this page May 16, 2019 · 3 revisions

Welcome to the pyicub wiki!

Typical usage

Start the yarp

import yarp
import sys
sys.path.append('../../')

from pyicub.api.iCubHelper import iCub, ROBOT_TYPE
yarp.Network.init()

Starting a connection

To iCub simulation (by default hard-coded as /icubSim)

icub = iCub(ROBOT_TYPE.ICUB_SIMULATOR, logtype="DEBUG")

To an actual iCub: icub = iCub(ROBOT_TYPE.ICUB, logtype="DEBUG")

Using the Position Controller

Main robot parts and their configuration size:

    HEAD = iCubPart("head", 6)
    FACE = iCubPart("face", 1)
    LEFT_ARM = iCubPart("left_arm", 16)
    RIGHT_ARM = iCubPart("right_arm", 16)
    TORSO = iCubPart("torso", 3)
    LEFT_LEG = iCubPart("left_leg", 6)
    RIGHT_LEG = iCubPart("right_leg", 6)
Clone this wiki locally