Bílý vrch
icon TrekBuddy
www.trekbuddy.net
Outdoor companion.
  • internal / bluetooth / simulator GPS
  • offline raster maps
  • smart GPX / raw NMEA logs
  • waypoints and simple navigation
  • custom views
  • MIDP and Symbian phones
  • Blackberry
  • Android
Visit wiki to see all features, guides and howtos. Project tracker.

Partners:    (Polish/Polski)(Polski) Compass mapy      (Polish/Polski)(Polski) Galileos mapy      (Polish/Polski)(Polski) CartoMedia      (Czech/Èesky)(Èesky) Eaglesoft trasy      (Polish/Polski)(Polski) ExpressMap     

 FAQFAQ   SearchSearch   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
JavaME tool for static navigation on bluetooth devices
Goto page Previous  1, 2, 3  Next
 
Post new topic   Reply to topic    TrekBuddy Forum Index -> Tools
View previous topic :: View next topic  
Author Message
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Fri Sep 11, 2009 2:16 pm    Post subject: Reply with quote

Sorry, I did not read the replies until just now. The forum software does not seem to notify me when a reply is posted. Bugger.
I will try to look into the matter next week.
Back to top
View user's profile Send private message
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Wed Sep 16, 2009 1:51 pm    Post subject: Reply with quote

Ok, finally got around to implement the new messages. I am not able to test them, though. Please install the attached version and tell me about the results, good or bad.

This version still does not poll the current settings and does not even listen to the device's answers to the commands. Yes, it's that dirty. I guess that very few people need and use this tool, so I did not bother making it nice. There is a much bigger project that I have to deal with.

What I may add is a way to make it easier to extend the command set. The minimum solution for that would be a configuration file in the jar, listing command names and command hex-strings. Getting the neccessary data from SirfDemo should be be easy enough for many potential users. But that solution may actually be the first step to adding a very simple kind of scripting language. This would give many users the power to add the features they need, without me having to implement all bits of the protocol. Anyway, that are my thoughts on the future of nosn.

Oh, one more point. I don't seem to get notifications from the forum software. If I do not react to direct questions or requests, please send me a note to guido.wegener@gmx.de



nosn.jad
 Description:

Download
 Filename:  nosn.jad
 Filesize:  212 Bytes
 Downloaded:  51 Time(s)


nosn.jar
 Description:

Download
 Filename:  nosn.jar
 Filesize:  5.63 KB
 Downloaded:  67 Time(s)


nosn.java
 Description:

Download
 Filename:  nosn.java
 Filesize:  8.95 KB
 Downloaded:  43 Time(s)

Back to top
View user's profile Send private message
guest



Joined: 08 Oct 2006
Posts: 5015

PostPosted: Fri Sep 18, 2009 10:02 am    Post subject: Reply with quote

Congratulations! SBAS on and off works perfectly with my Holux GPSlim236 and NOSN. It is a great idea to make a configuration file into the jar. Then anybody could implement own commands easily with a short instruction only. Thanks a lot for implementation of SBAS. Great!
Back to top
View user's profile Send private message Visit poster's website
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Mon Sep 21, 2009 4:39 pm    Post subject: Reply with quote

Once I started thinking about this, I could not stop. So I started to write a more flexible version of nosn and gave it a new name: SirfME
I did not get around to fully test it and there are a lot of ugly things going on, but it may already work. The .jar-file now includes a configuration file that I also quote below. It should be obvious how it works...
Parsing this file is still very sensitive to whitespace, so be careful with that!
It still ignores all responses from the connected device, sorry for that.
I'm still unsure about what else to add and how.
Comments?

The config file:
SirfME config format 1.0

sub SiRF:
sendString "$PSRF100,0,38400,8,1,0*3C\r\n"
wait 100

sub NMEA:
wait 100
sendHex "A0A20018810201010001010105010101000100010001000100019600012BB0B3"

item SN off:
sub SiRF
sendHex "A0A200028F00008FB0B3"
sub NMEA

item SN on:
sub SiRF
sendHex "A0A200028F010090B0B3"
sub NMEA

item SBAS on:
sub SiRF
sendHex "A0A20007850100000000000086B0B3"
sub NMEA

item SBAS off:
sub SiRF
sendHex "A0A20007850000000000000085B0B3"
sub NMEA



SirfME.java
 Description:

Download
 Filename:  SirfME.java
 Filesize:  13.52 KB
 Downloaded:  35 Time(s)


SirfME.jad
 Description:

Download
 Filename:  SirfME.jad
 Filesize:  221 Bytes
 Downloaded:  38 Time(s)


