Python 2.7 Raspberry Pi(Python):使用SIM800L发送短信 树莓皮3 Python 2.7
嗨! 我在连接gsm模块时出错 这是我从你那里得到的密码 以下是错误:Python 2.7 Raspberry Pi(Python):使用SIM800L发送短信 树莓皮3 Python 2.7,python-2.7,raspberry-pi3,gsm,sim800,Python 2.7,Raspberry Pi3,Gsm,Sim800,嗨! 我在连接gsm模块时出错 这是我从你那里得到的密码 以下是错误: OSError: [Errno 11] Resource temporarily unavailable raise SerialException('device reports readiness to read but returned no data (device disconnected?)') serial.serialutil.SerialException: device reports readines
OSError: [Errno 11] Resource temporarily unavailable
raise SerialException('device reports readiness to read but returned no data (device disconnected?)')
serial.serialutil.SerialException: device reports readiness to read but returned no data (device disconnected?)
raise SerialException('write failed: %s' % (v,))
serial.serialutil.SerialException: write failed: [Errno 5] Input/output error
有时它会发出
Hello User
Login incorrect
raspberrypi login:
有时
>
>
>
(100+ more '>')
Hello User
但它几乎总是不连接,并给出错误11
你也经历过吗?
在继续发送消息之前,是否有办法等待gsm连接?您是否已断开uart与内部蓝牙和内核控制台的连接 如果不这样做,您将在访问设备时遇到问题。您需要禁用使用它的服务:
sudo systemctl disable hciuart
还禁用该uart上的内核控制台
console=serial0,115200
从内核命令行(/boot/cmdline.txt)。您需要在设备树(/boot/config.txt)上启用两个覆盖,也许这可以帮助您:
dtoverlay=pi3-disable-bt
dtoverlay=pi3-miniuart-bt
rasberrypi.org提供的完整解决方案:您是否已断开uart与内部蓝牙和内核控制台的连接?也许这可以帮助你:
dtoverlay=pi3-disable-bt
dtoverlay=pi3-miniuart-bt