Bug in lejos.addon.gps??

This is where you talk about the NXJ software itself, installation issues, and programming talk.

Moderators: 99jonathan, roger, imaqine

Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 12:38 pm

Hello

First of all, I'm using Lejos v0.9.1 (fw version rev: 6217) from snapshot folder in the svn in my NXT's.

Using the sample file BTGPS.java, i've observed that when the gps data are printed in the NXT display, several numbers are displayed in the LCD all the time.

I think that all of this is because in VTGSentence.java file, line 106 shouldn't be there (or at least,should be commented)

Code: Select all
......
if(part8.length() == 0){
     speed = 0;
}else{
    speed = Float.parseFloat(part8);
}
         
System.out.println(speed); /*line 106*/
.......


Also, in spite of the bug, this program (BTGPS.java) raises an exception too (when running during a few minutes)
Exception: 79
string doesn't c
at: 131:25
....
at: 54:281

The line code (with nxjdebugtool) that raises the exception:
Code: Select all
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS_2\
src>nxjdebugtool -di BTGPS_2.nxd -c -m 79 131 25
The class number 79 refers to:
  java.lang.NumberFormatException (NumberFormatException.java)
The method number 131 refers to:
  java.lang.Integer.parseInt(Ljava/lang/String;IIZI)I (Integer.java)
PC 25 refers to:
  line 291 in Integer.java

C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS_2\
src>nxjdebugtool -di BTGPS_2.nxd -c -m 79 54 281
The class number 79 refers to:
  java.lang.NumberFormatException (NumberFormatException.java)
The method number 54 refers to:
  BTGPS_2.showData()V (BTGPS_2.java)
PC 281 refers to:
  line 240 in BTGPS_2.java


Line 240 in BTGPS.java:
Code: Select all
now = gps.getDate();



Thanks
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 12:58 pm

You need to translate the whole stacktrace into classes/methods.
You might want to use the debug monitor, which does that automatically. I believe you must use nxjconsole via USB to see the converted stack trace.

Unfortunately, I can't really. I don't have a BT GPS device, and I assume that the parser isn't that well written, I guess.
It would help to see a dump of all the data returned by the GPS device.
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 2:42 pm

Thanks for the answer

skoehler wrote:Unfortunately, I can't really. I don't have a BT GPS device, and I assume that the parser isn't that well written, I guess.
It would help to see a dump of all the data returned by the GPS device.


I've used remote console and this is the output:

Code: Select all
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjc BTGPS.java
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjlink -gr -o BTGPS.nxj -od BTGPS.nxd BTGPS
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjupload -r BTGPS.nxj
Found NXT: LAB1 0016530D8DC9
leJOS NXJ> Upload successful in 5046 milliseconds
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjconsole -di BTGPS.nxd
Debug attached
Found NXT: LAB1 0016530D8DC9
Connected to LAB1 0016530D8DC9
Console open
0.7
0.8
1.1
/*
Numbers that appears because of the bug in VTGSentence.java told in the first post
*/
0.5
0.8
1.1
0.9
0.6
0.3
Exception: java.lang.StringIndexOutOfBoundsException:String index out of range: -2
 at: java.lang.String.substring(String.java:563)
 at: lejos.addon.gps.GPS.updateDate(GPS.java:173)
 at: lejos.addon.gps.GPS.getDate(GPS.java:66)
 at: BTGPS.showData(BTGPS.java:240)
 at: BTGPS.main(BTGPS.java:67)
Console closed


BTGPS.java is the same at /samples/src/org/lejos/sample/btgps in svn

I've repeated this three times, first time is the dump posted
Second (raised exception about 20 secs from execution) and third time (about 1min from execution) have the same results, changing the exception:
Code: Select all
Exception: java.lang.StringIndexOutOfBoundsException:String index out of range: -1
 at: java.lang.String.substring(String.java:563)
 at: lejos.addon.gps.GPS.updateDate(GPS.java:173)
 at: lejos.addon.gps.GPS.getDate(GPS.java:66)
 at: BTGPS.showData(BTGPS.java:240)
 at: BTGPS.main(BTGPS.java:67)


thanks
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 3:28 pm

That is not the same error es before. The previous error was about Integer.parseInt throwing a NumberFormatException.
Now you're posting a StringIndexOutOfBoundsException.

