Solved

Cannot unlock device /dev/ttyS0

Posted on 2013-01-29
7
1,298 Views
Last Modified: 2013-03-07
I am using Gnokii to send alert that is done through a Mobile phone connected to the Linux server through USB cable, and I used “port = /dev/ttyS0” under gnokii setting.

It work for some time and stops with showing below error message

[root@monitor#] gnokii --identify
GNOKII Version 0.6.19
Telephone interface init failed: Command timed out.
Quitting.
Cannot unlock device.
Command timed out.


to make this work again, server has to restart or disconnect and connect Nokia phone again

Do you know what does this error means, and how to solve?

this is really an argent matter.

thanks
0
Comment
Question by:uknet80
  • 4
  • 2
7 Comments
 
LVL 11

Assisted Solution

by:un1x86
un1x86 earned 166 total points
ID: 38833909
Hi

What does your messages log file tell you when you connect your device? /var/log/messages. Also it would be good to know what Linux you are using.
0
 

Author Comment

by:uknet80
ID: 38833964
Log file doesn't show any thing, after it crush, I will even double check that for you.
But dmesg shows this:

cdc_acm 4-2:1.1: ttyACM0: USB ACM device

After I restarted the server it works and i get following message from "gnokii --identify"
[root@monitor ~]# gnokii --identify
GNOKII Version 0.6.19
IMEI         : 352042021632084
Manufacturer : Nokia
Model        : Nokia 6300
Product name : Nokia 6300
Revision     : V 05.50


After an hour it will crash and the message mentioned earlier appear.

Gnokii Setting:
[global]
#port = /dev/ttyS0
port = /dev/ttyACM0
model = AT
initlength = default
connection = serial
use_locking = no
serial_baudrate = 19200
smsc_timeout = 10
allow_breakage = 0
[gnokiid]
bindir = /usr/local/sbin/
[connect_script]
TELEPHONE = 12345678
[disconnect_script]
[logging]
debug = off
rlpdebug = off
xdebug = off



The version I am using is:
Linux is: RHEL5.7
Gnokii Version: GNOKII Version 0.6.19
0
 
LVL 34

Assisted Solution

by:Duncan Roe
Duncan Roe earned 334 total points
ID: 38846087
Note you are using /dev/ttyACM0 rather than /dev/ttyS0. This USB serial port may disappear if the USB connection is broken at which point it can be difficult for an application to unlock it.
You really need to increase logging so you can see what the USB device does. You could start by turning it on in your config above.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:uknet80
ID: 38878985
can you please explain to me what I need to do, I didn't understand:

You really need to increase logging so you can see what the USB device does. You could start by turning it on in your config above.
0
 
LVL 34

Accepted Solution

by:
Duncan Roe earned 334 total points
ID: 38879302
In your Gnokii Setting you have debug = off and I was suggesting you change that to debug = on.
Do you have the file /etc/syslog.conf? If you do, I strongly recommend you add the following lines to it
# Everything is logged here.
*.debug                                         -/var/log/debug

Open in new window

Remove any existing lines referring to /var/log/debug. After you do that, and issue the command pkill -HUP syslogd to get the file re-read, you will see in all USB connect and disconnect activity in /var/log/debug.
If you don't have /etc/syslog.conf then your system uses some other logging program which I can't help you with. Hopefully you can work out what to do.
0
 

Author Comment

by:uknet80
ID: 38960936
I've requested that this question be closed as follows:

Accepted answer: 0 points for uknet80's comment #a38878985
Assisted answer: 167 points for un1x86's comment #a38833909
Assisted answer: 167 points for duncan_roe's comment #a38846087
Assisted answer: 166 points for duncan_roe's comment #a38879302

for the following reason:

thanks for your continues supports
0
 

Author Closing Comment

by:uknet80
ID: 38960937
thanks for your support.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Currently, there is not an RPM package available under the RHEL/Fedora/CentOS distributions that gives you a quick and easy way to allow PHP to interface with Oracle. As a result, I have included a set of instructions on how to do this with minimal …
I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now