SirfME.jar
 Description:

Download
 Filename:  SirfME.jar
 Filesize:  10.51 KB
 Downloaded:  49 Time(s)

Back to top
View user's profile Send private message
brum



Joined: 05 Apr 2008
Posts: 13

PostPosted: Fri Sep 25, 2009 7:03 pm    Post subject: Reply with quote

not to ld3w + N6300: nullpointer!
Back to top
View user's profile Send private message
guest



Joined: 08 Oct 2006
Posts: 5015

PostPosted: Sun Sep 27, 2009 9:39 am    Post subject: Reply with quote

SE K750i and Holux GPSlim236:
connected ER2 java.lang.NullPointerException
Back to top
View user's profile Send private message Visit poster's website
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Sun Sep 27, 2009 9:51 am    Post subject: Reply with quote

Ok, this version does not work at all. I introduced a new bug after testing.
The bug is fixed, but I want to improve a few things before I post a new version.
Back to top
View user's profile Send private message
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Wed Sep 30, 2009 10:12 am    Post subject: Reply with quote

Debugging took a lot of time, as I do not know how to test Bluetooth communication in the emulator.
Well, it seems to work now and you may want to play around with the new version. It should be easy enough to add new commands by logging SirfDemo's communication and copying the relevant commands to the config-file.
Any responses from the device are still ignored and I may work on that if I ever get bored enough.



SirfME.jar
 Description:

Download
 Filename:  SirfME.jar
 Filesize:  10.71 KB
 Downloaded:  126 Time(s)


SirfME.jad
 Description:

Download
 Filename:  SirfME.jad
 Filesize:  221 Bytes
 Downloaded:  91 Time(s)


SirfME.java
 Description:

Download
 Filename:  SirfME.java
 Filesize:  13.12 KB
 Downloaded:  73 Time(s)

Back to top
View user's profile Send private message
guest



Joined: 08 Oct 2006
Posts: 5015

PostPosted: Thu Jan 07, 2010 2:07 pm    Post subject: Doesn't work with Nokia E51 and Leadtek 9559X GPS Mouse Reply with quote

Hello Guido,

unfortunaltly I have to confirm, that your programm doesn't work for me (nosn neither SiRFME).
I run your program on my Nokia E51 phone together with my Leadtek 9559x GPS Mouse (SiRFStarIII Chipset).
Your program says searching "bluetooth devices..." and after a short time it finds my Leadtek GPS Mouse with the following message: +[Leadtek 9559 series BT GPS] (1,0).
After that your program stucks and I have to restart my phone, becourse otherwise I can't close nosn/SiRFME.
There is no way to choose "SN off" or "SN on" becourse I dont see that items.
Until now I use SiRFDemo to change this feature and I've played a little bit with that SirfME.conf file but without success.
I think the problem isn't within the conf-file but in class files, becourse the items (menu) will not be shown.

After all searching in the net your program is the first one I've found which could/should toogle static navigation with a normal phone.
Unfortunatly my GPS Mouse changes really fast back to factory settings, which means after a hour of shutting down the mouse resets back to factory settings (this includes static navigation will be on again).
It seems leadtek hasn't applied battery backup voltage and in that case, when I power down, after a very short time when the filter capacitor bleeds off, I lose all my changes.
But for my logging on foot for geocaching or OpenStreetMap this (factory) setting makes the Leadtek 9559 GPS Mouse useless to me.
It's very annoying, that this GPS Mouse will not hold my special settings even until the battery is bleeding out.

You are my last hope, otherwise I have to change my GPS Mouse for another one which has the factory setting "static navigation = off" or at least hold my changes for battery lifetime.
Back to top
View user's profile Send private message Visit poster's website
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Thu Jan 07, 2010 8:44 pm    Post subject: Reply with quote

I've already started an email discussion with the author of the preceding post. But since it may be of interest to others, we have decided to move the discussion back to the forum. I'll try to destill the important points of the exchanged mails and answer the current questions at the same time. So this post might be a bit confusing for all.

It's always a bit difficult to debug without having the problematic devices, but I guess that the problem stems from the way I discover Bluetooth devices. Java offers two ways to call DiscoveryAgent.startInquiry: GIAC and LIAC. Since my device are only discovered when using GIAC and others' only with LIAC, SirfME does both, one after the other. The displayed '(1,0)' is a cryptic message saying that the device was discovered during by GIAC (1) and not by LIAC (2). The zero is the discoveryType supplied by Java and I'm not sure about its meaning.

I guess that LIAC does not work with this combination of devices. I suggested waiting for 5 minutes, in the hope that the cause is just an unusually long time-out, but even waiting for 30 minutes did not help.