Please try to reproduce the NumberFormatException, if possible.
I'll try to figure out what might have caused the StringIndexOutOfBoundsException.
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 4:24 pm

I can't reproduce the same error because i've realice that i change 1 parameter in Bluetooth.connect()

Using Bluetooth.connect(GPSDevice.getDeviceAddr(), NXTConnection.RAW, pin);
i get the last error posted

Code: Select all
Exception: java.lang.StringIndexOutOfBoundsException:String index out of range: -2
at: java.lang.String.substring(String.java:563)
at: lejos.addon.gps.GPS.updateDate(GPS.java:173)
at: lejos.addon.gps.GPS.getDate(GPS.java:66)
at: BTGPS.showData(BTGPS.java:240)
at: BTGPS.main(BTGPS.java:67)
Console closed


Using Bluetooth.connect(GPSDevice.getDeviceAddr(), NXTConnection.LCP, pin);
I get the first error posted with the bug

I have reproduced with remote console and without it
Remote console output:
Code: Select all
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjc BTGPS.java
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjlink -gr -o BTGPS.nxj -od BTGPS.nxd BTGPS
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjupload -r BTGPS.nxj
Found NXT: LAB1 0016530D8DC9
leJOS NXJ> Upload successful in 5735 milliseconds
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjconsole -di BTGPS.nxd
Debug attached
Found NXT: LAB1 0016530D8DC9
Connected to LAB1 0016530D8DC9
Console open
2.1
2.4
1.7
2.7
Exception: java.lang.StringIndexOutOfBoundsException:String index out of range:-2
 at: java.lang.String.substring(String.java:563)
 at: lejos.addon.gps.GPS.updateTime(GPS.java:155)
 at: lejos.addon.gps.GPS.getDate(GPS.java:67)
 at: BTGPS.showData(BTGPS.java:240)
 at: BTGPS.main(BTGPS.java:67)
Console closed


and in the NXT LCD:
Exception: 80
string doesn't c
at: 147:25
....
at: 54:281

Code: Select all
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjlink -o BTGPS.nxj -od BTGPS.nxd BTGPS
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjdebugtool -di BTGPS.nxd -c -m 80 147 25
The class number 80 refers to:  java.lang.NumberFormatException (NumberFormatException.java)
The method number 147 refers to:  java.lang.Integer.parseInt(Ljava/lang/String;IIZI)I (Integer.java)
PC 25 refers to:  line 291 in Integer.java

C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjdebugtool -di BTGPS.nxd -c -m 80 54 281
The class number 80 refers to:  java.lang.NumberFormatException (NumberFormatException.java)
The method number 54 refers to:  BTGPS.showData()V (BTGPS.java)
PC 281 refers to:  line 240 in BTGPS.java


I can't get the same number exception (79), but in this mode is the NumberFormatException too, also in the same line

Why I use LCP over RAW??
I use LCP because obtaining data from the gps via bluetooth to the NXT is faster than using RAW mode and for the 2º error i've changed by error and i didn't realiced that till you told me that i've posted a different exception
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 4:52 pm

Pgeorge wrote:Using Bluetooth.connect(GPSDevice.getDeviceAddr(), NXTConnection.LCP, pin);

That is rubbish. A GPS device doesn't understand LCP and never will. Use RAW.

The rest of your posting is confusing. Are you seeing two errors (one on the LCD and one in the output of nxjconsole)?

Pgeorge wrote:Exception: 80
string doesn't c
at: 147:25
....
at: 54:281


First and last line of the stack trace is not enough! I need the number (and the corresponding class/method names) after 147:25

Also, the GPS device send a serious of text strings to the NXT. I need that text in order to see when/why the error happens!
It might be easiest to connect the GPS device to the PC and somehow receive and log the data there. I assume the GPS device appears as a serial port? That should be easy to dump to a file.
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 5:31 pm

skoehler wrote:That is rubbish. A GPS device doesn't understand LCP and never will. Use RAW.

I read api and api says the same....
....but it works better in LCP. Why?? I don't know

In LCP, sample code in BTGPS.java updates every second aprox. and the time, longitude and latitude are correct
in RAW, same code updates when it wants (5 secs, 10secs, 1 min...)

skoehler wrote:The rest of your posting is confusing. Are you seeing two errors (one on the LCD and one in the output of nxjconsole)?


