Tether GPS possable? - G1 Android Development

Is there currently any way of tethering the GPS to a computer/laptop so i can use it as a serial or Bluetooth GPS device?
Could this be achieved using scripts similar to the way WiFi tethering is done, or is it more complicated then that?
Also, could an app be written that achieves this?

I agree this would be a nice feature. Hopefully with bluetooth tether. Can use old wm for gps program

This should be possible. Someone would need to write a script or app that takes the GPS position data and outputs it in the standard NMEA format that most other mapping software and/or hardware accepts.
Once you have that, you can perhaps broadcast that via bluetooth or maybe even wifi on a specific port.

Related

Any method to 'fool' programs into using a Bluetooth GPS

We all know the Tilt's GPS is slow, uses a lot of battery, and often continues to use battery after exiting all programs using it unless you soft reset. So I use my bluetooth GPS.
Works great, for programs which have a com port setting. There are some which do not, some are on the todo list, but some other programs are no longer under development.
What I'd like to be able to do is to 'fool' any program into using the Bluetooth's com port. I have GPSGate listening to the bluetooth GPS and outputting to com1 so that I can run whatever number of programs using the GPS data on com1, but I can't get several Wifi scanners to use com1, can't get the camera's GPS feature to use com1, etc.
I've tried a few things like messing with the built-in GPS settings and changing them to com1 hoping programs might then access com1, tried setting GPSGate to com4 to see if programs would access it instead of the built-in, but I think when programs access the built-in device they don't access it on com4, they access it on GPD4 or such.. Anyway.
So again, how to make programs which you cannot specify a com port use GPSGate's com port? Or another program if necessary..
Thanks!
Bumping in case anyone missed it.
Thanks!
SOLVED! But not for the faint of heart.
The developer of BasicGPS pointed me to this URL when I was asking him if he could implement selecting the com port for the GPS, since I use GPSGate with a Bluetooth GPS, not the built-in one:
http://msdn.microsoft.com/en-us/library/bb202089.aspx
From this, following these steps, I was able to make the Intermediate Driver use COM1, therefore using GPSGate/Bluetooth! So far this works in BasicGPS and I'm pretty sure it works in the camera too, so probably works in every program! Good news for people who hate the built-in GPS as much as I do!
Here are the basic steps, but you'll want to read the URL above. It's really written for developers, which I am not, but it made enough sense for me.
I used Resco Explorer to browse into this registry key. I made a copy of the whole key, then browsed in.
HKEY_LOCAL_MACHINE\System\CurrentControlSet\GPS Intermediate Driver\Drivers
There is a key named CurrentDriver, which was set to GPSOneDevice, which is apparently my built-in GPS. So I made a copy of the whole GPSOneDevice registry key, named it GPSGate. Then went into that key, changed the InterfaceType from POLL to COMM and added a string called CommPort and set it to COM1: where GPSGate outputs its info. I also modified the FriendlyName to "GPSGate Bluetooth". Finally, I changed the CurrentDriver to reference my new GPSGate registry key, and voila!
I'm not 100% sure it's working, as the built-in GPS is warmed up and would respond fairly quickly, but in a few days I'm going to try the camera in GPS mode and see if it immediately gets a fix from my Bluetooth unit vs 5+ minutes with the built-in GPS.
That said, I've tried GPSTest, BasicGPS, camera, etc, all get a fix immediately and update with the Bluetooth GPS on. If I turn the Bluetooth GPS off, they all stop getting updates. Previously when I was trying to figure out how to do this, I would discover the built-in GPS was still being used because I'd turn off the Bluetooth GPS and programs would continue to get new GPS data. So this tells me it's working! I'll follow up again in a few days to say for absolute sure.
Yay!
Just a followup here.. I think it's working, but if I monitor the data on COM9 (bluetooth) or COM1 (GPSGate re-distributing COM9 data), the data streams in at a reasonable pace.. Perhaps 6k of data in 10 or so seconds.. I didn't measure it closely.
But when I monitor data on COM4 the data is very fast, after about 10s it was up to 60k and when I left a few different programs open for a while they either crashed, never got a real lock, or locked up.
So not sure why, but the string of bluetooth->gpsgate->intermediate driver is causing a LOT more data to be produced.
I wasn't planning on using the intermediate driver for applications, I am still going to use the COM1 port for that when possible, but I wonder about the stability of using the camera and/or other programs which can't change the com port with this configuration.
Oh well! So far the camera seems to pick up a coordinate very quickly and probably disconnects from the GPS, so it's probably fine.
I suppose if I were truly curious I could capture the NMEA data and compare between the two. If anyone can do that who is also curious, I can do it and attach the data. I wouldn't know what to look for.
Hi,
ok, perhaps I know the Problem why my intermediate driver doesn't do his job. I can find this key in my reg:
Code:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\GPS Intermediate Driver\Drivers
But that is all. This key hasn't any values or subkeys. But why?
I'll try to find out the default Settings...
So. I've created following settings:
Code:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\GPS Intermediate Driver
CurrentLogFile="\Temp\gps.log"
IsEnabled=dword:00000001
HKEY_LOCAL_MACHINE\System\CurrentControlSet\GPS Intermediate Driver\Drivers
CurrentDriver="TestFile"
HKEY_LOCAL_MACHINE\System\CurrentControlSet\GPS Intermediate Driver\Drivers\TestFile
File1="\Temp\test.nmea"
FriendlyName="File Test #1"
InterfaceType="File"
After creating settings I "rebooted" my device. Then I start my GoogleMaps-App and configured it to use "managed GPS".
Result: GoogleMaps didn't get data from test-file and I cannot find the log-file in Temp-Folder. What the hell is going wrong here?
YFI: If I configure GoogleMaps to use GPS an COM4 (115200 Baud) then all works fine.

