2013-08-16 95 views
0

我試圖通過標準GSM USB調制解調器在Debain Squeeze 6.0.3 64位上使用gnokii-smsd-pgsql發送和接收批量SMS。通過USB調制解調器和gnokii-smsd-pgsql發送/接收批量短信

我下面從以下站點說明: http://thelogbox.com/send-receive-sms-messages-usb-modem-linux/

我已經在我的機器上安裝的Postgres,所以我用gnokii-SMSD-pgsql的。

[email protected]:/dev$ sudo apt-get install gnokii-smsd-pgsql 
Reading package lists... Done 
Building dependency tree  
Reading state information... Done 
gnokii-smsd-pgsql is already the newest version. 
0 upgraded, 0 newly installed, 0 to remove and 378 not upgraded. 
[email protected]:/dev$ sudo apt-get install gnokii-smsd-pgsql 
Reading package lists... Done 
Building dependency tree  
Reading state information... Done 
gnokii-smsd-pgsql is already the newest version. 
0 upgraded, 0 newly installed, 0 to remove and 378 not upgraded. 

當我試圖找到調制解調器連接在哪個端口上,這是我得到:

[email protected]:~$ sudo lsusb 
[sudo] password for shalin: 
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub 
Bus 004 Device 002: ID 1a86:7523 QinHeng Electronics HL-340 USB-Serial adapter 
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub 
Bus 003 Device 003: ID 0461:0010 Primax Electronics, Ltd 
Bus 003 Device 002: ID 093a:2510 Pixart Imaging, Inc. Optical Mouse 
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub 
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub 
Bus 001 Device 007: ID 19d2:0154 ONDA Communication S.p.A. 
Bus 001 Device 006: ID 058f:6366 Alcor Micro Corp. Multi Flash Reader 
Bus 001 Device 002: ID 04e8:3426 Samsung Electronics Co., Ltd SCX-4500 Laser Printer 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub 
[email protected]:~$ 

該設備是:昂達通訊SPA