yes, if i use remote console debugging i get what i've posted in code tags
if i upload the program with eclipse to the nxt and executes normaly, i get the exception and then i uses nxjdebugtool as in the other code tag (i think that i am doing all the steps in right way)

skoehler wrote:First and last line of the stack trace is not enough! I need the number (and the corresponding class/method names) after 147:25


Didn't know..
In LCP:
Code: Select all
Exception: 80
string doesn't c
at: 147:25
at: 146:44
at: 145:44
at:   88:29
at:   83:2
at:   54:281
at:   51:22


In RAW:
Code: Select all
Exception: 80
string doesn't c
at: 147:25
at: 146:44
at: 145:4
at:   88:29
at:   83:2
at:   54:281
at:   51:22



skoehler wrote:Also, the GPS device send a serious of text strings to the NXT. I need that text in order to see when/why the error happens!
It might be easiest to connect the GPS device to the PC and somehow receive and log the data there.


I don't know the order the GPS send text to the NXT
If you expalin me how to log gps data into pc, i could do it

Bonus error:
new error when doing another test with the remote console (twice)
Code: Select all
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjc BTGPS.java
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjlink -gr -o BTGPS.nxj -od BTGPS.nxd BTGPS
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjupload -r BTGPS.nxj
Found NXT: LAB1 0016530D8DC9
leJOS NXJ> Upload successful in 5735 milliseconds
C:\Documents and Settings\Administrador\Mis documentos\LeJOSNXJProjects\BTGPS\src>nxjconsole -di BTGPS.nxd
Debug attached
Found NXT: LAB1 0016530D8DC9
Connected to LAB1 0016530D8DC9
Console open
3.4
2.8
Exception: java.lang.NumberFormatException:string doesn't contain any digits
 at: java.lang.Integer.parseInt(Integer.java:291)
 at: java.lang.Integer.parseInt(Integer.java:284)
 at: java.lang.Integer.parseInt(Integer.java:254)
 at: lejos.addon.gps.GPS.updateDate(GPS.java:173)
 at: lejos.addon.gps.GPS.getDate(GPS.java:66)
 at: BTGPS.showData(BTGPS.java:240)
 at: BTGPS.main(BTGPS.java:67)
Console closed


also in
Code: Select all
 at: BTGPS.showData(BTGPS.java:219)


all related with getDate() in GPS.java
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby gloomyandy » Thu Feb 02, 2012 5:48 pm

What sort of GPS are you using? setting LCP mode on a Bluetooth connection means that we are expecting a two byte header in front of each packet, I'd be surprised if any GPS unit sends that header, but I suppose you never know... Certainly the Bluetooth GPS unit I have does not do this, and that actually works fine with the sample app...

Andy
User avatar
gloomyandy
leJOS Team Member
 
Posts: 4240
Joined: Fri Sep 28, 2007 2:06 pm
Location: UK

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 5:49 pm

Pgeorge wrote:
skoehler wrote:That is rubbish. A GPS device doesn't understand LCP and never will. Use RAW.

I read api and api says the same....
....but it works better in LCP. Why?? I don't know

In LCP, sample code in BTGPS.java updates every second aprox. and the time, longitude and latitude are correct
in RAW, same code updates when it wants (5 secs, 10secs, 1 min...)


Which device are you using? I want to take a look at the datasheet if there is any.

Pgeorge wrote:
skoehler wrote:The rest of your posting is confusing. Are you seeing two errors (one on the LCD and one in the output of nxjconsole)?


yes, if i use remote console debugging i get what i've posted in code tags
if i upload the program with eclipse to the nxt and executes normaly, i get the exception and then i uses nxjdebugtool as in the other code tag (i think that i am doing all the steps in right way)

weired!

Pgeorge wrote:
skoehler wrote:First and last line of the stack trace is not enough! I need the number (and the corresponding class/method names) after 147:25


Didn't know..
In LCP:
Code: Select all
Exception: 80
string doesn't c
at: 147:25
at: 146:44
at: 145:44
at:   88:29
at:   83:2
at:   54:281
at:   51:22


In RAW:
Code: Select all
Exception: 80
string doesn't c
at: 147:25
at: 146:44
at: 145:4
at:   88:29
at:   83:2
at:   54:281
at:   51:22



