RuntimeError: No access to /dev/mem

后端 未结 1 1242
-上瘾入骨i
-上瘾入骨i 2021-01-24 17:38

I have been trying to use the Python GPIO PWM to control a set of LEDs connected to my RPi. When I run the Python script, I get the following error:

Traceback (m         


        
1条回答
  •  闹比i
    闹比i (楼主)
    2021-01-24 17:53

    The problem is with the code above is that I forgot to set RED to at output before trying to use it. The error message did not help resolve this problem. Next time, I need to remember to setup PWM pins as outputs before trying to use them.

    0 讨论(0)
提交回复
热议问题