b.liu | e958203 | 2025-04-17 19:18:16 +0800 | [diff] [blame^] | 1 | /********************************************************************* |
| 2 | * All Rights Reserved |
| 3 | * |
| 4 | * MARVELL CONFIDENTIAL |
| 5 | * Copyright 2012 Marvell International Ltd All Rights Reserved. |
| 6 | * The source code contained or described herein and all documents related to |
| 7 | * the source code ("Material") are owned by Marvell International Ltd or its |
| 8 | * suppliers or licensors. Title to the Material remains with Marvell International Ltd |
| 9 | * or its suppliers and licensors. The Material contains trade secrets and |
| 10 | * proprietary and confidential information of Marvell or its suppliers and |
| 11 | * licensors. The Material is protected by worldwide copyright and trade secret |
| 12 | * laws and treaty provisions. No part of the Material may be used, copied, |
| 13 | * reproduced, modified, published, uploaded, posted, transmitted, distributed, |
| 14 | * or disclosed in any way without Marvell's prior express written permission. |
| 15 | * |
| 16 | * No license under any patent, copyright, trade secret or other intellectual |
| 17 | * property right is granted to or conferred upon you by disclosure or delivery |
| 18 | * of the Materials, either expressly, by implication, inducement, estoppel or |
| 19 | * otherwise. Any license under such intellectual property rights must be |
| 20 | * express and approved by Marvell in writing. |
| 21 | * |
| 22 | **********************************************************************/ |
| 23 | |
| 24 | |
| 25 | /*! \file hsm_mwif_api.h |
| 26 | \brief . |
| 27 | |
| 28 | */ |
| 29 | |
| 30 | #ifndef _HSM_API_H_ |
| 31 | #define _HSM_API_H_ |
| 32 | |
| 33 | #ifdef __cplusplus |
| 34 | extern "C" { |
| 35 | #endif |
| 36 | |
| 37 | #include "gps_types.h" |
| 38 | #include "gps_oal.h" |
| 39 | |
| 40 | #define GPS_STATE_SUCCESS 0 |
| 41 | #define GPS_STATE_FAIL -1 |
| 42 | |
| 43 | #define GPS_NMEA_STRING_MAXLEN 1024 |
| 44 | #define AGPS_MAX_NOTIFYID_LEN 50 |
| 45 | |
| 46 | #define GPS_MAX_SVS 32 |
| 47 | #define GLN_MAX_SVS 24 |
| 48 | |
| 49 | #define QZSS_MAX_SVS 5 |
| 50 | #define QZSS_MIN_SV_PRN 193 |
| 51 | #define QZSS_MAX_SV_PRN 197 |
| 52 | |
| 53 | #define WAAS_MAX_SVS 19 |
| 54 | #define WAAS_MIN_SV_PRN 120 |
| 55 | #define WAAS_MAX_SV_PRN 138 |
| 56 | |
| 57 | #define TRK_CHAN_MAX 40 |
| 58 | #define MAX_TESTMODE_SV_NUM 12 |
| 59 | #define GPS_DLBLOCK_TIME 40 |
| 60 | #define MAX_PDU_SIZE 8192 |
| 61 | |
| 62 | |
| 63 | |
| 64 | #define MAX_UTRA_RESULT_FREQS (8) |
| 65 | #define MAX_UTRA_RESULT_CELLS (32) /*< This is ASN.1, but can be reduced to save resources */ |
| 66 | #define MAX_NMR_CELLS (15) |
| 67 | #define GPS_HSM_MEAS_RESULT_LIST_LENGTH (32) |
| 68 | |
| 69 | #define MRVL_INTEG_TEST_START 0 //test start |
| 70 | #define MRVL_INTEG_TEST_1 1 //Integrity test 1,all tracking channels track one SV at one signal level |
| 71 | #define MRVL_INTEG_TEST_2 2 //Integrity test 2, all tracking channels track one SV at two signal level |
| 72 | #define MRVL_INTEG_TEST_3 3 //week acquisition test |
| 73 | #define MRVL_INTEG_TEST_4 4 //CW test |
| 74 | #define MRVL_INTEG_TEST_5 5 //Live fix test |
| 75 | #define MRVL_INTEG_TEST_6 6 //live fix test for AGPS |
| 76 | #define MRVL_INTEG_TEST_7 7 //Glonass single channel test |
| 77 | #define MRVL_INTEG_TEST_8 8 //Glonass multi channel test |
| 78 | #define MRVL_INTEG_TEST_9 9 //UART communication check |
| 79 | #define MRVL_INTEG_TEST_10 10 //CW test on GLN path |
| 80 | #define MRVL_INTEG_TEST_MAX (MRVL_INTEG_TEST_10+1) |
| 81 | #define MRVL_INTEG_TEST_READ 250 // read |
| 82 | #define MRVL_INTEG_TEST_RST 251 // reset chip |
| 83 | #define MRVL_INTEG_TEST_END 255 |
| 84 | |
| 85 | #define MRVLGPS_MAX_FREQ_LAYERS 3 |
| 86 | |
| 87 | enum |
| 88 | { |
| 89 | MRVLGPS_WORKMODE_NORMAL, |
| 90 | MRVLGPS_WORKMODE_FACTORY_TEST |
| 91 | }; |
| 92 | |
| 93 | typedef enum |
| 94 | { |
| 95 | MRVL_INTEG_TEST_STATUS_NONE = -2, |
| 96 | MRVL_INTEG_TEST_STATUS_RST = -1, |
| 97 | MRVL_INTEG_TEST_STATUS_INIT = 0, |
| 98 | MRVL_INTEG_TEST_STATUS_MODE1, |
| 99 | MRVL_INTEG_TEST_STATUS_MODE2, |
| 100 | MRVL_INTEG_TEST_STATUS_MODE3, |
| 101 | MRVL_INTEG_TEST_STATUS_MODE4, |
| 102 | MRVL_INTEG_TEST_STATUS_MODE5, |
| 103 | MRVL_INTEG_TEST_STATUS_MODE6, |
| 104 | MRVL_INTEG_TEST_STATUS_MODE7, |
| 105 | MRVL_INTEG_TEST_STATUS_MODE8, |
| 106 | MRVL_INTEG_TEST_STATUS_MODE9, |
| 107 | MRVL_INTEG_TEST_STATUS_MODE10, |
| 108 | MRVL_INTEG_TEST_STATUS_MAX |
| 109 | } |
| 110 | INTEG_TEST_STATUS; |
| 111 | |
| 112 | enum |
| 113 | { |
| 114 | GPS_HSM_SENSOR_TYPE_ACC = 1, |
| 115 | GPS_HSM_SENSOR_TYPE_MAG = 2, |
| 116 | GPS_HSM_SENSOR_TYPE_GYRO = 4, |
| 117 | GPS_HSM_SENSOR_TYPE_BARO = 6 |
| 118 | }; |
| 119 | |
| 120 | enum |
| 121 | { |
| 122 | GPS_HSM_MOLR_PREF_NONE = 0, |
| 123 | GPS_HSM_MOLR_PREF_CPLANE = 1, |
| 124 | GPS_HSM_MOLR_PREF_SUPL = 2 |
| 125 | }; |
| 126 | |
| 127 | |
| 128 | typedef enum Agps_SessionPriorityTag |
| 129 | { |
| 130 | AGPS_SESS_PRIORITY_UNKNOWN = 0, |
| 131 | AGPS_SESS_PRIORITY_EMERGENCY = 1, |
| 132 | AGPS_SESS_PRIORITY_LCS = 2, |
| 133 | } |
| 134 | Agps_SessionPriority_t; |
| 135 | |
| 136 | typedef enum Rrc_PduTypeTag |
| 137 | { |
| 138 | RRC_PDUTYPE_MEASCONTROLFAILURE, |
| 139 | RRC_PDUTYPE_MEASREPORT, |
| 140 | RRC_PDUTYPE_RRCSTATUS, |
| 141 | RRC_PDUTYPE_DL_DCCH, |
| 142 | RRC_PDUTYPE_SIB_BCH, |
| 143 | } |
| 144 | Rrc_PduType_t; |
| 145 | |
| 146 | |
| 147 | typedef enum AgpsRrcStateTag |
| 148 | { |
| 149 | AGPS_RRCSTATE_IDLE = 0, /* Idle State. */ |
| 150 | AGPS_RRCSTATE_CELL_DCH, /* Cell DCH Connected State. */ |
| 151 | AGPS_RRCSTATE_CELL_FACH, /* Cell FACH Connected State. */ |
| 152 | AGPS_RRCSTATE_CELL_PCH, /* Cell PCH Connected State. */ |
| 153 | AGPS_RRCSTATE_URA_PCH, /* URA PCH Connected State. */ |
| 154 | AGPS_RRCSTATE_INVALID /* Invalid State. */ |
| 155 | } |
| 156 | AgpsRrcState_t; |
| 157 | |
| 158 | typedef enum AgpsSystemStateTag |
| 159 | { |
| 160 | AGPS_SYSTEM_NONE = 0x0, /* None. */ |
| 161 | AGPS_SYSTEM_GSM = 0x1, /* GSM system */ |
| 162 | AGPS_SYSTEM_WCDMA = 0x2, /* UMTS system */ |
| 163 | AGPS_SYSTEM_LTE = 0x20, /* LTE network. */ |
| 164 | AGPS_SYSTEM_NETWORK_TYPE_MAX_LAST = 0x7FFFFFFF |
| 165 | } |
| 166 | mrvlGpsHsmNetworkType_t; |
| 167 | |
| 168 | typedef enum |
| 169 | { |
| 170 | AGPS_PROTOCOL_RRC, |
| 171 | AGPS_PROTOCOL_RRLP, |
| 172 | AGPS_PROTOCOL_LPP, |
| 173 | AGPS_PROTOCOL_SUPL, |
| 174 | |
| 175 | NUM_AGPS_PROTOCOLS, |
| 176 | |
| 177 | } AgpsProtocol_t; |
| 178 | |
| 179 | |
| 180 | enum |
| 181 | { |
| 182 | GPS_HSM_DELETE_EPHEMERIS = 0x0001, |
| 183 | GPS_HSM_DELETE_ALMANAC = 0x0002, |
| 184 | GPS_HSM_DELETE_POSITION = 0x0004, |
| 185 | GPS_HSM_DELETE_TIME = 0x0008, |
| 186 | GPS_HSM_DELETE_IONO = 0x0010, |
| 187 | GPS_HSM_DELETE_UTC = 0x0020, |
| 188 | GPS_HSM_DELETE_HEALTH = 0x0040, |
| 189 | GPS_HSM_DELETE_SVDIR = 0x0080, |
| 190 | GPS_HSM_DELETE_SVSTEER = 0x0100, |
| 191 | GPS_HSM_DELETE_SADATA = 0x0200, |
| 192 | GPS_HSM_DELETE_RTI = 0x0400, |
| 193 | GPS_HSM_DELETE_CELLDB_INFO = 0x8000, |
| 194 | GPS_HSM_DELETE_ALL = 0xFFFF |
| 195 | }; |
| 196 | |
| 197 | typedef struct |
| 198 | { |
| 199 | int prn; |
| 200 | float cno; |
| 201 | float elevation; /* degrees */ |
| 202 | float azimuth; /* degrees */ |
| 203 | } mrvlGpsSvInfo_t; |
| 204 | |
| 205 | typedef struct |
| 206 | { |
| 207 | U16 num_svs; |
| 208 | mrvlGpsSvInfo_t sv_list[GPS_MAX_SVS]; |
| 209 | U32 ephemeris_mask; |
| 210 | U32 almanac_mask; |
| 211 | U32 used_in_fix_mask; |
| 212 | } mrvlGpsSvStatus_t; |
| 213 | |
| 214 | typedef struct |
| 215 | { |
| 216 | U16 num_svs_gln; |
| 217 | mrvlGpsSvInfo_t gln_sv_list[GLN_MAX_SVS]; |
| 218 | U32 gln_ephemeris_mask; |
| 219 | U32 gln_almanac_mask; |
| 220 | U32 gln_used_in_fix_mask; |
| 221 | } mrvlGlnSvStatus_t; |
| 222 | |
| 223 | typedef struct |
| 224 | { |
| 225 | U16 num_svs_waas; |
| 226 | mrvlGpsSvInfo_t waas_sv_list[WAAS_MAX_SVS]; |
| 227 | U32 waas_ephemeris_mask; |
| 228 | U32 waas_almanac_mask; |
| 229 | U32 waas_used_in_fix_mask; |
| 230 | } mrvlWaasSvStatus_t; |
| 231 | |
| 232 | typedef struct |
| 233 | { |
| 234 | U16 num_svs_qzss; |
| 235 | mrvlGpsSvInfo_t qzss_sv_list[QZSS_MAX_SVS]; |
| 236 | U32 qzss_ephemeris_mask; |
| 237 | U32 qzss_almanac_mask; |
| 238 | U32 qzss_used_in_fix_mask; |
| 239 | } mrvlQzssSvStatus_t; |
| 240 | |
| 241 | typedef struct |
| 242 | { |
| 243 | mrvlGpsSvStatus_t gps_sv_status; |
| 244 | mrvlGlnSvStatus_t gln_sv_status; |
| 245 | mrvlWaasSvStatus_t waas_sv_status; |
| 246 | mrvlQzssSvStatus_t qzss_sv_status; |
| 247 | } mrvlGnssSvStatus_t; |
| 248 | |
| 249 | typedef struct |
| 250 | { |
| 251 | DBL latitude; |
| 252 | DBL longitude; |
| 253 | DBL altitude; // wgs84 hae |
| 254 | float speed; // speed (horizontal) |
| 255 | float bearing; // direction of velocity (degrees) |
| 256 | float accuracy; |
| 257 | DBL timestamp; |
| 258 | U32 weekNumber; |
| 259 | FLT vVel; |
| 260 | FLT hPosErr; |
| 261 | FLT vPosErr; |
| 262 | FLT ePosErr; |
| 263 | FLT nPosErr; |
| 264 | FLT hVelErr; |
| 265 | FLT vVelErr; |
| 266 | S32 usedAssistance; |
| 267 | } mrvlGpsLocation_t; |
| 268 | |
| 269 | typedef struct |
| 270 | { |
| 271 | DBL utcTime; |
| 272 | U16 msgLen; |
| 273 | S8 nmeaInfo[GPS_NMEA_STRING_MAXLEN]; |
| 274 | } mrvlGpsNmea_t; |
| 275 | |
| 276 | |
| 277 | typedef enum |
| 278 | { |
| 279 | GPS_HSM_STOP_INITIAL = 1, |
| 280 | GPS_HSM_STOP_NORMAL_APP, |
| 281 | GPS_HSM_STOP_NORMAL_HSM, |
| 282 | GPS_HSM_STOP_NORMAL_APP_DEFERRED, |
| 283 | GPS_HSM_STOP_NORMAL_FAKE |
| 284 | } mrvlGpsHsmStopMode_t; |
| 285 | |
| 286 | typedef enum |
| 287 | { |
| 288 | GPS_HSM_STATUS_INVALID, |
| 289 | GPS_HSM_STATUS_ON, |
| 290 | GPS_HSM_STATUS_STARTED, |
| 291 | GPS_HSM_STATUS_STOPPED, |
| 292 | GPS_HSM_STATUS_OFF |
| 293 | } mrvlGpsHsmStatus_t; |
| 294 | |
| 295 | typedef enum |
| 296 | { |
| 297 | GPS_HSM_CHIP_STATE_AWAKE, |
| 298 | GPS_HSM_CHIP_STATE_SLEEP, |
| 299 | GPS_HSM_AGPS_SUPL_NI_START, |
| 300 | GPS_HSM_AGPS_SUPL_NI_STOP, |
| 301 | GPS_HSM_AGPS_CPLANE_MTLR_START, |
| 302 | GPS_HSM_AGPS_CPLANE_MTLR_STOP, |
| 303 | GPS_HSM_AGPS_CPLANE_NILR_START, |
| 304 | GPS_HSM_AGPS_CPLANE_NILR_STOP, |
| 305 | GPS_HSM_AGPS_SUPL_TCP_CONNECT_ATTEMPT, |
| 306 | GPS_HSM_AGPS_SUPL_TCP_CONNECT_SUCCESS, |
| 307 | GPS_HSM_AGPS_SUPL_TCP_CONNECT_FAILURE, |
| 308 | GPS_HSM_AGPS_SUPL_TCP_CONNECT_CLOSED, |
| 309 | GPS_HSM_AGPS_SUPL_TLS_CONNECT_ATTEMPT, |
| 310 | GPS_HSM_AGPS_SUPL_TLS_CONNECT_SUCCESS, |
| 311 | GPS_HSM_AGPS_SUPL_TLS_CONNECT_FAILURE, |
| 312 | GPS_HSM_AGPS_ASSISTANCE_RECEIVED, |
| 313 | } mrvlGpsHsmSwEventType_t; |
| 314 | |
| 315 | |
| 316 | typedef struct |
| 317 | { |
| 318 | mrvlGpsHsmSwEventType_t type; |
| 319 | union |
| 320 | { |
| 321 | S32 dummy; |
| 322 | } context; |
| 323 | } mrvlGpsHsmSwEvent_t; |
| 324 | |
| 325 | typedef enum |
| 326 | { |
| 327 | GPS_HSM_GNSS_MODE_AUTONOMOUS = 0, |
| 328 | GPS_HSM_GNSS_MODE_GPS = 1, |
| 329 | GPS_HSM_GNSS_MODE_GLONASS = 2, |
| 330 | GPS_HSM_GNSS_MODE_COMPASS = 4 |
| 331 | } mrvlGpsHsmGnssMode_t; |
| 332 | |
| 333 | typedef enum |
| 334 | { |
| 335 | AGPS_NI_TYPE_VOICE, |
| 336 | AGPS_NI_TYPE_UMTS_SUPL, |
| 337 | AGPS_NI_TYPE_UMTS_CTRL_PLANE |
| 338 | } |
| 339 | mrvlGpsNiType_t; |
| 340 | |
| 341 | typedef enum |
| 342 | { |
| 343 | AGPS_NOTIFYTYPE_NONE, |
| 344 | AGPS_NOTIFYTYPE_NOTIFYONLY, |
| 345 | AGPS_NOTIFYTYPE_NOTIFY_VERIFY_ALLOW, |
| 346 | AGPS_NOTIFYTYPE_NOTIFY_VERIFY_DENY |
| 347 | } mrvlGpsUserNotificationType_t; |
| 348 | |
| 349 | typedef enum |
| 350 | { |
| 351 | AGPS_USRNTFY_IDTYPE_LOGICAL_NAME = 1, |
| 352 | AGPS_USRNTFY_IDTYPE_EMAIL, |
| 353 | AGPS_USRNTFY_IDTYPE_MSISDN, |
| 354 | AGPS_USRNTFY_IDTYPE_URL, |
| 355 | AGPS_USRNTFY_IDTYPE_SIP_URI, |
| 356 | AGPS_USRNTFY_IDTYPE_MIN, |
| 357 | AGPS_USRNTFY_IDTYPE_MDN, |
| 358 | AGPS_USRNTFY_IDTYPE_IMPI |
| 359 | } mrvlGpsUserNotificationIdType_t; |
| 360 | |
| 361 | typedef enum |
| 362 | { |
| 363 | AGPS_USRNTFY_PARAM_REQUESTOR_ID = 0x1, /* \a RequestorId is valid */ |
| 364 | AGPS_USRNTFY_PARAM_CLIENT_NAME = 0x2, /* \a ClientName is valid */ |
| 365 | } mrvlGpsHsmUserNotifyParamsValid_t; |
| 366 | |
| 367 | |
| 368 | typedef enum |
| 369 | { |
| 370 | HSM_CHARENC_US_ASCII, /* US-ASCII */ |
| 371 | HSM_CHARENC_UTF_8, /* UTF-8 */ |
| 372 | HSM_CHARENC_UCS_2, /* UCS-2 */ |
| 373 | HSM_CHARENC_GSM_DEFAULT, /* GSM Default 3GPP TS 23.038 */ |
| 374 | } S8Enc_t; |
| 375 | |
| 376 | enum |
| 377 | { |
| 378 | GPS_HSM_LOCTYPE_GSM_CELLID = 1, |
| 379 | GPS_HSM_LOCTYPE_UMTS_CELLID, |
| 380 | GPS_HSM_LOCATION_TYPE_MAC, |
| 381 | GPS_HSM_LOCTYPE_EUTRAN_CELLID // LTE |
| 382 | }; |
| 383 | |
| 384 | typedef enum |
| 385 | { |
| 386 | GPS_HSM_AGPS_NONE_SI, |
| 387 | GPS_HSM_AGPS_SI, |
| 388 | GPS_HSM_AGPS_AUTONOMOUS |
| 389 | } |
| 390 | mrvlGpsAgpsProcType_t; |
| 391 | |
| 392 | typedef struct |
| 393 | { |
| 394 | mrvlGpsUserNotificationIdType_t Type; |
| 395 | S32 Encoding; |
| 396 | S32 Len; |
| 397 | S8 Data[AGPS_MAX_NOTIFYID_LEN]; |
| 398 | } mrvlGpsNotificationId_t; |
| 399 | |
| 400 | typedef struct |
| 401 | { |
| 402 | mrvlGpsHsmUserNotifyParamsValid_t ValidParams; |
| 403 | mrvlGpsNiType_t NiType; |
| 404 | mrvlGpsUserNotificationType_t NotifyType; |
| 405 | mrvlGpsNotificationId_t RequestorId; |
| 406 | mrvlGpsNotificationId_t ClientName; |
| 407 | U32 TransactionId; |
| 408 | } mrvlGpsUserNotifyParams_t; |
| 409 | |
| 410 | |
| 411 | |
| 412 | typedef struct |
| 413 | { |
| 414 | U32 mode; |
| 415 | union |
| 416 | { |
| 417 | struct |
| 418 | { |
| 419 | U8 status; /*0-ongoing,1-complete*/ |
| 420 | U8 svid; |
| 421 | U16 Chan_cnt; |
| 422 | U32 ACQ_time;/*millisecond,0-none,the time of successful acquisition*/ |
| 423 | U32 Bit_sync_time;/*millisecond,0-none,the time of successful bit sync*/ |
| 424 | U16 CN0_mean;/*scale=0.1,0-none,the average CN0 of all channels*/ |
| 425 | U16 CN0_var;/*scale = 0.1,the variance of CN0 for all channels*/ |
| 426 | U16 CN0_max; |
| 427 | U16 CN0_min; |
| 428 | S32 Doppler_mean;/*0-none,the average doppler frequcency for all channels*/ |
| 429 | S32 Doppler_var;/*0-none,the variance of doppler frequency for all channels*/ |
| 430 | U32 ch_map0; |
| 431 | U32 ch_map1; |
| 432 | U16 CNO_all[TRK_CHAN_MAX]; |
| 433 | S32 Doppler_all[TRK_CHAN_MAX]; |
| 434 | } integTestResult1; |
| 435 | |
| 436 | struct |
| 437 | { |
| 438 | U8 status; /*0-ongoing,1-complete*/ |
| 439 | U8 svid; |
| 440 | U16 Chan_cnt; |
| 441 | U32 ACQ_time;/*millisecond,0-none,the time of successful acquisition*/ |
| 442 | U32 Bit_sync_time;/*millisecond,0-none,the time of successful bit sync*/ |
| 443 | U16 CN0_mean;/*scale=0.1,0-none,the average CN0 of all channels*/ |
| 444 | U16 CN0_var;/*scale = 0.1,the variance of CN0 for all channels*/ |
| 445 | U16 CN0_max; |
| 446 | U16 CN0_min; |
| 447 | S32 Doppler_mean;/*0-none,the average doppler frequcency for all channels*/ |
| 448 | S32 Doppler_var;/*0-none,the variance of doppler frequency for all channels*/ |
| 449 | U32 ch_map0; |
| 450 | U32 ch_map1; |
| 451 | U16 CNO_all[TRK_CHAN_MAX]; |
| 452 | S32 Doppler_all[TRK_CHAN_MAX]; |
| 453 | } integTestResult2; |
| 454 | |
| 455 | struct |
| 456 | { |
| 457 | U8 status;/*0-on going,1-complete*/ |
| 458 | U8 svCnt; |
| 459 | U32 msCount; |
| 460 | U32 svList; /*the Visible satellite list,bit0=1-->1# Invsible,bit1=1-->2# Invisible,......*/ |
| 461 | DBL Latitude;/*0-none,the latitude of the receiver*/ |
| 462 | DBL Longitude;/*0-none,the longitude of the receiver*/ |
| 463 | DBL Altitude;/*0-none,the altitude of the receiver*/ |
| 464 | FLT Speed;/*0-none,the speed of the receiver*/ |
| 465 | DBL RTC_frequency;/*0-none,the frequency of the RTC*/ |
| 466 | DBL Clock_offset;/*0-none,the frequency offset of TCXO*/ |
| 467 | DBL Clock_drift;/*0-none,the frqency drift of TCXO*/ |
| 468 | U16 CN0_mean;/*scale=0.1,0-none,the mean CN0*/ |
| 469 | U16 CN0_var;/*0-none,the variance of CN0*/ |
| 470 | U16 CN0_max; |
| 471 | U16 CN0_min; |
| 472 | U8 svID[MAX_TESTMODE_SV_NUM]; |
| 473 | U16 CN0[MAX_TESTMODE_SV_NUM]; |
| 474 | U8 aiding_flag;//0-without aiding; 1-with aiding |
| 475 | } integTestResult3; |
| 476 | |
| 477 | struct |
| 478 | { |
| 479 | U8 status; /* 0 = in progress, 1 = complete */ |
| 480 | U8 NF_Status[4]; /*0=on going,1=notch filter0 enable,2-notch filter1 enable,4-notch filter2 enable*/ |
| 481 | U32 time; /* millisecond */ |
| 482 | S32 frequency[4]; /* first spur frequency */ |
| 483 | S32 snr[4]; |
| 484 | } integTestResult4; |
| 485 | |
| 486 | struct |
| 487 | { |
| 488 | U8 status;/*0-on going,1-complete*/ |
| 489 | U8 svCnt; |
| 490 | U32 msCount; |
| 491 | U32 svList; /*the Visible satellite list,bit0=1-->1# Invsible,bit1=1-->2# Invisible,......*/ |
| 492 | DBL Latitude;/*0-none,the latitude of the receiver*/ |
| 493 | DBL Longitude;/*0-none,the longitude of the receiver*/ |
| 494 | DBL Altitude;/*0-none,the altitude of the receiver*/ |
| 495 | FLT Speed;/*0-none,the speed of the receiver*/ |
| 496 | DBL RTC_frequency;/*0-none,the frequency of the RTC*/ |
| 497 | DBL Clock_offset;/*0-none,the frequency offset of TCXO*/ |
| 498 | DBL Clock_drift;/*0-none,the frqency drift of TCXO*/ |
| 499 | U16 CN0_mean;/*scale=0.1,0-none,the mean CN0*/ |
| 500 | U16 CN0_var;/*0-none,the variance of CN0*/ |
| 501 | U16 CN0_max; |
| 502 | U16 CN0_min; |
| 503 | U8 svID[MAX_TESTMODE_SV_NUM]; |
| 504 | U16 CN0[MAX_TESTMODE_SV_NUM]; |
| 505 | U8 aiding_flag;//0-without aiding; 1-with aiding |
| 506 | } integTestResult5; |
| 507 | |
| 508 | struct |
| 509 | { |
| 510 | U8 status;/*0-on going,1-complete*/ |
| 511 | U8 svCnt; |
| 512 | U32 msCount; |
| 513 | U32 svList; /*the Visible satellite list,bit0=1-->1# Invsible,bit1=1-->2# Invisible,......*/ |
| 514 | DBL Latitude;/*0-none,the latitude of the receiver*/ |
| 515 | DBL Longitude;/*0-none,the longitude of the receiver*/ |
| 516 | DBL Altitude;/*0-none,the altitude of the receiver*/ |
| 517 | FLT Speed;/*0-none,the speed of the receiver*/ |
| 518 | DBL RTC_frequency;/*0-none,the frequency of the RTC*/ |
| 519 | DBL Clock_offset;/*0-none,the frequency offset of TCXO*/ |
| 520 | DBL Clock_drift;/*0-none,the frqency drift of TCXO*/ |
| 521 | U16 CN0_mean;/*scale=0.1,0-none,the mean CN0*/ |
| 522 | U16 CN0_var;/*0-none,the variance of CN0*/ |
| 523 | U16 CN0_max; |
| 524 | U16 CN0_min; |
| 525 | U8 svID[MAX_TESTMODE_SV_NUM]; |
| 526 | U16 CN0[MAX_TESTMODE_SV_NUM]; |
| 527 | U8 aiding_flag;//0-without aiding; 1-with aiding |
| 528 | } integTestResult6; |
| 529 | |
| 530 | struct |
| 531 | { |
| 532 | U8 status;/*0-on going,1-complete*/ |
| 533 | U8 svID; |
| 534 | U16 CN0; |
| 535 | U32 msCount; |
| 536 | } integTestResult7; |
| 537 | |
| 538 | struct |
| 539 | { |
| 540 | U8 status;/*0-on going,1-complete*/ |
| 541 | U8 svCnt; |
| 542 | U32 msCount; |
| 543 | U32 svList; /*the Visible satellite list,bit0=1-->1# Invsible,bit1=1-->2# Invisible,......*/ |
| 544 | DBL Latitude;/*0-none,the latitude of the receiver*/ |
| 545 | DBL Longitude;/*0-none,the longitude of the receiver*/ |
| 546 | DBL Altitude;/*0-none,the altitude of the receiver*/ |
| 547 | FLT Speed;/*0-none,the speed of the receiver*/ |
| 548 | DBL RTC_frequency;/*0-none,the frequency of the RTC*/ |
| 549 | DBL Clock_offset;/*0-none,the frequency offset of TCXO*/ |
| 550 | DBL Clock_drift;/*0-none,the frqency drift of TCXO*/ |
| 551 | U16 CN0_mean;/*scale=0.1,0-none,the mean CN0*/ |
| 552 | U16 CN0_var;/*0-none,the variance of CN0*/ |
| 553 | U16 CN0_max; |
| 554 | U16 CN0_min; |
| 555 | U8 svID[MAX_TESTMODE_SV_NUM]; |
| 556 | U16 CN0[MAX_TESTMODE_SV_NUM]; |
| 557 | U8 aiding_flag;//0-without aiding; 1-with aiding |
| 558 | } integTestResult8; |
| 559 | |
| 560 | struct |
| 561 | { |
| 562 | U8 status; |
| 563 | U32 uartProbableErrorBytes; |
| 564 | U32 uartGoodBytes; |
| 565 | } integTestResult9; |
| 566 | |
| 567 | struct |
| 568 | { |
| 569 | U8 status; /* 0 = in progress, 1 = complete */ |
| 570 | U8 NF_Status[4]; /*0=on going,1=notch filter0 enable,2-notch filter1 enable,4-notch filter2 enable*/ |
| 571 | U32 time; /* millisecond */ |
| 572 | S32 frequency[4]; /* first spur frequency */ |
| 573 | S32 snr[4]; |
| 574 | } integTestResult10; |
| 575 | } testRes; |
| 576 | } mrvlGpsHsmIntegrityTestResults; |
| 577 | |
| 578 | |
| 579 | /* struct for results of test mode 1&2 */ |
| 580 | typedef struct |
| 581 | { |
| 582 | U8 status; |
| 583 | U8 svid; |
| 584 | U16 nChannel; |
| 585 | U32 acqMsCnt; |
| 586 | U32 bitSyncMsCnt; |
| 587 | U16 meanCno; |
| 588 | U16 varCno; |
| 589 | U16 maxCno; |
| 590 | U16 minCno; |
| 591 | S32 meanDopp; |
| 592 | S32 varDopp; |
| 593 | U32 chMap0; |
| 594 | U32 chMap1; |
| 595 | U16 cnoAll[TRK_CHAN_MAX]; |
| 596 | S32 doppAll[TRK_CHAN_MAX]; |
| 597 | } integrityTestRes_t; |
| 598 | |
| 599 | /* struct for results of test mode 3&5&6 */ |
| 600 | typedef struct |
| 601 | { |
| 602 | U8 svCnt; |
| 603 | U32 MsCnt; |
| 604 | U32 sv_list; |
| 605 | DBL lat; |
| 606 | DBL lon; |
| 607 | DBL alt; |
| 608 | FLT vel; |
| 609 | DBL rtc_freq; |
| 610 | DBL clk_offset; |
| 611 | DBL clk_drift; |
| 612 | U16 meanCno; |
| 613 | U16 varCno; |
| 614 | U16 maxCno; |
| 615 | U16 minCno; |
| 616 | U8 sv_id[MAX_TESTMODE_SV_NUM]; |
| 617 | U16 cnoAll[MAX_TESTMODE_SV_NUM]; |
| 618 | U8 aid_flag;//0-without aiding, 1-with aiding |
| 619 | } LiveFixTestRes_t; |
| 620 | |
| 621 | /* struct for results of test mode 7 */ //add by zhujj |
| 622 | typedef struct |
| 623 | { |
| 624 | U8 status; |
| 625 | U8 svid; |
| 626 | U16 Cno; |
| 627 | U32 MsCnt; |
| 628 | } integrityTestResGln_t; |
| 629 | |
| 630 | |
| 631 | |
| 632 | typedef struct |
| 633 | { |
| 634 | unsigned int arfcn; /*< ARFCN (0...1023) */ |
| 635 | unsigned int bsic; /*< BSIC (0...63) */ |
| 636 | unsigned int rxLev; /*< RXLEV (0...63) */ |
| 637 | } mrvlGpsHsmEcidNmr_t; |
| 638 | |
| 639 | typedef struct |
| 640 | { |
| 641 | unsigned int mcc; /*< Mobile Country Code (0...999) */ |
| 642 | unsigned int mnc; /*< Mobile Network Code (0...99) */ |
| 643 | unsigned int lac; /*< Location area code (0...65535) */ |
| 644 | unsigned int ci; /*< Cell Identity (0...65535) */ |
| 645 | unsigned int numOfCells; /* < Number of cells in nmrCellResult array */ |
| 646 | mrvlGpsHsmEcidNmr_t nmr[MAX_NMR_CELLS]; /*< Network measurement result structure */ |
| 647 | unsigned int taPresent; /*< TRUE - timing advance present, FALSE - omitted */ |
| 648 | unsigned int timingAdv; /*< Timing advance (0...255) */ |
| 649 | } mrvlGpsHsmEcidGsmInfo_t; |
| 650 | |
| 651 | /* E-CID UTRA information provision */ |
| 652 | |
| 653 | |
| 654 | typedef struct |
| 655 | { |
| 656 | unsigned long ucidPresent; /*< TRUE - present, FALSE - omitted */ |
| 657 | unsigned long ucid; /*< Cell Identity (0...268435455). NOTE: this information element contains the Cell Identity sent in SIB3 */ |
| 658 | unsigned long psc; /*< Primary scrambling code (0...511) */ |
| 659 | unsigned long cpichRscp; /*< CPICH RSCP (0...91, spare, 123...127) */ |
| 660 | unsigned long cpichEcN0; /*< CPICH Ec / N0 (0...63) */ |
| 661 | unsigned long pathLossPresent; /*< TRUE - path loss present */ |
| 662 | unsigned long pathLoss; /*< Path loss (46...173) */ |
| 663 | } mrvlGpsHsmEcidCellResult_t; |
| 664 | |
| 665 | typedef struct |
| 666 | { |
| 667 | unsigned long numOfCells; /*< Number of cells in cell results list */ |
| 668 | mrvlGpsHsmEcidCellResult_t cellResult[MAX_UTRA_RESULT_CELLS]; /*< Cell results list */ |
| 669 | } mrvlGpsHsmEcidCellResultList_t; |
| 670 | |
| 671 | typedef struct |
| 672 | { |
| 673 | unsigned long uarfcnDl; /*< Downlink UARFCN (0...16383) */ |
| 674 | unsigned long rssi; /*< UTRA carrier RSSI (0...127) */ |
| 675 | mrvlGpsHsmEcidCellResultList_t cellResultList; |
| 676 | } mrvlGpsHsmMeasuredResultInfo_t; |
| 677 | |
| 678 | typedef struct |
| 679 | { |
| 680 | unsigned long numUtraReportedFreqs; /*< Number of UTRA reported frequencies (1...8) */ |
| 681 | mrvlGpsHsmMeasuredResultInfo_t utraMeasResult[MAX_UTRA_RESULT_FREQS]; /*< UTRA measurement results array */ |
| 682 | } mrvlGpsHsmEcidMeasuredResultListInfo_t; |
| 683 | |
| 684 | typedef struct |
| 685 | { |
| 686 | unsigned long mcc; /*< Mobile Country Code (0...999) */ |
| 687 | unsigned long mnc; /*< Mobile Network Code (0...99) */ |
| 688 | unsigned long ucid; /*< Cell Identity (0...268435455). NOTE: this information element contains the Cell Identity sent in SIB3 */ |
| 689 | unsigned long uarfcnDl; /*< Downlink UARFCN (0...16383) */ |
| 690 | unsigned long uarfcnUl; /*< Uplink UARFCN (0...16383) */ |
| 691 | unsigned long psc; /*< Primary scrambling code (0...511) */ |
| 692 | unsigned long MeasResultPresent; /*< TRUE - measured result list is present, FALSE - omitted */ |
| 693 | mrvlGpsHsmEcidMeasuredResultListInfo_t measResult; /*< UTRA measurement results */ |
| 694 | } mrvlGpsHsmEcidUtraInfo_t; |
| 695 | |
| 696 | /* E-CID EUTRA information provision */ |
| 697 | |
| 698 | |
| 699 | typedef struct |
| 700 | { |
| 701 | unsigned long mccPresent; |
| 702 | unsigned long mcc; |
| 703 | unsigned long mnc; |
| 704 | unsigned long cellId; |
| 705 | } mrvlGpsHsmCelllGlobalId_t; |
| 706 | |
| 707 | typedef struct |
| 708 | { |
| 709 | unsigned long physCellId; /*< Physical cell ID, 0...503 */ |
| 710 | unsigned long cgiPresent; /*< TRUE - Cell global Identity present */ |
| 711 | mrvlGpsHsmCelllGlobalId_t cellGlobalId; /*< Cell global identity */ |
| 712 | unsigned long arfcnEutra; /*< EARFCN */ |
| 713 | unsigned long sfnPresent; /*< TRUE - systemFrameNumber present */ |
| 714 | unsigned long systemFrameNumber; /*< System frame number */ |
| 715 | unsigned long rsrpPresent; /*< TRUE - RSRP present */ |
| 716 | unsigned long rsrp; /*< RSRP report (0...97), mapped according to 36.133 */ |
| 717 | unsigned long rsrqPresent; /*< TRUE - RSRQ present */ |
| 718 | unsigned long rsrq; /*< RSRQ report (0...34), mapped according to 36.133 */ |
| 719 | unsigned long rxTxTimeDiffPresent; /*< UE Rx-Tx time difference present */ |
| 720 | unsigned long rxTxTimeDiff; /*< UE Rx-Tx time difference (0...4095), mapped according to 36.133 */ |
| 721 | unsigned long taPresent; /*< TRUE - timing advance present */ |
| 722 | unsigned long timingAdvance; /*< Timing advance (0...1282). NTA/16 as per [3GPP 36.213]. |
| 723 | Required for E-CID over SUPL2.0 */ |
| 724 | unsigned long tacPresent; /*< TRUE - Tracking area code present */ |
| 725 | unsigned long trackingAreaCode; /*< Tracking area code. Required for E-CID over SUPL2.0 */ |
| 726 | } mrvlGpsHsmMeasuredResultElementInfo_t; |
| 727 | |
| 728 | /* E-CID provided measurement information during LTE. Provided by ERRC to the upper layers */ |
| 729 | typedef struct |
| 730 | { |
| 731 | unsigned long primaryCellMeasuredResultsPresent; /*< TRUE - primary cell measured results present */ |
| 732 | mrvlGpsHsmMeasuredResultElementInfo_t primaryCellMeasuredResults; /*< Primary cell measured results in LTE. primaryCellMeasuredResults |
| 733 | field contains measurements for the primary cell, when the target device reports measurements for both primary cell and neighbor |
| 734 | cells. This field shall be omitted when the target device reports measurements for the primary cell only, in which case the |
| 735 | measurements the primary cell is reported in the measuredResultsList. */ |
| 736 | unsigned long measuredResultsListLength; /*< Number of elements in measuredResultsList */ |
| 737 | mrvlGpsHsmMeasuredResultElementInfo_t measuredResultsList[GPS_HSM_MEAS_RESULT_LIST_LENGTH]; /*< Neighbor cell measured results */ |
| 738 | } mrvlGpsHsmEcidSignalMeasInfo_t; |
| 739 | |
| 740 | /* E-CID error causes enumerator */ |
| 741 | typedef enum |
| 742 | { |
| 743 | GPS_HSM_ECID_ERROR_CAUSE_UNDEFINED, /*< Unspecified error */ |
| 744 | GPS_HSM_ECID_ERROR_CAUSE_REQUESTED_MEASUREMENT_NOT_AVAILABLE, /*< Requested measurement not available */ |
| 745 | GPS_HSM_ECID_ERROR_CAUSE_NOT_ALL_REQUESTED_MEASUREMENT_POSSIBLE, |
| 746 | GPS_HSM_ECID_ERROR_CAUSE_MAX_LAST = 0x7FFFFFFF |
| 747 | } mrvlGpsHsmEcidErrocCause_t; |
| 748 | |
| 749 | /* E-CID target device error causes structure */ |
| 750 | typedef struct |
| 751 | { |
| 752 | mrvlGpsHsmEcidErrocCause_t ecidErrorCauses; /*< E-CID measurement error causes */ |
| 753 | unsigned long rsrpMeasurementNotPossible; /*< TRUE - RSRP measurement not possible */ |
| 754 | unsigned long rsrqMeasurementNotPossible; /*< TRUE - RSRQ measurement not possible */ |
| 755 | unsigned long ueRxTxMeasurementNotPossible; /*< TRUE - UE Rx-Tx time difference measurement not possible */ |
| 756 | } mrvlGpsHsmEcidErrorInfo_t; |
| 757 | |
| 758 | typedef struct |
| 759 | { |
| 760 | unsigned long ecidSignalMeasurementInformationPresent; /*< TRUE - E-CID information present, FALSE - omitted */ |
| 761 | mrvlGpsHsmEcidSignalMeasInfo_t ecidSignalMeasurementInformation; /*< E-CID signal measurement result in LTE */ |
| 762 | unsigned long ecidErrorPresent; /*< TRUE - E-CID error present, FALSE - omitted */ |
| 763 | mrvlGpsHsmEcidErrorInfo_t ecidError; /*< E-CID measurement error */ |
| 764 | } mrvlGpsHsmEcidEutraInfo_t; |
| 765 | |
| 766 | typedef struct mrvlGpsHsmEcidMeasCnf |
| 767 | { |
| 768 | mrvlGpsHsmNetworkType_t networkType; |
| 769 | union |
| 770 | { |
| 771 | mrvlGpsHsmEcidGsmInfo_t gsmInfo; |
| 772 | mrvlGpsHsmEcidUtraInfo_t utraInfo; |
| 773 | mrvlGpsHsmEcidEutraInfo_t eutraInfo; |
| 774 | } nt; |
| 775 | } mrvlGpsHsmEcidMeasCnf_t; |
| 776 | |
| 777 | /* E-CID UE AREA Indication */ |
| 778 | |
| 779 | |
| 780 | typedef struct mrvlGpsHsmGsmAreaInfo |
| 781 | { |
| 782 | unsigned long mcc; /*< Mobile Country Code (0...999) */ |
| 783 | unsigned long mnc; /*< Mobile Network Code (0...99) */ |
| 784 | unsigned long lac; /*< Location area code (0...65535) */ |
| 785 | unsigned long ci; /*< Cell Identity (0...65535) */ |
| 786 | } mrvlGpsHsmGsmAreaInfo_t; |
| 787 | |
| 788 | typedef struct mrvlGpsHsmUtraAreaInfo |
| 789 | { |
| 790 | unsigned long mcc; /*< Mobile Country Code (0...999) */ |
| 791 | unsigned long mnc; /*< Mobile Network Code (0...99) */ |
| 792 | unsigned long lac; /*< Location area code (0...65535) */ |
| 793 | unsigned long ucid; /*< Cell Identity (0...268435455). NOTE: this information element contains the Cell Identity sent in SIB3 */ |
| 794 | } mrvlGpsHsmUtraAreaInfo_t; |
| 795 | |
| 796 | typedef struct mrvlGpsHsmEutraAreaInfo |
| 797 | { |
| 798 | unsigned long arfcnEutra; /*< EARFCN */ |
| 799 | unsigned long physCellId; /*< Physical cell ID, 0...503 */ |
| 800 | unsigned long cgiPresent; /*< TRUE - Cell global Identity present */ |
| 801 | mrvlGpsHsmCelllGlobalId_t cellGlobalId; /*< Cell global identity */ |
| 802 | } mrvlGpsHsmEutraAreaInfo_t; |
| 803 | |
| 804 | typedef struct mrvlGpsHsmUeAreaInfo |
| 805 | { |
| 806 | mrvlGpsHsmNetworkType_t networkType; |
| 807 | union |
| 808 | { |
| 809 | mrvlGpsHsmGsmAreaInfo_t gsmArea; |
| 810 | mrvlGpsHsmUtraAreaInfo_t utraArea; |
| 811 | mrvlGpsHsmEutraAreaInfo_t eutraArea; |
| 812 | } nt; |
| 813 | } mrvlGpsHsmUeAreaInfo_t; |
| 814 | |
| 815 | typedef struct mrvlGpsHsmNLPInfo |
| 816 | { |
| 817 | double latitude; |
| 818 | double longitude; |
| 819 | float accuracy; |
| 820 | U64 timestamp; |
| 821 | } mrvlGpsHsmNLPInfo_t; |
| 822 | |
| 823 | typedef struct gpsRefLocbyCell |
| 824 | { |
| 825 | U8 semiMajor; |
| 826 | U16 mnc; |
| 827 | U16 mcc; |
| 828 | U16 lac; |
| 829 | U32 cid; |
| 830 | DBL lon; |
| 831 | DBL lat; |
| 832 | DBL alt; |
| 833 | } gpsRefLocbyCell_t; |
| 834 | |
| 835 | typedef enum mrvlGpsHsmLpOtdoaServerErrorCauses |
| 836 | { |
| 837 | GPS_HSM_LP_EOTDOA_LOCATION_SERVER_ERROR_CAUSES_CAUSE_UNDEFINED = 0, |
| 838 | GPS_HSM_LP_EOTDOA_LOCATION_SERVER_ERROR_CAUSES_CAUSE_ASSISTANCE_DATA_NOT_SUPPORTED_BY_SERVER, |
| 839 | GPS_HSM_LP_EOTDOA_LOCATION_SERVER_ERROR_CAUSES_CAUSE_ASSISTANCE_DATA_SUPPORTED_BUT_CURRENTLY_NOT_AVAILABLE_BY_SERVER, |
| 840 | GPS_HSM_LP_EOTDOA_LOCATION_SERVER_ERROR_CAUSE_MAX_LAST = 0x7FFFFFFF |
| 841 | } mrvlGpsHsmLpOtdoaServerErrorCauses_t; |
| 842 | |
| 843 | typedef enum mrvlGpsHsmLpOtdoaErrorTag |
| 844 | { |
| 845 | GPS_HSM_LP_EOTDOA_ERROR_LOCATION_SERVER_ERROR_CAUSES = 0, |
| 846 | GPS_HSM_LP_EOTDOA_ERROR_TARGET_DEVICE_ERROR_CAUSES = 1, |
| 847 | GPS_HSM_LP_EOTDOA_ERROR_CAUSES_MAX_LAST = 0x7FFFFFFF |
| 848 | } mrvlGpsHsmLpOtdoaErrorTag_t; |
| 849 | |
| 850 | typedef enum mrvlGpsHsmLpOtdoaErrorCause |
| 851 | { |
| 852 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSES_CAUSE_UNDEFINED = 0, |
| 853 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSES_CAUSE_ASSISTANCE_DATA_MISSING, |
| 854 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSES_CAUSE_UNABLE_TO_MEASURE_REFERENCE_CELL, |
| 855 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSES_CAUSE_UNABLE_TO_MEASURE_ANY_NEIGHBOUR_CELL, |
| 856 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSES_CAUSE_ATTEMPTED_BUT_UNABLE_TO_MEASURE_SOME_NEIGHBOUR_CELLS, |
| 857 | GPS_HSM_LP_EOTDOA_TARGET_DEVICE_ERROR_CAUSE_MAX_LAST = 0x7FFFFFFF |
| 858 | } mrvlGpsHsmLpOtdoaErrorCause_t; |
| 859 | |
| 860 | typedef enum mrvlGpsHsmLpOtdoaNeighCellInfoElemCpLen |
| 861 | { |
| 862 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_CP_LENGTH_NORMAL = 0, |
| 863 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_CP_LENGTH_EXTENDED, |
| 864 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_CP_LENGTH_MAX_LAST = 0x7FFFFFFF |
| 865 | } mrvlGpsHsmLpOtdoaNeighCellInfoElemCpLen_t; |
| 866 | |
| 867 | typedef enum mrvlGpsHsmLpOtdoaNeighCellInfoElemAntPortConfig |
| 868 | { |
| 869 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_ANTENNA_PORT_CONFIG_PORTS_MINUS_1_OR_MINUS_2 = 0, |
| 870 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_ANTENNA_PORT_CONFIG_PORTS_MINUS_4, |
| 871 | GPS_HSM_LP_EOTDOA_NEIGHBOUR_CELL_INFO_ELEMENT_ANTENNA_PORT_CONFIG_MAX_LAST = 0x7FFFFFFF |
| 872 | } mrvlGpsHsmLpOtdoaNeighCellInfoElemAntPortConfig_t; |
| 873 | |
| 874 | typedef enum mrvlGpsHsmLpOtdoaRefCellInfoElemAntPortConfig |
| 875 | { |
| 876 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_ANTENNA_PORT_CONFIG_PORTS1_OR_MINUS_2 = 0, |
| 877 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_ANTENNA_PORT_CONFIG_PORTS4, |
| 878 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_ANTENNA_PORT_CONFIG_MAX_LAST = 0x7FFFFFFF |
| 879 | } mrvlGpsHsmLpOtdoaRefCellInfoElemAntPortConfig_t; |
| 880 | |
| 881 | typedef enum mrvlGpsHsmLpOtdoaRefCellInfoElemCpLen |
| 882 | { |
| 883 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_CP_LENGTH_NORMAL = 0, |
| 884 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_CP_LENGTH_EXTENDED, |
| 885 | GPS_HSM_LP_EOTDOA_REFERENCE_CELL_INFO_CP_LENGTH_MAX_LAST = 0x7FFFFFFF |
| 886 | } mrvlGpsHsmLpOtdoaRefCellInfoElemCpLen_t; |
| 887 | |
| 888 | typedef enum mrvlGpsHsmLpOtdoaEprsInfoPrsBandwidth |
| 889 | { |
| 890 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N6 = 0, |
| 891 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N15, |
| 892 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N25, |
| 893 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N50, |
| 894 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N75, |
| 895 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_N100, |
| 896 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_BANDWIDTH_MAX_LAST = 0x7FFFFFFF |
| 897 | } mrvlGpsHsmLpOtdoaEprsInfoPrsBandwidth_t; |
| 898 | |
| 899 | typedef enum mrvlGpsHsmLpOtdoaEprsInfoNumDlFrames |
| 900 | { |
| 901 | GPS_HSM_LP_OTDOA_EPRS_INFO_NUM_DL_FRAMES_SF_MINUS_1 = 0, |
| 902 | GPS_HSM_LP_OTDOA_EPRS_INFO_NUM_DL_FRAMES_SF_MINUS_2, |
| 903 | GPS_HSM_LP_OTDOA_EPRS_INFO_NUM_DL_FRAMES_SF_MINUS_4, |
| 904 | GPS_HSM_LP_OTDOA_EPRS_INFO_NUM_DL_FRAMES_SF_MINUS_6, |
| 905 | GPS_HSM_LP_OTDOA_EPRS_INFO_NUM_DL_FRAMES_MAX_LAST = 0x7FFFFFFF |
| 906 | } mrvlGpsHsmLpOtdoaEprsInfoNumDlFrames_t; |
| 907 | |
| 908 | typedef enum mrvlGpsHsmLpOtdoaEprsInfoPrsMutingInfo99 |
| 909 | { |
| 910 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_MUTING_INFO_R9_PO2_R9 = 0, |
| 911 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_MUTING_INFO_R9_PO4_R9 = 1, |
| 912 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_MUTING_INFO_R9_PO8_R9 = 2, |
| 913 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_MUTING_INFO_R9_PO16_R9 = 3, |
| 914 | GPS_HSM_LP_OTDOA_EPRS_INFO_PRS_MUTING_INFO_MAX_LAST = 0x7FFFFFFF |
| 915 | } mrvlGpsHsmLpOtdoaEprsInfoPrsMutingInfo99_t; |
| 916 | |
| 917 | typedef struct mrvlGpsHsmLpOtdoaEeCgiMcc |
| 918 | { |
| 919 | unsigned char data [3]; /* 0 to 9 */ |
| 920 | } mrvlGpsHsmLpOtdoaEeCgiMcc_t; |
| 921 | |
| 922 | typedef struct mrvlGpsHsmLpOtdoaEeCgiMnc |
| 923 | { |
| 924 | unsigned short n; /* 2 to 3 */ |
| 925 | unsigned char data [3];/* 0 to 9 */ |
| 926 | } mrvlGpsHsmLpOtdoaEeCgiMnc_t; |
| 927 | |
| 928 | typedef struct mrvlGpsHsmLpOtdoaEeCgi |
| 929 | { |
| 930 | mrvlGpsHsmLpOtdoaEeCgiMcc_t mcc; |
| 931 | mrvlGpsHsmLpOtdoaEeCgiMnc_t mnc; |
| 932 | unsigned int cellIdentity; /* 0 to 268435455 */ |
| 933 | } mrvlGpsHsmLpOtdoaEeCgi_t; |
| 934 | |
| 935 | typedef struct mrvlGpsHsmEprsInfoPrsMutingInfo99 |
| 936 | { |
| 937 | unsigned char tag; |
| 938 | union |
| 939 | { |
| 940 | /* 0 */ |
| 941 | unsigned char po2R9; /* 0 to 3 */ |
| 942 | /* 1 */ |
| 943 | unsigned char po4R9; /* 0 to 15 */ |
| 944 | /* 2 */ |
| 945 | unsigned char po8R9; /* 0 to 255 */ |
| 946 | /* 3 */ |
| 947 | unsigned char po16R9; /* 0 to 65535 */ |
| 948 | } po; |
| 949 | } mrvlGpsHsmEprsInfoPrsMutingInfo99_t; |
| 950 | |
| 951 | typedef struct mrvlGpsHsmLpOtdoaEprsInfo |
| 952 | { |
| 953 | unsigned char prsBandwidth; |
| 954 | unsigned short prsConfigurationIndex; /* 0 to 4095 */ |
| 955 | unsigned char numDlFrames; |
| 956 | unsigned char prsMutingInfoR9Present; |
| 957 | mrvlGpsHsmEprsInfoPrsMutingInfo99_t prsMutingInfoR9; |
| 958 | } mrvlGpsHsmLpOtdoaEprsInfo_t; |
| 959 | |
| 960 | |
| 961 | typedef struct mrvlGpsHsmLpOtdoaRefCellInfo |
| 962 | { |
| 963 | unsigned short physCellId; /* 0 to 503 */ |
| 964 | unsigned char cellGlobalIdPresent; |
| 965 | mrvlGpsHsmLpOtdoaEeCgi_t cellGlobalId; |
| 966 | unsigned char earfcnRefPresent; |
| 967 | unsigned short earfcnRef; |
| 968 | unsigned char antennaPortConfigPresent; |
| 969 | unsigned char antennaPortConfig; |
| 970 | unsigned char cpLength; |
| 971 | unsigned char prsInfoPresent; |
| 972 | mrvlGpsHsmLpOtdoaEprsInfo_t prsInfo; |
| 973 | unsigned char earfcnRefV9a0Present; |
| 974 | unsigned int earfcnRefV9a0; |
| 975 | } mrvlGpsHsmLpOtdoaRefCellInfo_t; |
| 976 | |
| 977 | typedef struct mrvlGpsHsmLpOtdoaNeighCellInfoElement |
| 978 | { |
| 979 | unsigned short physCellId; /* 0 to 503 */ |
| 980 | unsigned char cellGlobalIdPresent; |
| 981 | mrvlGpsHsmLpOtdoaEeCgi_t cellGlobalId; |
| 982 | unsigned char earfcnPresent; |
| 983 | unsigned short earfcn; |
| 984 | unsigned char cpLengthPresent; |
| 985 | unsigned char cpLength; |
| 986 | unsigned char prsInfoPresent; |
| 987 | mrvlGpsHsmLpOtdoaEprsInfo_t prsInfo; |
| 988 | unsigned char antennaPortConfigPresent; |
| 989 | unsigned char antennaPortConfig; |
| 990 | unsigned char slotNumberOffsetPresent; |
| 991 | unsigned char slotNumberOffset; /* 0 to 19 */ |
| 992 | unsigned char prsSubframeOffsetPresent; |
| 993 | unsigned short prsSubframeOffset; /* 0 to 1279 */ |
| 994 | unsigned short expectedRstd; /* 0 to 16383 */ |
| 995 | unsigned short expectedRstdUncertainty; /* 0 to 1023 */ |
| 996 | unsigned char earfcnV9a0Present; |
| 997 | unsigned int earfcnV9a0; |
| 998 | } mrvlGpsHsmLpOtdoaNeighCellInfoElement_t; |
| 999 | |
| 1000 | typedef struct mrvlGpsHsmLpOtdoaNeighFreqInfo |
| 1001 | { |
| 1002 | unsigned short n; /* 1 to 24 */ |
| 1003 | mrvlGpsHsmLpOtdoaNeighCellInfoElement_t data[24]; |
| 1004 | } mrvlGpsHsmLpOtdoaNeighFreqInfo_t; |
| 1005 | |
| 1006 | typedef struct mrvlGpsHsmLpOtdoaNeighCellInfoList |
| 1007 | { |
| 1008 | unsigned long n; /* 1 to maxFreqLayers */ |
| 1009 | mrvlGpsHsmLpOtdoaNeighFreqInfo_t data[MRVLGPS_MAX_FREQ_LAYERS]; |
| 1010 | } mrvlGpsHsmLpOtdoaNeighCellInfoList_t; |
| 1011 | |
| 1012 | typedef struct mrvlGpsHsmLpOtdoaError |
| 1013 | { |
| 1014 | unsigned char tag; |
| 1015 | union |
| 1016 | { |
| 1017 | unsigned char locationServerErrorCauses; |
| 1018 | unsigned char targetDeviceErrorCauses; |
| 1019 | } err; |
| 1020 | } mrvlGpsHsmLpOtdoaError_t; |
| 1021 | |
| 1022 | typedef struct mrvlGpsHsmLpOtdoaProvideAssistanceData |
| 1023 | { |
| 1024 | unsigned char otdoaReferenceCellInfoPresent; |
| 1025 | mrvlGpsHsmLpOtdoaRefCellInfo_t otdoaReferenceCellInfo; |
| 1026 | unsigned char otdoaNeighbourCellInfoPresent; |
| 1027 | mrvlGpsHsmLpOtdoaNeighCellInfoList_t otdoaNeighbourCellInfo; |
| 1028 | unsigned char otdoaErrorPresent; |
| 1029 | mrvlGpsHsmLpOtdoaError_t otdoaError; |
| 1030 | } mrvlGpsHsmLpOtdoaProvideAssistanceData_t; |
| 1031 | |
| 1032 | typedef struct mrvlGpsHsmLpOtdoaMeasQuality |
| 1033 | { |
| 1034 | unsigned char errorResolution; /* 0 to 3 */ |
| 1035 | unsigned char errorValue; /* 0 to 31 */ |
| 1036 | unsigned char errorNumSamplesPresent; |
| 1037 | unsigned char errorNumSamples; /* 0 to 7 */ |
| 1038 | } mrvlGpsHsmLpOtdoaMeasQuality_t; |
| 1039 | |
| 1040 | typedef struct mrvlGpsHsmLpOtdoaMeasListElementData |
| 1041 | { |
| 1042 | unsigned short physCellIdNeighbor; /* 0 to 503 */ |
| 1043 | unsigned char cellGlobalIdNeighbourPresent; |
| 1044 | mrvlGpsHsmLpOtdoaEeCgi_t cellGlobalIdNeighbour; |
| 1045 | unsigned char earfcnNeighbourPresent; |
| 1046 | unsigned short earfcnNeighbour; |
| 1047 | unsigned short rstd; /* 0 to 12711 */ |
| 1048 | mrvlGpsHsmLpOtdoaMeasQuality_t rstdQuality; |
| 1049 | unsigned char earfcnNeighbourV9a0Present; |
| 1050 | unsigned int earfcnNeighbourV9a0; |
| 1051 | } mrvlGpsHsmLpOtdoaMeasListElementData_t; |
| 1052 | |
| 1053 | typedef struct mrvlGpsHsmLpOtdoaMeasList |
| 1054 | { |
| 1055 | unsigned short n; /* 1 to 24 */ |
| 1056 | mrvlGpsHsmLpOtdoaMeasListElementData_t data[24]; |
| 1057 | } mrvlGpsHsmLpOtdoaMeasList_t; |
| 1058 | |
| 1059 | typedef struct mrvlGpsHsmLpOtdoaMeasInfo |
| 1060 | { |
| 1061 | unsigned short systemFrameNumber; /* 0 to 1023 */ |
| 1062 | unsigned short physCellIdRef; /* 0 to 503 */ |
| 1063 | unsigned char cellGlobalIdRefPresent; |
| 1064 | mrvlGpsHsmLpOtdoaEeCgi_t cellGlobalIdRef; |
| 1065 | unsigned char earfcnRefPresent; |
| 1066 | unsigned short earfcnRef; |
| 1067 | unsigned char referenceQualityPresent; |
| 1068 | mrvlGpsHsmLpOtdoaMeasQuality_t referenceQuality; |
| 1069 | mrvlGpsHsmLpOtdoaMeasList_t neighbourMeasurementList; |
| 1070 | unsigned char earfcnRefV9a0Present; |
| 1071 | unsigned int earfcnRefV9a0; |
| 1072 | } mrvlGpsHsmLpOtdoaMeasInfo_t; |
| 1073 | |
| 1074 | typedef struct mrvlGpsHsmLpProvideLocInfo |
| 1075 | { |
| 1076 | unsigned char otdoaSignalMeasurementInformationPresent; |
| 1077 | mrvlGpsHsmLpOtdoaMeasInfo_t otdoaSignalMeasurementInformation; |
| 1078 | unsigned char otdoaErrorPresent; |
| 1079 | mrvlGpsHsmLpOtdoaError_t otdoaError; |
| 1080 | } mrvlGpsHsmLpProvideLocInfo_t; |
| 1081 | |
| 1082 | typedef struct mrvlGpsHsmOtdoaProvidePrsAssistanceReqMsg |
| 1083 | { |
| 1084 | mrvlGpsHsmLpOtdoaProvideAssistanceData_t prsAssistanceData; |
| 1085 | } mrvlGpsHsmOtdoaProvidePrsAssistanceReqMsg_t; |
| 1086 | |
| 1087 | typedef struct mrvlGpsHsmProvideRstdLocInfoMsg |
| 1088 | { |
| 1089 | mrvlGpsHsmLpProvideLocInfo_t otdoaProvideLocationInformation; |
| 1090 | } mrvlGpsHsmProvideRstdLocInfoMsg_t; |
| 1091 | |
| 1092 | //typedef enum |
| 1093 | //{ |
| 1094 | // /* Normal positioning request */ |
| 1095 | // NO_EMERGENCY = 0x00, |
| 1096 | // /* Emergent positioning request such as E911/112 */ |
| 1097 | // EMERGENCY = 0x01 |
| 1098 | //} mrvlGpsHsmSessionPriority_t; |
| 1099 | |
| 1100 | typedef enum |
| 1101 | { |
| 1102 | /* UL RRC message includeds MeasurementReport, which could be MeasuredResults/UE-Positioning-MeasuredResults or EventResults. */ |
| 1103 | GPS_HSM_RRC_MEAS_REPORT = 0, |
| 1104 | /* UL RRC MeasurementControlFailure is included. */ |
| 1105 | GPS_HSM_RRC_MEAS_FAILURE, |
| 1106 | /* UL RRCStatus is included */ |
| 1107 | GPS_HSM_RRC_STATUS |
| 1108 | } mrvlGpsHsmRrcMsgType_t; |
| 1109 | |
| 1110 | typedef struct |
| 1111 | { |
| 1112 | mrvlGpsHsmRrcMsgType_t rrc_msg_type; |
| 1113 | struct |
| 1114 | { |
| 1115 | unsigned char measurement_identity; /* valid if rrc_msg_type is LSM_RRC_MEAS_REPORT */ |
| 1116 | /* 0: MeasuredResults or UE-Positioning-MeasuredResults, which is compile time decided inside LPL. |
| 1117 | 1: EventResults is reported. */ |
| 1118 | unsigned char measurement_or_event; |
| 1119 | } meas_report; |
| 1120 | unsigned long int is_final_response; /* 1: final UL response; 0: more UL message to come. */ |
| 1121 | } mrvlGpsHsmOtaParams_t; |
| 1122 | |
| 1123 | typedef struct |
| 1124 | { |
| 1125 | S32 transactionId; |
| 1126 | S32 errorCodePresent; |
| 1127 | S32 errorCode; |
| 1128 | S32 locationPresent; |
| 1129 | mrvlGpsLocation_t location; |
| 1130 | } mrvlGpsHsmMolrRespT; |
| 1131 | |
| 1132 | typedef struct |
| 1133 | { |
| 1134 | S32 transcationId; |
| 1135 | S32 causePresent; |
| 1136 | S32 cause; |
| 1137 | } mrvlGpsHsmReleaseCompleteT; |
| 1138 | |
| 1139 | |
| 1140 | |
| 1141 | /* HSM to Framework APIs */ |
| 1142 | /** |
| 1143 | * \brief |
| 1144 | * Implemented as callback by porting/integration code. Used by GNSS software to update location information |
| 1145 | * |
| 1146 | * \param [IN] pGpsLoct Pointer to location information structure |
| 1147 | * |
| 1148 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1149 | * |
| 1150 | * \since |
| 1151 | * 1.2.8 |
| 1152 | * |
| 1153 | * <b>Example implementation</b> |
| 1154 | * \code |
| 1155 | * |
| 1156 | * S32 mrvlGpsHsmUpdateLocationInfo(mrvlGpsLocation_t* pGpsLoct) |
| 1157 | * { |
| 1158 | * gpsOalLog(DOBJ_HSM, DB_INFO, "Lat:Long:Alt is %g,%g,%g\n", pGpsLoct->latitude, pGpsLoct->longitude, pGpsLoct->altitude); |
| 1159 | * } |
| 1160 | * \endcode |
| 1161 | * |
| 1162 | * |
| 1163 | */ |
| 1164 | extern S32 mrvlGpsHsmUpdateLocationInfo(mrvlGpsLocation_t* pGpsLoct); |
| 1165 | |
| 1166 | /** |
| 1167 | * \brief |
| 1168 | * Implemented as callback by porting/integration code. Used by GNSS software to update SV information |
| 1169 | * |
| 1170 | * \param [IN] pGnssSvStat Pointer to SV information structure, containing all SVs tracked |
| 1171 | * |
| 1172 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1173 | * |
| 1174 | * \since |
| 1175 | * 1.2.8 |
| 1176 | * |
| 1177 | * <b>Example implementation</b> |
| 1178 | * \code |
| 1179 | * |
| 1180 | * S32 mrvlGpsHsmUpdateSvStatus(mrvlGnssSvStatus_t* pGnssSvStat) |
| 1181 | * { |
| 1182 | * gpsOalLog(DOBJ_HSM, DB_INFO, "%d GPS SVs and %d Glonass SVs\n", pGnssSvStat->gps_sv_status.num_svs, pGnssSvStat->gln_sv_status.num_svs_gln); |
| 1183 | * } |
| 1184 | * |
| 1185 | * \endcode |
| 1186 | * |
| 1187 | * |
| 1188 | */ |
| 1189 | extern S32 mrvlGpsHsmUpdateSvStatus(mrvlGnssSvStatus_t* pGnssSvStat); |
| 1190 | /** |
| 1191 | * \brief |
| 1192 | * Implemented as callback by porting/integration code. Used by GNSS software to send NMEA strings |
| 1193 | * |
| 1194 | * \param [IN] pGpsNmea Pointer to structure containing NMEA |
| 1195 | * |
| 1196 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1197 | * |
| 1198 | * \since |
| 1199 | * 1.2.8 |
| 1200 | * |
| 1201 | * <b>Example implementation</b> |
| 1202 | * \code |
| 1203 | * |
| 1204 | * S32 mrvlGpsHsmUpdateNMEA(mrvlGpsNmea_t* pGpsNmea) |
| 1205 | * { |
| 1206 | * gpsOalLog(DOBJ_HSM, DB_INFO, "NMEA String[%s]\n", pGpsNmea->nmeaInfo); |
| 1207 | * } |
| 1208 | * |
| 1209 | * \endcode |
| 1210 | * |
| 1211 | * |
| 1212 | */ |
| 1213 | extern S32 mrvlGpsHsmUpdateNMEA(mrvlGpsNmea_t* pGpsNmea); |
| 1214 | |
| 1215 | /** |
| 1216 | * \brief |
| 1217 | * Implemented as callback by porting/integration code. Used by GNSS software to update GNSS status (on/off/started/stopped) |
| 1218 | * |
| 1219 | * \param [IN] status GNSS status |
| 1220 | * |
| 1221 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1222 | * |
| 1223 | * \since |
| 1224 | * 1.2.8 |
| 1225 | * |
| 1226 | * <b>Example implementation</b> |
| 1227 | * \code |
| 1228 | * |
| 1229 | * mrvlGpsStatusUpdate(mrvlGpsHsmStatus_t status) |
| 1230 | * { |
| 1231 | * char *str = NULL; |
| 1232 | * switch (status) |
| 1233 | * { |
| 1234 | * case GPS_HSM_STATUS_INVALID: str = "INVALID"; break; |
| 1235 | * case GPS_HSM_STATUS_ON: str = "GPS_HSM_STATUS_ON"; break; |
| 1236 | * case GPS_HSM_STATUS_STARTED: str = "GPS_HSM_STATUS_STARTED"; break; |
| 1237 | * case GPS_HSM_STATUS_STOPPED: str = "GPS_HSM_STATUS_STOPPED"; break; |
| 1238 | * case GPS_HSM_STATUS_OFF: str = "GPS_HSM_STATUS_OFF"; break; |
| 1239 | * case GPS_HSM_STATUS_INVALID: str = "INVALID"; break; |
| 1240 | * } |
| 1241 | * gpsOalLog(DOBJ_HSM, DB_INFO, "GPS STATUS[%s]\n", str); |
| 1242 | * } |
| 1243 | * |
| 1244 | * \endcode |
| 1245 | * |
| 1246 | * |
| 1247 | */ |
| 1248 | extern S32 mrvlGpsStatusUpdate(mrvlGpsHsmStatus_t status); |
| 1249 | |
| 1250 | /** |
| 1251 | * \brief |
| 1252 | * Implemented as callback by porting/integration code. Used by GNSS software to update software events |
| 1253 | * |
| 1254 | * \param [IN] pEvt Pointer to event |
| 1255 | * |
| 1256 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1257 | * |
| 1258 | * \since |
| 1259 | * 2.4.0 |
| 1260 | * |
| 1261 | * <b>Example implementation</b> |
| 1262 | * \code |
| 1263 | * |
| 1264 | * |
| 1265 | * \endcode |
| 1266 | * |
| 1267 | * |
| 1268 | */ |
| 1269 | extern S32 mrvlGpsHsmEventUpdate(mrvlGpsHsmSwEvent_t* pEvt); |
| 1270 | |
| 1271 | /** |
| 1272 | * \brief |
| 1273 | * Implemented as callback by porting/integration code. Used by GNSS software to request for cell id. |
| 1274 | * mrvlGpsHsmUpdateCellid is called as response if UE is already registered, else it is called |
| 1275 | * when registration is successful |
| 1276 | * |
| 1277 | * \param None |
| 1278 | * |
| 1279 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1280 | * |
| 1281 | * \since |
| 1282 | * 1.2.8 |
| 1283 | * |
| 1284 | * <b>Example implementation</b> |
| 1285 | * \code |
| 1286 | * |
| 1287 | * |
| 1288 | * \endcode |
| 1289 | * |
| 1290 | * |
| 1291 | */ |
| 1292 | extern S32 mrvlGpsHsmRequestCellid(void); |
| 1293 | |
| 1294 | /** |
| 1295 | * \brief |
| 1296 | * Implemented as callback by porting/integration code. Used by GNSS software to request for SET id |
| 1297 | * mrvlGpsHsmUpdateSetId is called as response to set the SET id (IMSI or MSISDN) |
| 1298 | * \param None |
| 1299 | * |
| 1300 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1301 | * \return TRUE/FALSE response to query |
| 1302 | * |
| 1303 | * \since |
| 1304 | * 1.2.8 |
| 1305 | * |
| 1306 | * <b>Example implementation</b> |
| 1307 | * \code |
| 1308 | * |
| 1309 | * |
| 1310 | * \endcode |
| 1311 | * |
| 1312 | * |
| 1313 | */ |
| 1314 | extern S32 mrvlGpsHsmRequestSetId(void); |
| 1315 | |
| 1316 | /** |
| 1317 | * \brief |
| 1318 | * Implemented as callback by porting/integration code. Used by GNSS software to request for network connection |
| 1319 | * mrvlGpsHsmAgpsNwConnOpen is called if network connection is succesfully opened. Else, mrvlGpsHsmAgpsNwConnFail is called |
| 1320 | * \param None |
| 1321 | * |
| 1322 | * \return None |
| 1323 | * |
| 1324 | * \since |
| 1325 | * 1.2.8 |
| 1326 | * |
| 1327 | * <b>Example implementation</b> |
| 1328 | * \code |
| 1329 | * |
| 1330 | * \endcode |
| 1331 | * |
| 1332 | * |
| 1333 | */ |
| 1334 | extern void mrvlGpsHsmAgpsNwConnReq(void); |
| 1335 | |
| 1336 | /** |
| 1337 | * \brief |
| 1338 | * Implemented as callback by porting/integration code. Used by GNSS software to disconnect previously opened network connection |
| 1339 | * |
| 1340 | * \param None |
| 1341 | * |
| 1342 | * \return None |
| 1343 | * |
| 1344 | * \since |
| 1345 | * 1.2.8 |
| 1346 | * |
| 1347 | * <b>Example implementation</b> |
| 1348 | * \code |
| 1349 | * |
| 1350 | * \endcode |
| 1351 | * |
| 1352 | * |
| 1353 | */ |
| 1354 | extern void mrvlGpsHsmAgpsNwDisconnReq(void); |
| 1355 | |
| 1356 | /** |
| 1357 | * \brief |
| 1358 | * Implemented as callback by porting/integration code. Used by GNSS software to notify user of MTLR or SUPL NI |
| 1359 | * and request for verification if needed. As a response, mrvlGpsHsmAgpsNiResp needs to be called |
| 1360 | * when user accepts/denies the session |
| 1361 | * |
| 1362 | * \param [IN] notif Pointer to notification/verification structure including notification Id |
| 1363 | * |
| 1364 | * \return None |
| 1365 | * |
| 1366 | * \since |
| 1367 | * 1.2.8 |
| 1368 | * |
| 1369 | * <b>Example implementation</b> |
| 1370 | * \code |
| 1371 | * |
| 1372 | * \endcode |
| 1373 | * |
| 1374 | * |
| 1375 | */ |
| 1376 | extern void mrvlGpsHsmAgpsUserAuthReq(mrvlGpsUserNotifyParams_t* notif); |
| 1377 | |
| 1378 | /** |
| 1379 | * \brief |
| 1380 | * Implemented as callback by porting/integration code. Used by GNSS software to spawn a thread using |
| 1381 | * the integration/system code's thread framework. For e.g., in Android, it will be a thread |
| 1382 | * created by thread_create_cb function. All the callbacks are called from this thread, so that |
| 1383 | * the callback, implemented by porting code can use services/APIs available only to porting code |
| 1384 | * |
| 1385 | * \param [IN] name Pointer to string containing name of thread |
| 1386 | * \param [IN] funcPtr Pointer to entry function |
| 1387 | * |
| 1388 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1389 | * |
| 1390 | * \since |
| 1391 | * 1.2.8 |
| 1392 | * |
| 1393 | * <b>Example implementation</b> |
| 1394 | * \code |
| 1395 | * |
| 1396 | * |
| 1397 | * \endcode |
| 1398 | * |
| 1399 | * |
| 1400 | */ |
| 1401 | extern S32 mrvlGpsHsmSpawnAppThread(const char* name, void* funcPtr); |
| 1402 | |
| 1403 | /** |
| 1404 | * \brief |
| 1405 | * Implemented as callback by porting/integration code. Used by GNSS software to let the system know |
| 1406 | * that it cannot enter low power state that will block the host chip from running GNSS software |
| 1407 | * |
| 1408 | * \param None |
| 1409 | * |
| 1410 | * \return None |
| 1411 | * |
| 1412 | * \since |
| 1413 | * 2.3.5 |
| 1414 | * |
| 1415 | * <b>Example implementation</b> |
| 1416 | * \code |
| 1417 | * |
| 1418 | * |
| 1419 | * \endcode |
| 1420 | * |
| 1421 | * |
| 1422 | */ |
| 1423 | extern void mrvlGpsHsmAcquireWakeLock(void); |
| 1424 | |
| 1425 | /** |
| 1426 | * \brief |
| 1427 | * Implemented as callback by porting/integration code. Used by GNSS software to let the system |
| 1428 | * know that it is free to go to low power state and does not need let any GNSS thread execute |
| 1429 | * during this state. Usuall, this is called when GNSS software goes to sleep |
| 1430 | * |
| 1431 | * \param None |
| 1432 | * |
| 1433 | * \return None |
| 1434 | * |
| 1435 | * \since |
| 1436 | * 2.3.5 |
| 1437 | * |
| 1438 | * <b>Example implementation</b> |
| 1439 | * \code |
| 1440 | * |
| 1441 | * |
| 1442 | * \endcode |
| 1443 | * |
| 1444 | * |
| 1445 | */ |
| 1446 | extern void mrvlGpsHsmReleaseWakeLock(void); |
| 1447 | |
| 1448 | /** |
| 1449 | * \brief |
| 1450 | * Implemented as callback by porting/integration code. Used by GNSS software to initialize the wireless subsystem interface, |
| 1451 | * including the Control plane interface |
| 1452 | * |
| 1453 | * \param None |
| 1454 | * |
| 1455 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1456 | * |
| 1457 | * \since |
| 1458 | * 2.3.5 |
| 1459 | * |
| 1460 | * <b>Example implementation</b> |
| 1461 | * \code |
| 1462 | * |
| 1463 | * |
| 1464 | * \endcode |
| 1465 | * |
| 1466 | * |
| 1467 | */ |
| 1468 | extern S32 mrvlGpsHsmCpInterfaceInitHook(void); |
| 1469 | /** |
| 1470 | * \brief |
| 1471 | * Implemented as callback by porting/integration code. Used by GNSS software to cleanup the wireless subsystem interface, |
| 1472 | * including control plane interface |
| 1473 | * |
| 1474 | * \param None |
| 1475 | * |
| 1476 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1477 | * |
| 1478 | * \since |
| 1479 | * 2.3.5 |
| 1480 | * |
| 1481 | * <b>Example implementation</b> |
| 1482 | * \code |
| 1483 | * |
| 1484 | * |
| 1485 | * \endcode |
| 1486 | * |
| 1487 | * |
| 1488 | */ |
| 1489 | extern S32 mrvlGpsHsmCpInterfaceShutdownHook(void); |
| 1490 | |
| 1491 | /** |
| 1492 | * \brief |
| 1493 | * Implemented as callback by porting/integration code. Used by GNSS software to get the network |
| 1494 | * registration status |
| 1495 | * |
| 1496 | * \param None |
| 1497 | * |
| 1498 | * \return TRUE=registered, FALSE=not registered |
| 1499 | * |
| 1500 | * \since |
| 1501 | * 2.3.5 |
| 1502 | * |
| 1503 | * <b>Example implementation</b> |
| 1504 | * \code |
| 1505 | * |
| 1506 | * |
| 1507 | * \endcode |
| 1508 | * |
| 1509 | * |
| 1510 | */ |
| 1511 | extern int mrvlGpsHsmGetCPNWRegStatus(void); |
| 1512 | |
| 1513 | /** |
| 1514 | * \brief |
| 1515 | * Implemented as callback by porting/integration code. Used by GNSS software to let the porting/integration code |
| 1516 | * know that the user verification response for MTLR/SUPL NI |
| 1517 | * |
| 1518 | * \param [IN] notifId Notification id |
| 1519 | * \param [IN] present allow field contains valid value |
| 1520 | * \param [IN] allow 1 = allowed, 2 = denied |
| 1521 | * |
| 1522 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1523 | * |
| 1524 | * \since |
| 1525 | * 2.3.5 |
| 1526 | * |
| 1527 | * <b>Example implementation</b> |
| 1528 | * \code |
| 1529 | * |
| 1530 | * |
| 1531 | * \endcode |
| 1532 | * |
| 1533 | * |
| 1534 | */ |
| 1535 | extern S32 mrvlGpsHsmCpPosVerResp(S32 notifId, S32 present, S32 allow); |
| 1536 | |
| 1537 | /** |
| 1538 | * \brief |
| 1539 | * Implemented as callback by porting/integration code. Used by GNSS software to send a PDU out |
| 1540 | * to network via control plane |
| 1541 | * |
| 1542 | * \param [IN] protocol Protocol of PDU (RRLP/RRC/LPP/..) |
| 1543 | * \param [IN] pdu Pointer to PDU |
| 1544 | * \param [IN] pduLen PDU length |
| 1545 | * \param [IN] isFinal Is it final part of PDU |
| 1546 | * \param [IN] protocolMsgType Protocol specific sub type |
| 1547 | * |
| 1548 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1549 | * |
| 1550 | * \since |
| 1551 | * 2.3.5 |
| 1552 | * |
| 1553 | * <b>Example implementation</b> |
| 1554 | * \code |
| 1555 | * |
| 1556 | * |
| 1557 | * \endcode |
| 1558 | * |
| 1559 | * |
| 1560 | */ |
| 1561 | extern S32 mrvlGpsHsmCpSendUlMsg(AgpsProtocol_t protocol, U8* pdu, S32 pduLen, S32 isFinal, Rrc_PduType_t protocolMsgType, void* pAdditionalInfo, S32 additionInfoLen); |
| 1562 | #ifdef CPA_ECID |
| 1563 | /** |
| 1564 | * \brief |
| 1565 | * Implemented as callback by porting/integration code. Used by GNSS software to request ECID measurements |
| 1566 | * from wireless interface |
| 1567 | * |
| 1568 | * \param None |
| 1569 | * |
| 1570 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1571 | * |
| 1572 | * \since |
| 1573 | * 2.3.5 |
| 1574 | * |
| 1575 | * <b>Example implementation</b> |
| 1576 | * \code |
| 1577 | * |
| 1578 | * |
| 1579 | * \endcode |
| 1580 | * |
| 1581 | * |
| 1582 | */ |
| 1583 | extern S32 mrvlGpsHsmWrlsEcidMeasReq(void); |
| 1584 | |
| 1585 | /** |
| 1586 | * \brief |
| 1587 | * Implemented as callback by porting/integration code. Used by GNSS software to request LTE cell measurements |
| 1588 | * |
| 1589 | * \param [IN] enable_lp_ue_area_info_ind |
| 1590 | * |
| 1591 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1592 | * |
| 1593 | * \since |
| 1594 | * 2.3.5 |
| 1595 | * |
| 1596 | * <b>Example implementation</b> |
| 1597 | * \code |
| 1598 | * |
| 1599 | * |
| 1600 | * \endcode |
| 1601 | * |
| 1602 | * |
| 1603 | */ |
| 1604 | extern S32 mrvlGpsHsmLpUeAreaReq(unsigned int enable_lp_ue_area_info_ind); |
| 1605 | |
| 1606 | /** |
| 1607 | * \brief |
| 1608 | * Implemented as callback by porting/integration code. Used by GNSS software to request OTDOA measurement |
| 1609 | * |
| 1610 | * \param None |
| 1611 | * |
| 1612 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1613 | * |
| 1614 | * \since |
| 1615 | * 2.3.5 |
| 1616 | * |
| 1617 | * <b>Example implementation</b> |
| 1618 | * \code |
| 1619 | * |
| 1620 | * |
| 1621 | * \endcode |
| 1622 | * |
| 1623 | * |
| 1624 | */ |
| 1625 | extern S32 mrvlGpsHsmWrlsOtdoaMeasReq(void); |
| 1626 | |
| 1627 | /** |
| 1628 | * \brief |
| 1629 | * Implemented as callback by porting/integration code. Used by GNSS software to provide OTDOA assistance |
| 1630 | * |
| 1631 | * \param [IN] p_data Pointer to assistance structure |
| 1632 | * \param [IN] data_size Size of assistance structure |
| 1633 | * |
| 1634 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1635 | * |
| 1636 | * \since |
| 1637 | * 2.3.5 |
| 1638 | * |
| 1639 | * <b>Example implementation</b> |
| 1640 | * \code |
| 1641 | * |
| 1642 | * |
| 1643 | * \endcode |
| 1644 | * |
| 1645 | * |
| 1646 | */ |
| 1647 | extern S32 mrvlGpsHsmWrlsOtdoaAssistData(unsigned char* p_data, unsigned long int data_size); |
| 1648 | |
| 1649 | /** |
| 1650 | * \brief |
| 1651 | * Implemented as callback by porting/integration code. Used by GNSS software to send REGISTER message to indicate MOLR req to network |
| 1652 | * |
| 1653 | * \param [IN] transactionId Transaction id of REGISTER message to be sent out |
| 1654 | * \param [IN] locationEstimatePresent Encode if location estimate is requested |
| 1655 | * \param [IN] assistPresent Encode if assistance is requested |
| 1656 | * \param [IN] lppAssistancePdu If not NULL, this PDU is to be encapsulated inside LPP PDUs section of REGISTER |
| 1657 | * \param [IN] sizeAssistancePdu Size of assistance LPP PDU if present |
| 1658 | * \param [IN] lppProvideCapabilitiesPdu If not NULL, this PDU is to be encapsulated inside LPP PDUs section of REGISTER |
| 1659 | * \param [IN] sizeCapabilitiesPdu Size of provide capabilities LPP PDU if present |
| 1660 | * |
| 1661 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1662 | * |
| 1663 | * \since |
| 1664 | * 2.3.5 |
| 1665 | * |
| 1666 | * <b>Example implementation</b> |
| 1667 | * \code |
| 1668 | * |
| 1669 | * |
| 1670 | * \endcode |
| 1671 | * |
| 1672 | * |
| 1673 | */ |
| 1674 | extern S32 mrvlGpsHsmCpSendSsRegister(S32 transactionId, S32 locationEstimatePresent, S32 assistPresent, U8* lppAssistancePdu, S32 sizeAssistancePdu, U8* lppProvideCapabilitiesPdu, S32 sizeCapabilitiesPdu); |
| 1675 | |
| 1676 | /** |
| 1677 | * \brief |
| 1678 | * Implemented as callback by porting/integration code. Used by GNSS software to send RELEASE COMPLETE to network |
| 1679 | * |
| 1680 | * \param [IN] transactionId Transaction id of REGISTER message to be sent out |
| 1681 | * |
| 1682 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1683 | * |
| 1684 | * \since |
| 1685 | * 2.3.5 |
| 1686 | * |
| 1687 | * <b>Example implementation</b> |
| 1688 | * \code |
| 1689 | * |
| 1690 | * |
| 1691 | * \endcode |
| 1692 | * |
| 1693 | * |
| 1694 | */ |
| 1695 | extern S32 mrvlGpsHsmCpSendSsReleaseComplete(S32 transactionId); |
| 1696 | #endif |
| 1697 | |
| 1698 | /** |
| 1699 | * \brief |
| 1700 | * Implemented as callback by porting/integration code. Used by GNSS software to initialize AGPS logs |
| 1701 | * |
| 1702 | * \param None |
| 1703 | * |
| 1704 | * \return None |
| 1705 | * |
| 1706 | * \since |
| 1707 | * 2.4.0 |
| 1708 | * |
| 1709 | * <b>Example implementation</b> |
| 1710 | * \code |
| 1711 | * |
| 1712 | * |
| 1713 | * \endcode |
| 1714 | * |
| 1715 | * |
| 1716 | */ |
| 1717 | void mrvlGpsHsmAgpsLogInit(void); |
| 1718 | |
| 1719 | /** |
| 1720 | * \brief |
| 1721 | * Implemented as callback by porting/integration code. Used by GNSS software to trigger AGNSS diagnostic logs |
| 1722 | * |
| 1723 | * \param [IN] filter Diagnostic log level (debug/info/event/warning/error) |
| 1724 | * \param [IN] code Diagnostic code |
| 1725 | * \param [IN] sessionNum Session id if applicable |
| 1726 | * \param [IN] message Pointer to log message |
| 1727 | * |
| 1728 | * \return None |
| 1729 | * |
| 1730 | * \since |
| 1731 | * 2.3.5 |
| 1732 | * |
| 1733 | * <b>Example implementation</b> |
| 1734 | * \code |
| 1735 | * |
| 1736 | * |
| 1737 | * \endcode |
| 1738 | * |
| 1739 | * |
| 1740 | */ |
| 1741 | extern void mrvlGpsHsmAgpsLog(gpsOalLogLevelT filter, U32 code, S32 sessionNum, S8* message); |
| 1742 | |
| 1743 | /** |
| 1744 | * \brief |
| 1745 | * Implemented as callback by porting/integration code. Used by GNSS software to trigger AGNSS diagnostic interface logs |
| 1746 | * |
| 1747 | * \param [IN] direction Direction of message |
| 1748 | * \param [IN] type Type of interface message |
| 1749 | * \param [IN] buffer Interface message buffer pointer |
| 1750 | * \param [IN] len Length of buffer |
| 1751 | * |
| 1752 | * \return None |
| 1753 | * |
| 1754 | * \since |
| 1755 | * 2.3.5 |
| 1756 | * |
| 1757 | * <b>Example implementation</b> |
| 1758 | * \code |
| 1759 | * |
| 1760 | * |
| 1761 | * \endcode |
| 1762 | * |
| 1763 | * |
| 1764 | */ |
| 1765 | extern void mrvlGpsHsmAgpsIfLog(U32 direction, U32 type, void* buffer, U32 len); |
| 1766 | |
| 1767 | /** |
| 1768 | * \brief |
| 1769 | * Implemented as callback by porting/integration code. Used by GNSS software to get the current system reference time |
| 1770 | * |
| 1771 | * \param None |
| 1772 | * |
| 1773 | * \return Current system reference time |
| 1774 | * |
| 1775 | * \since |
| 1776 | * 2.3.5 |
| 1777 | * |
| 1778 | * <b>Example implementation</b> |
| 1779 | * \code |
| 1780 | * |
| 1781 | * |
| 1782 | * \endcode |
| 1783 | * |
| 1784 | * |
| 1785 | */ |
| 1786 | extern S64 mrvlGpsGetElapsedRealtime(void); |
| 1787 | |
| 1788 | |
| 1789 | /* Framework to HSM APIs */ |
| 1790 | /** |
| 1791 | * \brief |
| 1792 | * Implemented by GNSS software. Used by porting/integration code to check the GNSS chip status (if it is running and functional) |
| 1793 | * |
| 1794 | * \param None |
| 1795 | * |
| 1796 | * \return TRUE/FALSE response to query |
| 1797 | * |
| 1798 | * \since |
| 1799 | * 2.3.5 |
| 1800 | * |
| 1801 | * <b>Example usage</b> |
| 1802 | * \code |
| 1803 | * |
| 1804 | * |
| 1805 | * \endcode |
| 1806 | * |
| 1807 | * |
| 1808 | */ |
| 1809 | extern S8 mrvlGpsHsmChipStatusCheck(void); |
| 1810 | /** |
| 1811 | * \brief |
| 1812 | * Implemented by GNSS software. Used by porting/integration code to initialize GNSS software |
| 1813 | * This also involves downloading gnss chip firmware |
| 1814 | * |
| 1815 | * \param None |
| 1816 | * |
| 1817 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1818 | * |
| 1819 | * \since |
| 1820 | * 1.2.8 |
| 1821 | * |
| 1822 | * <b>Example usage</b> |
| 1823 | * \code |
| 1824 | * |
| 1825 | * |
| 1826 | * \endcode |
| 1827 | * |
| 1828 | * |
| 1829 | */ |
| 1830 | extern S32 mrvlGpsHsmInit(void); |
| 1831 | |
| 1832 | /** |
| 1833 | * \brief |
| 1834 | * Implemented by GNSS software. Used by porting/integration code to cleanup GNSS software |
| 1835 | * All threads created will be killed. |
| 1836 | * |
| 1837 | * \param None |
| 1838 | * |
| 1839 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1840 | * |
| 1841 | * \since |
| 1842 | * 1.2.8 |
| 1843 | * |
| 1844 | * <b>Example usage</b> |
| 1845 | * \code |
| 1846 | * |
| 1847 | * |
| 1848 | * \endcode |
| 1849 | * |
| 1850 | * |
| 1851 | */ |
| 1852 | extern S32 mrvlGpsHsmCleanup(void); |
| 1853 | |
| 1854 | /** |
| 1855 | * \brief |
| 1856 | * Implemented by GNSS software. Used by porting/integration code to start GNSS software |
| 1857 | * Multiple calls the this API will still result in only the first call actually starting the |
| 1858 | * software. Other API call instances will simply increment a reference count to maintain the |
| 1859 | * number of concurrent start requests. |
| 1860 | * |
| 1861 | * \param [IN] type Type of start |
| 1862 | * |
| 1863 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1864 | * |
| 1865 | * \since |
| 1866 | * 1.2.8 |
| 1867 | * |
| 1868 | * <b>Example usage</b> |
| 1869 | * \code |
| 1870 | * |
| 1871 | * |
| 1872 | * \endcode |
| 1873 | * |
| 1874 | * |
| 1875 | */ |
| 1876 | extern S32 mrvlGpsHsmStart(mrvlGpsAgpsProcType_t type); |
| 1877 | /** |
| 1878 | * \brief |
| 1879 | * Implemented by GNSS software. Used by porting/integration code to stop GNSS software |
| 1880 | * In cases where multiple calls to mrvlGpsHsmStart have been invoked, the GNSS software |
| 1881 | * will stop only when all these instances have called a stop. In other words, the first |
| 1882 | * mrvlGpsHsmStart api call will start GNSS, and the last mrvlGpsHsmStop will stop the GNSS. |
| 1883 | * |
| 1884 | * \param [IN] stopMode Mode indicating purpose of calling stop |
| 1885 | * |
| 1886 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 1887 | * |
| 1888 | * \since |
| 1889 | * 1.2.8 |
| 1890 | * |
| 1891 | * <b>Example usage</b> |
| 1892 | * \code |
| 1893 | * |
| 1894 | * |
| 1895 | * \endcode |
| 1896 | * |
| 1897 | * |
| 1898 | */ |
| 1899 | extern S32 mrvlGpsHsmStop(mrvlGpsHsmStopMode_t stopMode); |
| 1900 | extern S8 mrvlGpsHsmStopPrepare(void); |
| 1901 | extern void mrvlGpsHsmStopDelay(void); |
| 1902 | extern void mrvlGpsHsmForceStartModeByDeleteAiding(void); |
| 1903 | /** |
| 1904 | * \brief |
| 1905 | * Implemented by GNSS software. Used by porting/integration code to provide cell id to GNSS software |
| 1906 | * |
| 1907 | * \param [IN] type Type of cell (GSM/UMTS/LTE) |
| 1908 | * \param [IN] mcc Mobile country code |
| 1909 | * \param [IN] mnc Mobile network code |
| 1910 | * \param [IN] lac Location area code |
| 1911 | * \param [IN] cid Cell id |
| 1912 | * |
| 1913 | * \return None |
| 1914 | * |
| 1915 | * \since |
| 1916 | * 1.2.8 |
| 1917 | * |
| 1918 | * <b>Example usage</b> |
| 1919 | * \code |
| 1920 | * |
| 1921 | * |
| 1922 | * \endcode |
| 1923 | * |
| 1924 | * |
| 1925 | */ |
| 1926 | extern void mrvlGpsHsmUpdateCellid(U16 type, U16 mcc, U16 mnc, U16 lac, U32 cid); |
| 1927 | |
| 1928 | /** |
| 1929 | * \brief |
| 1930 | * Implemented by GNSS software. Used by porting/integration code to update set id (IMSI/MSISDN) |
| 1931 | * |
| 1932 | * \param [IN] setIdType SET id is IMSI or MSISDN |
| 1933 | * \param [IN] setId Pointer to SET id string |
| 1934 | * |
| 1935 | * \return None |
| 1936 | * |
| 1937 | * \since |
| 1938 | * 1.2.8 |
| 1939 | * |
| 1940 | * <b>Example usage</b> |
| 1941 | * \code |
| 1942 | * |
| 1943 | * |
| 1944 | * \endcode |
| 1945 | * |
| 1946 | * |
| 1947 | */ |
| 1948 | extern void mrvlGpsHsmUpdateSetId(U16 setIdType, U8* setId); |
| 1949 | |
| 1950 | /** |
| 1951 | * \brief |
| 1952 | * Implemented by GNSS software. Used by porting/integration code to update SUPL server |
| 1953 | * address and port. Can be called either by reading some system configuration file, or |
| 1954 | * by using the h-slp address stored in the SIM |
| 1955 | * |
| 1956 | * \param [IN] serverAddr Pointer to string that contains the fqdn or ip address of SUPL server |
| 1957 | * \param [IN] port TCP port of SUPL server. Usually 7275 or 7276 for SUPL 1.0/2.0 |
| 1958 | * |
| 1959 | * \return None |
| 1960 | * |
| 1961 | * \since |
| 1962 | * 1.2.8 |
| 1963 | * |
| 1964 | * <b>Example usage</b> |
| 1965 | * \code |
| 1966 | * |
| 1967 | * |
| 1968 | * \endcode |
| 1969 | * |
| 1970 | * |
| 1971 | */ |
| 1972 | extern void mrvlGpsHsmUpdateSuplServer(U8* serverAddr, U32 port); |
| 1973 | /** |
| 1974 | * \brief |
| 1975 | * Implemented by GNSS software. Used by porting/integration code to update the path |
| 1976 | * where the security certificates are stored. These certificates are used during |
| 1977 | * secure connection with SUPL server |
| 1978 | * |
| 1979 | * \param [IN] path Pointer to string containing folder path |
| 1980 | * |
| 1981 | * \return None |
| 1982 | * |
| 1983 | * \since |
| 1984 | * 1.2.8 |
| 1985 | * |
| 1986 | * <b>Example usage</b> |
| 1987 | * \code |
| 1988 | * |
| 1989 | * |
| 1990 | * \endcode |
| 1991 | * |
| 1992 | * |
| 1993 | */ |
| 1994 | extern void mrvlGpsHsmUpdateCaPath(U8* path); |
| 1995 | /** |
| 1996 | * \brief |
| 1997 | * Implemented by GNSS software. Used by porting/integration code to send a TSIP command |
| 1998 | * |
| 1999 | * \param [IN] type TSIP message type. Please refer to TSIP documentation for details |
| 2000 | * \param [IN] tsipBuffer Pointer to TSIP buffer. Please refer to TSIP documentation for details |
| 2001 | * \param [IN] len Length of TSIP buffer |
| 2002 | * |
| 2003 | * \return None |
| 2004 | * |
| 2005 | * \since |
| 2006 | * 1.2.8 |
| 2007 | * |
| 2008 | * <b>Example usage</b> |
| 2009 | * \code |
| 2010 | * |
| 2011 | * |
| 2012 | * \endcode |
| 2013 | * |
| 2014 | * |
| 2015 | */ |
| 2016 | extern void mrvlGpsHsmSendTsipCmd(U8 type, U8* tsipBuffer, S32 len); |
| 2017 | /** |
| 2018 | * \brief |
| 2019 | * Implemented by GNSS software. Used by porting/integration code to deliver SUPL_INIT message when received |
| 2020 | * via SMS/WAP/POTAP/UDP |
| 2021 | * |
| 2022 | * \param [IN] message Pointer to SUPL_INIT PDU |
| 2023 | * \param [IN] len Length of SUPL_INIT PDU |
| 2024 | * |
| 2025 | * \return None |
| 2026 | * |
| 2027 | * \since |
| 2028 | * 1.2.8 |
| 2029 | * |
| 2030 | * <b>Example usage</b> |
| 2031 | * \code |
| 2032 | * |
| 2033 | * |
| 2034 | * \endcode |
| 2035 | * |
| 2036 | * |
| 2037 | */ |
| 2038 | extern void mrvlGpsHsmAgpsNiMessage(U8* message, U32 len); |
| 2039 | /** |
| 2040 | * \brief |
| 2041 | * Implemented by GNSS software. Used by porting/integration code to inform the choice by user for a verfication request |
| 2042 | * |
| 2043 | * \param [IN] notifId Notification id |
| 2044 | * \param [IN] status 0=denied, 1=accepted |
| 2045 | * |
| 2046 | * \return None |
| 2047 | * |
| 2048 | * \since |
| 2049 | * 1.2.8 |
| 2050 | * |
| 2051 | * <b>Example usage</b> |
| 2052 | * \code |
| 2053 | * |
| 2054 | * |
| 2055 | * \endcode |
| 2056 | * |
| 2057 | * |
| 2058 | */ |
| 2059 | extern void mrvlGpsHsmAgpsNiResp(U32 notifId, U32 status); |
| 2060 | /** |
| 2061 | * \brief |
| 2062 | * Implemented by GNSS software. Used by porting/integration code to inform GNSS software |
| 2063 | * that network connection is opened |
| 2064 | * |
| 2065 | * \param [IN] apn Pointer to APN related to network connection |
| 2066 | * |
| 2067 | * \return None |
| 2068 | * |
| 2069 | * \since |
| 2070 | * 1.2.8 |
| 2071 | * |
| 2072 | * <b>Example usage</b> |
| 2073 | * \code |
| 2074 | * |
| 2075 | * |
| 2076 | * \endcode |
| 2077 | * |
| 2078 | * |
| 2079 | */ |
| 2080 | extern void mrvlGpsHsmAgpsNwConnOpen(U8* apn); |
| 2081 | /** |
| 2082 | * \brief |
| 2083 | * Implemented by GNSS software. Used by porting/integration code to indicate that the requested network |
| 2084 | * connection could not be made and the operation failed. |
| 2085 | * |
| 2086 | * \param None |
| 2087 | * |
| 2088 | * \return None |
| 2089 | * |
| 2090 | * \since |
| 2091 | * 1.2.8 |
| 2092 | * |
| 2093 | * <b>Example usage</b> |
| 2094 | * \code |
| 2095 | * |
| 2096 | * |
| 2097 | * \endcode |
| 2098 | * |
| 2099 | * |
| 2100 | */ |
| 2101 | extern void mrvlGpsHsmAgpsNwConnFail(void); |
| 2102 | |
| 2103 | /** |
| 2104 | * \brief |
| 2105 | * Implemented by GNSS software. Used by porting/integration code to indicate that the request |
| 2106 | * to disconnect from network has been processed and network connection is now closed |
| 2107 | * |
| 2108 | * \param None |
| 2109 | * |
| 2110 | * \return None |
| 2111 | * |
| 2112 | * \since |
| 2113 | * 1.2.8 |
| 2114 | * |
| 2115 | * <b>Example usage</b> |
| 2116 | * \code |
| 2117 | * |
| 2118 | * |
| 2119 | * \endcode |
| 2120 | * |
| 2121 | * |
| 2122 | */ |
| 2123 | extern void mrvlGpsHsmAgpsNwConnClosed(void); |
| 2124 | |
| 2125 | /** |
| 2126 | * \brief |
| 2127 | * Implemented by GNSS software. Used by porting/integration code to retrieve the integrity test results |
| 2128 | * |
| 2129 | * \param [IN] status Status to retrieve |
| 2130 | * \param [IN] data Pointer to structure where results will be stored |
| 2131 | * |
| 2132 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2133 | * \return TRUE/FALSE response to query |
| 2134 | * |
| 2135 | * \since |
| 2136 | * 1.2.8 |
| 2137 | * |
| 2138 | * <b>Example usage</b> |
| 2139 | * \code |
| 2140 | * |
| 2141 | * |
| 2142 | * \endcode |
| 2143 | * |
| 2144 | * |
| 2145 | */ |
| 2146 | extern S32 mrvlGpsHsmIntegTestResultGet(INTEG_TEST_STATUS status, void* data); |
| 2147 | |
| 2148 | /** |
| 2149 | * \brief |
| 2150 | * Implemented by GNSS software. Used by porting/integration code to get the current log level |
| 2151 | * |
| 2152 | * \param None |
| 2153 | * |
| 2154 | * \return Current log level |
| 2155 | * |
| 2156 | * \since |
| 2157 | * 1.2.8 |
| 2158 | * |
| 2159 | * <b>Example usage</b> |
| 2160 | * \code |
| 2161 | * |
| 2162 | * |
| 2163 | * \endcode |
| 2164 | * |
| 2165 | * |
| 2166 | */ |
| 2167 | extern U16 mrvlGpsHsmGetLogLevel(void); |
| 2168 | |
| 2169 | /** |
| 2170 | * \brief |
| 2171 | * Implemented by GNSS software. Used by porting/integration code to set current log level |
| 2172 | * |
| 2173 | * \param [IN] level |
| 2174 | * |
| 2175 | * \return None |
| 2176 | * |
| 2177 | * \since |
| 2178 | * 1.2.8 |
| 2179 | * |
| 2180 | * <b>Example usage</b> |
| 2181 | * \code |
| 2182 | * |
| 2183 | * |
| 2184 | * \endcode |
| 2185 | * |
| 2186 | * |
| 2187 | */ |
| 2188 | extern void mrvlGpsHsmSetLogLevel(U8 level); |
| 2189 | |
| 2190 | /** |
| 2191 | * \brief |
| 2192 | * Implemented by GNSS software. Used by porting/integration code to get the configured delay between |
| 2193 | * NMEA update and location updated. Usually, there is no delay, but can be set using configuration |
| 2194 | * parameters |
| 2195 | * |
| 2196 | * \param None |
| 2197 | * |
| 2198 | * \return Delay in milliseconds |
| 2199 | * |
| 2200 | * \since |
| 2201 | * 2.3.3 |
| 2202 | * |
| 2203 | * <b>Example usage</b> |
| 2204 | * \code |
| 2205 | * |
| 2206 | * |
| 2207 | * \endcode |
| 2208 | * |
| 2209 | * |
| 2210 | */ |
| 2211 | extern S32 mrvlGpsHsmGetLocUpdateDelay(void); |
| 2212 | /** |
| 2213 | * \brief |
| 2214 | * Implemented by GNSS software. Used by porting/integration code to check if GNSS software is currently in |
| 2215 | * factory reset mode |
| 2216 | * |
| 2217 | * \param None |
| 2218 | * |
| 2219 | * \return TRUE/FALSE response to query |
| 2220 | * |
| 2221 | * \since |
| 2222 | * 2.3.3 |
| 2223 | * |
| 2224 | * <b>Example usage</b> |
| 2225 | * \code |
| 2226 | * |
| 2227 | * |
| 2228 | * \endcode |
| 2229 | * |
| 2230 | * |
| 2231 | */ |
| 2232 | extern U32 mrvlGpsHsmIsFactoryReset(void); |
| 2233 | |
| 2234 | /** |
| 2235 | * \brief |
| 2236 | * Implemented by GNSS software. Used by porting/integration code to check if GNSS software is |
| 2237 | * currently executing factory test |
| 2238 | * |
| 2239 | * \param None |
| 2240 | * |
| 2241 | * \return TRUE/FALSE response to query |
| 2242 | * |
| 2243 | * \since |
| 2244 | * 2.3.3 |
| 2245 | * |
| 2246 | * <b>Example usage</b> |
| 2247 | * \code |
| 2248 | * |
| 2249 | * |
| 2250 | * \endcode |
| 2251 | * |
| 2252 | * |
| 2253 | */ |
| 2254 | extern U32 mrvlGpsHsmIsFactoryTestWorkMode(void); |
| 2255 | |
| 2256 | /** |
| 2257 | * \brief |
| 2258 | * Implemented by GNSS software. Used by porting/integration code to set if the GNSS software is |
| 2259 | * in normal mode or factory test mode |
| 2260 | * |
| 2261 | * \param [IN] mode |
| 2262 | * |
| 2263 | * \return None |
| 2264 | * |
| 2265 | * \since |
| 2266 | * 2.3.3 |
| 2267 | * |
| 2268 | * <b>Example usage</b> |
| 2269 | * \code |
| 2270 | * |
| 2271 | * |
| 2272 | * \endcode |
| 2273 | * |
| 2274 | * |
| 2275 | */ |
| 2276 | extern void mrvlGpsHsmSetMrvlgpsWorkMode(U32 mode); |
| 2277 | |
| 2278 | |
| 2279 | #ifdef MRVL_HSM_INCLUDE_SE |
| 2280 | /** |
| 2281 | * \brief |
| 2282 | * Implemented by GNSS software. Used by porting/integration code to enable SE to use a specific type of sensor |
| 2283 | * |
| 2284 | * \param [IN] sensorType Type of sensor |
| 2285 | * |
| 2286 | * \return None |
| 2287 | * |
| 2288 | * \since |
| 2289 | * 1.2.8 |
| 2290 | * |
| 2291 | * <b>Example usage</b> |
| 2292 | * \code |
| 2293 | * |
| 2294 | * |
| 2295 | * \endcode |
| 2296 | * |
| 2297 | * |
| 2298 | */ |
| 2299 | extern void mrvlGpsHsmSeEnable(S32 sensorType); |
| 2300 | |
| 2301 | /** |
| 2302 | * \brief |
| 2303 | * Implemented by GNSS software. Used by porting/integration code to disable SE from using a specific type of sensor |
| 2304 | * |
| 2305 | * \param [IN] sensorType Type of sensor |
| 2306 | * |
| 2307 | * \return None |
| 2308 | * |
| 2309 | * \since |
| 2310 | * 1.2.8 |
| 2311 | * |
| 2312 | * <b>Example usage</b> |
| 2313 | * \code |
| 2314 | * |
| 2315 | * |
| 2316 | * \endcode |
| 2317 | * |
| 2318 | * |
| 2319 | */ |
| 2320 | extern void mrvlGpsHsmSeDisable(S32 sensorType); |
| 2321 | |
| 2322 | /** |
| 2323 | * \brief |
| 2324 | * Implemented by GNSS software. Used by porting/integration code to inject sensor reading sample to GNSS software |
| 2325 | * |
| 2326 | * \param [IN] type Type of sensor |
| 2327 | * \param [IN] timestamp Timestamp in nanoseconds |
| 2328 | * \param [IN] accuracy Accuracy |
| 2329 | * \param [IN] x X value |
| 2330 | * \param [IN] y Y value |
| 2331 | * \param [IN] z Z value |
| 2332 | * |
| 2333 | * \return None |
| 2334 | * |
| 2335 | * \since |
| 2336 | * 1.2.8 |
| 2337 | * |
| 2338 | * <b>Example usage</b> |
| 2339 | * \code |
| 2340 | * |
| 2341 | * |
| 2342 | * \endcode |
| 2343 | * |
| 2344 | * |
| 2345 | */ |
| 2346 | extern void mrvlGpsHsmSeDataInject(U32 type, U64 timestamp, U32 accuracy, FLT x, FLT y, FLT z); |
| 2347 | |
| 2348 | /** |
| 2349 | * \brief |
| 2350 | * Implemented by GNSS software. Used by porting/integration code to gete the sensor sampling rate |
| 2351 | * |
| 2352 | * \param None |
| 2353 | * |
| 2354 | * \return Sensor sampling rate in Hz |
| 2355 | * |
| 2356 | * \since |
| 2357 | * 1.2.8 |
| 2358 | * |
| 2359 | * <b>Example usage</b> |
| 2360 | * \code |
| 2361 | * |
| 2362 | * |
| 2363 | * \endcode |
| 2364 | * |
| 2365 | * |
| 2366 | */ |
| 2367 | extern S32 mrvlGpsHsmGetSensorRate(void); |
| 2368 | /** |
| 2369 | * \brief |
| 2370 | * Implemented by GNSS software. Used by porting/integration code to initialize sensor engine |
| 2371 | * |
| 2372 | * \param None |
| 2373 | * |
| 2374 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2375 | * |
| 2376 | * \since |
| 2377 | * 1.2.8 |
| 2378 | * |
| 2379 | * <b>Example usage</b> |
| 2380 | * \code |
| 2381 | * |
| 2382 | * |
| 2383 | * \endcode |
| 2384 | * |
| 2385 | * |
| 2386 | */ |
| 2387 | extern U8 mrvlGpsHsmSeInit(void); |
| 2388 | |
| 2389 | /** |
| 2390 | * \brief |
| 2391 | * Implemented by GNSS software. Used by porting/integration code to cleanup sensor engine |
| 2392 | * |
| 2393 | * \param None |
| 2394 | * |
| 2395 | * \return None |
| 2396 | * |
| 2397 | * \since |
| 2398 | * 1.2.8 |
| 2399 | * |
| 2400 | * <b>Example usage</b> |
| 2401 | * \code |
| 2402 | * |
| 2403 | * |
| 2404 | * \endcode |
| 2405 | * |
| 2406 | * |
| 2407 | */ |
| 2408 | extern void mrvlGpsHsmSeCleanup(void); |
| 2409 | #endif |
| 2410 | extern S32 mrvlGpsHsmGetSuplPrivacyOverrideStatus(void); |
| 2411 | extern S32 mrvlGpsHsmGetSuplPrivacyLogOverrideStatus(void); |
| 2412 | extern void mrvlGpsHsmSetSuplPrivacyOverrideStatus(S32 status); |
| 2413 | extern void mrvlGpsHsmTsipSend(U32 port, U8* apiBuffer); |
| 2414 | |
| 2415 | /** |
| 2416 | * \brief |
| 2417 | * Implemented by GNSS software. Used by porting/integration code to set the origin plane for MOLR |
| 2418 | * |
| 2419 | * \param [IN] origin origin plane for MOLR: SUPL or Control plane |
| 2420 | * |
| 2421 | * \return None |
| 2422 | * |
| 2423 | * \since |
| 2424 | * 1.2.8 |
| 2425 | * |
| 2426 | * <b>Example usage</b> |
| 2427 | * \code |
| 2428 | * |
| 2429 | * |
| 2430 | * \endcode |
| 2431 | * |
| 2432 | * |
| 2433 | */ |
| 2434 | extern void mrvlGpsHsmSetSessionOrigin(S32 origin); |
| 2435 | |
| 2436 | /** |
| 2437 | * \brief |
| 2438 | * Implemented by GNSS software. Used by porting/integration code to set QOP for MOLR/SUPL SI |
| 2439 | * |
| 2440 | * \param [IN] horAcc Horizontal accuracy as specified in ETSI TS 123 032 V10.0.0 |
| 2441 | * \param [IN] verAcc Vertical accuracy as specified in ETSI TS 123 032 V10.0.0 |
| 2442 | * \param [IN] timeout Maximum response time allowed in seconds |
| 2443 | * |
| 2444 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2445 | * |
| 2446 | * \since |
| 2447 | * 1.2.8 |
| 2448 | * |
| 2449 | * <b>Example usage</b> |
| 2450 | * \code |
| 2451 | * |
| 2452 | * |
| 2453 | * \endcode |
| 2454 | * |
| 2455 | * |
| 2456 | */ |
| 2457 | extern S32 mrvlGpsHsmSetSessionQop(S8 horAcc, S8 verAcc, S32 timeout); |
| 2458 | |
| 2459 | |
| 2460 | /** |
| 2461 | * \brief |
| 2462 | * Implemented by GNSS software. Used by porting/integration code to set parameter to be sent out on MOLR command |
| 2463 | * |
| 2464 | * \param [IN] requestLocationEstimate Send out locationEstimate on MOLRArg |
| 2465 | * \param [IN] requestAssistance Send out assistance request on MOLRArg |
| 2466 | * |
| 2467 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2468 | * |
| 2469 | * \since |
| 2470 | * 1.2.8 |
| 2471 | * |
| 2472 | * <b>Example usage</b> |
| 2473 | * \code |
| 2474 | * |
| 2475 | * |
| 2476 | * \endcode |
| 2477 | * |
| 2478 | * |
| 2479 | */ |
| 2480 | extern S32 mrvlGpsHsmSetMolrReqParams(S32 requestLocationEstimate, S32 requestAssistance); |
| 2481 | |
| 2482 | /** |
| 2483 | * \brief |
| 2484 | * Implemented by GNSS software. Used by porting/integration code to set the list of allowed |
| 2485 | * GNSS technologies to be used for calculating position |
| 2486 | * |
| 2487 | * \param [IN] gnssMode Bitmap, 0x1 = GPS, 0x2 = GLONASS, 0x4=COMPASS |
| 2488 | * |
| 2489 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2490 | * |
| 2491 | * \since |
| 2492 | * 1.2.8 |
| 2493 | * |
| 2494 | * <b>Example usage</b> |
| 2495 | * \code |
| 2496 | * |
| 2497 | * |
| 2498 | * \endcode |
| 2499 | * |
| 2500 | * |
| 2501 | */ |
| 2502 | extern S32 mrvlGpsHsmSetGnssMode(U32 gnssMode); |
| 2503 | |
| 2504 | /** |
| 2505 | * \brief |
| 2506 | * Implemented by GNSS software. Used by porting/integration code to set the list of allowed |
| 2507 | * GNSS modes to use assistance from network |
| 2508 | * |
| 2509 | * \param [IN] gnssMode Bitmap, 0x1 = AGPS, 0x2 = AGLONASS |
| 2510 | * |
| 2511 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2512 | * |
| 2513 | * \since |
| 2514 | * 1.2.8 |
| 2515 | * |
| 2516 | * <b>Example usage</b> |
| 2517 | * \code |
| 2518 | * |
| 2519 | * |
| 2520 | * \endcode |
| 2521 | * |
| 2522 | * |
| 2523 | */ |
| 2524 | extern S32 mrvlGpsHsmSetAgnssMode(U32 gnssMode); |
| 2525 | |
| 2526 | /** |
| 2527 | * \brief |
| 2528 | * Implemented by GNSS software. Used by porting/integration code to get current start mode |
| 2529 | * GNSS is operating. During normal operations, it will operate in NORMAL_MODE (= 0). Else |
| 2530 | * It will be COLD(1)/HOT(2)/WARM(3) |
| 2531 | * |
| 2532 | * \param None |
| 2533 | * |
| 2534 | * \return Operating mode - normal/cold/hot/warm |
| 2535 | * |
| 2536 | * \since |
| 2537 | * 1.2.8 |
| 2538 | * |
| 2539 | * <b>Example usage</b> |
| 2540 | * \code |
| 2541 | * |
| 2542 | * |
| 2543 | * \endcode |
| 2544 | * |
| 2545 | * |
| 2546 | */ |
| 2547 | extern U32 mrvlGpsHsmGetStartMode(void); |
| 2548 | |
| 2549 | /** |
| 2550 | * \brief |
| 2551 | * Implemented by GNSS software. Used by porting/integration code to enable power save schemes |
| 2552 | * |
| 2553 | * \param [IN] enable Enable power save schemes when available |
| 2554 | * \param [IN] period Minimum interval between required position fixes |
| 2555 | * |
| 2556 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2557 | * |
| 2558 | * \since |
| 2559 | * 1.2.8 |
| 2560 | * |
| 2561 | * <b>Example usage</b> |
| 2562 | * \code |
| 2563 | * |
| 2564 | * |
| 2565 | * \endcode |
| 2566 | * |
| 2567 | * |
| 2568 | */ |
| 2569 | extern S32 mrvlGpsHsmPsModeSetStatus(S32 enable, U16 period); |
| 2570 | |
| 2571 | /** |
| 2572 | * \brief |
| 2573 | * Implemented by GNSS software. Used by porting/integration code to know if power save |
| 2574 | * scheme is currently enabled |
| 2575 | * |
| 2576 | * \param None |
| 2577 | * |
| 2578 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2579 | * |
| 2580 | * \since |
| 2581 | * 1.2.8 |
| 2582 | * |
| 2583 | * <b>Example usage</b> |
| 2584 | * \code |
| 2585 | * |
| 2586 | * |
| 2587 | * \endcode |
| 2588 | * |
| 2589 | * |
| 2590 | */ |
| 2591 | extern S32 mrvlGpsHsmPsModeGetStatus(void); |
| 2592 | |
| 2593 | /** |
| 2594 | * \brief |
| 2595 | * Implemented by GNSS software. Used by porting/integration code to know if chip has downloaded |
| 2596 | * firmware and started executing it |
| 2597 | * |
| 2598 | * \param None |
| 2599 | * |
| 2600 | * \return TRUE/FALSE response to query |
| 2601 | * |
| 2602 | * \since |
| 2603 | * 1.2.8 |
| 2604 | * |
| 2605 | * <b>Example usage</b> |
| 2606 | * \code |
| 2607 | * |
| 2608 | * |
| 2609 | * \endcode |
| 2610 | * |
| 2611 | * |
| 2612 | */ |
| 2613 | extern U32 mrvlGpsHsmChipInNormalStatus(void); |
| 2614 | |
| 2615 | /** |
| 2616 | * \brief |
| 2617 | * Implemented by GNSS software. Used by porting/integration code to enable/disable EE feature |
| 2618 | * |
| 2619 | * \param [IN] eeMode 1=enable, 0=disable |
| 2620 | * |
| 2621 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2622 | * |
| 2623 | * \since |
| 2624 | * 1.2.8 |
| 2625 | * |
| 2626 | * <b>Example usage</b> |
| 2627 | * \code |
| 2628 | * |
| 2629 | * |
| 2630 | * \endcode |
| 2631 | * |
| 2632 | * |
| 2633 | */ |
| 2634 | extern S32 mrvlGpsHsmSetEEMode(U32 eeMode); |
| 2635 | |
| 2636 | /** |
| 2637 | * \brief |
| 2638 | * Implemented by GNSS software. Used by porting/integration code to get the currently set EE mode |
| 2639 | * |
| 2640 | * \param None |
| 2641 | * |
| 2642 | * \return TRUE=enabled, FALSE=disabled |
| 2643 | * |
| 2644 | * \since |
| 2645 | * 1.2.8 |
| 2646 | * |
| 2647 | * <b>Example usage</b> |
| 2648 | * \code |
| 2649 | * |
| 2650 | * |
| 2651 | * \endcode |
| 2652 | * |
| 2653 | * |
| 2654 | */ |
| 2655 | extern S32 mrvlGpsHsmGetEEMode(void); |
| 2656 | |
| 2657 | /** |
| 2658 | * \brief |
| 2659 | * Implemented by GNSS software. Used by porting/integration code to reset GNSS settings to factory defaults |
| 2660 | * This clears QOP, sets default MOLR plane as user plane, enables GPS/GLONASS |
| 2661 | * |
| 2662 | * \param None |
| 2663 | * |
| 2664 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2665 | * |
| 2666 | * \since |
| 2667 | * 2.3.3 |
| 2668 | * |
| 2669 | * <b>Example usage</b> |
| 2670 | * \code |
| 2671 | * |
| 2672 | * |
| 2673 | * \endcode |
| 2674 | * |
| 2675 | * |
| 2676 | */ |
| 2677 | extern S32 mrvlGpsHsmRestoreFactoryDefaults(void); |
| 2678 | |
| 2679 | /** |
| 2680 | * \brief |
| 2681 | * Implemented by GNSS software. Used by porting/integration code to get current software version |
| 2682 | * |
| 2683 | * \param [IN] verString Pointer to string indicating factory version |
| 2684 | * \param [IN] verLen Pointer to length of verString |
| 2685 | * |
| 2686 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2687 | * |
| 2688 | * \since |
| 2689 | * 2.3.3 |
| 2690 | * |
| 2691 | * <b>Example usage</b> |
| 2692 | * \code |
| 2693 | * |
| 2694 | * |
| 2695 | * \endcode |
| 2696 | * |
| 2697 | * |
| 2698 | */ |
| 2699 | extern S32 mrvlGpsHsmGetSwVer(U8* verString, S32* verLen); |
| 2700 | |
| 2701 | /** |
| 2702 | * \brief |
| 2703 | * Implemented by GNSS software. Used by porting/integration code to check if ECLK is supported |
| 2704 | * |
| 2705 | * \param None |
| 2706 | * |
| 2707 | * \return TRUE/FALSE response to query |
| 2708 | * |
| 2709 | * \since |
| 2710 | * 2.3.5 |
| 2711 | * |
| 2712 | * <b>Example usage</b> |
| 2713 | * \code |
| 2714 | * |
| 2715 | * |
| 2716 | * \endcode |
| 2717 | * |
| 2718 | * |
| 2719 | */ |
| 2720 | extern S32 mrvlGpsHsmGetEclkSupported(void); |
| 2721 | extern S32 mrvlGpsHsmGetEclkEnable(void); |
| 2722 | |
| 2723 | /** |
| 2724 | * \brief |
| 2725 | * Implemented by GNSS software. Used by porting/integration code to get HAL specific context string. |
| 2726 | * HAL specific context is stored in configuration per platform type, and the porting code can retrieve the |
| 2727 | * store context information in form or a string. Interpretation of the string is platform-specific |
| 2728 | * |
| 2729 | * \param None |
| 2730 | * |
| 2731 | * \return Pointer to HAL context string |
| 2732 | * |
| 2733 | * \since |
| 2734 | * 1.2.8 |
| 2735 | * |
| 2736 | * <b>Example usage</b> |
| 2737 | * \code |
| 2738 | * |
| 2739 | * |
| 2740 | * \endcode |
| 2741 | * |
| 2742 | * |
| 2743 | */ |
| 2744 | extern void* mrvlGpsHsmGetHalCtx(void); |
| 2745 | |
| 2746 | /** |
| 2747 | * \brief |
| 2748 | * Implemented by GNSS software. Used by porting/integration code to reset stored GNSS positioning information as specified |
| 2749 | * This involves time, last known location, navigation parameters etc., |
| 2750 | * |
| 2751 | * \param [IN] aidingMask Mask indicating which information needs to be deleted |
| 2752 | * |
| 2753 | * \return None |
| 2754 | * |
| 2755 | * \since |
| 2756 | * 2.3.5 |
| 2757 | * |
| 2758 | * <b>Example usage</b> |
| 2759 | * \code |
| 2760 | * |
| 2761 | * |
| 2762 | * \endcode |
| 2763 | * |
| 2764 | * |
| 2765 | */ |
| 2766 | extern void mrvlGpsHsmResetStoredPosInfo(U16 aidingMask); |
| 2767 | |
| 2768 | /** |
| 2769 | * \brief |
| 2770 | * Implemented by GNSS software. Used by porting/integration code to know if GNSS software maitains |
| 2771 | * an internal timer mechanism to timeout user verification response. If internal timer is maitained, the |
| 2772 | * default action for verification on no user response is automatically triggered by the GNSS |
| 2773 | * software (accept-on-no-answer or reject-on-no-answer) |
| 2774 | * |
| 2775 | * \param None |
| 2776 | * |
| 2777 | * \return TRUE/FALSE response to query |
| 2778 | * |
| 2779 | * \since |
| 2780 | * 1.2.8 |
| 2781 | * |
| 2782 | * <b>Example usage</b> |
| 2783 | * \code |
| 2784 | * |
| 2785 | * |
| 2786 | * \endcode |
| 2787 | * |
| 2788 | * |
| 2789 | */ |
| 2790 | extern S32 mrvlGpsGetAgpsInternalAuthTimeoutFlag(void); |
| 2791 | |
| 2792 | /** |
| 2793 | * \brief |
| 2794 | * Implemented by GNSS software. Used by porting/integration code to enable GNSS to maintain internal timer |
| 2795 | * to detect user verification response timeout. If enabled, default action on no user response is automatically |
| 2796 | * performed by GNSS software (accept-on-no-answer or reject-on-no-answer) |
| 2797 | * |
| 2798 | * \param [IN] flag |
| 2799 | * |
| 2800 | * \return None |
| 2801 | * |
| 2802 | * \since |
| 2803 | * 2.3.5 |
| 2804 | * |
| 2805 | * <b>Example usage</b> |
| 2806 | * \code |
| 2807 | * |
| 2808 | * |
| 2809 | * \endcode |
| 2810 | * |
| 2811 | * |
| 2812 | */ |
| 2813 | extern void mrvlGpsSetAgpsInternalAuthTimeoutFlag(S32 flag); |
| 2814 | |
| 2815 | /** |
| 2816 | * \brief |
| 2817 | * Implemented by GNSS software. Used by porting/integration code to get the UDP port on which |
| 2818 | * SUPL will listen for SUPL_INIT messages. |
| 2819 | * |
| 2820 | * \param None |
| 2821 | * |
| 2822 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2823 | * |
| 2824 | * \since |
| 2825 | * 2.3.5 |
| 2826 | * |
| 2827 | * <b>Example usage</b> |
| 2828 | * \code |
| 2829 | * |
| 2830 | * |
| 2831 | * \endcode |
| 2832 | * |
| 2833 | * |
| 2834 | */ |
| 2835 | extern S32 mrvlGpsHsmAgpsGetSuplClientPort(void); |
| 2836 | |
| 2837 | /** |
| 2838 | * \brief |
| 2839 | * Implemented by GNSS software. Used by porting/integration code to get the interval used |
| 2840 | * by GNSS software to update positioning information |
| 2841 | * |
| 2842 | * \param None |
| 2843 | * |
| 2844 | * \return Reporting interval in seconds |
| 2845 | * |
| 2846 | * \since |
| 2847 | * 2.3.5 |
| 2848 | * |
| 2849 | * <b>Example usage</b> |
| 2850 | * \code |
| 2851 | * |
| 2852 | * |
| 2853 | * \endcode |
| 2854 | * |
| 2855 | * |
| 2856 | */ |
| 2857 | extern U32 mrvlGpsHsmGetReptInterval(void); |
| 2858 | |
| 2859 | /** |
| 2860 | * \brief |
| 2861 | * Implemented by GNSS software. Used by porting/integration code to get path where |
| 2862 | * GNSS software is storing log files |
| 2863 | * |
| 2864 | * \param None |
| 2865 | * |
| 2866 | * \return Pointer to the string containing log path |
| 2867 | * |
| 2868 | * \since |
| 2869 | * 2.3.5 |
| 2870 | * |
| 2871 | * <b>Example usage</b> |
| 2872 | * \code |
| 2873 | * |
| 2874 | * |
| 2875 | * \endcode |
| 2876 | * |
| 2877 | * |
| 2878 | */ |
| 2879 | extern U8* mrvlGpsHsmGetLogPath(void); |
| 2880 | |
| 2881 | |
| 2882 | /** |
| 2883 | * \brief |
| 2884 | * Implemented by GNSS software. Used by porting/integration code to get path where |
| 2885 | * GNSS software is storing agps.log and agpsdebug.log file |
| 2886 | * |
| 2887 | * \param None |
| 2888 | * |
| 2889 | * \return Pointer to the string containing log path |
| 2890 | * |
| 2891 | * \since |
| 2892 | * 2.4.0 |
| 2893 | * |
| 2894 | * <b>Example usage</b> |
| 2895 | * \code |
| 2896 | * |
| 2897 | * |
| 2898 | * \endcode |
| 2899 | * |
| 2900 | * |
| 2901 | */ |
| 2902 | extern U8* mrvlGpsHsmGetAgpsLogPath(void); |
| 2903 | /** |
| 2904 | * \brief |
| 2905 | * Implemented by GNSS software. Used by porting/integration code to send control plane PDU from network into the |
| 2906 | * GNSS software |
| 2907 | * |
| 2908 | * \param [IN] ota_type Protocol of PDU |
| 2909 | * \param [IN] wrlsPriority Priority (emergency or non-emergency) |
| 2910 | * \param [IN] p_msg_data Pointer to PDU |
| 2911 | * \param [IN] msg_size Length of PDU |
| 2912 | * |
| 2913 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2914 | * |
| 2915 | * \since |
| 2916 | * 2.3.5 |
| 2917 | * |
| 2918 | * <b>Example usage</b> |
| 2919 | * \code |
| 2920 | * |
| 2921 | * |
| 2922 | * \endcode |
| 2923 | * |
| 2924 | * |
| 2925 | */ |
| 2926 | extern S32 mrvlGpsHsmCpProcessDlMsg(AgpsProtocol_t ota_type, Agps_SessionPriority_t wrlsPriority, unsigned char* p_msg_data, unsigned long int msg_size, void* pAdditionalInfo, S32 len); |
| 2927 | |
| 2928 | /** |
| 2929 | * \brief |
| 2930 | * Implemented by GNSS software. Used by porting/integration code to indicate that the RRC measurement session |
| 2931 | * has terminated |
| 2932 | * |
| 2933 | * \param None |
| 2934 | * |
| 2935 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2936 | * |
| 2937 | * \since |
| 2938 | * 2.3.5 |
| 2939 | * |
| 2940 | * <b>Example usage</b> |
| 2941 | * \code |
| 2942 | * |
| 2943 | * |
| 2944 | * \endcode |
| 2945 | * |
| 2946 | * |
| 2947 | */ |
| 2948 | extern S32 mrvlGpsHsmCpMeasTerminatedInd(void); |
| 2949 | |
| 2950 | /** |
| 2951 | * \brief |
| 2952 | * Implemented by GNSS software. Used by porting/integration code to notify RRC state change |
| 2953 | * |
| 2954 | * \param [IN] rrc_state RRC state |
| 2955 | * |
| 2956 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2957 | * |
| 2958 | * \since |
| 2959 | * 2.3.5 |
| 2960 | * |
| 2961 | * <b>Example usage</b> |
| 2962 | * \code |
| 2963 | * |
| 2964 | * |
| 2965 | * \endcode |
| 2966 | * |
| 2967 | * |
| 2968 | */ |
| 2969 | extern S32 mrvlGpsHsmCpRRCStateEvent(unsigned int rrc_state); |
| 2970 | |
| 2971 | /** |
| 2972 | * \brief |
| 2973 | * Implemented by GNSS software. Used by porting/integration code to indicate that E911 or emergency |
| 2974 | * call has been dialled |
| 2975 | * |
| 2976 | * \param None |
| 2977 | * |
| 2978 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 2979 | * |
| 2980 | * \since |
| 2981 | * 2.3.5 |
| 2982 | * |
| 2983 | * <b>Example usage</b> |
| 2984 | * \code |
| 2985 | * |
| 2986 | * |
| 2987 | * \endcode |
| 2988 | * |
| 2989 | * |
| 2990 | */ |
| 2991 | extern S32 mrvlGpsHsmCpNotfiyE911Dialed(void); |
| 2992 | |
| 2993 | /** |
| 2994 | * \brief |
| 2995 | * Implemented by GNSS software. Used by porting/integration code to notify an MTLR from network |
| 2996 | * |
| 2997 | * \param [IN] pNotif Pointer to notification |
| 2998 | * |
| 2999 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3000 | * |
| 3001 | * \since |
| 3002 | * 2.3.5 |
| 3003 | * |
| 3004 | * <b>Example usage</b> |
| 3005 | * \code |
| 3006 | * |
| 3007 | * |
| 3008 | * \endcode |
| 3009 | * |
| 3010 | * |
| 3011 | */ |
| 3012 | extern S32 mrvlGpsHsmCpMtlrNotifyLocInd(mrvlGpsUserNotifyParams_t* pNotif); |
| 3013 | #ifdef CPA_ECID |
| 3014 | /** |
| 3015 | * \brief |
| 3016 | * Implemented by GNSS software. Used by porting/integration code to send ECID measurements to GNSS software |
| 3017 | * |
| 3018 | * \param [IN] pCpaLpEcidMeas Pointer to |
| 3019 | * |
| 3020 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3021 | * |
| 3022 | * \since |
| 3023 | * 2.3.5 |
| 3024 | * |
| 3025 | * <b>Example usage</b> |
| 3026 | * \code |
| 3027 | * |
| 3028 | * |
| 3029 | * \endcode |
| 3030 | * |
| 3031 | * |
| 3032 | */ |
| 3033 | extern S32 mrvlGpsHsmCpEcidMeasNotify(mrvlGpsHsmEcidMeasCnf_t* pCpaLpEcidMeas); |
| 3034 | |
| 3035 | /** |
| 3036 | * \brief |
| 3037 | * Implemented by GNSS software. Used by porting/integration code to LTE cellular measurements to GNSS software |
| 3038 | * |
| 3039 | * \param [IN] pCpaLpUeAreaInfoInd Pointer to LTE cellular measurements |
| 3040 | * |
| 3041 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3042 | * |
| 3043 | * \since |
| 3044 | * 2.3.5 |
| 3045 | * |
| 3046 | * <b>Example usage</b> |
| 3047 | * \code |
| 3048 | * |
| 3049 | * |
| 3050 | * \endcode |
| 3051 | * |
| 3052 | * |
| 3053 | */ |
| 3054 | extern S32 mrvlGpsHsmCpUeAreaInfoNotify(mrvlGpsHsmUeAreaInfo_t* pCpaLpUeAreaInfoInd); |
| 3055 | |
| 3056 | /** |
| 3057 | * \brief |
| 3058 | * Implemented by GNSS software. Used by porting/integration code to notify OTDOA measurements to GNSS software |
| 3059 | * |
| 3060 | * \param [IN] pHsmRstdLocInfo Pointer to OTDOA measurements |
| 3061 | * |
| 3062 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3063 | * |
| 3064 | * \since |
| 3065 | * 2.3.5 |
| 3066 | * |
| 3067 | * <b>Example usage</b> |
| 3068 | * \code |
| 3069 | * |
| 3070 | * |
| 3071 | * \endcode |
| 3072 | * |
| 3073 | * |
| 3074 | */ |
| 3075 | extern S32 mrvlGpsHsmLpOtdoaMeasNotify(mrvlGpsHsmProvideRstdLocInfoMsg_t* pHsmRstdLocInfo); |
| 3076 | #endif |
| 3077 | |
| 3078 | /** |
| 3079 | * \brief |
| 3080 | * Implemented by GNSS software. Used by porting/integration code to send a CLI command to GNSS software |
| 3081 | * |
| 3082 | * \param [IN] s Pointer to CLI command |
| 3083 | * |
| 3084 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3085 | * |
| 3086 | * \since |
| 3087 | * 2.3.5 |
| 3088 | * |
| 3089 | * <b>Example usage</b> |
| 3090 | * \code |
| 3091 | * |
| 3092 | * |
| 3093 | * \endcode |
| 3094 | * |
| 3095 | * |
| 3096 | */ |
| 3097 | extern S32 mrvlGpsHsmCliProc(char* s); |
| 3098 | |
| 3099 | #ifdef OS_ANDROID |
| 3100 | /** |
| 3101 | * \brief |
| 3102 | * Implemented by GNSS software. Used by porting/integration code to inject UTC/Network time wrt current reference |
| 3103 | * time in the system. Reference time is platform specific |
| 3104 | * |
| 3105 | * \param [IN] time |
| 3106 | * |
| 3107 | * \param [IN] timeReference |
| 3108 | * |
| 3109 | * \return None |
| 3110 | * |
| 3111 | * \since |
| 3112 | * 2.3.5 |
| 3113 | * |
| 3114 | * <b>Example usage</b> |
| 3115 | * \code |
| 3116 | * |
| 3117 | * |
| 3118 | * \endcode |
| 3119 | * |
| 3120 | * |
| 3121 | */ |
| 3122 | extern void mrvlGpsHsmRecordNetTime(U64 time, U64 timeReference); |
| 3123 | extern void mrvlGpsHsmRecordNetLocation(double latitude, double longitude, float accuracy); |
| 3124 | |
| 3125 | #endif |
| 3126 | /** |
| 3127 | * \brief |
| 3128 | * Implemented by GNSS software. Used by porting/integration code to get the current UTC/Network time from system |
| 3129 | * It is calculated based on time set using mrvlGpsHsmRecordNetTime() and elapsed time from provided reference time |
| 3130 | * |
| 3131 | * \param [IN] wn Pointer to week number |
| 3132 | * \param [IN] tow_ms Pointer to TOW in milliseconds |
| 3133 | * |
| 3134 | * \return SUCCESS/FAILURE if operation succeeds/fails |
| 3135 | * |
| 3136 | * \since |
| 3137 | * 2.3.5 |
| 3138 | * |
| 3139 | * <b>Example usage</b> |
| 3140 | * \code |
| 3141 | * |
| 3142 | * |
| 3143 | * \endcode |
| 3144 | * |
| 3145 | * |
| 3146 | */ |
| 3147 | extern U8 mrvlGpsHsmGetNetTime(U16* wn, U32* tow_ms); |
| 3148 | extern U8 mrvlGpsHsmGetNetLocation(double* latitude, double* longitude, float* accuracy); |
| 3149 | |
| 3150 | |
| 3151 | /** |
| 3152 | * \brief |
| 3153 | * Implemented by GNSS software. This is utility function provided by the GNSS software to convert a given |
| 3154 | * buffer to a hex string |
| 3155 | * |
| 3156 | * \param [IN] inBuf Pointer to input buffer |
| 3157 | * \param [IN] outBuf Pointer to converted hex string |
| 3158 | * \param [IN] len Length of hex string |
| 3159 | * |
| 3160 | * \return None |
| 3161 | * |
| 3162 | * \since |
| 3163 | * 2.3.5 |
| 3164 | * |
| 3165 | * <b>Example usage</b> |
| 3166 | * \code |
| 3167 | * |
| 3168 | * |
| 3169 | * \endcode |
| 3170 | * |
| 3171 | * |
| 3172 | */ |
| 3173 | extern void mrvlGPSHsmPrintHexString(char* inBuf, char* outBuf, unsigned long len); |
| 3174 | |
| 3175 | |
| 3176 | extern void mrvlGPSHsmPrintTime(void* fd); |
| 3177 | extern void mrvlGpsHsmUpdateImsiMncMcc(void); |
| 3178 | U8 mrvlGpsHsmGetRRCExtEnable(void); |
| 3179 | |
| 3180 | #ifdef __cplusplus |
| 3181 | } |
| 3182 | #endif |
| 3183 | |
| 3184 | #endif |
| 3185 | |