[REQ] Use G1 as GPS Reciever for PC? Utilize NEMA output of GPS and redirect to PC.

Hello,
I did quite some searching on this topic but nothing to be found. Maybe some developers can shed some light on this issue?
Many developers have written excellent applications that take the GPS output of the phone and display your coordinates, altitude, speed, and other variables. Presumably, this information can be gathered without the need for a data application.
Now, let's say the data format that the GPS is outputted in (NEMA Standard) is slipstreamed consistently into a Maps application (like Microsoft Streets & Maps), then you would have a winner. The combination of preloaded maps with the power of the GPS receiver in the G1 would give you awesome maps functionality on the cheap (perfect for that Netbook).
However, much GPS status applications only display the output on screen. While it is nice to have a coordinate staring at you in the face, that's all it's doing. Instead, utilizing those NEMA values for the computer to interpret would simplify the process.
My friend and I proposed a couple of concepts on how to take this on:
1) Upload the NEMA data to a server
*Okay idea but defeats the purpose of going Data-less. I might as well use Google Maps
2) Upload the NEMA data to a local server
*Good idea but if the laptop is connected to an ad-hoc network or some weird [sic] network, the phone maybe unable to connect to the same network (i.e. business-style wifi logins)
3) Bluetooth. Beam data through OBEX file transfer or other method.
*Better idea but the implementation of bluetooth in Android does not currently support OBEX file transfers or other pairing mechanisms. Would this be possible to carry out?
4) Serial output via USB.
*Best idea. This would put the GPS receiver in tandem to the other devices.
So...any ideas? Would love to hear them. Are there people who could utilize such functionality for a netbook/laptop combination? Spill your comments, questions, concerns.
Developers, feel free to chime in at any time Thanks.
~NerveBand
try BlueNMEA witch is avaible on the market, it send NMEA over bluetooth.
So does anyone use BlueNMEA and if so can you help set mine up. I cant seem to find any real documentation.
Are there any other options for utilizing the gps on a program like streets and trips?
Can anyone confirm blueNEMA and CM-4.1.9999?
Has anyone successfully gotten this blueNEMA working with a G1 + Bluetooth + Laptop and Streets and Trips?
Love to get this working too... I have the BlueNMEA installed, paird with my laptop over BT but I cant get MS Streets and Trips to see it, if I scan it doesnt see it either... weird.
Here's a bit of documentation I found: http://git.snow-crash.org/?p=blue-nmea.git;a=blob_plain;f=README
Sorry for the bump, but...
Is there any possibility of this ever working over USB rather than bluetooth?

Bluetooth GPS Receiver