I'm afraid, you have to translate those number for me, just to be safe. When I build/link the BTGPS sample, different numbers might be assigned to the classes etc.
Also, the stack traces are pretty much the same, so it's the same error no matter whether you're using LCP or RAW.

Pgeorge wrote:
skoehler wrote:Also, the GPS device send a serious of text strings to the NXT. I need that text in order to see when/why the error happens!
It might be easiest to connect the GPS device to the PC and somehow receive and log the data there.


I don't know the order the GPS send text to the NXT
If you expalin me how to log gps data into pc, i could do it


Pair the GPS device with your PC. As what kind of device does it appear in the device manager?
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 6:02 pm

gloomyandy wrote:What sort of GPS are you using? setting LCP mode on a Bluetooth connection means that we are expecting a two byte header in front of each packet, I'd be surprised if any GPS unit sends that header, but I suppose you never know... Certainly the Bluetooth GPS unit I have does not do this, and that actually works fine with the sample app...


It might be the case, the two skipped characters don't matter that much in the beginning, since they are at the start of the line.
However, it might still be the case that the parser might need some work (skipping lines which have the wrong format, etc.)
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 6:27 pm

I am now writing from my phone so i can anwser to all


Model is this
http://www.sysonchip.co.kr/eng/prod/pro_gps_1.htm

I also have an old tomtom that works fine on raw but i havent tried in lcp mode
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 6:44 pm



Can't find a useful data sheet which shows which kind of data that thing sending. However, it says that thing implements the serial port profile. So you have to pair it with your PC, then a serial port should occur, and you be able to use some terminal program (like hyperterminal, hterm, etc) to dump all the data that this box sends.
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 8:04 pm

Hope this can help to solve the exceptions

Get with hyperterminal (sample, not all, but is valid one):
SysOnChip BT gps SIRF III
Code: Select all
$GPGSA,A,3,05,26,08,17,28,,,,,,,,3.5,2.7,2.2*34
$GPGSV,3,1,11,26,64,095,27,15,64,313,14,27,59,286,17,28,43,055,21*7B
$GPGSV,3,2,11,09,34,267,13,05,24,182,24,18,23,310,13,17,16,106,32*76
$GPGSV,3,3,11,08,11,062,27,12,05,205,,21,02,282,*48
$GPRMC,195124.000,A,4142.5561,N,00100.1033,W,0.40,359.21,020212,,,A*79
$GPVTG,359.21,T,,M,0.40,N,0.7,K,A*02
$GPGGA,195125.000,4142.5560,N,00100.1033,W,1,05,2.7,211.3,M,51.6,M,,0000*43
$GPGLL,4142.5560,N,00100.1033,W,195125.000,A,A*45
$GPGSA,A,3,05,26,08,17,28,,,,,,,,3.5,2.7,2.2*34
$GPGSV,3,1,11,26,64,095,27,15,64,313,14,27,59,286,17,28,43,055,21*7B
$GPGSV,3,2,11,09,34,267,13,05,24,182,24,18,23,310,13,17,16,106,32*76
$GPGSV,3,3,11,08,11,062,27,12,05,205,,21,02,282,*48
$GPRMC,195125.000,A,4142.5560,N,00100.1033,W,0.36,276.98,020212,,,A*76
$GPVTG,276.98,T,,M,0.36,N,0.7,K,A*0D
$GPGGA,195126.000,4142.5558,N,00100.1032,W,1,05,2.7,211.2,M,51.6,M,,0000*4B
$GPGLL,4142.5558,N,00100.1032,W,195126.000,A,A*4C
$GPGSA,A,3,05,26,08,17,28,,,,,,,,3.5,2.7,2.2*34
$GPGSV,3,1,11,26,64,095,27,15,64,313,14,27,59,286,18,28,43,055,21*74
$GPGSV,3,2,11,09,34,267,13,05,24,182,24,18,23,310,13,17,16,106,31*75
$GPGSV,3,3,11,08,11,062,27,12,05,205,,21,02,282,*48
$GPRMC,195126.000,A,4142.5558,N,00100.1032,W,0.33,240.06,020212,,,A*78
$GPVTG,240.06,T,,M,0.33,N,0.6,K,A*0B
$GPGGA,195127.000,4142.5556,N,00100.1030,W,1,05,2.7,211.1,M,51.6,M,,0000*45
$GPGLL,4142.5556,N,00100.1030,W,195127.000,A,A*41


