2017-02-10 79 views
0

我有兩個樹莓派了3臺機器:監務工作的一個PI3而不是另一個PI3

  • raspberrypi01
  • raspberrypi05

與中興MF112 USB卡和英國3 SIM卡。

「05」PI3工作正常,但「01」PI1根本不起作用。請參見下面的命令的輸出:

[email protected]:/tmp $ sudo gammu identify 
Device    : /dev/ttyUSB1 
Manufacturer   : ZTE CORPORATION 
Model    : unknown (MF112) 
Firmware    : BD_P671A2V1.0.2B05 
IMEI     : 864592000347386 
SIM IMSI    : 234200208677663 
[email protected]:/tmp $ sudo gammu monitor 1 
Press Ctrl+C to break... 
Entering monitor mode... 

Enabling info about incoming SMS : No error. 
Enabling info about incoming CB  : No error. 
Enabling info about calls   : No error. 
Enabling info about USSD   : No error. 
SIM phonebook  : 0 used, 250 free 
Dialled numbers  : 10 used, 0 free 
Received numbers  : 0 used, 10 free 
Missed numbers  : 0 used, 10 free 
Own numbers   : 1 used, 5 free 
Phone phonebook  : 0 used, 100 free 
Battery level  : 100 percent 
Charge state   : powered from battery 
Signal strength  : -109 dBm 
Network level  : 6 percent 
SIM SMS status  : 0 used, 0 unread, 30 locations 
Phone SMS status  : 3 used, 0 unread, 100 locations 
Network state  : not logged into network 
Packet network state : not logged into network 
GPRS     : detached 

Leaving monitor mode... 
[email protected]:/tmp $ sudo gammu networkinfo 
Network state  : not logged into network 
Packet network state : not logged into network 
GPRS     : detached 
[email protected]:/tmp $ 

試圖在上面的一個發送短信給這個錯誤:

[email protected]:~ $ echo "Test from HA" | sudo gammu sendsms TEXT 05555555555 
If you want break, press Ctrl+C... 
Sending SMS 1/1....waiting for network answer..error 500, message reference=-1 
Unknown error. 

但是這一個工程:

[email protected]:~ $ sudo gammu identify 
Device    : /dev/ttyUSB1 
Manufacturer   : ZTE CORPORATION 
Model    : unknown (MF112) 
Firmware    : BD_P671A2V1.0.2B05 
IMEI     : 864592000347386 
SIM IMSI    : 234200208677663 
[email protected]:~ $ sudo gammu monitor 1 
Press Ctrl+C to break... 
Entering monitor mode... 

Enabling info about incoming SMS : No error. 
Enabling info about incoming CB  : No error. 
Enabling info about calls   : No error. 
Enabling info about USSD   : No error. 
SIM phonebook  : 0 used, 250 free 
Dialled numbers  : 10 used, 0 free 
Received numbers  : 0 used, 10 free 
Missed numbers  : 0 used, 10 free 
Own numbers   : 1 used, 5 free 
Phone phonebook  : 0 used, 100 free 
Battery level  : 100 percent 
Charge state   : powered from battery 
Signal strength  : -113 dBm 
Network level  : 0 percent 
SIM SMS status  : 0 used, 0 unread, 30 locations 
Phone SMS status  : 3 used, 0 unread, 100 locations 
Network state  : home network 
Network    : 234 20 (Three, United Kingdom), LAC 79, CID D6C8F0 
Name in phone  : "3 UK" 
Packet network state : home network 
Packet network  : 234 20 (Three, United Kingdom), LAC 79, CID D6C8F0 
Name in phone  : "3 UK" 
GPRS     : attached 

Leaving monitor mode... 
[email protected]:~ $ sudo gammu networkinfo 
Network state  : home network 
Network    : 234 20 (Three, United Kingdom), LAC 79, CID D6C8F0 
Name in phone  : "3 UK" 
Packet network state : home network 
Packet network  : 234 20 (Three, United Kingdom), LAC 79, CID D6C8F0 
Name in phone  : "3 UK" 
GPRS     : attached 

這一個正常工作:

[email protected]:~ $ echo "Test from HA" | sudo gammu sendsms TEXT 05555555555 
If you want break, press Ctrl+C... 
Sending SMS 1/1....waiting for network answer..OK, message reference=56 
[email protected]:~ $ 

「/root/.gammurc」上的內容爲:

[gammu] 

port = /dev/ttyUSB1 
model = at 
connection = at115200 
synchronizetime = yes 
logfile = /tmp/gammu.log 
logformat = textalldate 
use_locking = yes 
gammuloc = 

任何想法?

回答

0

問題是第一個設備沒有嘗試連接到網絡。這可能有幾個原因:

  • 它正在等待PIN碼,您可以使用gammu getsecuritystatus來檢查。
  • 它沒有被配置爲連接到網絡,這是一些中興通訊設備的問題,Gammu可以打開這個,但你的模型到目前爲止還沒有被識別(我已經在9740d70中修復了這個問題)。
  • SIM卡還有其他一些問題,它可以在其他設備上工作嗎?
相關問題