Geosense AirBridge
Coupled with Adobe AIR 2's new NativeProcess API and Microsoft .NET Framework 4, AirBridge enables you to access the underlying Location platform in Windows 7.
Writing code around AirBridge is dead simple, take a look at our HTML-based walkthrough below (or download the compiled AIR 2 package).
HTML-based AIR 2 + AirBridge example
-
Download the AirBridge redistributable.
-
Write some code in your application's onLoad function:
-
Write the code responsible for handling STDOUT data (we use a JSON parser to do the hard work):
-
Do something cool with the data! (this is not an example of something cool)
var si = new air.NativeProcessStartupInfo();
si.executable = air.File.applicationDirectory.resolvePath("bin/AirBridge.exe");
p = new air.NativeProcess();
p.addEventListener(air.ProgressEvent.STANDARD_OUTPUT_DATA, OnOutputData);
p.start(si);
var text = p.standardOutput.readUTFBytes(p.standardOutput.bytesAvailable);
var data = JSON.parse(text);
...
document.body.innerText = 'Your lat/long is: ' + data["Latitude"] + ' ' + data["Longitude"];
Okay, what can you give me?
AirBridge accesses the underlying Location platform and formats the data into an easy-to-parse JSON string. More specifically, we provide you with the following fields:
|
|
Can I load the executable once, and request data indefinitely?
Not yet, sorry. Thankfully, AirBridge is still warm, malleable, and open to change. For now, you can set up a loop to "poll" the executable at a configured interval.
Can you tweak X, tinker Y for my Z application?
We are definitely open to your custom needs. Shoot us an email.