Check here:
http://smslib.org/doc/smslib/troubleshooting/#Linux_and_undetectable_ports

The /dev/USB0 may not be directly detected.

On 23 March 2013 04:56, Kurniawan Junaidy via SMSLib Discussion Group <
smslib+noreply-apn2wqcgnm1a3agruc0grzbmqejoirijp5g9i4btkbtoe0...@googlegroups.com
> wrote:

> Hi all. I'm using smslib 3.5.3, rxtx 2.1.7 and wavecom M1306B. I try to
> run simple connection as follows:
>
> SerialModemGateway gateway = new SerialModemGateway("modem-1",
> "/dev/ttyUSB0", 115200, "Huawei", "");
> Service.getInstance().addGateway(gateway);
> Service.getInstance().startService();
>
> But i got errors:
>
> 0      2013-03-23 09:48:55,803 [main] INFO  org.smslib.Service  - SMSLib:
> A Java API library for sending and receiving SMS via a GSM modem or other
> supported gateways.
> This software is distributed under the terms of the Apache v2.0 License.
> Web Site: http://smslib.org
> 3      2013-03-23 09:48:55,806 [main] INFO  org.smslib.Service  - Version:
> 3.5.3
> 3      2013-03-23 09:48:55,806 [main] INFO  org.smslib.Service  - JRE
> Version: 1.6.0_30
> 5      2013-03-23 09:48:55,808 [main] INFO  org.smslib.Service  - JRE Impl
> Version: 20.5-b03
> 5      2013-03-23 09:48:55,808 [main] INFO  org.smslib.Service  - O/S:
> Linux / i386 / 3.2.0-25-generic-pae
> 8      2013-03-23 09:48:55,811 [main] INFO
>  org.smslib.queues.DefaultQueueManager  - Queue directory not defined.
> Queued messages will not be saved to filesystem.
> 9      2013-03-23 09:48:55,812 [main] DEBUG
> org.smslib.threading.AServiceThread  - Initialized.
> 10     2013-03-23 09:48:55,813 [NotifyQueueManager] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 10     2013-03-23 09:48:55,813 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager running...
> 10     2013-03-23 09:48:55,813 [main] DEBUG
> org.smslib.threading.AServiceThread  - Initialized.
> 10     2013-03-23 09:48:55,813 [DelayQueueManager] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 10     2013-03-23 09:48:55,813 [DelayQueueManager] DEBUG
> org.smslib.queues.AbstractQueueManager$DelayQueueManager  -
> DelayQueueManager running...
> 11     2013-03-23 09:48:55,814 [main] DEBUG
> org.smslib.threading.AServiceThread  - Initialized.
> 11     2013-03-23 09:48:55,814 [WatchDog] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 12     2013-03-23 09:48:55,815 [Thread-4] INFO
>  org.smslib.modem.ModemGateway  - GTW: modem-1: Starting gateway, using
> Huawei (Generic) AT Handler.
> 12     2013-03-23 09:48:55,815 [Thread-4] INFO
>  org.smslib.modem.SerialModemDriver  - GTW: modem-1: Opening: /dev/ttyUSB0
> @115200
> Stable Library
> =========================================
> Native lib Version = RXTX-2.1-7
> Java lib Version   = RXTX-2.1-7
> 288    2013-03-23 09:48:56,091 [Thread-4] DEBUG
> org.smslib.threading.AServiceThread  - Initialized.
> 288    2013-03-23 09:48:56,091 [KeepAlive [modem-1]] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 289    2013-03-23 09:48:56,092 [Thread-4] DEBUG
> org.smslib.threading.AServiceThread  - Initialized.
> 289    2013-03-23 09:48:56,092 [CNMIEmulatorProcessor [modem-1]] DEBUG
> org.smslib.threading.AServiceThread  - ** disabled **
> 290    2013-03-23 09:48:56,093 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver$ModemReader  - GTW: modem-1: ModemReader
> thread started.
> 292    2013-03-23 09:48:56,095 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver$AsyncNotifier  - GTW: modem-1: AsyncNotifier
> thread started.
> 293    2013-03-23 09:48:56,096 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver$AsyncMessageProcessor  - GTW: modem-1:
> AsyncMessageProcessor thread started.
> 294    2013-03-23 09:48:56,097 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: clearBuffer() called.
> 1294   2013-03-23 09:48:57,097 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :(27)
> 1498   2013-03-23 09:48:57,301 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :+++
> 1699   2013-03-23 09:48:57,502 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :ATZ(cr)
> 1900   2013-03-23 09:48:57,703 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: clearBuffer() called.
> 2900   2013-03-23 09:48:58,703 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :ATZ(cr)
> 3101   2013-03-23 09:48:58,904 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :ATE0(cr)
> 3302   2013-03-23 09:48:59,105 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: clearBuffer() called.
> 4303   2013-03-23 09:49:00,106 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: SEND :AT+CPIN?(cr)
> 15011  2013-03-23 09:49:10,814 [WatchDog] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 30012  2013-03-23 09:49:25,815 [WatchDog] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 30289  2013-03-23 09:49:26,092 [CNMIEmulatorProcessor [modem-1]] DEBUG
> org.smslib.threading.AServiceThread  - ** disabled **
> 45012  2013-03-23 09:49:40,815 [WatchDog] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 49305  2013-03-23 09:49:45,108 [Thread-4] DEBUG
> org.smslib.modem.AModemDriver  - GTW: modem-1: Buffer contents on timeout:
> 49305  2013-03-23 09:49:45,108 [KeepAlive [modem-1]] DEBUG
> org.smslib.threading.AServiceThread  - Stopped.
> 49305  2013-03-23 09:49:45,108 [CNMIEmulatorProcessor [modem-1]] DEBUG
> org.smslib.threading.AServiceThread  - Stopped.
> 49306  2013-03-23 09:49:45,109 [SMSLib-AsyncNotifier : modem-1] DEBUG
> org.smslib.modem.AModemDriver$AsyncNotifier  - GTW: modem-1: AsyncNotifier
> thread ended.
> 49306  2013-03-23 09:49:45,109 [SMSLib-AsyncMessageProcessor : modem-1]
> DEBUG org.smslib.modem.AModemDriver$AsyncMessageProcessor  - GTW: modem-1:
> AsyncMessageProcessor thread ended.
> 49306  2013-03-23 09:49:45,109 [SMSlib-ModemReader-modem-1] DEBUG
> org.smslib.modem.AModemDriver$ModemReader  - GTW: modem-1: ModemReader
> thread ended.
> 49406  2013-03-23 09:49:45,209 [Thread-4] INFO
>  org.smslib.modem.SerialModemDriver  - GTW: modem-1: Closing: /dev/ttyUSB0
> @115200
> 50019  2013-03-23 09:49:45,822 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager end...
> 50019  2013-03-23 09:49:45,822 [DelayQueueManager] DEBUG
> org.smslib.queues.AbstractQueueManager$DelayQueueManager  -
> DelayQueueManager end...
> 50120  2013-03-23 09:49:45,923 [NotifyQueueManager] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 50120  2013-03-23 09:49:45,923 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager running...
> 50220  2013-03-23 09:49:46,023 [WatchDog] DEBUG
> org.smslib.threading.AServiceThread  - Stopped.
> 50221  2013-03-23 09:49:46,024 [main] INFO  org.smslib.modem.ModemGateway
>  - GTW: modem-1: Stopping gateway...
> 50221  2013-03-23 09:49:46,024 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager end...
> 50221  2013-03-23 09:49:46,024 [main] INFO
>  org.smslib.modem.SerialModemDriver  - GTW: modem-1: Closing: /dev/ttyUSB0
> @115200
> 50222  2013-03-23 09:49:46,025 [main] INFO  org.smslib.modem.ModemGateway
>  - GTW: modem-1: Gateway stopped.
> 50322  2013-03-23 09:49:46,125 [NotifyQueueManager] DEBUG
> org.smslib.threading.AServiceThread  - Running...
> 50322  2013-03-23 09:49:46,125 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager running...
> 50322  2013-03-23 09:49:46,125 [NotifyQueueManager] DEBUG
> org.smslib.notify.NotifyQueueManager$NotificationQueueManager  -
> NotifyQueueManager end...
> 50422  2013-03-23 09:49:46,225 [NotifyQueueManager] DEBUG
> org.smslib.threading.AServiceThread  - Stopped.
> Exception in thread "main" org.smslib.TimeoutException: No response from
> device.
> at org.smslib.modem.AModemDriver$CharQueue.get(AModemDriver.java:535)
> at org.smslib.modem.AModemDriver.getResponse(AModemDriver.java:338)
> at org.smslib.modem.AModemDriver.getResponse(AModemDriver.java:313)
> at org.smslib.modem.athandler.ATHandler.getSimStatus(ATHandler.java:145)
> at org.smslib.modem.AModemDriver.connect(AModemDriver.java:132)
> at org.smslib.modem.ModemGateway.startGateway(ModemGateway.java:189)
> at org.smslib.Service$1Starter.run(Service.java:277)
> Experimental:  JNI_OnLoad called.
>
> Anybody know how to solve this problem?
>
>  --
> You received this message because you are subscribed to the Google Groups
> "SMSLib Discussion Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/smslib?hl=en.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/smslib/-/ogyGXb5yAxoJ.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"SMSLib Discussion Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/smslib?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to