Results 1 to 8 of 8
Thread: GPS programming.
- 02-05-2011, 05:01 PM #1
Hi . Ive done a program that reads from a GPS device from a serialport. My only problem is that it gives me strange stuff.
The strings i get look like this:
NMEA Sentence [$GPRMC,160718.0�00,A,5746.587�4,N,01150.6604,E,0.3 0�,125.53,050211�,,,A*6C]
where � = a square.
how can i fix this? thanks
- 02-05-2011, 05:37 PM #2
I think you need set encoding for input stream.
- 02-05-2011, 06:06 PM #3
Thank you for your reply . how can i do that? There is no such class ?
- 02-05-2011, 06:15 PM #4
How you get this string. Can you show snippet code, which get string?
- 02-05-2011, 11:56 PM #5
I know its a lot of trash in it ... but Ive edited it soo much trying to get to the problem =P any ideas?
/CODE WAS HERE/
Removed because my teachers will kill me if their "search bot" finds my code online.
Last edited by santa; 02-06-2011 at 11:23 AM. Reason: removing code
- 02-06-2011, 10:50 AM #6
You can try follows
String encoding = "UTF-8"; //need encoding InputStreamReader reader = new InputStreamReader(inStream, encoding);
- 02-06-2011, 11:17 AM #7
- Join Date
- Sep 2008
- Voorschoten, the Netherlands
- Blog Entries
- Rep Power
- 02-06-2011, 11:21 AM #8
- By santa in forum New To JavaReplies: 6Last Post: 01-23-2011, 07:06 PM
- By shazeb in forum New To JavaReplies: 9Last Post: 10-31-2010, 03:45 PM
- By sirwiggles in forum New To JavaReplies: 4Last Post: 04-28-2009, 05:53 AM
- By DSutta22 in forum New To JavaReplies: 2Last Post: 09-10-2008, 06:19 AM
- By abcdefg in forum New To JavaReplies: 9Last Post: 03-10-2008, 11:34 AM