EDIT:
data obtained with a tomtom wireless gps (9821x), SIRF II
Code: Select all
$GPGGA,201221.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*22
$GPRMC,201221.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*10
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201222.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*21
$GPRMC,201222.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*13
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201223.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*20
$GPRMC,201223.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*12
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201224.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*27
$GPGSA,A,1,,,,,,,,,,,,,50.0,50.0,50.0*05
$GPGSV,3,1,12,15,74,313,34,08,71,020,,25,57,286,,30,54,186,*71
$GPGSV,3,2,12,21,48,285,,18,44,288,,28,36,049,36,17,21,098,36*76
$GPGSV,3,3,12,12,13,207,,23,11,168,,06,11,153,,01,08,124,*7F
$GPRMC,201224.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*15
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201225.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*26
$GPRMC,201225.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*14
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201226.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*25
$GPRMC,201226.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*17
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201227.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*24
$GPRMC,201227.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*16
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201228.688,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2B
$GPRMC,201228.688,V,4142.5703,N,00100.1951,W,0.00,,020212,,*19
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201229.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*25
$GPGSA,A,1,,,,,,,,,,,,,50.0,50.0,50.0*05
$GPGSV,3,1,12,15,74,313,27,08,71,020,,25,57,286,,30,54,186,*73
$GPGSV,3,2,12,21,48,285,,18,44,288,,28,36,049,36,17,21,098,36*76
$GPGSV,3,3,12,12,13,207,,23,11,168,,06,11,153,,01,08,124,*7F
$GPRMC,201229.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*17
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201230.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2D
$GPRMC,201230.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1F
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201231.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2C
$GPRMC,201231.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1E
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201232.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2F
$GPRMC,201232.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1D
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201233.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2E
$GPRMC,201233.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1C
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201234.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*29
$GPGSA,A,1,,,,,,,,,,,,,50.0,50.0,50.0*05
$GPGSV,3,1,12,15,74,313,28,08,71,020,,25,57,286,,30,54,186,*7C
$GPGSV,3,2,12,21,48,285,,18,44,288,,28,36,049,36,17,21,098,36*76
$GPGSV,3,3,12,12,13,207,,23,11,168,,06,11,153,,01,08,124,*7F
$GPRMC,201234.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1B
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201235.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*28
$GPRMC,201235.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*1A
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201236.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2B
$GPRMC,201236.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*19
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201237.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*2A
$GPRMC,201237.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*18
$GPVTG,,T,,M,0.00,N,0.0,K*7E
$GPGGA,201238.687,4142.5703,N,00100.1951,W,0,00,50.0,0.0,M,,,,0000*25
$GPRMC,201238.687,V,4142.5703,N,00100.1951,W,0.00,,020212,,*17
$GPVTG,,T,,M,0.00,N,0.0,K*7E



the tomtom works fine with btgps in raw mode

the other bug, the line in VTGSentence.java file, have you seen the line?? (all post have focused on the other error but don'f forget this bug :) :) )
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Re: Bug in lejos.addon.gps??

Postby skoehler » Thu Feb 02, 2012 9:09 pm

I committed a fix to SVN:
http://lejos.svn.sourceforge.net/viewvc/lejos/trunk/classes/src/lejos/addon/gps/GPS.java?r1=5928&r2=6283

I'm sorry for the braindead code for splitting the date/timestamp, which might have caused the bug.
I hope that fixed your problem. I also created a new snapshot which includes the fix. You can download it from SVN:
http://lejos.svn.sourceforge.net/viewvc/lejos/trunk/snapshot/?view=tar
skoehler
leJOS Team Member
 
Posts: 1458
Joined: Thu Oct 30, 2008 4:54 pm

Re: Bug in lejos.addon.gps??

Postby Pgeorge » Thu Feb 02, 2012 9:47 pm

Thanks!!

output debug has dissapeared and running BTGPS program for 10 mins and counting and hasn't crashed yet (in LCP mode)
tomorrow will test in raw mode.


my project, for the moment, was more important the other, but now i know that can get time/date too if i need them without raising an exception in my nxt's

thanks again!!
Pgeorge
New User
 
Posts: 9
Joined: Thu Feb 02, 2012 11:53 am
Location: Spain

Next

Return to NXJ Software

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest

more stuff