I installed cwiid to my raspberry pi 4
(sudo apt-get install python-cwiid
)
and it worked, but when I try to import it into a python file
import cwiid
, it says ModuleNotFoundError: No module named 'cwiid'
(I've also tried import python-cwiid
but that gave me a syntax error)
Asked
Active
Viewed 710 times
0

Kate
- 31
- 1
- 5
-
Have you tried running it sans `sudo`? – Johnny May 10 '20 at 01:05
-
It says permission is denied. I already ran it with sudo and it installed fine, it is just not working when I try to import it into a python file – Kate May 10 '20 at 05:56
1 Answers
1
pip install cwiid
install in your virtual environment.

sandeshdaundkar
- 883
- 1
- 7
- 14
-
then you should be able to import , check if this one helps https://stackoverflow.com/questions/56738196/installing-cwiid-with-python-3-extension – sandeshdaundkar May 10 '20 at 06:15
-
I finally was able to import after moving the files to /usr/lib/python3/dist-packages (it was in python2.7 before). However when I wanted to use it in my code it said that nothing could be found in the module. So I manually deleted it and now I am getting errors trying to reinstall with the line 'pip install cwiid'. – Kate May 10 '20 at 20:22