C++ SDK

◆ GpsSwitchOn()

static int CApplicationAPI::GpsSwitchOn ( LpError  lpError,
LPCTSTR  lpszPort,
DWORD  dwBaudRate,
BOOL  bSwitchOn,
DWORD  dwMaxTime = DEFAULT_MAX_TIME 
)
static

The function turns Drive GPS module ON and OFF.

Parameters
lpErrorAdditional error information returned from Drive.
lpszPortName of port which is used to receive GPS signal.
dwBaudRateBaude rate used in GPS port.
bSwitchOnFlag determining whether GpsSwitchOn turns GPS module ON or OFF.
true - GpsSwitchOn turns GPS module ON.
false - GpsSwitchOn turns GPS module OFF.
dwMaxTimeMaximum time (in milliseconds) function can take. If dwMaxTime=0 function execution is not time limited.
Returns
1 if successful, other value otherwise.

Possible error codes returned from Drive are:

  • 0 - Function not succeeded.
  • 1 - Function succeeded.
  • 2 - Drive not succeeded. -3 - Function reached timeout.