ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Adding NaoQI API to PYTHONPATH (v1.12)

asked 2012-03-01 10:50:34 -0500

greczek_USC gravatar image

updated 2014-01-28 17:11:33 -0500

ngrennan gravatar image

Hello, I am trying to set up ROS on my Nao robot. I keep getting the error: "Please make sure that Aldebaran's NaoQI API is in your PYTHONPATH." I found the answer below:

and executed

PYTHONPATH=/my/path/to/naoqi-sdk-1.12-linux32/lib:${PYTHONPATH} ,

with "/my/path/to" being the path to the SDK in my system, but the error did not go away. I am using naoqi-sdk-1.12-linux32, so is the path different for this newer version?

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted

answered 2012-03-06 01:05:42 -0500

SLAMnect gravatar image

updated 2012-03-16 06:30:48 -0500

AHornung gravatar image

Put this

export AL_DIR=/home/naokinect/nao1.12/naoqi-sdk-1.12-linux32

into your bashrc. Path to the lib may differ to your path. Works for me.

edit flag offensive delete link more



Using NaoQI 1.12.3 this seems to be fixed and the Python API only needs to be in the PYTHONPATH, no more need for LD_LIBRARY_PATH

AHornung gravatar image AHornung  ( 2012-04-10 07:18:16 -0500 )edit

answered 2012-03-16 06:27:31 -0500

AHornung gravatar image

As SLAMnect wrote, it seems like the NaoQI Python API in version 1.12 also seems to require LD_LIBRARY_PATH set in addition to the PYTHONPATH. But I would suggest against putting the complete directory always in your LD_LIBRARY_PATH in .bashrc. There are many other libraries in this directory and it will mess up your system with conflicting versions of boost for example.

Instead, put

export AL_DIR=$HOME/path/to/naoqi-sdk-1.12-linux32 

in your .bashrc and either start nao_driver with

LD_LIBRARY_PATH=$AL_DIR/lib roslaunch nao_driver nao_driver.launch

or run


only in the terminal where you run nao_driver.

edit flag offensive delete link more

answered 2012-06-08 01:11:06 -0500

dbworth gravatar image

updated 2012-06-08 01:11:40 -0500

8 June 2012
ROS Fuerte
NAOqi 1.12.3

To execute nao_driver I had to follow AHornung's post above, and edit both PYTHONPATH and pass LD_LIBRARY_PATH directly to roslaunch.

See here for a walk-through guide to installing ROS and NAOqi:

edit flag offensive delete link more

Question Tools


Asked: 2012-03-01 10:50:34 -0500

Seen: 1,689 times

Last updated: Jun 08 '12