|
LinksPoint GPS Toolkit Reference
|
// Palm OS
case SwitchProtocolButton:
{
GPSPROTOCOL gpProtocol = GpsGetProtocol();
switch (gpProtocol)
{
case GPSPROTOCOL_SIRF:
{
// Switch Protocol
SirfSwitchToNMEA(1, 1, 1, 3, 1, 1, 4800);
// Force message checking
GpsCheckForData(NULL, NULL);
// Wait 3 secs. for command processing
SysTaskDelay(SysTicksPerSecond() * 3);
GpsSetBaudRate(4800);
GpsSetProtocol(GPSPROTOCOL_NMEA);
}
break;
}
}
// Windows based platforms
case SwitchProtocolButton:
{
GPSPROTOCOL gpProtocol = GpsGetProtocol();
switch (gpProtocol)
{
case GPSPROTOCOL_SIRF:
{
// Switch Protocol
SirfSwitchToNMEA(1, 1, 1, 3, 1, 1, 4800);
// Wait 3 secs. for command processing
Sleep(3000);
GpsSetBaudRate(4800);
GpsSetProtocol(GPSPROTOCOL_NMEA);
}
break;
}
}| Parameters | Description |
| long lGLL | Latitude, longitude, UTC time of position fix, and status |
| long lGSA | GPS receiver operating mode, satellites used in the position solution, and DOP values |
| long lGSV | Number of GPS satellites in view, satellite ID numbers, elevation, azimuth, and SNR values |
| long lRMC | Time, date, position, course, and speed data |
| long lVTG | Course and speed information relative to ground |
| unsigned short usBaudRate | Baud rate |
See Example 1 for Palm OS or Example 2 for Windows based platforms.
GPSERROR GPSAPI SirfSwitchToNMEA(long lGGA, long lGLL, long lGSA, long lGSV, long lRMC, long lVTG, unsigned short usBaudRate);