我想在运行Debian的Raspberry Pi上用Python 2.6访问串口。 我叫serial.py脚本尝试导入pySerial: import serial
ser = serial.Serial('/dev/ttyAMA0', 9600)
ser.write("hello world!")
出于某种原因,拒绝建立与此错误的串行连接:当我试图在交互式Python键入相同的代码 At
我是python的新手,我已经为我的Raspberry Pi上的GPIO引脚编写了一些代码,但是当我运行它时, : [email protected]:~$ sudo python change.py
Which GPIO do you whant to change? 13
Exit (y/n) n
Traceback (most recent call last):
File