user3419556 user3419556 - 7 months ago 44
Python Question

Installing Python SDK for NAO robots

I'm trying to follow the documentation provided by Aldebaran here in order to get my NAO ready for Python programming. I correctly dowloaded the NAOqi framework adapted to my OS (linux 64 bits) then I typed the command line

$ export PYTHONPATH=${PYTHONPATH}:/path/to/python-sdk
which, if I understand things right, should be typed in a terminal and not in a Python shell.

Then I typed
import naoqi
in a Python shell and got the
ImportError: No module named naoqi
error, so I tried troubleshooting and typed

import sys
print "\n".join(sys.path)

in the same Python sheel and got that :


so I indeed don't have
as I shoud but not I'm blocked. What should I do to solve that ?

I will add that I am new to Linux, Python and NAO so I'm sorry if the answer is actually obvious.

I have been trying to configurate my NAO for Python programming for almost 1 week so I really feel retarded. I need your help please.


Suppose you have naoqi installed in /home/user/naoqi

1.- Open a text editor (Kate, Gedit,... whatever)

2.- Open the file /home/user/.profile

3.- At the end of the file, add the following line

export PYTHONPATH=${PYTHONPATH}:/home/user/naoqi

4.- Reboot (Close your session and login again also works, but just to be sure)

NOTE: Remember to change /home/user/naoqi with the correct path