Проблема
pi@raspberrypi:/~ $ sudo wvdial
--> WvDial: Internet dialer version 1.61
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: ATQ0 V1 E1 S0=0 &C1 &D2
ATQ0 V1 E1 S0=0 &C1 &D2
OK
--> Modem initialized.
--> Sending: ATDT07********
--> Waiting for carrier.
ATDT07********
NO CARRIER
--> No Carrier! Trying again.
--> Sending: ATDT07********
--> Waiting for carrier.
ATDT07********
NO CARRIER
--> No Carrier! Trying again.
--> Sending: ATDT07********
--> Waiting for carrier.
ATDT07********
NO CARRIER
--> No Carrier! Trying again.
sudo wvdialconf
pi@raspberrypi:/~ $ sudo wvdialconf
Editing `/etc/wvdial.conf'.
Scanning your serial ports for a modem.
ttyUSB0: ATQ0 V1 E1 -- OK
ttyUSB0: ATQ0 V1 E1 Z -- OK
ttyUSB0: ATQ0 V1 E1 S0=0 -- OK
ttyUSB0: ATQ0 V1 E1 S0=0 &C1 -- OK
ttyUSB0: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK
ttyUSB0: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- ERROR
ttyUSB0: Modem Identifier: ATI -- Manufacturer: huawei
ttyUSB0: Speed 9600: AT -- OK
ttyUSB0: Max speed is 9600; that should be safe.
ttyUSB0: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK
ttyUSB1: ATQ0 V1 E1 -- failed with 2400 baud, next try: 9600 baud
ttyUSB1: ATQ0 V1 E1 -- failed with 9600 baud, next try: 9600 baud
ttyUSB1: ATQ0 V1 E1 -- and failed too at 115200, giving up.
ttyUSB2: ATQ0 V1 E1 -- OK
ttyUSB2: ATQ0 V1 E1 Z -- OK
ttyUSB2: ATQ0 V1 E1 S0=0 -- OK
ttyUSB2: ATQ0 V1 E1 S0=0 &C1 -- OK
ttyUSB2: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK
ttyUSB2: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- ERROR
ttyUSB2: Modem Identifier: ATI -- Manufacturer: huawei
ttyUSB2: Speed 9600: AT -- OK
ttyUSB2: Max speed is 9600; that should be safe.
ttyUSB2: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK
Found a modem on /dev/ttyUSB0.
Modem configuration written to /etc/wvdial.conf.
ttyUSB0: Speed 9600; init "ATQ0 V1 E1 S0=0 &C1 &D2"
ttyUSB2: Speed 9600; init "ATQ0 V1 E1 S0=0 &C1 &D2"
Приведенные выше сведения говорят о том, что я могу использовать ttyUSB0 или ttyUSB2 для отправки смс
lsusb Здесь ключ определяется как модем
pi@raspberrypi:/~ $ lsusb
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 009: ID 12d1:1001 Huawei Technologies Co., Ltd. E161/E169/E620/E800 HSDPA Modem
Bus 001 Device 003: ID 09da:054f A4Tech Co., Ltd.
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
/ etc / wvdial.conf
[Dialer Defaults]
Init1 = ATZ
Init2 = ATQ0 V1 E1 S0=0 &C1 &D2
Modem Type = Analog Modem
ISDN = 0
New PPPD = yes
Phone = 07********
Modem = /dev/ttyUSB0
Username = etisalat
Password = etisalat
Baud = 9600