The ugly solution may be to add an option to disable LIAC to the config file. But it bugs me that other applications offer a quicker and more stable discovery. Sadly, I have no idea how they do it and cannot find good examples for it online.

I just realized that I never configured Eclipse for JavaME development on my new computer. Since a lot of the neccessary packages seem to have changed recently, I did not manage to compile the project at all. It will take a while to get all the stuff running again.
Back to top
View user's profile Send private message
fireball2



Joined: 06 Aug 2008
Posts: 3

PostPosted: Thu Jan 07, 2010 11:18 pm    Post subject: Reply with quote

I've have tried both nosn-version and the last SiRFME-Version for half an hour. It happens nothing more.
Do have changes within the config file any influence to this search process (e.g. SiRF baud rate)? In the case of no influence I could stop editing it Very Happy .
Back to top
View user's profile Send private message
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Fri Jan 08, 2010 7:56 am    Post subject: Reply with quote

The settings in the config file only influence the behaviour after a connection with the bluetooth device is established. This may change in the future, but changing the contents of the file will not help currently. Sorry, I forgot to tell you that earlier.
Back to top
View user's profile Send private message
fireball2



Joined: 06 Aug 2008
Posts: 3

PostPosted: Fri Jan 08, 2010 11:25 am    Post subject: Reply with quote

OK, I've found out that my Leadtek 9559x SirfIII GPS Mouse doesn't hold any toggled setting if I power off the device and then on again.
So if I want to go geocaching or walking then I have to power on the device at home, switch with SiRFDemo Static Navigation off and have that mouse switched on all the time. Even If I would make a picknick or other breaks within my walking tour I can not power down that mouse or I will loose the SN=off setting. Therefore these mouse is practicaly unusable to me.
Does somebody out there know if all SirfIII GPS Mouses have that special problem or is there maybe a list in the internet with which I can find a mouse for my needs? At least a mouse that holds my toggled settings as long as the battery isn't empty?
What mouses do you use e.g. together with trekbuddy?
The most annoying thing is the problem if you want to buy a GPS Mouse, nothing about that important factory setting can be found in manuals, the packing or elsewhere on their internet sites. So you have to buy the cat in the bag?
Back to top
View user's profile Send private message
Guido



Joined: 16 Oct 2008
Posts: 16

PostPosted: Fri Jan 08, 2010 11:54 am    Post subject: Reply with quote

As you might have guessed, my GPS uses SirfIII, too. From what I remember from my research into this topic, SirfIII is the only chipset that uses static navigation. I don't know if there are devices that remember the settings after losing power, but my mouse does not.
It seems that SirfIII was an experiment in trying to help the connected device smoothing the data and prevent my car's navigation system from recalculating the route everytime the position jumps when waiting at a traffic light. More modern chipsets know that the nav system is smart enough to smooth the data.
Back to top
View user's profile Send private message
fireball2



Joined: 06 Aug 2008
Posts: 3

PostPosted: Fri Jan 08, 2010 2:47 pm    Post subject: Reply with quote

The internal backup battery (Model: Panasonic ML414RH, 3V) of my Leadtek LR9559x SiRFIII GPS receiver was empty. There was no such battery model to buy elsewhere in the internet. So I removed the soldered backup battery and connected their pins with the rechargeable Li-Ion battery. I had luck becourse both batteries had nearly the same voltage (3V vs. 3.7V). Now I can power off the device without fear to loose all my altered settings. Of course these settings will only hold until the Li-Ion battery gets empty, but better than nothing. I can't understand why Leadtek hasn't this done ex works. Without this the GPS receiver will operate only at factory settings after 2-3 years -until the unchangeable backup battery gets empty. So if the manufacturer don't makes public their special factory settings it could be, you have to throw away your GPS receiver at the end of backup batteries lifetime. Becourse e.g. car driver needs mostly static navigation toogled on and geocacher or openstreetmap logger on the other hand need static navigation toogled off. Now I have reached best possible modification for my GPS receiver but it doesn't compensate SiRFME especially if you want toggle settings in the field.
I would need SiRFME to find out the best settings in different enviroments (e.g. wood, field, street canyon) or to toggle static navigation for my walking trip after I'm driven to it with my car.
For that reason I hope SiRFME will function together with my GPS receiver in some time. For now I have to test the new Li-Ion batteries lifetime, but hopefully these backup function shouldn't take too mutch energy from it Very Happy .
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    TrekBuddy Forum Index -> Tools All times are GMT
Goto page Previous  1, 2, 3  Next
Page 2 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group