Python client application SIM7000C of NB-IOT module on Raspberry Pi, SIM7000C終端應用運行在樹莓派上, SIM7000C NB-IoT/LTE/GPRS 擴展板模組, CHT SIM card(大卡) 採用中華電信CAT. M1(門市申請即可, 據說已經改為企業才可申請) 我使用的SIM7000C NB-IoT HAT串口似乎有問題(/dev/ttyAMA0), 無法使用UART只能用USB port(/dev/ttyUSB3) SIM7000C NB-IoT HAT與Raspberry pi通訊時要注意SIM7000C模組速度較慢, 注意反饋訊息的檢查, 否則會採坑!!!
sudo nano /etc/lightdm/lightdm.conf
- [SeatDefaults]
- ...
- #xserver-command=X #Change to as below
- xserver-command=X -s 0 –dpms
- ...
sudo nano /home/pi/.config/autostart/autoboot.desktop
-
...
-
[Desktop Entry]
-
Type=Application
-
Name=MyApplicationRun
-
#Exec = lxterminal -e /home/pi/autorun.sh #運行掛機 applivcation close aftern run 5day
-
Exec = lxterminal -e "bash -c /home/pi/autorun.sh;bash" #運行測試(Stay Bash)
-
Icon=pictur.png
-
... or
-
[Desktop Entry]
-
Encoding=UTF-8
-
Type=Application
-
Name=myprogram
-
Exec=lxterminal -e bash -c '/home/pi/autorun.sh;$SHELL' #bash run autorun.sh
-
Terminal=true
-
...
-
sudo nano /home/pi/autorun.sh
-
...
-
python3 SIM7000_CHT.py
-
...