Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1251

Python • Re: Problems in the venv environment

$
0
0
I'm getting this error message after installing gpio, lgpio, and RPi.GPIO

I first installed the gpio package, but that gave me a lot of error messages while typing in the python prompt

Code:

red = LED(17)
Because I saw in the error message that lgpio and RPi were missing, I installed those two packages

Its now only giving me this error message

Code:

Traceback (most recent call last):File "<stdin>", line 1, in <module>NameError: name 'LED' is not defined

If that is Line #1 then I think you have omitted the import of the library or module that defines LED.

Statistics: Posted by B.Goode — Fri Feb 14, 2025 12:25 pm



Viewing all articles
Browse latest Browse all 1251

Trending Articles