Will it ever be possible for Android to be able to interface to a Bluetooth GPS Receiver for use in programs like Google Maps?
What sounds like such a simple thing which would give me some respite on my Samsung Galaxy S.
Cheers
Simon
I am curious also.
i need that too
I know that most of the Bluetooth GPS receivers use a simulated Comm port. As long as Android can use the Comm port and receive position data through ASCII sentences, then it should be fine.
i'm gonna try BlueNMEA (it's on the market)
i'll report back
edit: the app seems to be broken :\
If there is an app for NMEA data, that is a good sign. NMEA uses ASCII text strings to send data. To be honest, I know that Garmin's Bluetooth receivers will send NMEA data to the phone.
Sent from my Garminfone using XDA App
Any news on this topic?
Sent from my HTC Desire using Tapatalk
Look for "Bluetooth GPS Provider" or "Bluetooth GPS mouse" in the market...
I didn't want to pay for something like that and I did not understand why I should give phone call or network access for such an application...
So I've have developed mine:
it' free,
it's open-source (you can verify what it's really doing and you can improve it!),
it just asks for needed permissions.
The application allows to use an external bluetooth GPS on Android devices:
The application starts a service, then connects to a Bluetooth device (NMEA GPS) and creates a mock GPS provider which can be used to replace the internal GPS.
It's also possible to log the external GPS NMEA data in a file on the device.
The app need the following permissions:
bluetooth and bluetooth admin (connection to the GPS device),
location and mock location (replace the GPS location provider by a new one using the bluetooth GPS device),
write external storage (if you want to log the NMEA data into a file on the sdcard).
It should run on all android devices (2.0 and above) and NMEA bluetooth devices.
I have tested it with a GlobalSat BT-338 bluetooth GPS (SiRF III), a Galaxy S (I9000) and a HTC Sapphire (Froyo CM-6).
It works with Google Maps, Wikitude, GoPenS and my own personal navigation app. It should work with all applications that use Android official location API.
Note: in order to install the app:
enable Settings/Applications/Unknown sources,
enable Settings/Applications/Development/Allow mock locations,
download and install the apk.
Project page:
Bluetooth GPS for Android on SourceForge
BlueGPS4Droid apk: BlueGps4Droid_1.0.apk
herbert1 said:
I didn't want to pay for something like that and I did not understand why I should give phone call or network access for such an application...
So I've have developed mine:
it' free,
it's open-source (you can verify what it's really doing and you can improve it!),
it just asks for needed permissions.
Click to expand...
Click to collapse
Wow, went from zero of these to three or more.. More is good I guess! Does yours reconnect to the GPS when the connection is lost (walk away from the GPS, GPS accidentally gets turned off in pocket, etc)? What happens if you turn off the phone (hit power button.. standby), does it disconnect? Reconnect? What happens to apps while running, do they pick back up, or reconnect to the internal GPS?
EDIT: It disconnects. You should have it reconnect, especially if the signal was just lost watch for the device to become available again, and it'd also be really nice if it could do it automatically even if not just used; ie I get in the car, fire up the Holux 236 and a few seconds later your program connects to it.
Very very nice start, worked as well as the Bluetooth GPS Mouse program I've been using for a few weeks.. No sat or fix info, but that's a limitation of the Mock interface of course. Not much to be done there.
And it will be great if supports usb gps too. I have an android device with usb host and a usb gps, so will be great if we can attach a serial port to the mock gps in your app.
Thanks.
Corvus.
I actually have stopped using this, as about 50% of the time my phone is freezing when entering Waze with it enabled, 0% of the time without it or using Bluetooth GPS Mouse.
But it is a new program, it has room to grow.
khaytsus said:
Wow, went from zero of these to three or more.. More is good I guess! Does yours reconnect to the GPS when the connection is lost (walk away from the GPS, GPS accidentally gets turned off in pocket, etc)? What happens if you turn off the phone (hit power button.. standby), does it disconnect? Reconnect? What happens to apps while running, do they pick back up, or reconnect to the internal GPS?
EDIT: It disconnects. You should have it reconnect, especially if the signal was just lost watch for the device to become available again,
Click to expand...
Click to collapse
I don't have this kind of problems in my car, so I haven't planned anything for that. For now, I have preferred that, in case of problems, everything stops properly. However I will verify what I can do (if I can find a simple way to do this).
and it'd also be really nice if it could do it automatically even if not just used; ie I get in the car, fire up the Holux 236 and a few seconds later your program connects to it.
Click to expand...
Click to collapse
A priori, no good way for doing this with the sdk. If we have a background task, which runs looking for the GPS mouse to often it won't be good for the battery.
Generally you have to switch on the GPS, so It should not really be a problem to start the service at the same time, especially if, as I do, you plug the android device in a car dock...
Very very nice start, worked as well as the Bluetooth GPS Mouse program I've been using for a few weeks.. No sat or fix info, but that's a limitation of the Mock interface of course. Not much to be done there.
Click to expand...
Click to collapse
You can use the extra info in the location to have the number of sat used.
However, if Google has made a better Mock API, we should be able to use GPS Test directly...
Thanks for your comments,
Herbert
Hello,
I downloaded the file but that is not apk but zip and does not include any apy files.
Where can i download the bluegps4droid.apk file from? or How can I use the zip file in the android unit?
Thanks for the help
Sandor
Any Hope for Android 1.6?
I just tried Bluetooth GPS for Android but sadly found out it won't work with Android 1.6 such as used by my Archos 5 Internet Tablet.
Any hope for 1.6 support? Is it even possible?
I imagine the other two solutions suggested here were not found in my Market because they are 2.x only as well. Boo. I was so looking forward to this solving all my problems of the craptastic GPS in that device.
herbert1 said:
I didn't want to pay for something like that and I did not understand why I should give phone call or network access for such an application...
So I've have developed mine:
it' free,
it's open-source (you can verify what it's really doing and you can improve it!),
it just asks for needed permissions.
The application allows to use an external bluetooth GPS on Android devices:
The application starts a service, then connects to a Bluetooth device (NMEA GPS) and creates a mock GPS provider which can be used to replace the internal GPS.
It's also possible to log the external GPS NMEA data in a file on the device.
The app need the following permissions:
bluetooth and bluetooth admin (connection to the GPS device),
location and mock location (replace the GPS location provider by a new one using the bluetooth GPS device),
write external storage (if you want to log the NMEA data into a file on the sdcard).
It should run on all android devices (2.0 and above) and NMEA bluetooth devices.
I have tested it with a GlobalSat BT-338 bluetooth GPS (SiRF III), a Galaxy S (I9000) and a HTC Sapphire (Froyo CM-6).
It works with Google Maps, Wikitude, GoPenS and my own personal navigation app. It should work with all applications that use Android official location API.
Note: in order to install the app:
enable Settings/Applications/Unknown sources,
enable Settings/Applications/Development/Allow mock locations,
download and install the apk.
Project page:
Bluetooth GPS for Android on SourceForge
BlueGPS4Droid apk: BlueGps4Droid_1.0.apk
Click to expand...
Click to collapse
Any way you could port this to android 1.6 ? everyone with an archos needs this app cause the gps that is in it is terrible . Please please please port it to android 1.6 .
I've been in touch with a developer of one of these programs and unfortunately it is not possible to port these apps to 1.6 since 1.6 lacks some of the Bluetooth APIs/libraries needed for the functionality. Without a whole lot of messy programming it isn't possible for these apps to work on 1.6.
Can I use an USB GPS receivier instead of a Bluetooth one?
Stefem said:
Can I use an USB GPS receivier instead of a Bluetooth one?
Click to expand...
Click to collapse
I am not sure that such app exists...
Some devices (some tablets for example) have usb host capabilities, but not all of them.
If you can read the NMEA sentences from the USB GPS, it should be feasible (At least to adapt one of the app used with bluetooth GPS).
Thanks for this great App!
Wow!
Thanks Herbert1, this was exactly what I was looking for. I am using you app with a Samsung Galaxy S and a Columbus v900 BT GPS reciever. The reciever does the logging and is WAY faster and more accurate then the internal GPS android gives me.

