Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
04-08-2006, 12:42 AM
|
#1
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Rep:
|
Keep my Nokia 8210 IrDA on
Hello,everyone.
I am using Nokia 8210 as a GSM modem at home via gnokii.However,when I use Nokia 8210,the IrDA will shut down if there are no data communication within 2 minutes.As a result,I wrote a shell script to send some message like gnokii --getnetworkinfo to keep the phone's IrDA busy.It seems to work for a while.However,when I tested it last whole night,it generated some error message say like "interface failed..."
My question is,how can I keep my Nokia 8210 IrDA on forever except I stop it?Any ideas are appreciated.
|
|
|
04-08-2006, 02:46 AM
|
#2
|
Member
Registered: Sep 2004
Location: CA, USA
Distribution: Slackware 10.2
Posts: 132
Rep:
|
I'd look more in to how to operate your phone, since what you're doing is pretty much all you can do on the GNU/Linux side. Unless you can reprogram your phone from your GNU/Linux distribution....
|
|
|
04-08-2006, 06:20 AM
|
#3
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
d0odman,thanks for your reply.
As far as I know,it's quite impossible for me to "reprogram" my mobile phone because it's very complicated.
I just can't figure out why my method is successful by half.It seemed fine at the beginning of 10 or so minutes.But it caused error after that.
|
|
|
04-08-2006, 12:22 PM
|
#4
|
Member
Registered: Sep 2004
Location: CA, USA
Distribution: Slackware 10.2
Posts: 132
Rep:
|
Can you post your shell script please?
|
|
|
04-09-2006, 02:19 AM
|
#5
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
Quote:
#/bin/sh
persist_connect=1
while [ persist_connect==1 ]
do
gnokii --getnetworkinfo
sleep 15
done
|
Something like that,I can't really remember.However,I don't think the problem lies on the script.It lies on either gnokii package or phone problem.
Thank you anyway.
|
|
|
04-09-2006, 04:46 AM
|
#6
|
Member
Registered: Sep 2004
Location: CA, USA
Distribution: Slackware 10.2
Posts: 132
Rep:
|
I think you should look more in to how to operate your phone. If sending out that command every 15 seconds doesn't keep your IR active, there's something else going on.
How long does it take that command to finish? If it takes longer than 15 seconds, then you'd miss one loop of your while, and after you're able to see the third one and are able to send it again, your IR connection could have already shut down. Try increasing the sleep time to 30 or something.
|
|
|
04-10-2006, 08:12 AM
|
#7
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
d0odman,thanks for your reply.
Quote:
How long does it take that command to finish? If it takes longer than 15 seconds, then you'd miss one loop of your while, and after you're able to see the third one and are able to send it again, your IR connection could have already shut down. Try increasing the sleep time to 30 or something.
|
I definitely think that the script will not take more than 15 seconds except there are errors.By the way,if you increase the sleep time,I think the connection will be lost easily.As you said,if the first script has problem or process longer than expected,say like a minute or 2.When you increase the sleep time,the connection will be lost.
d0odman,have you ever played around with gnokii?I don't know whether they have some method to connect the mobile phone consistently.Maybe a cable should work.However,I am not sure whether my phone can be connected with serial cable or something.Or most importantly,I can't easily buy it in Hong Kong because this phone is too old in this rapidly changing world.
Thanks for your great help.I can't really get any reply from the official supporting e-mail from gnokii. :-{
Last edited by Swift&Smart; 04-10-2006 at 08:14 AM.
|
|
|
04-10-2006, 04:48 PM
|
#8
|
Member
Registered: Sep 2004
Location: CA, USA
Distribution: Slackware 10.2
Posts: 132
Rep:
|
Development teams are usually very busy doing other things,and put out some shady documentation at best a lot of the time. I haven't used gnokii, but I can look in to it, now that I have an IR capable phone :P I'll check in to it later tonight, hopefully, for you.
|
|
|
04-11-2006, 12:34 AM
|
#9
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
Quote:
I haven't used gnokii, but I can look in to it, now that I have an IR capable phone :P I'll check in to it later tonight, hopefully, for you.
|
Thanks a million!
d0odman,someone replied to my question in the mailing list.He doubted that my mobile phone terminated the IrDA connection and he suggested me to write a script which writes data to the phonebook and delete it back and forth.I'll try it by tonight.However,I am quite skeptic about this method because it's doing quite the same task as mine.It keeps sending data to the mobile phone and make it busy.Anyway,I'll try every method.
|
|
|
04-14-2006, 11:21 PM
|
#10
|
Member
Registered: Sep 2004
Location: CA, USA
Distribution: Slackware 10.2
Posts: 132
Rep:
|
I finally looked in to the gnokii project, and it seems that my phone is not supported. I have a Motorola L7 (SLVR), the US model that has the iTunes firmware. I've been trying to figure out a way to access and upload music to it, but since it's a pretty new piece of hardware, there is not a lot of support for it yet. There's a way to use iTunes over wine, I believe, but that's just not gonna cut it for me.
Oh yeah, I also incorrectly assumed that the phone comes with an IR port, and I think there's no wrapper to use the built in bluetooth capabilities of the phone with gnokii.
|
|
|
04-15-2006, 12:45 AM
|
#11
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
d0odman,thanks for your reply.
Sadly,I've given up to fix this problem and waste my time.I use my Motorola V500 with USB cable and it works fine.
|
|
|
04-16-2006, 12:59 PM
|
#12
|
Senior Member
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
|
Quote:
Originally Posted by Swift&Smart
Hello,everyone.
... the IrDA will shut down if there are no data communication within 2 minutes. ...
|
2 min. == 120 sec. Try sleep 100 -- I think you may be overwhelming the phone w/ your keep alive commands.
2nd possibility, any chance it's the modem link (phone to ISP) that is being shut down, not the IrDA link (computer to phone)? If so, a ping every 100 sec. might be the solution.
BTW, your script could be simplified:
|
|
|
04-16-2006, 01:28 PM
|
#13
|
Member
Registered: Jan 2003
Location: Hong Kong,China
Distribution: Slackware,OpenSUSE
Posts: 472
Original Poster
Rep:
|
archtoad6,thanks for your reply.
By the way,if I set the sleep time to 100,then my connection will be terminated when my previous script,gnokii --getnetworkinfo takes more than 20 secs to execute.So,frankly,I don't think it's the solution.Moreover,as far as I know,gnokii cannot process two request at a time,I think this is the real problem.Maybe some process hasn't finished but next process rushed in.Anyway,I don't really care about this right now because I've been wasted quite a lot of time on this.
If you have any friends who can get the IrDA keep connected under gnokii without problem,I would like to listen,though.
P.S:
1.I've heard that IrDA is notorious on Linux because it's not very common.Maybe bluetooth is better.
2.Thanks for your coding recommendation.I should be economical on writing my code.:-)
Last edited by Swift&Smart; 04-16-2006 at 01:30 PM.
|
|
|
04-17-2006, 08:00 AM
|
#14
|
Senior Member
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
|
I think you're right about Bluetooth ("BT") vs. IrDA. I just got a Sony Ericsson W600i, which has both; & my experiments & readings so far lead me to believe that BT is much more likely to be the way to sync the phone w/ a KDE & Kontact. Or anything else, except direct phone-to-phone transfers, which seem to be smooth w/ IrDA.
I don't have a modern, working IrDA dongle nor am I likely to buy one given the promise of BT. Still I will keep my ears open. As they say "don't hold your breath" -- my friends: - have broadband, not dial-up
- have phones w/ BT, not IrDA, nor both
- have PDA's & don't care about sync'ing phones
The 2 problems I would like to solve are: - sync my phone w/ a KDE & Kontact
- use the W600i as a (BT) modem for a buddy's Nokia 770 "web tablet" when we are at a restaurant w/ no hotspot
|
|
|
All times are GMT -5. The time now is 01:18 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|