I am trying to import a module to control the LED in the button of the voice AIY. I have version 2 of the kit. Using both the v2 instructions and the v1 instructions, I get an ImportError
when trying to import the packages. The v2 instructions say to run from aiy.leds import Leds, Color
, and the v1 instructions say to use from aiy.board import Board, Led
Am I incorrectly trying to import the module, or missing it entirely? If it is missing, can I download the necessary module, or do I have to re-flash the image entirely?
pi@raspberrypi:/opt/aiy/projects-python/src $ python3 main.py
Importing packages...
Importing LED...
Traceback (most recent call last):
File "main.py", line 454, in <module>
from aiy.board import Board, Led
ImportError: No module named 'aiy.board'
pi@raspberrypi:/opt/aiy/projects-python/src $ sudo nano main.py
pi@raspberrypi:/opt/aiy/projects-python/src $ python3 main.py
Importing packages...
Importing LED...
Traceback (most recent call last):
File "main.py", line 458, in <module>
from aiy.leds import Leds, Color
ImportError: No module named 'aiy.leds'