Home > Software engineering >  "No module name adafruit_servokit"
"No module name adafruit_servokit"

Time:09-10

I am working on Jetson Nano and trying to control servo motors. I am using PCA9685. I have installed all the pre-requisites for that

sudo pip3 install adafruit-circuitpython-servokit

Faced an error called

SyntaxError: future feature annotations is not defined

i updated python for that and the issue was resolved. Now the issue is that when i use python 3.8 as an interpreter in Visual studio i face the error

No module name adafruit_servokit

But when i use the python 3.6, the adafruit_servokit error is solved and the annotation error arises. Looking forward to every suggestion. Thank you

CodePudding user response:

This is because you have conflicting interpreters for your python installation.

Inside your Visual Studio terminal, try using:

python3.8 -m pip install adafruit-circuitpython-servokit

Using python -m pip install instead of just pip install is recommended. The reason is that it will use the correct interpreter for your python installation, specially if you have many versions installed. More details here: https://snarky.ca/why-you-should-use-python-m-pip/

---EDIT---

You should replace python3.8 with your target version number.

  • Related