增加4G启动脚本 #36
pcf80c552
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
不知道不同版本固件的4G模块会不会工作正常 我以前发现9011固件(就是插卡自动联网的固件) ModemManager 不会识别出来 |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
4G脚本
nano ~/start-modem-gui.sh
粘贴以下内容:
bash
复制
编辑
#!/bin/bash
启用 4G 模块
uconsole-4g-cm4 enable
等待硬件初始化(可视情况调整等待时间)
sleep 3
重启 ModemManager 服务
sudo systemctl restart ModemManager
启动 ModemManager GUI
modem-manager-gu
🔧 2. 添加执行权限
bash
复制
编辑
chmod +x ~/start-modem-gui.sh
🔧 3. 创建桌面图标
bash
复制
编辑
nano ~/.local/share/applications/start-modem-gui.desktop
内容如下:
ini
复制
编辑
[Desktop Entry]
Name=4G Manager
Exec=/home/pi/start-modem-gui.sh
Icon=network-cellular
Type=Application
Terminal=true
Categories=Network;
完成后,可在“开始菜单”或“Internet”类菜单中找到这个图标,点它即可一键启动 ModemManager GUI 并自动准备好 4G 模块。
Beta Was this translation helpful? Give feedback.
All reactions