From Wiki for iCub and Friends
Jump to navigation Jump to search
The correct title of this article is controlGaze. The initial letter is shown capitalized due to technical restrictions.

Author: Manuel Lopes

Module to perform saccades, smooth pursuit and VOR.

The input ports receives the target position (relative or absolute), it can be a position or a velocity reference. Then it computes the desired joint velocities and sends then to the /controlboard/ module.

For now the control gaze module is a controller and does not decide what to do. In the future it should include more behaviors, e.g. if it gets behind during a smooth pursuit it should decide to saccade.

When performing a saccade it sends a command to the egosphere to stop updating it and does not accept any new command until reaching the desired position, i.e. during a saccade the eyes are closed and no interruption is accepted.

During a smooth pursuit all new commands are accepted.

To compensate the VOR a forward model is used to distinguish between voluntary and involuntary motion and then compensate in the desired motion.

To go to a target position both eyes and neck move and an energy criteria is used to separate the motion among both.

It works for any neck/eye position by using the full analytic jacobian.

To summarize, this module accepts target locations and performs some calculations then sends the desired joint space commands to another module.

Back to iCub YARP module specifications

Compiler & Linker Dependencies


kinematics (iCub library)    

Run-time Dependencies

Module arguments

pidON 1 - use integral term in the control vorON 0 - use VOR egosphereVisualUpdateThreshold 0.01 - threshold to define the end of a saccade log 0 - write the log to a file

Input Ports

Ports that are assumed to exist prior to instantiation of the module (i.e. some other module must create them)

/control_gaze/conf                     //configuration
/control_gaze/imu                      //inertial information
/control_gaze/pos                      //desired saccade target
/control_gaze/vel                      //desired smooth pursuit target
/control_gaze/dis  //disparity

Output Ports

Ports that are instantiated by the module and are then available for other modules to use (using yarp connect)


/control_gaze/trackersignal/bot:o               // signal the tracker to restart

Input data files


Output data files

log.txt for logging trajectories. This is a useful debug tool for the controllers. It just dumps all the values to a text file that can be read from the matlab to plot nice figures. It should be disable when running a real demo as it is consuming computer resources.

Configuration files

[CONTROLGAZE] pidON 1 vorON 0 egosphereVisualUpdateThreshold 0.01 log 0

User interface mechanism

Run-time modification of module parameters None

OS on which the module was developed

Windows XP

OS on which the module was tested

Windows XP

Operating system dependencies

For now we are testing it with JrKerr control boards, and not the official iCub boards. Should be an easy transitions apart from some controller gains.

Example instantiation of the module

Run & port connection commands

REM Copyright (C) 2007 Jonas Ruesch
REM CopyPolicy: Released under the terms of the GNU GPL v2.0.

REM Simple example instantiation.
REM You need to adapt values between <> according to your environment in order to make this work.
REM The module configuration is loaded from a file specified by the --file option. To create this file
REM have a look at the default terminal output of the module. A module reports it's option keys 
REM and default values on startup. Some modules require an additional option --group which specifies
REM the name of the configuration group within the configuration file (specify without []).
REM We assume you compiled in release mode.

:: Start module
start <ICUB_DIR>\bin\release\controlGaze.exe --remoteEgoSphere </chica/egosphere/conf> --name /iCub/controlGaze

:: Connect source
yarp wait /iCub/controlGaze/pos
yarp connect </iCub/attentionSelection/o:position> /iCub/controlGaze/pos

See also iCub/scripts/startChicaGazeControl.bat

iCub Capabilities

iCub capability code

C11  Saccadic direction of gaze towards salient events (visual, auditory, tactile)
C12  Focus attention and direct gaze on human faces (features, movements, sounds)
C13  Ocular modulation of head pose so that head pose is adjusted to centre eye gaze
C17  Stabilization of gaze with respect to self-motion (VOR) 
C24  Fixation and vergence
C25  Gaze control: smooth pursuit (with prediction); possibly tuned by learning

Other Yarp modules required to effect this capability


Example instantiation

The given script startChicaGazeControl.bat is an example of the instantiation of capabilities C11, C12, and C13

Back to iCub YARP module specifications