[email protected]:~$ sudo dmesg | grep USB 
[ 0.471217] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver 
[ 0.471311] ehci_hcd 0000:00:1d.7: new USB bus registered, assigned bus number 1 
[ 0.475052] uhci_hcd: USB Universal Host Controller Interface driver 
[ 0.487912] ehci_hcd 0000:00:1d.7: USB 2.0 started, EHCI 1.00 
[ 0.487956] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002 
[ 0.487960] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1 
[ 0.488073] hub 1-0:1.0: USB hub found 
[ 0.488148] uhci_hcd 0000:00:1d.0: new USB bus registered, assigned bus number 2 
[ 0.488195] usb usb2: New USB device found, idVendor=1d6b, idProduct=0001 
[ 0.488197] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1 
[ 0.488257] hub 2-0:1.0: USB hub found 
[ 0.489428] uhci_hcd 0000:00:1d.1: new USB bus registered, assigned bus number 3 
[ 0.489495] usb usb3: New USB device found, idVendor=1d6b, idProduct=0001 
[ 0.489497] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1 
[ 0.489559] hub 3-0:1.0: USB hub found 
[ 0.490862] uhci_hcd 0000:00:1d.2: new USB bus registered, assigned bus number 4 
[ 0.490916] usb usb4: New USB device found, idVendor=1d6b, idProduct=0001 
[ 0.490918] usb usb4: New USB device strings: Mfr=3, Product=2, SerialNumber=1 
[ 0.490981] hub 4-0:1.0: USB hub found 
[ 0.491031] uhci_hcd 0000:00:1d.3: new USB bus registered, assigned bus number 5 
[ 0.491082] usb usb5: New USB device found, idVendor=1d6b, idProduct=0001 
[ 0.491084] usb usb5: New USB device strings: Mfr=3, Product=2, SerialNumber=1 
[ 0.491141] hub 5-0:1.0: USB hub found 
[ 0.803706] usb 1-1: new high speed USB device using ehci_hcd and address 2 
[ 0.937425] usb 1-1: New USB device found, idVendor=04e8, idProduct=3426 
[ 0.937431] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3 
[ 1.268016] usb 1-7: new high speed USB device using ehci_hcd and address 6 
[ 1.401680] usb 1-7: New USB device found, idVendor=058f, idProduct=6366 
[ 1.401683] usb 1-7: New USB device strings: Mfr=1, Product=2, SerialNumber=3 
[ 1.406441] Initializing USB Mass Storage driver... 
[ 1.406635] scsi4 : SCSI emulation for USB Mass Storage devices 
[ 1.406703] USB Mass Storage support registered. 
[ 1.640040] usb 4-2: new full speed USB device using uhci_hcd and address 2 
[ 1.803952] usb 4-2: New USB device found, idVendor=1a86, idProduct=7523 
[ 1.803957] usb 4-2: New USB device strings: Mfr=0, Product=2, SerialNumber=0 
[ 1.803961] usb 4-2: Product: USB2.0-Ser! 
[ 2.044018] usb 3-1: new low speed USB device using uhci_hcd and address 2 
[ 2.218546] usb 3-1: New USB device found, idVendor=093a, idProduct=2510 
[ 2.218552] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0 
[ 2.218557] usb 3-1: Product: USB OPTICAL MOUSE 
[ 2.524518] usb 3-2: new low speed USB device using uhci_hcd and address 3 
[ 2.701552] usb 3-2: New USB device found, idVendor=0461, idProduct=0010 
[ 2.701558] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0 
[ 2.701562] usb 3-2: Product: USB Keyboard 
[ 3.125256] usblp0: USB Bidirectional printer dev 2 if 1 alt 0 proto 2 vid 0x04E8 pid 0x3426 
[ 3.140601] USB Serial support registered for generic 
[ 3.140639] usbserial: USB Serial Driver core 
[ 3.163516] USB Serial support registered for ch341-uart 
[ 3.176282] usb 4-2: ch341-uart converter now attached to ttyUSB0 
[ 3.476799] input: PIXART USB OPTICAL MOUSE as /devices/pci0000:00/0000:00:1d.1/usb3/3-1/3-1:1.0/input/input4 
[ 3.476877] generic-usb 0003:093A:2510.0001: input,hidraw0: USB HID v1.11 Mouse [PIXART USB OPTICAL MOUSE] on usb-0000:00:1d.1-1/input0 
[ 3.491755] input: NOVATEK USB Keyboard as /devices/pci0000:00/0000:00:1d.1/usb3/3-2/3-2:1.0/input/input5 
[ 3.491808] generic-usb 0003:0461:0010.0002: input,hidraw1: USB HID v1.10 Keyboard [NOVATEK USB Keyboard] on usb-0000:00:1d.1-2/input0 
[ 3.525651] input: NOVATEK USB Keyboard as /devices/pci0000:00/0000:00:1d.1/usb3/3-2/3-2:1.1/input/input6 
[ 3.525714] generic-usb 0003:0461:0010.0003: input,hidraw2: USB HID v1.10 Device [NOVATEK USB Keyboard] on usb-0000:00:1d.1-2/input1 
[ 3.525736] usbhid: v2.6:USB HID core driver 
[ 1636.760031] usb 1-5: new high speed USB device using ehci_hcd and address 7 
[ 1636.893751] usb 1-5: New USB device found, idVendor=19d2, idProduct=0154 
[ 1636.893756] usb 1-5: New USB device strings: Mfr=3, Product=2, SerialNumber=4 
[ 1636.896329] scsi5 : SCSI emulation for USB Mass Storage devices 
[ 1641.897006] scsi 5:0:0:0: CD-ROM   ZTE  USB SCSI CD-ROM 2.31 PQ: 0 ANSI: 2 
[email protected]:~$ 

我應該聲明我有一段時間沒有在Linux系統上,並開始懷疑爲什麼我不知道爲什麼我不知道調制解調器映射到哪個/ dev /文件夾的主要原因是因爲我使用的是舊版本的Debian。

我按照指令創建並編輯了配置文件。文件位於:

/home/shalin/.config/ 

編輯爲:

port = /dev/tty0 

和:

model = AT 

最後,當我嘗試使用測試:

sudo gnokii --identify 

gnokii ISN」甚至在提示符的可能命令中列出。 Tab只能用於gnome,所以我甚至不認爲gnokii已經安裝。

正如你所看到的,我不知道什麼是錯的,以及我應該做什麼。任何幫助將不勝感激。

Regards, Shalin。

回答

2
  1. 我相信你還沒有安裝gnokii。 smsd不是gnokii。只需apt-get install gnokii,然後嘗試從命令行運行gnokii --identify

  2. 此外,您還必須確保端口是您的調制解調器連接到的確切端口。當我插入我的調制解調器,並做了dmesg它沒有列出它,但幸運的是我只有6個USB端口,所以我只嘗試了所有這些,直到我找到了正確的。在我的配置文件中的行是:

端口=的/ dev/ttyUSB3

的末數量將根據該端口的不同而不同。

3. http://rolfblijleven.blogspot.nl/2013/01/raspberry-pi-as-sms-gateway.html

相關問題