Interface to SUPL v1.0 Library. More...
Classes | |
struct | GLSUPL_PosTechnology |
SET Capabilities. More... | |
struct | GLSUPL_PosProtocol |
Positioning protocol. More... | |
struct | GLSUPL_SETCapabilities |
SET Capabilities. More... | |
struct | GLSUPL_Position |
Position. More... | |
struct | GLSUPL_SetID |
SET ID. More... | |
struct | GLSUPL_Session |
Session buffer. More... | |
struct | GLSUPL_Connection |
Connection. More... | |
Defines | |
SUPL API Version (implements SUPL 1.0.0 specification) | |
#define | GLSUPL_API_VER 2 |
Version number of API. | |
glsupl_DecodeSuplInit10 error code | |
#define | GL_SUPL_SUPLINIT 0 |
no error | |
#define | GL_SUPL_UNEXPECTED_MSG -2 |
unexpected message | |
#define | GL_SUPL_SMALL_TEMP_BUFFER -3 |
small temp buffer | |
#define | GL_SUPL_CONVERSION_ERROR -4 |
conversion error | |
Typedefs | |
typedef struct GLSUPL_PosTechnology | GLSUPL_PosTechnology |
SET Capabilities. | |
typedef enum GLSUPL_PrefMethod | GLSUPL_PrefMethod |
Preferred Method. | |
typedef struct GLSUPL_PosProtocol | GLSUPL_PosProtocol |
Positioning protocol. | |
typedef struct GLSUPL_SETCapabilities | GLSUPL_SETCapabilities |
SET Capabilities. | |
typedef struct GLSUPL_Position | GLSUPL_Position |
Position. | |
typedef enum GLSUPL_SetIDType | GLSUPL_SetIDType |
SET ID Type. | |
typedef struct GLSUPL_SetID | GLSUPL_SetID |
SET ID. | |
typedef enum GLSUPL_StatusCode | GLSUPL_StatusCode |
Status Code. | |
typedef struct GLSUPL_Session | GLSUPL_Session |
Session buffer. | |
typedef enum GLSUPL_ConnectionType | GLSUPL_ConnectionType |
Connection Type SLP address should be considered by client. | |
typedef enum GLSUPL_ConnectionPriority | GLSUPL_ConnectionPriority |
Connection Priority. | |
typedef struct GLSUPL_Connection | GLSUPL_Connection |
Connection. | |
typedef enum GLSUPL_LOG_SEVERITY | GLSUPL_LOG_SEVERITY |
Log severity. | |
Enumerations | |
enum | GLSUPL_PrefMethod |
Preferred Method. More... | |
enum | GLSUPL_SetIDType |
SET ID Type. More... | |
enum | GLSUPL_StatusCode { GLSUPL_unspecified = 0, GLSUPL_systemFailure = 1, GLSUPL_unexpectedMessage = 2, GLSUPL_protocolError = 3, GLSUPL_dataMissing = 4, GLSUPL_unexpectedDataValue = 5, GLSUPL_posMethodFailure = 6, GLSUPL_posMethodMismatch = 7, GLSUPL_posProtocolMismatch = 8, GLSUPL_targetSETnotReachable = 9, GLSUPL_versionNotSupported = 10, GLSUPL_resourceShortage = 11, GLSUPL_invalidSessionId = 12, GLSUPL_nonProxyModeNotSupported = 13, GLSUPL_proxyModeNotSupported = 14, GLSUPL_positioningNotPermitted = 15, GLSUPL_authNetFailure = 16, GLSUPL_authSuplinitFailure = 17, GLSUPL_consentDeniedByUser = 100, GLSUPL_consentGrantedByUser = 101, GLSUPL_unspecified = 0, GLSUPL_systemFailure = 1, GLSUPL_unexpectedMessage = 2, GLSUPL_protocolError = 3, GLSUPL_dataMissing = 4, GLSUPL_unexpectedDataValue = 5, GLSUPL_posMethodFailure = 6, GLSUPL_posMethodMismatch = 7, GLSUPL_posProtocolMismatch = 8, GLSUPL_targetSETnotReachable = 9, GLSUPL_versionNotSupported = 10, GLSUPL_resourceShortage = 11, GLSUPL_invalidSessionId = 12, GLSUPL_nonProxyModeNotSupported = 13, GLSUPL_proxyModeNotSupported = 14, GLSUPL_positioningNotPermitted = 15, GLSUPL_authNetFailure = 16, GLSUPL_authSuplinitFailure = 17, GLSUPL_incompatibleProtectionLevel = 18, GLSUPL_serviceNotSupported = 19, GLSUPL_insufficientInterval = 20, GLSUPL_noSUPLCoverage = 21, GLSUPL_consentDeniedByUser = 100, GLSUPL_consentGrantedByUser = 101, GLSUPL_sessionStopped = 102, GLSUPL_appIdDenied = 103 } |
Status Code. More... | |
enum | GLSUPL_ConnectionType { , GLSUPL_CONNECTION_URL, GLSUPL_CONNECTION_IPv4, GLSUPL_CONNECTION_IPv6 , GLSUPL_CONNECTION_URL, GLSUPL_CONNECTION_IPv4, GLSUPL_CONNECTION_IPv6 } |
Connection Type SLP address should be considered by client. More... | |
enum | GLSUPL_ConnectionPriority |
Connection Priority. | |
enum | GLSUPL_LOG_SEVERITY { LOG_SUPL_EMERG, LOG_SUPL_ALERT, LOG_SUPL_CRIT, LOG_SUPL_ERR, LOG_SUPL_WARNING, LOG_SUPL_NOTICE, LOG_SUPL_INFO, LOG_SUPL_DEBUG, LOG_SUPL_EMERG, LOG_SUPL_ALERT, LOG_SUPL_CRIT, LOG_SUPL_ERR, LOG_SUPL_WARNING, LOG_SUPL_NOTICE, LOG_SUPL_INFO, LOG_SUPL_DEBUG } |
Log severity. More... | |
Functions | |
SUPL API functions | |
GLSUPL_Session * | glsupl_Create () |
Create SUPL session. | |
void | glsupl_Abort (GLSUPL_Session *session) |
Abort SUPL session. | |
void | glsupl_AbortWithStatusCode (GLSUPL_Session *session, GLSUPL_StatusCode code) |
Abort SUPL session with status code. | |
GLBOOL | glsupl_Request (GLSUPL_Session *session, GLSUPL_QoP *qop) |
Start SUPL request. | |
void | glsupl_RequestAssistanceData (GLSUPL_Session *session, GLRRLP_RequestedAssistData *reqData) |
Response on glcb_supl_RequestAssistanceData() or can be called after receiving positioning request to request additional assistance data. | |
void | glsupl_SetPosition (GLSUPL_Session *session, const GLSUPL_Position *pPos) |
Response on glcb_supl_ReqPosition() | |
void | glsupl_ReportGpsMeasurements (GLSUPL_Session *session, const GLRRLP_GPS_MeasureInfo *pMes) |
Response to MSA request. | |
void | glsupl_ReportLocationInfo (GLSUPL_Session *session, const GLRRLP_LocationInfo *pLoc) |
Response to MSB or autonomous request. | |
void | glsupl_NetworkRequest (GLSUPL_Session *session, const unsigned char *pucBuf, int nBytes, const unsigned char *ver) |
Initiate Network Initiated request. | |
void | glsupl_Data (GLSUPL_Session *session, const unsigned char *pucBuf, int nBytes) |
This function should be called to deliver SUPL messages to GLL. | |
void | glsupl_SetCapabilities (GLSUPL_Session *session, const GLSUPL_SETCapabilities *pCap) |
Sets default capabilities for GLL SUPL protocol stack. | |
void | glsupl_GetCapabilities (GLSUPL_Session *session, GLSUPL_SETCapabilities *pCap) |
Gets capabilities from GLL SUPL protocol stack. | |
void | glsupl_SetTimers (GLSUPL_Session *session, unsigned long ut1, unsigned long ut2, unsigned long ut3) |
Allows to customize values for timers UT1, UT2, and UT3. | |
void | glsupl_Connect (GLSUPL_Session *session, GLBOOL bSuccess) |
Inform GLL SUPL protocol stack that SUPL connection has been established (bSuccess = 1) or not (bSuccess = 0) | |
void | glsupl_Disconnected (GLSUPL_Session *session) |
Inform GLL SUPL protocol stack that SUPL connection has been terminated. | |
GLBOOL | glsupl_SetID (GLSUPL_Session *session, const GLSUPL_SetID *pSuplSetID) |
Sets the SUPL ID in the GLL SUPL protocol stack. | |
void | glsupl_VerificationRsp (GLSUPL_Session *session, GLBOOL bAllow) |
Respond to glcb_supl_NotificationVerificationReq() | |
void | glsupl_SetLocationId (GLSUPL_Session *session, const GLSUPL_LocationId *pLocationId) |
Sets the Location Information for the LBS SUPL protocol stack. | |
SUPL helper functions | |
int | glsupl_DecodeSuplInit10 (const unsigned char *pBinaryBuffer, int nBinaryBytes, unsigned char *pTempBuffer, int nTempBytes, GLSUPL_SUPLINIT *pSUPLINIT) |
Decode SUPL INIT binary message to GLSUPL_SUPLINIT structure. | |
SUPL callbacks to apply Assistance Data | |
void | glcb_supl_SetReferenceTime (GLSUPL_Session *session, const GLRRLP_ReferenceTime *refTime) |
Reference Time. | |
void | glcb_supl_SetReferenceLocation (GLSUPL_Session *session, const GLRRLP_PositionEstimate *refLoc) |
Reference Location. | |
void | glcb_supl_SetAcquisitionAssistance (GLSUPL_Session *session, const GLRRLP_AcquisAssist *acqAssist) |
Acquisition Assistance. | |
void | glcb_supl_SetAlmanac (GLSUPL_Session *session, const GLRRLP_Almanac *alm) |
Almanac. | |
void | glcb_supl_SetNavModel (GLSUPL_Session *session, const GLRRLP_SeqOfNavModelElement *nav) |
Navigation Model. | |
void | glcb_supl_SetIonosphericModel (GLSUPL_Session *session, const GLRRLP_IonosphericModel *iono) |
Ionospheric Model. | |
void | glcb_supl_SetUTCModel (GLSUPL_Session *session, const GLRRLP_UTCModel *utc) |
UTC Model. | |
void | glcb_supl_SetDGPSCorrections (GLSUPL_Session *session, const GLRRLP_DGPSCorrections *dgpsc) |
DGPS Corrections. | |
void | glcb_supl_SetRTIntegrity (GLSUPL_Session *session, const GLRRLP_BadSatellites *rti) |
Real Time Integrity. | |
Timer functions | |
Returning GLFALSE will result in calling glcb_supl_DestroyTimer() | |
void * | glcb_supl_CreateTimer (GLSUPL_Session *session) |
Create Timer. | |
GLBOOL | glcb_supl_DisarmTimer (GLSUPL_Session *session, void *pTimer) |
Disarm Timer. | |
GLBOOL | glcb_supl_ArmTimer (GLSUPL_Session *session, void *pTimer, unsigned long ulMs) |
Arm Timer. | |
void | glcb_supl_DestroyTimer (GLSUPL_Session *session, void *pTimer) |
Destroy Timer. | |
void | glsupl_Timeout (GLSUPL_Session *session, void *pTimer) |
Timer Timeout. | |
SUPL callback functions | |
typedef void(* | CB_SuplNotify )(GLSUPL_Session *session, GLSUPL_MessageType code, void *data) |
Called by the SUPL engine to notify APR about all send and recieve messages. | |
void | glcb_supl_Log (GLSUPL_LOG_SEVERITY sev, const char *fmt,...) |
Log message. | |
void | glcb_supl_ExceptionAssert (const char *file, unsigned line, const char *msg) |
Exception Assert. | |
void | glcb_supl_ReportFromSuplEnd (GLSUPL_Session *session, const GLSUPL_Position *pos, const GLSUPL_StatusCode *code) |
Report position and status code information to the application when it is received from SLP (SUPL) server in SUPL_END message. | |
void | glcb_supl_SendingSuplEnd (GLSUPL_Session *session, const GLSUPL_StatusCode *code) |
Report status code information to the application before it sent to SLP (SUPL) server in SUPL_END message. | |
void | glcb_supl_Write (GLSUPL_Session *session, const unsigned char *data, unsigned nBytes) |
Called by the SUPL engine to write the encoded bytes to the network. | |
void | glcb_supl_ReqLocationId (GLSUPL_Session *session) |
Called by the SUPL engine to request the Cell Information. | |
void | glcb_supl_ReqPosition (GLSUPL_Session *session, GLSUPL_PosMethod posMethod, const GLSUPL_QoP *qop) |
Called by the SUPL engine to request the position of SET. | |
void | glcb_supl_RequestAssistanceData (GLSUPL_Session *session, GLSUPL_PosMethod method) |
Called by the SUPL engine to request the Assistance Data. | |
void | glcb_supl_ReqConnection (GLSUPL_Session *session) |
Called by the SUPL engine to request SUPL Connection. | |
void | glcb_supl_NotificationVerificationReq (GLSUPL_Session *session, const GLSUPL_Notification *notif) |
Called by the SUPL engine after receiving SUPL-INIT message. | |
void | glcb_supl_EndConnection (GLSUPL_Session *session) |
Called by the SUPL engine to inform that SUPL connection is no longer necessary. | |
void | glcb_supl_EndSession (GLSUPL_Session *session) |
Called by the SUPL engine to inform that all data associated with session is no longer necessary. | |
void * | glcb_supl_Allocate (unsigned long size) |
Called by the SUPL engine to allocate session. | |
void | glcb_supl_Deallocate (void *session) |
Called by the SUPL engine to deallocate session. | |
void | glcb_supl_StartSingleShot (GLSUPL_Session *session, const GLRRLP_PositionInstruct *positionInstruct) |
Called by the SUPL engine to execute positioning request for GLL engine. | |
GLBOOL | glcb_supl_SUPLINIT (GLSUPL_Session *session, const GLSUPL_SUPLINIT *suplInit) |
Called by the SUPL engine to notify ARP. | |
void | glsupl_SetNotifyCB (GLSUPL_Session *session, CB_SuplNotify cb) |
Interface to SUPL v1.0 Library.
Copyright 2001-2011 Broadcom Corporation -- http://www.broadcom.com This program is the proprietary software of Broadcom Corporation and/or its licensors, and may only be used, duplicated, modified or distributed pursuant to the terms and conditions of a separate, written license agreement executed between you and Broadcom (an "Authorized License"). Except as set forth in an Authorized License, Broadcom grants no license (express or implied), right to use, or waiver of any kind with respect to the Software, and Broadcom expressly reserves all rights in and to the Software and all intellectual property rights therein. IF YOU HAVE NO AUTHORIZED LICENSE, THEN YOU HAVE NO RIGHT TO USE THIS SOFTWARE IN ANY WAY, AND SHOULD IMMEDIATELY NOTIFY BROADCOM AND DISCONTINUE ALL USE OF THE SOFTWARE.
Please refer to OMA SUPL 1.0 specification and 3GPP RRLP specification for more information
SUPL: OMA-ERP-SUPL-V1_0-20070615-A RRLP: 3GPP TS 44.031 V5.12.0
#define GLSUPL_API_VER 2 |
Version number of API.
typedef void(* CB_SuplNotify)(GLSUPL_Session *session, GLSUPL_MessageType code, void *data) |
Called by the SUPL engine to notify APR about all send and recieve messages.
code | - type of SUPL message. |
data | - optional data associated with message (NULL, if not present) for SUPLEND data contains statusCode, if the code is present |
typedef enum GLSUPL_ConnectionType GLSUPL_ConnectionType |
Connection Type SLP address should be considered by client.
This type can be used with SET originated connections when SLP address is unknown to build-in SUPL engine.
typedef struct GLSUPL_Position GLSUPL_Position |
Position.
This parameter describes the position of the SET. The parameter also contains a timestamp and optionally the velocity. timestamp format as defined in ASN.1 specification as UTCTime: yymmddhhnnssZ where: yy - year mm - month [01..12] hh - hour [00..23] nn - minutes [00..59] ss - seconds [00..59] Z - character indicating UTC (or Zulu) time.
Reference: OMA SUPL TS (Section 7.7 Position).
ASN.1 specification:
Position ::= SEQUENCE { timestamp UTCTime, -- shall include seconds and shall use UTC time. positionEstimate PositionEstimate, velocity Velocity OPTIONAL, ... }
typedef struct GLSUPL_PosProtocol GLSUPL_PosProtocol |
Positioning protocol.
Zero or more of the following positioning protocols (bitmap):
Reference: OMA SUPL TS (Section 7.10 SET capabilities).
ASN.1 specification:
PosProtocol ::= SEQUENCE { tia801 BOOLEAN, rrlp BOOLEAN, rrc BOOLEAN, ... }
typedef struct GLSUPL_PosTechnology GLSUPL_PosTechnology |
SET Capabilities.
This section contains descriptions of the SUPL library portion of the LBS.
Structures defined according to OMA-TS-SUPL-V1_0-20050223-D
Reference: OMA SUPL TS (Section 7. Parameter Definitions).
SUPL API functions
SUPL structures Positioning Technology. Defines the positioning technology. Zero or more of the following positioning technologies (bitmap):
Reference: OMA SUPL TS (Section 7.10 SET capabilities).
ASN.1 specification:
PosTechnology ::= SEQUENCE { agpsSETassisted BOOLEAN, agpsSETBased BOOLEAN, autonomousGPS BOOLEAN, aFLT BOOLEAN, eCID BOOLEAN, eOTD BOOLEAN, ... }
typedef enum GLSUPL_PrefMethod GLSUPL_PrefMethod |
Preferred Method.
One of the following preferred modes:
Reference: OMA SUPL TS (Section 7.10 SET capabilities).
ASN.1 specification:
PrefMethod ::= ENUMERATED { agpsSETassistedPreferred, agpsSETBasedPreferred, noPreference }
typedef struct GLSUPL_SETCapabilities GLSUPL_SETCapabilities |
SET Capabilities.
SET capabilities (not mutually exclusive) in terms of supported positioning technologies and positioning protocols.
Reference: OMA SUPL TS (Section 7.10 SET capabilities).
ASN.1 specification:
SETCapabilities ::= SEQUENCE { posTechnology PosTechnology, prefMethod PrefMethod, posProtocol PosProtocol, ... }
typedef struct GLSUPL_SetID GLSUPL_SetID |
SET ID.
SET identity value. This parameter can be of type:
Reference: OMA SUPL TS (Section 7.14.1 SET Session ID).
ASN.1 specification:
SETId ::= CHOICE { msisdn OCTET STRING(SIZE (8)), mdn OCTET STRING(SIZE (8)), min BIT STRING(SIZE (34)), -- coded according to TIA-553 imsi OCTET STRING(SIZE (8)), nai IA5String(SIZE (1..1000)), iPAddress IPAddress, ... }
typedef enum GLSUPL_SetIDType GLSUPL_SetIDType |
SET ID Type.
SET Session ID type.
Reference: OMA SUPL TS (Section 7.14.1 SET Session ID)
typedef enum GLSUPL_StatusCode GLSUPL_StatusCode |
Status Code.
The different status codes, either error or information indicators, as described in the table below.
Reference: OMA SUPL TS (Section 7.6 Status Code)
Connection Type SLP address should be considered by client.
This type can be used with SET originated connections when SLP address is unknown to build-in SUPL engine.
enum GLSUPL_LOG_SEVERITY |
Log severity.
enum GLSUPL_PrefMethod |
Preferred Method.
One of the following preferred modes:
Reference: OMA SUPL TS (Section 7.10 SET capabilities).
ASN.1 specification:
PrefMethod ::= ENUMERATED { agpsSETassistedPreferred, agpsSETBasedPreferred, noPreference }
enum GLSUPL_SetIDType |
SET ID Type.
SET Session ID type.
Reference: OMA SUPL TS (Section 7.14.1 SET Session ID)
enum GLSUPL_StatusCode |
Status Code.
The different status codes, either error or information indicators, as described in the table below.
Reference: OMA SUPL TS (Section 7.6 Status Code)
void* glcb_supl_Allocate | ( | unsigned long | size | ) |
Called by the SUPL engine to allocate session.
size | - size of required memory |
void glcb_supl_Deallocate | ( | void * | session | ) |
Called by the SUPL engine to deallocate session.
session | - pointer to previously allocated session. |
void glcb_supl_EndConnection | ( | GLSUPL_Session * | session | ) |
Called by the SUPL engine to inform that SUPL connection is no longer necessary.
Inform that connection to SLP server can be closed.
void glcb_supl_EndSession | ( | GLSUPL_Session * | session | ) |
Called by the SUPL engine to inform that all data associated with session is no longer necessary.
Inform that all requests can be stoped.
void glcb_supl_ExceptionAssert | ( | const char * | file, |
unsigned | line, | ||
const char * | msg | ||
) |
Exception Assert.
file | - file name. |
line | - line number. |
msg | - message. |
void glcb_supl_Log | ( | GLSUPL_LOG_SEVERITY | sev, |
const char * | fmt, | ||
... | |||
) |
Log message.
sev | - Log level. |
fmt,... | - format and message (printf format) |
void glcb_supl_NotificationVerificationReq | ( | GLSUPL_Session * | session, |
const GLSUPL_Notification * | notif | ||
) |
Called by the SUPL engine after receiving SUPL-INIT message.
Inform that SLP requests for Notification & Verification
session | - |
notif | - Describes the notification/verification mechanism to be applied. |
void glcb_supl_ReportFromSuplEnd | ( | GLSUPL_Session * | session, |
const GLSUPL_Position * | pos, | ||
const GLSUPL_StatusCode * | code | ||
) |
Report position and status code information to the application when it is received from SLP (SUPL) server in SUPL_END message.
session | - [in] pointer to SUPL session, can not be NULL. |
pos | - [in] pointer to position reported in SUPL END, can be NULL. |
code | - [in] pointer to status code in SUPL END, can be NULL. |
void glcb_supl_ReqConnection | ( | GLSUPL_Session * | session | ) |
Called by the SUPL engine to request SUPL Connection.
SUPL Protocol stack waiting for glsupl_Connect() call which will inform about the result of this request.
void glcb_supl_SendingSuplEnd | ( | GLSUPL_Session * | session, |
const GLSUPL_StatusCode * | code | ||
) |
Report status code information to the application before it sent to SLP (SUPL) server in SUPL_END message.
session | - [in] pointer to SUPL session, can not be NULL. |
code | - [in] pointer to status code in SUPL END, can be NULL. |
void glcb_supl_SetAcquisitionAssistance | ( | GLSUPL_Session * | session, |
const GLRRLP_AcquisAssist * | acqAssist | ||
) |
Acquisition Assistance.
session | - |
acqAssist | - GPS Acquisition Assistance. |
void glcb_supl_SetAlmanac | ( | GLSUPL_Session * | session, |
const GLRRLP_Almanac * | alm | ||
) |
Almanac.
session | - pointer to SUPL session. |
alm | - GPS Almanac. |
void glcb_supl_SetDGPSCorrections | ( | GLSUPL_Session * | session, |
const GLRRLP_DGPSCorrections * | dgpsc | ||
) |
DGPS Corrections.
session | - pointer to SUPL session. |
dgpsc | - GPS DGPS Corrections. |
void glcb_supl_SetIonosphericModel | ( | GLSUPL_Session * | session, |
const GLRRLP_IonosphericModel * | iono | ||
) |
Ionospheric Model.
session | - pointer to SUPL session. |
iono | - GPS Ionospheric Model. |
void glcb_supl_SetNavModel | ( | GLSUPL_Session * | session, |
const GLRRLP_SeqOfNavModelElement * | nav | ||
) |
Navigation Model.
session | - pointer to SUPL session. |
nav | - GPS Navigation Model. |
void glcb_supl_SetReferenceLocation | ( | GLSUPL_Session * | session, |
const GLRRLP_PositionEstimate * | refLoc | ||
) |
Reference Location.
session | - pointer to SUPL session. |
refLoc | - GPS Reference Location. |
void glcb_supl_SetReferenceTime | ( | GLSUPL_Session * | session, |
const GLRRLP_ReferenceTime * | refTime | ||
) |
Reference Time.
session | - pointer to SUPL session. |
refTime | - GPS Reference Time. |
void glcb_supl_SetRTIntegrity | ( | GLSUPL_Session * | session, |
const GLRRLP_BadSatellites * | rti | ||
) |
Real Time Integrity.
session | - pointer to SUPL session. |
rti | - GPS Real Time Integrity. |
void glcb_supl_SetUTCModel | ( | GLSUPL_Session * | session, |
const GLRRLP_UTCModel * | utc | ||
) |
UTC Model.
session | - pointer to SUPL session. |
utc | - GPS UTC Model. |
void glcb_supl_StartSingleShot | ( | GLSUPL_Session * | session, |
const GLRRLP_PositionInstruct * | positionInstruct | ||
) |
Called by the SUPL engine to execute positioning request for GLL engine.
session | - pointer to previously allocated session. |
positionInstruct | - parameters of positioning request. |
void glcb_supl_Write | ( | GLSUPL_Session * | session, |
const unsigned char * | data, | ||
unsigned | nBytes | ||
) |
Called by the SUPL engine to write the encoded bytes to the network.
session | - [in] pointer to SUPL session, can not be NULL. |
data | - [in] address of buffer for send. |
nBytes | - [in] length of buffer. |
void glsupl_Abort | ( | GLSUPL_Session * | session | ) |
Abort SUPL session.
session | - pointer to SUPL session. |
none. |
void glsupl_AbortWithStatusCode | ( | GLSUPL_Session * | session, |
GLSUPL_StatusCode | code | ||
) |
Abort SUPL session with status code.
session | - pointer to SUPL session. |
code | - SUPL status code. |
none. |
void glsupl_Connect | ( | GLSUPL_Session * | session, |
GLBOOL | bSuccess | ||
) |
Inform GLL SUPL protocol stack that SUPL connection has been established (bSuccess = 1) or not (bSuccess = 0)
session | - pointer to SUPL session. |
bSuccess | 0 - unsuccessful, 1 - successful |
Create SUPL session.
pointer | to the newly created SUPL session. |
void glsupl_Data | ( | GLSUPL_Session * | session, |
const unsigned char * | pucBuf, | ||
int | nBytes | ||
) |
This function should be called to deliver SUPL messages to GLL.
session | - pointer to SUPL session. |
pucBuf | - pointer to the buffer containing the bytes. |
nBytes | - number of bytes received (may be zero) |
int glsupl_DecodeSuplInit10 | ( | const unsigned char * | pBinaryBuffer, |
int | nBinaryBytes, | ||
unsigned char * | pTempBuffer, | ||
int | nTempBytes, | ||
GLSUPL_SUPLINIT * | pSUPLINIT | ||
) |
Decode SUPL INIT binary message to GLSUPL_SUPLINIT structure.
pBinaryBuffer | [in] - pointer to SUPL INIT binary message. |
nBinaryBytes | [in] - size of Binary buffer. |
pTempBuffer | [in] - pointer to temp buffer for conversion. |
nTempBytes | [in] - size of temp buffer. |
pSUPLINIT | [in,out] - pointer to resulting structure. |
Buffer size request mode:
int nRequestedTempBufferSize = glsupl_DecodeSuplInit10(0,0,0,0,0);
Decoding mode:
int nErrorCode = glsupl_DecodeSuplInit10(pBinaryBuffer, nBinaryBytes, pTempBuffer, nTempBytes, pSUPLINIT);
void glsupl_Disconnected | ( | GLSUPL_Session * | session | ) |
Inform GLL SUPL protocol stack that SUPL connection has been terminated.
session | - pointer to SUPL session. |
void glsupl_GetCapabilities | ( | GLSUPL_Session * | session, |
GLSUPL_SETCapabilities * | pCap | ||
) |
Gets capabilities from GLL SUPL protocol stack.
void glsupl_NetworkRequest | ( | GLSUPL_Session * | session, |
const unsigned char * | pucBuf, | ||
int | nBytes, | ||
const unsigned char * | ver | ||
) |
Initiate Network Initiated request.
session | - pointer to SUPL session. |
pucBuf | - pointer to a buffer with binary coded Network initiated message. |
nBytes | - size of this message. |
ver | - can be HMAC of pucBuf(SUPL_INIT) (described in SUPL 1.0 spec), in this case MUST be 8 bytes array. Refer to GpsHalSuplInitPrepareVer() for additional information |
ver | - or can be key-string for calculation HMAC of pucBuf(SUPL_INIT) inside SUPL stack. |
void glsupl_ReportGpsMeasurements | ( | GLSUPL_Session * | session, |
const GLRRLP_GPS_MeasureInfo * | pMes | ||
) |
Response to MSA request.
session | - pointer to SUPL session. |
pMes | - GPS Measurement Information. |
void glsupl_ReportLocationInfo | ( | GLSUPL_Session * | session, |
const GLRRLP_LocationInfo * | pLoc | ||
) |
Response to MSB or autonomous request.
session | - pointer to SUPL session. |
pLoc | - Location Info. |
GLBOOL glsupl_Request | ( | GLSUPL_Session * | session, |
GLSUPL_QoP * | qop | ||
) |
Start SUPL request.
It will be SET-initiated session.
session | - pointer to SUPL session. |
qop | - Desired Quality of Position. |
void glsupl_RequestAssistanceData | ( | GLSUPL_Session * | session, |
GLRRLP_RequestedAssistData * | reqData | ||
) |
Response on glcb_supl_RequestAssistanceData() or can be called after receiving positioning request to request additional assistance data.
session | - pointer to SUPL session. |
reqData | - Requested Assist Data. |
void glsupl_SetCapabilities | ( | GLSUPL_Session * | session, |
const GLSUPL_SETCapabilities * | pCap | ||
) |
Sets default capabilities for GLL SUPL protocol stack.
GLBOOL glsupl_SetID | ( | GLSUPL_Session * | session, |
const GLSUPL_SetID * | pSuplSetID | ||
) |
Sets the SUPL ID in the GLL SUPL protocol stack.
session | - pointer to SUPL session. |
pSuplSetID | - pointer to structure defining SUPL SET ID |
void glsupl_SetLocationId | ( | GLSUPL_Session * | session, |
const GLSUPL_LocationId * | pLocationId | ||
) |
Sets the Location Information for the LBS SUPL protocol stack.
session | - pointer to SUPL session. |
pLocationId | - pointer to a location information structure. |
void glsupl_SetPosition | ( | GLSUPL_Session * | session, |
const GLSUPL_Position * | pPos | ||
) |
Response on glcb_supl_ReqPosition()
session | - pointer to SUPL session. |
pPos | - position of the SET. |
void glsupl_SetTimers | ( | GLSUPL_Session * | session, |
unsigned long | ut1, | ||
unsigned long | ut2, | ||
unsigned long | ut3 | ||
) |
Allows to customize values for timers UT1, UT2, and UT3.
session | - pointer to SUPL session. |
ut1 | - UT1 timer in milliseconds, default value is 10000 ms. |
ut2 | - UT2 timer in milliseconds, default value is 10000 ms. |
ut3 | - UT3 timer in milliseconds, default value is 10000 ms. |
void glsupl_VerificationRsp | ( | GLSUPL_Session * | session, |
GLBOOL | bAllow | ||
) |
Respond to glcb_supl_NotificationVerificationReq()
session | - pointer to SUPL session. |
bAllow | 1 - allow positioning info, 0 - deny |