Hichem-elAbassi / j4me

Automatically exported from code.google.com/p/j4me
0 stars 0 forks source link

gps not works with Motorla v3x and Nokia LD-3W #8

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Start GPS demo
2. Select bluetooth and the Nokia LD-3W

The bluetooth connection seems OK, but the demo wait at the "fixing yor
location" screen

What version of the product are you using? On what operating system?
Build: November 26 2007 1110

Please provide any additional information below.

 Nokia E61 + LD-3W and Motorola v3x + another gps device works.

Original issue reported on code.google.com by schaffer...@gmail.com on 22 Dec 2007 at 9:30

GoogleCodeExporter commented 9 years ago
The same problem occurs when using version 1.0.1

Another gps libs have problem too with this pairing but navigami works.

Original comment by schaffer...@gmail.com on 22 Dec 2007 at 10:49

GoogleCodeExporter commented 9 years ago
Found the problem: the first read always timed out and j4me started to 
reconnect in
an infinite loop. I changed the READ_TIMEOUT in BluetoothGPS.java

from  

READ_TIMEOUT = SLEEP_BEFORE_READ + 1000

to

READ_TIMEOUT = SLEEP_BEFORE_READ + 3000 

so it works now. 

What the cause of the timeout was, I don't now exactly. Maybe the LD-3W is slow 
and
there is some delay in the v3x and the two together was too much. 

It would be an honor to test the fix of this issue in the next release!

by,
Krisztián

Original comment by schaffer...@gmail.com on 22 Dec 2007 at 9:16

GoogleCodeExporter commented 9 years ago

Original comment by deanbro...@gmail.com on 24 Dec 2007 at 12:24

GoogleCodeExporter commented 9 years ago
I will make the fix soon.  It is a bit tough during the Holidays.

Sounds like the read timeout thread should not start until after the first 
read.  Or
at least have a much larger initial timeout.  I'll play around with our phones 
and
GPS and when I get something reasonable I'll have you test it.

I'm guessing the timeout has to do with the Motorola phone.  We added it 
because the
Motorola JVM is very bad about handling lots of data coming through Bluetooth.  
Most
often it just stops responding and doesn't notify you.  So the read timeout was 
added
as a way to detect that state.  It is interesting the Nokia E61 also had the 
problem.

Original comment by deanbro...@gmail.com on 24 Dec 2007 at 12:30

GoogleCodeExporter commented 9 years ago
Thank You!

 The Nokia E61 didn't have the problem: I have two phones (Nokia E61, Motorola V3X)
and two gps modules (LD-3W and a noname) and only one of the four combinations 
have
this issue.

K.

Original comment by schaffer...@gmail.com on 25 Dec 2007 at 7:09

GoogleCodeExporter commented 9 years ago

Original comment by deanbro...@gmail.com on 10 Jan 2008 at 5:03