Gets the current speed of travel (in meters per second).
Returns a positive value (meters per second) if the call was successful, negative otherwise.
LocationGetSpeed() returns the speed of travel in meters per second. Since speed values can change many times between delivery of values, this information should be used for informational purposes only.
Speed data is not available on all devices, as it requires a GPS radio.
Windows Simulator NOTE: To provide values for the Windows Simulator, be sure to edit C:\DragonFireSDK\DragonFireSDK.ini and modify the value for Speed in the Location section.
NOTE: It is recommended to call LocationMonitorLocation() prior to calling LocationGetSpeed(). This gives the device time to begin receiving more and more accurate location data prior to getting location data. Subsequent calls to LocationGetSpeed() may become more accurate over time as the device pinpoints your location.
Available in DragonFireSDK 1.4 and later on devices with GPS.
// Begin monitoring location
MyFont = FontAdd("Helvetica", "Regular", 24, 0x00FF00);
SpeedText = TextAdd(10, 10, "Speed:", MyFont);
speed = LocationGetHorizontalAccuracy();
sprintf(TextBuffer, "Speed: %fm/s", speed);