[Q] network gps connection

Hi. I have a device, a Nook Color, that doesn't have a built in gps. I've seen applications that would allow an android phone to connect to a gps that's available via a bluetooth serial connection. What I would like to do is create a gps device on the nook that connects over a wireless network to a gps program (something like gpsd) and emulates all the behaviors needed for things like google maps.
Is this possible or does the gps these programs looking for have to be a hardware device?
Can someone give me an idea where to start? I do programming and device integration all the time but don't have a lot a familiarity with the internals of the android OS
Thanks

[Q] Does Xoom built in gps produce nmea data?

Turbo GPS, downloadable from Google Play has a feature that displays nmea sentences from a built in gps. However, although the built in gps is on and lat/long displays in Turbo GPS (and GPS Test), there is apparently no nmea sentence output by the gps. Is this attributable to the gps hardware, or a driver/software issue. I cannot yet post comments in the developer forum - especially the Xoom UMTS 3g Jellybean forum where custom ROMS are developed. So, if someone can raise this issue there I'd be very thankful.
I am downloading update 154 now and have been running 146.
Thanks,
armido
Have answer...
armido said:
Turbo GPS, downloadable from Google Play has a feature that displays nmea sentences from a built in gps. However, although the built in gps is on and lat/long displays in Turbo GPS (and GPS Test), there is apparently no nmea sentence output by the gps. Is this attributable to the gps hardware, or a driver/software issue. I cannot yet post comments in the developer forum - especially the Xoom UMTS 3g Jellybean forum where custom ROMS are developed. So, if someone can raise this issue there I'd be very thankful.
I am downloading update 154 now and have been running 146.
Thanks,
armido
Click to expand...
Click to collapse
Motorola confirms the Xoom's built in gps only gives position. The Xoom is probably not the only device who's gps does this. So, the gps is useless for programs that use nmea data - like OpenCPN. We need somebody to put together a server that uses positional information to generate 'fake' nmea data so our Xooms can use the built in gps with OpenCPN. Anyone able to help out there?
armido
Solution using internal gps with programs in chroot linux environment
armido said:
Motorola confirms the Xoom's built in gps only gives position. The Xoom is probably not the only device who's gps does this. So, the gps is useless for programs that use nmea data - like OpenCPN. We need somebody to put together a server that uses positional information to generate 'fake' nmea data so our Xooms can use the built in gps with OpenCPN. Anyone able to help out there?
armido
Click to expand...
Click to collapse
'GPS Share WIFI', downloadable from Google Play enables Xoom users to connect the built in gps with programs running in a linux chroot environment. No external router or other device required!

Categories

Resources