From a2fc84b21943cff412bf7faf42ec99571b9ce895 Mon Sep 17 00:00:00 2001 From: Anup Dasari Date: Tue, 10 Jul 2012 22:35:56 +0530 Subject: [PATCH 01/33] Add optional flag in make file Change-Id: I099cd597c77641bdf2a98732f87484ec6d70f9a9 --- loc_api/libloc_api/Android.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/loc_api/libloc_api/Android.mk b/loc_api/libloc_api/Android.mk index 1fd409f5..df2ff2d0 100755 --- a/loc_api/libloc_api/Android.mk +++ b/loc_api/libloc_api/Android.mk @@ -11,6 +11,8 @@ include $(CLEAR_VARS) LOCAL_MODULE := gps.$(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE) +LOCAL_MODULE_TAGS := optional + LOCAL_STATIC_LIBRARIES:= \ libloc_api-rpc From 3c2630ef2aa770721337a7471fcd4f4ab759cbcb Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Thu, 12 Jul 2012 18:31:41 -0700 Subject: [PATCH 02/33] gps: initial merge to jb based from AU_LINUX_ANDROID_ICS.04.00.01.00.007 with qcom enhanced features flagged out Change-Id: I2bc03fe4447047fd7c9a7d000040dadb8bb34647 --- loc_api/Android.mk | 26 +- loc_api/libloc_api-rpc-50001/Android.mk | 3 + .../libloc_api-rpc-glue/Android.mk | 59 + .../rpc_inc/LocApiRpcAdapter.h | 102 + .../libloc_api-rpc-glue/rpc_inc/debug.h | 69 + .../rpc_inc/loc_api_fixup.h | 226 + .../libloc_api-rpc-glue/rpc_inc/loc_api_log.h | 59 + .../rpc_inc/loc_api_rpc_glue.h | 123 + .../rpc_inc/loc_api_sync_call.h | 90 + .../rpc_inc/loc_apicb_appinit.h | 45 + .../src/LocApiRpcAdapter.cpp | 1225 ++++ .../libloc_api-rpc-glue/src/loc_api_fixup.c | 52 + .../libloc_api-rpc-glue/src/loc_api_log.c | 344 + .../src/loc_api_rpc_glue.c | 621 ++ .../src/loc_api_sync_call.c | 510 ++ .../src/loc_apicb_appinit.c | 86 + .../libloc_api-rpc-stub/Android.mk | 35 + .../inc/loc_api_rpcgen_cb_rpc.h | 156 + .../inc/loc_api_rpcgen_common_rpc.h | 1261 ++++ .../inc/loc_api_rpcgen_rpc.h | 288 + .../inc/loc_apicb_appinit.h | 34 + .../src/loc_api_rpcgen_cb_svc.c | 327 + .../src/loc_api_rpcgen_cb_xdr.c | 60 + .../src/loc_api_rpcgen_clnt.c | 155 + .../src/loc_api_rpcgen_common_xdr.c | 1775 +++++ .../src/loc_api_rpcgen_xdr.c | 199 + .../src/loc_apicb_appinit.c | 74 + .../libloc_api-rpc-stub/xdr/loc_api.xdr | 261 + .../libloc_api-rpc-stub/xdr/loc_api_cb.xdr | 187 + .../xdr/loc_api_common.xdr | 1021 +++ loc_api/libloc_api-rpc/Android.mk | 11 +- loc_api/libloc_api-rpc/gen-1240/Makefile.xdr | 9 - .../gen-1240/loc_api_rpc_glue.c | 18 +- loc_api/libloc_api-rpc/gen-3200/Makefile.xdr | 9 - .../gen-3200/loc_api_rpc_glue.c | 18 +- loc_api/libloc_api-rpc/inc/debug.h | 6 +- loc_api/libloc_api/Android.mk | 12 +- loc_api/libloc_api/gps.c | 56 +- loc_api/libloc_api/loc_eng.cpp | 154 +- loc_api/libloc_api/loc_eng.h | 60 +- loc_api/libloc_api/loc_eng_ioctl.cpp | 84 +- loc_api/libloc_api/loc_eng_ioctl.h | 62 +- loc_api/libloc_api/loc_eng_ni.cpp | 102 +- loc_api/libloc_api/loc_eng_ni.h | 55 +- loc_api/libloc_api/loc_eng_xtra.cpp | 73 +- loc_api/libloc_api/loc_eng_xtra.h | 60 +- loc_api/libloc_api_50001/Android.mk | 131 + loc_api/libloc_api_50001/LocApiAdapter.cpp | 196 + loc_api/libloc_api_50001/LocApiAdapter.h | 205 + loc_api/libloc_api_50001/gps.c | 68 + loc_api/libloc_api_50001/loc.cpp | 870 +++ loc_api/libloc_api_50001/loc.h | 86 + loc_api/libloc_api_50001/loc_eng.cpp | 1838 +++++ loc_api/libloc_api_50001/loc_eng.h | 204 + loc_api/libloc_api_50001/loc_eng_agps.cpp | 702 ++ loc_api/libloc_api_50001/loc_eng_agps.h | 274 + loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp | 180 + loc_api/libloc_api_50001/loc_eng_dmn_conn.h | 53 + .../loc_eng_dmn_conn_glue_msg.c | 223 + .../loc_eng_dmn_conn_glue_msg.h | 51 + .../loc_eng_dmn_conn_glue_pipe.c | 206 + .../loc_eng_dmn_conn_glue_pipe.h | 50 + .../loc_eng_dmn_conn_handler.cpp | 78 + .../loc_eng_dmn_conn_handler.h | 82 + .../loc_eng_dmn_conn_thread_helper.c | 398 ++ .../loc_eng_dmn_conn_thread_helper.h | 74 + loc_api/libloc_api_50001/loc_eng_log.cpp | 292 + loc_api/libloc_api_50001/loc_eng_log.h | 62 + loc_api/libloc_api_50001/loc_eng_msg.cpp | 133 + loc_api/libloc_api_50001/loc_eng_msg.h | 584 ++ loc_api/libloc_api_50001/loc_eng_msg_id.h | 90 + loc_api/libloc_api_50001/loc_eng_ni.cpp | 313 + loc_api/libloc_api_50001/loc_eng_ni.h | 50 + loc_api/libloc_api_50001/loc_eng_xtra.cpp | 90 + loc_api/libloc_api_50001/loc_eng_xtra.h | 46 + loc_api/loc_api_v02/Android.mk | 43 + loc_api/loc_api_v02/LocApiV02Adapter.cpp | 2056 ++++++ loc_api/loc_api_v02/LocApiV02Adapter.h | 197 + loc_api/loc_api_v02/loc_api_sync_req.c | 548 ++ loc_api/loc_api_v02/loc_api_sync_req.h | 68 + loc_api/loc_api_v02/loc_api_v02_client.c | 1867 ++++++ loc_api/loc_api_v02/loc_api_v02_client.h | 1255 ++++ loc_api/loc_api_v02/loc_api_v02_log.c | 243 + loc_api/loc_api_v02/loc_api_v02_log.h | 50 + loc_api/loc_api_v02/loc_util_log.h | 81 + loc_api/loc_api_v02/location_service_v02.c | 2223 +++++++ loc_api/loc_api_v02/location_service_v02.h | 5914 +++++++++++++++++ loc_api/ulp/inc/ulp.h | 76 + utils/Android.mk | 45 + utils/linked_list.c | 328 + utils/linked_list.h | 217 + utils/loc_cfg.cpp | 272 + utils/loc_cfg.h | 98 + utils/loc_log.cpp | 183 + utils/loc_log.h | 66 + utils/log_util.h | 151 + utils/msg_q.c | 322 + utils/msg_q.h | 189 + 98 files changed, 33961 insertions(+), 422 deletions(-) create mode 100755 loc_api/libloc_api-rpc-50001/Android.mk create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr create mode 100755 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr create mode 100755 loc_api/libloc_api_50001/Android.mk create mode 100755 loc_api/libloc_api_50001/LocApiAdapter.cpp create mode 100755 loc_api/libloc_api_50001/LocApiAdapter.h create mode 100755 loc_api/libloc_api_50001/gps.c create mode 100755 loc_api/libloc_api_50001/loc.cpp create mode 100755 loc_api/libloc_api_50001/loc.h create mode 100755 loc_api/libloc_api_50001/loc_eng.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng.h create mode 100755 loc_api/libloc_api_50001/loc_eng_agps.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_agps.h create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn.h create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c create mode 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h create mode 100755 loc_api/libloc_api_50001/loc_eng_log.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_log.h create mode 100755 loc_api/libloc_api_50001/loc_eng_msg.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_msg.h create mode 100755 loc_api/libloc_api_50001/loc_eng_msg_id.h create mode 100755 loc_api/libloc_api_50001/loc_eng_ni.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_ni.h create mode 100755 loc_api/libloc_api_50001/loc_eng_xtra.cpp create mode 100755 loc_api/libloc_api_50001/loc_eng_xtra.h create mode 100755 loc_api/loc_api_v02/Android.mk create mode 100755 loc_api/loc_api_v02/LocApiV02Adapter.cpp create mode 100755 loc_api/loc_api_v02/LocApiV02Adapter.h create mode 100755 loc_api/loc_api_v02/loc_api_sync_req.c create mode 100755 loc_api/loc_api_v02/loc_api_sync_req.h create mode 100755 loc_api/loc_api_v02/loc_api_v02_client.c create mode 100755 loc_api/loc_api_v02/loc_api_v02_client.h create mode 100755 loc_api/loc_api_v02/loc_api_v02_log.c create mode 100755 loc_api/loc_api_v02/loc_api_v02_log.h create mode 100755 loc_api/loc_api_v02/loc_util_log.h create mode 100755 loc_api/loc_api_v02/location_service_v02.c create mode 100755 loc_api/loc_api_v02/location_service_v02.h create mode 100755 loc_api/ulp/inc/ulp.h create mode 100755 utils/Android.mk create mode 100755 utils/linked_list.c create mode 100755 utils/linked_list.h create mode 100755 utils/loc_cfg.cpp create mode 100755 utils/loc_cfg.h create mode 100755 utils/loc_log.cpp create mode 100755 utils/loc_log.h create mode 100755 utils/log_util.h create mode 100755 utils/msg_q.c create mode 100755 utils/msg_q.h diff --git a/loc_api/Android.mk b/loc_api/Android.mk index 52942bfe..7e09d5f9 100755 --- a/loc_api/Android.mk +++ b/loc_api/Android.mk @@ -7,5 +7,27 @@ # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) -include $(call all-subdir-makefiles) -endif + +LOCAL_PATH := $(call my-dir) + +GPS_DIR_LIST := + +# add RPC dirs if RPC is available +ifneq ($(TARGET_NO_RPC),true) + +GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api-rpc-50001/ +GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api-rpc/ +GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api/ + +else + +GPS_DIR_LIST += $(LOCAL_PATH)/loc_api_v02/ + +endif #TARGET_NO_RPC + +GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api_50001/ + +#call the subfolders +include $(addsuffix Android.mk, $(GPS_DIR_LIST)) + +endif#BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE diff --git a/loc_api/libloc_api-rpc-50001/Android.mk b/loc_api/libloc_api-rpc-50001/Android.mk new file mode 100755 index 00000000..6c5d5339 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/Android.mk @@ -0,0 +1,3 @@ +ifeq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_AMSS_VERSION),50001) +include $(call all-subdir-makefiles) +endif diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk new file mode 100755 index 00000000..1287c69e --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk @@ -0,0 +1,59 @@ +LOCAL_PATH:= $(call my-dir) +include $(CLEAR_VARS) + +RPC_INC:=rpc_inc + +source_files:= \ + src/loc_api_rpc_glue.c \ + src/loc_api_sync_call.c \ + src/loc_apicb_appinit.c \ + src/loc_api_fixup.c \ + src/loc_api_log.c \ + src/LocApiRpcAdapter.cpp + +LOCAL_SRC_FILES:= $(source_files) + +LOCAL_CFLAGS:=-fno-short-enums +LOCAL_CFLAGS+=-DDEBUG -DUSE_QCOM_AUTO_RPC -DUSE_QCOM_AUTO_RPC +LOCAL_CFLAGS+=$(GPS_FEATURES) + +# for loc_api_fixup.c +LOCAL_CFLAGS+=-DADD_XDR_FLOAT -DADD_XDR_BOOL + +LOCAL_SHARED_LIBRARIES:= \ + librpc \ + libutils \ + libcutils \ + libcommondefs \ + libgps.utils \ + libloc_adapter + +LOCAL_STATIC_LIBRARIES := \ + libloc_api_rpcgen + +LOCAL_PRELINK_MODULE:= false + +LOCAL_C_INCLUDES:= \ + $(LOCAL_PATH) \ + $(LOCAL_PATH)/rpc_inc \ + $(TARGET_OUT_HEADERS)/gps.utils \ + $(TARGET_OUT_HEADERS)/loc_api/rpcgen/inc \ + $(TARGET_OUT_HEADERS)/libcommondefs-rpc \ + $(TARGET_OUT_HEADERS)/libcommondefs/rpcgen/inc \ + $(TARGET_OUT_HEADERS)/librpc \ + $(TARGET_OUT_HEADERS)/libloc-rpc/rpc_inc \ + $(TARGET_OUT_HEADERS)/libloc_eng \ + hardware/msm7k/librpc + +LOCAL_COPY_HEADERS_TO:= libloc_api-rpc-qc/$(RPC_INC) +LOCAL_COPY_HEADERS:= \ + $(RPC_INC)/loc_api_rpc_glue.h \ + $(RPC_INC)/loc_api_fixup.h \ + $(RPC_INC)/loc_api_sync_call.h \ + $(RPC_INC)/loc_apicb_appinit.h + +LOCAL_MODULE:= libloc_api-rpc-qc + +LOCAL_MODULE_TAGS := optional + +include $(BUILD_SHARED_LIBRARY) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h new file mode 100755 index 00000000..7b1f59ba --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h @@ -0,0 +1,102 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_API_RPC_ADAPTER_H +#define LOC_API_RPC_ADAPTER_H + +#include +#include +#include + + +class LocApiRpcAdapter : public LocApiAdapter { + // RPC communication establishment + rpc_loc_client_handle_type client_handle; + rpc_loc_event_mask_type eMask; + + static const rpc_loc_event_mask_type locBits[]; + static rpc_loc_event_mask_type convertMask(LOC_API_ADAPTER_EVENT_MASK_T mask); + static enum loc_api_adapter_err convertErr(int rpcErr); + + void reportPosition(const rpc_loc_parsed_position_s_type *location_report_ptr); + void reportSv(const rpc_loc_gnss_info_s_type *gnss_report_ptr); + void reportStatus(const rpc_loc_status_event_s_type *status_report_ptr); + void reportNmea(const rpc_loc_nmea_report_s_type *nmea_report_ptr); + void ATLEvent(const rpc_loc_server_request_s_type *server_request_ptr); + void NIEvent(const rpc_loc_ni_event_s_type *ni_req_ptr); + int NIEventFillVerfiyType(GpsNiNotification ¬if, + rpc_loc_ni_notify_verify_e_type notif_priv); + GpsNiEncodingType convertNiEncodingType(int loc_encoding); + +public: + LocApiRpcAdapter(LocEng &locEng); + ~LocApiRpcAdapter(); + + int locEventCB(rpc_loc_client_handle_type client_handle, + rpc_loc_event_mask_type loc_event, + const rpc_loc_event_payload_u_type* loc_event_payload); + + void locRpcGlobalCB(CLIENT* clnt, enum rpc_reset_event event); + + // RPC adapter interface implementations + virtual enum loc_api_adapter_err + reinit(); + virtual enum loc_api_adapter_err + startFix(); + virtual enum loc_api_adapter_err + stopFix(); + virtual enum loc_api_adapter_err + setPositionMode(LocPositionMode mode, GpsPositionRecurrence recurrence, + uint32_t min_interval, uint32_t preferred_accuracy, uint32_t preferred_time); + virtual enum loc_api_adapter_err + enableData(int enable); + virtual enum loc_api_adapter_err + setTime(GpsUtcTime time, int64_t timeReference, int uncertainty); + virtual enum loc_api_adapter_err + injectPosition(double latitude, double longitude, float accuracy); + virtual enum loc_api_adapter_err + deleteAidingData(GpsAidingData f); + virtual enum loc_api_adapter_err + informNiResponse(GpsUserResponseType userResponse, const void* passThroughData); + virtual enum loc_api_adapter_err + setAPN(char* apn, int len); + virtual enum loc_api_adapter_err + setServer(const char* url, int len); + virtual enum loc_api_adapter_err + setServer(unsigned int ip, int port, LocServerType type); + virtual enum loc_api_adapter_err + setXtraData(char* data, int length); + virtual enum loc_api_adapter_err + atlOpenStatus(int handle, int is_succ, char* apn, AGpsBearerType bear, AGpsType agpsType); + virtual enum loc_api_adapter_err + atlCloseStatus(int handle, int is_succ); + virtual enum loc_api_adapter_err + setSUPLVersion(uint32_t version); +}; + +#endif //LOC_API_RPC_ADAPTER_H diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h new file mode 100755 index 00000000..8b20a3f5 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h @@ -0,0 +1,69 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef DEBUG_H +#define DEBUG_H + +#include + +#define LOG_TAG "LocSvc_rpc" +#include + +#define PRINT(x...) do { \ + fprintf(stdout, "%s(%d) ", __FUNCTION__, __LINE__); \ + fprintf(stdout, ##x); \ + LOGD(x); \ + } while(0) + +#ifdef DEBUG +#define D PRINT +#else +#define D(x...) do { } while(0) +#endif + +#ifdef VERBOSE +#define V PRINT +#else +#define V(x...) do { } while(0) +#endif + +#define E(x...) do { \ + fprintf(stderr, "%s(%d) ", __FUNCTION__, __LINE__); \ + fprintf(stderr, ##x); \ + LOGE(x); \ + } while(0) + +#define FAILIF(cond, msg...) do { \ + if (__builtin_expect (cond, 0)) { \ + fprintf(stderr, "%s:%s:(%d): ", __FILE__, __FUNCTION__, __LINE__); \ + fprintf(stderr, ##msg); \ + LOGE(##msg); \ + } \ + } while(0) + +#endif/*DEBUG_H*/ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h new file mode 100755 index 00000000..9bfe5f0c --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h @@ -0,0 +1,226 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_API_FIXUP_H +#define LOC_API_FIXUP_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#ifndef NULLPROC +#define NULLPROC 0 +#endif /* NULLPROC */ + +#ifdef ADD_XDR_FLOAT + +extern bool_t xdr_float (XDR *__xdrs, float *__fp); +extern bool_t xdr_double (XDR *__xdrs, double *__dp); + +#endif /* ADD_XDR_FLOAT */ + +#ifdef ADD_XDR_BOOL +extern bool_t xdr_bool(XDR *__xdrs, int *__bp); +#endif /* ADD_XDR_BOOL */ + +#define RPC_LOC_API_MAJOR_VERSION_NUMBER 1 +#define RPC_LOC_API_MINOR_VERSION_NUMBER 0 + +// Return value for loc_open in case of failure. +#define RPC_LOC_CLIENT_HANDLE_INVALID -1 + +// Return value of loc api calls for loc_close, loc_start_fix, loc_stop_fix and loc_ioctl +// These are also the status for the ioctl callback +#define RPC_LOC_API_SUCCESS 0 +#define RPC_LOC_API_GENERAL_FAILURE 1 +#define RPC_LOC_API_UNSUPPORTED 2 +#define RPC_LOC_API_INVALID_HANDLE 4 +#define RPC_LOC_API_INVALID_PARAMETER 5 +#define RPC_LOC_API_ENGINE_BUSY 6 +#define RPC_LOC_API_PHONE_OFFLINE 7 +#define RPC_LOC_API_TIMEOUT 8 + +// Special return value for loc api calls in case of RPC failure +#define RPC_LOC_API_RPC_FAILURE (-1234) +// Special return value for modem restart incurred RPC failure +#define RPC_LOC_API_RPC_MODEM_RESTART (-1235) + +#define RPC_LOC_API_MAX_SV_COUNT 80 +#define RPC_LOC_API_MAX_NMEA_STRING_LENGTH 1200 + +// Maximum server address that will be used in location API +#define RPC_LOC_API_MAX_SERVER_ADDR_LENGTH 256 +#define RPC_LOC_API_MAX_NUM_PREDICTED_ORBITS_SERVERS 3 +#define RPC_LOC_API_MAX_NUM_NTP_SERVERS 3 + +#define RPC_LOC_EVENT_PARSED_POSITION_REPORT 0x00000001 // Position report comes in loc_parsed_position_s_type +#define RPC_LOC_EVENT_SATELLITE_REPORT 0x00000002 // Satellite in view report +#define RPC_LOC_EVENT_NMEA_1HZ_REPORT 0x00000004 // NMEA report at 1HZ rate +#define RPC_LOC_EVENT_NMEA_POSITION_REPORT 0x00000008 // NMEA report at position report rate +#define RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST 0x00000010 // NI notification/verification request +#define RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST 0x00000020 // Assistance data, eg: time, predicted orbits request +#define RPC_LOC_EVENT_LOCATION_SERVER_REQUEST 0x00000040 // Request for location server +#define RPC_LOC_EVENT_IOCTL_REPORT 0x00000080 // Callback report for loc_ioctl +#define RPC_LOC_EVENT_STATUS_REPORT 0x00000100 // Misc status report: eg, engine state + +#define RPC_LOC_POS_VALID_SESSION_STATUS 0x00000001 +#define RPC_LOC_POS_VALID_TIMESTAMP_CALENDAR 0x00000002 +#define RPC_LOC_POS_VALID_TIMESTAMP_UTC 0x00000004 +#define RPC_LOC_POS_VALID_LEAP_SECONDS 0x00000008 +#define RPC_LOC_POS_VALID_TIME_UNC 0x00000010 +#define RPC_LOC_POS_VALID_LATITUDE 0x00000020 +#define RPC_LOC_POS_VALID_LONGITUDE 0x00000040 +#define RPC_LOC_POS_VALID_ALTITUDE_WRT_ELLIPSOID 0x00000080 +#define RPC_LOC_POS_VALID_ALTITUDE_WRT_MEAN_SEA_LEVEL 0x00000100 +#define RPC_LOC_POS_VALID_SPEED_HORIZONTAL 0x00000200 +#define RPC_LOC_POS_VALID_SPEED_VERTICAL 0x00000400 +#define RPC_LOC_POS_VALID_HEADING 0x00000800 +#define RPC_LOC_POS_VALID_HOR_UNC_CIRCULAR 0x00001000 +#define RPC_LOC_POS_VALID_HOR_UNC_ELLI_SEMI_MAJ 0x00002000 +#define RPC_LOC_POS_VALID_HOR_UNC_ELLI_SEMI_MIN 0x00004000 +#define RPC_LOC_POS_VALID_HOR_UNC_ELLI_ORIENT_AZIMUTH 0x00008000 +#define RPC_LOC_POS_VALID_VERTICAL_UNC 0x00010000 +#define RPC_LOC_POS_VALID_SPEED_UNC 0x00020000 +#define RPC_LOC_POS_VALID_HEADING_UNC 0x00040000 +#define RPC_LOC_POS_VALID_CONFIDENCE_HORIZONTAL 0x00080000 +#define RPC_LOC_POS_VALID_CONFIDENCE_VERTICAL 0x00100000 +#define RPC_LOC_POS_VALID_MAGNETIC_VARIATION 0x00200000 +#define RPC_LOC_POS_VALID_TECHNOLOGY_MASK 0x00400000 + +#define RPC_LOC_POS_TECH_SATELLITE 0x00000001 +#define RPC_LOC_POS_TECH_CELLID 0x00000002 +#define RPC_LOC_POS_TECH_WIFI 0x00000004 + +#define RPC_LOC_SV_INFO_VALID_SYSTEM 0x00000001 +#define RPC_LOC_SV_INFO_VALID_PRN 0x00000002 +#define RPC_LOC_SV_INFO_VALID_HEALTH_STATUS 0x00000004 +#define RPC_LOC_SV_INFO_VALID_PROCESS_STATUS 0x00000008 +#define RPC_LOC_SV_INFO_VALID_HAS_EPH 0x00000010 +#define RPC_LOC_SV_INFO_VALID_HAS_ALM 0x00000020 +#define RPC_LOC_SV_INFO_VALID_ELEVATION 0x00000040 +#define RPC_LOC_SV_INFO_VALID_AZIMUTH 0x00000080 +#define RPC_LOC_SV_INFO_VALID_SNR 0x00000100 + +#define RPC_LOC_GNSS_INFO_VALID_POS_DOP 0x00000001 +#define RPC_LOC_GNSS_INFO_VALID_HOR_DOP 0x00000002 +#define RPC_LOC_GNSS_INFO_VALID_VERT_DOP 0x00000004 +#define RPC_LOC_GNSS_INFO_VALID_ALTITUDE_ASSUMED 0x00000008 +#define RPC_LOC_GNSS_INFO_VALID_SV_COUNT 0x00000010 +#define RPC_LOC_GNSS_INFO_VALID_SV_LIST 0x00000020 + +#define RPC_LOC_NI_MAX_REQUESTOR_ID_LENGTH 200 +#define RPC_LOC_NI_SUPL_HASH_LENGTH 8 +#define RPC_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH 4 +#define RPC_LOC_NI_MAX_CLIENT_NAME_LENGTH 64 +#define RPC_LOC_NI_MAX_EXT_CLIENT_ADDRESS 20 +#define RPC_LOC_NI_CODEWORD_LENGTH 20 + +#define RPC_LOC_NI_SUPL_QOP_VALID 0x01 +#define RPC_LOC_NI_SUPL_QOP_VERACC_VALID 0x02 +#define RPC_LOC_NI_SUPL_QOP_MAXAGE_VALID 0x04 +#define RPC_LOC_NI_SUPL_QOP_DELAY_VALID 0x08 + +#define RPC_LOC_FIX_CRIT_VALID_RECURRENCE_TYPE 0x00000001 +#define RPC_LOC_FIX_CRIT_VALID_PREFERRED_OPERATION_MODE 0x00000002 +#define RPC_LOC_FIX_CRIT_VALID_PREFERRED_ACCURACY 0x00000004 +#define RPC_LOC_FIX_CRIT_VALID_PREFERRED_RESPONSE_TIME 0x00000008 +#define RPC_LOC_FIX_CRIT_VALID_INTERMEDIATE_POS_REPORT_ENABLED 0x00000010 +#define RPC_LOC_FIX_CRIT_VALID_NOTIFY_TYPE 0x00000020 +#define RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL 0x00000040 +#define RPC_LOC_FIX_CRIT_VALID_MIN_DISTANCE 0x00000080 +#define RPC_LOC_FIX_CRIT_VALID_MIN_DIST_SAMPLE_INTERVAL 0x00000100 + +#define RPC_LOC_ASSIST_POS_VALID_TIMESTAMP_UTC 0x00000001 +#define RPC_LOC_ASSIST_POS_VALID_LATITUDE 0x00000002 +#define RPC_LOC_ASSIST_POS_VALID_LONGITUDE 0x00000004 +#define RPC_LOC_ASSIST_POS_VALID_ALTITUDE_WRT_ELLIPSOID 0x00000008 +#define RPC_LOC_ASSIST_POS_VALID_ALTITUDE_WRT_MEAN_SEA_LEVEL 0x00000010 +#define RPC_LOC_ASSIST_POS_VALID_HOR_UNC_CIRCULAR 0x00000020 +#define RPC_LOC_ASSIST_POS_VALID_VERT_UNC 0x00000040 +#define RPC_LOC_ASSIST_POS_VALID_CONFIDENCE_HORIZONTAL 0x00000080 +#define RPC_LOC_ASSIST_POS_VALID_CONFIDENCE_VERTICAL 0x00000100 +#define RPC_LOC_ASSIST_POS_VALID_TIMESTAMP_AGE 0x00000200 + +#define RPC_LOC_ASSIST_DATA_ALL 0xFFFFFFFF + +#define RPC_LOC_NMEA_MASK_ALL 0xffff +#define RPC_LOC_NMEA_MASK_GGA 0x0001 +#define RPC_LOC_NMEA_MASK_RMC 0x0002 +#define RPC_LOC_NMEA_MASK_GSV 0x0004 +#define RPC_LOC_NMEA_MASK_GSA 0x0008 +#define RPC_LOC_NMEA_MASK_VTG 0x0010 + +/* EFS data access */ +#define RPC_LOC_EFS_MAX_PATH_LEN_BYTES 64 /* Max file name length in bytes that can be written*/ +#define RPC_LOC_EFS_MAX_FILE_LEN_BYTES 2000 /* Max file size in bytes that can be written */ + +/* WIPER valid information flag in log report */ +#define RPC_LOC_WIPER_LOG_TIME_VALID 0x01 +#define RPC_LOC_WIPER_LOG_POS_VALID 0x02 +#define RPC_LOC_WIPER_LOG_AP_SET_VALID 0x04 + +/* General WIPER defines */ +#define RPC_LOC_WIPER_MAC_ADDR_LENGTH 6 // Do not change this number since it affects RPC and log packet sizes +#define RPC_LOC_WIPER_MAX_REPORTED_APS_PER_LOG_MSG 50 // Do not change this number since it affects RPC and log packet sizes + +/* WIPER AP Qualifier */ +#define RPC_LOC_WIPER_AP_QUALIFIER_BEING_USED 0x1 /* AP is being used by WPS */ +#define RPC_LOC_WIPER_AP_QUALIFIER_HIDDEN_SSID 0x2 /* AP does not broadcast SSID */ +#define RPC_LOC_WIPER_AP_QUALIFIER_PRIVATE 0x4 /* AP has encryption turned on */ +#define RPC_LOC_WIPER_AP_QUALIFIER_INFRASTRUCTURE_MODE 0x8 /* AP is in infrastructure mode and not in ad-hoc/unknown mode */ + +/* flags for notification */ +#define RPC_LOC_NI_CLIENT_NAME_PRESENT 0x0001 +#define RPC_LOC_NI_CLIENT_EXTADDR_PRESENT 0x0002 +#define RPC_LOC_NI_DEF_LOCATION_TYPE_PRESENT 0x0010 +#define RPC_LOC_NI_REQUESTOR_ID_PRESENT 0x0020 +#define RPC_LOC_NI_CODEWORD_PRESENT 0x0040 +#define RPC_LOC_NI_SERVICE_TYPE_ID_PRESENT 0x0080 +#define RPC_LOC_NI_ENCODING_TYPE_PRESENT 0x0100 + +/* below are for RPC_LOC_IOCTL_SET_LBS_APN_PROFILE data */ +/* values for apn_profiles[0].srv_system_type */ +#define LOC_APN_PROFILE_SRV_SYS_CDMA 0x01 +#define LOC_APN_PROFILE_SRV_SYS_HDR 0x02 +#define LOC_APN_PROFILE_SRV_SYS_GSM 0x04 +#define LOC_APN_PROFILE_SRV_SYS_WCDMA 0x08 +#define LOC_APN_PROFILE_SRV_SYS_LTE 0x10 +#define LOC_APN_PROFILE_SRV_SYS_MAX 0x1F +/* values for apn_profiles[0].pdp_type */ +#define LOC_APN_PROFILE_PDN_TYPE_IPV4 0x01 +#define LOC_APN_PROFILE_PDN_TYPE_IPV6 0x02 +#define LOC_APN_PROFILE_PDN_TYPE_IPV4V6 0x03 +#define LOC_APN_PROFILE_PDN_TYPE_PPP 0x04 +#define LOC_APN_PROFILE_PDN_TYPE_MAX 0x04 + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_FIXUP_H */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h new file mode 100755 index 00000000..c0bcda16 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h @@ -0,0 +1,59 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_API_LOG_H +#define LOC_API_LOG_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#include +#include "loc_api_rpcgen_common_rpc.h" + +extern int loc_callback_log( + rpc_loc_event_mask_type loc_event, /* event mask */ + const rpc_loc_event_payload_u_type* loc_event_payload /* payload */ +); + +extern const char* loc_get_event_atl_open_name(rpc_loc_server_request_e_type loc_event_atl_open); +extern const char* loc_get_event_name(rpc_loc_event_mask_type loc_event_mask); +extern const char* loc_get_ioctl_type_name(rpc_loc_ioctl_e_type ioctl_type); +extern const char* loc_get_ioctl_status_name(uint32 status); +extern const char* loc_get_sess_status_name(rpc_loc_session_status_e_type status); +extern const char* loc_get_engine_state_name(rpc_loc_engine_state_e_type state); +extern const char* loc_get_fix_session_state_name(rpc_loc_fix_session_state_e_type state); +extern const char* loc_get_rpc_reset_event_name(enum rpc_reset_event event); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_LOG_H */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h new file mode 100755 index 00000000..16552a0c --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h @@ -0,0 +1,123 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_API_RPC_GLUE_H +#define LOC_API_RPC_GLUE_H + +/* Include RPC headers */ +#ifdef USE_LOCAL_RPC +#include "rpc_inc/loc_api_common.h" +#include "rpc_inc/loc_api.h" +#include "rpc_inc/loc_api_cb.h" +#endif + +#ifdef USE_QCOM_AUTO_RPC +#include "loc_api_rpcgen_rpc.h" +#include "loc_api_rpcgen_common_rpc.h" +#include "loc_api_rpcgen_cb_rpc.h" +#endif + +/* Boolean */ +/* Other data types in comdef.h are defined in rpc stubs, so fix it here */ +typedef unsigned char boolean; +#define TRUE 1 +#define FALSE 0 + +#include "rpc_inc/loc_api_fixup.h" +#include "rpc_inc/loc_api_sync_call.h" +#include + +#ifdef __cplusplus +extern "C" +{ +#endif + +extern int loc_api_glue_init(void); +extern int loc_api_null(void); + +typedef int32 (loc_event_cb_f_type)( + void* userData, + rpc_loc_client_handle_type loc_handle, /* handle of the client */ + rpc_loc_event_mask_type loc_event, /* event mask */ + const rpc_loc_event_payload_u_type* loc_event_payload /* payload */ +); + +typedef void (loc_reset_notif_cb_f_type)( + void* userData, + CLIENT* clnt, + enum rpc_reset_event event +); + +extern rpc_loc_client_handle_type loc_open( + rpc_loc_event_mask_type event_reg_mask, + loc_event_cb_f_type *event_callback, + loc_reset_notif_cb_f_type *rpc_global_cb, + void* userData +); + +extern int32 loc_close +( + rpc_loc_client_handle_type handle +); + +extern void loc_clear +( + rpc_loc_client_handle_type handle +); + +extern int32 loc_start_fix +( + rpc_loc_client_handle_type handle +); + +extern int32 loc_stop_fix +( + rpc_loc_client_handle_type handle +); + +extern int32 loc_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data +); + +extern int loc_eng_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data_ptr, + uint32 timeout_msec, + rpc_loc_ioctl_callback_s_type *cb_data_ptr +); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_RPC_GLUE_H */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h new file mode 100755 index 00000000..266f8ec8 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h @@ -0,0 +1,90 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_API_CB_SYNC_H +#define LOC_API_CB_SYNC_H + +#ifdef __cplusplus +extern "C" +{ +#endif +#include "loc_api_rpc_glue.h" +#define LOC_SYNC_CALL_SLOTS_MAX 8 + +typedef struct { + pthread_mutex_t lock; + + /* Client ID */ + rpc_loc_client_handle_type loc_handle; + + /* Callback waiting conditional variable */ + pthread_cond_t loc_cb_arrived_cond; + + /* Callback waiting data block, protected by loc_cb_data_mutex */ + boolean in_use; + boolean signal_sent; + boolean not_available; + rpc_loc_event_mask_type loc_cb_wait_event_mask; /* event to wait for */ + rpc_loc_ioctl_e_type ioctl_type; /* ioctl to wait for */ + rpc_loc_event_payload_u_type loc_cb_received_payload; /* received payload */ + rpc_loc_event_mask_type loc_cb_received_event_mask; /* received event */ +} loc_sync_call_slot_s_type; + +typedef struct { + int num_of_slots; + loc_sync_call_slot_s_type slots[LOC_SYNC_CALL_SLOTS_MAX]; +} loc_sync_call_slot_array_s_type; + +/* Init function */ +void loc_api_sync_call_init(); + +/* Destroy function */ +void loc_api_sync_call_destroy(); + +/* Process Loc API callbacks to wake up blocked user threads */ +void loc_api_callback_process_sync_call( + rpc_loc_client_handle_type loc_handle, /* handle of the client */ + rpc_loc_event_mask_type loc_event, /* event mask */ + const rpc_loc_event_payload_u_type* loc_event_payload /* payload */ +); + +/* Reentrant synchronous IOCTL call, using Loc API return code */ +int loc_api_sync_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data_ptr, + uint32 timeout_msec, + rpc_loc_ioctl_callback_s_type *cb_data_ptr +); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_CB_SYNC_H */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h new file mode 100755 index 00000000..8dbcb9ac --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h @@ -0,0 +1,45 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_APICB_APPINIT_H +#define LOC_APICB_APPINIT_H + +#ifdef __cplusplus +extern "C" +{ +#endif + + /* Initialization function for callbacks */ +extern int loc_apicb_app_init(); +extern void loc_apicb_app_deinit(); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_APICB_APPINIT_H */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp new file mode 100755 index 00000000..48b3a0fe --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -0,0 +1,1225 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_adapter" + +#include +#include +#include +#include "LocApiRpcAdapter.h" +#include "loc_api_rpcgen_common_rpc.h" +#include "log_util.h" +#include "loc_log.h" +#include "loc_api_log.h" + +#define LOC_XTRA_INJECT_DEFAULT_TIMEOUT (3100) +#define XTRA_BLOCK_SIZE (3072) +#define LOC_IOCTL_DEFAULT_TIMEOUT 1000 // 1000 milli-seconds +#define LOC_NI_NOTIF_KEY_ADDRESS "Address" + +/*=========================================================================== +FUNCTION loc_event_cb + +DESCRIPTION + This is the callback function registered by loc_open. + +DEPENDENCIES + N/A + +RETURN VALUE + RPC_LOC_API_SUCCESS + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int32 loc_event_cb +( + void* user, + rpc_loc_client_handle_type client_handle, + rpc_loc_event_mask_type loc_event, + const rpc_loc_event_payload_u_type* loc_event_payload +) +{ + MODEM_LOG_CALLFLOW(%s, loc_get_event_name(loc_event)); + loc_callback_log(loc_event, loc_event_payload); + int32 ret_val = ((LocApiRpcAdapter*)user)->locEventCB(client_handle, loc_event, loc_event_payload); + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_rpc_global_cb + +DESCRIPTION + This is the callback function registered by loc_open for RPC global events + +DEPENDENCIES + N/A + +RETURN VALUE + RPC_LOC_API_SUCCESS + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_rpc_global_cb(void* user, CLIENT* clnt, enum rpc_reset_event event) +{ + MODEM_LOG_CALLFLOW(%s, loc_get_rpc_reset_event_name(event)); + ((LocApiRpcAdapter*)user)->locRpcGlobalCB(clnt, event); + EXIT_LOG(%p, VOID_RET); +} + + +LocApiAdapter* getLocApiAdapter(LocEng &locEng) +{ + return new LocApiRpcAdapter(locEng); +} + +const rpc_loc_event_mask_type LocApiRpcAdapter::locBits[] = +{ + RPC_LOC_EVENT_PARSED_POSITION_REPORT, + RPC_LOC_EVENT_SATELLITE_REPORT, + RPC_LOC_EVENT_NMEA_1HZ_REPORT, + RPC_LOC_EVENT_NMEA_POSITION_REPORT, + RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST, + RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST, + RPC_LOC_EVENT_LOCATION_SERVER_REQUEST, + RPC_LOC_EVENT_IOCTL_REPORT, + RPC_LOC_EVENT_STATUS_REPORT +}; + +LocApiRpcAdapter::LocApiRpcAdapter(LocEng &locEng) : + LocApiAdapter(locEng), + client_handle(RPC_LOC_CLIENT_HANDLE_INVALID), + eMask(convertMask(locEng.eventMask)) +{ + loc_api_glue_init(); +} + +LocApiRpcAdapter::~LocApiRpcAdapter() +{ + if (RPC_LOC_CLIENT_HANDLE_INVALID != client_handle) { + loc_clear(client_handle); + } + + loc_close(client_handle); +} + +rpc_loc_event_mask_type +LocApiRpcAdapter::convertMask(LOC_API_ADAPTER_EVENT_MASK_T mask) +{ + rpc_loc_event_mask_type newMask = 0; + + for (unsigned int i = 0, bit=1; 0 != mask; i++, bit<<=1) { + if (mask & bit) { + newMask |= locBits[i]; + mask ^= bit; + } + } + + return newMask; +} + +enum loc_api_adapter_err +LocApiRpcAdapter::convertErr(int rpcErr) +{ + switch(rpcErr) + { + case RPC_LOC_API_SUCCESS: + return LOC_API_ADAPTER_ERR_SUCCESS; + case RPC_LOC_API_GENERAL_FAILURE: + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + case RPC_LOC_API_UNSUPPORTED: + return LOC_API_ADAPTER_ERR_UNSUPPORTED; + case RPC_LOC_API_INVALID_HANDLE: + return LOC_API_ADAPTER_ERR_INVALID_HANDLE; + case RPC_LOC_API_INVALID_PARAMETER: + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + case RPC_LOC_API_ENGINE_BUSY: + return LOC_API_ADAPTER_ERR_ENGINE_BUSY; + case RPC_LOC_API_PHONE_OFFLINE: + return LOC_API_ADAPTER_ERR_PHONE_OFFLINE; + case RPC_LOC_API_TIMEOUT: + return LOC_API_ADAPTER_ERR_TIMEOUT; + case RPC_LOC_API_RPC_MODEM_RESTART: + return LOC_API_ADAPTER_ERR_ENGINE_DOWN; + case RPC_LOC_API_RPC_FAILURE: + return LOC_API_ADAPTER_ERR_FAILURE; + default: + return LOC_API_ADAPTER_ERR_UNKNOWN; + } +} + +void LocApiRpcAdapter::locRpcGlobalCB(CLIENT* clnt, enum rpc_reset_event event) +{ + static rpc_loc_engine_state_e_type last_state = RPC_LOC_ENGINE_STATE_MAX; + + switch (event) { + case RPC_SUBSYSTEM_RESTART_BEGIN: + if (RPC_LOC_ENGINE_STATE_OFF != last_state) { + last_state = RPC_LOC_ENGINE_STATE_OFF; + handleEngineDownEvent(); + } + break; + case RPC_SUBSYSTEM_RESTART_END: + if (RPC_LOC_ENGINE_STATE_ON != last_state) { + last_state = RPC_LOC_ENGINE_STATE_ON; + handleEngineUpEvent(); + } + break; + } +} + +int32 LocApiRpcAdapter::locEventCB(rpc_loc_client_handle_type client_handle, + rpc_loc_event_mask_type loc_event, + const rpc_loc_event_payload_u_type* loc_event_payload) +{ + locEngHandle.acquireWakelock(); + + // Parsed report + if (loc_event & RPC_LOC_EVENT_PARSED_POSITION_REPORT) + { + reportPosition(&loc_event_payload->rpc_loc_event_payload_u_type_u. + parsed_location_report); + } + + // Satellite report + if (loc_event & RPC_LOC_EVENT_SATELLITE_REPORT) + { + reportSv(&loc_event_payload->rpc_loc_event_payload_u_type_u.gnss_report); + } + + // Status report + if (loc_event & RPC_LOC_EVENT_STATUS_REPORT) + { + reportStatus(&loc_event_payload->rpc_loc_event_payload_u_type_u.status_report); + } + + // NMEA + if (loc_event & RPC_LOC_EVENT_NMEA_1HZ_REPORT) + { + reportNmea(&(loc_event_payload->rpc_loc_event_payload_u_type_u.nmea_report)); + } + // XTRA support: supports only XTRA download + if (loc_event & RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST) + { + if (loc_event_payload->rpc_loc_event_payload_u_type_u.assist_data_request.event == + RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ) + { + requestXtraData(); + } else if (loc_event_payload->rpc_loc_event_payload_u_type_u.assist_data_request.event == + RPC_LOC_ASSIST_DATA_TIME_REQ) + { + requestTime(); + } else if (loc_event_payload->rpc_loc_event_payload_u_type_u.assist_data_request.event == + RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ) + { + requestLocation(); + } + } + + // AGPS data request + if (loc_event & RPC_LOC_EVENT_LOCATION_SERVER_REQUEST) + { + ATLEvent(&loc_event_payload->rpc_loc_event_payload_u_type_u. + loc_server_request); + } + + // NI notify request + if (loc_event & RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST) + { + NIEvent(&loc_event_payload->rpc_loc_event_payload_u_type_u.ni_request); + } + + locEngHandle.releaseWakeLock(); + return RPC_LOC_API_SUCCESS;//We simply want to return sucess here as we do not want to + // cause any issues in RPC thread context +} + +enum loc_api_adapter_err +LocApiRpcAdapter::reinit() +{ + enum loc_api_adapter_err ret_val = LOC_API_ADAPTER_ERR_SUCCESS; + if (RPC_LOC_CLIENT_HANDLE_INVALID != client_handle) { + loc_clear(client_handle); + } + + client_handle = loc_open(eMask, loc_event_cb, loc_rpc_global_cb, this); + + if (client_handle < 0) { + ret_val = LOC_API_ADAPTER_ERR_INVALID_HANDLE; + } + + return ret_val; +} + +enum loc_api_adapter_err +LocApiRpcAdapter::startFix() { + LOC_LOGD("LocApiRpcAdapter::startFix() called"); + return convertErr( + loc_start_fix(client_handle) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::stopFix() { + LOC_LOGD("LocApiRpcAdapter::stopFix() called"); + return convertErr( + loc_stop_fix(client_handle) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setPositionMode(LocPositionMode mode, + GpsPositionRecurrence recurrence, uint32_t min_interval, + uint32_t preferred_accuracy, uint32_t preferred_time) +{ + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_fix_criteria_s_type *fix_criteria_ptr; + rpc_loc_ioctl_e_type ioctl_type = RPC_LOC_IOCTL_SET_FIX_CRITERIA; + rpc_loc_operation_mode_e_type op_mode; + int ret_val; + + LOGD ("loc_eng_set_position mode, client = %d, interval = %d, mode = %d\n", + (int32) client_handle, min_interval, mode); + + switch (mode) + { + case LOC_POSITION_MODE_MS_BASED: + op_mode = RPC_LOC_OPER_MODE_MSB; + break; + case LOC_POSITION_MODE_MS_ASSISTED: + op_mode = RPC_LOC_OPER_MODE_MSA; + break; + case LOC_POSITION_MODE_RESERVED_1: + op_mode = RPC_LOC_OPER_MODE_SPEED_OPTIMAL; + break; + case LOC_POSITION_MODE_RESERVED_2: + op_mode = RPC_LOC_OPER_MODE_ACCURACY_OPTIMAL; + break; + case LOC_POSITION_MODE_RESERVED_3: + op_mode = RPC_LOC_OPER_MODE_DATA_OPTIMAL; + break; + case LOC_POSITION_MODE_RESERVED_4: + op_mode = RPC_LOC_OPER_MODE_MSA; + fix_criteria_ptr->preferred_response_time = 0; + break; + default: + op_mode = RPC_LOC_OPER_MODE_STANDALONE; + } + + fix_criteria_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.fix_criteria; + fix_criteria_ptr->valid_mask = RPC_LOC_FIX_CRIT_VALID_PREFERRED_OPERATION_MODE | + RPC_LOC_FIX_CRIT_VALID_RECURRENCE_TYPE; + fix_criteria_ptr->min_interval = min_interval; + fix_criteria_ptr->preferred_operation_mode = op_mode; + + if (min_interval > 0) { + fix_criteria_ptr->min_interval = min_interval; + fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL; + }else if(min_interval == 0) + { + /*If the framework passes in 0 transalate it into the maximum frequency we can report positions + which is 1 Hz or once very second */ + fix_criteria_ptr->min_interval = MIN_POSSIBLE_FIX_INTERVAL; + fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL; + } + if (preferred_accuracy > 0) { + fix_criteria_ptr->preferred_accuracy = preferred_accuracy; + fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_PREFERRED_ACCURACY; + } + if (preferred_time > 0) { + fix_criteria_ptr->preferred_response_time = preferred_time; + fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_PREFERRED_RESPONSE_TIME; + } + + switch (recurrence) { + case GPS_POSITION_RECURRENCE_SINGLE: + fix_criteria_ptr->recurrence_type = RPC_LOC_SINGLE_FIX; + break; + case GPS_POSITION_RECURRENCE_PERIODIC: + default: + fix_criteria_ptr->recurrence_type = RPC_LOC_PERIODIC_FIX; + break; + } + ioctl_data.disc = ioctl_type; + + ret_val = loc_eng_ioctl (client_handle, + ioctl_type, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL /* No output information is expected*/); + + return convertErr(ret_val); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setTime(GpsUtcTime time, int64_t timeReference, int uncertainty) +{ + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_assist_data_time_s_type *time_info_ptr; + rpc_loc_ioctl_e_type ioctl_type = RPC_LOC_IOCTL_INJECT_UTC_TIME; + int ret_val; + + LOC_LOGD ("loc_eng_inject_time, uncertainty = %d\n", uncertainty); + + time_info_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.assistance_data_time; + time_info_ptr->time_utc = time; + time_info_ptr->time_utc += (int64_t)(android::elapsedRealtime() - timeReference); + time_info_ptr->uncertainty = uncertainty; // Uncertainty in ms + + ioctl_data.disc = ioctl_type; + + ret_val = loc_eng_ioctl (client_handle, + ioctl_type, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL /* No output information is expected*/); + + return convertErr(ret_val); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::injectPosition(double latitude, double longitude, float accuracy) +{ + /* IOCTL data */ + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_assist_data_pos_s_type *assistance_data_position = + &ioctl_data.rpc_loc_ioctl_data_u_type_u.assistance_data_position; + int ret_val; + + /************************************************ + * Fill in latitude, longitude & accuracy + ************************************************/ + + /* This combo is required */ + assistance_data_position->valid_mask = + RPC_LOC_ASSIST_POS_VALID_LATITUDE | + RPC_LOC_ASSIST_POS_VALID_LONGITUDE | + RPC_LOC_ASSIST_POS_VALID_HOR_UNC_CIRCULAR | + RPC_LOC_ASSIST_POS_VALID_CONFIDENCE_HORIZONTAL; + + assistance_data_position->latitude = latitude; + assistance_data_position->longitude = longitude; + assistance_data_position->hor_unc_circular = accuracy; /* Meters assumed */ + assistance_data_position->confidence_horizontal = 63; /* 63% (1 std dev) assumed */ + + /* Log */ + LOC_LOGD("Inject coarse position Lat=%lf, Lon=%lf, Acc=%.2lf\n", + (double) assistance_data_position->latitude, + (double) assistance_data_position->longitude, + (double) assistance_data_position->hor_unc_circular); + + ret_val = loc_eng_ioctl( client_handle, + RPC_LOC_IOCTL_INJECT_POSITION, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL /* No output information is expected*/); + return convertErr(ret_val); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::informNiResponse(GpsUserResponseType userResponse, + const void* passThroughData) +{ + rpc_loc_ioctl_data_u_type data; + rpc_loc_ioctl_callback_s_type callback_payload; + + memcpy(&data.rpc_loc_ioctl_data_u_type_u.user_verify_resp.ni_event_pass_back, + passThroughData, sizeof (rpc_loc_ni_event_s_type)); + + rpc_loc_ni_user_resp_e_type resp; + switch (userResponse) + { + case GPS_NI_RESPONSE_ACCEPT: + data.rpc_loc_ioctl_data_u_type_u.user_verify_resp.user_resp = + RPC_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT; + break; + case GPS_NI_RESPONSE_DENY: + data.rpc_loc_ioctl_data_u_type_u.user_verify_resp.user_resp = + RPC_LOC_NI_LCS_NOTIFY_VERIFY_DENY; + break; + case GPS_NI_RESPONSE_NORESP: + default: + data.rpc_loc_ioctl_data_u_type_u.user_verify_resp.user_resp = + RPC_LOC_NI_LCS_NOTIFY_VERIFY_NORESP; + break; + } + + return convertErr( + loc_eng_ioctl(client_handle, + RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE, + &data, + LOC_IOCTL_DEFAULT_TIMEOUT, + &callback_payload) + ); +} + +enum loc_api_adapter_err + LocApiRpcAdapter::setAPN(char* apn, int len) +{ + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, {0}}; + ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].srv_system_type = LOC_APN_PROFILE_SRV_SYS_MAX; + ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].pdp_type = LOC_APN_PROFILE_PDN_TYPE_IPV4; + memcpy(&(ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].apn_name), apn, len+1); + + return convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setServer(const char* url, int len) +{ + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_server_info_s_type *server_info_ptr; + rpc_loc_ioctl_e_type ioctl_cmd; + + ioctl_cmd = RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR; + ioctl_data.disc = ioctl_cmd; + server_info_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.server_addr; + server_info_ptr->addr_type = RPC_LOC_SERVER_ADDR_URL; + server_info_ptr->addr_info.disc = server_info_ptr->addr_type; + server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.length = len; +#if (AMSS_VERSION==3200) + server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_val = (char*) url; + server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_len= len; +#else + strlcpy(server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr, url, + sizeof server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr); +#endif /* #if (AMSS_VERSION==3200) */ + LOC_LOGD ("loc_eng_set_server, addr = %s\n", url); + + return convertErr( + loc_eng_ioctl (client_handle, + ioctl_cmd, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL /* No output information is expected*/) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setServer(unsigned int ip, int port, LocServerType type) +{ + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_server_info_s_type *server_info_ptr; + rpc_loc_ioctl_e_type ioctl_cmd; + + switch (type) { + case LOC_AGPS_MPC_SERVER: + ioctl_cmd = RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR; + break; + case LOC_AGPS_CUSTOM_PDE_SERVER: + ioctl_cmd = RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR; + break; + default: + ioctl_cmd = RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR; + break; + } + ioctl_data.disc = ioctl_cmd; + server_info_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.server_addr; + server_info_ptr->addr_type = RPC_LOC_SERVER_ADDR_IPV4; + server_info_ptr->addr_info.disc = server_info_ptr->addr_type; + server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.ipv4.addr = ip; + server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.ipv4.port = port; + LOC_LOGD ("setServer, addr = %X:%d\n", (unsigned int) ip, (unsigned int) port); + + return convertErr( + loc_eng_ioctl (client_handle, + ioctl_cmd, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL /* No output information is expected*/) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::enableData(int enable) +{ + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_DATA_ENABLE, {0}}; + + ioctl_data.rpc_loc_ioctl_data_u_type_u.data_enable = enable; + return convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_SET_DATA_ENABLE, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::deleteAidingData(GpsAidingData bits) +{ + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_DELETE_ASSIST_DATA, {0}}; + ioctl_data.rpc_loc_ioctl_data_u_type_u.assist_data_delete.type = bits; + + return convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_DELETE_ASSIST_DATA, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *location_report_ptr) +{ + GpsLocation location = {0}; + + location.size = sizeof(location); + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_SESSION_STATUS) + { + // Process the position from final and intermediate reports + if (location_report_ptr->session_status == RPC_LOC_SESS_STATUS_SUCCESS || + location_report_ptr->session_status == RPC_LOC_SESS_STATUS_IN_PROGESS) + { + // Latitude & Longitude + if ((location_report_ptr->valid_mask & RPC_LOC_POS_VALID_LATITUDE) && + (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_LONGITUDE) && + (location_report_ptr->latitude != 0 || + location_report_ptr->longitude != 0)) + { + location.flags |= GPS_LOCATION_HAS_LAT_LONG; + location.latitude = location_report_ptr->latitude; + location.longitude = location_report_ptr->longitude; + + // Time stamp (UTC) + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_TIMESTAMP_UTC) + { + location.timestamp = location_report_ptr->timestamp_utc; + } + + // Altitude + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_ALTITUDE_WRT_ELLIPSOID ) + { + location.flags |= GPS_LOCATION_HAS_ALTITUDE; + location.altitude = location_report_ptr->altitude_wrt_ellipsoid; + } + + // Speed + if ((location_report_ptr->valid_mask & RPC_LOC_POS_VALID_SPEED_HORIZONTAL) && + (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_SPEED_VERTICAL)) + { + location.flags |= GPS_LOCATION_HAS_SPEED; + location.speed = sqrt(location_report_ptr->speed_horizontal * location_report_ptr->speed_horizontal + + location_report_ptr->speed_vertical * location_report_ptr->speed_vertical); + } + + // Heading + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_HEADING) + { + location.flags |= GPS_LOCATION_HAS_BEARING; + location.bearing = location_report_ptr->heading; + } + + // Uncertainty (circular) + if ( (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_HOR_UNC_CIRCULAR) ) + { + location.flags |= GPS_LOCATION_HAS_ACCURACY; + location.accuracy = location_report_ptr->hor_unc_circular; + } + + LOC_LOGV("reportPosition: fire callback\n"); + LocApiAdapter::reportPosition(location, + locEngHandle.extPosInfo((void*)location_report_ptr), + (location_report_ptr->session_status == RPC_LOC_SESS_STATUS_IN_PROGESS ? + LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS)); + } + } + else + { + LocApiAdapter::reportPosition(location, + NULL, + LOC_SESS_FAILURE); + LOC_LOGV("loc_eng_report_position: ignore position report when session status = %d\n", location_report_ptr->session_status); + } + } + else + { + LOC_LOGV("loc_eng_report_position: ignore position report when session status is not set\n"); + } +} + +void LocApiRpcAdapter::reportSv(const rpc_loc_gnss_info_s_type *gnss_report_ptr) +{ + GpsSvStatus SvStatus = {0}; + int num_svs_max = 0; + const rpc_loc_sv_info_s_type *sv_info_ptr; + + if (gnss_report_ptr->valid_mask & RPC_LOC_GNSS_INFO_VALID_SV_COUNT) + { + num_svs_max = gnss_report_ptr->sv_count; + if (num_svs_max > GPS_MAX_SVS) + { + num_svs_max = GPS_MAX_SVS; + } + } + + if (gnss_report_ptr->valid_mask & RPC_LOC_GNSS_INFO_VALID_SV_LIST) + { + SvStatus.num_svs = 0; + + for (int i = 0; i < num_svs_max; i++) + { + sv_info_ptr = &(gnss_report_ptr->sv_list.sv_list_val[i]); + if (sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_SYSTEM) + { + if (sv_info_ptr->system == RPC_LOC_SV_SYSTEM_GPS) + { + SvStatus.sv_list[SvStatus.num_svs].size = sizeof(GpsSvStatus); + SvStatus.sv_list[SvStatus.num_svs].prn = sv_info_ptr->prn; + + // We only have the data field to report gps eph and alm mask + if ((sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_HAS_EPH) && + (sv_info_ptr->has_eph == 1)) + { + SvStatus.ephemeris_mask |= (1 << (sv_info_ptr->prn-1)); + } + + if ((sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_HAS_ALM) && + (sv_info_ptr->has_alm == 1)) + { + SvStatus.almanac_mask |= (1 << (sv_info_ptr->prn-1)); + } + + if ((sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_PROCESS_STATUS) && + (sv_info_ptr->process_status == RPC_LOC_SV_STATUS_TRACK)) + { + SvStatus.used_in_fix_mask |= (1 << (sv_info_ptr->prn-1)); + } + } + // SBAS: GPS RPN: 120-151, + // In exteneded measurement report, we follow nmea standard, which is from 33-64. + else if (sv_info_ptr->system == RPC_LOC_SV_SYSTEM_SBAS) + { + SvStatus.sv_list[SvStatus.num_svs].prn = sv_info_ptr->prn + 33 - 120; + } + // Gloness: Slot id: 1-32 + // In extended measurement report, we follow nmea standard, which is 65-96 + else if (sv_info_ptr->system == RPC_LOC_SV_SYSTEM_GLONASS) + { + SvStatus.sv_list[SvStatus.num_svs].prn = sv_info_ptr->prn + (65-1); + } + // Unsupported SV system + else + { + continue; + } + } + + if (sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_SNR) + { + SvStatus.sv_list[SvStatus.num_svs].snr = sv_info_ptr->snr; + } + + if (sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_ELEVATION) + { + SvStatus.sv_list[SvStatus.num_svs].elevation = sv_info_ptr->elevation; + } + + if (sv_info_ptr->valid_mask & RPC_LOC_SV_INFO_VALID_AZIMUTH) + { + SvStatus.sv_list[SvStatus.num_svs].azimuth = sv_info_ptr->azimuth; + } + + SvStatus.num_svs++; + } + } + + if (SvStatus.num_svs >= 0) + { + LocApiAdapter::reportSv(SvStatus, + locEngHandle.extSvInfo((void*)gnss_report_ptr)); + } +} + +void LocApiRpcAdapter::reportStatus(const rpc_loc_status_event_s_type *status_report_ptr) +{ + GpsStatusValue status = GPS_STATUS_NONE; + + if (status_report_ptr->event == RPC_LOC_STATUS_EVENT_ENGINE_STATE) { + if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.engine_state == RPC_LOC_ENGINE_STATE_ON) + { + status = GPS_STATUS_ENGINE_ON; + } + else if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.engine_state == RPC_LOC_ENGINE_STATE_OFF) + { + status = GPS_STATUS_ENGINE_OFF; + } + } else if (status_report_ptr->event == RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE) { + if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.fix_session_state == RPC_LOC_FIX_SESSION_STATE_BEGIN) + { + status = GPS_STATUS_SESSION_BEGIN; + } + else if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.fix_session_state == RPC_LOC_FIX_SESSION_STATE_END) + { + status = GPS_STATUS_SESSION_END; + } + } + + LocApiAdapter::reportStatus(status); +} + +void LocApiRpcAdapter::reportNmea(const rpc_loc_nmea_report_s_type *nmea_report_ptr) +{ + +#if (AMSS_VERSION==3200) + LocApiAdapter::reportNmea(nmea_report_ptr->nmea_sentences.nmea_sentences_val, + nmea_report_ptr->nmea_sentences.nmea_sentences_len); +#else + LocApiAdapter::reportNmea(nmea_report_ptr->nmea_sentences, + nmea_report_ptr->length); + LOC_LOGD("loc_eng_report_nmea: $%c%c%c\n", + nmea_report_ptr->nmea_sentences[3], nmea_report_ptr->nmea_sentences[4], + nmea_report_ptr->nmea_sentences[5]); +#endif /* #if (AMSS_VERSION==3200) */ +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setXtraData(char* data, int length) +{ + int rpc_ret_val = RPC_LOC_API_GENERAL_FAILURE; + int total_parts; + uint8 part; + uint16 part_len; + uint16 len_injected; + rpc_loc_ioctl_data_u_type ioctl_data; + rpc_loc_ioctl_e_type ioctl_type = RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA; + rpc_loc_predicted_orbits_data_s_type *predicted_orbits_data_ptr; + + LOC_LOGD("qct_loc_eng_inject_xtra_data, xtra size = %d, data ptr = 0x%lx\n", length, (long) data); + + predicted_orbits_data_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.predicted_orbits_data; + predicted_orbits_data_ptr->format_type = RPC_LOC_PREDICTED_ORBITS_XTRA; + predicted_orbits_data_ptr->total_size = length; + total_parts = (length - 1) / XTRA_BLOCK_SIZE + 1; + predicted_orbits_data_ptr->total_parts = total_parts; + + len_injected = 0; // O bytes injected + ioctl_data.disc = ioctl_type; + + // XTRA injection starts with part 1 + for (part = 1; part <= total_parts; part++) + { + predicted_orbits_data_ptr->part = part; + predicted_orbits_data_ptr->part_len = XTRA_BLOCK_SIZE; + if (XTRA_BLOCK_SIZE > (length - len_injected)) + { + predicted_orbits_data_ptr->part_len = length - len_injected; + } + predicted_orbits_data_ptr->data_ptr.data_ptr_len = predicted_orbits_data_ptr->part_len; + predicted_orbits_data_ptr->data_ptr.data_ptr_val = data + len_injected; + + LOC_LOGD("qct_loc_eng_inject_xtra_data, part %d/%d, len = %d, total = %d\n", + predicted_orbits_data_ptr->part, + total_parts, + predicted_orbits_data_ptr->part_len, + len_injected); + + if (part < total_parts) + { + // No callback in this case + rpc_ret_val = loc_ioctl (client_handle, + ioctl_type, + &ioctl_data); + + if (rpc_ret_val != RPC_LOC_API_SUCCESS) + { + LOC_LOGE("loc_ioctl for xtra error: %s\n", loc_get_ioctl_status_name(rpc_ret_val)); + break; + } + //Add a delay of 10 ms so that repeated RPC calls dont starve the modem processor + usleep(10 * 1000); + } + else // part == total_parts + { + // Last part injection, will need to wait for callback + if (!loc_eng_ioctl(client_handle, + ioctl_type, + &ioctl_data, + LOC_XTRA_INJECT_DEFAULT_TIMEOUT, + NULL)) + { + rpc_ret_val = RPC_LOC_API_GENERAL_FAILURE; + } + break; // done with injection + } + + len_injected += predicted_orbits_data_ptr->part_len; + LOC_LOGD("loc_ioctl XTRA injected length: %d\n", len_injected); + } + + return convertErr(rpc_ret_val); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::atlOpenStatus(int handle, int is_succ, char* apn, AGpsBearerType bearer, AGpsType agpsType) +{ + rpc_loc_server_open_status_e_type open_status = is_succ ? RPC_LOC_SERVER_OPEN_SUCCESS : RPC_LOC_SERVER_OPEN_FAIL; + rpc_loc_ioctl_data_u_type ioctl_data; + + if (AGPS_TYPE_INVALID == agpsType) { + rpc_loc_server_open_status_s_type *conn_open_status_ptr = + &ioctl_data.rpc_loc_ioctl_data_u_type_u.conn_open_status; + + // Fill in data + ioctl_data.disc = RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS; + conn_open_status_ptr->conn_handle = handle; + conn_open_status_ptr->open_status = open_status; +#if (AMSS_VERSION==3200) + conn_open_status_ptr->apn_name = apn; /* requires APN */ +#else + if (is_succ) { + strlcpy(conn_open_status_ptr->apn_name, apn, + sizeof conn_open_status_ptr->apn_name); + } else { + conn_open_status_ptr->apn_name[0] = 0; + } +#endif /* #if (AMSS_VERSION==3200) */ + + LOC_LOGD("ATL RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS open %s, APN name = [%s]\n", + log_succ_fail_string(is_succ), + apn); + } else { + rpc_loc_server_multi_open_status_s_type *conn_multi_open_status_ptr = + &ioctl_data.rpc_loc_ioctl_data_u_type_u.multi_conn_open_status; + + // Fill in data + ioctl_data.disc = RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS; + conn_multi_open_status_ptr->conn_handle = handle; + conn_multi_open_status_ptr->open_status = open_status; + if (is_succ) { + strlcpy(conn_multi_open_status_ptr->apn_name, apn, + sizeof conn_multi_open_status_ptr->apn_name); + } else { + conn_multi_open_status_ptr->apn_name[0] = 0; + } + + switch(bearer) + { + case AGPS_APN_BEARER_IPV4: + conn_multi_open_status_ptr->pdp_type = RPC_LOC_SERVER_PDP_IP; + break; + case AGPS_APN_BEARER_IPV6: + conn_multi_open_status_ptr->pdp_type = RPC_LOC_SERVER_PDP_IPV6; + break; + case AGPS_APN_BEARER_IPV4V6: + conn_multi_open_status_ptr->pdp_type = RPC_LOC_SERVER_PDP_IPV4V6; + break; + default: + conn_multi_open_status_ptr->pdp_type = RPC_LOC_SERVER_PDP_PPP; + } + + LOC_LOGD("ATL RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS open %s, APN name = [%s], pdp_type = %d\n", + log_succ_fail_string(is_succ), + apn, + conn_multi_open_status_ptr->pdp_type); + } + + // Make the IOCTL call + return convertErr( + loc_eng_ioctl(client_handle, + ioctl_data.disc, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +enum loc_api_adapter_err +LocApiRpcAdapter::atlCloseStatus(int handle, int is_succ) +{ + rpc_loc_ioctl_data_u_type ioctl_data; + ioctl_data.disc = RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS; + + rpc_loc_server_close_status_s_type *conn_close_status_ptr = + &ioctl_data.rpc_loc_ioctl_data_u_type_u.conn_close_status; + conn_close_status_ptr->conn_handle = handle; + conn_close_status_ptr->close_status = is_succ ? RPC_LOC_SERVER_CLOSE_SUCCESS : RPC_LOC_SERVER_CLOSE_FAIL; + + // Make the IOCTL call + return convertErr( + loc_eng_ioctl(client_handle, + ioctl_data.disc, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +void LocApiRpcAdapter::ATLEvent(const rpc_loc_server_request_s_type *server_request_ptr) +{ + int connHandle; + AGpsType agps_type; + + LOC_LOGV("RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST event %s)", + loc_get_event_atl_open_name(server_request_ptr->event)); + switch (server_request_ptr->event) + { + case RPC_LOC_SERVER_REQUEST_MULTI_OPEN: + connHandle = server_request_ptr->payload.rpc_loc_server_request_u_type_u.multi_open_req.conn_handle; + if (server_request_ptr->payload.rpc_loc_server_request_u_type_u.multi_open_req.connection_type + == RPC_LOC_SERVER_CONNECTION_LBS) { + agps_type = AGPS_TYPE_SUPL; + LOC_LOGV("ATLEvent: event - RPC_LOC_SERVER_REQUEST_MULTI_OPEN\n type - AGPS_TYPE_SUPL\n handle - %d", connHandle); + } else { + agps_type = AGPS_TYPE_WWAN_ANY; + LOC_LOGV("ATLEvent: event - RPC_LOC_SERVER_REQUEST_MULTI_OPEN\n type - AGPS_TYPE_WWAN_ANY\n handle - %d", connHandle); + } + requestATL(connHandle, agps_type); + break; + case RPC_LOC_SERVER_REQUEST_OPEN: + connHandle = server_request_ptr->payload.rpc_loc_server_request_u_type_u.open_req.conn_handle; + LOC_LOGV("ATLEvent: event - RPC_LOC_SERVER_REQUEST_OPEN\n handle - %d", connHandle); + requestATL(connHandle, AGPS_TYPE_INVALID); + break; + case RPC_LOC_SERVER_REQUEST_CLOSE: + connHandle = server_request_ptr->payload.rpc_loc_server_request_u_type_u.close_req.conn_handle; + LOC_LOGV("ATLEvent: event - RPC_LOC_SERVER_REQUEST_CLOSE\n handle - %d", connHandle); + releaseATL(connHandle); + break; + default: + LOC_LOGE("ATLEvent: event type %d invalid", server_request_ptr->event); + } +} + +void LocApiRpcAdapter::NIEvent(const rpc_loc_ni_event_s_type *ni_req) +{ + GpsNiNotification notif = {0}; + + switch (ni_req->event) + { + case RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ: + { + const rpc_loc_ni_vx_notify_verify_req_s_type *vx_req = + &ni_req->payload.rpc_loc_ni_event_payload_u_type_u.vx_req; + LOC_LOGI("VX Notification"); + notif.ni_type = GPS_NI_TYPE_VOICE; + // Requestor ID + hexcode(notif.requestor_id, sizeof notif.requestor_id, + vx_req->requester_id.requester_id, + vx_req->requester_id.requester_id_length); + notif.text_encoding = 0; // No text and no encoding + notif.requestor_id_encoding = convertNiEncodingType(vx_req->encoding_scheme); + NIEventFillVerfiyType(notif, vx_req->notification_priv_type); + } + break; + + case RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ: + { + const rpc_loc_ni_umts_cp_notify_verify_req_s_type *umts_cp_req = + &ni_req->payload.rpc_loc_ni_event_payload_u_type_u.umts_cp_req; + LOC_LOGI("UMTS CP Notification\n"); + notif.ni_type= GPS_NI_TYPE_UMTS_CTRL_PLANE; // Stores notification text +#if (AMSS_VERSION==3200) + hexcode(notif.text, sizeof notif.text, + umts_cp_req->notification_text.notification_text_val, + umts_cp_req->notification_length); + hexcode(notif.requestor_id, sizeof notif.requestor_id, + umts_cp_req->requestor_id.requestor_id_string.requestor_id_string_val, + umts_cp_req->requestor_id.string_len); +#else + hexcode(notif.text, sizeof notif.text, + umts_cp_req->notification_text, + umts_cp_req->notification_length); + hexcode(notif.requestor_id, sizeof notif.requestor_id, + umts_cp_req->requestor_id.requestor_id_string, + umts_cp_req->requestor_id.string_len); +#endif + notif.text_encoding = convertNiEncodingType(umts_cp_req->datacoding_scheme); + notif.requestor_id_encoding = notif.text_encoding; + NIEventFillVerfiyType(notif, umts_cp_req->notification_priv_type); + + // LCS address (using extras field) + if (umts_cp_req->ext_client_address_data.ext_client_address_len != 0) + { + // Copy LCS Address into notif.extras in the format: Address = 012345 + strlcat(notif.extras, LOC_NI_NOTIF_KEY_ADDRESS, sizeof notif.extras); + strlcat(notif.extras, " = ", sizeof notif.extras); + int addr_len = 0; + const char *address_source = NULL; + +#if (AMSS_VERSION==3200) + address_source = umts_cp_req->ext_client_address_data.ext_client_address.ext_client_address_val; +#else + address_source = umts_cp_req->ext_client_address_data.ext_client_address; +#endif /* #if (AMSS_VERSION==3200) */ + + char lcs_addr[32]; // Decoded LCS address for UMTS CP NI + addr_len = LocApiAdapter::decodeAddress(lcs_addr, sizeof lcs_addr, address_source, + umts_cp_req->ext_client_address_data.ext_client_address_len); + + // The address is ASCII string + if (addr_len) + { + strlcat(notif.extras, lcs_addr, sizeof notif.extras); + } + } + } + break; + + case RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ: + { + const rpc_loc_ni_supl_notify_verify_req_s_type *supl_req = + &ni_req->payload.rpc_loc_ni_event_payload_u_type_u.supl_req; + LOC_LOGI("SUPL Notification\n"); + notif.ni_type = GPS_NI_TYPE_UMTS_SUPL; + + if (supl_req->flags & RPC_LOC_NI_CLIENT_NAME_PRESENT) + { +#if (AMSS_VERSION==3200) + hexcode(notif.text, sizeof notif.text, + supl_req->client_name.client_name_string.client_name_string_val, /* buffer */ + supl_req->client_name.string_len /* length */ + ); +#else + hexcode(notif.text, sizeof notif.text, + supl_req->client_name.client_name_string, /* buffer */ + supl_req->client_name.string_len /* length */ + ); +#endif /* #if (AMSS_VERSION==3200) */ + LOC_LOGV("SUPL NI: client_name: %s len=%d", notif.text, supl_req->client_name.string_len); + } + else { + LOC_LOGV("SUPL NI: client_name not present."); + } + + // Requestor ID + if (supl_req->flags & RPC_LOC_NI_REQUESTOR_ID_PRESENT) + { +#if (AMSS_VERSION==3200) + hexcode(notif.requestor_id, sizeof notif.requestor_id, + supl_req->requestor_id.requestor_id_string.requestor_id_string_val, /* buffer */ + supl_req->requestor_id.string_len /* length */ + ); +#else + hexcode(notif.requestor_id, sizeof notif.requestor_id, + supl_req->requestor_id.requestor_id_string, /* buffer */ + supl_req->requestor_id.string_len /* length */ + ); +#endif /* #if (AMSS_VERSION==3200) */ + LOC_LOGV("SUPL NI: requestor_id: %s len=%d", notif.requestor_id, supl_req->requestor_id.string_len); + } + else { + LOC_LOGV("SUPL NI: requestor_id not present."); + } + + // Encoding type + if (supl_req->flags & RPC_LOC_NI_ENCODING_TYPE_PRESENT) + { + notif.text_encoding = convertNiEncodingType(supl_req->datacoding_scheme); + notif.requestor_id_encoding = notif.text_encoding; + } + else { + notif.text_encoding = notif.requestor_id_encoding = GPS_ENC_UNKNOWN; + } + + NIEventFillVerfiyType(notif, ni_req->payload.rpc_loc_ni_event_payload_u_type_u.supl_req.notification_priv_type); + } + break; + + default: + LOC_LOGE("Unknown NI event: %x\n", (int) ni_req->event); + return; + } + + // this copy will get freed in loc_eng_ni when loc_ni_respond() is called + rpc_loc_ni_event_s_type *copy = (rpc_loc_ni_event_s_type *)malloc(sizeof(*copy)); + memcpy(copy, ni_req, sizeof(*copy)); + LocApiAdapter::requestNiNotify(notif, (const void*)copy); +} + +int LocApiRpcAdapter::NIEventFillVerfiyType(GpsNiNotification ¬if, + rpc_loc_ni_notify_verify_e_type notif_priv) +{ + switch (notif_priv) + { + case RPC_LOC_NI_USER_NO_NOTIFY_NO_VERIFY: + notif.notify_flags = 0; + notif.default_response = GPS_NI_RESPONSE_NORESP; + return 1; + case RPC_LOC_NI_USER_NOTIFY_ONLY: + notif.notify_flags = GPS_NI_NEED_NOTIFY; + notif.default_response = GPS_NI_RESPONSE_NORESP; + return 1; + case RPC_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP: + notif.notify_flags = GPS_NI_NEED_NOTIFY | GPS_NI_NEED_VERIFY; + notif.default_response = GPS_NI_RESPONSE_ACCEPT; + return 1; + case RPC_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP: + notif.notify_flags = GPS_NI_NEED_NOTIFY | GPS_NI_NEED_VERIFY; + notif.default_response = GPS_NI_RESPONSE_DENY; + return 1; + case RPC_LOC_NI_USER_PRIVACY_OVERRIDE: + notif.notify_flags = GPS_NI_PRIVACY_OVERRIDE; + notif.default_response = GPS_NI_RESPONSE_NORESP; + return 1; + default: + return 0; + } +} + +enum loc_api_adapter_err +LocApiRpcAdapter::setSUPLVersion(uint32_t version) +{ + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_SUPL_VERSION, {0}}; + ioctl_data.rpc_loc_ioctl_data_u_type_u.supl_version = (int)version; + return convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_SET_SUPL_VERSION, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); +} + +GpsNiEncodingType LocApiRpcAdapter::convertNiEncodingType(int loc_encoding) +{ + switch (loc_encoding) + { + case RPC_LOC_NI_SUPL_UTF8: + return GPS_ENC_SUPL_UTF8; + case RPC_LOC_NI_SUPL_UCS2: + return GPS_ENC_SUPL_UCS2; + case RPC_LOC_NI_SUPL_GSM_DEFAULT: + return GPS_ENC_SUPL_GSM_DEFAULT; + case RPC_LOC_NI_SS_LANGUAGE_UNSPEC: + return GPS_ENC_SUPL_GSM_DEFAULT; // SS_LANGUAGE_UNSPEC = GSM + default: + return GPS_ENC_UNKNOWN; + } +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c new file mode 100755 index 00000000..32e3cda8 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c @@ -0,0 +1,52 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include + +#include "loc_api_fixup.h" + +#ifdef ADD_XDR_FLOAT + +int +xdr_float(xdrp, fp) + XDR *xdrp; + float *fp; +{ + return xdr_long(xdrp, (long*)fp); +} + +int +xdr_double(xdrp, dp) + XDR *xdrp; + double *dp; +{ + return xdr_long(xdrp, (long*)dp + 1) + && xdr_long(xdrp, (long*)dp); +} + +#endif /* ADD_XDR_FLOAT */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c new file mode 100755 index 00000000..6aa5254f --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c @@ -0,0 +1,344 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_api_rpc_glue" + +#include "loc_api_log.h" +#include "loc_log.h" +#include "log_util.h" +#include "rpc/rpc.h" +#include "loc_api_fixup.h" + +/* Event names */ +loc_name_val_s_type loc_event_name[] = + { + NAME_VAL( RPC_LOC_EVENT_PARSED_POSITION_REPORT ), + NAME_VAL( RPC_LOC_EVENT_SATELLITE_REPORT ), + NAME_VAL( RPC_LOC_EVENT_NMEA_1HZ_REPORT ), + NAME_VAL( RPC_LOC_EVENT_NMEA_POSITION_REPORT ), + NAME_VAL( RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST ), + NAME_VAL( RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST ), + NAME_VAL( RPC_LOC_EVENT_LOCATION_SERVER_REQUEST ), + NAME_VAL( RPC_LOC_EVENT_IOCTL_REPORT ), + NAME_VAL( RPC_LOC_EVENT_STATUS_REPORT ), + NAME_VAL( RPC_LOC_EVENT_WPS_NEEDED_REQUEST ), + }; +int loc_event_num = sizeof loc_event_name / sizeof(loc_name_val_s_type); + +/* Event names */ +loc_name_val_s_type loc_event_atl_open_name[] = + { + NAME_VAL( RPC_LOC_SERVER_REQUEST_OPEN ), + NAME_VAL( RPC_LOC_SERVER_REQUEST_CLOSE ), + NAME_VAL( RPC_LOC_SERVER_REQUEST_MULTI_OPEN ) + }; +int loc_event_atl_open_num = sizeof loc_event_atl_open_name / sizeof(loc_name_val_s_type); + +/* Finds the first event found in the mask */ +const char* loc_get_event_atl_open_name(rpc_loc_server_request_e_type loc_event_atl_open) +{ + return loc_get_name_from_val(loc_event_atl_open_name, loc_event_atl_open_num, + (long) loc_event_atl_open); +} + +/* IOCTL Type names */ +loc_name_val_s_type loc_ioctl_type_name[] = + { + NAME_VAL( RPC_LOC_IOCTL_GET_API_VERSION ), + NAME_VAL( RPC_LOC_IOCTL_SET_FIX_CRITERIA ), + NAME_VAL( RPC_LOC_IOCTL_GET_FIX_CRITERIA ), + NAME_VAL( RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE ), + NAME_VAL( RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA ), + NAME_VAL( RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY ), + NAME_VAL( RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE ), + NAME_VAL( RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD ), + NAME_VAL( RPC_LOC_IOCTL_INJECT_UTC_TIME ), + NAME_VAL( RPC_LOC_IOCTL_INJECT_RTC_VALUE ), + NAME_VAL( RPC_LOC_IOCTL_INJECT_POSITION ), + NAME_VAL( RPC_LOC_IOCTL_QUERY_ENGINE_STATE ), + NAME_VAL( RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG), + NAME_VAL( RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS ), + NAME_VAL( RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS ), + NAME_VAL( RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS ), + NAME_VAL( RPC_LOC_IOCTL_SEND_WIPER_POSITION_REPORT ), + NAME_VAL( RPC_LOC_IOCTL_NOTIFY_WIPER_STATUS ), + NAME_VAL( RPC_LOC_IOCTL_SET_ENGINE_LOCK ), + NAME_VAL( RPC_LOC_IOCTL_GET_ENGINE_LOCK ), + NAME_VAL( RPC_LOC_IOCTL_SET_SBAS_CONFIG ), + NAME_VAL( RPC_LOC_IOCTL_GET_SBAS_CONFIG ), + NAME_VAL( RPC_LOC_IOCTL_SET_NMEA_TYPES ), + NAME_VAL( RPC_LOC_IOCTL_GET_NMEA_TYPES ), + NAME_VAL( RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_SET_ON_DEMAND_LPM ), + NAME_VAL( RPC_LOC_IOCTL_GET_ON_DEMAND_LPM ), + NAME_VAL( RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL ), + NAME_VAL( RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL ), + NAME_VAL( RPC_LOC_IOCTL_SET_LBS_APN_PROFILE ), + NAME_VAL( RPC_LOC_IOCTL_GET_LBS_APN_PROFILE ), + NAME_VAL( RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE ), + NAME_VAL( RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE ), + NAME_VAL( RPC_LOC_IOCTL_SET_DATA_ENABLE ), + NAME_VAL( RPC_LOC_IOCTL_SET_SUPL_VERSION ), + NAME_VAL( RPC_LOC_IOCTL_GET_SUPL_VERSION ), + NAME_VAL( RPC_LOC_IOCTL_DELETE_ASSIST_DATA ), + NAME_VAL( RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR ), + NAME_VAL( RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR ), + }; +int loc_ioctl_type_num = sizeof loc_ioctl_type_name / sizeof(loc_name_val_s_type); + +/* IOCTL Status names */ +loc_name_val_s_type loc_ioctl_status_name[] = + { + NAME_VAL( RPC_LOC_API_SUCCESS ), + NAME_VAL( RPC_LOC_API_GENERAL_FAILURE ), + NAME_VAL( RPC_LOC_API_UNSUPPORTED ), + NAME_VAL( RPC_LOC_API_INVALID_HANDLE ), + NAME_VAL( RPC_LOC_API_INVALID_PARAMETER ), + NAME_VAL( RPC_LOC_API_ENGINE_BUSY ), + NAME_VAL( RPC_LOC_API_PHONE_OFFLINE ), + NAME_VAL( RPC_LOC_API_TIMEOUT ), + NAME_VAL( RPC_LOC_API_RPC_FAILURE ), + NAME_VAL( RPC_LOC_API_RPC_MODEM_RESTART ) + }; +int loc_ioctl_status_num = sizeof loc_ioctl_status_name / sizeof(loc_name_val_s_type); + +/* Fix session status names */ +loc_name_val_s_type loc_sess_status_name[] = + { + NAME_VAL( RPC_LOC_SESS_STATUS_SUCCESS ), + NAME_VAL( RPC_LOC_SESS_STATUS_IN_PROGESS ), + NAME_VAL( RPC_LOC_SESS_STATUS_GENERAL_FAILURE ), + NAME_VAL( RPC_LOC_SESS_STATUS_TIMEOUT ), + NAME_VAL( RPC_LOC_SESS_STATUS_USER_END ), + NAME_VAL( RPC_LOC_SESS_STATUS_BAD_PARAMETER ), + NAME_VAL( RPC_LOC_SESS_STATUS_PHONE_OFFLINE ), + NAME_VAL( RPC_LOC_SESS_STATUS_USER_END ), + NAME_VAL( RPC_LOC_SESS_STATUS_ENGINE_LOCKED ) + }; +int loc_sess_status_num = sizeof loc_sess_status_name / sizeof(loc_name_val_s_type); + +/* Engine state names */ +loc_name_val_s_type loc_engine_state_name[] = + { + NAME_VAL( RPC_LOC_ENGINE_STATE_ON ), + NAME_VAL( RPC_LOC_ENGINE_STATE_OFF ) + }; +int loc_engine_state_num = sizeof loc_engine_state_name / sizeof(loc_name_val_s_type); + +/* Fix session state names */ +loc_name_val_s_type loc_fix_session_state_name[] = + { + NAME_VAL( RPC_LOC_FIX_SESSION_STATE_BEGIN ), + NAME_VAL( RPC_LOC_FIX_SESSION_STATE_END ) + }; +int loc_fix_session_state_num = sizeof loc_fix_session_state_name / sizeof(loc_name_val_s_type); + + +static const char* log_final_interm_string(int is_final) +{ + return is_final ? "final" : "intermediate"; +} + +/* Logs parsed report */ +static void log_parsed_report(const rpc_loc_parsed_position_s_type *parsed_report) +{ + rpc_loc_session_status_e_type status = parsed_report->session_status; + LOC_LOGD("Session status: %s Valid mask: 0x%X\n", + loc_get_sess_status_name(status), + (uint) parsed_report->valid_mask); + LOC_LOGD("Latitude: %.7f (%s)\n", parsed_report->latitude, + log_final_interm_string( + (parsed_report->valid_mask & RPC_LOC_POS_VALID_LATITUDE) && + parsed_report->session_status == RPC_LOC_SESS_STATUS_SUCCESS)); + LOC_LOGD("Longitude: %.7f\n", parsed_report->longitude); + LOC_LOGD("Accuracy: %.7f\n", parsed_report->hor_unc_circular); +} + +/* Logs status report */ +static void log_status_report(const rpc_loc_status_event_s_type *status_event) +{ + rpc_loc_status_event_e_type event = status_event->event; + switch (event) { + case RPC_LOC_STATUS_EVENT_ENGINE_STATE: + LOC_LOGD("Engine state: %s\n", + loc_get_engine_state_name( + status_event->payload.rpc_loc_status_event_payload_u_type_u.engine_state)); + break; + case RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE: + LOC_LOGD("Fix session state: %s\n", + loc_get_fix_session_state_name( + status_event->payload.rpc_loc_status_event_payload_u_type_u.fix_session_state)); + break; + default: + break; + } +} + +/* Logs valid fields in the GNSS SV constellation report */ +static void log_satellite_report(const rpc_loc_gnss_info_s_type *gnss) +{ + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_POS_DOP) + { + LOC_LOGV("position dop: %.3f\n", (float) gnss->position_dop); + } + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_HOR_DOP) + { + LOC_LOGV("horizontal dop: %.3f\n", (float) gnss->horizontal_dop); + } + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_VERT_DOP) + { + LOC_LOGV("vertical dop: %.3f\n", (float) gnss->vertical_dop); + } + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_ALTITUDE_ASSUMED) + { + LOC_LOGV("altitude assumed: %d\n", (int) gnss->altitude_assumed); + } + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_SV_COUNT) + { + LOC_LOGD("sv count: %d\n", (int) gnss->sv_count); + } + if (gnss->valid_mask & RPC_LOC_GNSS_INFO_VALID_SV_LIST) + { + LOC_LOGV("sv list: "); + + if (gnss->sv_count) + { + LOC_LOGV("\n\tsys\tprn\thlth\tproc\teph\talm\telev\tazi\tsnr\n"); + } + else { + LOC_LOGV("empty\n"); + } + + int i; + for (i = 0; i < gnss->sv_count; i++) + { + const rpc_loc_sv_info_s_type *sv = &gnss->sv_list.sv_list_val[i]; + rpc_loc_sv_info_valid_mask_type mask = sv->valid_mask; + LOC_LOGV(" %d: \t%d\t%d\t%d\t%d\t%d\t%d\t%.3f\t%.3f\t%.3f\n", i, + CHECK_MASK(int, sv->system, mask, RPC_LOC_SV_INFO_VALID_SYSTEM), + CHECK_MASK(int, sv->prn, mask, RPC_LOC_SV_INFO_VALID_PRN), + CHECK_MASK(int, sv->health_status, mask, RPC_LOC_SV_INFO_VALID_HEALTH_STATUS), + CHECK_MASK(int, sv->process_status, mask, RPC_LOC_SV_INFO_VALID_PROCESS_STATUS), + CHECK_MASK(int, sv->has_eph, mask, RPC_LOC_SV_INFO_VALID_HAS_EPH), + CHECK_MASK(int, sv->has_alm, mask, RPC_LOC_SV_INFO_VALID_HAS_ALM), + CHECK_MASK(float, sv->elevation, mask, RPC_LOC_SV_INFO_VALID_ELEVATION), + CHECK_MASK(float, sv->azimuth, mask, RPC_LOC_SV_INFO_VALID_AZIMUTH), + CHECK_MASK(float, sv->snr, mask, RPC_LOC_SV_INFO_VALID_SNR) + ); + } + } +} + +/* Logs a callback event */ +int loc_callback_log( + rpc_loc_event_mask_type loc_event, /* event mask */ + const rpc_loc_event_payload_u_type* loc_event_payload /* payload */ +) +{ + switch (loc_event) + { + case RPC_LOC_EVENT_SATELLITE_REPORT: + log_satellite_report(&loc_event_payload-> + rpc_loc_event_payload_u_type_u.gnss_report); + break; + case RPC_LOC_EVENT_STATUS_REPORT: + log_status_report(&loc_event_payload-> + rpc_loc_event_payload_u_type_u.status_report); + break; + case RPC_LOC_EVENT_PARSED_POSITION_REPORT: + log_parsed_report(&loc_event_payload-> + rpc_loc_event_payload_u_type_u.parsed_location_report); + break; + default: + break; + } + + return 0; +} + +/* Finds the first event found in the mask */ +const char* loc_get_event_name(rpc_loc_event_mask_type loc_event_mask) +{ + return loc_get_name_from_mask(loc_event_name, loc_event_num, + (long) loc_event_mask); +} + +/* Finds IOCTL type name */ +const char* loc_get_ioctl_type_name(rpc_loc_ioctl_e_type ioctl_type) +{ + return loc_get_name_from_val(loc_ioctl_type_name, loc_ioctl_type_num, + (long) ioctl_type); +} + +/* Finds IOCTL status name */ +const char* loc_get_ioctl_status_name(uint32 status) +{ + return loc_get_name_from_val(loc_ioctl_status_name, loc_ioctl_status_num, + (long) status); +} + +/* Finds session status name */ +const char* loc_get_sess_status_name(rpc_loc_session_status_e_type status) +{ + return loc_get_name_from_val(loc_sess_status_name, loc_sess_status_num, + (long) status); +} + +/* Find engine state name */ +const char* loc_get_engine_state_name(rpc_loc_engine_state_e_type state) +{ + return loc_get_name_from_val(loc_engine_state_name, loc_engine_state_num, + (long) state); +} + +/* Find engine state name */ +const char* loc_get_fix_session_state_name(rpc_loc_fix_session_state_e_type state) +{ + return loc_get_name_from_val(loc_fix_session_state_name, loc_fix_session_state_num, + (long) state); +} + +/* Event names */ +loc_name_val_s_type rpc_reset_event_name[] = +{ + NAME_VAL( RPC_SUBSYSTEM_RESTART_BEGIN ), + NAME_VAL( RPC_SUBSYSTEM_RESTART_END ) +}; +int rpc_reset_event_num = sizeof rpc_reset_event_name / sizeof(loc_name_val_s_type); + +const char* loc_get_rpc_reset_event_name(enum rpc_reset_event event) +{ + return loc_get_name_from_val(rpc_reset_event_name, rpc_reset_event_num, event); +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c new file mode 100755 index 00000000..10b2d221 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c @@ -0,0 +1,621 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/*===================================================================== + + INCLUDE FILES FOR MODULE + +======================================================================*/ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +/* Include RPC headers */ +#include "rpc_inc/loc_api_rpc_glue.h" + +/* Callback init */ +#include "rpc_inc/loc_apicb_appinit.h" + +/* Logging */ +#define LOG_TAG "LocSvc_api_rpc_glue" +#define LOG_NDDEBUG 0 +#include + +/* Logging Improvement */ +#include "log_util.h" + +/* Uncomment to force LOGD messages */ +// #define LOGD LOGI + +/*===================================================================== + External declarations +======================================================================*/ + +CLIENT* loc_api_clnt = NULL; + +/* Callback ID and pointer */ +#define LOC_API_CB_MAX_CLIENTS 16 +typedef struct +{ + uint32 cb_id; /* same as rpc/types.h */ + loc_event_cb_f_type *cb_func; /* callback func */ + loc_reset_notif_cb_f_type *rpc_cb; /* callback from RPC */ + rpc_loc_client_handle_type handle; /* stores handle for client closing */ + void* user; /* user's own data handle */ +} loc_glue_cb_entry_s_type; + +loc_glue_cb_entry_s_type loc_glue_callback_table[LOC_API_CB_MAX_CLIENTS]; + +#define RPC_FUNC_VERSION_BASE(a,b) a ## b +#define RPC_FUNC_VERSION(a,b) RPC_FUNC_VERSION_BASE(a,b) + +#define RPC_CALLBACK_FUNC_VERSION_BASE(a,v,b) a ## v ## b +#define RPC_CALLBACK_FUNC_VERSION(a,v,b) RPC_CALLBACK_FUNC_VERSION_BASE(a,v,b) + +#define LOC_GLUE_CHECK_INIT(ret_type) \ + if (loc_api_clnt == NULL) { EXIT_LOG_CALLFLOW(%d, RPC_LOC_API_RPC_FAILURE); return (ret_type) RPC_LOC_API_RPC_FAILURE; } + +#define LOC_GLUE_CHECK_RESULT(stat, ret_type) \ + if (stat != RPC_SUCCESS) { \ + LOC_LOGE("%s:%d] failure code %d", __func__, __LINE__, stat); \ + return (ret_type)((stat == RPC_SUBSYSTEM_RESTART) ? \ + RPC_LOC_API_RPC_MODEM_RESTART : RPC_LOC_API_RPC_FAILURE); \ + } + +/* Callback functions */ +/* Returns 1 if successful */ +bool_t rpc_loc_event_cb_f_type_svc( + rpc_loc_event_cb_f_type_args *argp, + rpc_loc_event_cb_f_type_rets *ret, + struct svc_req *req) +{ + // The lower word of cd_id is the index + int index = argp->cb_id & 0xFFFF; + + /* Callback not registered, or unexpected ID (shouldn't happen) */ + if (index >= LOC_API_CB_MAX_CLIENTS || loc_glue_callback_table[index].cb_func == NULL) + { + LOC_LOGE("Warning: No callback handler %d.\n", index); + ret->loc_event_cb_f_type_result = 0; + return 1; /* simply return */ + } + + LOC_LOGV("proc: %x prog: %x vers: %x\n", + (int) req->rq_proc, + (int) req->rq_prog, + (int) req->rq_vers); + + LOC_LOGV("Callback received: %x (cb_id=%p handle=%d ret_ptr=%d)\n", + (int) argp->loc_event, + argp->cb_id, + (int) argp->loc_handle, + (int) ret); + + /* Forward callback to real callback procedure */ + rpc_loc_client_handle_type loc_handle = argp->loc_handle; + rpc_loc_event_mask_type loc_event = argp->loc_event; + const rpc_loc_event_payload_u_type* loc_event_payload = + (const rpc_loc_event_payload_u_type*) argp->loc_event_payload; + + /* Gives control to synchronous call handler */ + loc_api_callback_process_sync_call(loc_handle, loc_event, loc_event_payload); + + int32 rc = (loc_glue_callback_table[index].cb_func)(loc_glue_callback_table[index].user, + loc_handle, loc_event, loc_event_payload); + + LOC_LOGV("cb_func=%p", loc_glue_callback_table[index].cb_func); + + ret->loc_event_cb_f_type_result = rc; + + return 1; /* ok */ +} + +int loc_apicbprog_freeresult (SVCXPRT *transp, xdrproc_t xdr_result, caddr_t result) +{ + xdr_free (xdr_result, result); + + /* + * Insert additional freeing code here, if needed + */ + // LOC_LOGD("***** loc_apicbprog_freeresult\n"); + + return 1; +} + +/*=========================================================================== + +FUNCTION rpc_loc_event_cb_f_type__svc (MACRO) + +DESCRIPTION + Callback function for Loc API + +RETURN VALUE + 1 for success + 0 for failure + +===========================================================================*/ +bool_t RPC_CALLBACK_FUNC_VERSION(rpc_loc_event_cb_f_type_, RPC_LOC_EVENT_CB_F_TYPE_VERSION, _svc) ( + rpc_loc_event_cb_f_type_args *argp, + rpc_loc_event_cb_f_type_rets *ret, + struct svc_req *req) +{ + return rpc_loc_event_cb_f_type_svc(argp, ret, req); +} + +/*=========================================================================== + +FUNCTION loc_apicbprog__freeresult (MACRO) + +DESCRIPTION + Free up RPC data structure + +RETURN VALUE + 1 for success + 0 for failure + +===========================================================================*/ +#define VERSION_CONCAT(MAJOR,MINOR) MAJOR##MINOR +#define loc_apicb_prog_VER_freeresult(M,N) \ +int RPC_CALLBACK_FUNC_VERSION(loc_apicbprog_, VERSION_CONCAT(M,N), _freeresult) \ +(SVCXPRT *transp, xdrproc_t xdr_result, caddr_t result) \ +{ \ + return loc_apicbprog_freeresult(transp, xdr_result, result); \ +} + +/* Define all of the possible minors */ +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0001); +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0002); +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0003); +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0004); +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0005); +loc_apicb_prog_VER_freeresult(RPC_LOC_API_API_MAJOR_NUM, 0006); + +/*=========================================================================== + +FUNCTION rpc_loc_api_cb_null__svc (MACRO) [Patch for wrong RPCGEN stubs] + +DESCRIPTION + Null callback function for Loc API + +RETURN VALUE + 1 for success + +===========================================================================*/ +#define rpc_loc_api_cb_null_VER_svc(M,N) \ +bool_t RPC_CALLBACK_FUNC_VERSION(rpc_loc_api_cb_null_, VERSION_CONCAT(M,N), _svc) ( \ + void *a, int *b, struct svc_req *req) \ +{ \ + return 1; \ +} + +/* Define all of the possible minors */ +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0001); +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0002); +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0003); +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0004); +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0005); +rpc_loc_api_cb_null_VER_svc(RPC_LOC_API_API_MAJOR_NUM, 0006); + +static void loc_api_glue_rpc_cb(CLIENT* client, enum rpc_reset_event event) +{ + int i; + for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) { + if (NULL != loc_glue_callback_table[i].rpc_cb) { + loc_glue_callback_table[i].rpc_cb(loc_glue_callback_table[i].user, client, event); + } + } +} + +/*=========================================================================== + +FUNCTION loc_api_glue_init + +DESCRIPTION + Initiates the RPC client + +RETURN VALUE + 1 for success + 0 for failure + +===========================================================================*/ +int loc_api_glue_init(void) +{ + if (loc_api_clnt == NULL) + { + /* Initialize data */ + int i; + int pid = getpid(); + for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) + { + loc_glue_callback_table[i].cb_id = i | (pid << 16); + loc_glue_callback_table[i].cb_func = NULL; + loc_glue_callback_table[i].handle = -1; + loc_glue_callback_table[i].rpc_cb = NULL; + loc_glue_callback_table[i].user = NULL; + } + + /* Print msg */ + LOC_LOGV("Trying to create RPC client...\n"); + loc_api_clnt = clnt_create(NULL, LOC_APIPROG, LOC_APIVERS, NULL); + LOC_LOGV("Created loc_api_clnt ---- %x\n", (unsigned int)loc_api_clnt); + + if (loc_api_clnt == NULL) + { + LOC_LOGE("Error: cannot create RPC client.\n"); + return 0; + } + + /* Init RPC callbacks */ + loc_api_sync_call_init(); + + int rc = loc_apicb_app_init(); + if (rc >= 0) + { + LOC_LOGD("Loc API RPC client initialized.\n"); + clnt_register_reset_notification_cb(loc_api_clnt, loc_api_glue_rpc_cb); + } + else { + LOC_LOGE("Loc API callback initialization failed.\n"); + return 0; + } + } + + return 1; +} + +rpc_loc_client_handle_type loc_open ( + rpc_loc_event_mask_type event_reg_mask, + loc_event_cb_f_type *event_callback, + loc_reset_notif_cb_f_type *rpc_cb, + void* userData +) +{ + ENTRY_LOG(); + LOC_GLUE_CHECK_INIT(rpc_loc_client_handle_type); + + rpc_loc_client_handle_type ret_val; + + rpc_loc_open_args args; + args.event_reg_mask = event_reg_mask; + + int i; + for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) + { + if (loc_glue_callback_table[i].cb_func == event_callback || + loc_glue_callback_table[i].user == userData) + { + LOC_LOGW("Client already opened service (callback=%p)...\n", + event_callback); + break; + } + } + + if (i == LOC_API_CB_MAX_CLIENTS) + { + for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) + { + if (loc_glue_callback_table[i].cb_func == NULL) + { + loc_glue_callback_table[i].cb_func = event_callback; + loc_glue_callback_table[i].rpc_cb = rpc_cb; + loc_glue_callback_table[i].user = userData; + break; + } + } + } + + if (i == LOC_API_CB_MAX_CLIENTS) + { + LOC_LOGE("Too many clients opened at once...\n"); + return RPC_LOC_CLIENT_HANDLE_INVALID; + } + + args.event_callback = loc_glue_callback_table[i].cb_id; + LOC_LOGV("cb_id=%d, func=0x%x", i, (unsigned int) event_callback); + + rpc_loc_open_rets rets; + enum clnt_stat stat = RPC_SUCCESS; + + EXIT_LOG_CALLFLOW(%s, "loc client open"); + stat = RPC_FUNC_VERSION(rpc_loc_open_, RPC_LOC_OPEN_VERSION)(&args, &rets, loc_api_clnt); + LOC_GLUE_CHECK_RESULT(stat, int32); + + /* save the handle in the table */ + loc_glue_callback_table[i].handle = (rpc_loc_client_handle_type) rets.loc_open_result; + + ret_val = (rpc_loc_client_handle_type) rets.loc_open_result; + + return ret_val; + +} + +int32 loc_close +( + rpc_loc_client_handle_type handle +) +{ + ENTRY_LOG(); + LOC_GLUE_CHECK_INIT(int32); + + int32 ret_val; + + rpc_loc_close_args args; + args.handle = handle; + + rpc_loc_close_rets rets; + enum clnt_stat stat = RPC_SUCCESS; + + EXIT_LOG_CALLFLOW(%s, "loc client close"); + stat = RPC_FUNC_VERSION(rpc_loc_close_, RPC_LOC_CLOSE_VERSION)(&args, &rets, loc_api_clnt); + + loc_clear(handle); + + LOC_GLUE_CHECK_RESULT(stat, int32); + ret_val = (int32) rets.loc_close_result; + + return ret_val; +} + +void loc_clear(rpc_loc_client_handle_type handle) { + /* Clean the client's callback function in callback table */ + int i; + for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) + { + if (loc_glue_callback_table[i].handle == handle) + { + /* Found the client */ + loc_glue_callback_table[i].cb_func = NULL; + loc_glue_callback_table[i].rpc_cb = NULL; + loc_glue_callback_table[i].handle = -1; + break; + } + } + + if (i == LOC_API_CB_MAX_CLIENTS) + { + LOC_LOGW("Handle not found (handle=%d)...\n", (int) handle); + } +} + +int32 loc_start_fix +( + rpc_loc_client_handle_type handle +) +{ + ENTRY_LOG(); + LOC_GLUE_CHECK_INIT(int32); + + int32 ret_val; + + rpc_loc_start_fix_args args; + args.handle = handle; + + rpc_loc_start_fix_rets rets; + enum clnt_stat stat = RPC_SUCCESS; + + EXIT_LOG_CALLFLOW(%s, "loc start fix"); + stat = RPC_FUNC_VERSION(rpc_loc_start_fix_, RPC_LOC_START_FIX_VERSION)(&args, &rets, loc_api_clnt); + LOC_GLUE_CHECK_RESULT(stat, int32); + + ret_val = (int32) rets.loc_start_fix_result; + + return ret_val; +} + +int32 loc_stop_fix +( + rpc_loc_client_handle_type handle +) +{ + ENTRY_LOG(); + LOC_GLUE_CHECK_INIT(int32); + + int32 ret_val; + + rpc_loc_stop_fix_args args; + args.handle = handle; + + rpc_loc_stop_fix_rets rets; + enum clnt_stat stat = RPC_SUCCESS; + + EXIT_LOG_CALLFLOW(%s, "loc stop fix"); + stat = RPC_FUNC_VERSION(rpc_loc_stop_fix_, RPC_LOC_STOP_FIX_VERSION)(&args, &rets, loc_api_clnt); + LOC_GLUE_CHECK_RESULT(stat, int32); + + ret_val = (int32) rets.loc_stop_fix_result; + + return ret_val; +} + +int32 loc_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data +) +{ + ENTRY_LOG(); + LOC_GLUE_CHECK_INIT(int32); + + int32 ret_val; + + rpc_loc_ioctl_args args; + args.handle = handle; + args.ioctl_data = ioctl_data; + args.ioctl_type = ioctl_type; + if (ioctl_data != NULL) + { + /* Assign ioctl union discriminator */ + ioctl_data->disc = ioctl_type; + + /* In case the user hasn't filled in other disc fields, + automatically fill them in here */ + switch (ioctl_type) + { + case RPC_LOC_IOCTL_GET_API_VERSION: + break; + case RPC_LOC_IOCTL_SET_FIX_CRITERIA: + break; + case RPC_LOC_IOCTL_GET_FIX_CRITERIA: + break; + case RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE: + break; + case RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA: + break; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY: + break; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE: + break; + case RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD: + break; + case RPC_LOC_IOCTL_INJECT_UTC_TIME: + break; + case RPC_LOC_IOCTL_INJECT_RTC_VALUE: + break; + case RPC_LOC_IOCTL_INJECT_POSITION: + break; + case RPC_LOC_IOCTL_QUERY_ENGINE_STATE: + break; + case RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS: + break; + case RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS: + break; + case RPC_LOC_IOCTL_SET_ENGINE_LOCK: + break; + case RPC_LOC_IOCTL_GET_ENGINE_LOCK: + break; + case RPC_LOC_IOCTL_SET_SBAS_CONFIG: + break; + case RPC_LOC_IOCTL_GET_SBAS_CONFIG: + break; + case RPC_LOC_IOCTL_SET_NMEA_TYPES: + break; + case RPC_LOC_IOCTL_GET_NMEA_TYPES: + break; + case RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR: + args.ioctl_data->rpc_loc_ioctl_data_u_type_u.server_addr.addr_info.disc = + args.ioctl_data->rpc_loc_ioctl_data_u_type_u.server_addr.addr_type; + break; + case RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR: + break; + case RPC_LOC_IOCTL_SET_ON_DEMAND_LPM: + break; + case RPC_LOC_IOCTL_GET_ON_DEMAND_LPM: + break; + case RPC_LOC_IOCTL_DELETE_ASSIST_DATA: + break; + default: + break; + } /* switch */ + } /* ioctl_data != NULL */ + + rpc_loc_ioctl_rets rets; + enum clnt_stat stat = RPC_SUCCESS; + + EXIT_LOG_CALLFLOW(%s, loc_get_ioctl_type_name(ioctl_type)); + stat = RPC_FUNC_VERSION(rpc_loc_ioctl_, RPC_LOC_IOCTL_VERSION)(&args, &rets, loc_api_clnt); + LOC_GLUE_CHECK_RESULT(stat, int32); + + ret_val = (int32) rets.loc_ioctl_result; + + return ret_val; +} + +/* Returns 0 if error */ +int32 loc_api_null(void) +{ + LOC_GLUE_CHECK_INIT(int32); + + int32 rets; + enum clnt_stat stat = RPC_SUCCESS; + + clnt_unregister_reset_notification_cb(loc_api_clnt); + stat = RPC_FUNC_VERSION(rpc_loc_api_null_, RPC_LOC_API_NULL_VERSION)(NULL, &rets, loc_api_clnt); + LOC_GLUE_CHECK_RESULT(stat, int32); + + return (int32) rets; +} + +/*=========================================================================== + +FUNCTION loc_eng_ioctl + +DESCRIPTION + This function calls loc_ioctl and waits for the callback result before + returning back to the user. + +DEPENDENCIES + N/A + +RETURN VALUE + TRUE if successful + FALSE if failed + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data_ptr, + uint32 timeout_msec, + rpc_loc_ioctl_callback_s_type *cb_data_ptr +) +{ + int ret_val = RPC_LOC_API_SUCCESS; + + ret_val = loc_api_sync_ioctl(handle, ioctl_type, ioctl_data_ptr, timeout_msec, cb_data_ptr); + + LOC_LOGD("loc_eng_ioctl result: client = %d, ioctl_type = %s, returt %s\n", + (int32) handle, + loc_get_ioctl_type_name(ioctl_type), + loc_get_ioctl_status_name(ret_val) ); + + return ret_val; +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c new file mode 100755 index 00000000..e2a5786f --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c @@ -0,0 +1,510 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include + +#include +#include +#include "loc_api_sync_call.h" + +/* Logging */ +#define LOG_TAG "LocSvc_api_rpc_glue" +// #define LOG_NDDEBUG 0 +#include + +/*************************************************************************** + * DATA FOR ASYNCHRONOUS RPC PROCESSING + **************************************************************************/ +loc_sync_call_slot_array_s_type loc_sync_data; + +pthread_mutex_t loc_sync_call_mutex = PTHREAD_MUTEX_INITIALIZER; +boolean loc_sync_call_inited = 0; + +/*=========================================================================== + +FUNCTION loc_api_sync_call_init + +DESCRIPTION + Initialize this module + +DEPENDENCIES + N/A + +RETURN VALUE + none + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_api_sync_call_init() +{ + pthread_mutex_lock(&loc_sync_call_mutex); + if (loc_sync_call_inited == 1) { + pthread_mutex_unlock(&loc_sync_call_mutex); + return; + } + loc_sync_call_inited = 1; + + loc_sync_data.num_of_slots = LOC_SYNC_CALL_SLOTS_MAX; + + int i; + for (i = 0; i < loc_sync_data.num_of_slots; i++) + { + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; + + pthread_mutex_init(&slot->lock, NULL); + pthread_cond_init(&slot->loc_cb_arrived_cond, NULL); + + slot->not_available = 0; + slot->in_use = 0; + slot->loc_handle = -1; + slot->loc_cb_wait_event_mask = 0; /* event to wait */ + slot->loc_cb_received_event_mask = 0; /* received event */ + } + + pthread_mutex_unlock(&loc_sync_call_mutex); +} + +/*=========================================================================== + +FUNCTION loc_api_sync_call_destroy + +DESCRIPTION + Initialize this module + +DEPENDENCIES + N/A + +RETURN VALUE + none + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_api_sync_call_destroy() +{ + int i; + + pthread_mutex_lock(&loc_sync_call_mutex); + if (loc_sync_call_inited == 0) { + pthread_mutex_unlock(&loc_sync_call_mutex); + return; + } + loc_sync_call_inited = 0; + + for (i = 0; i < loc_sync_data.num_of_slots; i++) + { + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; + + pthread_mutex_lock(&slot->lock); + + slot->not_available = 1; + + pthread_mutex_unlock(&slot->lock); + + pthread_cond_destroy(&slot->loc_cb_arrived_cond); + pthread_mutex_destroy(&slot->lock); + } + + pthread_mutex_unlock(&loc_sync_call_mutex); +} + +/*=========================================================================== + +FUNCTION loc_match_callback + +DESCRIPTION + Checks if an awaited event has arrived + +RETURN VALUE + TRUE arrived + FALSE not matching + +===========================================================================*/ +static boolean loc_match_callback( + rpc_loc_event_mask_type wait_mask, + rpc_loc_ioctl_e_type wait_ioctl, + rpc_loc_event_mask_type event_mask, + const rpc_loc_event_payload_u_type *callback_payload +) +{ + if ((event_mask & wait_mask) == 0) return FALSE; + + if (event_mask != RPC_LOC_EVENT_IOCTL_REPORT || wait_ioctl == 0 || + ( (callback_payload != NULL) && + callback_payload->rpc_loc_event_payload_u_type_u.ioctl_report.type == wait_ioctl) ) + return TRUE; + + return FALSE; +} + +/*=========================================================================== + +FUNCTION loc_api_callback_process_sync_call + +DESCRIPTION + Wakes up blocked API calls to check if the needed callback has arrived + +DEPENDENCIES + N/A + +RETURN VALUE + none + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_api_callback_process_sync_call( + rpc_loc_client_handle_type loc_handle, /* handle of the client */ + rpc_loc_event_mask_type loc_event, /* event mask */ + const rpc_loc_event_payload_u_type* loc_event_payload /* payload */ +) +{ + int i; + + LOGV("loc_handle = 0x%lx, loc_event = 0x%lx", loc_handle, loc_event); + for (i = 0; i < loc_sync_data.num_of_slots; i++) + { + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; + + pthread_mutex_lock(&slot->lock); + + if (slot->in_use && + slot->signal_sent == 0 && + slot->loc_handle == loc_handle && + loc_match_callback(slot->loc_cb_wait_event_mask, slot->ioctl_type, loc_event, loc_event_payload)) + { + memcpy(&slot->loc_cb_received_payload, loc_event_payload, sizeof (rpc_loc_event_payload_u_type)); + + slot->loc_cb_received_event_mask = loc_event; + + LOGV("signal slot %d in_use %d, loc_handle 0x%lx, event_mask 0x%1x, ioctl_type %d", i, slot->in_use, slot->loc_handle, (int) slot->loc_cb_wait_event_mask, (int) slot->ioctl_type); + pthread_cond_signal(&slot->loc_cb_arrived_cond); + slot->signal_sent = 1; + + pthread_mutex_unlock(&slot->lock); + break; + } else { + /* do nothing */ + } + + pthread_mutex_unlock(&slot->lock); + } +} + +/*=========================================================================== + +FUNCTION loc_lock_a_slot + +DESCRIPTION + Allocates a buffer slot for the synchronous API call + +DEPENDENCIES + N/A + +RETURN VALUE + Select ID (>=0) : successful + -1 : buffer full + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_lock_a_slot() +{ + int i, select_id = -1; /* no free buffer */ + + for (i = 0; i < loc_sync_data.num_of_slots; i++) + { + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; + if (pthread_mutex_trylock(&slot->lock) == EBUSY) + { + LOGV("trylock EBUSY : %d", i); + continue; + } + + if (!slot->in_use && !slot->not_available) + { + select_id = i; + slot->in_use = 1; + slot->signal_sent = 0; + /* Return from here and leave the mutex locked. + * will unlock it in loc_unlock_slot() + */ + break; + } + /* LOGV("slot %d in_use = %d, not_available = %d : %d", i, slot->in_use, slot->not_available, i); */ + pthread_mutex_unlock(&slot->lock); + } + + return select_id; +} + +/*=========================================================================== + +FUNCTION loc_unlock_slot + +DESCRIPTION + Frees a buffer slot after the synchronous API call + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_unlock_slot(int select_id) +{ + loc_sync_data.slots[select_id].in_use = 0; + + pthread_mutex_unlock(&loc_sync_data.slots[select_id].lock); +} + +/*=========================================================================== + +FUNCTION loc_api_save_callback + +DESCRIPTION + Selects which callback or IOCTL event to wait for. + + The event_mask specifies the event(s). If it is RPC_LOC_EVENT_IOCTL_REPORT, + then ioctl_type specifies the IOCTL event. + + If ioctl_type is non-zero, RPC_LOC_EVENT_IOCTL_REPORT is automatically added. + +DEPENDENCIES + N/A + +RETURN VALUE + Select ID (>=0) : successful + -1 : out of buffer + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_api_save_callback( + int select_id, /* Selected slot */ + rpc_loc_client_handle_type loc_handle, /* Client handle */ + rpc_loc_event_mask_type event_mask, /* Event mask to wait for */ + rpc_loc_ioctl_e_type ioctl_type /* IOCTL type to wait for */ +) +{ + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[select_id]; + + slot->loc_handle = loc_handle; + + slot->loc_cb_wait_event_mask = event_mask; + slot->ioctl_type = ioctl_type; + if (ioctl_type) slot->loc_cb_wait_event_mask |= RPC_LOC_EVENT_IOCTL_REPORT; + + return; +} + +/*=========================================================================== + +FUNCTION loc_save_user_payload + +DESCRIPTION + Saves received payload into user data structures + +RETURN VALUE + None + +===========================================================================*/ +static void loc_save_user_payload( + rpc_loc_event_payload_u_type *user_cb_payload, + rpc_loc_ioctl_callback_s_type *user_ioctl_buffer, + const rpc_loc_event_payload_u_type *received_cb_payload +) +{ + if (user_cb_payload) + { + memcpy(user_cb_payload, received_cb_payload, + sizeof (rpc_loc_event_payload_u_type)); + } + if (user_ioctl_buffer) + { + memcpy(user_ioctl_buffer, + &received_cb_payload->rpc_loc_event_payload_u_type_u.ioctl_report, + sizeof *user_ioctl_buffer); + } +} + +/*=========================================================================== + +FUNCTION loc_api_wait_callback + +DESCRIPTION + Waits for a selected callback. The wait expires in timeout_seconds seconds. + + If the function is called before an existing wait has finished, it will + immediately return EBUSY. + +DEPENDENCIES + N/A + +RETURN VALUE + RPC_LOC_API_SUCCESS if successful (0) + RPC_LOC_API_TIMEOUT if timed out + RPC_LOC_API_ENGINE_BUSY if already in a wait + RPC_LOC_API_INVALID_PARAMETER if callback is not yet selected + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_api_wait_callback( + int select_id, /* ID from loc_select_callback() */ + int timeout_seconds, /* Timeout in this number of seconds */ + rpc_loc_event_payload_u_type *callback_payload, /* Pointer to callback payload buffer, can be NULL */ + rpc_loc_ioctl_callback_s_type *ioctl_payload /* Pointer to IOCTL payload, can be NULL */ +) +{ + int ret_val = RPC_LOC_API_SUCCESS; /* the return value of this function: 0 = no error */ + int rc; /* return code from pthread calls */ + + struct timespec expire_time; + + loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[select_id]; + + clock_gettime(CLOCK_REALTIME, &expire_time); + expire_time.tv_sec += timeout_seconds; + + /* Waiting */ + while (slot->signal_sent == 0 && rc != ETIMEDOUT) { + rc = pthread_cond_timedwait(&slot->loc_cb_arrived_cond, + &slot->lock, &expire_time); + } + + if (rc == ETIMEDOUT) + { + ret_val = RPC_LOC_API_TIMEOUT; /* Timed out */ + LOGE("TIMEOUT: %d", select_id); + } + else { + /* Obtained the first awaited callback */ + ret_val = RPC_LOC_API_SUCCESS; /* Successful */ + loc_save_user_payload(callback_payload, ioctl_payload, &slot->loc_cb_received_payload); + } + + return ret_val; +} + +/*=========================================================================== + +FUNCTION loc_api_sync_ioctl + +DESCRIPTION + Synchronous IOCTL call (reentrant version) + +DEPENDENCIES + N/A + +RETURN VALUE + Loc API error code (0 = success) + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_api_sync_ioctl +( + rpc_loc_client_handle_type handle, + rpc_loc_ioctl_e_type ioctl_type, + rpc_loc_ioctl_data_u_type* ioctl_data_ptr, + uint32 timeout_msec, + rpc_loc_ioctl_callback_s_type *cb_data_ptr +) +{ + int rc = -1; + int select_id; + rpc_loc_ioctl_callback_s_type callback_data; + + select_id = loc_lock_a_slot(); + + if (select_id < 0 || select_id >= loc_sync_data.num_of_slots) + { + LOGE("slot not available ioctl_type = %s", + loc_get_ioctl_type_name(ioctl_type)); + return rc; + } + + // Select the callback we are waiting for + loc_api_save_callback(select_id, handle, 0, ioctl_type); + + rc = loc_ioctl(handle, ioctl_type, ioctl_data_ptr); + + if (rc != RPC_LOC_API_SUCCESS) + { + LOGE("loc_ioctl failed select_id = %d, ioctl_type %s, returned %s", + select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); + } + else { + LOGV("select_id = %d, ioctl_type %d, returned RPC_LOC_API_SUCCESS", + select_id, ioctl_type); + // Wait for the callback of loc_ioctl + if ((rc = loc_api_wait_callback(select_id, timeout_msec / 1000, NULL, &callback_data)) != 0) + { + // Callback waiting failed + LOGE("callback wait failed select_id = %d, ioctl_type %s, returned %s", + select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); + } + else + { + if (cb_data_ptr) memcpy(cb_data_ptr, &callback_data, sizeof *cb_data_ptr); + if (callback_data.status != RPC_LOC_API_SUCCESS) + { + rc = callback_data.status; + LOGE("callback status failed select_id = %d, ioctl_type %s, returned %s", + select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); + } else { + LOGV("callback status success select_id = %d, ioctl_type %d, returned %d", + select_id, ioctl_type, rc); + } + } /* wait callback */ + } /* loc_ioctl */ + + loc_unlock_slot(select_id); + + return rc; +} + + diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c new file mode 100755 index 00000000..b257fb81 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c @@ -0,0 +1,86 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "rpc/rpc.h" + +/* Include RPC headers */ +#ifdef USE_LOCAL_RPC +#include "rpc_inc/loc_api_common.h" +#include "rpc_inc/loc_api.h" +#include "rpc_inc/loc_api_cb.h" +#endif + +#ifdef USE_QCOM_AUTO_RPC +#include "loc_api_rpcgen_rpc.h" +#include "loc_api_rpcgen_common_rpc.h" +#include "loc_api_rpcgen_cb_rpc.h" +#endif + +#include "rpc_inc/loc_api_fixup.h" +#include "loc_apicb_appinit.h" + +#define RPC_FUNC_VERSION_BASE(a,b) a ## b +#define RPC_CB_FUNC_VERS(a,b) RPC_FUNC_VERSION_BASE(a,b) + +static SVCXPRT* svrPort = NULL; + +extern void RPC_CB_FUNC_VERS(loc_apicbprog_,LOC_APICBVERS_0001)(struct svc_req *rqstp, register SVCXPRT *transp); + +int loc_apicb_app_init(void) +{ + + /* Register a callback server to use the loc_apicbprog_* function */ + if (svrPort == NULL) { + svrPort = svcrtr_create(); + } + if (!svrPort) return -1; + + xprt_register(svrPort); + if(svc_register(svrPort, LOC_APICBPROG, LOC_APICBVERS_0001, RPC_CB_FUNC_VERS(loc_apicbprog_,LOC_APICBVERS_0001),0)) + { + return 0; + } + else + { + return -1; + } +} + +void loc_apicb_app_deinit(void) +{ + if (svrPort == NULL) + { + return; + } + + svc_unregister(svrPort, LOC_APICBPROG, LOC_APICBVERS_0001); + xprt_unregister(svrPort); + svc_destroy(svrPort); + svrPort = NULL; +} + diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk new file mode 100755 index 00000000..abd15c8f --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk @@ -0,0 +1,35 @@ +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +# functions +LOC_RPCGEN_APIS_PATH := $(TARGET_OUT_INTERMEDIATES)/loc_api/libloc_api_rpcgen_intermediates +LOC_RPCGEN_APIS_PATH_FL := ../../../../../$(TARGET_OUT_INTERMEDIATES)/loc_api/libloc_api_rpcgen_intermediates + +LOCAL_MODULE := libloc_api_rpcgen + +LOCAL_SHARED_LIBRARIES := \ + librpc \ + libcommondefs + +LOCAL_SRC_FILES += \ + src/loc_api_rpcgen_cb_xdr.c \ + src/loc_api_rpcgen_common_xdr.c \ + src/loc_api_rpcgen_cb_svc.c \ + src/loc_api_rpcgen_clnt.c \ + src/loc_api_rpcgen_xdr.c + +LOCAL_C_INCLUDES += hardware/msm7k/librpc +LOCAL_C_INCLUDES += $(LOC_RPCGEN_APIS_PATH)/../../SHARED_LIBRARIES/libcommondefs_intermediates/inc +LOCAL_C_INCLUDES += $(LOCAL_PATH)/inc +LOCAL_C_INCLUDES += $(TARGET_OUT_HEADERS)/libcommondefs/rpcgen/inc + +LOCAL_COPY_HEADERS_TO := loc_api/rpcgen/inc +LOCAL_COPY_HEADERS := inc/loc_api_rpcgen_rpc.h +LOCAL_COPY_HEADERS += inc/loc_api_rpcgen_common_rpc.h +LOCAL_COPY_HEADERS += inc/loc_api_rpcgen_cb_rpc.h +LOCAL_COPY_HEADERS += inc/loc_apicb_appinit.h + +LOCAL_LDLIBS += -lpthread +LOCAL_PRELINK_MODULE := false +include $(BUILD_STATIC_LIBRARY) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h new file mode 100755 index 00000000..47478e80 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h @@ -0,0 +1,156 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#ifndef _LOC_API_CB_RPC_H_RPCGEN +#define _LOC_API_CB_RPC_H_RPCGEN + +#include "librpc.h" +#include "commondefs_rpcgen_rpc.h" +#include "loc_api_rpcgen_common_rpc.h" + +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +struct rpc_loc_event_cb_f_type_args { + rpc_uint32 cb_id; + rpc_loc_client_handle_type loc_handle; + rpc_loc_event_mask_type loc_event; + rpc_loc_event_payload_u_type *loc_event_payload; +}; +typedef struct rpc_loc_event_cb_f_type_args rpc_loc_event_cb_f_type_args; + +struct rpc_loc_event_cb_f_type_rets { + rpc_int32 loc_event_cb_f_type_result; +}; +typedef struct rpc_loc_event_cb_f_type_rets rpc_loc_event_cb_f_type_rets; +#define LOC_APICBVERS 0x00050006 + +#define LOC_APICBPROG 0x3100008C +#define LOC_APICBVERS_0001 0x00050001 + +#if defined(__STDC__) || defined(__cplusplus) +#define rpc_loc_event_cb_f_type 1 +extern enum clnt_stat rpc_loc_event_cb_f_type_0x00050001(rpc_loc_event_cb_f_type_args *, rpc_loc_event_cb_f_type_rets *, CLIENT *); +extern bool_t rpc_loc_event_cb_f_type_0x00050001_svc(rpc_loc_event_cb_f_type_args *, rpc_loc_event_cb_f_type_rets *, struct svc_req *); +extern int loc_apicbprog_0x00050001_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +#define rpc_loc_event_cb_f_type 1 +extern enum clnt_stat rpc_loc_event_cb_f_type_0x00050001(); +extern bool_t rpc_loc_event_cb_f_type_0x00050001_svc(); +extern int loc_apicbprog_0x00050001_freeresult (); +#endif /* K&R C */ +#define LOC_APICBVERS_0002 0x00050002 + +#if defined(__STDC__) || defined(__cplusplus) +#define rpc_loc_api_cb_null 0xffffff00 +extern enum clnt_stat rpc_loc_api_cb_null_0x00050002(void *, int *, CLIENT *); +extern bool_t rpc_loc_api_cb_null_0x00050002_svc(void *, int *, struct svc_req *); +extern int loc_apicbprog_0x00050002_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +#define rpc_loc_api_cb_null 0xffffff00 +extern enum clnt_stat rpc_loc_api_cb_null_0x00050002(); +extern bool_t rpc_loc_api_cb_null_0x00050002_svc(); +extern int loc_apicbprog_0x00050002_freeresult (); +#endif /* K&R C */ +#define LOC_APICBVERS_0003 0x00050003 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_cb_null_0x00050003(void *, int *, CLIENT *); +extern bool_t rpc_loc_api_cb_null_0x00050003_svc(void *, int *, struct svc_req *); +extern int loc_apicbprog_0x00050003_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_cb_null_0x00050003(); +extern bool_t rpc_loc_api_cb_null_0x00050003_svc(); +extern int loc_apicbprog_0x00050003_freeresult (); +#endif /* K&R C */ +#define LOC_APICBVERS_0004 0x00050004 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_cb_null_0x00050004(void *, int *, CLIENT *); +extern bool_t rpc_loc_api_cb_null_0x00050004_svc(void *, int *, struct svc_req *); +extern int loc_apicbprog_0x00050004_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_cb_null_0x00050004(); +extern bool_t rpc_loc_api_cb_null_0x00050004_svc(); +extern int loc_apicbprog_0x00050004_freeresult (); +#endif /* K&R C */ +#define LOC_APICBVERS_0005 0x00050005 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_cb_null_0x00050005(void *, int *, CLIENT *); +extern bool_t rpc_loc_api_cb_null_0x00050005_svc(void *, int *, struct svc_req *); +extern int loc_apicbprog_0x00050005_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_cb_null_0x00050005(); +extern bool_t rpc_loc_api_cb_null_0x00050005_svc(); +extern int loc_apicbprog_0x00050005_freeresult (); +#endif /* K&R C */ +#define LOC_APICBVERS_0006 0x00050006 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_cb_null_0x00050006(void *, int *, CLIENT *); +extern bool_t rpc_loc_api_cb_null_0x00050006_svc(void *, int *, struct svc_req *); +extern int loc_apicbprog_0x00050006_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_cb_null_0x00050006(); +extern bool_t rpc_loc_api_cb_null_0x00050006_svc(); +extern int loc_apicbprog_0x00050006_freeresult (); +#endif /* K&R C */ + +/* the xdr functions */ + +#if defined(__STDC__) || defined(__cplusplus) +extern bool_t xdr_rpc_loc_event_cb_f_type_args (XDR *, rpc_loc_event_cb_f_type_args*); +extern bool_t xdr_rpc_loc_event_cb_f_type_rets (XDR *, rpc_loc_event_cb_f_type_rets*); + +#else /* K&R C */ +extern bool_t xdr_rpc_loc_event_cb_f_type_args (); +extern bool_t xdr_rpc_loc_event_cb_f_type_rets (); + +#endif /* K&R C */ + +#ifdef __cplusplus +} +#endif + +#endif /* !_LOC_API_CB_RPC_H_RPCGEN */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h new file mode 100755 index 00000000..507103ce --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h @@ -0,0 +1,1261 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#ifndef _LOC_API_COMMON_RPC_H_RPCGEN +#define _LOC_API_COMMON_RPC_H_RPCGEN + +#include "librpc.h" +#include "commondefs_rpcgen_rpc.h" + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#define LOC_API_TOOLVERS 0x00040030 +#define LOC_API_FEATURES 0x00000001 +#define RPC_LOC_EVENT_STATUS_REPORT 0x00000100 +#define RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST 0x00000020 +#define RPC_LOC_EVENT_WPS_NEEDED_REQUEST 0x00000200 +#define RPC_LOC_EVENT_SATELLITE_REPORT 0x00000002 +#define RPC_LOC_EVENT_PARSED_POSITION_REPORT 0x00000001 +#define RPC_LOC_EVENT_RESERVED 0x8000000000000000 +#define RPC_LOC_EVENT_LOCATION_SERVER_REQUEST 0x00000040 +#define RPC_LOC_EVENT_NMEA_POSITION_REPORT 0x00000008 +#define RPC_LOC_EVENT_IOCTL_REPORT 0x00000080 +#define RPC_LOC_EVENT_NMEA_1HZ_REPORT 0x00000004 +#define RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST 0x00000010 +#define RPC_LOC_API_CB_NULL_VERSION 0x00050002 +#define RPC_LOC_EVENT_CB_F_TYPE_VERSION 0x00050001 +#define RPC_LOC_API_API_VERSIONS_VERSION 0x00050001 +#define RPC_LOC_STOP_FIX_VERSION 0x00050001 +#define RPC_LOC_START_FIX_VERSION 0x00050001 +#define RPC_LOC_IOCTL_VERSION 0x00050001 +#define RPC_LOC_CLOSE_VERSION 0x00050001 +#define RPC_LOC_API_RPC_GLUE_CODE_INFO_REMOTE_VERSION 0x00050001 +#define RPC_LOC_OPEN_VERSION 0x00050001 +#define RPC_LOC_API_NULL_VERSION 0x00050001 +#define RPC_LOC_API_API_MAJOR_NUM 0x0005 +#define RPC_LOC_APIAPI_VERSION_IS_HASHKEY 0 + +typedef rpc_int32 rpc_loc_client_handle_type; + +typedef rpc_uint64 rpc_loc_event_mask_type; + +typedef rpc_uint64 rpc_loc_position_valid_mask_type; + +typedef rpc_uint32 rpc_loc_pos_technology_mask_type; + +enum rpc_loc_session_status_e_type { + RPC_LOC_SESS_STATUS_SUCCESS = 0, + RPC_LOC_SESS_STATUS_IN_PROGESS = 1, + RPC_LOC_SESS_STATUS_GENERAL_FAILURE = 2, + RPC_LOC_SESS_STATUS_TIMEOUT = 3, + RPC_LOC_SESS_STATUS_USER_END = 4, + RPC_LOC_SESS_STATUS_BAD_PARAMETER = 5, + RPC_LOC_SESS_STATUS_PHONE_OFFLINE = 6, + RPC_LOC_SESS_STATUS_ENGINE_LOCKED = 7, + RPC_LOC_SESS_STATUS_MAX = 268435456, +}; +typedef enum rpc_loc_session_status_e_type rpc_loc_session_status_e_type; + +struct rpc_loc_calendar_time_s_type { + rpc_uint16 year; + u_char month; + u_char day_of_week; + u_char day; + u_char hour; + u_char minute; + u_char second; + rpc_uint16 millisecond; +}; +typedef struct rpc_loc_calendar_time_s_type rpc_loc_calendar_time_s_type; + +struct rpc_loc_parsed_position_s_type { + rpc_loc_position_valid_mask_type valid_mask; + rpc_loc_session_status_e_type session_status; + rpc_loc_calendar_time_s_type timestamp_calendar; + rpc_uint64 timestamp_utc; + rpc_uint8 leap_seconds; + float time_unc; + double latitude; + double longitude; + float altitude_wrt_ellipsoid; + float altitude_wrt_mean_sea_level; + float speed_horizontal; + float speed_vertical; + float heading; + float hor_unc_circular; + float hor_unc_ellipse_semi_major; + float hor_unc_ellipse_semi_minor; + float hor_unc_ellipse_orient_azimuth; + float vert_unc; + float speed_unc; + float heading_unc; + u_char confidence_horizontal; + u_char confidence_vertical; + float magnetic_deviation; + rpc_loc_pos_technology_mask_type technology_mask; +}; +typedef struct rpc_loc_parsed_position_s_type rpc_loc_parsed_position_s_type; + +enum rpc_loc_sv_system_e_type { + RPC_LOC_SV_SYSTEM_GPS = 1, + RPC_LOC_SV_SYSTEM_GALILEO = 2, + RPC_LOC_SV_SYSTEM_SBAS = 3, + RPC_LOC_SV_SYSTEM_COMPASS = 4, + RPC_LOC_SV_SYSTEM_GLONASS = 5, + RPC_LOC_SV_SYSTEM_MAX = 268435456, +}; +typedef enum rpc_loc_sv_system_e_type rpc_loc_sv_system_e_type; + +enum rpc_loc_sv_status_e_type { + RPC_LOC_SV_STATUS_IDLE = 1, + RPC_LOC_SV_STATUS_SEARCH = 2, + RPC_LOC_SV_STATUS_TRACK = 3, + RPC_LOC_SV_STATUS_MAX = 268435456, +}; +typedef enum rpc_loc_sv_status_e_type rpc_loc_sv_status_e_type; + +typedef rpc_uint32 rpc_loc_sv_info_valid_mask_type; + +struct rpc_loc_sv_info_s_type { + rpc_loc_sv_info_valid_mask_type valid_mask; + rpc_loc_sv_system_e_type system; + rpc_uint8 prn; + rpc_uint8 health_status; + rpc_loc_sv_status_e_type process_status; + rpc_boolean has_eph; + rpc_boolean has_alm; + float elevation; + float azimuth; + float snr; +}; +typedef struct rpc_loc_sv_info_s_type rpc_loc_sv_info_s_type; + +typedef rpc_uint32 rpc_loc_gnss_info_valid_mask_type; + +struct rpc_loc_gnss_info_s_type { + rpc_loc_gnss_info_valid_mask_type valid_mask; + float position_dop; + float horizontal_dop; + float vertical_dop; + rpc_boolean altitude_assumed; + rpc_uint16 sv_count; + struct { + u_int sv_list_len; + rpc_loc_sv_info_s_type *sv_list_val; + } sv_list; +}; +typedef struct rpc_loc_gnss_info_s_type rpc_loc_gnss_info_s_type; + +struct rpc_loc_nmea_report_s_type { + rpc_uint16 length; + char nmea_sentences[200]; +}; +typedef struct rpc_loc_nmea_report_s_type rpc_loc_nmea_report_s_type; + +enum rpc_loc_status_event_e_type { + RPC_LOC_STATUS_EVENT_ENGINE_STATE = 1, + RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE = 2, + RPC_LOC_STATUS_EVENT_MAX = 268435456, +}; +typedef enum rpc_loc_status_event_e_type rpc_loc_status_event_e_type; + +enum rpc_loc_engine_state_e_type { + RPC_LOC_ENGINE_STATE_ON = 1, + RPC_LOC_ENGINE_STATE_OFF = 2, + RPC_LOC_ENGINE_STATE_MAX = 268435456, +}; +typedef enum rpc_loc_engine_state_e_type rpc_loc_engine_state_e_type; + +enum rpc_loc_fix_session_state_e_type { + RPC_LOC_FIX_SESSION_STATE_BEGIN = 1, + RPC_LOC_FIX_SESSION_STATE_END = 2, + RPC_LOC_FIX_SESSION_STATE_MAX = 268435456, +}; +typedef enum rpc_loc_fix_session_state_e_type rpc_loc_fix_session_state_e_type; + +struct rpc_loc_status_event_payload_u_type { + rpc_loc_status_event_e_type disc; + union { + rpc_loc_engine_state_e_type engine_state; + rpc_loc_fix_session_state_e_type fix_session_state; + } rpc_loc_status_event_payload_u_type_u; +}; +typedef struct rpc_loc_status_event_payload_u_type rpc_loc_status_event_payload_u_type; + +struct rpc_loc_status_event_s_type { + rpc_loc_status_event_e_type event; + rpc_loc_status_event_payload_u_type payload; +}; +typedef struct rpc_loc_status_event_s_type rpc_loc_status_event_s_type; + +enum rpc_loc_server_addr_e_type { + RPC_LOC_SERVER_ADDR_IPV4 = 1, + RPC_LOC_SERVER_ADDR_URL = 2, + RPC_LOC_SERVER_ADDR_IPV6 = 3, + RPC_LOC_SERVER_ADDR_MAX = 268435456, +}; +typedef enum rpc_loc_server_addr_e_type rpc_loc_server_addr_e_type; + +struct rpc_loc_server_addr_ipv4_type { + rpc_uint32 addr; + rpc_uint16 port; +}; +typedef struct rpc_loc_server_addr_ipv4_type rpc_loc_server_addr_ipv4_type; + +struct rpc_loc_server_addr_url_type { + rpc_uint16 length; + char addr[256]; +}; +typedef struct rpc_loc_server_addr_url_type rpc_loc_server_addr_url_type; + +struct rpc_loc_server_addr_ipv6_type { + rpc_uint16 addr[8]; + rpc_uint32 port; +}; +typedef struct rpc_loc_server_addr_ipv6_type rpc_loc_server_addr_ipv6_type; + +struct rpc_loc_server_addr_u_type { + rpc_loc_server_addr_e_type disc; + union { + rpc_loc_server_addr_ipv4_type ipv4; + rpc_loc_server_addr_url_type url; + rpc_loc_server_addr_ipv6_type ipv6; + } rpc_loc_server_addr_u_type_u; +}; +typedef struct rpc_loc_server_addr_u_type rpc_loc_server_addr_u_type; + +struct rpc_loc_server_info_s_type { + rpc_loc_server_addr_e_type addr_type; + rpc_loc_server_addr_u_type addr_info; +}; +typedef struct rpc_loc_server_info_s_type rpc_loc_server_info_s_type; + +enum rpc_loc_ni_notify_verify_e_type { + RPC_LOC_NI_USER_NO_NOTIFY_NO_VERIFY = 1, + RPC_LOC_NI_USER_NOTIFY_ONLY = 2, + RPC_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP = 3, + RPC_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP = 4, + RPC_LOC_NI_USER_PRIVACY_OVERRIDE = 5, + RPC_LOC_NI_USER_NOTIFY_VERITY_TYPE_MAX = 268435456, +}; +typedef enum rpc_loc_ni_notify_verify_e_type rpc_loc_ni_notify_verify_e_type; + +enum rpc_loc_ni_event_e_type { + RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ = 1, + RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ = 2, + RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ = 3, + RPC_LOC_NI_EVENT_VX_SERVICE_INTERACTION_REQ = 4, + RPC_LOC_NI_EVENT_MAX = 268435456, +}; +typedef enum rpc_loc_ni_event_e_type rpc_loc_ni_event_e_type; + +enum rpc_loc_ni_datacoding_scheme_e_type { + RPC_LOC_NI_PRESUPL_ISO646IRV = 0, + RPC_LOC_NI_PRESUPL_ISO8859 = 1, + RPC_LOC_NI_PRESUPL_UTF8 = 2, + RPC_LOC_NI_PRESUPL_UTF16 = 3, + RPC_LOC_NI_PRESUPL_UCS2 = 4, + RPC_LOC_NI_PRESUPL_GSM_DEFAULT = 5, + RPC_LOC_NI_PRESUPL_SHIFT_JIS = 6, + RPC_LOC_NI_PRESUPL_JIS = 7, + RPC_LOC_NI_PRESUPL_EUC = 8, + RPC_LOC_NI_PRESUPL_GB2312 = 9, + RPC_LOC_NI_PRESUPL_CNS11643 = 10, + RPC_LOC_NI_PRESUPL_KSC1001 = 11, + RPC_LOC_NI_PRESUPL_ENCODING_UNKNOWN = 2147483647, + RPC_LOC_NI_SS_GERMAN = 12, + RPC_LOC_NI_SS_ENGLISH = 13, + RPC_LOC_NI_SS_ITALIAN = 14, + RPC_LOC_NI_SS_FRENCH = 15, + RPC_LOC_NI_SS_SPANISH = 16, + RPC_LOC_NI_SS_DUTCH = 17, + RPC_LOC_NI_SS_SWEDISH = 18, + RPC_LOC_NI_SS_DANISH = 19, + RPC_LOC_NI_SS_PORTUGUESE = 20, + RPC_LOC_NI_SS_FINNISH = 21, + RPC_LOC_NI_SS_NORWEGIAN = 22, + RPC_LOC_NI_SS_GREEK = 23, + RPC_LOC_NI_SS_TURKISH = 24, + RPC_LOC_NI_SS_HUNGARIAN = 25, + RPC_LOC_NI_SS_POLISH = 26, + RPC_LOC_NI_SS_LANGUAGE_UNSPEC = 27, + RPC_LOC_NI_SUPL_UTF8 = 28, + RPC_LOC_NI_SUPL_UCS2 = 29, + RPC_LOC_NI_SUPL_GSM_DEFAULT = 30, + RPC_LOC_NI_SUPL_ENCODING_UNKNOWN = 2147483647, +}; +typedef enum rpc_loc_ni_datacoding_scheme_e_type rpc_loc_ni_datacoding_scheme_e_type; + +enum rpc_loc_ni_vx_requester_id_encoding_scheme_e_type { + RPC_LOC_NI_VX_OCTET = 0, + RPC_LOC_NI_VX_EXN_PROTOCOL_MSG = 1, + RPC_LOC_NI_VX_ASCII = 2, + RPC_LOC_NI_VX_IA5 = 3, + RPC_LOC_NI_VX_UNICODE = 4, + RPC_LOC_NI_VX_SHIFT_JIS = 5, + RPC_LOC_NI_VX_KOREAN = 6, + RPC_LOC_NI_VX_LATIN_HEBREW = 7, + RPC_LOC_NI_VX_LATIN = 8, + RPC_LOC_NI_VX_GSM = 9, + RPC_LOC_NI_VX_ENCODING_TYPE_MAX = 268435456, +}; +typedef enum rpc_loc_ni_vx_requester_id_encoding_scheme_e_type rpc_loc_ni_vx_requester_id_encoding_scheme_e_type; + +enum rpc_loc_ni_vx_pos_mode_e_type { + RPC_LOC_VX_MS_ASSISTED_ONLY = 1, + RPC_LOC_VX_MS_BASED_ONLY = 2, + RPC_LOC_VX_MS_ASSISTED_PREF_MSBASED_ALLWD = 3, + RPC_LOC_VX_MS_BASED_PREF_ASSISTED_ALLWD = 4, + RPC_LOC_VX_POS_MODE_MAX = 268435456, +}; +typedef enum rpc_loc_ni_vx_pos_mode_e_type rpc_loc_ni_vx_pos_mode_e_type; + +struct rpc_loc_ni_vx_requester_id_s_type { + u_char requester_id_length; + char requester_id[200]; +}; +typedef struct rpc_loc_ni_vx_requester_id_s_type rpc_loc_ni_vx_requester_id_s_type; + +struct rpc_loc_ni_vx_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + u_char pos_qos_incl; + u_char pos_qos; + rpc_uint32 num_fixes; + rpc_uint32 tbf; + rpc_loc_ni_vx_pos_mode_e_type pos_mode; + rpc_loc_ni_vx_requester_id_encoding_scheme_e_type encoding_scheme; + rpc_loc_ni_vx_requester_id_s_type requester_id; + rpc_uint16 user_resp_timer_val; +}; +typedef struct rpc_loc_ni_vx_notify_verify_req_s_type rpc_loc_ni_vx_notify_verify_req_s_type; + +enum rpc_loc_ni_supl_pos_method_e_type { + RPC_LOC_NI_POSMETHOD_AGPS_SETASSISTED = 1, + RPC_LOC_NI_POSMETHOD_AGPS_SETBASED = 2, + RPC_LOC_NI_POSMETHOD_AGPS_SETASSISTED_PREF = 3, + RPC_LOC_NI_POSMETHOD_AGPS_SETBASED_PREF = 4, + RPC_LOC_NI_POSMETHOD_AUTONOMOUS_GPS = 5, + RPC_LOC_NI_POSMETHOD_AFLT = 6, + RPC_LOC_NI_POSMETHOD_ECID = 7, + RPC_LOC_NI_POSMETHOD_EOTD = 8, + RPC_LOC_NI_POSMETHOD_OTDOA = 9, + RPC_LOC_NI_POSMETHOD_NO_POSITION = 10, + RPC_LOC_NI_POSMETHOD_MAX = 268435456, +}; +typedef enum rpc_loc_ni_supl_pos_method_e_type rpc_loc_ni_supl_pos_method_e_type; + +struct rpc_loc_ni_supl_slp_session_id_s_type { + u_char presence; + char session_id[4]; + rpc_loc_server_info_s_type slp_address; +}; +typedef struct rpc_loc_ni_supl_slp_session_id_s_type rpc_loc_ni_supl_slp_session_id_s_type; + +struct rpc_loc_ni_requestor_id_s_type { + u_char data_coding_scheme; + char requestor_id_string[200]; + u_char string_len; +}; +typedef struct rpc_loc_ni_requestor_id_s_type rpc_loc_ni_requestor_id_s_type; + +struct rpc_loc_ni_supl_client_name_s_type { + u_char data_coding_scheme; + char client_name_string[64]; + u_char string_len; +}; +typedef struct rpc_loc_ni_supl_client_name_s_type rpc_loc_ni_supl_client_name_s_type; + +struct rpc_loc_ni_supl_qop_s_type { + u_char bit_mask; + u_char horacc; + u_char veracc; + rpc_uint16 maxLocAge; + u_char delay; +}; +typedef struct rpc_loc_ni_supl_qop_s_type rpc_loc_ni_supl_qop_s_type; + +struct rpc_loc_ni_supl_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + rpc_uint16 flags; + rpc_loc_ni_supl_slp_session_id_s_type supl_slp_session_id; + char supl_hash[8]; + rpc_loc_ni_datacoding_scheme_e_type datacoding_scheme; + rpc_loc_ni_supl_pos_method_e_type pos_method; + rpc_loc_ni_requestor_id_s_type requestor_id; + rpc_loc_ni_supl_client_name_s_type client_name; + rpc_loc_ni_supl_qop_s_type supl_qop; + rpc_uint16 user_response_timer; +}; +typedef struct rpc_loc_ni_supl_notify_verify_req_s_type rpc_loc_ni_supl_notify_verify_req_s_type; + +struct rpc_loc_ni_ext_client_address_s_type { + u_char ext_client_address_len; + char ext_client_address[20]; +}; +typedef struct rpc_loc_ni_ext_client_address_s_type rpc_loc_ni_ext_client_address_s_type; + +enum rpc_loc_ni_location_type_e_type { + RPC_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION = 1, + RPC_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION = 2, + RPC_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION = 3, + RPC_LOC_NI_LOCATIONTYPE_MAX = 268435456, +}; +typedef enum rpc_loc_ni_location_type_e_type rpc_loc_ni_location_type_e_type; + +struct rpc_loc_ni_deferred_location_s_type { + u_char unused_bits; + u_char ms_available; +}; +typedef struct rpc_loc_ni_deferred_location_s_type rpc_loc_ni_deferred_location_s_type; + +struct rpc_loc_ni_codeword_string_s_type { + u_char data_coding_scheme; + char lcs_codeword_string[20]; + u_char string_len; +}; +typedef struct rpc_loc_ni_codeword_string_s_type rpc_loc_ni_codeword_string_s_type; + +struct rpc_loc_ni_service_type_id_s_type { + u_char lcs_service_type_id; +}; +typedef struct rpc_loc_ni_service_type_id_s_type rpc_loc_ni_service_type_id_s_type; + +struct rpc_loc_ni_umts_cp_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + u_char invoke_id; + rpc_uint16 flags; + u_char notification_length; + char notification_text[64]; + rpc_loc_ni_datacoding_scheme_e_type datacoding_scheme; + rpc_loc_ni_ext_client_address_s_type ext_client_address_data; + rpc_loc_ni_location_type_e_type location_type; + rpc_loc_ni_deferred_location_s_type deferred_location; + rpc_loc_ni_requestor_id_s_type requestor_id; + rpc_loc_ni_codeword_string_s_type codeword_string; + rpc_loc_ni_service_type_id_s_type service_type_id; + rpc_uint16 user_response_timer; +}; +typedef struct rpc_loc_ni_umts_cp_notify_verify_req_s_type rpc_loc_ni_umts_cp_notify_verify_req_s_type; + +enum rpc_loc_ni_service_interaction_e_type { + RPC_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO = 1, + RPC_LOC_NI_SERVICE_INTERACTION_MAX = 268435456, +}; +typedef enum rpc_loc_ni_service_interaction_e_type rpc_loc_ni_service_interaction_e_type; + +struct rpc_loc_ni_vx_service_interaction_req_s_type { + rpc_loc_ni_vx_notify_verify_req_s_type ni_vx_req; + rpc_loc_ni_service_interaction_e_type service_interation_type; +}; +typedef struct rpc_loc_ni_vx_service_interaction_req_s_type rpc_loc_ni_vx_service_interaction_req_s_type; + +struct rpc_loc_ni_event_payload_u_type { + rpc_loc_ni_event_e_type disc; + union { + rpc_loc_ni_vx_notify_verify_req_s_type vx_req; + rpc_loc_ni_supl_notify_verify_req_s_type supl_req; + rpc_loc_ni_umts_cp_notify_verify_req_s_type umts_cp_req; + rpc_loc_ni_vx_service_interaction_req_s_type service_interaction_req; + } rpc_loc_ni_event_payload_u_type_u; +}; +typedef struct rpc_loc_ni_event_payload_u_type rpc_loc_ni_event_payload_u_type; + +struct rpc_loc_ni_event_s_type { + rpc_loc_ni_event_e_type event; + rpc_loc_ni_event_payload_u_type payload; +}; +typedef struct rpc_loc_ni_event_s_type rpc_loc_ni_event_s_type; + +enum rpc_loc_assist_data_request_e_type { + RPC_LOC_ASSIST_DATA_TIME_REQ = 1, + RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ = 2, + RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ = 3, + RPC_LOC_ASSIST_DATA_MAX = 268435456, +}; +typedef enum rpc_loc_assist_data_request_e_type rpc_loc_assist_data_request_e_type; + +typedef char *rpc_struct_loc_time_download_source_s_type_servers_ptr; + +typedef rpc_struct_loc_time_download_source_s_type_servers_ptr rpc_struct_loc_time_download_source_s_type_servers[3]; + +struct rpc_loc_time_download_source_s_type { + rpc_uint32 delay_threshold; + rpc_struct_loc_time_download_source_s_type_servers servers; +}; +typedef struct rpc_loc_time_download_source_s_type rpc_loc_time_download_source_s_type; + +typedef char *rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr; + +typedef rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr rpc_struct_loc_predicted_orbits_data_source_s_type_servers[3]; + +struct rpc_loc_predicted_orbits_data_source_s_type { + rpc_uint32 max_file_size; + rpc_uint32 max_part_size; + rpc_struct_loc_predicted_orbits_data_source_s_type_servers servers; +}; +typedef struct rpc_loc_predicted_orbits_data_source_s_type rpc_loc_predicted_orbits_data_source_s_type; + +struct rpc_loc_pos_inj_request_s_type { + rpc_uint32 flags; + double latitude; + double longitude; + rpc_uint32 position_uncertainty; + rpc_uint64 timestamp; +}; +typedef struct rpc_loc_pos_inj_request_s_type rpc_loc_pos_inj_request_s_type; + +struct rpc_loc_assist_data_request_payload_u_type { + rpc_loc_assist_data_request_e_type disc; + union { + rpc_loc_time_download_source_s_type time_download; + rpc_loc_predicted_orbits_data_source_s_type data_download; + rpc_loc_pos_inj_request_s_type pos_injection; + } rpc_loc_assist_data_request_payload_u_type_u; +}; +typedef struct rpc_loc_assist_data_request_payload_u_type rpc_loc_assist_data_request_payload_u_type; + +struct rpc_loc_assist_data_request_s_type { + rpc_loc_assist_data_request_e_type event; + rpc_loc_assist_data_request_payload_u_type payload; +}; +typedef struct rpc_loc_assist_data_request_s_type rpc_loc_assist_data_request_s_type; + +typedef rpc_uint32 rpc_loc_server_connection_handle; + +enum rpc_loc_server_protocol_e_type { + RPC_LOC_SERVER_PROTOCOL_DEFAULT = 0, + RPC_LOC_SERVER_PROTOCOL_SUPL = 1, + RPC_LOC_SERVER_PROTOCOL_VX_MPC = 2, + RPC_LOC_SERVER_PROTOCOL_VX_PDE = 3, + RPC_LOC_SERVER_PROTOCOL_MAX = 16777216, +}; +typedef enum rpc_loc_server_protocol_e_type rpc_loc_server_protocol_e_type; + +enum rpc_loc_server_connection_e_type { + RPC_LOC_SERVER_CONNECTION_LBS = 0, + RPC_LOC_SERVER_CONNECTION_WWAN_INTERNET = 0 + 1, + RPC_LOC_SERVER_CONNECTION_MAX = 16777216, +}; +typedef enum rpc_loc_server_connection_e_type rpc_loc_server_connection_e_type; + +enum rpc_loc_server_request_e_type { + RPC_LOC_SERVER_REQUEST_OPEN = 1, + RPC_LOC_SERVER_REQUEST_CLOSE = 2, + RPC_LOC_SERVER_REQUEST_MULTI_OPEN = 3, + RPC_LOC_SERVER_REQUEST_MAX = 268435456, +}; +typedef enum rpc_loc_server_request_e_type rpc_loc_server_request_e_type; + +struct rpc_loc_server_open_req_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_protocol_e_type protocol; +}; +typedef struct rpc_loc_server_open_req_s_type rpc_loc_server_open_req_s_type; + +struct rpc_loc_server_multi_open_req_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_protocol_e_type protocol; + rpc_loc_server_connection_e_type connection_type; +}; +typedef struct rpc_loc_server_multi_open_req_s_type rpc_loc_server_multi_open_req_s_type; + +struct rpc_loc_server_close_req_s_type { + rpc_loc_server_connection_handle conn_handle; +}; +typedef struct rpc_loc_server_close_req_s_type rpc_loc_server_close_req_s_type; + +struct rpc_loc_server_request_u_type { + rpc_loc_server_request_e_type disc; + union { + rpc_loc_server_open_req_s_type open_req; + rpc_loc_server_close_req_s_type close_req; + rpc_loc_server_multi_open_req_s_type multi_open_req; + } rpc_loc_server_request_u_type_u; +}; +typedef struct rpc_loc_server_request_u_type rpc_loc_server_request_u_type; + +struct rpc_loc_server_request_s_type { + rpc_loc_server_request_e_type event; + rpc_loc_server_request_u_type payload; +}; +typedef struct rpc_loc_server_request_s_type rpc_loc_server_request_s_type; + +enum rpc_loc_qwip_request_e_type { + RPC_LOC_QWIP_START_PERIODIC_HI_FREQ_FIXES = 0, + RPC_LOC_QWIP_START_PERIODIC_KEEP_WARM = 0 + 1, + RPC_LOC_QWIP_STOP_PERIODIC_FIXES = 0 + 2, + RPC_LOC_QWIP_SUSPEND = 0 + 3, + RPC_LOC_QWIP_REQUEST_MAX = 268435456, +}; +typedef enum rpc_loc_qwip_request_e_type rpc_loc_qwip_request_e_type; + +struct rpc_loc_qwip_request_s_type { + rpc_loc_qwip_request_e_type request_type; + rpc_uint16 tbf_ms; +}; +typedef struct rpc_loc_qwip_request_s_type rpc_loc_qwip_request_s_type; + +struct rpc_loc_reserved_payload_s_type { + rpc_uint16 data_size; + struct { + u_int data_len; + char *data_val; + } data; +}; +typedef struct rpc_loc_reserved_payload_s_type rpc_loc_reserved_payload_s_type; + +enum rpc_loc_ioctl_e_type { + RPC_LOC_IOCTL_GET_API_VERSION = 1, + RPC_LOC_IOCTL_SET_FIX_CRITERIA = 2, + RPC_LOC_IOCTL_GET_FIX_CRITERIA = 3, + RPC_LOC_IOCTL_SERVICE_START_INDEX = 400, + RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE = 400, + RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA = 401, + RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY = 402, + RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE = 403, + RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD = 404, + RPC_LOC_IOCTL_INJECT_UTC_TIME = 405, + RPC_LOC_IOCTL_INJECT_RTC_VALUE = 406, + RPC_LOC_IOCTL_INJECT_POSITION = 407, + RPC_LOC_IOCTL_QUERY_ENGINE_STATE = 408, + RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS = 409, + RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS = 410, + RPC_LOC_IOCTL_SEND_WIPER_POSITION_REPORT = 411, + RPC_LOC_IOCTL_NOTIFY_WIPER_STATUS = 412, + RPC_LOC_IOCTL_ACCESS_EFS_DATA = 413, + RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG = 414, + RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS = 415, + RPC_LOC_IOCTL_NV_SETTINGS_START_INDEX = 800, + RPC_LOC_IOCTL_SET_ENGINE_LOCK = 800, + RPC_LOC_IOCTL_GET_ENGINE_LOCK = 801, + RPC_LOC_IOCTL_SET_SBAS_CONFIG = 802, + RPC_LOC_IOCTL_GET_SBAS_CONFIG = 803, + RPC_LOC_IOCTL_SET_NMEA_TYPES = 804, + RPC_LOC_IOCTL_GET_NMEA_TYPES = 805, + RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR = 806, + RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR = 807, + RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR = 808, + RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR = 809, + RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR = 810, + RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR = 811, + RPC_LOC_IOCTL_SET_ON_DEMAND_LPM = 812, + RPC_LOC_IOCTL_GET_ON_DEMAND_LPM = 813, + RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL = 814, + RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL = 815, + RPC_LOC_IOCTL_SET_LBS_APN_PROFILE = 816, + RPC_LOC_IOCTL_GET_LBS_APN_PROFILE = 817, + RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE = 818, + RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE = 819, + RPC_LOC_IOCTL_SET_DATA_ENABLE = 820, + RPC_LOC_IOCTL_SET_SUPL_VERSION = 821, + RPC_LOC_IOCTL_GET_SUPL_VERSION = 822, + RPC_LOC_IOCTL_PROPRIETARY_START_INDEX = 1000, + RPC_LOC_IOCTL_DELETE_ASSIST_DATA = 1000, + RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR = 1001, + RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR = 1002, + RPC_LOC_IOCTL_RESERVED_CMD = 8000, + RPC_LOC_IOCTL_THIRD_PARTY_START_INDEX = 1073741824, +}; +typedef enum rpc_loc_ioctl_e_type rpc_loc_ioctl_e_type; + +struct rpc_loc_api_version_s_type { + u_char major; + u_char minor; +}; +typedef struct rpc_loc_api_version_s_type rpc_loc_api_version_s_type; + +enum rpc_loc_fix_recurrence_e_type { + RPC_LOC_PERIODIC_FIX = 1, + RPC_LOC_SINGLE_FIX = 2, + RPC_LOC_FIX_SESSION_TYPE_MAX = 268435456, +}; +typedef enum rpc_loc_fix_recurrence_e_type rpc_loc_fix_recurrence_e_type; + +enum rpc_loc_operation_mode_e_type { + RPC_LOC_OPER_MODE_DEFAULT = 1, + RPC_LOC_OPER_MODE_MSB = 2, + RPC_LOC_OPER_MODE_MSA = 3, + RPC_LOC_OPER_MODE_STANDALONE = 4, + RPC_LOC_OPER_MODE_SPEED_OPTIMAL = 5, + RPC_LOC_OPER_MODE_ACCURACY_OPTIMAL = 6, + RPC_LOC_OPER_MODE_DATA_OPTIMAL = 7, + RPC_LOC_OPER_MODE_CELL_ID = 8, + RPC_LOC_OPER_MODE_MAX = 268435456, +}; +typedef enum rpc_loc_operation_mode_e_type rpc_loc_operation_mode_e_type; + +enum rpc_loc_notify_e_type { + RPC_LOC_NOTIFY_ON_INTERVAL = 1, + RPC_LOC_NOTIFY_ON_DISTANCE = 2, + RPC_LOC_NOTIFY_ON_ANY = 3, + RPC_LOC_NOTIFY_ON_ALL = 4, + RPC_LOC_NOTIFY_TYPE_MAX = 268435456, +}; +typedef enum rpc_loc_notify_e_type rpc_loc_notify_e_type; + +struct rpc_loc_fix_criteria_s_type { + rpc_uint32 valid_mask; + rpc_loc_fix_recurrence_e_type recurrence_type; + rpc_loc_operation_mode_e_type preferred_operation_mode; + rpc_uint32 preferred_accuracy; + rpc_uint32 preferred_response_time; + rpc_boolean intermediate_pos_report_enabled; + rpc_loc_notify_e_type notify_type; + rpc_uint32 min_interval; + float min_distance; + rpc_uint32 min_dist_sample_interval; +}; +typedef struct rpc_loc_fix_criteria_s_type rpc_loc_fix_criteria_s_type; + +enum rpc_loc_ni_user_resp_e_type { + RPC_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT = 1, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_DENY = 2, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_NORESP = 3, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_MAX = 268435456, +}; +typedef enum rpc_loc_ni_user_resp_e_type rpc_loc_ni_user_resp_e_type; + +struct rpc_loc_user_verify_s_type { + rpc_loc_ni_user_resp_e_type user_resp; + rpc_loc_ni_event_s_type ni_event_pass_back; +}; +typedef struct rpc_loc_user_verify_s_type rpc_loc_user_verify_s_type; + +enum rpc_loc_predicted_orbits_data_format_e_type { + RPC_LOC_PREDICTED_ORBITS_XTRA = 0, + RPC_LOC_PREDICTED_ORBITS_FORMAT_MAX = 268435456, +}; +typedef enum rpc_loc_predicted_orbits_data_format_e_type rpc_loc_predicted_orbits_data_format_e_type; + +struct rpc_loc_predicted_orbits_data_s_type { + rpc_loc_predicted_orbits_data_format_e_type format_type; + rpc_uint32 total_size; + rpc_uint8 total_parts; + rpc_uint8 part; + rpc_uint16 part_len; + struct { + u_int data_ptr_len; + char *data_ptr_val; + } data_ptr; +}; +typedef struct rpc_loc_predicted_orbits_data_s_type rpc_loc_predicted_orbits_data_s_type; + +struct rpc_loc_predicted_orbits_data_validity_report_s_type { + rpc_uint64 start_time_utc; + rpc_uint16 valid_duration_hrs; +}; +typedef struct rpc_loc_predicted_orbits_data_validity_report_s_type rpc_loc_predicted_orbits_data_validity_report_s_type; + +struct rpc_loc_predicted_orbits_auto_download_config_s_type { + rpc_boolean enable; + u_char auto_check_every_hrs; +}; +typedef struct rpc_loc_predicted_orbits_auto_download_config_s_type rpc_loc_predicted_orbits_auto_download_config_s_type; + +struct rpc_loc_assist_data_time_s_type { + rpc_uint64 time_utc; + rpc_uint32 uncertainty; +}; +typedef struct rpc_loc_assist_data_time_s_type rpc_loc_assist_data_time_s_type; + +typedef rpc_uint64 rpc_loc_assist_pos_valid_mask_type; + +struct rpc_loc_assist_data_pos_s_type { + rpc_loc_assist_pos_valid_mask_type valid_mask; + rpc_uint64 timestamp_utc; + double latitude; + double longitude; + float altitude_wrt_ellipsoid; + float altitude_wrt_mean_sea_level; + float hor_unc_circular; + float vert_unc; + u_char confidence_horizontal; + u_char confidence_vertical; + rpc_int32 timestamp_age; +}; +typedef struct rpc_loc_assist_data_pos_s_type rpc_loc_assist_data_pos_s_type; + +enum rpc_loc_server_open_status_e_type { + RPC_LOC_SERVER_OPEN_SUCCESS = 1, + RPC_LOC_SERVER_OPEN_FAIL = 2, + RPC_LOC_SERVER_OPEN_STATUS_MAX = 268435456, +}; +typedef enum rpc_loc_server_open_status_e_type rpc_loc_server_open_status_e_type; + +enum rpc_loc_server_pdp_type_e_type { + RPC_LOC_SERVER_PDP_IP = 0, + RPC_LOC_SERVER_PDP_PPP = 0 + 1, + RPC_LOC_SERVER_PDP_IPV6 = 0 + 2, + RPC_LOC_SERVER_PDP_IPV4V6 = 0 + 3, + RPC_LOC_SERVER_PDP_MAX = 268435456, +}; +typedef enum rpc_loc_server_pdp_type_e_type rpc_loc_server_pdp_type_e_type; + +struct rpc_loc_server_open_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_open_status_e_type open_status; + char apn_name[100]; +}; +typedef struct rpc_loc_server_open_status_s_type rpc_loc_server_open_status_s_type; + +struct rpc_loc_server_multi_open_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_open_status_e_type open_status; + rpc_loc_server_pdp_type_e_type pdp_type; + char apn_name[100]; +}; +typedef struct rpc_loc_server_multi_open_status_s_type rpc_loc_server_multi_open_status_s_type; + +enum rpc_loc_server_close_status_e_type { + RPC_LOC_SERVER_CLOSE_SUCCESS = 1, + RPC_LOC_SERVER_CLOSE_FAIL = 2, + RPC_LOC_SERVER_CLOSE_STATUS_MAX = 268435456, +}; +typedef enum rpc_loc_server_close_status_e_type rpc_loc_server_close_status_e_type; + +struct rpc_loc_server_close_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_close_status_e_type close_status; +}; +typedef struct rpc_loc_server_close_status_s_type rpc_loc_server_close_status_s_type; + +struct rpc_loc_wiper_fix_time_s_type { + rpc_uint32 slow_clock_count; +}; +typedef struct rpc_loc_wiper_fix_time_s_type rpc_loc_wiper_fix_time_s_type; + +struct rpc_loc_wiper_fix_pos_s_type { + rpc_int32 lat; + rpc_int32 lon; + rpc_uint16 HEPE; + rpc_uint8 num_of_aps_used; + rpc_uint8 fix_error_code; +}; +typedef struct rpc_loc_wiper_fix_pos_s_type rpc_loc_wiper_fix_pos_s_type; + +struct rpc_loc_wiper_ap_info_s_type { + char mac_addr[6]; + rpc_int32 rssi; + rpc_uint16 channel; + rpc_uint8 ap_qualifier; +}; +typedef struct rpc_loc_wiper_ap_info_s_type rpc_loc_wiper_ap_info_s_type; + +struct rpc_loc_wiper_ap_set_s_type { + rpc_uint8 num_of_aps; + rpc_loc_wiper_ap_info_s_type ap_info[50]; +}; +typedef struct rpc_loc_wiper_ap_set_s_type rpc_loc_wiper_ap_set_s_type; + +struct rpc_loc_wiper_position_report_s_type { + rpc_uint8 wiper_valid_info_flag; + rpc_loc_wiper_fix_time_s_type wiper_fix_time; + rpc_loc_wiper_fix_pos_s_type wiper_fix_position; + rpc_loc_wiper_ap_set_s_type wiper_ap_set; +}; +typedef struct rpc_loc_wiper_position_report_s_type rpc_loc_wiper_position_report_s_type; + +enum rpc_loc_wiper_status_e_type { + RPC_LOC_WIPER_STATUS_AVAILABLE = 1, + RPC_LOC_WIPER_STATUS_UNAVAILABLE = 2, + RPC_LOC_WIPER_STATUS_E_SIZE = 268435456, +}; +typedef enum rpc_loc_wiper_status_e_type rpc_loc_wiper_status_e_type; + +enum rpc_loc_fs_operation_e_type { + RPC_LOC_FS_CREATE_WRITE_FILE = 1, + RPC_LOC_FS_APPEND_FILE = 2, + RPC_LOC_FS_DELETE_FILE = 3, + RPC_LOC_FS_READ_FILE = 4, + RPC_LOC_FS_MAX = 268435456, +}; +typedef enum rpc_loc_fs_operation_e_type rpc_loc_fs_operation_e_type; + +struct rpc_loc_efs_data_s_type { + char filename[64]; + rpc_loc_fs_operation_e_type operation; + rpc_uint32 total_size; + struct { + u_int data_ptr_len; + char *data_ptr_val; + } data_ptr; + rpc_uint32 part_len; + rpc_uint8 part; + rpc_uint8 total_parts; + rpc_uint32 reserved; +}; +typedef struct rpc_loc_efs_data_s_type rpc_loc_efs_data_s_type; + +enum rpc_loc_error_estimate_config_e_type { + RPC_LOC_ERROR_ESTIMATE_CONFIG_SET = 1, + RPC_LOC_ERROR_ESTIMATE_CONFIG_CLEAR = 2, + RPC_LOC_ERROR_ESTIMATE_MAX = 268435456, +}; +typedef enum rpc_loc_error_estimate_config_e_type rpc_loc_error_estimate_config_e_type; + +struct rpc_loc_apn_profiles_type { + rpc_uint32 srv_system_type; + rpc_uint32 pdp_type; + rpc_uint32 reserved; + char apn_name[100]; +}; +typedef struct rpc_loc_apn_profiles_type rpc_loc_apn_profiles_type; + +enum rpc_loc_lock_e_type { + RPC_LOC_LOCK_NONE = 1, + RPC_LOC_LOCK_MI = 2, + RPC_LOC_LOCK_MT = 3, + RPC_LOC_LOCK_ALL = 4, + RPC_LOC_LOCK_MAX = 268435456, +}; +typedef enum rpc_loc_lock_e_type rpc_loc_lock_e_type; + +typedef rpc_uint32 rpc_loc_nmea_sentence_type; + +typedef rpc_uint32 rpc_loc_assist_data_type; + +struct rpc_loc_assist_data_delete_s_type { + rpc_loc_assist_data_type type; + rpc_uint32 reserved[8]; +}; +typedef struct rpc_loc_assist_data_delete_s_type rpc_loc_assist_data_delete_s_type; + +struct rpc_loc_ioctl_data_u_type { + rpc_loc_ioctl_e_type disc; + union { + rpc_loc_fix_criteria_s_type fix_criteria; + rpc_loc_user_verify_s_type user_verify_resp; + rpc_loc_predicted_orbits_data_s_type predicted_orbits_data; + rpc_loc_predicted_orbits_auto_download_config_s_type predicted_orbits_auto_download; + rpc_loc_assist_data_time_s_type assistance_data_time; + rpc_loc_assist_data_pos_s_type assistance_data_position; + rpc_loc_server_open_status_s_type conn_open_status; + rpc_loc_server_close_status_s_type conn_close_status; + rpc_loc_wiper_position_report_s_type wiper_pos; + rpc_loc_wiper_status_e_type wiper_status; + rpc_loc_lock_e_type engine_lock; + rpc_boolean sbas_mode; + rpc_loc_nmea_sentence_type nmea_types; + rpc_boolean on_demand_lpm; + rpc_loc_server_info_s_type server_addr; + rpc_loc_assist_data_delete_s_type assist_data_delete; + rpc_loc_efs_data_s_type efs_data; + rpc_loc_error_estimate_config_e_type error_estimate_config; + rpc_uint8 xtra_t_session_control; + rpc_loc_apn_profiles_type apn_profiles[6]; + rpc_boolean data_enable; + rpc_uint32 supl_version; + rpc_loc_server_multi_open_status_s_type multi_conn_open_status; + rpc_loc_reserved_payload_s_type reserved; + } rpc_loc_ioctl_data_u_type_u; +}; +typedef struct rpc_loc_ioctl_data_u_type rpc_loc_ioctl_data_u_type; + +struct rpc_loc_ioctl_callback_data_u_type { + rpc_loc_ioctl_e_type disc; + union { + rpc_loc_api_version_s_type api_version; + rpc_loc_fix_criteria_s_type fix_criteria; + rpc_loc_lock_e_type engine_lock; + rpc_boolean sbas_mode; + rpc_loc_nmea_sentence_type nmea_types; + rpc_boolean on_demand_lpm; + rpc_loc_server_info_s_type server_addr; + rpc_loc_predicted_orbits_data_source_s_type predicted_orbits_data_source; + rpc_loc_predicted_orbits_data_validity_report_s_type predicted_orbits_data_validity; + rpc_uint8 xtra_t_session_control; + rpc_loc_apn_profiles_type apn_profiles[6]; + rpc_uint32 supl_version; + } rpc_loc_ioctl_callback_data_u_type_u; +}; +typedef struct rpc_loc_ioctl_callback_data_u_type rpc_loc_ioctl_callback_data_u_type; + +struct rpc_loc_ioctl_callback_s_type { + rpc_loc_ioctl_e_type type; + rpc_int32 status; + rpc_loc_ioctl_callback_data_u_type data; +}; +typedef struct rpc_loc_ioctl_callback_s_type rpc_loc_ioctl_callback_s_type; + +struct rpc_loc_event_payload_u_type { + u_quad_t disc; + union { + rpc_loc_parsed_position_s_type parsed_location_report; + rpc_loc_gnss_info_s_type gnss_report; + rpc_loc_nmea_report_s_type nmea_report; + rpc_loc_ni_event_s_type ni_request; + rpc_loc_assist_data_request_s_type assist_data_request; + rpc_loc_server_request_s_type loc_server_request; + rpc_loc_ioctl_callback_s_type ioctl_report; + rpc_loc_status_event_s_type status_report; + rpc_loc_qwip_request_s_type qwip_request; + rpc_loc_reserved_payload_s_type reserved; + } rpc_loc_event_payload_u_type_u; +}; +typedef struct rpc_loc_event_payload_u_type rpc_loc_event_payload_u_type; + +/* the xdr functions */ + +#if defined(__STDC__) || defined(__cplusplus) +extern bool_t xdr_rpc_loc_client_handle_type (XDR *, rpc_loc_client_handle_type*); +extern bool_t xdr_rpc_loc_event_mask_type (XDR *, rpc_loc_event_mask_type*); +extern bool_t xdr_rpc_loc_position_valid_mask_type (XDR *, rpc_loc_position_valid_mask_type*); +extern bool_t xdr_rpc_loc_pos_technology_mask_type (XDR *, rpc_loc_pos_technology_mask_type*); +extern bool_t xdr_rpc_loc_session_status_e_type (XDR *, rpc_loc_session_status_e_type*); +extern bool_t xdr_rpc_loc_calendar_time_s_type (XDR *, rpc_loc_calendar_time_s_type*); +extern bool_t xdr_rpc_loc_parsed_position_s_type (XDR *, rpc_loc_parsed_position_s_type*); +extern bool_t xdr_rpc_loc_sv_system_e_type (XDR *, rpc_loc_sv_system_e_type*); +extern bool_t xdr_rpc_loc_sv_status_e_type (XDR *, rpc_loc_sv_status_e_type*); +extern bool_t xdr_rpc_loc_sv_info_valid_mask_type (XDR *, rpc_loc_sv_info_valid_mask_type*); +extern bool_t xdr_rpc_loc_sv_info_s_type (XDR *, rpc_loc_sv_info_s_type*); +extern bool_t xdr_rpc_loc_gnss_info_valid_mask_type (XDR *, rpc_loc_gnss_info_valid_mask_type*); +extern bool_t xdr_rpc_loc_gnss_info_s_type (XDR *, rpc_loc_gnss_info_s_type*); +extern bool_t xdr_rpc_loc_nmea_report_s_type (XDR *, rpc_loc_nmea_report_s_type*); +extern bool_t xdr_rpc_loc_status_event_e_type (XDR *, rpc_loc_status_event_e_type*); +extern bool_t xdr_rpc_loc_engine_state_e_type (XDR *, rpc_loc_engine_state_e_type*); +extern bool_t xdr_rpc_loc_fix_session_state_e_type (XDR *, rpc_loc_fix_session_state_e_type*); +extern bool_t xdr_rpc_loc_status_event_payload_u_type (XDR *, rpc_loc_status_event_payload_u_type*); +extern bool_t xdr_rpc_loc_status_event_s_type (XDR *, rpc_loc_status_event_s_type*); +extern bool_t xdr_rpc_loc_server_addr_e_type (XDR *, rpc_loc_server_addr_e_type*); +extern bool_t xdr_rpc_loc_server_addr_ipv4_type (XDR *, rpc_loc_server_addr_ipv4_type*); +extern bool_t xdr_rpc_loc_server_addr_url_type (XDR *, rpc_loc_server_addr_url_type*); +extern bool_t xdr_rpc_loc_server_addr_ipv6_type (XDR *, rpc_loc_server_addr_ipv6_type*); +extern bool_t xdr_rpc_loc_server_addr_u_type (XDR *, rpc_loc_server_addr_u_type*); +extern bool_t xdr_rpc_loc_server_info_s_type (XDR *, rpc_loc_server_info_s_type*); +extern bool_t xdr_rpc_loc_ni_notify_verify_e_type (XDR *, rpc_loc_ni_notify_verify_e_type*); +extern bool_t xdr_rpc_loc_ni_event_e_type (XDR *, rpc_loc_ni_event_e_type*); +extern bool_t xdr_rpc_loc_ni_datacoding_scheme_e_type (XDR *, rpc_loc_ni_datacoding_scheme_e_type*); +extern bool_t xdr_rpc_loc_ni_vx_requester_id_encoding_scheme_e_type (XDR *, rpc_loc_ni_vx_requester_id_encoding_scheme_e_type*); +extern bool_t xdr_rpc_loc_ni_vx_pos_mode_e_type (XDR *, rpc_loc_ni_vx_pos_mode_e_type*); +extern bool_t xdr_rpc_loc_ni_vx_requester_id_s_type (XDR *, rpc_loc_ni_vx_requester_id_s_type*); +extern bool_t xdr_rpc_loc_ni_vx_notify_verify_req_s_type (XDR *, rpc_loc_ni_vx_notify_verify_req_s_type*); +extern bool_t xdr_rpc_loc_ni_supl_pos_method_e_type (XDR *, rpc_loc_ni_supl_pos_method_e_type*); +extern bool_t xdr_rpc_loc_ni_supl_slp_session_id_s_type (XDR *, rpc_loc_ni_supl_slp_session_id_s_type*); +extern bool_t xdr_rpc_loc_ni_requestor_id_s_type (XDR *, rpc_loc_ni_requestor_id_s_type*); +extern bool_t xdr_rpc_loc_ni_supl_client_name_s_type (XDR *, rpc_loc_ni_supl_client_name_s_type*); +extern bool_t xdr_rpc_loc_ni_supl_qop_s_type (XDR *, rpc_loc_ni_supl_qop_s_type*); +extern bool_t xdr_rpc_loc_ni_supl_notify_verify_req_s_type (XDR *, rpc_loc_ni_supl_notify_verify_req_s_type*); +extern bool_t xdr_rpc_loc_ni_ext_client_address_s_type (XDR *, rpc_loc_ni_ext_client_address_s_type*); +extern bool_t xdr_rpc_loc_ni_location_type_e_type (XDR *, rpc_loc_ni_location_type_e_type*); +extern bool_t xdr_rpc_loc_ni_deferred_location_s_type (XDR *, rpc_loc_ni_deferred_location_s_type*); +extern bool_t xdr_rpc_loc_ni_codeword_string_s_type (XDR *, rpc_loc_ni_codeword_string_s_type*); +extern bool_t xdr_rpc_loc_ni_service_type_id_s_type (XDR *, rpc_loc_ni_service_type_id_s_type*); +extern bool_t xdr_rpc_loc_ni_umts_cp_notify_verify_req_s_type (XDR *, rpc_loc_ni_umts_cp_notify_verify_req_s_type*); +extern bool_t xdr_rpc_loc_ni_service_interaction_e_type (XDR *, rpc_loc_ni_service_interaction_e_type*); +extern bool_t xdr_rpc_loc_ni_vx_service_interaction_req_s_type (XDR *, rpc_loc_ni_vx_service_interaction_req_s_type*); +extern bool_t xdr_rpc_loc_ni_event_payload_u_type (XDR *, rpc_loc_ni_event_payload_u_type*); +extern bool_t xdr_rpc_loc_ni_event_s_type (XDR *, rpc_loc_ni_event_s_type*); +extern bool_t xdr_rpc_loc_assist_data_request_e_type (XDR *, rpc_loc_assist_data_request_e_type*); +extern bool_t xdr_rpc_struct_loc_time_download_source_s_type_servers_ptr (XDR *, rpc_struct_loc_time_download_source_s_type_servers_ptr*); +extern bool_t xdr_rpc_struct_loc_time_download_source_s_type_servers (XDR *, rpc_struct_loc_time_download_source_s_type_servers); +extern bool_t xdr_rpc_loc_time_download_source_s_type (XDR *, rpc_loc_time_download_source_s_type*); +extern bool_t xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr (XDR *, rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr*); +extern bool_t xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers (XDR *, rpc_struct_loc_predicted_orbits_data_source_s_type_servers); +extern bool_t xdr_rpc_loc_predicted_orbits_data_source_s_type (XDR *, rpc_loc_predicted_orbits_data_source_s_type*); +extern bool_t xdr_rpc_loc_pos_inj_request_s_type (XDR *, rpc_loc_pos_inj_request_s_type*); +extern bool_t xdr_rpc_loc_assist_data_request_payload_u_type (XDR *, rpc_loc_assist_data_request_payload_u_type*); +extern bool_t xdr_rpc_loc_assist_data_request_s_type (XDR *, rpc_loc_assist_data_request_s_type*); +extern bool_t xdr_rpc_loc_server_connection_handle (XDR *, rpc_loc_server_connection_handle*); +extern bool_t xdr_rpc_loc_server_protocol_e_type (XDR *, rpc_loc_server_protocol_e_type*); +extern bool_t xdr_rpc_loc_server_connection_e_type (XDR *, rpc_loc_server_connection_e_type*); +extern bool_t xdr_rpc_loc_server_request_e_type (XDR *, rpc_loc_server_request_e_type*); +extern bool_t xdr_rpc_loc_server_open_req_s_type (XDR *, rpc_loc_server_open_req_s_type*); +extern bool_t xdr_rpc_loc_server_multi_open_req_s_type (XDR *, rpc_loc_server_multi_open_req_s_type*); +extern bool_t xdr_rpc_loc_server_close_req_s_type (XDR *, rpc_loc_server_close_req_s_type*); +extern bool_t xdr_rpc_loc_server_request_u_type (XDR *, rpc_loc_server_request_u_type*); +extern bool_t xdr_rpc_loc_server_request_s_type (XDR *, rpc_loc_server_request_s_type*); +extern bool_t xdr_rpc_loc_qwip_request_e_type (XDR *, rpc_loc_qwip_request_e_type*); +extern bool_t xdr_rpc_loc_qwip_request_s_type (XDR *, rpc_loc_qwip_request_s_type*); +extern bool_t xdr_rpc_loc_reserved_payload_s_type (XDR *, rpc_loc_reserved_payload_s_type*); +extern bool_t xdr_rpc_loc_ioctl_e_type (XDR *, rpc_loc_ioctl_e_type*); +extern bool_t xdr_rpc_loc_api_version_s_type (XDR *, rpc_loc_api_version_s_type*); +extern bool_t xdr_rpc_loc_fix_recurrence_e_type (XDR *, rpc_loc_fix_recurrence_e_type*); +extern bool_t xdr_rpc_loc_operation_mode_e_type (XDR *, rpc_loc_operation_mode_e_type*); +extern bool_t xdr_rpc_loc_notify_e_type (XDR *, rpc_loc_notify_e_type*); +extern bool_t xdr_rpc_loc_fix_criteria_s_type (XDR *, rpc_loc_fix_criteria_s_type*); +extern bool_t xdr_rpc_loc_ni_user_resp_e_type (XDR *, rpc_loc_ni_user_resp_e_type*); +extern bool_t xdr_rpc_loc_user_verify_s_type (XDR *, rpc_loc_user_verify_s_type*); +extern bool_t xdr_rpc_loc_predicted_orbits_data_format_e_type (XDR *, rpc_loc_predicted_orbits_data_format_e_type*); +extern bool_t xdr_rpc_loc_predicted_orbits_data_s_type (XDR *, rpc_loc_predicted_orbits_data_s_type*); +extern bool_t xdr_rpc_loc_predicted_orbits_data_validity_report_s_type (XDR *, rpc_loc_predicted_orbits_data_validity_report_s_type*); +extern bool_t xdr_rpc_loc_predicted_orbits_auto_download_config_s_type (XDR *, rpc_loc_predicted_orbits_auto_download_config_s_type*); +extern bool_t xdr_rpc_loc_assist_data_time_s_type (XDR *, rpc_loc_assist_data_time_s_type*); +extern bool_t xdr_rpc_loc_assist_pos_valid_mask_type (XDR *, rpc_loc_assist_pos_valid_mask_type*); +extern bool_t xdr_rpc_loc_assist_data_pos_s_type (XDR *, rpc_loc_assist_data_pos_s_type*); +extern bool_t xdr_rpc_loc_server_open_status_e_type (XDR *, rpc_loc_server_open_status_e_type*); +extern bool_t xdr_rpc_loc_server_pdp_type_e_type (XDR *, rpc_loc_server_pdp_type_e_type*); +extern bool_t xdr_rpc_loc_server_open_status_s_type (XDR *, rpc_loc_server_open_status_s_type*); +extern bool_t xdr_rpc_loc_server_multi_open_status_s_type (XDR *, rpc_loc_server_multi_open_status_s_type*); +extern bool_t xdr_rpc_loc_server_close_status_e_type (XDR *, rpc_loc_server_close_status_e_type*); +extern bool_t xdr_rpc_loc_server_close_status_s_type (XDR *, rpc_loc_server_close_status_s_type*); +extern bool_t xdr_rpc_loc_wiper_fix_time_s_type (XDR *, rpc_loc_wiper_fix_time_s_type*); +extern bool_t xdr_rpc_loc_wiper_fix_pos_s_type (XDR *, rpc_loc_wiper_fix_pos_s_type*); +extern bool_t xdr_rpc_loc_wiper_ap_info_s_type (XDR *, rpc_loc_wiper_ap_info_s_type*); +extern bool_t xdr_rpc_loc_wiper_ap_set_s_type (XDR *, rpc_loc_wiper_ap_set_s_type*); +extern bool_t xdr_rpc_loc_wiper_position_report_s_type (XDR *, rpc_loc_wiper_position_report_s_type*); +extern bool_t xdr_rpc_loc_wiper_status_e_type (XDR *, rpc_loc_wiper_status_e_type*); +extern bool_t xdr_rpc_loc_fs_operation_e_type (XDR *, rpc_loc_fs_operation_e_type*); +extern bool_t xdr_rpc_loc_efs_data_s_type (XDR *, rpc_loc_efs_data_s_type*); +extern bool_t xdr_rpc_loc_error_estimate_config_e_type (XDR *, rpc_loc_error_estimate_config_e_type*); +extern bool_t xdr_rpc_loc_apn_profiles_type (XDR *, rpc_loc_apn_profiles_type*); +extern bool_t xdr_rpc_loc_lock_e_type (XDR *, rpc_loc_lock_e_type*); +extern bool_t xdr_rpc_loc_nmea_sentence_type (XDR *, rpc_loc_nmea_sentence_type*); +extern bool_t xdr_rpc_loc_assist_data_type (XDR *, rpc_loc_assist_data_type*); +extern bool_t xdr_rpc_loc_assist_data_delete_s_type (XDR *, rpc_loc_assist_data_delete_s_type*); +extern bool_t xdr_rpc_loc_ioctl_data_u_type (XDR *, rpc_loc_ioctl_data_u_type*); +extern bool_t xdr_rpc_loc_ioctl_callback_data_u_type (XDR *, rpc_loc_ioctl_callback_data_u_type*); +extern bool_t xdr_rpc_loc_ioctl_callback_s_type (XDR *, rpc_loc_ioctl_callback_s_type*); +extern bool_t xdr_rpc_loc_event_payload_u_type (XDR *, rpc_loc_event_payload_u_type*); + +#else /* K&R C */ +extern bool_t xdr_rpc_loc_client_handle_type (); +extern bool_t xdr_rpc_loc_event_mask_type (); +extern bool_t xdr_rpc_loc_position_valid_mask_type (); +extern bool_t xdr_rpc_loc_pos_technology_mask_type (); +extern bool_t xdr_rpc_loc_session_status_e_type (); +extern bool_t xdr_rpc_loc_calendar_time_s_type (); +extern bool_t xdr_rpc_loc_parsed_position_s_type (); +extern bool_t xdr_rpc_loc_sv_system_e_type (); +extern bool_t xdr_rpc_loc_sv_status_e_type (); +extern bool_t xdr_rpc_loc_sv_info_valid_mask_type (); +extern bool_t xdr_rpc_loc_sv_info_s_type (); +extern bool_t xdr_rpc_loc_gnss_info_valid_mask_type (); +extern bool_t xdr_rpc_loc_gnss_info_s_type (); +extern bool_t xdr_rpc_loc_nmea_report_s_type (); +extern bool_t xdr_rpc_loc_status_event_e_type (); +extern bool_t xdr_rpc_loc_engine_state_e_type (); +extern bool_t xdr_rpc_loc_fix_session_state_e_type (); +extern bool_t xdr_rpc_loc_status_event_payload_u_type (); +extern bool_t xdr_rpc_loc_status_event_s_type (); +extern bool_t xdr_rpc_loc_server_addr_e_type (); +extern bool_t xdr_rpc_loc_server_addr_ipv4_type (); +extern bool_t xdr_rpc_loc_server_addr_url_type (); +extern bool_t xdr_rpc_loc_server_addr_ipv6_type (); +extern bool_t xdr_rpc_loc_server_addr_u_type (); +extern bool_t xdr_rpc_loc_server_info_s_type (); +extern bool_t xdr_rpc_loc_ni_notify_verify_e_type (); +extern bool_t xdr_rpc_loc_ni_event_e_type (); +extern bool_t xdr_rpc_loc_ni_datacoding_scheme_e_type (); +extern bool_t xdr_rpc_loc_ni_vx_requester_id_encoding_scheme_e_type (); +extern bool_t xdr_rpc_loc_ni_vx_pos_mode_e_type (); +extern bool_t xdr_rpc_loc_ni_vx_requester_id_s_type (); +extern bool_t xdr_rpc_loc_ni_vx_notify_verify_req_s_type (); +extern bool_t xdr_rpc_loc_ni_supl_pos_method_e_type (); +extern bool_t xdr_rpc_loc_ni_supl_slp_session_id_s_type (); +extern bool_t xdr_rpc_loc_ni_requestor_id_s_type (); +extern bool_t xdr_rpc_loc_ni_supl_client_name_s_type (); +extern bool_t xdr_rpc_loc_ni_supl_qop_s_type (); +extern bool_t xdr_rpc_loc_ni_supl_notify_verify_req_s_type (); +extern bool_t xdr_rpc_loc_ni_ext_client_address_s_type (); +extern bool_t xdr_rpc_loc_ni_location_type_e_type (); +extern bool_t xdr_rpc_loc_ni_deferred_location_s_type (); +extern bool_t xdr_rpc_loc_ni_codeword_string_s_type (); +extern bool_t xdr_rpc_loc_ni_service_type_id_s_type (); +extern bool_t xdr_rpc_loc_ni_umts_cp_notify_verify_req_s_type (); +extern bool_t xdr_rpc_loc_ni_service_interaction_e_type (); +extern bool_t xdr_rpc_loc_ni_vx_service_interaction_req_s_type (); +extern bool_t xdr_rpc_loc_ni_event_payload_u_type (); +extern bool_t xdr_rpc_loc_ni_event_s_type (); +extern bool_t xdr_rpc_loc_assist_data_request_e_type (); +extern bool_t xdr_rpc_struct_loc_time_download_source_s_type_servers_ptr (); +extern bool_t xdr_rpc_struct_loc_time_download_source_s_type_servers (); +extern bool_t xdr_rpc_loc_time_download_source_s_type (); +extern bool_t xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr (); +extern bool_t xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers (); +extern bool_t xdr_rpc_loc_predicted_orbits_data_source_s_type (); +extern bool_t xdr_rpc_loc_pos_inj_request_s_type (); +extern bool_t xdr_rpc_loc_assist_data_request_payload_u_type (); +extern bool_t xdr_rpc_loc_assist_data_request_s_type (); +extern bool_t xdr_rpc_loc_server_connection_handle (); +extern bool_t xdr_rpc_loc_server_protocol_e_type (); +extern bool_t xdr_rpc_loc_server_connection_e_type (); +extern bool_t xdr_rpc_loc_server_request_e_type (); +extern bool_t xdr_rpc_loc_server_open_req_s_type (); +extern bool_t xdr_rpc_loc_server_multi_open_req_s_type (); +extern bool_t xdr_rpc_loc_server_close_req_s_type (); +extern bool_t xdr_rpc_loc_server_request_u_type (); +extern bool_t xdr_rpc_loc_server_request_s_type (); +extern bool_t xdr_rpc_loc_qwip_request_e_type (); +extern bool_t xdr_rpc_loc_qwip_request_s_type (); +extern bool_t xdr_rpc_loc_reserved_payload_s_type (); +extern bool_t xdr_rpc_loc_ioctl_e_type (); +extern bool_t xdr_rpc_loc_api_version_s_type (); +extern bool_t xdr_rpc_loc_fix_recurrence_e_type (); +extern bool_t xdr_rpc_loc_operation_mode_e_type (); +extern bool_t xdr_rpc_loc_notify_e_type (); +extern bool_t xdr_rpc_loc_fix_criteria_s_type (); +extern bool_t xdr_rpc_loc_ni_user_resp_e_type (); +extern bool_t xdr_rpc_loc_user_verify_s_type (); +extern bool_t xdr_rpc_loc_predicted_orbits_data_format_e_type (); +extern bool_t xdr_rpc_loc_predicted_orbits_data_s_type (); +extern bool_t xdr_rpc_loc_predicted_orbits_data_validity_report_s_type (); +extern bool_t xdr_rpc_loc_predicted_orbits_auto_download_config_s_type (); +extern bool_t xdr_rpc_loc_assist_data_time_s_type (); +extern bool_t xdr_rpc_loc_assist_pos_valid_mask_type (); +extern bool_t xdr_rpc_loc_assist_data_pos_s_type (); +extern bool_t xdr_rpc_loc_server_open_status_e_type (); +extern bool_t xdr_rpc_loc_server_pdp_type_e_type (); +extern bool_t xdr_rpc_loc_server_open_status_s_type (); +extern bool_t xdr_rpc_loc_server_multi_open_status_s_type (); +extern bool_t xdr_rpc_loc_server_close_status_e_type (); +extern bool_t xdr_rpc_loc_server_close_status_s_type (); +extern bool_t xdr_rpc_loc_wiper_fix_time_s_type (); +extern bool_t xdr_rpc_loc_wiper_fix_pos_s_type (); +extern bool_t xdr_rpc_loc_wiper_ap_info_s_type (); +extern bool_t xdr_rpc_loc_wiper_ap_set_s_type (); +extern bool_t xdr_rpc_loc_wiper_position_report_s_type (); +extern bool_t xdr_rpc_loc_wiper_status_e_type (); +extern bool_t xdr_rpc_loc_fs_operation_e_type (); +extern bool_t xdr_rpc_loc_efs_data_s_type (); +extern bool_t xdr_rpc_loc_error_estimate_config_e_type (); +extern bool_t xdr_rpc_loc_apn_profiles_type (); +extern bool_t xdr_rpc_loc_lock_e_type (); +extern bool_t xdr_rpc_loc_nmea_sentence_type (); +extern bool_t xdr_rpc_loc_assist_data_type (); +extern bool_t xdr_rpc_loc_assist_data_delete_s_type (); +extern bool_t xdr_rpc_loc_ioctl_data_u_type (); +extern bool_t xdr_rpc_loc_ioctl_callback_data_u_type (); +extern bool_t xdr_rpc_loc_ioctl_callback_s_type (); +extern bool_t xdr_rpc_loc_event_payload_u_type (); + +#endif /* K&R C */ + +#ifdef __cplusplus +} +#endif + +#endif /* !_LOC_API_COMMON_RPC_H_RPCGEN */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h new file mode 100755 index 00000000..f11bb654 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h @@ -0,0 +1,288 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#ifndef _LOC_API_RPC_H_RPCGEN +#define _LOC_API_RPC_H_RPCGEN + +#include "librpc.h" +#include "commondefs_rpcgen_rpc.h" +#include "loc_api_rpcgen_common_rpc.h" + +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +typedef struct { + u_int rpc_loc_api_api_versions_return_type_len; + rpc_uint32 *rpc_loc_api_api_versions_return_type_val; +} rpc_loc_api_api_versions_return_type; + +typedef rpc_uint32 rpc_loc_event_cb_f_type; + +struct rpc_loc_open_args { + rpc_loc_event_mask_type event_reg_mask; + rpc_loc_event_cb_f_type event_callback; +}; +typedef struct rpc_loc_open_args rpc_loc_open_args; + +struct rpc_loc_close_args { + rpc_loc_client_handle_type handle; +}; +typedef struct rpc_loc_close_args rpc_loc_close_args; + +struct rpc_loc_start_fix_args { + rpc_loc_client_handle_type handle; +}; +typedef struct rpc_loc_start_fix_args rpc_loc_start_fix_args; + +struct rpc_loc_stop_fix_args { + rpc_loc_client_handle_type handle; +}; +typedef struct rpc_loc_stop_fix_args rpc_loc_stop_fix_args; + +struct rpc_loc_ioctl_args { + rpc_loc_client_handle_type handle; + rpc_loc_ioctl_e_type ioctl_type; + rpc_loc_ioctl_data_u_type *ioctl_data; +}; +typedef struct rpc_loc_ioctl_args rpc_loc_ioctl_args; + +struct rpc_loc_api_api_version_s_args { + rpc_boolean len_not_null; +}; +typedef struct rpc_loc_api_api_version_s_args rpc_loc_api_api_version_s_args; + +struct rpc_loc_api_rpc_glue_code_info_remote_rets { + rpc_uint32 toolvers; + rpc_uint32 features; + rpc_uint32 proghash; + rpc_uint32 cbproghash; +}; +typedef struct rpc_loc_api_rpc_glue_code_info_remote_rets rpc_loc_api_rpc_glue_code_info_remote_rets; + +struct rpc_loc_open_rets { + rpc_loc_client_handle_type loc_open_result; +}; +typedef struct rpc_loc_open_rets rpc_loc_open_rets; + +struct rpc_loc_close_rets { + rpc_int32 loc_close_result; +}; +typedef struct rpc_loc_close_rets rpc_loc_close_rets; + +struct rpc_loc_start_fix_rets { + rpc_int32 loc_start_fix_result; +}; +typedef struct rpc_loc_start_fix_rets rpc_loc_start_fix_rets; + +struct rpc_loc_stop_fix_rets { + rpc_int32 loc_stop_fix_result; +}; +typedef struct rpc_loc_stop_fix_rets rpc_loc_stop_fix_rets; + +struct rpc_loc_ioctl_rets { + rpc_int32 loc_ioctl_result; +}; +typedef struct rpc_loc_ioctl_rets rpc_loc_ioctl_rets; + +struct rpc_loc_api_api_versions_rets { + rpc_loc_api_api_versions_return_type loc_api_api_versions_result; + rpc_uint32 *len; +}; +typedef struct rpc_loc_api_api_versions_rets rpc_loc_api_api_versions_rets; +#define LOC_APIVERS 0x00050006 + +#define LOC_APIPROG 0x3000008C +#define LOC_APIVERS_0001 0x00050001 + +#if defined(__STDC__) || defined(__cplusplus) +#define rpc_loc_api_null 0 +extern enum clnt_stat rpc_loc_api_null_0x00050001(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050001_svc(void *, void *, struct svc_req *); +#define rpc_loc_api_rpc_glue_code_info_remote 1 +extern enum clnt_stat rpc_loc_api_rpc_glue_code_info_remote_0x00050001(void *, rpc_loc_api_rpc_glue_code_info_remote_rets *, CLIENT *); +extern bool_t rpc_loc_api_rpc_glue_code_info_remote_0x00050001_svc(void *, rpc_loc_api_rpc_glue_code_info_remote_rets *, struct svc_req *); +#define rpc_loc_open 2 +extern enum clnt_stat rpc_loc_open_0x00050001(rpc_loc_open_args *, rpc_loc_open_rets *, CLIENT *); +extern bool_t rpc_loc_open_0x00050001_svc(rpc_loc_open_args *, rpc_loc_open_rets *, struct svc_req *); +#define rpc_loc_close 3 +extern enum clnt_stat rpc_loc_close_0x00050001(rpc_loc_close_args *, rpc_loc_close_rets *, CLIENT *); +extern bool_t rpc_loc_close_0x00050001_svc(rpc_loc_close_args *, rpc_loc_close_rets *, struct svc_req *); +#define rpc_loc_start_fix 4 +extern enum clnt_stat rpc_loc_start_fix_0x00050001(rpc_loc_start_fix_args *, rpc_loc_start_fix_rets *, CLIENT *); +extern bool_t rpc_loc_start_fix_0x00050001_svc(rpc_loc_start_fix_args *, rpc_loc_start_fix_rets *, struct svc_req *); +#define rpc_loc_stop_fix 5 +extern enum clnt_stat rpc_loc_stop_fix_0x00050001(rpc_loc_stop_fix_args *, rpc_loc_stop_fix_rets *, CLIENT *); +extern bool_t rpc_loc_stop_fix_0x00050001_svc(rpc_loc_stop_fix_args *, rpc_loc_stop_fix_rets *, struct svc_req *); +#define rpc_loc_ioctl 6 +extern enum clnt_stat rpc_loc_ioctl_0x00050001(rpc_loc_ioctl_args *, rpc_loc_ioctl_rets *, CLIENT *); +extern bool_t rpc_loc_ioctl_0x00050001_svc(rpc_loc_ioctl_args *, rpc_loc_ioctl_rets *, struct svc_req *); +#define rpc_loc_api_api_versions 0xFFFFFFFF +extern enum clnt_stat rpc_loc_api_api_versions_0x00050001(void *, rpc_loc_api_api_versions_rets *, CLIENT *); +extern bool_t rpc_loc_api_api_versions_0x00050001_svc(void *, rpc_loc_api_api_versions_rets *, struct svc_req *); +extern int loc_apiprog_0x00050001_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +#define rpc_loc_api_null 0 +extern enum clnt_stat rpc_loc_api_null_0x00050001(); +extern bool_t rpc_loc_api_null_0x00050001_svc(); +#define rpc_loc_api_rpc_glue_code_info_remote 1 +extern enum clnt_stat rpc_loc_api_rpc_glue_code_info_remote_0x00050001(); +extern bool_t rpc_loc_api_rpc_glue_code_info_remote_0x00050001_svc(); +#define rpc_loc_open 2 +extern enum clnt_stat rpc_loc_open_0x00050001(); +extern bool_t rpc_loc_open_0x00050001_svc(); +#define rpc_loc_close 3 +extern enum clnt_stat rpc_loc_close_0x00050001(); +extern bool_t rpc_loc_close_0x00050001_svc(); +#define rpc_loc_start_fix 4 +extern enum clnt_stat rpc_loc_start_fix_0x00050001(); +extern bool_t rpc_loc_start_fix_0x00050001_svc(); +#define rpc_loc_stop_fix 5 +extern enum clnt_stat rpc_loc_stop_fix_0x00050001(); +extern bool_t rpc_loc_stop_fix_0x00050001_svc(); +#define rpc_loc_ioctl 6 +extern enum clnt_stat rpc_loc_ioctl_0x00050001(); +extern bool_t rpc_loc_ioctl_0x00050001_svc(); +#define rpc_loc_api_api_versions 0xFFFFFFFF +extern enum clnt_stat rpc_loc_api_api_versions_0x00050001(); +extern bool_t rpc_loc_api_api_versions_0x00050001_svc(); +extern int loc_apiprog_0x00050001_freeresult (); +#endif /* K&R C */ +#define LOC_APIVERS_0002 0x00050002 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_null_0x00050002(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050002_svc(void *, void *, struct svc_req *); +extern int loc_apiprog_0x00050002_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_null_0x00050002(); +extern bool_t rpc_loc_api_null_0x00050002_svc(); +extern int loc_apiprog_0x00050002_freeresult (); +#endif /* K&R C */ +#define LOC_APIVERS_0003 0x00050003 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_null_0x00050003(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050003_svc(void *, void *, struct svc_req *); +extern int loc_apiprog_0x00050003_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_null_0x00050003(); +extern bool_t rpc_loc_api_null_0x00050003_svc(); +extern int loc_apiprog_0x00050003_freeresult (); +#endif /* K&R C */ +#define LOC_APIVERS_0004 0x00050004 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_null_0x00050004(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050004_svc(void *, void *, struct svc_req *); +extern int loc_apiprog_0x00050004_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_null_0x00050004(); +extern bool_t rpc_loc_api_null_0x00050004_svc(); +extern int loc_apiprog_0x00050004_freeresult (); +#endif /* K&R C */ +#define LOC_APIVERS_0005 0x00050005 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_null_0x00050005(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050005_svc(void *, void *, struct svc_req *); +extern int loc_apiprog_0x00050005_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_null_0x00050005(); +extern bool_t rpc_loc_api_null_0x00050005_svc(); +extern int loc_apiprog_0x00050005_freeresult (); +#endif /* K&R C */ +#define LOC_APIVERS_0006 0x00050006 + +#if defined(__STDC__) || defined(__cplusplus) +extern enum clnt_stat rpc_loc_api_null_0x00050006(void *, void *, CLIENT *); +extern bool_t rpc_loc_api_null_0x00050006_svc(void *, void *, struct svc_req *); +extern int loc_apiprog_0x00050006_freeresult (SVCXPRT *, xdrproc_t, caddr_t); + +#else /* K&R C */ +extern enum clnt_stat rpc_loc_api_null_0x00050006(); +extern bool_t rpc_loc_api_null_0x00050006_svc(); +extern int loc_apiprog_0x00050006_freeresult (); +#endif /* K&R C */ + +/* the xdr functions */ + +#if defined(__STDC__) || defined(__cplusplus) +extern bool_t xdr_rpc_loc_api_api_versions_return_type (XDR *, rpc_loc_api_api_versions_return_type*); +extern bool_t xdr_rpc_loc_event_cb_f_type (XDR *, rpc_loc_event_cb_f_type*); +extern bool_t xdr_rpc_loc_open_args (XDR *, rpc_loc_open_args*); +extern bool_t xdr_rpc_loc_close_args (XDR *, rpc_loc_close_args*); +extern bool_t xdr_rpc_loc_start_fix_args (XDR *, rpc_loc_start_fix_args*); +extern bool_t xdr_rpc_loc_stop_fix_args (XDR *, rpc_loc_stop_fix_args*); +extern bool_t xdr_rpc_loc_ioctl_args (XDR *, rpc_loc_ioctl_args*); +extern bool_t xdr_rpc_loc_api_api_version_s_args (XDR *, rpc_loc_api_api_version_s_args*); +extern bool_t xdr_rpc_loc_api_rpc_glue_code_info_remote_rets (XDR *, rpc_loc_api_rpc_glue_code_info_remote_rets*); +extern bool_t xdr_rpc_loc_open_rets (XDR *, rpc_loc_open_rets*); +extern bool_t xdr_rpc_loc_close_rets (XDR *, rpc_loc_close_rets*); +extern bool_t xdr_rpc_loc_start_fix_rets (XDR *, rpc_loc_start_fix_rets*); +extern bool_t xdr_rpc_loc_stop_fix_rets (XDR *, rpc_loc_stop_fix_rets*); +extern bool_t xdr_rpc_loc_ioctl_rets (XDR *, rpc_loc_ioctl_rets*); +extern bool_t xdr_rpc_loc_api_api_versions_rets (XDR *, rpc_loc_api_api_versions_rets*); + +#else /* K&R C */ +extern bool_t xdr_rpc_loc_api_api_versions_return_type (); +extern bool_t xdr_rpc_loc_event_cb_f_type (); +extern bool_t xdr_rpc_loc_open_args (); +extern bool_t xdr_rpc_loc_close_args (); +extern bool_t xdr_rpc_loc_start_fix_args (); +extern bool_t xdr_rpc_loc_stop_fix_args (); +extern bool_t xdr_rpc_loc_ioctl_args (); +extern bool_t xdr_rpc_loc_api_api_version_s_args (); +extern bool_t xdr_rpc_loc_api_rpc_glue_code_info_remote_rets (); +extern bool_t xdr_rpc_loc_open_rets (); +extern bool_t xdr_rpc_loc_close_rets (); +extern bool_t xdr_rpc_loc_start_fix_rets (); +extern bool_t xdr_rpc_loc_stop_fix_rets (); +extern bool_t xdr_rpc_loc_ioctl_rets (); +extern bool_t xdr_rpc_loc_api_api_versions_rets (); + +#endif /* K&R C */ + +#ifdef __cplusplus +} +#endif + +#endif /* !_LOC_API_RPC_H_RPCGEN */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h new file mode 100755 index 00000000..e109852c --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h @@ -0,0 +1,34 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +/* Initialization function for callbacks */ +int loc_apicb_app_init(); + +void loc_apicb_app_deinit(); + diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c new file mode 100755 index 00000000..b0443487 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c @@ -0,0 +1,327 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#include "loc_api_rpcgen_cb_rpc.h" +#include +#include +#include +#include +#include +#include +#include + +#ifndef SIG_PF +#define SIG_PF void(*)(int) +#endif + +void +loc_apicbprog_0x00050001(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + rpc_loc_event_cb_f_type_args rpc_loc_event_cb_f_type_0x00050001_arg; + } argument; + union { + rpc_loc_event_cb_f_type_rets rpc_loc_event_cb_f_type_0x00050001_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_event_cb_f_type: + _xdr_argument = (xdrproc_t) xdr_rpc_loc_event_cb_f_type_args; + _xdr_result = (xdrproc_t) xdr_rpc_loc_event_cb_f_type_rets; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_event_cb_f_type_0x00050001_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050001_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} + +void +loc_apicbprog_0x00050002(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + int fill; + } argument; + union { + int rpc_loc_api_cb_null_0x00050002_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_api_cb_null: + _xdr_argument = (xdrproc_t) xdr_void; + _xdr_result = (xdrproc_t) xdr_int; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_api_cb_null_0x00050002_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050002_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} + +void +loc_apicbprog_0x00050003(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + int fill; + } argument; + union { + int rpc_loc_api_cb_null_0x00050003_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_api_cb_null: + _xdr_argument = (xdrproc_t) xdr_void; + _xdr_result = (xdrproc_t) xdr_int; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_api_cb_null_0x00050003_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050003_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} + +void +loc_apicbprog_0x00050004(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + int fill; + } argument; + union { + int rpc_loc_api_cb_null_0x00050004_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_api_cb_null: + _xdr_argument = (xdrproc_t) xdr_void; + _xdr_result = (xdrproc_t) xdr_int; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_api_cb_null_0x00050004_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050004_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} + +void +loc_apicbprog_0x00050005(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + int fill; + } argument; + union { + int rpc_loc_api_cb_null_0x00050005_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_api_cb_null: + _xdr_argument = (xdrproc_t) xdr_void; + _xdr_result = (xdrproc_t) xdr_int; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_api_cb_null_0x00050005_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050005_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} + +void +loc_apicbprog_0x00050006(struct svc_req *rqstp, register SVCXPRT *transp) +{ + union { + int fill; + } argument; + union { + int rpc_loc_api_cb_null_0x00050006_res; + } result; + bool_t retval; + xdrproc_t _xdr_argument, _xdr_result; + bool_t (*local)(char *, void *, struct svc_req *); + + switch (rqstp->rq_proc) { + case NULLPROC: + (void) svc_sendreply (transp, (xdrproc_t) xdr_void, (char *)NULL); + return; + + case rpc_loc_api_cb_null: + _xdr_argument = (xdrproc_t) xdr_void; + _xdr_result = (xdrproc_t) xdr_int; + local = (bool_t (*) (char *, void *, struct svc_req *))rpc_loc_api_cb_null_0x00050006_svc; + break; + + default: + svcerr_noproc (transp); + return; + } + memset ((char *)&argument, 0, sizeof (argument)); + if (!svc_getargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + svcerr_decode (transp); + return; + } + retval = (bool_t) (*local)((char *)&argument, (void *)&result, rqstp); + if (retval > 0 && !svc_sendreply(transp, (xdrproc_t) _xdr_result, (char *)&result)) { + svcerr_systemerr (transp); + } + if (!svc_freeargs (transp, (xdrproc_t) _xdr_argument, (caddr_t) &argument)) { + fprintf (stderr, "%s", "unable to free arguments"); + exit (1); + } + if (!loc_apicbprog_0x00050006_freeresult (transp, _xdr_result, (caddr_t) &result)) + fprintf (stderr, "%s", "unable to free results"); + + return; +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c new file mode 100755 index 00000000..7f519281 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c @@ -0,0 +1,60 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#include "loc_api_rpcgen_cb_rpc.h" + +bool_t +xdr_rpc_loc_event_cb_f_type_args (XDR *xdrs, rpc_loc_event_cb_f_type_args *objp) +{ +; + + if (!xdr_rpc_uint32 (xdrs, &objp->cb_id)) + return FALSE; + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->loc_handle)) + return FALSE; + if (!xdr_rpc_loc_event_mask_type (xdrs, &objp->loc_event)) + return FALSE; + if (!xdr_pointer (xdrs, (char **)&objp->loc_event_payload, sizeof (rpc_loc_event_payload_u_type), (xdrproc_t) xdr_rpc_loc_event_payload_u_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_event_cb_f_type_rets (XDR *xdrs, rpc_loc_event_cb_f_type_rets *objp) +{ +; + + if (!xdr_rpc_int32 (xdrs, &objp->loc_event_cb_f_type_result)) + return FALSE; + return TRUE; +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c new file mode 100755 index 00000000..d2152ab4 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c @@ -0,0 +1,155 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#include /* for memset */ +#include "loc_api_rpcgen_rpc.h" + +/* Default timeout can be changed using clnt_control() */ +static struct timeval TIMEOUT = { 25, 0 }; + +enum clnt_stat +rpc_loc_api_null_0x00050001(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_rpc_glue_code_info_remote_0x00050001(void *argp, rpc_loc_api_rpc_glue_code_info_remote_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_rpc_glue_code_info_remote, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_api_rpc_glue_code_info_remote_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_open_0x00050001(rpc_loc_open_args *argp, rpc_loc_open_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_open, + (xdrproc_t) xdr_rpc_loc_open_args, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_open_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_close_0x00050001(rpc_loc_close_args *argp, rpc_loc_close_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_close, + (xdrproc_t) xdr_rpc_loc_close_args, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_close_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_start_fix_0x00050001(rpc_loc_start_fix_args *argp, rpc_loc_start_fix_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_start_fix, + (xdrproc_t) xdr_rpc_loc_start_fix_args, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_start_fix_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_stop_fix_0x00050001(rpc_loc_stop_fix_args *argp, rpc_loc_stop_fix_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_stop_fix, + (xdrproc_t) xdr_rpc_loc_stop_fix_args, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_stop_fix_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_ioctl_0x00050001(rpc_loc_ioctl_args *argp, rpc_loc_ioctl_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_ioctl, + (xdrproc_t) xdr_rpc_loc_ioctl_args, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_ioctl_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_api_versions_0x00050001(void *argp, rpc_loc_api_api_versions_rets *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_api_versions, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_rpc_loc_api_api_versions_rets, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_null_0x00050002(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_null_0x00050003(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_null_0x00050004(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_null_0x00050005(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} + +enum clnt_stat +rpc_loc_api_null_0x00050006(void *argp, void *clnt_res, CLIENT *clnt) +{ + return (clnt_call(clnt, rpc_loc_api_null, + (xdrproc_t) xdr_void, (caddr_t) argp, + (xdrproc_t) xdr_void, (caddr_t) clnt_res, + TIMEOUT)); +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c new file mode 100755 index 00000000..da066b42 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c @@ -0,0 +1,1775 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#include "loc_api_rpcgen_common_rpc.h" + +bool_t +xdr_rpc_loc_client_handle_type (XDR *xdrs, rpc_loc_client_handle_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_int32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_event_mask_type (XDR *xdrs, rpc_loc_event_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint64 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_position_valid_mask_type (XDR *xdrs, rpc_loc_position_valid_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint64 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_pos_technology_mask_type (XDR *xdrs, rpc_loc_pos_technology_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_session_status_e_type (XDR *xdrs, rpc_loc_session_status_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_calendar_time_s_type (XDR *xdrs, rpc_loc_calendar_time_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint16 (xdrs, &objp->year)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->month)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->day_of_week)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->day)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->hour)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->minute)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->second)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->millisecond)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_parsed_position_s_type (XDR *xdrs, rpc_loc_parsed_position_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_position_valid_mask_type (xdrs, &objp->valid_mask)) + return FALSE; + if (!xdr_rpc_loc_session_status_e_type (xdrs, &objp->session_status)) + return FALSE; + if (!xdr_rpc_loc_calendar_time_s_type (xdrs, &objp->timestamp_calendar)) + return FALSE; + if (!xdr_rpc_uint64 (xdrs, &objp->timestamp_utc)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->leap_seconds)) + return FALSE; + if (!xdr_float (xdrs, &objp->time_unc)) + return FALSE; + if (!xdr_double (xdrs, &objp->latitude)) + return FALSE; + if (!xdr_double (xdrs, &objp->longitude)) + return FALSE; + if (!xdr_float (xdrs, &objp->altitude_wrt_ellipsoid)) + return FALSE; + if (!xdr_float (xdrs, &objp->altitude_wrt_mean_sea_level)) + return FALSE; + if (!xdr_float (xdrs, &objp->speed_horizontal)) + return FALSE; + if (!xdr_float (xdrs, &objp->speed_vertical)) + return FALSE; + if (!xdr_float (xdrs, &objp->heading)) + return FALSE; + if (!xdr_float (xdrs, &objp->hor_unc_circular)) + return FALSE; + if (!xdr_float (xdrs, &objp->hor_unc_ellipse_semi_major)) + return FALSE; + if (!xdr_float (xdrs, &objp->hor_unc_ellipse_semi_minor)) + return FALSE; + if (!xdr_float (xdrs, &objp->hor_unc_ellipse_orient_azimuth)) + return FALSE; + if (!xdr_float (xdrs, &objp->vert_unc)) + return FALSE; + if (!xdr_float (xdrs, &objp->speed_unc)) + return FALSE; + if (!xdr_float (xdrs, &objp->heading_unc)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->confidence_horizontal)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->confidence_vertical)) + return FALSE; + if (!xdr_float (xdrs, &objp->magnetic_deviation)) + return FALSE; + if (!xdr_rpc_loc_pos_technology_mask_type (xdrs, &objp->technology_mask)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_sv_system_e_type (XDR *xdrs, rpc_loc_sv_system_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_sv_status_e_type (XDR *xdrs, rpc_loc_sv_status_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_sv_info_valid_mask_type (XDR *xdrs, rpc_loc_sv_info_valid_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_sv_info_s_type (XDR *xdrs, rpc_loc_sv_info_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_sv_info_valid_mask_type (xdrs, &objp->valid_mask)) + return FALSE; + if (!xdr_rpc_loc_sv_system_e_type (xdrs, &objp->system)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->prn)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->health_status)) + return FALSE; + if (!xdr_rpc_loc_sv_status_e_type (xdrs, &objp->process_status)) + return FALSE; + if (!xdr_rpc_boolean (xdrs, &objp->has_eph)) + return FALSE; + if (!xdr_rpc_boolean (xdrs, &objp->has_alm)) + return FALSE; + if (!xdr_float (xdrs, &objp->elevation)) + return FALSE; + if (!xdr_float (xdrs, &objp->azimuth)) + return FALSE; + if (!xdr_float (xdrs, &objp->snr)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_gnss_info_valid_mask_type (XDR *xdrs, rpc_loc_gnss_info_valid_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_gnss_info_s_type (XDR *xdrs, rpc_loc_gnss_info_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_gnss_info_valid_mask_type (xdrs, &objp->valid_mask)) + return FALSE; + if (!xdr_float (xdrs, &objp->position_dop)) + return FALSE; + if (!xdr_float (xdrs, &objp->horizontal_dop)) + return FALSE; + if (!xdr_float (xdrs, &objp->vertical_dop)) + return FALSE; + if (!xdr_rpc_boolean (xdrs, &objp->altitude_assumed)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->sv_count)) + return FALSE; + if (!xdr_array (xdrs, (char **)&objp->sv_list.sv_list_val, (u_int *) &objp->sv_list.sv_list_len, 80, + sizeof (rpc_loc_sv_info_s_type), (xdrproc_t) xdr_rpc_loc_sv_info_s_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_nmea_report_s_type (XDR *xdrs, rpc_loc_nmea_report_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_uint16 (xdrs, &objp->length)) + return FALSE; + if (!xdr_opaque (xdrs, objp->nmea_sentences, 200)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_status_event_e_type (XDR *xdrs, rpc_loc_status_event_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_engine_state_e_type (XDR *xdrs, rpc_loc_engine_state_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_fix_session_state_e_type (XDR *xdrs, rpc_loc_fix_session_state_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_status_event_payload_u_type (XDR *xdrs, rpc_loc_status_event_payload_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_status_event_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_STATUS_EVENT_ENGINE_STATE: + if (!xdr_rpc_loc_engine_state_e_type (xdrs, &objp->rpc_loc_status_event_payload_u_type_u.engine_state)) + return FALSE; + break; + case RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE: + if (!xdr_rpc_loc_fix_session_state_e_type (xdrs, &objp->rpc_loc_status_event_payload_u_type_u.fix_session_state)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_status_event_s_type (XDR *xdrs, rpc_loc_status_event_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_status_event_e_type (xdrs, &objp->event)) + return FALSE; + if (!xdr_rpc_loc_status_event_payload_u_type (xdrs, &objp->payload)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_addr_e_type (XDR *xdrs, rpc_loc_server_addr_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_addr_ipv4_type (XDR *xdrs, rpc_loc_server_addr_ipv4_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->addr)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->port)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_addr_url_type (XDR *xdrs, rpc_loc_server_addr_url_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_uint16 (xdrs, &objp->length)) + return FALSE; + if (!xdr_opaque (xdrs, objp->addr, 256)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_addr_ipv6_type (XDR *xdrs, rpc_loc_server_addr_ipv6_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_vector (xdrs, (char *)objp->addr, 8, + sizeof (rpc_uint16), (xdrproc_t) xdr_rpc_uint16)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->port)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_addr_u_type (XDR *xdrs, rpc_loc_server_addr_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_addr_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_SERVER_ADDR_IPV4: + if (!xdr_rpc_loc_server_addr_ipv4_type (xdrs, &objp->rpc_loc_server_addr_u_type_u.ipv4)) + return FALSE; + break; + case RPC_LOC_SERVER_ADDR_URL: + if (!xdr_rpc_loc_server_addr_url_type (xdrs, &objp->rpc_loc_server_addr_u_type_u.url)) + return FALSE; + break; + case RPC_LOC_SERVER_ADDR_IPV6: + if (!xdr_rpc_loc_server_addr_ipv6_type (xdrs, &objp->rpc_loc_server_addr_u_type_u.ipv6)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_server_info_s_type (XDR *xdrs, rpc_loc_server_info_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_addr_e_type (xdrs, &objp->addr_type)) + return FALSE; + if (!xdr_rpc_loc_server_addr_u_type (xdrs, &objp->addr_info)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_notify_verify_e_type (XDR *xdrs, rpc_loc_ni_notify_verify_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_event_e_type (XDR *xdrs, rpc_loc_ni_event_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_datacoding_scheme_e_type (XDR *xdrs, rpc_loc_ni_datacoding_scheme_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_vx_requester_id_encoding_scheme_e_type (XDR *xdrs, rpc_loc_ni_vx_requester_id_encoding_scheme_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_vx_pos_mode_e_type (XDR *xdrs, rpc_loc_ni_vx_pos_mode_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_vx_requester_id_s_type (XDR *xdrs, rpc_loc_ni_vx_requester_id_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->requester_id_length)) + return FALSE; + if (!xdr_opaque (xdrs, objp->requester_id, 200)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_vx_notify_verify_req_s_type (XDR *xdrs, rpc_loc_ni_vx_notify_verify_req_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ni_notify_verify_e_type (xdrs, &objp->notification_priv_type)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->pos_qos_incl)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->pos_qos)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->num_fixes)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->tbf)) + return FALSE; + if (!xdr_rpc_loc_ni_vx_pos_mode_e_type (xdrs, &objp->pos_mode)) + return FALSE; + if (!xdr_rpc_loc_ni_vx_requester_id_encoding_scheme_e_type (xdrs, &objp->encoding_scheme)) + return FALSE; + if (!xdr_rpc_loc_ni_vx_requester_id_s_type (xdrs, &objp->requester_id)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->user_resp_timer_val)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_supl_pos_method_e_type (XDR *xdrs, rpc_loc_ni_supl_pos_method_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_supl_slp_session_id_s_type (XDR *xdrs, rpc_loc_ni_supl_slp_session_id_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->presence)) + return FALSE; + if (!xdr_opaque (xdrs, objp->session_id, 4)) + return FALSE; + if (!xdr_rpc_loc_server_info_s_type (xdrs, &objp->slp_address)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_requestor_id_s_type (XDR *xdrs, rpc_loc_ni_requestor_id_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->data_coding_scheme)) + return FALSE; + if (!xdr_opaque (xdrs, objp->requestor_id_string, 200)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->string_len)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_supl_client_name_s_type (XDR *xdrs, rpc_loc_ni_supl_client_name_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->data_coding_scheme)) + return FALSE; + if (!xdr_opaque (xdrs, objp->client_name_string, 64)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->string_len)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_supl_qop_s_type (XDR *xdrs, rpc_loc_ni_supl_qop_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_u_char (xdrs, &objp->bit_mask)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->horacc)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->veracc)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->maxLocAge)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->delay)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_supl_notify_verify_req_s_type (XDR *xdrs, rpc_loc_ni_supl_notify_verify_req_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_loc_ni_notify_verify_e_type (xdrs, &objp->notification_priv_type)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->flags)) + return FALSE; + if (!xdr_rpc_loc_ni_supl_slp_session_id_s_type (xdrs, &objp->supl_slp_session_id)) + return FALSE; + if (!xdr_opaque (xdrs, objp->supl_hash, 8)) + return FALSE; + if (!xdr_rpc_loc_ni_datacoding_scheme_e_type (xdrs, &objp->datacoding_scheme)) + return FALSE; + if (!xdr_rpc_loc_ni_supl_pos_method_e_type (xdrs, &objp->pos_method)) + return FALSE; + if (!xdr_rpc_loc_ni_requestor_id_s_type (xdrs, &objp->requestor_id)) + return FALSE; + if (!xdr_rpc_loc_ni_supl_client_name_s_type (xdrs, &objp->client_name)) + return FALSE; + if (!xdr_rpc_loc_ni_supl_qop_s_type (xdrs, &objp->supl_qop)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->user_response_timer)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_ext_client_address_s_type (XDR *xdrs, rpc_loc_ni_ext_client_address_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->ext_client_address_len)) + return FALSE; + if (!xdr_opaque (xdrs, objp->ext_client_address, 20)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_location_type_e_type (XDR *xdrs, rpc_loc_ni_location_type_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_deferred_location_s_type (XDR *xdrs, rpc_loc_ni_deferred_location_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_u_char (xdrs, &objp->unused_bits)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->ms_available)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_codeword_string_s_type (XDR *xdrs, rpc_loc_ni_codeword_string_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_u_char (xdrs, &objp->data_coding_scheme)) + return FALSE; + if (!xdr_opaque (xdrs, objp->lcs_codeword_string, 20)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->string_len)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_service_type_id_s_type (XDR *xdrs, rpc_loc_ni_service_type_id_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_u_char (xdrs, &objp->lcs_service_type_id)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_umts_cp_notify_verify_req_s_type (XDR *xdrs, rpc_loc_ni_umts_cp_notify_verify_req_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_loc_ni_notify_verify_e_type (xdrs, &objp->notification_priv_type)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->invoke_id)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->flags)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->notification_length)) + return FALSE; + if (!xdr_opaque (xdrs, objp->notification_text, 64)) + return FALSE; + if (!xdr_rpc_loc_ni_datacoding_scheme_e_type (xdrs, &objp->datacoding_scheme)) + return FALSE; + if (!xdr_rpc_loc_ni_ext_client_address_s_type (xdrs, &objp->ext_client_address_data)) + return FALSE; + if (!xdr_rpc_loc_ni_location_type_e_type (xdrs, &objp->location_type)) + return FALSE; + if (!xdr_rpc_loc_ni_deferred_location_s_type (xdrs, &objp->deferred_location)) + return FALSE; + if (!xdr_rpc_loc_ni_requestor_id_s_type (xdrs, &objp->requestor_id)) + return FALSE; + if (!xdr_rpc_loc_ni_codeword_string_s_type (xdrs, &objp->codeword_string)) + return FALSE; + if (!xdr_rpc_loc_ni_service_type_id_s_type (xdrs, &objp->service_type_id)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->user_response_timer)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_service_interaction_e_type (XDR *xdrs, rpc_loc_ni_service_interaction_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_vx_service_interaction_req_s_type (XDR *xdrs, rpc_loc_ni_vx_service_interaction_req_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ni_vx_notify_verify_req_s_type (xdrs, &objp->ni_vx_req)) + return FALSE; + if (!xdr_rpc_loc_ni_service_interaction_e_type (xdrs, &objp->service_interation_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_event_payload_u_type (XDR *xdrs, rpc_loc_ni_event_payload_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ni_event_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ: + if (!xdr_rpc_loc_ni_vx_notify_verify_req_s_type (xdrs, &objp->rpc_loc_ni_event_payload_u_type_u.vx_req)) + return FALSE; + break; + case RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ: + if (!xdr_rpc_loc_ni_supl_notify_verify_req_s_type (xdrs, &objp->rpc_loc_ni_event_payload_u_type_u.supl_req)) + return FALSE; + break; + case RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ: + if (!xdr_rpc_loc_ni_umts_cp_notify_verify_req_s_type (xdrs, &objp->rpc_loc_ni_event_payload_u_type_u.umts_cp_req)) + return FALSE; + break; + case RPC_LOC_NI_EVENT_VX_SERVICE_INTERACTION_REQ: + if (!xdr_rpc_loc_ni_vx_service_interaction_req_s_type (xdrs, &objp->rpc_loc_ni_event_payload_u_type_u.service_interaction_req)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_event_s_type (XDR *xdrs, rpc_loc_ni_event_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ni_event_e_type (xdrs, &objp->event)) + return FALSE; + if (!xdr_rpc_loc_ni_event_payload_u_type (xdrs, &objp->payload)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_request_e_type (XDR *xdrs, rpc_loc_assist_data_request_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_struct_loc_time_download_source_s_type_servers_ptr (XDR *xdrs, rpc_struct_loc_time_download_source_s_type_servers_ptr *objp) +{ + register int32_t *buf; + + if (!xdr_string (xdrs, objp, 256)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_struct_loc_time_download_source_s_type_servers (XDR *xdrs, rpc_struct_loc_time_download_source_s_type_servers objp) +{ + register int32_t *buf; + + if (!xdr_vector (xdrs, (char *)objp, 3, + sizeof (rpc_struct_loc_time_download_source_s_type_servers_ptr), (xdrproc_t) xdr_rpc_struct_loc_time_download_source_s_type_servers_ptr)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_time_download_source_s_type (XDR *xdrs, rpc_loc_time_download_source_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->delay_threshold)) + return FALSE; + if (!xdr_rpc_struct_loc_time_download_source_s_type_servers (xdrs, objp->servers)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr (XDR *xdrs, rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr *objp) +{ + register int32_t *buf; + + if (!xdr_string (xdrs, objp, 256)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers (XDR *xdrs, rpc_struct_loc_predicted_orbits_data_source_s_type_servers objp) +{ + register int32_t *buf; + + if (!xdr_vector (xdrs, (char *)objp, 3, + sizeof (rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr), (xdrproc_t) xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_predicted_orbits_data_source_s_type (XDR *xdrs, rpc_loc_predicted_orbits_data_source_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->max_file_size)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->max_part_size)) + return FALSE; + if (!xdr_rpc_struct_loc_predicted_orbits_data_source_s_type_servers (xdrs, objp->servers)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_pos_inj_request_s_type (XDR *xdrs, rpc_loc_pos_inj_request_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->flags)) + return FALSE; + if (!xdr_double (xdrs, &objp->latitude)) + return FALSE; + if (!xdr_double (xdrs, &objp->longitude)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->position_uncertainty)) + return FALSE; + if (!xdr_rpc_uint64 (xdrs, &objp->timestamp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_request_payload_u_type (XDR *xdrs, rpc_loc_assist_data_request_payload_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_assist_data_request_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_ASSIST_DATA_TIME_REQ: + if (!xdr_rpc_loc_time_download_source_s_type (xdrs, &objp->rpc_loc_assist_data_request_payload_u_type_u.time_download)) + return FALSE; + break; + case RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ: + if (!xdr_rpc_loc_predicted_orbits_data_source_s_type (xdrs, &objp->rpc_loc_assist_data_request_payload_u_type_u.data_download)) + return FALSE; + break; + case RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ: + if (!xdr_rpc_loc_pos_inj_request_s_type (xdrs, &objp->rpc_loc_assist_data_request_payload_u_type_u.pos_injection)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_request_s_type (XDR *xdrs, rpc_loc_assist_data_request_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_assist_data_request_e_type (xdrs, &objp->event)) + return FALSE; + if (!xdr_rpc_loc_assist_data_request_payload_u_type (xdrs, &objp->payload)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_connection_handle (XDR *xdrs, rpc_loc_server_connection_handle *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_protocol_e_type (XDR *xdrs, rpc_loc_server_protocol_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_connection_e_type (XDR *xdrs, rpc_loc_server_connection_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_request_e_type (XDR *xdrs, rpc_loc_server_request_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_open_req_s_type (XDR *xdrs, rpc_loc_server_open_req_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + if (!xdr_rpc_loc_server_protocol_e_type (xdrs, &objp->protocol)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_multi_open_req_s_type (XDR *xdrs, rpc_loc_server_multi_open_req_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + if (!xdr_rpc_loc_server_protocol_e_type (xdrs, &objp->protocol)) + return FALSE; + if (!xdr_rpc_loc_server_connection_e_type (xdrs, &objp->connection_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_close_req_s_type (XDR *xdrs, rpc_loc_server_close_req_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_request_u_type (XDR *xdrs, rpc_loc_server_request_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_request_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_SERVER_REQUEST_OPEN: + if (!xdr_rpc_loc_server_open_req_s_type (xdrs, &objp->rpc_loc_server_request_u_type_u.open_req)) + return FALSE; + break; + case RPC_LOC_SERVER_REQUEST_CLOSE: + if (!xdr_rpc_loc_server_close_req_s_type (xdrs, &objp->rpc_loc_server_request_u_type_u.close_req)) + return FALSE; + break; + case RPC_LOC_SERVER_REQUEST_MULTI_OPEN: + if (!xdr_rpc_loc_server_multi_open_req_s_type (xdrs, &objp->rpc_loc_server_request_u_type_u.multi_open_req)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_server_request_s_type (XDR *xdrs, rpc_loc_server_request_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_request_e_type (xdrs, &objp->event)) + return FALSE; + if (!xdr_rpc_loc_server_request_u_type (xdrs, &objp->payload)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_qwip_request_e_type (XDR *xdrs, rpc_loc_qwip_request_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_qwip_request_s_type (XDR *xdrs, rpc_loc_qwip_request_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_qwip_request_e_type (xdrs, &objp->request_type)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->tbf_ms)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_reserved_payload_s_type (XDR *xdrs, rpc_loc_reserved_payload_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint16 (xdrs, &objp->data_size)) + return FALSE; + if (!xdr_bytes (xdrs, (char **)&objp->data.data_val, (u_int *) &objp->data.data_len, ~0)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_e_type (XDR *xdrs, rpc_loc_ioctl_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_api_version_s_type (XDR *xdrs, rpc_loc_api_version_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_u_char (xdrs, &objp->major)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->minor)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_fix_recurrence_e_type (XDR *xdrs, rpc_loc_fix_recurrence_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_operation_mode_e_type (XDR *xdrs, rpc_loc_operation_mode_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_notify_e_type (XDR *xdrs, rpc_loc_notify_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_fix_criteria_s_type (XDR *xdrs, rpc_loc_fix_criteria_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->valid_mask)) + return FALSE; + if (!xdr_rpc_loc_fix_recurrence_e_type (xdrs, &objp->recurrence_type)) + return FALSE; + if (!xdr_rpc_loc_operation_mode_e_type (xdrs, &objp->preferred_operation_mode)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->preferred_accuracy)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->preferred_response_time)) + return FALSE; + if (!xdr_rpc_boolean (xdrs, &objp->intermediate_pos_report_enabled)) + return FALSE; + if (!xdr_rpc_loc_notify_e_type (xdrs, &objp->notify_type)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->min_interval)) + return FALSE; + if (!xdr_float (xdrs, &objp->min_distance)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->min_dist_sample_interval)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ni_user_resp_e_type (XDR *xdrs, rpc_loc_ni_user_resp_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_user_verify_s_type (XDR *xdrs, rpc_loc_user_verify_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ni_user_resp_e_type (xdrs, &objp->user_resp)) + return FALSE; + if (!xdr_rpc_loc_ni_event_s_type (xdrs, &objp->ni_event_pass_back)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_predicted_orbits_data_format_e_type (XDR *xdrs, rpc_loc_predicted_orbits_data_format_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_predicted_orbits_data_s_type (XDR *xdrs, rpc_loc_predicted_orbits_data_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_predicted_orbits_data_format_e_type (xdrs, &objp->format_type)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->total_size)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->total_parts)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->part)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->part_len)) + return FALSE; + if (!xdr_bytes (xdrs, (char **)&objp->data_ptr.data_ptr_val, (u_int *) &objp->data_ptr.data_ptr_len, ~0)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_predicted_orbits_data_validity_report_s_type (XDR *xdrs, rpc_loc_predicted_orbits_data_validity_report_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint64 (xdrs, &objp->start_time_utc)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->valid_duration_hrs)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_predicted_orbits_auto_download_config_s_type (XDR *xdrs, rpc_loc_predicted_orbits_auto_download_config_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_boolean (xdrs, &objp->enable)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->auto_check_every_hrs)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_time_s_type (XDR *xdrs, rpc_loc_assist_data_time_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint64 (xdrs, &objp->time_utc)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->uncertainty)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_pos_valid_mask_type (XDR *xdrs, rpc_loc_assist_pos_valid_mask_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint64 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_pos_s_type (XDR *xdrs, rpc_loc_assist_data_pos_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_assist_pos_valid_mask_type (xdrs, &objp->valid_mask)) + return FALSE; + if (!xdr_rpc_uint64 (xdrs, &objp->timestamp_utc)) + return FALSE; + if (!xdr_double (xdrs, &objp->latitude)) + return FALSE; + if (!xdr_double (xdrs, &objp->longitude)) + return FALSE; + if (!xdr_float (xdrs, &objp->altitude_wrt_ellipsoid)) + return FALSE; + if (!xdr_float (xdrs, &objp->altitude_wrt_mean_sea_level)) + return FALSE; + if (!xdr_float (xdrs, &objp->hor_unc_circular)) + return FALSE; + if (!xdr_float (xdrs, &objp->vert_unc)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->confidence_horizontal)) + return FALSE; + if (!xdr_u_char (xdrs, &objp->confidence_vertical)) + return FALSE; + if (!xdr_rpc_int32 (xdrs, &objp->timestamp_age)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_open_status_e_type (XDR *xdrs, rpc_loc_server_open_status_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_pdp_type_e_type (XDR *xdrs, rpc_loc_server_pdp_type_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_open_status_s_type (XDR *xdrs, rpc_loc_server_open_status_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + if (!xdr_rpc_loc_server_open_status_e_type (xdrs, &objp->open_status)) + return FALSE; + if (!xdr_opaque (xdrs, objp->apn_name, 100)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_multi_open_status_s_type (XDR *xdrs, rpc_loc_server_multi_open_status_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + if (!xdr_rpc_loc_server_open_status_e_type (xdrs, &objp->open_status)) + return FALSE; + if (!xdr_rpc_loc_server_pdp_type_e_type (xdrs, &objp->pdp_type)) + return FALSE; + if (!xdr_opaque (xdrs, objp->apn_name, 100)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_close_status_e_type (XDR *xdrs, rpc_loc_server_close_status_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_server_close_status_s_type (XDR *xdrs, rpc_loc_server_close_status_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_server_connection_handle (xdrs, &objp->conn_handle)) + return FALSE; + if (!xdr_rpc_loc_server_close_status_e_type (xdrs, &objp->close_status)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_fix_time_s_type (XDR *xdrs, rpc_loc_wiper_fix_time_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, &objp->slow_clock_count)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_fix_pos_s_type (XDR *xdrs, rpc_loc_wiper_fix_pos_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_int32 (xdrs, &objp->lat)) + return FALSE; + if (!xdr_rpc_int32 (xdrs, &objp->lon)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->HEPE)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->num_of_aps_used)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->fix_error_code)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_ap_info_s_type (XDR *xdrs, rpc_loc_wiper_ap_info_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_opaque (xdrs, objp->mac_addr, 6)) + return FALSE; + if (!xdr_rpc_int32 (xdrs, &objp->rssi)) + return FALSE; + if (!xdr_rpc_uint16 (xdrs, &objp->channel)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->ap_qualifier)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_ap_set_s_type (XDR *xdrs, rpc_loc_wiper_ap_set_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_uint8 (xdrs, &objp->num_of_aps)) + return FALSE; + if (!xdr_vector (xdrs, (char *)objp->ap_info, 50, + sizeof (rpc_loc_wiper_ap_info_s_type), (xdrproc_t) xdr_rpc_loc_wiper_ap_info_s_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_position_report_s_type (XDR *xdrs, rpc_loc_wiper_position_report_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint8 (xdrs, &objp->wiper_valid_info_flag)) + return FALSE; + if (!xdr_rpc_loc_wiper_fix_time_s_type (xdrs, &objp->wiper_fix_time)) + return FALSE; + if (!xdr_rpc_loc_wiper_fix_pos_s_type (xdrs, &objp->wiper_fix_position)) + return FALSE; + if (!xdr_rpc_loc_wiper_ap_set_s_type (xdrs, &objp->wiper_ap_set)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_wiper_status_e_type (XDR *xdrs, rpc_loc_wiper_status_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_fs_operation_e_type (XDR *xdrs, rpc_loc_fs_operation_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_efs_data_s_type (XDR *xdrs, rpc_loc_efs_data_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_opaque (xdrs, objp->filename, 64)) + return FALSE; + if (!xdr_rpc_loc_fs_operation_e_type (xdrs, &objp->operation)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->total_size)) + return FALSE; + if (!xdr_bytes (xdrs, (char **)&objp->data_ptr.data_ptr_val, (u_int *) &objp->data_ptr.data_ptr_len, ~0)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->part_len)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->part)) + return FALSE; + if (!xdr_rpc_uint8 (xdrs, &objp->total_parts)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->reserved)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_error_estimate_config_e_type (XDR *xdrs, rpc_loc_error_estimate_config_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_apn_profiles_type (XDR *xdrs, rpc_loc_apn_profiles_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_uint32 (xdrs, &objp->srv_system_type)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->pdp_type)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->reserved)) + return FALSE; + if (!xdr_opaque (xdrs, objp->apn_name, 100)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_lock_e_type (XDR *xdrs, rpc_loc_lock_e_type *objp) +{ + register int32_t *buf; + + if (!xdr_enum (xdrs, (enum_t *) objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_nmea_sentence_type (XDR *xdrs, rpc_loc_nmea_sentence_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_type (XDR *xdrs, rpc_loc_assist_data_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_assist_data_delete_s_type (XDR *xdrs, rpc_loc_assist_data_delete_s_type *objp) +{ + register int32_t *buf; + + int i; + if (!xdr_rpc_loc_assist_data_type (xdrs, &objp->type)) + return FALSE; + if (!xdr_vector (xdrs, (char *)objp->reserved, 8, + sizeof (rpc_uint32), (xdrproc_t) xdr_rpc_uint32)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_data_u_type (XDR *xdrs, rpc_loc_ioctl_data_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ioctl_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_IOCTL_SET_FIX_CRITERIA: + if (!xdr_rpc_loc_fix_criteria_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.fix_criteria)) + return FALSE; + break; + case RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE: + if (!xdr_rpc_loc_user_verify_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.user_verify_resp)) + return FALSE; + break; + case RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA: + if (!xdr_rpc_loc_predicted_orbits_data_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.predicted_orbits_data)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD: + if (!xdr_rpc_loc_predicted_orbits_auto_download_config_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.predicted_orbits_auto_download)) + return FALSE; + break; + case RPC_LOC_IOCTL_INJECT_UTC_TIME: + if (!xdr_rpc_loc_assist_data_time_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.assistance_data_time)) + return FALSE; + break; + case RPC_LOC_IOCTL_INJECT_POSITION: + if (!xdr_rpc_loc_assist_data_pos_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.assistance_data_position)) + return FALSE; + break; + case RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS: + if (!xdr_rpc_loc_server_open_status_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.conn_open_status)) + return FALSE; + break; + case RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS: + if (!xdr_rpc_loc_server_close_status_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.conn_close_status)) + return FALSE; + break; + case RPC_LOC_IOCTL_SEND_WIPER_POSITION_REPORT: + if (!xdr_rpc_loc_wiper_position_report_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.wiper_pos)) + return FALSE; + break; + case RPC_LOC_IOCTL_NOTIFY_WIPER_STATUS: + if (!xdr_rpc_loc_wiper_status_e_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.wiper_status)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_ENGINE_LOCK: + if (!xdr_rpc_loc_lock_e_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.engine_lock)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_SBAS_CONFIG: + if (!xdr_rpc_boolean (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.sbas_mode)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_NMEA_TYPES: + if (!xdr_rpc_loc_nmea_sentence_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.nmea_types)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_ON_DEMAND_LPM: + if (!xdr_rpc_boolean (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.on_demand_lpm)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR: + if (!xdr_rpc_loc_server_info_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.server_addr)) + return FALSE; + break; + case RPC_LOC_IOCTL_DELETE_ASSIST_DATA: + if (!xdr_rpc_loc_assist_data_delete_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.assist_data_delete)) + return FALSE; + break; + case RPC_LOC_IOCTL_ACCESS_EFS_DATA: + if (!xdr_rpc_loc_efs_data_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.efs_data)) + return FALSE; + break; + case RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG: + if (!xdr_rpc_loc_error_estimate_config_e_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.error_estimate_config)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL: + if (!xdr_rpc_uint8 (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.xtra_t_session_control)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_LBS_APN_PROFILE: + case RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE: + if (!xdr_vector (xdrs, (char *)objp->rpc_loc_ioctl_data_u_type_u.apn_profiles, 6, + sizeof (rpc_loc_apn_profiles_type), (xdrproc_t) xdr_rpc_loc_apn_profiles_type)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_DATA_ENABLE: + if (!xdr_rpc_boolean (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.data_enable)) + return FALSE; + break; + case RPC_LOC_IOCTL_SET_SUPL_VERSION: + if (!xdr_rpc_uint32 (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.supl_version)) + return FALSE; + break; + case RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS: + if (!xdr_rpc_loc_server_multi_open_status_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.multi_conn_open_status)) + return FALSE; + break; + case RPC_LOC_IOCTL_RESERVED_CMD: + if (!xdr_rpc_loc_reserved_payload_s_type (xdrs, &objp->rpc_loc_ioctl_data_u_type_u.reserved)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_callback_data_u_type (XDR *xdrs, rpc_loc_ioctl_callback_data_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ioctl_e_type (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_IOCTL_GET_API_VERSION: + if (!xdr_rpc_loc_api_version_s_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.api_version)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_FIX_CRITERIA: + if (!xdr_rpc_loc_fix_criteria_s_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.fix_criteria)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_ENGINE_LOCK: + if (!xdr_rpc_loc_lock_e_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.engine_lock)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_SBAS_CONFIG: + if (!xdr_rpc_boolean (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.sbas_mode)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_NMEA_TYPES: + if (!xdr_rpc_loc_nmea_sentence_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.nmea_types)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_ON_DEMAND_LPM: + if (!xdr_rpc_boolean (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.on_demand_lpm)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR: + if (!xdr_rpc_loc_server_info_s_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.server_addr)) + return FALSE; + break; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE: + if (!xdr_rpc_loc_predicted_orbits_data_source_s_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.predicted_orbits_data_source)) + return FALSE; + break; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY: + if (!xdr_rpc_loc_predicted_orbits_data_validity_report_s_type (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.predicted_orbits_data_validity)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL: + if (!xdr_rpc_uint8 (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.xtra_t_session_control)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_LBS_APN_PROFILE: + case RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE: + if (!xdr_vector (xdrs, (char *)objp->rpc_loc_ioctl_callback_data_u_type_u.apn_profiles, 6, + sizeof (rpc_loc_apn_profiles_type), (xdrproc_t) xdr_rpc_loc_apn_profiles_type)) + return FALSE; + break; + case RPC_LOC_IOCTL_GET_SUPL_VERSION: + if (!xdr_rpc_uint32 (xdrs, &objp->rpc_loc_ioctl_callback_data_u_type_u.supl_version)) + return FALSE; + break; + default: + break; + } + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_callback_s_type (XDR *xdrs, rpc_loc_ioctl_callback_s_type *objp) +{ + register int32_t *buf; + + if (!xdr_rpc_loc_ioctl_e_type (xdrs, &objp->type)) + return FALSE; + if (!xdr_rpc_int32 (xdrs, &objp->status)) + return FALSE; + if (!xdr_rpc_loc_ioctl_callback_data_u_type (xdrs, &objp->data)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_event_payload_u_type (XDR *xdrs, rpc_loc_event_payload_u_type *objp) +{ + register int32_t *buf; + + if (!xdr_u_quad_t (xdrs, &objp->disc)) + return FALSE; + switch (objp->disc) { + case RPC_LOC_EVENT_PARSED_POSITION_REPORT: + if (!xdr_rpc_loc_parsed_position_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.parsed_location_report)) + return FALSE; + break; + case RPC_LOC_EVENT_SATELLITE_REPORT: + if (!xdr_rpc_loc_gnss_info_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.gnss_report)) + return FALSE; + break; + case RPC_LOC_EVENT_NMEA_POSITION_REPORT: + case RPC_LOC_EVENT_NMEA_1HZ_REPORT: + if (!xdr_rpc_loc_nmea_report_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.nmea_report)) + return FALSE; + break; + case RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST: + if (!xdr_rpc_loc_ni_event_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.ni_request)) + return FALSE; + break; + case RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST: + if (!xdr_rpc_loc_assist_data_request_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.assist_data_request)) + return FALSE; + break; + case RPC_LOC_EVENT_LOCATION_SERVER_REQUEST: + if (!xdr_rpc_loc_server_request_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.loc_server_request)) + return FALSE; + break; + case RPC_LOC_EVENT_IOCTL_REPORT: + if (!xdr_rpc_loc_ioctl_callback_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.ioctl_report)) + return FALSE; + break; + case RPC_LOC_EVENT_STATUS_REPORT: + if (!xdr_rpc_loc_status_event_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.status_report)) + return FALSE; + break; + case RPC_LOC_EVENT_WPS_NEEDED_REQUEST: + if (!xdr_rpc_loc_qwip_request_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.qwip_request)) + return FALSE; + break; + case RPC_LOC_EVENT_RESERVED: + if (!xdr_rpc_loc_reserved_payload_s_type (xdrs, &objp->rpc_loc_event_payload_u_type_u.reserved)) + return FALSE; + break; + default: + break; + } + return TRUE; +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c new file mode 100755 index 00000000..e8a2aa78 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c @@ -0,0 +1,199 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* + * Please do not edit this file. + * It was generated using rpcgen. + */ + +#include "loc_api_rpcgen_rpc.h" + +bool_t +xdr_rpc_loc_api_api_versions_return_type (XDR *xdrs, rpc_loc_api_api_versions_return_type *objp) +{ +; + + if (!xdr_array (xdrs, (char **)&objp->rpc_loc_api_api_versions_return_type_val, (u_int *) &objp->rpc_loc_api_api_versions_return_type_len, ~0, + sizeof (rpc_uint32), (xdrproc_t) xdr_rpc_uint32)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_event_cb_f_type (XDR *xdrs, rpc_loc_event_cb_f_type *objp) +{ +; + + if (!xdr_rpc_uint32 (xdrs, objp)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_open_args (XDR *xdrs, rpc_loc_open_args *objp) +{ +; + + if (!xdr_rpc_loc_event_mask_type (xdrs, &objp->event_reg_mask)) + return FALSE; + if (!xdr_rpc_loc_event_cb_f_type (xdrs, &objp->event_callback)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_close_args (XDR *xdrs, rpc_loc_close_args *objp) +{ +; + + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->handle)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_start_fix_args (XDR *xdrs, rpc_loc_start_fix_args *objp) +{ +; + + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->handle)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_stop_fix_args (XDR *xdrs, rpc_loc_stop_fix_args *objp) +{ +; + + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->handle)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_args (XDR *xdrs, rpc_loc_ioctl_args *objp) +{ +; + + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->handle)) + return FALSE; + if (!xdr_rpc_loc_ioctl_e_type (xdrs, &objp->ioctl_type)) + return FALSE; + if (!xdr_pointer (xdrs, (char **)&objp->ioctl_data, sizeof (rpc_loc_ioctl_data_u_type), (xdrproc_t) xdr_rpc_loc_ioctl_data_u_type)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_api_api_version_s_args (XDR *xdrs, rpc_loc_api_api_version_s_args *objp) +{ +; + + if (!xdr_rpc_boolean (xdrs, &objp->len_not_null)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_api_rpc_glue_code_info_remote_rets (XDR *xdrs, rpc_loc_api_rpc_glue_code_info_remote_rets *objp) +{ +; + + if (!xdr_rpc_uint32 (xdrs, &objp->toolvers)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->features)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->proghash)) + return FALSE; + if (!xdr_rpc_uint32 (xdrs, &objp->cbproghash)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_open_rets (XDR *xdrs, rpc_loc_open_rets *objp) +{ +; + + if (!xdr_rpc_loc_client_handle_type (xdrs, &objp->loc_open_result)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_close_rets (XDR *xdrs, rpc_loc_close_rets *objp) +{ +; + + if (!xdr_rpc_int32 (xdrs, &objp->loc_close_result)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_start_fix_rets (XDR *xdrs, rpc_loc_start_fix_rets *objp) +{ +; + + if (!xdr_rpc_int32 (xdrs, &objp->loc_start_fix_result)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_stop_fix_rets (XDR *xdrs, rpc_loc_stop_fix_rets *objp) +{ +; + + if (!xdr_rpc_int32 (xdrs, &objp->loc_stop_fix_result)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_ioctl_rets (XDR *xdrs, rpc_loc_ioctl_rets *objp) +{ +; + + if (!xdr_rpc_int32 (xdrs, &objp->loc_ioctl_result)) + return FALSE; + return TRUE; +} + +bool_t +xdr_rpc_loc_api_api_versions_rets (XDR *xdrs, rpc_loc_api_api_versions_rets *objp) +{ +; + + if (!xdr_rpc_loc_api_api_versions_return_type (xdrs, &objp->loc_api_api_versions_result)) + return FALSE; + if (!xdr_pointer (xdrs, (char **)&objp->len, sizeof (rpc_uint32), (xdrproc_t) xdr_rpc_uint32)) + return FALSE; + return TRUE; +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c new file mode 100755 index 00000000..b4aeb5e7 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c @@ -0,0 +1,74 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include "librpc.h" +#include "loc_api_rpcgen_rpc.h" +#include "loc_api_rpcgen_cb_rpc.h" + + +#define RPC_FUNC_VERSION_BASE(a,b) a ## b +#define RPC_CB_FUNC_VERS(a,b) RPC_FUNC_VERSION_BASE(a,b) + + +static SVCXPRT* svrPort = NULL; + +extern void RPC_CB_FUNC_VERS(loc_apicbprog_,LOC_APICBVERS_0001)(struct svc_req *rqstp, register SVCXPRT *transp); + +int loc_apicb_app_init(void) +{ + + /* Register a callback server to use the loc_apicbprog_0x00010001 */ + if (svrPort == NULL) { + svrPort = svcrtr_create(); + } + if (!svrPort) return -1; + + xprt_register(svrPort); + + + + if(svc_register(svrPort, LOC_APICBPROG,LOC_APICBVERS_0001, RPC_CB_FUNC_VERS(loc_apicbprog_,LOC_APICBVERS_0001),0)) + { + return 0; + } + else + { + return -1; + } +} +void loc_apicb_app_deinit(void) +{ + + if (svrPort == NULL) + { + return; + } + + + svc_unregister(svrPort, LOC_APICBPROG,LOC_APICBVERS_0001); +} diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr new file mode 100755 index 00000000..3d6c759e --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr @@ -0,0 +1,261 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* LOC_API TOOL VERSION: 4.48 */ +/* GENERATED: TUE JUN 14 2011 */ +/*============================================================================= + L O C _ A P I . X D R + +GENERAL DESCRIPTION + This is an AUTO GENERATED file that provides an xdr compatible definition of + the loc_api API. + + --------------------------------------------------------------------------- + + + --------------------------------------------------------------------------- +=============================================================================*/ + +/*============================================================================= + + Edit History + + AUTO GENERATED + +Generated by following versions of Htorpc modules: +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/htorpc.pl#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Start.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Htoxdr.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/XDR.pm#3 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Output.pm#5 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Parser.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Metacomments.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/SymbolTable.pm#1 + +loc_api Definition File(s): +Id: //source/qcom/qct/modem/api/gps/main/latest/loc_api.h#24 +=============================================================================*/ +/*============================================================================= +$Header$ +=============================================================================*/ + + + +typedef rpc_uint32 rpc_loc_api_api_versions_return_type<>; + +/* + * Declare an rpc_uint32 type for each callback type in the API + */ +typedef rpc_uint32 rpc_loc_event_cb_f_type; + + + +/* + * These are struct declarations for the function arguments + */ + +struct rpc_loc_open_args { + rpc_loc_event_mask_type event_reg_mask; + rpc_loc_event_cb_f_type event_callback; +}; + +struct rpc_loc_close_args { + rpc_loc_client_handle_type handle; +}; + +struct rpc_loc_start_fix_args { + rpc_loc_client_handle_type handle; +}; + +struct rpc_loc_stop_fix_args { + rpc_loc_client_handle_type handle; +}; + +struct rpc_loc_ioctl_args { + rpc_loc_client_handle_type handle; + rpc_loc_ioctl_e_type ioctl_type; + rpc_loc_ioctl_data_u_type *ioctl_data; +}; + + + +struct rpc_loc_api_api_version_s_args { + rpc_boolean len_not_null; +}; + +/* + * These are struct declarations for the function results + */ + +struct rpc_loc_api_rpc_glue_code_info_remote_rets { + rpc_uint32 toolvers; /* Tool version */ + rpc_uint32 features; /* Features turned on in the code. + * 0x00000001 ONCRPC Server Cleanup Support + */ + rpc_uint32 proghash; /* Unique hash value for the API XDR definition */ + rpc_uint32 cbproghash; /* Unique hash value for the Callbacks' XDR definition */ +}; + +struct rpc_loc_open_rets { + rpc_loc_client_handle_type loc_open_result; +}; + +struct rpc_loc_close_rets { + rpc_int32 loc_close_result; +}; + +struct rpc_loc_start_fix_rets { + rpc_int32 loc_start_fix_result; +}; + +struct rpc_loc_stop_fix_rets { + rpc_int32 loc_stop_fix_result; +}; + +struct rpc_loc_ioctl_rets { + rpc_int32 loc_ioctl_result; +}; + + struct rpc_loc_api_api_versions_rets { + rpc_loc_api_api_versions_return_type loc_api_api_versions_result; + rpc_uint32 *len; +}; + +/* + * XDR definition of the LOC_API program ( vers. 0x00050006 ) + */ + +program LOC_APIPROG { + version LOC_APIVERS_0001 { + + void + rpc_loc_api_null( void ) = 0; + + rpc_loc_api_rpc_glue_code_info_remote_rets + rpc_loc_api_rpc_glue_code_info_remote( void ) = 1; + + rpc_loc_open_rets + rpc_loc_open( rpc_loc_open_args ) = 2; + + rpc_loc_close_rets + rpc_loc_close( rpc_loc_close_args ) = 3; + + rpc_loc_start_fix_rets + rpc_loc_start_fix( rpc_loc_start_fix_args ) = 4; + + rpc_loc_stop_fix_rets + rpc_loc_stop_fix( rpc_loc_stop_fix_args ) = 5; + + rpc_loc_ioctl_rets + rpc_loc_ioctl( rpc_loc_ioctl_args ) = 6; + + rpc_loc_api_api_versions_rets + rpc_loc_api_api_versions( void ) = 0xFFFFFFFF; + + + + + } = 0x00050001; + +version LOC_APIVERS_0002 { + +/* Following elements added in enum rpc_loc_assist_data_request_e_type in 0x00050002 +RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ +*/ +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050002 +RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL +RPC_LOC_IOCTL_RESERVED_CMD +RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL +*/ + + void + rpc_loc_api_null( void ) = 0; + + } = 0x00050002; + +version LOC_APIVERS_0003 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050003 +RPC_LOC_IOCTL_SET_DATA_ENABLE +RPC_LOC_IOCTL_SET_LBS_APN_PROFILE +RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE +RPC_LOC_IOCTL_GET_LBS_APN_PROFILE +RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE +*/ + + void + rpc_loc_api_null( void ) = 0; + + } = 0x00050003; + +version LOC_APIVERS_0004 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050004 +RPC_LOC_IOCTL_GET_SUPL_VERSION +RPC_LOC_IOCTL_SET_SUPL_VERSION +*/ + + void + rpc_loc_api_null( void ) = 0; + + } = 0x00050004; + +version LOC_APIVERS_0005 { + +/* Following elements added in enum rpc_loc_server_addr_e_type in 0x00050005 +RPC_LOC_SERVER_ADDR_IPV6 +*/ +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050005 +RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG +*/ + + void + rpc_loc_api_null( void ) = 0; + + } = 0x00050005; + + + + version LOC_APIVERS_0006 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050006 +RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS +*/ +/* Following elements added in enum rpc_loc_server_request_e_type in 0x00050006 +RPC_LOC_SERVER_REQUEST_MULTI_OPEN +*/ + + void + rpc_loc_api_null( void ) = 0; + + } = 0x00050006; + + +} = 0x3000008C; + +const LOC_APIVERS = 0x00050006; diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr new file mode 100755 index 00000000..36d0e6d2 --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr @@ -0,0 +1,187 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* LOC_API TOOL VERSION: 4.48 */ +/* GENERATED: TUE JUN 14 2011 */ +/*============================================================================= + L O C _ A P I _ C B . X D R + +GENERAL DESCRIPTION + This is an AUTO GENERATED file that provides an xdr compatible definition of + an api that represents the grouping of the different callback functions the + loc_api API supports. + + --------------------------------------------------------------------------- + + + --------------------------------------------------------------------------- +=============================================================================*/ + +/*============================================================================= + + Edit History + + AUTO GENERATED + +Generated by following versions of Htorpc modules: +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/htorpc.pl#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Start.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Htoxdr.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/XDR.pm#3 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Output.pm#5 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Parser.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Metacomments.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/SymbolTable.pm#1 + +loc_api Definition File(s): +Id: //source/qcom/qct/modem/api/gps/main/latest/loc_api.h#24 +=============================================================================*/ +/*============================================================================= +$Header$ +=============================================================================*/ + + + + +/* + * These are struct declarations for the function arguments + */ + +struct rpc_loc_event_cb_f_type_args { + rpc_uint32 cb_id; + rpc_loc_client_handle_type loc_handle; + rpc_loc_event_mask_type loc_event; + rpc_loc_event_payload_u_type *loc_event_payload; +}; + + + + + +/* + * These are struct declaratios for the function results + */ + +struct rpc_loc_event_cb_f_type_rets { + rpc_int32 loc_event_cb_f_type_result; +}; + + + +/* + * XDR definition of the LOC_API callback program ( vers. 0x00050006 ) + */ + +program LOC_APICBPROG { + version LOC_APICBVERS_0001 { + + rpc_loc_event_cb_f_type_rets + rpc_loc_event_cb_f_type( rpc_loc_event_cb_f_type_args ) = 1; + + + + + } = 0x00050001; + +version LOC_APICBVERS_0002 { + +/* Following elements added in enum rpc_loc_assist_data_request_e_type in 0x00050002 +RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ +*/ +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050002 +RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL +RPC_LOC_IOCTL_RESERVED_CMD +RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL +*/ + + int + rpc_loc_api_cb_null( void ) = 0xffffff00; + + } = 0x00050002; + +version LOC_APICBVERS_0003 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050003 +RPC_LOC_IOCTL_SET_DATA_ENABLE +RPC_LOC_IOCTL_SET_LBS_APN_PROFILE +RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE +RPC_LOC_IOCTL_GET_LBS_APN_PROFILE +RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE +*/ + + int + rpc_loc_api_cb_null( void ) = 0xffffff00; + + } = 0x00050003; + +version LOC_APICBVERS_0004 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050004 +RPC_LOC_IOCTL_GET_SUPL_VERSION +RPC_LOC_IOCTL_SET_SUPL_VERSION +*/ + + int + rpc_loc_api_cb_null( void ) = 0xffffff00; + + } = 0x00050004; + +version LOC_APICBVERS_0005 { + +/* Following elements added in enum rpc_loc_server_addr_e_type in 0x00050005 +RPC_LOC_SERVER_ADDR_IPV6 +*/ +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050005 +RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG +*/ + + int + rpc_loc_api_cb_null( void ) = 0xffffff00; + + } = 0x00050005; + + + + version LOC_APICBVERS_0006 { + +/* Following elements added in enum rpc_loc_ioctl_e_type in 0x00050006 +RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS +*/ +/* Following elements added in enum rpc_loc_server_request_e_type in 0x00050006 +RPC_LOC_SERVER_REQUEST_MULTI_OPEN +*/ + + int + rpc_loc_api_cb_null( void ) = 0xffffff00; + + } = 0x00050006; + + +} = 0x3100008C; + +const LOC_APICBVERS = 0x00050006; diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr new file mode 100755 index 00000000..fcdaf57f --- /dev/null +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr @@ -0,0 +1,1021 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +/* LOC_API TOOL VERSION: 4.48 */ +/* GENERATED: TUE JUN 14 2011 */ +/*============================================================================= + L O C _ A P I _ C O M M O N . X D R + +GENERAL DESCRIPTION + This is an AUTO GENERATED file that provides an xdr compatible definition of + an api that represents the grouping of the different callback functions the + loc_api API supports. + + --------------------------------------------------------------------------- + + + --------------------------------------------------------------------------- +=============================================================================*/ + +/*============================================================================= + + Edit History + + AUTO GENERATED + +Generated by following versions of Htorpc modules: +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/htorpc.pl#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Start.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Htoxdr.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/XDR.pm#3 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Output.pm#5 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Parser.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/Metacomments.pm#1 +Id: //source/qcom/qct/core/mproc/tools/rel/2h09/htorpc/lib/Htorpc/SymbolTable.pm#1 + +loc_api Definition File(s): +Id: //source/qcom/qct/modem/api/gps/main/latest/loc_api.h#24 +=============================================================================*/ +/*============================================================================= +$Header$ +=============================================================================*/ + + + +const LOC_API_TOOLVERS = 0x00040030; +const LOC_API_FEATURES = 0x00000001; + +const RPC_LOC_EVENT_STATUS_REPORT = 0x00000100; + +const RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST = 0x00000020; + +const RPC_LOC_EVENT_WPS_NEEDED_REQUEST = 0x00000200; + +const RPC_LOC_EVENT_SATELLITE_REPORT = 0x00000002; + +const RPC_LOC_EVENT_PARSED_POSITION_REPORT = 0x00000001; + +const RPC_LOC_EVENT_RESERVED = 0x8000000000000000; + +const RPC_LOC_EVENT_LOCATION_SERVER_REQUEST = 0x00000040; + +const RPC_LOC_EVENT_NMEA_POSITION_REPORT = 0x00000008; + +const RPC_LOC_EVENT_IOCTL_REPORT = 0x00000080; + +const RPC_LOC_EVENT_NMEA_1HZ_REPORT = 0x00000004; + +const RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST = 0x00000010; + +const RPC_LOC_API_CB_NULL_VERSION = 0x00050002; +const RPC_LOC_EVENT_CB_F_TYPE_VERSION = 0x00050001; +const RPC_LOC_API_API_VERSIONS_VERSION = 0x00050001; +const RPC_LOC_STOP_FIX_VERSION = 0x00050001; +const RPC_LOC_START_FIX_VERSION = 0x00050001; +const RPC_LOC_IOCTL_VERSION = 0x00050001; +const RPC_LOC_CLOSE_VERSION = 0x00050001; +const RPC_LOC_API_RPC_GLUE_CODE_INFO_REMOTE_VERSION = 0x00050001; +const RPC_LOC_OPEN_VERSION = 0x00050001; +const RPC_LOC_API_NULL_VERSION = 0x00050001; +const RPC_LOC_API_API_MAJOR_NUM = 0x0005; +const RPC_LOC_APIAPI_VERSION_IS_HASHKEY = 0; + +typedef rpc_int32 rpc_loc_client_handle_type; + +typedef rpc_uint64 rpc_loc_event_mask_type; + +typedef rpc_uint64 rpc_loc_position_valid_mask_type; + +typedef rpc_uint32 rpc_loc_pos_technology_mask_type; + +enum rpc_loc_session_status_e_type { + RPC_LOC_SESS_STATUS_SUCCESS = 0, + RPC_LOC_SESS_STATUS_IN_PROGESS = 1, + RPC_LOC_SESS_STATUS_GENERAL_FAILURE = 2, + RPC_LOC_SESS_STATUS_TIMEOUT = 3, + RPC_LOC_SESS_STATUS_USER_END = 4, + RPC_LOC_SESS_STATUS_BAD_PARAMETER = 5, + RPC_LOC_SESS_STATUS_PHONE_OFFLINE = 6, + RPC_LOC_SESS_STATUS_ENGINE_LOCKED = 7, + RPC_LOC_SESS_STATUS_MAX = 268435456 +}; + +struct rpc_loc_calendar_time_s_type { + rpc_uint16 year; + unsigned char month; + unsigned char day_of_week; + unsigned char day; + unsigned char hour; + unsigned char minute; + unsigned char second; + rpc_uint16 millisecond; +}; + +struct rpc_loc_parsed_position_s_type { + rpc_loc_position_valid_mask_type valid_mask; + rpc_loc_session_status_e_type session_status; + rpc_loc_calendar_time_s_type timestamp_calendar; + rpc_uint64 timestamp_utc; + rpc_uint8 leap_seconds; + float time_unc; + double latitude; + double longitude; + float altitude_wrt_ellipsoid; + float altitude_wrt_mean_sea_level; + float speed_horizontal; + float speed_vertical; + float heading; + float hor_unc_circular; + float hor_unc_ellipse_semi_major; + float hor_unc_ellipse_semi_minor; + float hor_unc_ellipse_orient_azimuth; + float vert_unc; + float speed_unc; + float heading_unc; + unsigned char confidence_horizontal; + unsigned char confidence_vertical; + float magnetic_deviation; + rpc_loc_pos_technology_mask_type technology_mask; +}; + +enum rpc_loc_sv_system_e_type { + RPC_LOC_SV_SYSTEM_GPS = 1, + RPC_LOC_SV_SYSTEM_GALILEO = 2, + RPC_LOC_SV_SYSTEM_SBAS = 3, + RPC_LOC_SV_SYSTEM_COMPASS = 4, + RPC_LOC_SV_SYSTEM_GLONASS = 5, + RPC_LOC_SV_SYSTEM_MAX = 268435456 +}; + +enum rpc_loc_sv_status_e_type { + RPC_LOC_SV_STATUS_IDLE = 1, + RPC_LOC_SV_STATUS_SEARCH = 2, + RPC_LOC_SV_STATUS_TRACK = 3, + RPC_LOC_SV_STATUS_MAX = 268435456 +}; + +typedef rpc_uint32 rpc_loc_sv_info_valid_mask_type; + +struct rpc_loc_sv_info_s_type { + rpc_loc_sv_info_valid_mask_type valid_mask; + rpc_loc_sv_system_e_type system; + rpc_uint8 prn; + rpc_uint8 health_status; + rpc_loc_sv_status_e_type process_status; + rpc_boolean has_eph; + rpc_boolean has_alm; + float elevation; + float azimuth; + float snr; +}; + +typedef rpc_uint32 rpc_loc_gnss_info_valid_mask_type; + +struct rpc_loc_gnss_info_s_type { + rpc_loc_gnss_info_valid_mask_type valid_mask; + float position_dop; + float horizontal_dop; + float vertical_dop; + rpc_boolean altitude_assumed; + rpc_uint16 sv_count; + rpc_loc_sv_info_s_type sv_list<80>; /* EVAL:[LOC_API_MAX_SV_COUNT]*/ +}; + +struct rpc_loc_nmea_report_s_type { + rpc_uint16 length; + opaque nmea_sentences[200]; +}; + +enum rpc_loc_status_event_e_type { + RPC_LOC_STATUS_EVENT_ENGINE_STATE = 1, + RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE = 2, + RPC_LOC_STATUS_EVENT_MAX = 268435456 +}; + +enum rpc_loc_engine_state_e_type { + RPC_LOC_ENGINE_STATE_ON = 1, + RPC_LOC_ENGINE_STATE_OFF = 2, + RPC_LOC_ENGINE_STATE_MAX = 268435456 +}; + +enum rpc_loc_fix_session_state_e_type { + RPC_LOC_FIX_SESSION_STATE_BEGIN = 1, + RPC_LOC_FIX_SESSION_STATE_END = 2, + RPC_LOC_FIX_SESSION_STATE_MAX = 268435456 +}; + +union rpc_loc_status_event_payload_u_type switch (rpc_loc_status_event_e_type disc) { + case RPC_LOC_STATUS_EVENT_ENGINE_STATE: + rpc_loc_engine_state_e_type engine_state; + case RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE: + rpc_loc_fix_session_state_e_type fix_session_state; + default: + void; +}; + +struct rpc_loc_status_event_s_type { + rpc_loc_status_event_e_type event; + rpc_loc_status_event_payload_u_type payload; +}; + +enum rpc_loc_server_addr_e_type { + RPC_LOC_SERVER_ADDR_IPV4 = 1, + RPC_LOC_SERVER_ADDR_URL = 2, + RPC_LOC_SERVER_ADDR_IPV6 = 3, + RPC_LOC_SERVER_ADDR_MAX = 268435456 +}; + +struct rpc_loc_server_addr_ipv4_type { + rpc_uint32 addr; + rpc_uint16 port; +}; + +struct rpc_loc_server_addr_url_type { + rpc_uint16 length; + opaque addr[256]; +}; + +struct rpc_loc_server_addr_ipv6_type { + rpc_uint16 addr[8]; + rpc_uint32 port; +}; + +union rpc_loc_server_addr_u_type switch (rpc_loc_server_addr_e_type disc) { + case RPC_LOC_SERVER_ADDR_IPV4: + rpc_loc_server_addr_ipv4_type ipv4; + case RPC_LOC_SERVER_ADDR_URL: + rpc_loc_server_addr_url_type url; + case RPC_LOC_SERVER_ADDR_IPV6: + rpc_loc_server_addr_ipv6_type ipv6; + default: + void; +}; + +struct rpc_loc_server_info_s_type { + rpc_loc_server_addr_e_type addr_type; + rpc_loc_server_addr_u_type addr_info; +}; + +enum rpc_loc_ni_notify_verify_e_type { + RPC_LOC_NI_USER_NO_NOTIFY_NO_VERIFY = 1, + RPC_LOC_NI_USER_NOTIFY_ONLY = 2, + RPC_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP = 3, + RPC_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP = 4, + RPC_LOC_NI_USER_PRIVACY_OVERRIDE = 5, + RPC_LOC_NI_USER_NOTIFY_VERITY_TYPE_MAX = 268435456 +}; + +enum rpc_loc_ni_event_e_type { + RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ = 1, + RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ = 2, + RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ = 3, + RPC_LOC_NI_EVENT_VX_SERVICE_INTERACTION_REQ = 4, + RPC_LOC_NI_EVENT_MAX = 268435456 +}; + +enum rpc_loc_ni_datacoding_scheme_e_type { + RPC_LOC_NI_PRESUPL_ISO646IRV = 0, + RPC_LOC_NI_PRESUPL_ISO8859 = 1, + RPC_LOC_NI_PRESUPL_UTF8 = 2, + RPC_LOC_NI_PRESUPL_UTF16 = 3, + RPC_LOC_NI_PRESUPL_UCS2 = 4, + RPC_LOC_NI_PRESUPL_GSM_DEFAULT = 5, + RPC_LOC_NI_PRESUPL_SHIFT_JIS = 6, + RPC_LOC_NI_PRESUPL_JIS = 7, + RPC_LOC_NI_PRESUPL_EUC = 8, + RPC_LOC_NI_PRESUPL_GB2312 = 9, + RPC_LOC_NI_PRESUPL_CNS11643 = 10, + RPC_LOC_NI_PRESUPL_KSC1001 = 11, + RPC_LOC_NI_PRESUPL_ENCODING_UNKNOWN = 2147483647, + RPC_LOC_NI_SS_GERMAN = 12, + RPC_LOC_NI_SS_ENGLISH = 13, + RPC_LOC_NI_SS_ITALIAN = 14, + RPC_LOC_NI_SS_FRENCH = 15, + RPC_LOC_NI_SS_SPANISH = 16, + RPC_LOC_NI_SS_DUTCH = 17, + RPC_LOC_NI_SS_SWEDISH = 18, + RPC_LOC_NI_SS_DANISH = 19, + RPC_LOC_NI_SS_PORTUGUESE = 20, + RPC_LOC_NI_SS_FINNISH = 21, + RPC_LOC_NI_SS_NORWEGIAN = 22, + RPC_LOC_NI_SS_GREEK = 23, + RPC_LOC_NI_SS_TURKISH = 24, + RPC_LOC_NI_SS_HUNGARIAN = 25, + RPC_LOC_NI_SS_POLISH = 26, + RPC_LOC_NI_SS_LANGUAGE_UNSPEC = 27, + RPC_LOC_NI_SUPL_UTF8 = 28, + RPC_LOC_NI_SUPL_UCS2 = 29, + RPC_LOC_NI_SUPL_GSM_DEFAULT = 30, + RPC_LOC_NI_SUPL_ENCODING_UNKNOWN = 2147483647 +}; + +enum rpc_loc_ni_vx_requester_id_encoding_scheme_e_type { + RPC_LOC_NI_VX_OCTET = 0, + RPC_LOC_NI_VX_EXN_PROTOCOL_MSG = 1, + RPC_LOC_NI_VX_ASCII = 2, + RPC_LOC_NI_VX_IA5 = 3, + RPC_LOC_NI_VX_UNICODE = 4, + RPC_LOC_NI_VX_SHIFT_JIS = 5, + RPC_LOC_NI_VX_KOREAN = 6, + RPC_LOC_NI_VX_LATIN_HEBREW = 7, + RPC_LOC_NI_VX_LATIN = 8, + RPC_LOC_NI_VX_GSM = 9, + RPC_LOC_NI_VX_ENCODING_TYPE_MAX = 268435456 +}; + +enum rpc_loc_ni_vx_pos_mode_e_type { + RPC_LOC_VX_MS_ASSISTED_ONLY = 1, + RPC_LOC_VX_MS_BASED_ONLY = 2, + RPC_LOC_VX_MS_ASSISTED_PREF_MSBASED_ALLWD = 3, + RPC_LOC_VX_MS_BASED_PREF_ASSISTED_ALLWD = 4, + RPC_LOC_VX_POS_MODE_MAX = 268435456 +}; + +struct rpc_loc_ni_vx_requester_id_s_type { + unsigned char requester_id_length; + opaque requester_id[200]; +}; + +struct rpc_loc_ni_vx_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + unsigned char pos_qos_incl; + unsigned char pos_qos; + rpc_uint32 num_fixes; + rpc_uint32 tbf; + rpc_loc_ni_vx_pos_mode_e_type pos_mode; + rpc_loc_ni_vx_requester_id_encoding_scheme_e_type encoding_scheme; + rpc_loc_ni_vx_requester_id_s_type requester_id; + rpc_uint16 user_resp_timer_val; +}; + +enum rpc_loc_ni_supl_pos_method_e_type { + RPC_LOC_NI_POSMETHOD_AGPS_SETASSISTED = 1, + RPC_LOC_NI_POSMETHOD_AGPS_SETBASED = 2, + RPC_LOC_NI_POSMETHOD_AGPS_SETASSISTED_PREF = 3, + RPC_LOC_NI_POSMETHOD_AGPS_SETBASED_PREF = 4, + RPC_LOC_NI_POSMETHOD_AUTONOMOUS_GPS = 5, + RPC_LOC_NI_POSMETHOD_AFLT = 6, + RPC_LOC_NI_POSMETHOD_ECID = 7, + RPC_LOC_NI_POSMETHOD_EOTD = 8, + RPC_LOC_NI_POSMETHOD_OTDOA = 9, + RPC_LOC_NI_POSMETHOD_NO_POSITION = 10, + RPC_LOC_NI_POSMETHOD_MAX = 268435456 +}; + +struct rpc_loc_ni_supl_slp_session_id_s_type { + unsigned char presence; + opaque session_id[4]; + rpc_loc_server_info_s_type slp_address; +}; + +struct rpc_loc_ni_requestor_id_s_type { + unsigned char data_coding_scheme; + opaque requestor_id_string[200]; + unsigned char string_len; +}; + +struct rpc_loc_ni_supl_client_name_s_type { + unsigned char data_coding_scheme; + opaque client_name_string[64]; + unsigned char string_len; +}; + +struct rpc_loc_ni_supl_qop_s_type { + unsigned char bit_mask; + unsigned char horacc; + unsigned char veracc; + rpc_uint16 maxLocAge; + unsigned char delay; +}; + +struct rpc_loc_ni_supl_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + rpc_uint16 flags; + rpc_loc_ni_supl_slp_session_id_s_type supl_slp_session_id; + opaque supl_hash[8]; + rpc_loc_ni_datacoding_scheme_e_type datacoding_scheme; + rpc_loc_ni_supl_pos_method_e_type pos_method; + rpc_loc_ni_requestor_id_s_type requestor_id; + rpc_loc_ni_supl_client_name_s_type client_name; + rpc_loc_ni_supl_qop_s_type supl_qop; + rpc_uint16 user_response_timer; +}; + +struct rpc_loc_ni_ext_client_address_s_type { + unsigned char ext_client_address_len; + opaque ext_client_address[20]; +}; + +enum rpc_loc_ni_location_type_e_type { + RPC_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION = 1, + RPC_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION = 2, + RPC_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION = 3, + RPC_LOC_NI_LOCATIONTYPE_MAX = 268435456 +}; + +struct rpc_loc_ni_deferred_location_s_type { + unsigned char unused_bits; + unsigned char ms_available; +}; + +struct rpc_loc_ni_codeword_string_s_type { + unsigned char data_coding_scheme; + opaque lcs_codeword_string[20]; + unsigned char string_len; +}; + +struct rpc_loc_ni_service_type_id_s_type { + unsigned char lcs_service_type_id; +}; + +struct rpc_loc_ni_umts_cp_notify_verify_req_s_type { + rpc_loc_ni_notify_verify_e_type notification_priv_type; + unsigned char invoke_id; + rpc_uint16 flags; + unsigned char notification_length; + opaque notification_text[64]; + rpc_loc_ni_datacoding_scheme_e_type datacoding_scheme; + rpc_loc_ni_ext_client_address_s_type ext_client_address_data; + rpc_loc_ni_location_type_e_type location_type; + rpc_loc_ni_deferred_location_s_type deferred_location; + rpc_loc_ni_requestor_id_s_type requestor_id; + rpc_loc_ni_codeword_string_s_type codeword_string; + rpc_loc_ni_service_type_id_s_type service_type_id; + rpc_uint16 user_response_timer; +}; + +enum rpc_loc_ni_service_interaction_e_type { + RPC_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO = 1, + RPC_LOC_NI_SERVICE_INTERACTION_MAX = 268435456 +}; + +struct rpc_loc_ni_vx_service_interaction_req_s_type { + rpc_loc_ni_vx_notify_verify_req_s_type ni_vx_req; + rpc_loc_ni_service_interaction_e_type service_interation_type; +}; + +union rpc_loc_ni_event_payload_u_type switch (rpc_loc_ni_event_e_type disc) { + case RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ: + rpc_loc_ni_vx_notify_verify_req_s_type vx_req; + case RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ: + rpc_loc_ni_supl_notify_verify_req_s_type supl_req; + case RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ: + rpc_loc_ni_umts_cp_notify_verify_req_s_type umts_cp_req; + case RPC_LOC_NI_EVENT_VX_SERVICE_INTERACTION_REQ: + rpc_loc_ni_vx_service_interaction_req_s_type service_interaction_req; + default: + void; +}; + +struct rpc_loc_ni_event_s_type { + rpc_loc_ni_event_e_type event; + rpc_loc_ni_event_payload_u_type payload; +}; + +enum rpc_loc_assist_data_request_e_type { + RPC_LOC_ASSIST_DATA_TIME_REQ = 1, + RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ = 2, + RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ = 3, + RPC_LOC_ASSIST_DATA_MAX = 268435456 +}; + +typedef string rpc_struct_loc_time_download_source_s_type_servers_ptr<256>; /* EVAL:[LOC_API_MAX_SERVER_ADDR_LENGTH]*/ + +typedef rpc_struct_loc_time_download_source_s_type_servers_ptr rpc_struct_loc_time_download_source_s_type_servers[3]; + +struct rpc_loc_time_download_source_s_type { + rpc_uint32 delay_threshold; + rpc_struct_loc_time_download_source_s_type_servers servers; +}; + +typedef string rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr; + +typedef rpc_struct_loc_predicted_orbits_data_source_s_type_servers_ptr rpc_struct_loc_predicted_orbits_data_source_s_type_servers[3]; + +struct rpc_loc_predicted_orbits_data_source_s_type { + rpc_uint32 max_file_size; + rpc_uint32 max_part_size; + rpc_struct_loc_predicted_orbits_data_source_s_type_servers servers; +}; + +struct rpc_loc_pos_inj_request_s_type { + rpc_uint32 flags; + double latitude; + double longitude; + rpc_uint32 position_uncertainty; + rpc_uint64 timestamp; +}; + +union rpc_loc_assist_data_request_payload_u_type switch (rpc_loc_assist_data_request_e_type disc) { + case RPC_LOC_ASSIST_DATA_TIME_REQ: + rpc_loc_time_download_source_s_type time_download; + case RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ: + rpc_loc_predicted_orbits_data_source_s_type data_download; + case RPC_LOC_ASSIST_DATA_POSITION_INJECTION_REQ: + rpc_loc_pos_inj_request_s_type pos_injection; + default: + void; +}; + +struct rpc_loc_assist_data_request_s_type { + rpc_loc_assist_data_request_e_type event; + rpc_loc_assist_data_request_payload_u_type payload; +}; + +typedef rpc_uint32 rpc_loc_server_connection_handle; + +enum rpc_loc_server_protocol_e_type { + RPC_LOC_SERVER_PROTOCOL_DEFAULT = 0, + RPC_LOC_SERVER_PROTOCOL_SUPL = 1, + RPC_LOC_SERVER_PROTOCOL_VX_MPC = 2, + RPC_LOC_SERVER_PROTOCOL_VX_PDE = 3, + RPC_LOC_SERVER_PROTOCOL_MAX = 16777216 +}; + +enum rpc_loc_server_connection_e_type { + RPC_LOC_SERVER_CONNECTION_LBS = 0, + RPC_LOC_SERVER_CONNECTION_WWAN_INTERNET, + RPC_LOC_SERVER_CONNECTION_MAX = 16777216 +}; + +enum rpc_loc_server_request_e_type { + RPC_LOC_SERVER_REQUEST_OPEN = 1, + RPC_LOC_SERVER_REQUEST_CLOSE = 2, + RPC_LOC_SERVER_REQUEST_MULTI_OPEN = 3, + RPC_LOC_SERVER_REQUEST_MAX = 268435456 +}; + +struct rpc_loc_server_open_req_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_protocol_e_type protocol; +}; + +struct rpc_loc_server_multi_open_req_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_protocol_e_type protocol; + rpc_loc_server_connection_e_type connection_type; +}; + +struct rpc_loc_server_close_req_s_type { + rpc_loc_server_connection_handle conn_handle; +}; + +union rpc_loc_server_request_u_type switch (rpc_loc_server_request_e_type disc) { + case RPC_LOC_SERVER_REQUEST_OPEN: + rpc_loc_server_open_req_s_type open_req; + case RPC_LOC_SERVER_REQUEST_CLOSE: + rpc_loc_server_close_req_s_type close_req; + case RPC_LOC_SERVER_REQUEST_MULTI_OPEN: + rpc_loc_server_multi_open_req_s_type multi_open_req; + default: + void; +}; + +struct rpc_loc_server_request_s_type { + rpc_loc_server_request_e_type event; + rpc_loc_server_request_u_type payload; +}; + +enum rpc_loc_qwip_request_e_type { + RPC_LOC_QWIP_START_PERIODIC_HI_FREQ_FIXES = 0, + RPC_LOC_QWIP_START_PERIODIC_KEEP_WARM, + RPC_LOC_QWIP_STOP_PERIODIC_FIXES, + RPC_LOC_QWIP_SUSPEND, + RPC_LOC_QWIP_REQUEST_MAX = 268435456 +}; + +struct rpc_loc_qwip_request_s_type { + rpc_loc_qwip_request_e_type request_type; + rpc_uint16 tbf_ms; +}; + +struct rpc_loc_reserved_payload_s_type { + rpc_uint16 data_size; + opaque data<>; +}; + +enum rpc_loc_ioctl_e_type { + RPC_LOC_IOCTL_GET_API_VERSION = 1, + RPC_LOC_IOCTL_SET_FIX_CRITERIA = 2, + RPC_LOC_IOCTL_GET_FIX_CRITERIA = 3, + RPC_LOC_IOCTL_SERVICE_START_INDEX = 400, + RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE = 400, + RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA = 401, + RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY = 402, + RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE = 403, + RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD = 404, + RPC_LOC_IOCTL_INJECT_UTC_TIME = 405, + RPC_LOC_IOCTL_INJECT_RTC_VALUE = 406, + RPC_LOC_IOCTL_INJECT_POSITION = 407, + RPC_LOC_IOCTL_QUERY_ENGINE_STATE = 408, + RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS = 409, + RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS = 410, + RPC_LOC_IOCTL_SEND_WIPER_POSITION_REPORT = 411, + RPC_LOC_IOCTL_NOTIFY_WIPER_STATUS = 412, + RPC_LOC_IOCTL_ACCESS_EFS_DATA = 413, + RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG = 414, + RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS = 415, + RPC_LOC_IOCTL_NV_SETTINGS_START_INDEX = 800, + RPC_LOC_IOCTL_SET_ENGINE_LOCK = 800, + RPC_LOC_IOCTL_GET_ENGINE_LOCK = 801, + RPC_LOC_IOCTL_SET_SBAS_CONFIG = 802, + RPC_LOC_IOCTL_GET_SBAS_CONFIG = 803, + RPC_LOC_IOCTL_SET_NMEA_TYPES = 804, + RPC_LOC_IOCTL_GET_NMEA_TYPES = 805, + RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR = 806, + RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR = 807, + RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR = 808, + RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR = 809, + RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR = 810, + RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR = 811, + RPC_LOC_IOCTL_SET_ON_DEMAND_LPM = 812, + RPC_LOC_IOCTL_GET_ON_DEMAND_LPM = 813, + RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL = 814, + RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL = 815, + RPC_LOC_IOCTL_SET_LBS_APN_PROFILE = 816, + RPC_LOC_IOCTL_GET_LBS_APN_PROFILE = 817, + RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE = 818, + RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE = 819, + RPC_LOC_IOCTL_SET_DATA_ENABLE = 820, + RPC_LOC_IOCTL_SET_SUPL_VERSION = 821, + RPC_LOC_IOCTL_GET_SUPL_VERSION = 822, + RPC_LOC_IOCTL_PROPRIETARY_START_INDEX = 1000, + RPC_LOC_IOCTL_DELETE_ASSIST_DATA = 1000, + RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR = 1001, + RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR = 1002, + RPC_LOC_IOCTL_RESERVED_CMD = 8000, + RPC_LOC_IOCTL_THIRD_PARTY_START_INDEX = 1073741824 +}; + +struct rpc_loc_api_version_s_type { + unsigned char major; + unsigned char minor; +}; + +enum rpc_loc_fix_recurrence_e_type { + RPC_LOC_PERIODIC_FIX = 1, + RPC_LOC_SINGLE_FIX = 2, + RPC_LOC_FIX_SESSION_TYPE_MAX = 268435456 +}; + +enum rpc_loc_operation_mode_e_type { + RPC_LOC_OPER_MODE_DEFAULT = 1, + RPC_LOC_OPER_MODE_MSB = 2, + RPC_LOC_OPER_MODE_MSA = 3, + RPC_LOC_OPER_MODE_STANDALONE = 4, + RPC_LOC_OPER_MODE_SPEED_OPTIMAL = 5, + RPC_LOC_OPER_MODE_ACCURACY_OPTIMAL = 6, + RPC_LOC_OPER_MODE_DATA_OPTIMAL = 7, + RPC_LOC_OPER_MODE_CELL_ID = 8, + RPC_LOC_OPER_MODE_MAX = 268435456 +}; + +enum rpc_loc_notify_e_type { + RPC_LOC_NOTIFY_ON_INTERVAL = 1, + RPC_LOC_NOTIFY_ON_DISTANCE = 2, + RPC_LOC_NOTIFY_ON_ANY = 3, + RPC_LOC_NOTIFY_ON_ALL = 4, + RPC_LOC_NOTIFY_TYPE_MAX = 268435456 +}; + +struct rpc_loc_fix_criteria_s_type { + rpc_uint32 valid_mask; + rpc_loc_fix_recurrence_e_type recurrence_type; + rpc_loc_operation_mode_e_type preferred_operation_mode; + rpc_uint32 preferred_accuracy; + rpc_uint32 preferred_response_time; + rpc_boolean intermediate_pos_report_enabled; + rpc_loc_notify_e_type notify_type; + rpc_uint32 min_interval; + float min_distance; + rpc_uint32 min_dist_sample_interval; +}; + +enum rpc_loc_ni_user_resp_e_type { + RPC_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT = 1, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_DENY = 2, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_NORESP = 3, + RPC_LOC_NI_LCS_NOTIFY_VERIFY_MAX = 268435456 +}; + +struct rpc_loc_user_verify_s_type { + rpc_loc_ni_user_resp_e_type user_resp; + rpc_loc_ni_event_s_type ni_event_pass_back; +}; + +enum rpc_loc_predicted_orbits_data_format_e_type { + RPC_LOC_PREDICTED_ORBITS_XTRA = 0, + RPC_LOC_PREDICTED_ORBITS_FORMAT_MAX = 268435456 +}; + +struct rpc_loc_predicted_orbits_data_s_type { + rpc_loc_predicted_orbits_data_format_e_type format_type; + rpc_uint32 total_size; + rpc_uint8 total_parts; + rpc_uint8 part; + rpc_uint16 part_len; + opaque data_ptr<>; +}; + +struct rpc_loc_predicted_orbits_data_validity_report_s_type { + rpc_uint64 start_time_utc; + rpc_uint16 valid_duration_hrs; +}; + +struct rpc_loc_predicted_orbits_auto_download_config_s_type { + rpc_boolean enable; + unsigned char auto_check_every_hrs; +}; + +struct rpc_loc_assist_data_time_s_type { + rpc_uint64 time_utc; + rpc_uint32 uncertainty; +}; + +typedef rpc_uint64 rpc_loc_assist_pos_valid_mask_type; + +struct rpc_loc_assist_data_pos_s_type { + rpc_loc_assist_pos_valid_mask_type valid_mask; + rpc_uint64 timestamp_utc; + double latitude; + double longitude; + float altitude_wrt_ellipsoid; + float altitude_wrt_mean_sea_level; + float hor_unc_circular; + float vert_unc; + unsigned char confidence_horizontal; + unsigned char confidence_vertical; + rpc_int32 timestamp_age; +}; + +enum rpc_loc_server_open_status_e_type { + RPC_LOC_SERVER_OPEN_SUCCESS = 1, + RPC_LOC_SERVER_OPEN_FAIL = 2, + RPC_LOC_SERVER_OPEN_STATUS_MAX = 268435456 +}; + +enum rpc_loc_server_pdp_type_e_type { + RPC_LOC_SERVER_PDP_IP = 0, + RPC_LOC_SERVER_PDP_PPP, + RPC_LOC_SERVER_PDP_IPV6, + RPC_LOC_SERVER_PDP_IPV4V6, + RPC_LOC_SERVER_PDP_MAX = 268435456 +}; + +struct rpc_loc_server_open_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_open_status_e_type open_status; + opaque apn_name[100]; +}; + +struct rpc_loc_server_multi_open_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_open_status_e_type open_status; + rpc_loc_server_pdp_type_e_type pdp_type; + opaque apn_name[100]; +}; + +enum rpc_loc_server_close_status_e_type { + RPC_LOC_SERVER_CLOSE_SUCCESS = 1, + RPC_LOC_SERVER_CLOSE_FAIL = 2, + RPC_LOC_SERVER_CLOSE_STATUS_MAX = 268435456 +}; + +struct rpc_loc_server_close_status_s_type { + rpc_loc_server_connection_handle conn_handle; + rpc_loc_server_close_status_e_type close_status; +}; + +struct rpc_loc_wiper_fix_time_s_type { + rpc_uint32 slow_clock_count; +}; + +struct rpc_loc_wiper_fix_pos_s_type { + rpc_int32 lat; + rpc_int32 lon; + rpc_uint16 HEPE; + rpc_uint8 num_of_aps_used; + rpc_uint8 fix_error_code; +}; + +struct rpc_loc_wiper_ap_info_s_type { + opaque mac_addr[6]; + rpc_int32 rssi; + rpc_uint16 channel; + rpc_uint8 ap_qualifier; +}; + +struct rpc_loc_wiper_ap_set_s_type { + rpc_uint8 num_of_aps; + rpc_loc_wiper_ap_info_s_type ap_info[50]; +}; + +struct rpc_loc_wiper_position_report_s_type { + rpc_uint8 wiper_valid_info_flag; + rpc_loc_wiper_fix_time_s_type wiper_fix_time; + rpc_loc_wiper_fix_pos_s_type wiper_fix_position; + rpc_loc_wiper_ap_set_s_type wiper_ap_set; +}; + +enum rpc_loc_wiper_status_e_type { + RPC_LOC_WIPER_STATUS_AVAILABLE = 1, + RPC_LOC_WIPER_STATUS_UNAVAILABLE = 2, + RPC_LOC_WIPER_STATUS_E_SIZE = 268435456 +}; + +enum rpc_loc_fs_operation_e_type { + RPC_LOC_FS_CREATE_WRITE_FILE = 1, + RPC_LOC_FS_APPEND_FILE = 2, + RPC_LOC_FS_DELETE_FILE = 3, + RPC_LOC_FS_READ_FILE = 4, + RPC_LOC_FS_MAX = 268435456 +}; + +struct rpc_loc_efs_data_s_type { + opaque filename[64]; + rpc_loc_fs_operation_e_type operation; + rpc_uint32 total_size; + opaque data_ptr<>; + rpc_uint32 part_len; + rpc_uint8 part; + rpc_uint8 total_parts; + rpc_uint32 reserved; +}; + +enum rpc_loc_error_estimate_config_e_type { + RPC_LOC_ERROR_ESTIMATE_CONFIG_SET = 1, + RPC_LOC_ERROR_ESTIMATE_CONFIG_CLEAR = 2, + RPC_LOC_ERROR_ESTIMATE_MAX = 268435456 +}; + +struct rpc_loc_apn_profiles_type { + rpc_uint32 srv_system_type; + rpc_uint32 pdp_type; + rpc_uint32 reserved; + opaque apn_name[100]; +}; + +enum rpc_loc_lock_e_type { + RPC_LOC_LOCK_NONE = 1, + RPC_LOC_LOCK_MI = 2, + RPC_LOC_LOCK_MT = 3, + RPC_LOC_LOCK_ALL = 4, + RPC_LOC_LOCK_MAX = 268435456 +}; + +typedef rpc_uint32 rpc_loc_nmea_sentence_type; + +typedef rpc_uint32 rpc_loc_assist_data_type; + +struct rpc_loc_assist_data_delete_s_type { + rpc_loc_assist_data_type type; + rpc_uint32 reserved[8]; +}; + +union rpc_loc_ioctl_data_u_type switch (rpc_loc_ioctl_e_type disc) { + case RPC_LOC_IOCTL_SET_FIX_CRITERIA: + rpc_loc_fix_criteria_s_type fix_criteria; + case RPC_LOC_IOCTL_INFORM_NI_USER_RESPONSE: + rpc_loc_user_verify_s_type user_verify_resp; + case RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA: + rpc_loc_predicted_orbits_data_s_type predicted_orbits_data; + case RPC_LOC_IOCTL_SET_PREDICTED_ORBITS_DATA_AUTO_DOWNLOAD: + rpc_loc_predicted_orbits_auto_download_config_s_type predicted_orbits_auto_download; + case RPC_LOC_IOCTL_INJECT_UTC_TIME: + rpc_loc_assist_data_time_s_type assistance_data_time; + case RPC_LOC_IOCTL_INJECT_POSITION: + rpc_loc_assist_data_pos_s_type assistance_data_position; + case RPC_LOC_IOCTL_INFORM_SERVER_OPEN_STATUS: + rpc_loc_server_open_status_s_type conn_open_status; + case RPC_LOC_IOCTL_INFORM_SERVER_CLOSE_STATUS: + rpc_loc_server_close_status_s_type conn_close_status; + case RPC_LOC_IOCTL_SEND_WIPER_POSITION_REPORT: + rpc_loc_wiper_position_report_s_type wiper_pos; + case RPC_LOC_IOCTL_NOTIFY_WIPER_STATUS: + rpc_loc_wiper_status_e_type wiper_status; + case RPC_LOC_IOCTL_SET_ENGINE_LOCK: + rpc_loc_lock_e_type engine_lock; + case RPC_LOC_IOCTL_SET_SBAS_CONFIG: + rpc_boolean sbas_mode; + case RPC_LOC_IOCTL_SET_NMEA_TYPES: + rpc_loc_nmea_sentence_type nmea_types; + case RPC_LOC_IOCTL_SET_ON_DEMAND_LPM: + rpc_boolean on_demand_lpm; + case RPC_LOC_IOCTL_SET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_SET_CUSTOM_PDE_SERVER_ADDR: + rpc_loc_server_info_s_type server_addr; + case RPC_LOC_IOCTL_DELETE_ASSIST_DATA: + rpc_loc_assist_data_delete_s_type assist_data_delete; + case RPC_LOC_IOCTL_ACCESS_EFS_DATA: + rpc_loc_efs_data_s_type efs_data; + case RPC_LOC_IOCTL_ERROR_ESTIMATE_CONFIG: + rpc_loc_error_estimate_config_e_type error_estimate_config; + case RPC_LOC_IOCTL_SET_XTRA_T_SESSION_CONTROL: + rpc_uint8 xtra_t_session_control; + case RPC_LOC_IOCTL_SET_LBS_APN_PROFILE: + case RPC_LOC_IOCTL_SET_XTRA_APN_PROFILE: + rpc_loc_apn_profiles_type apn_profiles[6]; + case RPC_LOC_IOCTL_SET_DATA_ENABLE: + rpc_boolean data_enable; + case RPC_LOC_IOCTL_SET_SUPL_VERSION: + rpc_uint32 supl_version; + case RPC_LOC_IOCTL_INFORM_SERVER_MULTI_OPEN_STATUS: + rpc_loc_server_multi_open_status_s_type multi_conn_open_status; + case RPC_LOC_IOCTL_RESERVED_CMD: + rpc_loc_reserved_payload_s_type reserved; + default: + void; +}; + +union rpc_loc_ioctl_callback_data_u_type switch (rpc_loc_ioctl_e_type disc) { + case RPC_LOC_IOCTL_GET_API_VERSION: + rpc_loc_api_version_s_type api_version; + case RPC_LOC_IOCTL_GET_FIX_CRITERIA: + rpc_loc_fix_criteria_s_type fix_criteria; + case RPC_LOC_IOCTL_GET_ENGINE_LOCK: + rpc_loc_lock_e_type engine_lock; + case RPC_LOC_IOCTL_GET_SBAS_CONFIG: + rpc_boolean sbas_mode; + case RPC_LOC_IOCTL_GET_NMEA_TYPES: + rpc_loc_nmea_sentence_type nmea_types; + case RPC_LOC_IOCTL_GET_ON_DEMAND_LPM: + rpc_boolean on_demand_lpm; + case RPC_LOC_IOCTL_GET_CDMA_PDE_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CDMA_MPC_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_UMTS_SLP_SERVER_ADDR: + case RPC_LOC_IOCTL_GET_CUSTOM_PDE_SERVER_ADDR: + rpc_loc_server_info_s_type server_addr; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_SOURCE: + rpc_loc_predicted_orbits_data_source_s_type predicted_orbits_data_source; + case RPC_LOC_IOCTL_QUERY_PREDICTED_ORBITS_DATA_VALIDITY: + rpc_loc_predicted_orbits_data_validity_report_s_type predicted_orbits_data_validity; + case RPC_LOC_IOCTL_GET_XTRA_T_SESSION_CONTROL: + rpc_uint8 xtra_t_session_control; + case RPC_LOC_IOCTL_GET_LBS_APN_PROFILE: + case RPC_LOC_IOCTL_GET_XTRA_APN_PROFILE: + rpc_loc_apn_profiles_type apn_profiles[6]; + case RPC_LOC_IOCTL_GET_SUPL_VERSION: + rpc_uint32 supl_version; + default: + void; +}; + +struct rpc_loc_ioctl_callback_s_type { + rpc_loc_ioctl_e_type type; + rpc_int32 status; + rpc_loc_ioctl_callback_data_u_type data; +}; + +union rpc_loc_event_payload_u_type switch (unsigned hyper disc) { + case RPC_LOC_EVENT_PARSED_POSITION_REPORT: + rpc_loc_parsed_position_s_type parsed_location_report; + case RPC_LOC_EVENT_SATELLITE_REPORT: + rpc_loc_gnss_info_s_type gnss_report; + case RPC_LOC_EVENT_NMEA_POSITION_REPORT: + case RPC_LOC_EVENT_NMEA_1HZ_REPORT: + rpc_loc_nmea_report_s_type nmea_report; + case RPC_LOC_EVENT_NI_NOTIFY_VERIFY_REQUEST: + rpc_loc_ni_event_s_type ni_request; + case RPC_LOC_EVENT_ASSISTANCE_DATA_REQUEST: + rpc_loc_assist_data_request_s_type assist_data_request; + case RPC_LOC_EVENT_LOCATION_SERVER_REQUEST: + rpc_loc_server_request_s_type loc_server_request; + case RPC_LOC_EVENT_IOCTL_REPORT: + rpc_loc_ioctl_callback_s_type ioctl_report; + case RPC_LOC_EVENT_STATUS_REPORT: + rpc_loc_status_event_s_type status_report; + case RPC_LOC_EVENT_WPS_NEEDED_REQUEST: + rpc_loc_qwip_request_s_type qwip_request; + case RPC_LOC_EVENT_RESERVED: + rpc_loc_reserved_payload_s_type reserved; + default: + void; +}; + diff --git a/loc_api/libloc_api-rpc/Android.mk b/loc_api/libloc_api-rpc/Android.mk index a0fec50f..f70cba50 100755 --- a/loc_api/libloc_api-rpc/Android.mk +++ b/loc_api/libloc_api-rpc/Android.mk @@ -1,13 +1,7 @@ -#Copyright (c) 2009, QUALCOMM USA, INC. -#All rights reserved. -#Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -#· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -#· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -#· Neither the name of the QUALCOMM USA, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ifneq ($(BUILD_TINY_ANDROID),true) +ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_AMSS_VERSION),50001) + LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) @@ -63,3 +57,4 @@ LOCAL_MODULE:= libloc_api-rpc include $(BUILD_STATIC_LIBRARY) endif +endif diff --git a/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr b/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr index 60f730c2..5d9cf6c8 100755 --- a/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr +++ b/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr @@ -1,12 +1,3 @@ -# Copyright (c) 2009, QUALCOMM USA, INC. -# All rights reserved. -# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -# · Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -# · Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -# · Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - CLIENTS:= loc_api SERVERS:= loc_api_cb COMMON:= loc_api_common diff --git a/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c index 571bbda7..fbaca8b6 100755 --- a/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c +++ b/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c @@ -67,8 +67,8 @@ when who what, where, why #include /* Comment this out to enable logging */ -#undef ALOGD -#define ALOGD(...) {} +#undef LOGD +#define LOGD(...) {} /*===================================================================== External declarations @@ -99,17 +99,17 @@ bool_t rpc_loc_event_cb_f_type_0x00040001_svc( /* Callback not registered, or unexpected ID (shouldn't happen) */ if (loc_api_saved_cb == NULL || argp->cb_id != LOC_API_CB_ID) { - ALOGD("Warning: No callback handler.\n"); + LOGD("Warning: No callback handler.\n"); ret->loc_event_cb_f_type_result = 0; return 1; /* simply return */ } - ALOGD("proc: %x prog: %x vers: %x\n", + LOGD("proc: %x prog: %x vers: %x\n", (int) req->rq_proc, (int) req->rq_prog, (int) req->rq_vers); - ALOGD("Callback received: %x (handle=%d ret_ptr=%d)\n", + LOGD("Callback received: %x (handle=%d ret_ptr=%d)\n", (int) argp->loc_event, (int) argp->loc_handle, (int) ret); @@ -133,7 +133,7 @@ int loc_apicbprog_freeresult (SVCXPRT *transp, xdrproc_t xdr_result, caddr_t res /* * Insert additional freeing code here, if needed */ - // ALOGD("***** loc_apicbprog_freeresult\n"); + // LOGD("***** loc_apicbprog_freeresult\n"); return 1; } @@ -160,9 +160,9 @@ int loc_api_glue_init(void) if (loc_api_clnt == NULL) { /* Print msg */ - ALOGD("Trying to create RPC client...\n"); + LOGD("Trying to create RPC client...\n"); loc_api_clnt = clnt_create(NULL, LOC_APIPROG, LOC_APIVERS, NULL); - ALOGD("Created loc_api_clnt ---- %x\n", (unsigned int)loc_api_clnt); + LOGD("Created loc_api_clnt ---- %x\n", (unsigned int)loc_api_clnt); if (loc_api_clnt == NULL) { @@ -174,7 +174,7 @@ int loc_api_glue_init(void) int rc = loc_apicb_app_init(); if (rc >= 0) { - ALOGD("Loc API callback initialized.\n"); + LOGD("Loc API callback initialized.\n"); } else { fprintf(stderr, "Loc API callback initialization failed.\n"); return 0; diff --git a/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr b/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr index 60f730c2..5d9cf6c8 100755 --- a/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr +++ b/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr @@ -1,12 +1,3 @@ -# Copyright (c) 2009, QUALCOMM USA, INC. -# All rights reserved. -# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -# · Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -# · Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -# · Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - - CLIENTS:= loc_api SERVERS:= loc_api_cb COMMON:= loc_api_common diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c index cb9350ed..8c171222 100755 --- a/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c +++ b/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c @@ -67,8 +67,8 @@ when who what, where, why #include /* Comment this out to enable logging */ -#undef ALOGD -#define ALOGD(...) {} +#undef LOGD +#define LOGD(...) {} /*===================================================================== External declarations @@ -99,17 +99,17 @@ bool_t rpc_loc_event_cb_f_type_0x00010001_svc( /* Callback not registered, or unexpected ID (shouldn't happen) */ if (loc_api_saved_cb == NULL || argp->cb_id != LOC_API_CB_ID) { - ALOGD("Warning: No callback handler.\n"); + LOGD("Warning: No callback handler.\n"); ret->loc_event_cb_f_type_result = 0; return 1; /* simply return */ } - ALOGD("proc: %x prog: %x vers: %x\n", + LOGD("proc: %x prog: %x vers: %x\n", (int) req->rq_proc, (int) req->rq_prog, (int) req->rq_vers); - ALOGD("Callback received: %x (handle=%d ret_ptr=%d)\n", + LOGD("Callback received: %x (handle=%d ret_ptr=%d)\n", (int) argp->loc_event, (int) argp->loc_handle, (int) ret); @@ -133,7 +133,7 @@ int loc_apicbprog_freeresult (SVCXPRT *transp, xdrproc_t xdr_result, caddr_t res /* * Insert additional freeing code here, if needed */ - // ALOGD("***** loc_apicbprog_freeresult\n"); + // LOGD("***** loc_apicbprog_freeresult\n"); return 1; } @@ -160,9 +160,9 @@ int loc_api_glue_init(void) if (loc_api_clnt == NULL) { /* Print msg */ - ALOGD("Trying to create RPC client...\n"); + LOGD("Trying to create RPC client...\n"); loc_api_clnt = clnt_create(NULL, LOC_APIPROG, /*LOC_APIVERS*/ 0x00010000, NULL); - ALOGD("Created loc_api_clnt ---- %x\n", (unsigned int)loc_api_clnt); + LOGD("Created loc_api_clnt ---- %x\n", (unsigned int)loc_api_clnt); if (loc_api_clnt == NULL) { @@ -174,7 +174,7 @@ int loc_api_glue_init(void) int rc = loc_apicb_app_init(); if (rc >= 0) { - ALOGD("Loc API callback initialized.\n"); + LOGD("Loc API callback initialized.\n"); } else { fprintf(stderr, "Loc API callback initialization failed.\n"); return 0; diff --git a/loc_api/libloc_api-rpc/inc/debug.h b/loc_api/libloc_api-rpc/inc/debug.h index bef0ad39..a71b23a0 100755 --- a/loc_api/libloc_api-rpc/inc/debug.h +++ b/loc_api/libloc_api-rpc/inc/debug.h @@ -25,7 +25,7 @@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND #define PRINT(x...) do { \ fprintf(stdout, "%s(%d) ", __FUNCTION__, __LINE__); \ fprintf(stdout, ##x); \ - ALOGD(x); \ + LOGD(x); \ } while(0) #ifdef DEBUG @@ -43,14 +43,14 @@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND #define E(x...) do { \ fprintf(stderr, "%s(%d) ", __FUNCTION__, __LINE__); \ fprintf(stderr, ##x); \ - ALOGE(x); \ + LOGE(x); \ } while(0) #define FAILIF(cond, msg...) do { \ if (__builtin_expect (cond, 0)) { \ fprintf(stderr, "%s:%s:(%d): ", __FILE__, __FUNCTION__, __LINE__); \ fprintf(stderr, ##msg); \ - ALOGE(##msg); \ + LOGE(##msg); \ } \ } while(0) diff --git a/loc_api/libloc_api/Android.mk b/loc_api/libloc_api/Android.mk index df2ff2d0..f20280ee 100755 --- a/loc_api/libloc_api/Android.mk +++ b/loc_api/libloc_api/Android.mk @@ -1,11 +1,5 @@ -#Copyright (c) 2009, QUALCOMM USA, INC. -#All rights reserved. -#Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -#· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -#· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -#· Neither the name of the QUALCOMM USA, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - +#Compile the old library version from Google push for Passion builds with old modem image +ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_AMSS_VERSION),50001) LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) @@ -42,4 +36,4 @@ LOCAL_C_INCLUDES:= \ LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw include $(BUILD_SHARED_LIBRARY) - +endif #BOARD_VENDOR_QCOM_GPS_LOC_API_AMSS_VERSION = 50001 diff --git a/loc_api/libloc_api/gps.c b/loc_api/libloc_api/gps.c index a28a608e..5f6d8095 100644 --- a/loc_api/libloc_api/gps.c +++ b/loc_api/libloc_api/gps.c @@ -1,29 +1,31 @@ -/****************************************************************************** - @file: gps.c - @brief: - - DESCRIPTION - This file defines the implemenation for GPS hardware abstraction layer. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #include @@ -55,7 +57,7 @@ static struct hw_module_methods_t gps_module_methods = { .open = open_gps }; -struct hw_module_t HAL_MODULE_INFO_SYM = { +const struct hw_module_t HAL_MODULE_INFO_SYM = { .tag = HARDWARE_MODULE_TAG, .version_major = 1, .version_minor = 0, diff --git a/loc_api/libloc_api/loc_eng.cpp b/loc_api/libloc_api/loc_eng.cpp index 48c94f31..68ac002c 100755 --- a/loc_api/libloc_api/loc_eng.cpp +++ b/loc_api/libloc_api/loc_eng.cpp @@ -1,35 +1,31 @@ -/****************************************************************************** - @file: loc_eng.cpp - @brief: - - DESCRIPTION - This file defines the implemenation for GPS hardware abstraction layer. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #define LOG_NDDEBUG 0 @@ -57,8 +53,8 @@ $Author: $ #include // comment this out to enable logging -// #undef ALOGD -// #define ALOGD(...) {} +// #undef LOGD +// #define LOGD(...) {} #define DEBUG_MOCK_NI 0 @@ -150,7 +146,7 @@ const GpsInterface* gps_get_hardware_interface () property_get("gps.disable", propBuf, ""); if (propBuf[0] == '1') { - ALOGD("gps_get_interface returning NULL because gps.disable=1\n"); + LOGD("gps_get_interface returning NULL because gps.disable=1\n"); return NULL; } @@ -240,7 +236,7 @@ static int loc_eng_init(GpsCallbacks* callbacks) loc_eng_data.deferred_action_thread = callbacks->create_thread_cb("loc_api", loc_eng_process_deferred_action, NULL); - ALOGD ("loc_eng_init called, client id = %d\n", (int32) loc_eng_data.client_handle); + LOGD ("loc_eng_init called, client id = %d\n", (int32) loc_eng_data.client_handle); return 0; } @@ -314,20 +310,20 @@ SIDE EFFECTS static int loc_eng_start() { int ret_val; - ALOGD ("loc_eng_start\n"); + LOGD ("loc_eng_start\n"); if (loc_eng_data.position_mode != GPS_POSITION_MODE_STANDALONE && loc_eng_data.agps_server_host[0] != 0 && loc_eng_data.agps_server_port != 0) { int result = set_agps_server(); - ALOGD ("set_agps_server returned = %d\n", result); + LOGD ("set_agps_server returned = %d\n", result); } ret_val = loc_start_fix (loc_eng_data.client_handle); if (ret_val != RPC_LOC_API_SUCCESS) { - ALOGD ("loc_eng_start returned error = %d\n", ret_val); + LOGD ("loc_eng_start returned error = %d\n", ret_val); } return 0; @@ -354,7 +350,7 @@ static int loc_eng_stop() { int ret_val; - ALOGD ("loc_eng_stop\n"); + LOGD ("loc_eng_stop\n"); pthread_mutex_lock(&(loc_eng_data.deferred_stop_mutex)); // work around problem with loc_eng_stop when AGPS requests are pending @@ -362,7 +358,7 @@ static int loc_eng_stop() if (loc_eng_data.agps_request_pending) { loc_eng_data.stop_request_pending = true; - ALOGD ("deferring stop until AGPS data call is finished\n"); + LOGD ("deferring stop until AGPS data call is finished\n"); pthread_mutex_unlock(&(loc_eng_data.deferred_stop_mutex)); return 0; } @@ -371,7 +367,7 @@ static int loc_eng_stop() ret_val = loc_stop_fix (loc_eng_data.client_handle); if (ret_val != RPC_LOC_API_SUCCESS) { - ALOGD ("loc_eng_stop returned error = %d\n", ret_val); + LOGD ("loc_eng_stop returned error = %d\n", ret_val); } return 0; @@ -382,7 +378,7 @@ static int loc_eng_set_gps_lock(rpc_loc_lock_e_type lock_type) rpc_loc_ioctl_data_u_type ioctl_data; boolean ret_val; - ALOGD ("loc_eng_set_gps_lock mode, client = %d, lock_type = %d\n", + LOGD ("loc_eng_set_gps_lock mode, client = %d, lock_type = %d\n", (int32) loc_eng_data.client_handle, lock_type); ioctl_data.rpc_loc_ioctl_data_u_type_u.engine_lock = lock_type; @@ -396,7 +392,7 @@ static int loc_eng_set_gps_lock(rpc_loc_lock_e_type lock_type) if (ret_val != TRUE) { - ALOGD ("loc_eng_set_gps_lock mode failed\n"); + LOGD ("loc_eng_set_gps_lock mode failed\n"); } return 0; @@ -425,7 +421,7 @@ static int loc_eng_set_position_mode(GpsPositionMode mode, GpsPositionRecurrence rpc_loc_fix_criteria_s_type *fix_criteria_ptr; boolean ret_val; - ALOGD ("loc_eng_set_position mode, client = %d, interval = %d, mode = %d\n", + LOGD ("loc_eng_set_position mode, client = %d, interval = %d, mode = %d\n", (int32) loc_eng_data.client_handle, min_interval, mode); loc_eng_data.position_mode = mode; @@ -478,7 +474,7 @@ static int loc_eng_set_position_mode(GpsPositionMode mode, GpsPositionRecurrence if (ret_val != TRUE) { - ALOGD ("loc_eng_set_position mode failed\n"); + LOGD ("loc_eng_set_position mode failed\n"); } return 0; @@ -506,7 +502,7 @@ static int loc_eng_inject_time (GpsUtcTime time, int64_t timeReference, int unce rpc_loc_assist_data_time_s_type *time_info_ptr; boolean ret_val; - ALOGD ("loc_eng_inject_time, uncertainty = %d\n", uncertainty); + LOGD ("loc_eng_inject_time, uncertainty = %d\n", uncertainty); ioctl_data.disc = RPC_LOC_IOCTL_INJECT_UTC_TIME; @@ -523,7 +519,7 @@ static int loc_eng_inject_time (GpsUtcTime time, int64_t timeReference, int unce if (ret_val != TRUE) { - ALOGD ("loc_eng_inject_time failed\n"); + LOGD ("loc_eng_inject_time failed\n"); } return 0; @@ -708,7 +704,7 @@ static int32 loc_event_cb( const rpc_loc_event_payload_u_type* loc_event_payload ) { - ALOGV ("loc_event_cb, client = %d, loc_event = 0x%x", (int32) client_handle, (uint32) loc_event); + LOGV ("loc_event_cb, client = %d, loc_event = 0x%x", (int32) client_handle, (uint32) loc_event); if (client_handle == loc_eng_data.client_handle) { pthread_mutex_lock(&loc_eng_data.deferred_action_mutex); @@ -723,7 +719,7 @@ static int32 loc_event_cb( } else { - ALOGD ("loc client mismatch: received = %d, expected = %d \n", (int32) client_handle, (int32) loc_eng_data.client_handle); + LOGD ("loc client mismatch: received = %d, expected = %d \n", (int32) client_handle, (int32) loc_eng_data.client_handle); } return RPC_LOC_API_SUCCESS; @@ -749,7 +745,7 @@ static void loc_eng_report_position (const rpc_loc_parsed_position_s_type *locat { GpsLocation location; - ALOGV ("loc_eng_report_position: location report, valid mask = 0x%x, sess status = %d\n", + LOGV ("loc_eng_report_position: location report, valid mask = 0x%x, sess status = %d\n", (uint32) location_report_ptr->valid_mask, location_report_ptr->session_status); memset (&location, 0, sizeof(location)); @@ -800,18 +796,18 @@ static void loc_eng_report_position (const rpc_loc_parsed_position_s_type *locat if (loc_eng_data.location_cb != NULL) { - ALOGV ("loc_eng_report_position: fire callback\n"); + LOGV ("loc_eng_report_position: fire callback\n"); loc_eng_data.location_cb (&location); } } else { - ALOGV ("loc_eng_report_position: ignore position report when session status = %d\n", location_report_ptr->session_status); + LOGV ("loc_eng_report_position: ignore position report when session status = %d\n", location_report_ptr->session_status); } } else { - ALOGV ("loc_eng_report_position: ignore position report when session status is not set\n"); + LOGV ("loc_eng_report_position: ignore position report when session status is not set\n"); } } @@ -837,7 +833,7 @@ static void loc_eng_report_sv (const rpc_loc_gnss_info_s_type *gnss_report_ptr) int num_svs_max, i; const rpc_loc_sv_info_s_type *sv_info_ptr; - ALOGV ("loc_eng_report_sv: valid_mask = 0x%x, num of sv = %d\n", + LOGV ("loc_eng_report_sv: valid_mask = 0x%x, num of sv = %d\n", (uint32) gnss_report_ptr->valid_mask, gnss_report_ptr->sv_count); @@ -923,7 +919,7 @@ static void loc_eng_report_sv (const rpc_loc_gnss_info_s_type *gnss_report_ptr) } } - ALOGV ("num_svs = %d, eph mask = %d, alm mask = %d\n", SvStatus.num_svs, SvStatus.ephemeris_mask, SvStatus.almanac_mask ); + LOGV ("num_svs = %d, eph mask = %d, alm mask = %d\n", SvStatus.num_svs, SvStatus.ephemeris_mask, SvStatus.almanac_mask ); if ((SvStatus.num_svs != 0) && (loc_eng_data.sv_status_cb != NULL)) { loc_eng_data.sv_status_cb(&SvStatus); @@ -950,7 +946,7 @@ static void loc_eng_report_status (const rpc_loc_status_event_s_type *status_rep { GpsStatus status; - ALOGV ("loc_eng_report_status: event = %d\n", status_report_ptr->event); + LOGV ("loc_eng_report_status: event = %d\n", status_report_ptr->event); memset (&status, 0, sizeof(status)); status.size = sizeof(status); @@ -1024,7 +1020,7 @@ SIDE EFFECTS ===========================================================================*/ static void loc_eng_process_conn_request (const rpc_loc_server_request_s_type *server_request_ptr) { - ALOGD ("loc_event_cb: get loc event location server request, event = %d\n", server_request_ptr->event); + LOGD ("loc_event_cb: get loc event location server request, event = %d\n", server_request_ptr->event); // Signal DeferredActionThread to send the APN name pthread_mutex_lock(&loc_eng_data.deferred_action_mutex); @@ -1068,14 +1064,14 @@ SIDE EFFECTS ===========================================================================*/ static void loc_eng_agps_init(AGpsCallbacks* callbacks) { - ALOGV("loc_eng_agps_init\n"); + LOGV("loc_eng_agps_init\n"); loc_eng_data.agps_status_cb = callbacks->status_cb; } static int loc_eng_agps_data_conn_open(const char* apn) { int apn_len; - ALOGD("loc_eng_agps_data_conn_open: %s\n", apn); + LOGD("loc_eng_agps_data_conn_open: %s\n", apn); pthread_mutex_lock(&(loc_eng_data.deferred_action_mutex)); @@ -1085,7 +1081,7 @@ static int loc_eng_agps_data_conn_open(const char* apn) if (apn_len >= sizeof(loc_eng_data.apn_name)) { - ALOGD ("loc_eng_set_apn: error, apn name exceeds maximum lenght of 100 chars\n"); + LOGD ("loc_eng_set_apn: error, apn name exceeds maximum lenght of 100 chars\n"); apn_len = sizeof(loc_eng_data.apn_name) - 1; } @@ -1103,7 +1099,7 @@ static int loc_eng_agps_data_conn_open(const char* apn) static int loc_eng_agps_data_conn_closed() { - ALOGD("loc_eng_agps_data_conn_closed\n"); + LOGD("loc_eng_agps_data_conn_closed\n"); pthread_mutex_lock(&(loc_eng_data.deferred_action_mutex)); /* hold a wake lock while events are pending for deferred_action_thread */ loc_eng_data.acquire_wakelock_cb(); @@ -1115,7 +1111,7 @@ static int loc_eng_agps_data_conn_closed() static int loc_eng_agps_data_conn_failed() { - ALOGD("loc_eng_agps_data_conn_failed\n"); + LOGD("loc_eng_agps_data_conn_failed\n"); pthread_mutex_lock(&(loc_eng_data.deferred_action_mutex)); /* hold a wake lock while events are pending for deferred_action_thread */ @@ -1163,7 +1159,7 @@ static int set_agps_server() server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_val = url; server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_len = strlen(url); - ALOGD ("set_agps_server, addr = %s\n", server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_val); + LOGD ("set_agps_server, addr = %s\n", server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr.addr_val); #else char* buf = server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr; int buf_len = sizeof(server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.addr); @@ -1174,7 +1170,7 @@ static int set_agps_server() (loc_eng_data.agps_server_port & (0x0000ffff))); server_info_ptr->addr_info.rpc_loc_server_addr_u_type_u.url.length = buf_len; - ALOGD ("set_agps_server, addr = %s\n", buf); + LOGD ("set_agps_server, addr = %s\n", buf); #endif ret_val = loc_eng_ioctl (loc_eng_data.client_handle, @@ -1185,19 +1181,19 @@ static int set_agps_server() if (ret_val != TRUE) { - ALOGD ("set_agps_server failed\n"); + LOGD ("set_agps_server failed\n"); return -1; } else { - ALOGV ("set_agps_server successful\n"); + LOGV ("set_agps_server successful\n"); return 0; } } static int loc_eng_agps_set_server(AGpsType type, const char* hostname, int port) { - ALOGD ("loc_eng_set_default_agps_server, type = %d, hostname = %s, port = %d\n", type, hostname, port); + LOGD ("loc_eng_set_default_agps_server, type = %d, hostname = %s, port = %d\n", type, hostname, port); if (type != AGPS_TYPE_SUPL) return -1; @@ -1246,7 +1242,7 @@ static void loc_eng_delete_aiding_data_deferred_action (void) LOC_IOCTL_DEFAULT_TIMEOUT, NULL); - ALOGD("loc_eng_ioctl for aiding data deletion returned %d, 1 for success\n", ret_val); + LOGD("loc_eng_ioctl for aiding data deletion returned %d, 1 for success\n", ret_val); } /*=========================================================================== @@ -1274,7 +1270,7 @@ static void loc_eng_process_atl_deferred_action (int flags) boolean ret_val; int agps_status = -1; - ALOGV("loc_eng_process_atl_deferred_action, agps_status = %d\n", loc_eng_data.agps_status); + LOGV("loc_eng_process_atl_deferred_action, agps_status = %d\n", loc_eng_data.agps_status); memset (&ioctl_data, 0, sizeof (rpc_loc_ioctl_data_u_type)); @@ -1304,7 +1300,7 @@ static void loc_eng_process_atl_deferred_action (int flags) #endif // Delay this so that PDSM ATL module will behave properly sleep (1); - ALOGD("loc_eng_ioctl for ATL with apn_name = %s\n", conn_open_status_ptr->apn_name); + LOGD("loc_eng_ioctl for ATL with apn_name = %s\n", conn_open_status_ptr->apn_name); } else // data_connection_failed { @@ -1320,7 +1316,7 @@ static void loc_eng_process_atl_deferred_action (int flags) LOC_IOCTL_DEFAULT_TIMEOUT, NULL); - ALOGD("loc_eng_ioctl for ATL returned %d (1 for success)\n", ret_val); + LOGD("loc_eng_ioctl for ATL returned %d (1 for success)\n", ret_val); } /*=========================================================================== @@ -1368,7 +1364,7 @@ static void loc_eng_process_loc_event (rpc_loc_event_mask_type loc_event, if (loc_event_payload->rpc_loc_event_payload_u_type_u.assist_data_request.event == RPC_LOC_ASSIST_DATA_PREDICTED_ORBITS_REQ) { - ALOGD ("loc_event_cb: xtra download requst"); + LOGD ("loc_event_cb: xtra download requst"); // Call Registered callback if (loc_eng_data.xtra_module_data.download_request_cb != NULL) @@ -1429,13 +1425,13 @@ static void loc_eng_process_deferred_action (void* arg) status.size = sizeof(status); status.type = AGPS_TYPE_SUPL; - ALOGD("loc_eng_process_deferred_action started\n"); + LOGD("loc_eng_process_deferred_action started\n"); // make sure we do not run in background scheduling group set_sched_policy(gettid(), SP_FOREGROUND); // disable the GPS lock - ALOGD("Setting GPS privacy lock to RPC_LOC_LOCK_NONE\n"); + LOGD("Setting GPS privacy lock to RPC_LOC_LOCK_NONE\n"); loc_eng_set_gps_lock(RPC_LOC_LOCK_NONE); while (1) @@ -1506,10 +1502,10 @@ static void loc_eng_process_deferred_action (void* arg) loc_eng_data.agps_request_pending = false; if (loc_eng_data.stop_request_pending) { - ALOGD ("handling deferred stop\n"); + LOGD ("handling deferred stop\n"); if (loc_stop_fix(loc_eng_data.client_handle) != RPC_LOC_API_SUCCESS) { - ALOGD ("loc_stop_fix failed!\n"); + LOGD ("loc_stop_fix failed!\n"); } } pthread_mutex_unlock(&(loc_eng_data.deferred_stop_mutex)); @@ -1521,10 +1517,10 @@ static void loc_eng_process_deferred_action (void* arg) } // reenable the GPS lock - ALOGD("Setting GPS privacy lock to RPC_LOC_LOCK_ALL\n"); + LOGD("Setting GPS privacy lock to RPC_LOC_LOCK_ALL\n"); loc_eng_set_gps_lock(RPC_LOC_LOCK_ALL); - ALOGD("loc_eng_process_deferred_action thread exiting\n"); + LOGD("loc_eng_process_deferred_action thread exiting\n"); loc_eng_data.release_wakelock_cb(); loc_eng_data.deferred_action_thread = 0; diff --git a/loc_api/libloc_api/loc_eng.h b/loc_api/libloc_api/loc_eng.h index 39f3d91b..553a97e0 100755 --- a/loc_api/libloc_api/loc_eng.h +++ b/loc_api/libloc_api/loc_eng.h @@ -1,35 +1,31 @@ -/****************************************************************************** - @file: loc_eng.h - @brief: - - DESCRIPTION - This file defines the global data structure used by this module. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #ifndef LOC_ENG_H #define LOC_ENG_H diff --git a/loc_api/libloc_api/loc_eng_ioctl.cpp b/loc_api/libloc_api/loc_eng_ioctl.cpp index f59cc4eb..a43d8cca 100755 --- a/loc_api/libloc_api/loc_eng_ioctl.cpp +++ b/loc_api/libloc_api/loc_eng_ioctl.cpp @@ -1,36 +1,32 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ -/****************************************************************************** - @file: loc_eng.cpp - @brief: - - DESCRIPTION - This file defines the implemenation for GPS hardware abstraction layer. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ #define LOG_NDDEBUG 0 #include @@ -52,8 +48,8 @@ $Author: $ #include // comment this out to enable logging -// #undef ALOGD -// #define ALOGD(...) {} +// #undef LOGD +// #define LOGD(...) {} // Function declarations static boolean loc_eng_ioctl_setup_cb( @@ -97,7 +93,7 @@ boolean loc_eng_ioctl( int rpc_ret_val; loc_eng_ioctl_data_s_type *ioctl_cb_data_ptr; - ALOGV ("loc_eng_ioctl: client = %d, ioctl_type = %d, cb_data =0x%x\n", (int32) handle, ioctl_type, (uint32) cb_data_ptr); + LOGV ("loc_eng_ioctl: client = %d, ioctl_type = %d, cb_data =0x%x\n", (int32) handle, ioctl_type, (uint32) cb_data_ptr); ioctl_cb_data_ptr = &(loc_eng_data.ioctl_data); // Select the callback we are waiting for @@ -109,7 +105,7 @@ boolean loc_eng_ioctl( ioctl_type, ioctl_data_ptr); - ALOGV ("loc_eng_ioctl: loc_ioctl returned %d \n", rpc_ret_val); + LOGV ("loc_eng_ioctl: loc_ioctl returned %d \n", rpc_ret_val); if (rpc_ret_val == RPC_LOC_API_SUCCESS) { @@ -164,7 +160,7 @@ static boolean loc_eng_ioctl_setup_cb( pthread_mutex_lock(&ioctl_cb_data_ptr->cb_data_mutex); if (ioctl_cb_data_ptr->cb_is_selected == TRUE) { - ALOGD ("loc_eng_ioctl_setup_cb: ERROR, another ioctl in progress \n"); + LOGD ("loc_eng_ioctl_setup_cb: ERROR, another ioctl in progress \n"); ret_val = FALSE; } else @@ -222,7 +218,7 @@ boolean loc_eng_ioctl_wait_cb( do { if (ioctl_cb_data_ptr->cb_is_selected == FALSE) { - ALOGD ("loc_eng_ioctl_wait_cb: ERROR called when cb_is_waiting is set to FALSE \n"); + LOGD ("loc_eng_ioctl_wait_cb: ERROR called when cb_is_waiting is set to FALSE \n"); ret_val = FALSE; break; } @@ -240,7 +236,7 @@ boolean loc_eng_ioctl_wait_cb( // Special case where callback is issued before loc_ioctl ever returns if (ioctl_cb_data_ptr->cb_has_arrived == TRUE) { - ALOGD ("loc_eng_ioctl_wait_cb: cb has arrived without waiting \n"); + LOGD ("loc_eng_ioctl_wait_cb: cb has arrived without waiting \n"); ret_val = TRUE; break; } @@ -260,7 +256,7 @@ boolean loc_eng_ioctl_wait_cb( ret_val = FALSE; } - ALOGV ("loc_eng_ioctl_wait_cb: pthread_cond_timedwait returned %d\n", rc); + LOGV ("loc_eng_ioctl_wait_cb: pthread_cond_timedwait returned %d\n", rc); } while (0); @@ -286,7 +282,7 @@ boolean loc_eng_ioctl_wait_cb( pthread_mutex_unlock(&ioctl_cb_data_ptr->cb_data_mutex); - ALOGV ("loc_eng_ioctl_wait_cb: returned %d\n", ret_val); + LOGV ("loc_eng_ioctl_wait_cb: returned %d\n", ret_val); return ret_val; } @@ -321,13 +317,13 @@ boolean loc_eng_ioctl_process_cb ( pthread_mutex_lock(&ioctl_cb_data_ptr->cb_data_mutex); if (client_handle != ioctl_cb_data_ptr->client_handle) { - ALOGD ("loc_eng_ioctl_process_cb: client handle mismatch, received = %d, expected = %d \n", + LOGD ("loc_eng_ioctl_process_cb: client handle mismatch, received = %d, expected = %d \n", (int32) client_handle, (int32) ioctl_cb_data_ptr->client_handle); ret_val = FALSE; } else if (cb_data_ptr->type != ioctl_cb_data_ptr->ioctl_type) { - ALOGD ("loc_eng_ioctl_process_cb: ioctl type mismatch, received = %d, expected = %d \n", + LOGD ("loc_eng_ioctl_process_cb: ioctl type mismatch, received = %d, expected = %d \n", cb_data_ptr->type, ioctl_cb_data_ptr->ioctl_type); ret_val = FALSE; } @@ -339,7 +335,7 @@ boolean loc_eng_ioctl_process_cb ( ioctl_cb_data_ptr->cb_has_arrived = TRUE; - ALOGV ("loc_eng_ioctl_process_cb: callback arrived for client = %d, ioctl = %d, status = %d\n", + LOGV ("loc_eng_ioctl_process_cb: callback arrived for client = %d, ioctl = %d, status = %d\n", (int32) ioctl_cb_data_ptr->client_handle, ioctl_cb_data_ptr->ioctl_type, (int32) ioctl_cb_data_ptr->cb_payload.status); diff --git a/loc_api/libloc_api/loc_eng_ioctl.h b/loc_api/libloc_api/loc_eng_ioctl.h index 4090a4d8..eb0c201a 100755 --- a/loc_api/libloc_api/loc_eng_ioctl.h +++ b/loc_api/libloc_api/loc_eng_ioctl.h @@ -1,37 +1,31 @@ -/****************************************************************************** - @file: loc_eng_ioctl.h - @brief: - - DESCRIPTION - This file defines the data structure used by any location client that - waits for the ioctl particular event to occur. Any one IOCTL can be pending - at any time. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #ifndef LOC_ENG_IOCTL_H #define LOC_ENG_IOCTL_H diff --git a/loc_api/libloc_api/loc_eng_ni.cpp b/loc_api/libloc_api/loc_eng_ni.cpp index c7636831..3df0af14 100755 --- a/loc_api/libloc_api/loc_eng_ni.cpp +++ b/loc_api/libloc_api/loc_eng_ni.cpp @@ -1,33 +1,33 @@ -/****************************************************************************** - @file: loc_eng_ni.cpp - @brief: module for network initiated interactions - - DESCRIPTION - LOC_API network initiated operation support - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- - Copyright (c) 2009 QUALCOMM Incorporated. - All Rights Reserved. QUALCOMM Proprietary and Confidential. - ----------------------------------------------------------------------------- -******************************************************************************/ - -/*===================================================================== - EDIT HISTORY FOR MODULE - - This section contains comments describing changes made to the module. - Notice that changes are listed in reverse chronological order. - -when who what, where, why --------- --- ------------------------------------------------------- -07/30/09 dx Initial version - -$Id: -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #define LOG_NDDEBUG 0 -#define LOG_NIDEBUG 0 #include #include @@ -46,8 +46,8 @@ $Id: #include // comment this out to enable logging -// #undef ALOGD -// #define ALOGD(...) {} +// #undef LOGD +// #define LOGD(...) {} /*============================================================================= * @@ -119,7 +119,7 @@ static void loc_ni_respond(rpc_loc_ni_user_resp_e_type resp, const rpc_loc_ni_event_s_type *request_pass_back ) { - ALOGD("Sending NI response: %s\n", respond_from_enum(resp)); + LOGD("Sending NI response: %s\n", respond_from_enum(resp)); rpc_loc_ioctl_data_u_type data; rpc_loc_ioctl_callback_s_type callback_payload; @@ -267,12 +267,12 @@ static void loc_ni_request_handler(const char *msg, const rpc_loc_ni_event_s_typ loc_ni_respond(response, ni_req); */ #endif - ALOGW("loc_ni_request_handler, notification in progress, new NI request ignored, type: %d", + LOGW("loc_ni_request_handler, notification in progress, new NI request ignored, type: %d", ni_req->event); } else { /* Print notification */ - ALOGD("NI Notification: %s, event: %d", msg, ni_req->event); + LOGD("NI Notification: %s, event: %d", msg, ni_req->event); pthread_mutex_lock(&loc_eng_ni_data.loc_ni_lock); @@ -366,9 +366,9 @@ static void loc_ni_request_handler(const char *msg, const rpc_loc_ni_event_s_typ #endif supl_req->client_name.string_len /* length */ ); - ALOGD("SUPL NI: client_name: %s len=%d", notif.text, supl_req->client_name.string_len); + LOGD("SUPL NI: client_name: %s len=%d", notif.text, supl_req->client_name.string_len); } else { - ALOGD("SUPL NI: client_name not present."); + LOGD("SUPL NI: client_name not present."); } // Requestor ID @@ -382,9 +382,9 @@ static void loc_ni_request_handler(const char *msg, const rpc_loc_ni_event_s_typ #endif supl_req->requestor_id.string_len /* length */ ); - ALOGD("SUPL NI: requestor_id: %s len=%d", notif.requestor_id, supl_req->requestor_id.string_len); + LOGD("SUPL NI: requestor_id: %s len=%d", notif.requestor_id, supl_req->requestor_id.string_len); } else { - ALOGD("SUPL NI: requestor_id not present."); + LOGD("SUPL NI: requestor_id not present."); } // Encoding type @@ -402,20 +402,20 @@ static void loc_ni_request_handler(const char *msg, const rpc_loc_ni_event_s_typ break; default: - ALOGE("loc_ni_request_handler, unknown request event: %d", ni_req->event); + LOGE("loc_ni_request_handler, unknown request event: %d", ni_req->event); return; } /* Log requestor ID and text for debugging */ - ALOGI("Notification: notif_type: %d, timeout: %d, default_resp: %d", notif.ni_type, notif.timeout, notif.default_response); - ALOGI(" requestor_id: %s (encoding: %d)", notif.requestor_id, notif.requestor_id_encoding); - ALOGI(" text: %s text (encoding: %d)", notif.text, notif.text_encoding); + LOGI("Notification: notif_type: %d, timeout: %d, default_resp: %d", notif.ni_type, notif.timeout, notif.default_response); + LOGI(" requestor_id: %s (encoding: %d)", notif.requestor_id, notif.requestor_id_encoding); + LOGI(" text: %s text (encoding: %d)", notif.text, notif.text_encoding); /* For robustness, always sets a timeout to clear up the notification status, even though * the OEM layer in java does not do so. **/ loc_eng_ni_data.response_time_left = 5 + (notif.timeout != 0 ? notif.timeout : LOC_NI_NO_RESPONSE_TIME); - ALOGI("Automatically sends 'no response' in %d seconds (to clear status)\n", loc_eng_ni_data.response_time_left); + LOGI("Automatically sends 'no response' in %d seconds (to clear status)\n", loc_eng_ni_data.response_time_left); pthread_mutex_unlock(&loc_eng_ni_data.loc_ni_lock); @@ -440,7 +440,7 @@ RETURN VALUE ===========================================================================*/ int loc_ni_process_user_response(GpsUserResponseType userResponse) { - ALOGD("NI response from UI: %d", userResponse); + LOGD("NI response from UI: %d", userResponse); rpc_loc_ni_user_resp_e_type resp; switch (userResponse) @@ -493,22 +493,22 @@ int loc_eng_ni_callback ( switch (ni_req->event) { case RPC_LOC_NI_EVENT_VX_NOTIFY_VERIFY_REQ: - ALOGI("VX Notification"); + LOGI("VX Notification"); loc_ni_request_handler("VX Notify", ni_req); break; case RPC_LOC_NI_EVENT_UMTS_CP_NOTIFY_VERIFY_REQ: - ALOGI("UMTS CP Notification\n"); + LOGI("UMTS CP Notification\n"); loc_ni_request_handler("UMTS CP Notify", ni_req); break; case RPC_LOC_NI_EVENT_SUPL_NOTIFY_VERIFY_REQ: - ALOGI("SUPL Notification\n"); + LOGI("SUPL Notification\n"); loc_ni_request_handler("SUPL Notify", ni_req); break; default: - ALOGE("Unknown NI event: %x\n", (int) ni_req->event); + LOGE("Unknown NI event: %x\n", (int) ni_req->event); break; } } @@ -522,7 +522,7 @@ FUNCTION loc_ni_thread_proc ===========================================================================*/ static void loc_ni_thread_proc(void *unused) { - ALOGI("Starting Loc NI thread...\n"); + LOGI("Starting Loc NI thread...\n"); while (1) { @@ -563,7 +563,7 @@ SIDE EFFECTS ===========================================================================*/ void loc_eng_ni_init(GpsNiCallbacks *callbacks) { - ALOGD("loc_eng_ni_init: entered."); + LOGD("loc_eng_ni_init: entered."); if (!loc_eng_ni_data_init) { @@ -600,10 +600,10 @@ void loc_eng_ni_respond(int notif_id, GpsUserResponseType user_response) { if (notif_id == loc_eng_ni_data.current_notif_id && loc_eng_ni_data.notif_in_progress) { - ALOGI("loc_eng_ni_respond: send user response %d for notif %d", user_response, notif_id); + LOGI("loc_eng_ni_respond: send user response %d for notif %d", user_response, notif_id); loc_ni_process_user_response(user_response); } else { - ALOGE("loc_eng_ni_respond: notif_id %d mismatch or notification not in progress, response: %d", + LOGE("loc_eng_ni_respond: notif_id %d mismatch or notification not in progress, response: %d", notif_id, user_response); } } diff --git a/loc_api/libloc_api/loc_eng_ni.h b/loc_api/libloc_api/loc_eng_ni.h index 88d285ae..193b9f85 100755 --- a/loc_api/libloc_api/loc_eng_ni.h +++ b/loc_api/libloc_api/loc_eng_ni.h @@ -1,30 +1,31 @@ -/****************************************************************************** - @file: loc_eng_ni.cpp - @brief: module for network initiated interactions - - DESCRIPTION - LOC_API network initiated operation support - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- - Copyright (c) 2009 QUALCOMM Incorporated. - All Rights Reserved. QUALCOMM Proprietary and Confidential. - ----------------------------------------------------------------------------- -******************************************************************************/ - -/*===================================================================== - EDIT HISTORY FOR MODULE - - This section contains comments describing changes made to the module. - Notice that changes are listed in reverse chronological order. - -when who what, where, why --------- --- ------------------------------------------------------- -07/30/09 dx Initial version - -$Id: -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #ifndef LOC_ENG_NI_H #define LOC_ENG_NI_H diff --git a/loc_api/libloc_api/loc_eng_xtra.cpp b/loc_api/libloc_api/loc_eng_xtra.cpp index c713c270..1ec3bf07 100755 --- a/loc_api/libloc_api/loc_eng_xtra.cpp +++ b/loc_api/libloc_api/loc_eng_xtra.cpp @@ -1,35 +1,32 @@ -/****************************************************************************** - @file: loc_eng.cpp - @brief: +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ - DESCRIPTION - This file defines the implemenation for GPS hardware abstraction layer. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ #define LOG_NDDEBUG 0 #include @@ -49,8 +46,8 @@ $Author: $ #include // comment this out to enable logging -// #undef ALOGD -// #define ALOGD(...) {} +// #undef LOGD +// #define LOGD(...) {} #define LOC_XTRA_INJECT_DEFAULT_TIMEOUT (3100) #define XTRA_BLOCK_SIZE (400) @@ -120,7 +117,7 @@ static int qct_loc_eng_inject_xtra_data(char* data, int length) rpc_loc_ioctl_data_u_type ioctl_data; rpc_loc_predicted_orbits_data_s_type *predicted_orbits_data_ptr; - ALOGV ("qct_loc_eng_inject_xtra_data, xtra size = %d, data ptr = 0x%x\n", length, (int) data); + LOGV ("qct_loc_eng_inject_xtra_data, xtra size = %d, data ptr = 0x%x\n", length, (int) data); ioctl_data.disc = RPC_LOC_IOCTL_INJECT_PREDICTED_ORBITS_DATA; @@ -147,8 +144,8 @@ static int qct_loc_eng_inject_xtra_data(char* data, int length) predicted_orbits_data_ptr->data_ptr.data_ptr_len = predicted_orbits_data_ptr->part_len; predicted_orbits_data_ptr->data_ptr.data_ptr_val = data + len_injected; - ALOGV ("qct_loc_eng_inject_xtra_data, inject part = %d, len = %d, len = %d\n", predicted_orbits_data_ptr->part, predicted_orbits_data_ptr->part_len, predicted_orbits_data_ptr->data_ptr.data_ptr_len); - ALOGV ("qct_loc_eng_inject_xtra_data, total part = %d, len = %d \n", predicted_orbits_data_ptr->part, predicted_orbits_data_ptr->part_len); + LOGV ("qct_loc_eng_inject_xtra_data, inject part = %d, len = %d, len = %d\n", predicted_orbits_data_ptr->part, predicted_orbits_data_ptr->part_len, predicted_orbits_data_ptr->data_ptr.data_ptr_len); + LOGV ("qct_loc_eng_inject_xtra_data, total part = %d, len = %d \n", predicted_orbits_data_ptr->part, predicted_orbits_data_ptr->part_len); if (part < total_parts) { @@ -159,7 +156,7 @@ static int qct_loc_eng_inject_xtra_data(char* data, int length) if (rpc_ret_val != RPC_LOC_API_SUCCESS) { - ALOGE ("loc_ioctl for xtra returned %d \n", rpc_ret_val); + LOGE ("loc_ioctl for xtra returned %d \n", rpc_ret_val); ret_val = EINVAL; // return error break; } @@ -176,7 +173,7 @@ static int qct_loc_eng_inject_xtra_data(char* data, int length) } len_injected += predicted_orbits_data_ptr->part_len; - ALOGV ("loc_ioctl for xtra len injected %d \n", len_injected); + LOGV ("loc_ioctl for xtra len injected %d \n", len_injected); } return ret_val; diff --git a/loc_api/libloc_api/loc_eng_xtra.h b/loc_api/libloc_api/loc_eng_xtra.h index b5c79451..82778ae5 100755 --- a/loc_api/libloc_api/loc_eng_xtra.h +++ b/loc_api/libloc_api/loc_eng_xtra.h @@ -1,35 +1,31 @@ -/****************************************************************************** - @file: loc_eng.h - @brief: - - DESCRIPTION - This file defines the data structure used by this XTRA module. - - INITIALIZATION AND SEQUENCING REQUIREMENTS - - ----------------------------------------------------------------------------- -Copyright (c) 2009, QUALCOMM USA, INC. - -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -· Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -· Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -· Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ----------------------------------------------------------------------------- - -******************************************************************************/ - -/*===================================================================== -$Header: $ -$DateTime: $ -$Author: $ -======================================================================*/ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ #ifndef LOC_ENG_XTRA_H #define LOC_ENG_XTRA_H diff --git a/loc_api/libloc_api_50001/Android.mk b/loc_api/libloc_api_50001/Android.mk new file mode 100755 index 00000000..0a5a0a10 --- /dev/null +++ b/loc_api/libloc_api_50001/Android.mk @@ -0,0 +1,131 @@ +ifneq ($(BUILD_TINY_ANDROID),true) +#Compile this library only for builds with the latest modem image + +BIT_ENABLED_BOARD_PLATFORM_LIST := msm7630_fusion +BIT_ENABLED_BOARD_PLATFORM_LIST += msm8660 +ifeq ($(call is-board-platform-in-list,$(BIT_ENABLED_BOARD_PLATFORM_LIST)),true) +FEATURE_GNSS_BIT_API := true +endif # is-board-platform-in-list + +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_MODULE := libloc_adapter + +LOCAL_MODULE_TAGS := optional + +LOCAL_SHARED_LIBRARIES := \ + libutils \ + libcutils \ + libgps.utils + +LOCAL_SRC_FILES += \ + loc_eng_log.cpp \ + LocApiAdapter.cpp + +LOCAL_CFLAGS += \ + -fno-short-enums \ + -D_ANDROID_ + +LOCAL_C_INCLUDES:= \ + $(TARGET_OUT_HEADERS)/gps.utils + +LOCAL_COPY_HEADERS_TO:= libloc_eng/ +LOCAL_COPY_HEADERS:= \ + LocApiAdapter.h \ + loc.h \ + loc_eng.h \ + loc_eng_xtra.h \ + loc_eng_ni.h \ + loc_eng_agps.h \ + loc_eng_msg.h \ + loc_eng_msg_id.h \ + loc_eng_log.h + +LOCAL_PRELINK_MODULE := false + +include $(BUILD_SHARED_LIBRARY) + +include $(CLEAR_VARS) + +LOCAL_MODULE := libloc_eng + +LOCAL_MODULE_TAGS := optional + +LOCAL_SHARED_LIBRARIES := \ + libutils \ + libcutils \ + libloc_adapter \ + libgps.utils \ + libdl + +LOCAL_SRC_FILES += \ + loc_eng.cpp \ + loc_eng_agps.cpp \ + loc_eng_xtra.cpp \ + loc_eng_ni.cpp \ + loc_eng_log.cpp + +ifeq ($(FEATURE_GNSS_BIT_API), true) +LOCAL_CFLAGS += -DFEATURE_GNSS_BIT_API +endif # FEATURE_GNSS_BIT_API + +LOCAL_SRC_FILES += \ + loc_eng_dmn_conn.cpp \ + loc_eng_dmn_conn_handler.cpp \ + loc_eng_dmn_conn_thread_helper.c \ + loc_eng_dmn_conn_glue_msg.c \ + loc_eng_dmn_conn_glue_pipe.c + +## Check if RPC is not unsupported +ifneq ($(TARGET_NO_RPC),true) +LOCAL_SHARED_LIBRARIES += libloc_api-rpc-qc +else +LOCAL_SHARED_LIBRARIES += libloc_api_v02 +endif #TARGET_NO_RPC + +LOCAL_CFLAGS += \ + -fno-short-enums \ + -D_ANDROID_ + +LOCAL_C_INCLUDES:= \ + $(TARGET_OUT_HEADERS)/gps.utils \ + hardware/qcom/gps/loc_api/ulp/inc + +LOCAL_PRELINK_MODULE := false + +include $(BUILD_SHARED_LIBRARY) + +include $(CLEAR_VARS) + +LOCAL_MODULE := gps.$(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE) + +LOCAL_MODULE_TAGS := optional + +## Libs + +LOCAL_SHARED_LIBRARIES := \ + libutils \ + libcutils \ + libloc_eng \ + libgps.utils + +LOCAL_SRC_FILES += \ + loc.cpp \ + gps.c + +LOCAL_CFLAGS += \ + -fno-short-enums \ + -D_ANDROID_ \ + +## Includes +LOCAL_C_INCLUDES:= \ + $(TARGET_OUT_HEADERS)/gps.utils + +LOCAL_PRELINK_MODULE := false +LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw + +include $(BUILD_SHARED_LIBRARY) + +endif # not BUILD_TINY_ANDROID diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp new file mode 100755 index 00000000..e631642d --- /dev/null +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -0,0 +1,196 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_adapter" + +#include +#include "loc_eng_msg.h" +#include "loc_log.h" +#include "loc_eng_ni.h" + +static void* noProc(void* data) +{ + return NULL; +} + +LocEng::LocEng(void* caller, + LOC_API_ADAPTER_EVENT_MASK_T emask, + gps_acquire_wakelock acqwl, + gps_release_wakelock relwl, + loc_msg_sender msgSender, + loc_ext_parser posParser, + loc_ext_parser svParser) : + owner(caller), + eventMask(emask), acquireWakelock(acqwl), + releaseWakeLock(relwl), sendMsge(msgSender), + extPosInfo(NULL == posParser ? noProc : posParser), + extSvInfo(NULL == svParser ? noProc : svParser) +{ + LOC_LOGV("LocEng constructor %p, %p", posParser, svParser); +} + +LocApiAdapter::LocApiAdapter(LocEng &locEng) : + locEngHandle(locEng) +{ + LOC_LOGD("LocApiAdapter created"); +} + +LocApiAdapter::~LocApiAdapter() +{ + LOC_LOGV("LocApiAdapter deleted"); +} + +int LocApiAdapter::hexcode(char *hexstring, int string_size, + const char *data, int data_size) +{ + int i; + for (i = 0; i < data_size; i++) + { + char ch = data[i]; + if (i*2 + 3 <= string_size) + { + snprintf(&hexstring[i*2], 3, "%02X", ch); + } + else { + break; + } + } + return i; +} + +int LocApiAdapter::decodeAddress(char *addr_string, int string_size, + const char *data, int data_size) +{ + const char addr_prefix = 0x91; + int i, idxOutput = 0; + + if (!data || !addr_string) { return 0; } + + if (data[0] != addr_prefix) + { + LOC_LOGW("decodeAddress: address prefix is not 0x%x but 0x%x", addr_prefix, data[0]); + addr_string[0] = '\0'; + return 0; // prefix not correct + } + + for (i = 1; i < data_size; i++) + { + unsigned char ch = data[i], low = ch & 0x0F, hi = ch >> 4; + if (low <= 9 && idxOutput < string_size - 1) { addr_string[idxOutput++] = low + '0'; } + if (hi <= 9 && idxOutput < string_size - 1) { addr_string[idxOutput++] = hi + '0'; } + } + + addr_string[idxOutput] = '\0'; // Terminates the string + + return idxOutput; +} + +void LocApiAdapter::reportPosition(GpsLocation &location, + void* locationExt, + enum loc_sess_status status) +{ + loc_eng_msg_report_position *msg(new loc_eng_msg_report_position(locEngHandle.owner, + location, + locationExt, + status)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::reportSv(GpsSvStatus &svStatus, void* svExt) +{ + loc_eng_msg_report_sv *msg(new loc_eng_msg_report_sv(locEngHandle.owner, svStatus, svExt)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::reportStatus(GpsStatusValue status) +{ + loc_eng_msg_report_status *msg(new loc_eng_msg_report_status(locEngHandle.owner, status)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::reportNmea(const char* nmea, int length) +{ + loc_eng_msg_report_nmea *msg(new loc_eng_msg_report_nmea(locEngHandle.owner, nmea, length)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::requestATL(int connHandle, AGpsType agps_type) +{ + loc_eng_msg_request_atl *msg(new loc_eng_msg_request_atl(locEngHandle.owner, connHandle, agps_type)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::releaseATL(int connHandle) +{ + loc_eng_msg_release_atl *msg(new loc_eng_msg_release_atl(locEngHandle.owner, connHandle)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::requestXtraData() +{ + LOC_LOGD("XTRA download request"); + + loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_REQUEST_XTRA_DATA)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::requestTime() +{ + LOC_LOGD("loc_event_cb: XTRA time download request... not supported"); + // loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_REQUEST_TIME)); + // locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::requestLocation() +{ + LOC_LOGD("loc_event_cb: XTRA time download request... not supported"); + // loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_REQUEST_POSITION)); + // locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::requestNiNotify(GpsNiNotification ¬if, const void* data) +{ + notif.size = sizeof(notif); + notif.timeout = LOC_NI_NO_RESPONSE_TIME; + + loc_eng_msg_request_ni *msg(new loc_eng_msg_request_ni(locEngHandle.owner, notif, data)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::handleEngineDownEvent() +{ + loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_ENGINE_DOWN)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} + +void LocApiAdapter::handleEngineUpEvent() +{ + loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_ENGINE_UP)); + locEngHandle.sendMsge(locEngHandle.owner, msg); +} diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h new file mode 100755 index 00000000..033a034c --- /dev/null +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -0,0 +1,205 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_API_ADAPTER_H +#define LOC_API_ADAPTER_H + +#include +#include +#include +#include + +#define MIN_POSSIBLE_FIX_INTERVAL 1000 /* msec */ + +enum loc_api_adapter_err { + LOC_API_ADAPTER_ERR_SUCCESS = 0, + LOC_API_ADAPTER_ERR_GENERAL_FAILURE = 1, + LOC_API_ADAPTER_ERR_UNSUPPORTED = 2, + LOC_API_ADAPTER_ERR_INVALID_HANDLE = 4, + LOC_API_ADAPTER_ERR_INVALID_PARAMETER = 5, + LOC_API_ADAPTER_ERR_ENGINE_BUSY = 6, + LOC_API_ADAPTER_ERR_PHONE_OFFLINE = 7, + LOC_API_ADAPTER_ERR_TIMEOUT = 8, + LOC_API_ADAPTER_ERR_SERVICE_NOT_PRESENT = 9, + + LOC_API_ADAPTER_ERR_ENGINE_DOWN = 100, + LOC_API_ADAPTER_ERR_FAILURE, + LOC_API_ADAPTER_ERR_UNKNOWN +}; + +enum loc_api_adapter_event_index { + LOC_API_ADAPTER_REPORT_POSITION = 0, // Position report comes in loc_parsed_position_s_type + LOC_API_ADAPTER_REPORT_SATELLITE, // Satellite in view report + LOC_API_ADAPTER_REPORT_NMEA_1HZ, // NMEA report at 1HZ rate + LOC_API_ADAPTER_REPORT_NMEA_POSITION, // NMEA report at position report rate + LOC_API_ADAPTER_REQUEST_NI_NOTIFY_VERIFY, // NI notification/verification request + LOC_API_ADAPTER_REQUEST_ASSISTANCE_DATA, // Assistance data, eg: time, predicted orbits request + LOC_API_ADAPTER_REQUEST_LOCATION_SERVER, // Request for location server + LOC_API_ADAPTER_REPORT_IOCTL, // Callback report for loc_ioctl + LOC_API_ADAPTER_REPORT_STATUS, // Misc status report: eg, engine state + + LOC_API_ADAPTER_EVENT_MAX +}; + +#define LOC_API_ADAPTER_BIT_PARSED_POSITION_REPORT (1< + +#include + +extern const GpsInterface* get_gps_interface(); + +const GpsInterface* gps__get_gps_interface(struct gps_device_t* dev) +{ + return get_gps_interface(); +} + +static int open_gps(const struct hw_module_t* module, char const* name, + struct hw_device_t** device) +{ + struct gps_device_t *dev = (struct gps_device_t *) malloc(sizeof(struct gps_device_t)); + memset(dev, 0, sizeof(*dev)); + + dev->common.tag = HARDWARE_DEVICE_TAG; + dev->common.version = 0; + dev->common.module = (struct hw_module_t*)module; + dev->get_gps_interface = gps__get_gps_interface; + + *device = (struct hw_device_t*)dev; + return 0; +} + +static struct hw_module_methods_t gps_module_methods = { + .open = open_gps +}; + +struct hw_module_t HAL_MODULE_INFO_SYM = { + .tag = HARDWARE_MODULE_TAG, + .module_api_version = 1, + .hal_api_version = 0, + .id = GPS_HARDWARE_MODULE_ID, + .name = "loc_api GPS Module", + .author = "Qualcomm USA, Inc.", + .methods = &gps_module_methods, +}; diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp new file mode 100755 index 00000000..16bed3b1 --- /dev/null +++ b/loc_api/libloc_api_50001/loc.cpp @@ -0,0 +1,870 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_afw" + +#include +#include +#include + +static gps_location_callback gps_loc_cb = NULL; +static gps_sv_status_callback gps_sv_cb = NULL; + +static void loc_cb(GpsLocation* location, void* locExt); +static void sv_cb(GpsSvStatus* sv_status, void* svExt); + +// Function declarations for sLocEngInterface +static int loc_init(GpsCallbacks* callbacks); +static int loc_start(); +static int loc_stop(); +static void loc_cleanup(); +static int loc_inject_time(GpsUtcTime time, int64_t timeReference, int uncertainty); +static int loc_inject_location(double latitude, double longitude, float accuracy); +static void loc_delete_aiding_data(GpsAidingData f); +static int loc_set_position_mode(GpsPositionMode mode, GpsPositionRecurrence recurrence, + uint32_t min_interval, uint32_t preferred_accuracy, + uint32_t preferred_time); +static const void* loc_get_extension(const char* name); +#ifdef QCOM_FEATURE_ULP +static int loc_update_criteria(UlpLocationCriteria criteria); +#endif + +// Defines the GpsInterface in gps.h +static const GpsInterface sLocEngInterface = +{ + sizeof(GpsInterface), + loc_init, + loc_start, + loc_stop, + loc_cleanup, + loc_inject_time, + loc_inject_location, + loc_delete_aiding_data, + loc_set_position_mode, + loc_get_extension +#ifdef QCOM_FEATURE_ULP + ,loc_update_criteria +#endif +}; + +// Function declarations for sLocEngAGpsInterface +static void loc_agps_init(AGpsCallbacks* callbacks); +#ifdef QCOM_FEATURE_IPV6 +static int loc_agps_open(AGpsType agpsType, + const char* apn, AGpsBearerType bearerType); +static int loc_agps_closed(AGpsType agpsType); +static int loc_agps_open_failed(AGpsType agpsType); +#else +static int loc_agps_open(const char* apn); +static int loc_agps_closed(); +static int loc_agps_open_failed(); +#endif +static int loc_agps_set_server(AGpsType type, const char *hostname, int port); + +static const AGpsInterface sLocEngAGpsInterface = +{ + sizeof(AGpsInterface), + loc_agps_init, + loc_agps_open, + loc_agps_closed, + loc_agps_open_failed, + loc_agps_set_server +}; + +static int loc_xtra_init(GpsXtraCallbacks* callbacks); +static int loc_xtra_inject_data(char* data, int length); + +static const GpsXtraInterface sLocEngXTRAInterface = +{ + sizeof(GpsXtraInterface), + loc_xtra_init, + loc_xtra_inject_data +}; + +static void loc_ni_init(GpsNiCallbacks *callbacks); +static void loc_ni_respond(int notif_id, GpsUserResponseType user_response); + +const GpsNiInterface sLocEngNiInterface = +{ + sizeof(GpsNiInterface), + loc_ni_init, + loc_ni_respond, +}; + +static void loc_agps_ril_init( AGpsRilCallbacks* callbacks ); +static void loc_agps_ril_set_ref_location(const AGpsRefLocation *agps_reflocation, size_t sz_struct); +static void loc_agps_ril_set_set_id(AGpsSetIDType type, const char* setid); +static void loc_agps_ril_ni_message(uint8_t *msg, size_t len); +static void loc_agps_ril_update_network_state(int connected, int type, int roaming, const char* extra_info); +static void loc_agps_ril_update_network_availability(int avaiable, const char* apn); + +static const AGpsRilInterface sLocEngAGpsRilInterface = +{ + sizeof(AGpsRilInterface), + loc_agps_ril_init, + loc_agps_ril_set_ref_location, + loc_agps_ril_set_set_id, + loc_agps_ril_ni_message, + loc_agps_ril_update_network_state, + loc_agps_ril_update_network_availability +}; + +#ifdef QCOM_FEATURE_ULP +static bool loc_inject_raw_command(char* command, int length); + +static const InjectRawCmdInterface sLocEngInjectRawCmdInterface = +{ + sizeof(InjectRawCmdInterface), + loc_inject_raw_command +}; +#endif + +static loc_eng_data_s_type loc_afw_data; + +/*=========================================================================== +FUNCTION gps_get_hardware_interface + +DESCRIPTION + Returns the GPS hardware interaface based on LOC API + if GPS is enabled. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +const GpsInterface* gps_get_hardware_interface () +{ + ENTRY_LOG_CALLFLOW(); + const GpsInterface* ret_val; + + char propBuf[PROPERTY_VALUE_MAX]; + + // check to see if GPS should be disabled + property_get("gps.disable", propBuf, ""); + if (propBuf[0] == '1') + { + LOC_LOGD("gps_get_interface returning NULL because gps.disable=1\n"); + ret_val = NULL; + } else { + ret_val = &sLocEngInterface; + } + + EXIT_LOG(%p, ret_val); + return ret_val; +} + +// for gps.c +extern "C" const GpsInterface* get_gps_interface() +{ + return &sLocEngInterface; +} +/*=========================================================================== +FUNCTION loc_init + +DESCRIPTION + Initialize the location engine, this include setting up global datas + and registers location engien with loc api service. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/Ax + +===========================================================================*/ +static int loc_init(GpsCallbacks* callbacks) +{ + ENTRY_LOG(); + LOC_API_ADAPTER_EVENT_MASK_T event = + LOC_API_ADAPTER_BIT_PARSED_POSITION_REPORT | + LOC_API_ADAPTER_BIT_SATELLITE_REPORT | + LOC_API_ADAPTER_BIT_LOCATION_SERVER_REQUEST | + LOC_API_ADAPTER_BIT_ASSISTANCE_DATA_REQUEST | + LOC_API_ADAPTER_BIT_IOCTL_REPORT | + LOC_API_ADAPTER_BIT_STATUS_REPORT | + LOC_API_ADAPTER_BIT_NMEA_1HZ_REPORT | + LOC_API_ADAPTER_BIT_NI_NOTIFY_VERIFY_REQUEST; + LocCallbacks clientCallbacks = {loc_cb, /* location_cb */ + callbacks->status_cb, /* status_cb */ + sv_cb, /* sv_status_cb */ + callbacks->nmea_cb, /* nmea_cb */ + callbacks->set_capabilities_cb, /* set_capabilities_cb */ + callbacks->acquire_wakelock_cb, /* acquire_wakelock_cb */ + callbacks->release_wakelock_cb, /* release_wakelock_cb */ + callbacks->create_thread_cb, /* create_thread_cb */ + NULL, /* location_ext_parser */ + NULL /* sv_ext_parser */}; + gps_loc_cb = callbacks->location_cb; + gps_sv_cb = callbacks->sv_status_cb; + + int ret_val = loc_eng_init(loc_afw_data, &clientCallbacks, event); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_cleanup + +DESCRIPTION + Cleans location engine. The location client handle will be released. + +DEPENDENCIES + None + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_cleanup() +{ + ENTRY_LOG(); + loc_eng_cleanup(loc_afw_data); + gps_loc_cb = NULL; + gps_sv_cb = NULL; + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_start + +DESCRIPTION + Starts the tracking session + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_start() +{ + ENTRY_LOG(); + int ret_val = loc_eng_start(loc_afw_data); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_stop + +DESCRIPTION + Stops the tracking session + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_stop() +{ + ENTRY_LOG(); + int ret_val = loc_eng_stop(loc_afw_data); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_set_position_mode + +DESCRIPTION + Sets the mode and fix frequency for the tracking session. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_set_position_mode(GpsPositionMode mode, + GpsPositionRecurrence recurrence, + uint32_t min_interval, + uint32_t preferred_accuracy, + uint32_t preferred_time) +{ + ENTRY_LOG(); + LocPositionMode locMode; + switch (mode) { + case GPS_POSITION_MODE_MS_BASED: + locMode = LOC_POSITION_MODE_MS_BASED; + break; + case GPS_POSITION_MODE_MS_ASSISTED: + locMode = LOC_POSITION_MODE_MS_ASSISTED; + break; + default: + locMode = LOC_POSITION_MODE_STANDALONE; + break; + } + int ret_val = loc_eng_set_position_mode(loc_afw_data, locMode, + recurrence, min_interval, + preferred_accuracy, preferred_time); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_inject_time + +DESCRIPTION + This is used by Java native function to do time injection. + +DEPENDENCIES + None + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_inject_time(GpsUtcTime time, int64_t timeReference, int uncertainty) +{ + ENTRY_LOG(); + int ret_val = loc_eng_inject_time(loc_afw_data, time, timeReference, uncertainty); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + + +/*=========================================================================== +FUNCTION loc_inject_location + +DESCRIPTION + This is used by Java native function to do location injection. + +DEPENDENCIES + None + +RETURN VALUE + 0 : Successful + error code : Failure + +SIDE EFFECTS + N/A +===========================================================================*/ +static int loc_inject_location(double latitude, double longitude, float accuracy) +{ + ENTRY_LOG(); + int ret_val = loc_eng_inject_location(loc_afw_data, latitude, longitude, accuracy); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + + +/*=========================================================================== +FUNCTION loc_delete_aiding_data + +DESCRIPTION + This is used by Java native function to delete the aiding data. The function + updates the global variable for the aiding data to be deleted. If the GPS + engine is off, the aiding data will be deleted. Otherwise, the actual action + will happen when gps engine is turned off. + +DEPENDENCIES + Assumes the aiding data type specified in GpsAidingData matches with + LOC API specification. + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_delete_aiding_data(GpsAidingData f) +{ + ENTRY_LOG(); + loc_eng_delete_aiding_data(loc_afw_data, f); + + EXIT_LOG(%s, VOID_RET); +} + +#ifdef QCOM_FEATURE_ULP +/*=========================================================================== +FUNCTION loc_update_criteria + +DESCRIPTION + This is used to inform the ULP module of new unique criteria that are passed + in by the applications +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_update_criteria(UlpLocationCriteria criteria) +{ + ENTRY_LOG(); + int ret_val = loc_eng_update_criteria(loc_afw_data, criteria); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#endif + +/*=========================================================================== +FUNCTION loc_get_extension + +DESCRIPTION + Get the gps extension to support XTRA. + +DEPENDENCIES + N/A + +RETURN VALUE + The GPS extension interface. + +SIDE EFFECTS + N/A + +===========================================================================*/ +static const void* loc_get_extension(const char* name) +{ + ENTRY_LOG(); + const void* ret_val = NULL; + + if (strcmp(name, GPS_XTRA_INTERFACE) == 0) + { + ret_val = &sLocEngXTRAInterface; + } + + else if (strcmp(name, AGPS_INTERFACE) == 0) + { + ret_val = &sLocEngAGpsInterface; + } + + else if (strcmp(name, GPS_NI_INTERFACE) == 0) + { + ret_val = &sLocEngNiInterface; + } + + else if (strcmp(name, AGPS_RIL_INTERFACE) == 0) + { + ret_val = &sLocEngAGpsRilInterface; + } +#ifdef QCOM_FEATURE_ULP + else if (strcmp(name, ULP_RAW_CMD_INTERFACE) == 0) + { + ret_val = &sLocEngInjectRawCmdInterface; + } +#endif + else + { + LOC_LOGE ("get_extension: Invalid interface passed in\n"); + } + + EXIT_LOG(%p, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_agps_init + +DESCRIPTION + Initialize the AGps interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_agps_init(AGpsCallbacks* callbacks) +{ + ENTRY_LOG(); + loc_eng_agps_init(loc_afw_data, callbacks); + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_agps_open + +DESCRIPTION + This function is called when on-demand data connection opening is successful. +It should inform ARM 9 about the data open result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +static int loc_agps_open(AGpsType agpsType, + const char* apn, AGpsBearerType bearerType) +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_open(loc_afw_data, agpsType, apn, bearerType); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#else +static int loc_agps_open(const char* apn) +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_open(loc_afw_data, apn); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#endif + +/*=========================================================================== +FUNCTION loc_agps_closed + +DESCRIPTION + This function is called when on-demand data connection closing is done. +It should inform ARM 9 about the data close result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +static int loc_agps_closed(AGpsType agpsType) +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_closed(loc_afw_data, agpsType); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#else +static int loc_agps_closed() +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_closed(loc_afw_data); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#endif + +/*=========================================================================== +FUNCTION loc_agps_open_failed + +DESCRIPTION + This function is called when on-demand data connection opening has failed. +It should inform ARM 9 about the data open result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +int loc_agps_open_failed(AGpsType agpsType) +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_open_failed(loc_afw_data, agpsType); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#else +int loc_agps_open_failed() +{ + ENTRY_LOG(); + int ret_val = loc_eng_agps_open_failed(loc_afw_data); + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#endif + +/*=========================================================================== +FUNCTION loc_agps_set_server + +DESCRIPTION + If loc_eng_set_server is called before loc_eng_init, it doesn't work. This + proxy buffers server settings and calls loc_eng_set_server when the client is + open. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_agps_set_server(AGpsType type, const char* hostname, int port) +{ + ENTRY_LOG(); + LocServerType serverType; + switch (type) { + case AGPS_TYPE_SUPL: + serverType = LOC_AGPS_SUPL_SERVER; + break; + case AGPS_TYPE_C2K: + serverType = LOC_AGPS_CDMA_PDE_SERVER; + break; + } + int ret_val = loc_eng_set_server_proxy(loc_afw_data, serverType, hostname, port); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_xtra_init + +DESCRIPTION + Initialize XTRA module. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_xtra_init(GpsXtraCallbacks* callbacks) +{ + ENTRY_LOG(); + int ret_val = loc_eng_xtra_init(loc_afw_data, callbacks); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + + +/*=========================================================================== +FUNCTION loc_xtra_inject_data + +DESCRIPTION + Initialize XTRA module. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_xtra_inject_data(char* data, int length) +{ + ENTRY_LOG(); + int ret_val = loc_eng_xtra_inject_data(loc_afw_data, data, length); + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_ni_init + +DESCRIPTION + This function initializes the NI interface + +DEPENDENCIES + NONE + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_ni_init(GpsNiCallbacks *callbacks) +{ + ENTRY_LOG(); + loc_eng_ni_init(loc_afw_data, callbacks); + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_ni_respond + +DESCRIPTION + This function sends an NI respond to the modem processor + +DEPENDENCIES + NONE + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_ni_respond(int notif_id, GpsUserResponseType user_response) +{ + ENTRY_LOG(); + loc_eng_ni_respond(loc_afw_data, notif_id, user_response); + EXIT_LOG(%s, VOID_RET); +} + +// Below stub functions are members of sLocEngAGpsRilInterface +static void loc_agps_ril_init( AGpsRilCallbacks* callbacks ) {} +static void loc_agps_ril_set_ref_location(const AGpsRefLocation *agps_reflocation, size_t sz_struct) {} +static void loc_agps_ril_set_set_id(AGpsSetIDType type, const char* setid) {} +static void loc_agps_ril_ni_message(uint8_t *msg, size_t len) {} +static void loc_agps_ril_update_network_state(int connected, int type, int roaming, const char* extra_info) {} + +/*=========================================================================== +FUNCTION loc_agps_ril_update_network_availability + +DESCRIPTION + Sets data call allow vs disallow flag to modem + This is the only member of sLocEngAGpsRilInterface implemented. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_agps_ril_update_network_availability(int available, const char* apn) +{ + ENTRY_LOG(); + loc_eng_agps_ril_update_network_availability(loc_afw_data, available, apn); + EXIT_LOG(%s, VOID_RET); +} + +#ifdef QCOM_FEATURE_ULP +/*=========================================================================== +FUNCTION loc_inject_raw_command + +DESCRIPTION + This is used to send special test modem commands from the applications + down into the HAL +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +static bool loc_inject_raw_command(char* command, int length) +{ + ENTRY_LOG(); + int ret_val = loc_eng_inject_raw_command(loc_afw_data, command, length); + EXIT_LOG(%s, loc_logger_boolStr[ret_val!=0]); + return ret_val; +} +#endif + + +static void loc_cb(GpsLocation* location, void* locExt) +{ + ENTRY_LOG(); + if (NULL != gps_loc_cb && NULL != location) { +#ifdef QCOM_FEATURE_ULP + CALLBACK_LOG_CALLFLOW("location_cb - from", %d, location->position_source); +#else + CALLBACK_LOG_CALLFLOW("location_cb - at", %llu, location->timestamp); +#endif + gps_loc_cb(location); + } + EXIT_LOG(%s, VOID_RET); +} + +static void sv_cb(GpsSvStatus* sv_status, void* svExt) +{ + ENTRY_LOG(); + if (NULL != gps_sv_cb) { + CALLBACK_LOG_CALLFLOW("sv_status_cb -", %d, sv_status->num_svs); + gps_sv_cb(sv_status); + } + EXIT_LOG(%s, VOID_RET); +} diff --git a/loc_api/libloc_api_50001/loc.h b/loc_api/libloc_api_50001/loc.h new file mode 100755 index 00000000..bf942373 --- /dev/null +++ b/loc_api/libloc_api_50001/loc.h @@ -0,0 +1,86 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __LOC_H__ +#define __LOC_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include +#include +#include + +typedef enum loc_server_type { + LOC_AGPS_CDMA_PDE_SERVER, + LOC_AGPS_CUSTOM_PDE_SERVER, + LOC_AGPS_MPC_SERVER, + LOC_AGPS_SUPL_SERVER +} LocServerType; + +typedef enum loc_position_mode_type { + LOC_POSITION_MODE_STANDALONE, + LOC_POSITION_MODE_MS_BASED, + LOC_POSITION_MODE_MS_ASSISTED, + LOC_POSITION_MODE_RESERVED_1, + LOC_POSITION_MODE_RESERVED_2, + LOC_POSITION_MODE_RESERVED_3, + LOC_POSITION_MODE_RESERVED_4 +} LocPositionMode; + +typedef void (*loc_location_cb_ext) (GpsLocation* location, void* locExt); +typedef void (*loc_sv_status_cb_ext) (GpsSvStatus* sv_status, void* svExt); +typedef void* (*loc_ext_parser)(void* data); + +typedef struct { + loc_location_cb_ext location_cb; + gps_status_callback status_cb; + loc_sv_status_cb_ext sv_status_cb; + gps_nmea_callback nmea_cb; + gps_set_capabilities set_capabilities_cb; + gps_acquire_wakelock acquire_wakelock_cb; + gps_release_wakelock release_wakelock_cb; + gps_create_thread create_thread_cb; + loc_ext_parser location_ext_parser; + loc_ext_parser sv_ext_parser; +} LocCallbacks; + +enum loc_sess_status { + LOC_SESS_SUCCESS, + LOC_SESS_INTERMEDIATE, + LOC_SESS_FAILURE +}; + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif //__LOC_H__ diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp new file mode 100755 index 00000000..4d032dce --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -0,0 +1,1838 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng" + +#include +#include +#include +#include +#include +#include +#include +#include +#include /* struct sockaddr_in */ +#include +#include +#include +#include +#include + +#include "LocApiAdapter.h" + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "ulp.h" + +#include "log_util.h" +#include "loc_eng_log.h" + +#define SUCCESS TRUE +#define FAILURE FALSE + + +static void loc_eng_deferred_action_thread(void* context); +static void* loc_eng_create_msg_q(); +static void loc_eng_free_msg(void* msg); + +struct LocEngContext { + // Data variables used by deferred action thread + const void* deferred_q; + const pthread_t deferred_action_thread; + static LocEngContext* get(gps_create_thread threadCreator); + void drop(); + static pthread_mutex_t lock; + static pthread_cond_t cond; +private: + int counter; + static LocEngContext *me; + LocEngContext(gps_create_thread threadCreator); +}; + +pthread_mutex_t LocEngContext::lock = PTHREAD_MUTEX_INITIALIZER; +pthread_cond_t LocEngContext::cond = PTHREAD_COND_INITIALIZER; +LocEngContext* LocEngContext::me = NULL; + +LocEngContext::LocEngContext(gps_create_thread threadCreator) : + deferred_q((const void*)loc_eng_create_msg_q()), + deferred_action_thread(threadCreator("loc_eng",loc_eng_deferred_action_thread, this)), + counter(0) +{ + LOC_LOGV("LocEngContext %d : %d pthread_id %ld\n", + getpid(), gettid(), + deferred_action_thread); +} + +LocEngContext* LocEngContext::get(gps_create_thread threadCreator) +{ + pthread_mutex_lock(&lock); + // gonna need mutex protection here... + if (NULL == me) { + // gps.conf is not part of the context class. But we only want to parse the conf + // file once. This is the only good place to ensure that. + // In fact one day the conf file should go into context as well. + loc_read_gps_conf(); + + me = new LocEngContext(threadCreator); + } + me->counter++; + + pthread_mutex_unlock(&lock); + return me; +} + +void LocEngContext::drop() +{ + if (deferred_action_thread != pthread_self()) { + pthread_mutex_lock(&lock); + counter--; + if (counter == 0) { + loc_eng_msg *msg(new loc_eng_msg(this, LOC_ENG_MSG_QUIT)); + msg_q_snd((void*)deferred_q, msg, loc_eng_free_msg); + + // I am not sure if this is going to be hazardous. The calling thread + // might be blocked for a while, if the q is loaded. I am wondering + // if we should just dump all the msgs in the q upon QUIT. + pthread_cond_wait(&cond, &lock); + + msg_q_destroy((void**)&deferred_q); + delete me; + me = NULL; + } + pthread_mutex_unlock(&lock); + } else { + LOC_LOGE("The HAL thread cannot free itself"); + } +} + +// 2nd half of init(), singled out for +// modem restart to use. +static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data); +static void loc_eng_agps_reinit(loc_eng_data_s_type &loc_eng_data); + +static int loc_eng_set_server(loc_eng_data_s_type &loc_eng_data, + LocServerType type, const char *hostname, int port); +// Internal functions +static void loc_inform_gps_status(loc_eng_data_s_type &loc_eng_data, + GpsStatusValue status); +static void loc_eng_report_status(loc_eng_data_s_type &loc_eng_data, + GpsStatusValue status); +static void loc_eng_process_conn_request(loc_eng_data_s_type &loc_eng_data, + int connHandle, AGpsType agps_type); +static void loc_eng_agps_close_status(loc_eng_data_s_type &loc_eng_data, int is_succ); +static void loc_eng_handle_engine_down(loc_eng_data_s_type &loc_eng_data) ; +static void loc_eng_handle_engine_up(loc_eng_data_s_type &loc_eng_data) ; + +static char extra_data[100]; + +#ifdef QCOM_FEATURE_ULP +// ULP integration +static const ulpInterface* locEngUlpInf = NULL; +static int loc_eng_ulp_init(void* handle) ; +#endif + +/********************************************************************* + * Initialization checking macros + *********************************************************************/ +#define STATE_CHECK(ctx, x, ret) \ + if (!(ctx)) \ + { \ + /* Not intialized, abort */\ + LOC_LOGE("%s: log_eng state error: %s", __func__, x); \ + EXIT_LOG(%s, x); \ + ret; \ + } +#define INIT_CHECK(ctx, ret) STATE_CHECK(ctx, "instance not initialized", ret) + +void loc_eng_msg_sender(void* loc_eng_data_p, void* msg) +{ + LocEngContext* loc_eng_context = (LocEngContext*)((loc_eng_data_s_type*)loc_eng_data_p)->context; + msg_q_snd((void*)loc_eng_context->deferred_q, msg, loc_eng_free_msg); +} + +static void* loc_eng_create_msg_q() +{ + void* q = NULL; + if (eMSG_Q_SUCCESS != msg_q_init(&q)) { + LOC_LOGE("loc_eng_create_msg_q Q init failed."); + q = NULL; + } + return q; +} + +static void loc_eng_free_msg(void* msg) +{ + delete (loc_eng_msg*)msg; +} + +/*=========================================================================== +FUNCTION loc_eng_init + +DESCRIPTION + Initialize the location engine, this include setting up global datas + and registers location engien with loc api service. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, + LOC_API_ADAPTER_EVENT_MASK_T event) +{ + ENTRY_LOG_CALLFLOW(); + + if (NULL == callbacks || 0 == event) { + LOC_LOGE("loc_eng_init: bad parameters cb %p eMask %d", callbacks, event); + EXIT_LOG(%d, 0); + return 0; + } + + STATE_CHECK((NULL == loc_eng_data.context), + "instance already initialized", return 0); + + memset(&loc_eng_data, 0, sizeof (loc_eng_data)); + + // Create context (msg q + thread) (if not yet created) + // This will also parse gps.conf, if not done. + loc_eng_data.context = (void*)LocEngContext::get(callbacks->create_thread_cb); + if (NULL != callbacks->set_capabilities_cb) { + callbacks->set_capabilities_cb(gps_conf.CAPABILITIES); + } + + // Save callbacks + loc_eng_data.location_cb = callbacks->location_cb; + loc_eng_data.sv_status_cb = callbacks->sv_status_cb; + loc_eng_data.status_cb = callbacks->status_cb; + loc_eng_data.nmea_cb = callbacks->nmea_cb; + loc_eng_data.acquire_wakelock_cb = callbacks->acquire_wakelock_cb; + loc_eng_data.release_wakelock_cb = callbacks->release_wakelock_cb; + + loc_eng_data.intermediateFix = gps_conf.INTERMEDIATE_POS; + + // initial states taken care of by the memset above + // loc_eng_data.engine_status -- GPS_STATUS_NONE; + // loc_eng_data.fix_session_status -- GPS_STATUS_NONE; + // loc_eng_data.mute_session_state -- LOC_MUTE_SESS_NONE; + +#ifdef QCOM_FEATURE_ULP + loc_eng_ulp_init(&loc_eng_data); +#endif + + LocEng locEngHandle(&loc_eng_data, event, loc_eng_data.acquire_wakelock_cb, + loc_eng_data.release_wakelock_cb, loc_eng_msg_sender, + callbacks->location_ext_parser, callbacks->sv_ext_parser); + loc_eng_data.client_handle = getLocApiAdapter(locEngHandle); + + int ret_val =-1; + if (NULL == loc_eng_data.client_handle) { + // drop the context and declare failure + ((LocEngContext*)(loc_eng_data.context))->drop(); + loc_eng_data.context = NULL; + } else { + LOC_LOGD("loc_eng_init created client, id = %p\n", loc_eng_data.client_handle); + + // call reinit to send initialization messages + int tries = 30; + while (tries > 0 && + LOC_API_ADAPTER_ERR_SUCCESS != (ret_val = loc_eng_reinit(loc_eng_data))) { + tries--; + LOC_LOGD("loc_eng_init client open failed, %d more tries", tries); + sleep(1); + } + } + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + int ret_val = loc_eng_data.client_handle->reinit(); + + if (LOC_API_ADAPTER_ERR_SUCCESS == ret_val) { + LOC_LOGD("loc_eng_reinit reinit() successful"); + + loc_eng_msg_suple_version *supl_msg(new loc_eng_msg_suple_version(&loc_eng_data, + gps_conf.SUPL_VER)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + supl_msg, loc_eng_free_msg); + + loc_eng_msg_sensor_control_config *sensor_control_config_msg( + new loc_eng_msg_sensor_control_config(&loc_eng_data, gps_conf.SENSOR_USAGE)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + sensor_control_config_msg, loc_eng_free_msg); + + /* Make sure this is specified by the user in the gps.conf file */ + if(gps_conf.GYRO_BIAS_RANDOM_WALK_VALID) + { + loc_eng_msg_sensor_properties *sensor_properties_msg( + new loc_eng_msg_sensor_properties(&loc_eng_data, gps_conf.GYRO_BIAS_RANDOM_WALK)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + sensor_properties_msg, loc_eng_free_msg); + } + + loc_eng_msg_sensor_perf_control_config *sensor_perf_control_conf_msg( + new loc_eng_msg_sensor_perf_control_config(&loc_eng_data, + gps_conf.SENSOR_CONTROL_MODE, + gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, + gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, + gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + sensor_perf_control_conf_msg, loc_eng_free_msg); + } + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_cleanup + +DESCRIPTION + Cleans location engine. The location client handle will be released. + +DEPENDENCIES + None + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return); + + // XTRA has no state, so we are fine with it. + + // we need to check and clear NI + + // we need to check and clear ATL + if (NULL != loc_eng_data.agnss_nif) { + delete loc_eng_data.agnss_nif; + loc_eng_data.agnss_nif = NULL; + } + if (NULL != loc_eng_data.internet_nif) { + delete loc_eng_data.internet_nif; + loc_eng_data.internet_nif = NULL; + } + + if (loc_eng_data.navigating) + { + LOC_LOGD("loc_eng_cleanup: fix not stopped. stop it now."); + loc_eng_stop(loc_eng_data); + } + +#if 0 // can't afford to actually clean up, for many reason. + + ((LocEngContext*)(loc_eng_data.context))->drop(); + loc_eng_data.context = NULL; + + // De-initialize ulp + if (locEngUlpInf != NULL) + { + locEngUlpInf->destroy (); + locEngUlpInf = NULL; + } + + if (loc_eng_data.client_handle != NULL) + { + LOC_LOGD("loc_eng_init: client opened. close it now."); + delete loc_eng_data.client_handle; + loc_eng_data.client_handle = NULL; + } + +#ifdef FEATURE_GNSS_BIT_API + { + char baseband[PROPERTY_VALUE_MAX]; + property_get("ro.baseband", baseband, "msm"); + if ((strcmp(baseband,"svlte2a") == 0)) + { + loc_eng_dmn_conn_loc_api_server_unblock(); + loc_eng_dmn_conn_loc_api_server_join(); + } + } +#endif /* FEATURE_GNSS_BIT_API */ + +#endif + + EXIT_LOG(%s, VOID_RET); +} + + +/*=========================================================================== +FUNCTION loc_eng_start + +DESCRIPTION + Starts the tracking session + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_start(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_START_FIX)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} + +static int loc_eng_start_handler(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + int ret_val = LOC_API_ADAPTER_ERR_SUCCESS; + + if (!loc_eng_data.navigating) { +#ifdef QCOM_FEATURE_ULP + if (NULL == locEngUlpInf || + locEngUlpInf->start_fix () == 1) { + ret_val = loc_eng_data.client_handle->startFix(); + } +#else + ret_val = loc_eng_data.client_handle->startFix(); +#endif + + if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS || + ret_val == LOC_API_ADAPTER_ERR_ENGINE_DOWN) + { + loc_eng_data.navigating = TRUE; + } + } + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_stop + +DESCRIPTION + Stops the tracking session + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_stop(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_STOP_FIX)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} + +static int loc_eng_stop_handler(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + int ret_val = LOC_API_ADAPTER_ERR_SUCCESS; + + if (loc_eng_data.navigating) { +#ifdef QCOM_FEATURE_ULP + // Stops the ULP + if (locEngUlpInf != NULL) + { + locEngUlpInf->stop_fix (); + } +#endif + + ret_val = loc_eng_data.client_handle->stopFix(); + if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS && + loc_eng_data.fix_session_status != GPS_STATUS_SESSION_BEGIN) + { + loc_inform_gps_status(loc_eng_data, GPS_STATUS_SESSION_END); + } + + loc_eng_data.navigating = FALSE; + } + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_mute_one_session + +DESCRIPTION + Mutes one session + +DEPENDENCIES + None + +RETURN VALUE + 0: Success + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_mute_one_session(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + loc_eng_data.mute_session_state = LOC_MUTE_SESS_WAIT; + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_set_position_mode + +DESCRIPTION + Sets the mode and fix frequency for the tracking session. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_set_position_mode(loc_eng_data_s_type &loc_eng_data, + LocPositionMode mode, + GpsPositionRecurrence recurrence, + uint32_t min_interval, + uint32_t preferred_accuracy, + uint32_t preferred_time) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + loc_eng_msg_position_mode *msg( + new loc_eng_msg_position_mode(&loc_eng_data, mode, + recurrence, min_interval, + preferred_accuracy, preferred_time)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} + +/*=========================================================================== +FUNCTION loc_eng_inject_time + +DESCRIPTION + This is used by Java native function to do time injection. + +DEPENDENCIES + None + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_inject_time(loc_eng_data_s_type &loc_eng_data, GpsUtcTime time, + int64_t timeReference, int uncertainty) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + loc_eng_msg_set_time *msg( + new loc_eng_msg_set_time(&loc_eng_data, + time, + timeReference, + uncertainty)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} + + +/*=========================================================================== +FUNCTION loc_eng_inject_location + +DESCRIPTION + This is used by Java native function to do location injection. + +DEPENDENCIES + None + +RETURN VALUE + 0 : Successful + error code : Failure + +SIDE EFFECTS + N/A +===========================================================================*/ +int loc_eng_inject_location(loc_eng_data_s_type &loc_eng_data, double latitude, + double longitude, float accuracy) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + loc_eng_msg_inject_location *msg( + new loc_eng_msg_inject_location(&loc_eng_data, + latitude, + longitude, + accuracy)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} + + +/*=========================================================================== +FUNCTION loc_eng_delete_aiding_data + +DESCRIPTION + This is used by Java native function to delete the aiding data. The function + updates the global variable for the aiding data to be deleted. If the GPS + engine is off, the aiding data will be deleted. Otherwise, the actual action + will happen when gps engine is turned off. + +DEPENDENCIES + Assumes the aiding data type specified in GpsAidingData matches with + LOC API specification. + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_delete_aiding_data(loc_eng_data_s_type &loc_eng_data, GpsAidingData f) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return); + + loc_eng_msg_delete_aiding_data *msg( + new loc_eng_msg_delete_aiding_data(&loc_eng_data, + f)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_inform_gps_state + +DESCRIPTION + Informs the GPS Provider about the GPS status + +DEPENDENCIES + None + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_inform_gps_status(loc_eng_data_s_type &loc_eng_data, GpsStatusValue status) +{ + ENTRY_LOG(); + + static GpsStatusValue last_status = GPS_STATUS_NONE; + + GpsStatus gs = { sizeof(gs),status }; + + + if (loc_eng_data.status_cb) + { + CALLBACK_LOG_CALLFLOW("status_cb", %s, loc_get_gps_status_name(gs.status)); + loc_eng_data.status_cb(&gs); + + // Restore session begin if needed + if (status == GPS_STATUS_ENGINE_ON && last_status == GPS_STATUS_SESSION_BEGIN) + { + GpsStatus gs_sess_begin = { sizeof(gs_sess_begin),GPS_STATUS_SESSION_BEGIN }; + CALLBACK_LOG_CALLFLOW("status_cb", %s, loc_get_gps_status_name(gs_sess_begin.status)); + loc_eng_data.status_cb(&gs_sess_begin); + } + } + + last_status = status; + + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_agps_reinit + +DESCRIPTION + 2nd half of loc_eng_agps_init(), singled out for modem restart to use. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_eng_agps_reinit(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + + // Set server addresses which came before init + if (loc_eng_data.supl_host_set) + { + loc_eng_set_server(loc_eng_data, LOC_AGPS_SUPL_SERVER, + loc_eng_data.supl_host_buf, + loc_eng_data.supl_port_buf); + } + + if (loc_eng_data.c2k_host_set) + { + loc_eng_set_server(loc_eng_data, LOC_AGPS_CDMA_PDE_SERVER, + loc_eng_data.c2k_host_buf, + loc_eng_data.c2k_port_buf); + } + EXIT_LOG(%p, VOID_RET); +} +/*=========================================================================== +FUNCTION loc_eng_agps_init + +DESCRIPTION + Initialize the AGps interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbacks) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return); + STATE_CHECK((NULL == loc_eng_data.agps_status_cb), + "agps instance already initialized", + return); + loc_eng_data.agps_status_cb = callbacks->status_cb; + + loc_eng_data.agnss_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, + AGPS_TYPE_SUPL); +#ifdef QCOM_FEATURE_IPV6 + loc_eng_data.internet_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, + AGPS_TYPE_WWAN_ANY); +#else + loc_eng_data.internet_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, + AGPS_TYPE_SUPL); +#endif + +#ifdef FEATURE_GNSS_BIT_API + { + char baseband[PROPERTY_VALUE_MAX]; + property_get("ro.baseband", baseband, "msm"); + if ((strcmp(baseband,"svlte2a") == 0)) + { + loc_eng_dmn_conn_loc_api_server_launch(callbacks->create_thread_cb, + NULL, NULL, &loc_eng_data); + } + } +#endif /* FEATURE_GNSS_BIT_API */ + + loc_eng_agps_reinit(loc_eng_data); + EXIT_LOG(%p, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_agps_open + +DESCRIPTION + This function is called when on-demand data connection opening is successful. +It should inform engine about the data open result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType, + const char* apn, AGpsBearerType bearerType) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + if (apn == NULL) + { + LOC_LOGE("APN Name NULL\n"); + return 0; + } + + LOC_LOGD("loc_eng_agps_open APN name = [%s]", apn); + + int apn_len = smaller_of(strlen (apn), MAX_APN_LEN); + loc_eng_msg_atl_open_success *msg( + new loc_eng_msg_atl_open_success(&loc_eng_data, agpsType, apn, + apn_len, bearerType)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#else +int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, + const char* apn) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + if (apn == NULL) + { + LOC_LOGE("APN Name NULL\n"); + return 0; + } + + LOC_LOGD("loc_eng_agps_open APN name = [%s]", apn); + + int apn_len = smaller_of(strlen (apn), MAX_APN_LEN); + loc_eng_msg_atl_open_success *msg( + new loc_eng_msg_atl_open_success(&loc_eng_data, apn, + apn_len)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#endif + +/*=========================================================================== +FUNCTION loc_eng_agps_closed + +DESCRIPTION + This function is called when on-demand data connection closing is done. +It should inform engine about the data close result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + loc_eng_msg_atl_closed *msg(new loc_eng_msg_atl_closed(&loc_eng_data, agpsType)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#else +int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + loc_eng_msg_atl_closed *msg(new loc_eng_msg_atl_closed(&loc_eng_data)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#endif + +/*=========================================================================== +FUNCTION loc_eng_agps_open_failed + +DESCRIPTION + This function is called when on-demand data connection opening has failed. +It should inform engine about the data open result. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +#ifdef QCOM_FEATURE_IPV6 +int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + loc_eng_msg_atl_open_failed *msg(new loc_eng_msg_atl_open_failed(&loc_eng_data, agpsType)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#else +int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, + return -1); + + loc_eng_msg_atl_open_failed *msg(new loc_eng_msg_atl_open_failed(&loc_eng_data)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + + EXIT_LOG(%d, 0); + return 0; +} +#endif + +/*=========================================================================== + +FUNCTION resolve_in_addr + +DESCRIPTION + Translates a hostname to in_addr struct + +DEPENDENCIES + n/a + +RETURN VALUE + TRUE if successful + +SIDE EFFECTS + n/a + +===========================================================================*/ +static boolean resolve_in_addr(const char *host_addr, struct in_addr *in_addr_ptr) +{ + ENTRY_LOG(); + boolean ret_val = TRUE; + + struct hostent *hp; + hp = gethostbyname(host_addr); + if (hp != NULL) /* DNS OK */ + { + memcpy(in_addr_ptr, hp->h_addr_list[0], hp->h_length); + } + else + { + /* Try IP representation */ + if (inet_aton(host_addr, in_addr_ptr) == 0) + { + /* IP not valid */ + LOC_LOGE("DNS query on '%s' failed\n", host_addr); + ret_val = FALSE; + } + } + + EXIT_LOG(%s, loc_logger_boolStr[ret_val!=0]); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_set_server + +DESCRIPTION + This is used to set the default AGPS server. Server address is obtained + from gps.conf. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_eng_set_server(loc_eng_data_s_type &loc_eng_data, + LocServerType type, const char* hostname, int port) +{ + ENTRY_LOG(); + int ret = 0; + + if (LOC_AGPS_SUPL_SERVER == type) { + char url[MAX_URL_LEN]; + unsigned int len = snprintf(url, sizeof(url), "%s:%u", hostname, (unsigned) port); + + if (sizeof(url) > len) { + loc_eng_msg_set_server_url *msg(new loc_eng_msg_set_server_url(&loc_eng_data, + url, len)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + } + } else if (LOC_AGPS_CDMA_PDE_SERVER == type || + LOC_AGPS_CUSTOM_PDE_SERVER == type || + LOC_AGPS_MPC_SERVER == type) { + struct in_addr addr; + if (!resolve_in_addr(hostname, &addr)) + { + LOC_LOGE("loc_eng_set_server, hostname %s cannot be resolved.\n", hostname); + ret = -2; + } else { + unsigned int ip = htonl(addr.s_addr); + loc_eng_msg_set_server_ipv4 *msg(new loc_eng_msg_set_server_ipv4(&loc_eng_data, + ip, + port, + type)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + } + } else { + LOC_LOGE("loc_eng_set_server, type %d cannot be resolved.\n", type); + } + + EXIT_LOG(%d, ret); + return ret; +} + +/*=========================================================================== +FUNCTION loc_eng_set_server_proxy + +DESCRIPTION + If loc_eng_set_server is called before loc_eng_init, it doesn't work. This + proxy buffers server settings and calls loc_eng_set_server when the client is + open. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_set_server_proxy(loc_eng_data_s_type &loc_eng_data, + LocServerType type, + const char* hostname, int port) +{ + ENTRY_LOG_CALLFLOW(); + int ret_val = 0; + + if (NULL != loc_eng_data.context) + { + ret_val = loc_eng_set_server(loc_eng_data, type, hostname, port); + } else { + LOC_LOGW("set_server called before init. save the address, type: %d, hostname: %s, port: %d", + (int) type, hostname, port); + switch (type) + { + case LOC_AGPS_SUPL_SERVER: + strlcpy(loc_eng_data.supl_host_buf, hostname, + sizeof(loc_eng_data.supl_host_buf)); + loc_eng_data.supl_port_buf = port; + loc_eng_data.supl_host_set = 1; + break; + case LOC_AGPS_CDMA_PDE_SERVER: + strlcpy(loc_eng_data.c2k_host_buf, hostname, + sizeof(loc_eng_data.c2k_host_buf)); + loc_eng_data.c2k_port_buf = port; + loc_eng_data.c2k_host_set = 1; + break; + default: + LOC_LOGE("loc_eng_set_server_proxy, unknown server type = %d", (int) type); + } + } + + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_agps_ril_update_network_availability + +DESCRIPTION + Sets data call allow vs disallow flag to modem + This is the only member of sLocEngAGpsRilInterface implemented. + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_agps_ril_update_network_availability(loc_eng_data_s_type &loc_eng_data, + int available, const char* apn) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return); + if (apn != NULL) + { + LOC_LOGD("loc_eng_agps_ril_update_network_availability: APN Name = [%s]\n", apn); + int apn_len = smaller_of(strlen (apn), MAX_APN_LEN); + loc_eng_msg_set_data_enable *msg(new loc_eng_msg_set_data_enable(&loc_eng_data, apn, + apn_len, available)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + } + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_report_status + +DESCRIPTION + Reports GPS engine state to Java layer. + +DEPENDENCIES + N/A + +RETURN VALUE + N/A + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_eng_report_status (loc_eng_data_s_type &loc_eng_data, GpsStatusValue status) +{ + ENTRY_LOG(); + // Switch from WAIT to MUTE, for "engine on" or "session begin" event + if (status == GPS_STATUS_SESSION_BEGIN || status == GPS_STATUS_ENGINE_ON) + { + if (loc_eng_data.mute_session_state == LOC_MUTE_SESS_WAIT) + { + LOC_LOGD("loc_eng_report_status: mute_session_state changed from WAIT to IN SESSION"); + loc_eng_data.mute_session_state = LOC_MUTE_SESS_IN_SESSION; + } + } + + // Switch off MUTE session + if (loc_eng_data.mute_session_state == LOC_MUTE_SESS_IN_SESSION && + (status == GPS_STATUS_SESSION_END || status == GPS_STATUS_ENGINE_OFF)) + { + LOC_LOGD("loc_eng_report_status: mute_session_state changed from IN SESSION to NONE"); + loc_eng_data.mute_session_state = LOC_MUTE_SESS_NONE; + } + + // Session End is not reported during Android navigating state + if (status != GPS_STATUS_NONE && + !(status == GPS_STATUS_SESSION_END && loc_eng_data.navigating) && + !(status == GPS_STATUS_SESSION_BEGIN && !loc_eng_data.navigating)) + { + if (loc_eng_data.mute_session_state != LOC_MUTE_SESS_IN_SESSION) + { + // Inform GpsLocationProvider about mNavigating status + loc_inform_gps_status(loc_eng_data, status); + } + else { + LOC_LOGD("loc_eng_report_status: muting the status report."); + } + } + + // Only keeps ENGINE ON/OFF in engine_status + if (status == GPS_STATUS_ENGINE_ON || status == GPS_STATUS_ENGINE_OFF) + { + loc_eng_data.engine_status = status; + } + + // Only keeps SESSION BEGIN/END in fix_session_status + if (status == GPS_STATUS_SESSION_BEGIN || status == GPS_STATUS_SESSION_END) + { + loc_eng_data.fix_session_status = status; + } + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_handle_engine_down + loc_eng_handle_engine_up + +DESCRIPTION + Calls this function when it is detected that modem restart is happening. + Either we detected the modem is down or received modem up event. + This must be called from the deferred thread to avoid race condition. + +DEPENDENCIES + None + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_handle_engine_down(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + loc_eng_ni_reset_on_engine_restart(loc_eng_data); + loc_eng_report_status(loc_eng_data, GPS_STATUS_ENGINE_OFF); + EXIT_LOG(%s, VOID_RET); +} + +void loc_eng_handle_engine_up(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + loc_eng_reinit(loc_eng_data); + + if (loc_eng_data.agps_status_cb != NULL) { + loc_eng_data.agnss_nif->dropAllSubscribers(); + loc_eng_data.internet_nif->dropAllSubscribers(); + + loc_eng_agps_reinit(loc_eng_data); + } + + loc_eng_report_status(loc_eng_data, GPS_STATUS_ENGINE_ON); + + // modem is back up. If we crashed in the middle of navigating, we restart. + if (loc_eng_data.navigating) { + loc_eng_data.client_handle->setPositionMode( + loc_eng_data.position_mode.pMode, + loc_eng_data.position_mode.pRecurrence, + loc_eng_data.position_mode.minInterval, + loc_eng_data.position_mode.preferredAccuracy, + loc_eng_data.position_mode.preferredTime); + // not mutex protected, assuming fw won't call start twice without a + // stop call in between. + loc_eng_start_handler(loc_eng_data); + } + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_deferred_action_thread + +DESCRIPTION + Main routine for the thread to execute loc_eng commands. + +DEPENDENCIES + None + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_eng_deferred_action_thread(void* arg) +{ + ENTRY_LOG(); + loc_eng_msg *msg; + static int cnt = 0; + LocEngContext* context = (LocEngContext*)arg; + + // make sure we do not run in background scheduling group + set_sched_policy(gettid(), SP_FOREGROUND); + + while (1) + { + LOC_LOGD("%s:%d] %d listening ...\n", __func__, __LINE__, cnt++); + + // we are only sending / receiving msg pointers + msq_q_err_type result = msg_q_rcv((void*)context->deferred_q, (void **) &msg); + if (eMSG_Q_SUCCESS != result) { + LOC_LOGE("%s:%d] fail receiving msg: %s\n", __func__, __LINE__, + loc_get_msg_q_status(result)); + return; + } + + loc_eng_data_s_type* loc_eng_data_p = (loc_eng_data_s_type*)msg->owner; + + LOC_LOGD("%s:%d] received msg_id = %s context = %p\n", + __func__, __LINE__, loc_get_msg_name(msg->msgid), loc_eng_data_p->context); + + // need to ensure the instance data is valid + STATE_CHECK(NULL != loc_eng_data_p->context, + "instance cleanup happened", + delete msg; return); + + switch(msg->msgid) { + case LOC_ENG_MSG_QUIT: + { + LocEngContext* context = (LocEngContext*)loc_eng_data_p->context; + pthread_mutex_lock(&(context->lock)); + pthread_cond_signal(&(context->cond)); + pthread_mutex_unlock(&(context->lock)); + EXIT_LOG(%s, "LOC_ENG_MSG_QUIT, signal the main thread and return"); + } + return; + + case LOC_ENG_MSG_REQUEST_NI: + { + loc_eng_msg_request_ni *niMsg = (loc_eng_msg_request_ni*)msg; + loc_eng_ni_request_handler(*loc_eng_data_p, &niMsg->notify, niMsg->passThroughData); + } + break; + + case LOC_ENG_MSG_INFORM_NI_RESPONSE: + { + loc_eng_msg_inform_ni_response *nrMsg = (loc_eng_msg_inform_ni_response*)msg; + loc_eng_data_p->client_handle->informNiResponse(nrMsg->response, + nrMsg->passThroughData); + } + break; + + case LOC_ENG_MSG_START_FIX: + loc_eng_start_handler(*loc_eng_data_p); + break; + + case LOC_ENG_MSG_STOP_FIX: + if (loc_eng_data_p->agps_request_pending) + { + loc_eng_data_p->stop_request_pending = true; + LOC_LOGD("loc_eng_stop - deferring stop until AGPS data call is finished\n"); + } else { + loc_eng_stop_handler(*loc_eng_data_p); + } + break; + + case LOC_ENG_MSG_SET_POSITION_MODE: + { + loc_eng_msg_position_mode *pmMsg = (loc_eng_msg_position_mode*)msg; + loc_eng_data_p->client_handle->setPositionMode(pmMsg->pMode, pmMsg->pRecurrence, + pmMsg->minInterval,pmMsg->preferredAccuracy, + pmMsg->preferredTime); + memcpy((void*)&loc_eng_data_p->position_mode, (void*)pmMsg, sizeof(*pmMsg)); + } + break; + + case LOC_ENG_MSG_SET_TIME: + { + loc_eng_msg_set_time *tMsg = (loc_eng_msg_set_time*)msg; + loc_eng_data_p->client_handle->setTime(tMsg->time, tMsg->timeReference, + tMsg->uncertainty); + } + break; + + case LOC_ENG_MSG_INJECT_LOCATION: + { + loc_eng_msg_inject_location *ilMsg = (loc_eng_msg_inject_location*) msg; + loc_eng_data_p->client_handle->injectPosition(ilMsg->latitude, ilMsg->longitude, + ilMsg->accuracy); + } + break; + + case LOC_ENG_MSG_SET_SERVER_IPV4: + { + loc_eng_msg_set_server_ipv4 *ssiMsg = (loc_eng_msg_set_server_ipv4*)msg; + loc_eng_data_p->client_handle->setServer(ssiMsg->nl_addr, + ssiMsg->port, + ssiMsg->serverType); + } + break; + + case LOC_ENG_MSG_SET_SERVER_URL: + { + loc_eng_msg_set_server_url *ssuMsg = (loc_eng_msg_set_server_url*)msg; + loc_eng_data_p->client_handle->setServer(ssuMsg->url, ssuMsg->len); + } + break; + + case LOC_ENG_MSG_SUPL_VERSION: + { + loc_eng_msg_suple_version *svMsg = (loc_eng_msg_suple_version*)msg; + loc_eng_data_p->client_handle->setSUPLVersion(svMsg->supl_version); + } + break; + + case LOC_ENG_MSG_SET_SENSOR_CONTROL_CONFIG: + { + loc_eng_msg_sensor_control_config *sccMsg = (loc_eng_msg_sensor_control_config*)msg; + loc_eng_data_p->client_handle->setSensorControlConfig(sccMsg->sensorsDisabled); + } + break; + + case LOC_ENG_MSG_SET_SENSOR_PROPERTIES: + { + loc_eng_msg_sensor_properties *spMsg = (loc_eng_msg_sensor_properties*)msg; + loc_eng_data_p->client_handle->setSensorProperties(spMsg->gyroBiasVarianceRandomWalk); + } + break; + + case LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG: + { + loc_eng_msg_sensor_perf_control_config *spccMsg = (loc_eng_msg_sensor_perf_control_config*)msg; + loc_eng_data_p->client_handle->setSensorPerfControlConfig(spccMsg->controlMode, spccMsg->accelSamplesPerBatch, spccMsg->accelBatchesPerSec, + spccMsg->gyroSamplesPerBatch, spccMsg->gyroBatchesPerSec); + } + break; + + case LOC_ENG_MSG_REPORT_POSITION: + if (loc_eng_data_p->mute_session_state != LOC_MUTE_SESS_IN_SESSION) + { + loc_eng_msg_report_position *rpMsg = (loc_eng_msg_report_position*)msg; + if (loc_eng_data_p->location_cb != NULL) { + if (LOC_SESS_FAILURE == rpMsg->status) { + // in case we want to handle the failure case + loc_eng_data_p->location_cb(NULL, NULL); + } + // what's in the else if is... (line by line) + // 1. this is a good fix; or + // 2. (must be intermediate fix... implicit) + // 2.1 we accepte intermediate; and + // 2.2 it is NOT the case that + // 2.2.1 there is inaccuracy; and + // 2.2.2 we care about inaccuracy; and + // 2.2.3 the inaccuracy exceeds our tolerance + else if (LOC_SESS_SUCCESS == rpMsg->status || + (LOC_SESS_INTERMEDIATE == loc_eng_data_p->intermediateFix && + !((rpMsg->location.flags & GPS_LOCATION_HAS_ACCURACY) && + (gps_conf.ACCURACY_THRES != 0) && + (rpMsg->location.accuracy > gps_conf.ACCURACY_THRES)))) { + loc_eng_data_p->location_cb((GpsLocation*)&(rpMsg->location), + (void*)rpMsg->locationExt); + } + } + } + + break; + + case LOC_ENG_MSG_REPORT_SV: + if (loc_eng_data_p->mute_session_state != LOC_MUTE_SESS_IN_SESSION) + { + loc_eng_msg_report_sv *rsMsg = (loc_eng_msg_report_sv*)msg; + if (loc_eng_data_p->sv_status_cb != NULL) { + loc_eng_data_p->sv_status_cb((GpsSvStatus*)&(rsMsg->svStatus), + (void*)rsMsg->svExt); + } + } + break; + + case LOC_ENG_MSG_REPORT_STATUS: + loc_eng_report_status(*loc_eng_data_p, ((loc_eng_msg_report_status*)msg)->status); + break; + + case LOC_ENG_MSG_REPORT_NMEA: + if (NULL != loc_eng_data_p->nmea_cb) { + loc_eng_msg_report_nmea* nmMsg = (loc_eng_msg_report_nmea*)msg; + struct timeval tv; + gettimeofday(&tv, (struct timezone *) NULL); + int64_t now = tv.tv_sec * 1000LL + tv.tv_usec / 1000; + CALLBACK_LOG_CALLFLOW("nmea_cb", %p, nmMsg->nmea); + } + break; + + case LOC_ENG_MSG_REQUEST_BIT: + { + loc_eng_msg_request_bit* brqMsg = (loc_eng_msg_request_bit*)msg; + AgpsStateMachine* stateMachine = (brqMsg->isSupl) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; + BITSubscriber subscriber(stateMachine, brqMsg->ipv4Addr, brqMsg->ipv6Addr); + + stateMachine->subscribeRsrc((Subscriber*)&subscriber); + } + break; + + case LOC_ENG_MSG_RELEASE_BIT: + { + loc_eng_msg_release_bit* brlMsg = (loc_eng_msg_release_bit*)msg; + AgpsStateMachine* stateMachine = (brlMsg->isSupl) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; + BITSubscriber subscriber(stateMachine, brlMsg->ipv4Addr, brlMsg->ipv6Addr); + + stateMachine->unsubscribeRsrc((Subscriber*)&subscriber); + } + break; + + case LOC_ENG_MSG_REQUEST_ATL: + { + loc_eng_msg_request_atl* arqMsg = (loc_eng_msg_request_atl*)msg; + AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == arqMsg->type) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; + ATLSubscriber subscriber(arqMsg->handle, + stateMachine, + loc_eng_data_p->client_handle); + + stateMachine->subscribeRsrc((Subscriber*)&subscriber); + } + break; + + case LOC_ENG_MSG_RELEASE_ATL: + { + loc_eng_msg_release_atl* arlMsg = (loc_eng_msg_release_atl*)msg; + ATLSubscriber s1(arlMsg->handle, + loc_eng_data_p->agnss_nif, + loc_eng_data_p->client_handle); + // attempt to unsubscribe from agnss_nif first + if (! loc_eng_data_p->agnss_nif->unsubscribeRsrc((Subscriber*)&s1)) { + ATLSubscriber s2(arlMsg->handle, + loc_eng_data_p->internet_nif, + loc_eng_data_p->client_handle); + // if unsuccessful, try internet_nif + loc_eng_data_p->internet_nif->unsubscribeRsrc((Subscriber*)&s2); + } + } + break; + + case LOC_ENG_MSG_REQUEST_XTRA_DATA: + if (loc_eng_data_p->xtra_module_data.download_request_cb != NULL) + { + loc_eng_data_p->xtra_module_data.download_request_cb(); + } + break; + + case LOC_ENG_MSG_REQUEST_TIME: + break; + + case LOC_ENG_MSG_REQUEST_POSITION: + break; + + case LOC_ENG_MSG_DELETE_AIDING_DATA: + loc_eng_data_p->aiding_data_for_deletion |= ((loc_eng_msg_delete_aiding_data*)msg)->type; + break; + + case LOC_ENG_MSG_ENABLE_DATA: + { + loc_eng_msg_set_data_enable *unaMsg = (loc_eng_msg_set_data_enable*)msg; + loc_eng_data_p->client_handle->enableData(unaMsg->enable); + loc_eng_data_p->client_handle->setAPN(unaMsg->apn, unaMsg->length); + } + break; + + case LOC_ENG_MSG_INJECT_XTRA_DATA: + { + loc_eng_msg_inject_xtra_data *xdMsg = (loc_eng_msg_inject_xtra_data*)msg; + loc_eng_data_p->client_handle->setXtraData(xdMsg->data, xdMsg->length); + } + break; + + case LOC_ENG_MSG_ATL_OPEN_SUCCESS: + { + loc_eng_msg_atl_open_success *aosMsg = (loc_eng_msg_atl_open_success*)msg; +#ifdef QCOM_FEATURE_IPV6 + AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == aosMsg->agpsType) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; + + stateMachine->setBearer(aosMsg->bearerType); +#else + AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; +#endif + stateMachine->setAPN(aosMsg->apn, aosMsg->length); + stateMachine->onRsrcEvent(RSRC_GRANTED); + } + break; + + case LOC_ENG_MSG_ATL_CLOSED: + { + loc_eng_msg_atl_closed *acsMsg = (loc_eng_msg_atl_closed*)msg; +#ifdef QCOM_FEATURE_IPV6 + AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == acsMsg->agpsType) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; +#else + AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; +#endif + + stateMachine->onRsrcEvent(RSRC_RELEASED); + } + break; + + case LOC_ENG_MSG_ATL_OPEN_FAILED: + { + loc_eng_msg_atl_open_failed *aofMsg = (loc_eng_msg_atl_open_failed*)msg; +#ifdef QCOM_FEATURE_IPV6 + AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == aofMsg->agpsType) ? + loc_eng_data_p->agnss_nif : + loc_eng_data_p->internet_nif; +#else + AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; +#endif + + stateMachine->onRsrcEvent(RSRC_DENIED); + } + break; + + case LOC_ENG_MSG_ENGINE_DOWN: + loc_eng_handle_engine_down(*loc_eng_data_p); + break; + + case LOC_ENG_MSG_ENGINE_UP: + loc_eng_handle_engine_up(*loc_eng_data_p); + break; + + default: + LOC_LOGE("unsupported msgid = %d\n", msg->msgid); + break; + } + + if ( (msg->msgid == LOC_ENG_MSG_ATL_OPEN_FAILED) | + (msg->msgid == LOC_ENG_MSG_ATL_CLOSED) | + (msg->msgid == LOC_ENG_MSG_ATL_OPEN_SUCCESS) ) + { + loc_eng_data_p->agps_request_pending = false; + if (loc_eng_data_p->stop_request_pending) { + loc_eng_stop_handler(*loc_eng_data_p); + loc_eng_data_p->stop_request_pending = false; + } + } + loc_eng_data_p->stop_request_pending = false; + + if (loc_eng_data_p->engine_status != GPS_STATUS_ENGINE_ON && + loc_eng_data_p->aiding_data_for_deletion != 0) + { + loc_eng_data_p->client_handle->deleteAidingData(loc_eng_data_p->aiding_data_for_deletion); + loc_eng_data_p->aiding_data_for_deletion = 0; + } + + delete msg; + } + + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_report_position_ulp + +DESCRIPTION + Report a ULP position + p_ulp_pos_absolute, ULP position in absolute coordinates + +DEPENDENCIES + None + +RETURN VALUE + 0: SUCCESS + others: error + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_eng_report_position_ulp (void* handle, + const GpsLocation* location_report_ptr, + unsigned int ext_data_length, + unsigned char* ext_data) +{ + ENTRY_LOG(); + loc_eng_data_s_type* loc_eng_data_p = (loc_eng_data_s_type*)handle; + + INIT_CHECK(loc_eng_data_p->context && loc_eng_data_p->client_handle, + return -1); + + if (ext_data_length > sizeof (extra_data)) + { + ext_data_length = sizeof (extra_data); + } + + memcpy(extra_data, + ext_data, + ext_data_length); + + loc_eng_data_p->client_handle->reportPosition((GpsLocation&)*location_report_ptr, + NULL, LOC_SESS_SUCCESS); + + EXIT_LOG(%d, 0); + return 0; +} + +#ifdef QCOM_FEATURE_ULP +/*=========================================================================== +FUNCTION loc_eng_ulp_init + +DESCRIPTION + This function dynamically loads the libulp.so and calls + its init function to start up the ulp module + +DEPENDENCIES + None + +RETURN VALUE + 0: no error + -1: errors + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_eng_ulp_init(void* owner) +{ + ENTRY_LOG(); + int ret_val; + void *handle; + const char *error; + get_ulp_interface* get_ulp_inf; + + if (!(gps_conf.CAPABILITIES & ULP_CAPABILITY)) { + LOC_LOGD ("%s, ULP is not supported\n", __func__); + ret_val = -1; + goto exit; + } + + handle = dlopen ("libulp.so", RTLD_NOW); + if (!handle) + { + LOC_LOGE ("%s, dlopen for libulp.so failed\n", __func__); + ret_val = -1; + goto exit; + } + dlerror(); /* Clear any existing error */ + + get_ulp_inf = (get_ulp_interface*) dlsym(handle, "ulp_get_interface"); + if ((error = dlerror()) != NULL) { + LOC_LOGE ("%s, dlsym for ulpInterface failed, error = %s\n", __func__, error); + ret_val = -1; + goto exit; + } + + locEngUlpInf = get_ulp_inf(); + + // Initialize the ULP interface + locEngUlpInf->init (owner, loc_eng_report_position_ulp); + + ret_val = 0; +exit: + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_inject_raw_command + +DESCRIPTION + This is used to send special test modem commands from the applications + down into the HAL +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +bool loc_eng_inject_raw_command(loc_eng_data_s_type &loc_eng_data, + char* command, int length) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + boolean ret_val; + LOC_LOGD("loc_eng_send_extra_command: %s\n", command); + ret_val = TRUE; + + EXIT_LOG(%s, loc_logger_boolStr[ret_val!=0]); + return ret_val; +} +/*=========================================================================== +FUNCTION loc_eng_update_criteria + +DESCRIPTION + This is used to inform the ULP module of new unique criteria that are passed + in by the applications +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_update_criteria(loc_eng_data_s_type &loc_eng_data, + UlpLocationCriteria criteria) +{ + ENTRY_LOG_CALLFLOW(); + INIT_CHECK(loc_eng_data.context, return -1); + int ret_val; + ret_val = 0; + + EXIT_LOG(%d, ret_val); + return ret_val; +} +#endif diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h new file mode 100755 index 00000000..73578ec8 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -0,0 +1,204 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_ENG_H +#define LOC_ENG_H + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +// Uncomment to keep all LOG messages (LOGD, LOGI, LOGV, etc.) +#define MAX_NUM_ATL_CONNECTIONS 2 +// Define boolean type to be used by libgps on loc api module +typedef unsigned char boolean; + +#ifndef TRUE +#define TRUE 1 +#endif + +#ifndef FALSE +#define FALSE 0 +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// The data connection minimal open time +#define DATA_OPEN_MIN_TIME 1 /* sec */ + +// The system sees GPS engine turns off after inactive for this period of time +#define GPS_AUTO_OFF_TIME 2 /* secs */ +#define SUCCESS TRUE +#define FAILURE FALSE +#define INVALID_ATL_CONNECTION_HANDLE -1 + +#define MAX_APN_LEN 100 +#define MAX_URL_LEN 256 +#define smaller_of(a, b) (((a) > (b)) ? (b) : (a)) + +enum loc_mute_session_e_type { + LOC_MUTE_SESS_NONE = 0, + LOC_MUTE_SESS_WAIT, + LOC_MUTE_SESS_IN_SESSION +}; + +// Module data +typedef struct +{ + LocApiAdapter *client_handle; + loc_location_cb_ext location_cb; + gps_status_callback status_cb; + loc_sv_status_cb_ext sv_status_cb; + agps_status_callback agps_status_cb; + gps_nmea_callback nmea_cb; + gps_ni_notify_callback ni_notify_cb; + gps_acquire_wakelock acquire_wakelock_cb; + gps_release_wakelock release_wakelock_cb; + boolean intermediateFix; + AGpsStatusValue agps_status; + // used to defer stopping the GPS engine until AGPS data calls are done + boolean agps_request_pending; + boolean stop_request_pending; + loc_eng_xtra_data_s_type xtra_module_data; + loc_eng_ni_data_s_type loc_eng_ni_data; + + boolean navigating; + + // AGPS state machines + AgpsStateMachine* agnss_nif; + AgpsStateMachine* internet_nif; + + // GPS engine status + GpsStatusValue engine_status; + GpsStatusValue fix_session_status; + + // Aiding data information to be deleted, aiding data can only be deleted when GPS engine is off + GpsAidingData aiding_data_for_deletion; + + void* context; + + loc_eng_msg_position_mode position_mode; + + // For muting session broadcast + loc_mute_session_e_type mute_session_state; + + // Address buffers, for addressing setting before init + int supl_host_set; + char supl_host_buf[101]; + int supl_port_buf; + int c2k_host_set; + char c2k_host_buf[101]; + int c2k_port_buf; + int mpc_host_set; + char mpc_host_buf[101]; + int mpc_port_buf; +} loc_eng_data_s_type; + + +int loc_eng_init(loc_eng_data_s_type &loc_eng_data, + LocCallbacks* callbacks, + LOC_API_ADAPTER_EVENT_MASK_T event); +int loc_eng_start(loc_eng_data_s_type &loc_eng_data); +int loc_eng_stop(loc_eng_data_s_type &loc_eng_data); +void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data); +int loc_eng_inject_time(loc_eng_data_s_type &loc_eng_data, + GpsUtcTime time, int64_t timeReference, + int uncertainty); +int loc_eng_inject_location(loc_eng_data_s_type &loc_eng_data, + double latitude, double longitude, + float accuracy); +void loc_eng_delete_aiding_data(loc_eng_data_s_type &loc_eng_data, + GpsAidingData f); +int loc_eng_set_position_mode(loc_eng_data_s_type &loc_eng_data, + LocPositionMode mode, GpsPositionRecurrence recurrence, + uint32_t min_interval, uint32_t preferred_accuracy, + uint32_t preferred_time); +const void* loc_eng_get_extension(loc_eng_data_s_type &loc_eng_data, + const char* name); +#ifdef QCOM_FEATURE_ULP +int loc_eng_update_criteria(loc_eng_data_s_type &loc_eng_data, + UlpLocationCriteria criteria); +#endif + +void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, + AGpsCallbacks* callbacks); +#ifdef QCOM_FEATURE_IPV6 +int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType, + const char* apn, AGpsBearerType bearerType); +int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType); +int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType); +#else +int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, const char* apn); +int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data); +int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data); +#endif + +int loc_eng_set_server_proxy(loc_eng_data_s_type &loc_eng_data, + LocServerType type, const char *hostname, int port); + + +void loc_eng_agps_ril_update_network_availability(loc_eng_data_s_type &loc_eng_data, + int avaiable, const char* apn); + + +bool loc_eng_inject_raw_command(loc_eng_data_s_type &loc_eng_data, + char* command, int length); + + +void loc_eng_mute_one_session(loc_eng_data_s_type &loc_eng_data); + +int loc_eng_xtra_init (loc_eng_data_s_type &loc_eng_data, + GpsXtraCallbacks* callbacks); + +int loc_eng_xtra_inject_data(loc_eng_data_s_type &loc_eng_data, + char* data, int length); + +extern void loc_eng_ni_init(loc_eng_data_s_type &loc_eng_data, + GpsNiCallbacks *callbacks); +extern void loc_eng_ni_respond(loc_eng_data_s_type &loc_eng_data, + int notif_id, GpsUserResponseType user_response); +extern void loc_eng_ni_request_handler(loc_eng_data_s_type &loc_eng_data, + const GpsNiNotification *notif, + const void* passThrough); +extern void loc_eng_ni_reset_on_engine_restart(loc_eng_data_s_type &loc_eng_data); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif // LOC_ENG_H diff --git a/loc_api/libloc_api_50001/loc_eng_agps.cpp b/loc_api/libloc_api_50001/loc_eng_agps.cpp new file mode 100755 index 00000000..07475680 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_agps.cpp @@ -0,0 +1,702 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng" + +#include +#include +#include +#include +#include + +//====================================================================== +// C callbacks +//====================================================================== + +// This is given to linked_list_add as the dealloc callback +// data -- an instance of Subscriber +static void deleteObj(void* data) +{ + delete (Subscriber*)data; +} + +// This is given to linked_list_search() as the comparison callback +// when the state manchine needs to process for particular subscriber +// fromCaller -- caller provides this obj +// fromList -- linked_list_search() function take this one from list +static bool hasSubscriber(void* fromCaller, void* fromList) +{ + Notification* notification = (Notification*)fromCaller; + Subscriber* s1 = (Subscriber*)fromList; + + return s1->forMe(*notification); +} + +// This is gvien to linked_list_search() to notify subscriber objs +// when the state machine needs to inform all subscribers of resource +// status changes, e.g. when resource is GRANTED. +// fromCaller -- caller provides this ptr to a Notification obj. +// fromList -- linked_list_search() function take this one from list +static bool notifySubscriber(void* fromCaller, void* fromList) +{ + Notification* notification = (Notification*)fromCaller; + Subscriber* s1 = (Subscriber*)fromList; + + // we notify every subscriber indiscriminatively + // each subscriber decides if this notification is interesting. + return s1->notifyRsrcStatus(*notification) && + // if we do not want to delete the subscriber from the + // the list, we must set this to false so this function + // returns false + notification->postNotifyDelete; +} + +//====================================================================== +// Notification +//====================================================================== +const int Notification::BROADCAST_ALL = 0x80000000; +const int Notification::BROADCAST_ACTIVE = 0x80000001; +const int Notification::BROADCAST_INACTIVE = 0x80000002; + + +//====================================================================== +// Subscriber: BITSubscriber / ATLSubscriber +//====================================================================== +bool Subscriber::forMe(Notification ¬ification) +{ + if (NULL != notification.rcver) { + return equals(notification.rcver); + } else { + return Notification::BROADCAST_ALL == notification.groupID || + (Notification::BROADCAST_ACTIVE == notification.groupID && + !isInactive()) || + (Notification::BROADCAST_INACTIVE == notification.groupID && + isInactive()); + } +} +bool BITSubscriber::equals(const Subscriber *s) const +{ + BITSubscriber* bitS = (BITSubscriber*)s; + + return (ID == bitS->ID && + (INADDR_NONE != (unsigned int)ID || + 0 == strncmp(ipv6Addr, bitS->ipv6Addr, sizeof(ipv6Addr)))); +} + +bool BITSubscriber::notifyRsrcStatus(Notification ¬ification) +{ + bool notify = forMe(notification); + + if (notify) { + switch(notification.rsrcStatus) + { + case RSRC_UNSUBSCRIBE: + case RSRC_RELEASED: + loc_eng_dmn_conn_loc_api_server_data_conn( + GPSONE_LOC_API_IF_RELEASE_SUCCESS); + break; + case RSRC_DENIED: + loc_eng_dmn_conn_loc_api_server_data_conn( + GPSONE_LOC_API_IF_FAILURE); + break; + case RSRC_GRANTED: + loc_eng_dmn_conn_loc_api_server_data_conn( + GPSONE_LOC_API_IF_REQUEST_SUCCESS); + break; + default: + notify = false; + } + } + + return notify; +} + +bool ATLSubscriber::notifyRsrcStatus(Notification ¬ification) +{ + bool notify = forMe(notification); + + if (notify) { + switch(notification.rsrcStatus) + { + case RSRC_UNSUBSCRIBE: + case RSRC_RELEASED: + ((LocApiAdapter*)mLocAdapter)->atlCloseStatus(ID, 1); + break; + case RSRC_DENIED: + ((LocApiAdapter*)mLocAdapter)->atlOpenStatus(ID, 0, + (char*)mStateMachine->getAPN(), +#ifdef QCOM_FEATURE_IPV6 + mStateMachine->getBearer(), +#endif + mStateMachine->getType()); + break; + case RSRC_GRANTED: + ((LocApiAdapter*)mLocAdapter)->atlOpenStatus(ID, 1, + (char*)mStateMachine->getAPN(), +#ifdef QCOM_FEATURE_IPV6 + mStateMachine->getBearer(), +#endif + mStateMachine->getType()); + break; + default: + notify = false; + } + } + + return notify; +} + + +//====================================================================== +// AgpsState: AgpsReleasedState / AgpsPendingState / AgpsAcquiredState +//====================================================================== + +// AgpsReleasedState +class AgpsReleasedState : public AgpsState +{ + friend class AgpsStateMachine; + + inline AgpsReleasedState(AgpsStateMachine* stateMachine) : + AgpsState(stateMachine) + { mReleasedState = this; } + + inline ~AgpsReleasedState() {} +public: + virtual AgpsState* onRsrcEvent(AgpsRsrcStatus event, void* data); + inline virtual char* whoami() {return (char*)"AgpsReleasedState";} +}; + +AgpsState* AgpsReleasedState::onRsrcEvent(AgpsRsrcStatus event, void* data) +{ + if (mStateMachine->hasSubscribers()) { + LOC_LOGE("Error: %s subscriber list not empty!!!", whoami()); + // I don't know how to recover from it. I am adding this rather + // for debugging purpose. + } + + AgpsState* nextState = this;; + switch (event) + { + case RSRC_SUBSCRIBE: + { + // no notification until we get RSRC_GRANTED + // but we need to add subscriber to the list + mStateMachine->addSubscriber((Subscriber*)data); + // move the state to PENDING + nextState = mPendingState; + + // request from connecivity service for NIF + mStateMachine->sendRsrcRequest(GPS_REQUEST_AGPS_DATA_CONN); + } + break; + + case RSRC_UNSUBSCRIBE: + { + // the list should really be empty, nothing to remove. + // but we might as well just tell the client it is + // unsubscribed. False tolerance, right? + Subscriber* subscriber = (Subscriber*) data; + Notification notification(subscriber, event, false); + subscriber->notifyRsrcStatus(notification); + } + // break; + case RSRC_GRANTED: + case RSRC_RELEASED: + case RSRC_DENIED: + default: + LOC_LOGW("%s: unrecognized event %d", whoami(), event); + // no state change. + break; + } + + LOC_LOGD("onRsrcEvent, old state %s, new state %s, event %d", + whoami(), nextState->whoami(), event); + return nextState; +} + +// AgpsPendingState +class AgpsPendingState : public AgpsState +{ + friend class AgpsStateMachine; + + inline AgpsPendingState(AgpsStateMachine* stateMachine) : + AgpsState(stateMachine) + { mPendingState = this; } + + inline ~AgpsPendingState() {} +public: + virtual AgpsState* onRsrcEvent(AgpsRsrcStatus event, void* data); + inline virtual char* whoami() {return (char*)"AgpsPendingState";} +}; + +AgpsState* AgpsPendingState::onRsrcEvent(AgpsRsrcStatus event, void* data) +{ + AgpsState* nextState = this;; + switch (event) + { + case RSRC_SUBSCRIBE: + { + // already requested for NIF resource, + // do nothing until we get RSRC_GRANTED indication + // but we need to add subscriber to the list + mStateMachine->addSubscriber((Subscriber*)data); + // no state change. + } + break; + + case RSRC_UNSUBSCRIBE: + { + Subscriber* subscriber = (Subscriber*) data; + if (subscriber->waitForCloseComplete()) { + subscriber->setInactive(); + if (!mStateMachine->hasActiveSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasingState; + } + } else { + // auto notify this subscriber of the unsubscribe + Notification notification(subscriber, event, true); + mStateMachine->notifySubscribers(notification); + + // now check if there is any subscribers left + if (!mStateMachine->hasSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasedState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } + } + } + break; + + case RSRC_GRANTED: + { + nextState = mAcquiredState; + Notification notification(Notification::BROADCAST_ACTIVE, event, false); + // notify all subscribers NIF resource GRANTED + // by setting false, we keep subscribers on the linked list + mStateMachine->notifySubscribers(notification); + } + break; + + case RSRC_RELEASED: + // no state change. + // we are expecting either GRANTED or DENIED. Handling RELEASED + // may like break our state machine in race conditions. + break; + + case RSRC_DENIED: + { + nextState = mReleasedState; + Notification notification(Notification::BROADCAST_ALL, event, true); + // notify all subscribers NIF resource RELEASED or DENIED + // by setting true, we remove subscribers from the linked list + mStateMachine->notifySubscribers(notification); + } + break; + + default: + LOC_LOGE("%s: unrecognized event %d", whoami(), event); + // no state change. + } + + LOC_LOGD("onRsrcEvent, old state %s, new state %s, event %d", + whoami(), nextState->whoami(), event); + return nextState; +} + + +class AgpsAcquiredState : public AgpsState +{ + friend class AgpsStateMachine; + + inline AgpsAcquiredState(AgpsStateMachine* stateMachine) : + AgpsState(stateMachine) + { mAcquiredState = this; } + + inline ~AgpsAcquiredState() {} +public: + virtual AgpsState* onRsrcEvent(AgpsRsrcStatus event, void* data); + inline virtual char* whoami() { return (char*)"AgpsAcquiredState"; } +}; + + +AgpsState* AgpsAcquiredState::onRsrcEvent(AgpsRsrcStatus event, void* data) +{ + AgpsState* nextState = this; + switch (event) + { + case RSRC_SUBSCRIBE: + { + // we already have the NIF resource, simply notify subscriber + Subscriber* subscriber = (Subscriber*) data; + // we have rsrc in hand, so grant it right away + Notification notification(subscriber, RSRC_GRANTED, false); + subscriber->notifyRsrcStatus(notification); + // add subscriber to the list + mStateMachine->addSubscriber(subscriber); + // no state change. + } + break; + + case RSRC_UNSUBSCRIBE: + { + Subscriber* subscriber = (Subscriber*) data; + if (subscriber->waitForCloseComplete()) { + subscriber->setInactive(); + } else { + // auto notify this subscriber of the unsubscribe + Notification notification(subscriber, event, true); + mStateMachine->notifySubscribers(notification); + } + + // now check if there is any subscribers left + if (!mStateMachine->hasSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasingState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } else if (!mStateMachine->hasActiveSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasedState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } + } + break; + + case RSRC_GRANTED: + LOC_LOGW("%s: %d, RSRC_GRANTED already received", whoami(), event); + // no state change. + break; + + case RSRC_RELEASED: + { + LOC_LOGW("%s: %d, a force rsrc release", whoami(), event); + nextState = mReleasedState; + Notification notification(Notification::BROADCAST_ALL, event, true); + // by setting true, we remove subscribers from the linked list + mStateMachine->notifySubscribers(notification); + } + break; + + case RSRC_DENIED: + // no state change. + // we are expecting RELEASED. Handling DENIED + // may like break our state machine in race conditions. + break; + + default: + LOC_LOGE("%s: unrecognized event %d", whoami(), event); + // no state change. + } + + LOC_LOGD("onRsrcEvent, old state %s, new state %s, event %d", + whoami(), nextState->whoami(), event); + return nextState; +} + +// AgpsPendingState +class AgpsReleasingState : public AgpsState +{ + friend class AgpsStateMachine; + + inline AgpsReleasingState(AgpsStateMachine* stateMachine) : + AgpsState(stateMachine) + { mReleasingState = this; } + + inline ~AgpsReleasingState() {} +public: + virtual AgpsState* onRsrcEvent(AgpsRsrcStatus event, void* data); + inline virtual char* whoami() {return (char*)"AgpsReleasingState";} +}; + +AgpsState* AgpsReleasingState::onRsrcEvent(AgpsRsrcStatus event, void* data) +{ + AgpsState* nextState = this;; + switch (event) + { + case RSRC_SUBSCRIBE: + { + // already requested for NIF resource, + // do nothing until we get RSRC_GRANTED indication + // but we need to add subscriber to the list + mStateMachine->addSubscriber((Subscriber*)data); + // no state change. + } + break; + + case RSRC_UNSUBSCRIBE: + { + Subscriber* subscriber = (Subscriber*) data; + if (subscriber->waitForCloseComplete()) { + subscriber->setInactive(); + } else { + // auto notify this subscriber of the unsubscribe + Notification notification(subscriber, event, true); + mStateMachine->notifySubscribers(notification); + } + + // now check if there is any subscribers left + if (!mStateMachine->hasSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasingState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } else if (!mStateMachine->hasActiveSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasedState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } + } + break; + + case RSRC_RELEASED: + { + nextState = mAcquiredState; + Notification notification(Notification::BROADCAST_INACTIVE, event, true); + // notify all subscribers that are active NIF resource RELEASE + // by setting false, we keep subscribers on the linked list + mStateMachine->notifySubscribers(notification); + + if (mStateMachine->hasSubscribers()) { + nextState = mPendingState; + // request from connecivity service for NIF + mStateMachine->sendRsrcRequest(GPS_REQUEST_AGPS_DATA_CONN); + } else { + nextState = mReleasedState; + } + } + break; + + case RSRC_GRANTED: + case RSRC_DENIED: + default: + LOC_LOGE("%s: unrecognized event %d", whoami(), event); + // no state change. + } + + LOC_LOGD("onRsrcEvent, old state %s, new state %s, event %d", + whoami(), nextState->whoami(), event); + return nextState; +} + + +//====================================================================== +// AgpsStateMachine +//====================================================================== + +AgpsStateMachine::AgpsStateMachine(void (*servicer)(AGpsStatus* status), + AGpsType type) : + mServicer(servicer), mType(type), + mStatePtr(new AgpsReleasedState(this)), + mAPN(NULL), + mAPNLen(0) +{ + linked_list_init(&mSubscribers); + + // setting up mReleasedState + mStatePtr->mPendingState = new AgpsPendingState(this); + mStatePtr->mAcquiredState = new AgpsAcquiredState(this); + mStatePtr->mReleasingState = new AgpsReleasingState(this); + + // setting up mAcquiredState + mStatePtr->mAcquiredState->mReleasedState = mStatePtr; + mStatePtr->mAcquiredState->mPendingState = mStatePtr->mPendingState; + mStatePtr->mAcquiredState->mReleasingState = mStatePtr->mReleasingState; + + // setting up mPendingState + mStatePtr->mPendingState->mAcquiredState = mStatePtr->mAcquiredState; + mStatePtr->mPendingState->mReleasedState = mStatePtr; + mStatePtr->mPendingState->mReleasingState = mStatePtr->mReleasingState; + + // setting up mReleasingState + mStatePtr->mReleasingState->mReleasedState = mStatePtr; + mStatePtr->mReleasingState->mPendingState = mStatePtr->mPendingState; + mStatePtr->mReleasingState->mAcquiredState = mStatePtr->mAcquiredState; +} + +AgpsStateMachine::~AgpsStateMachine() +{ + dropAllSubscribers(); + + // free the 3 states. We must read out all 3 pointers first. + // Otherwise we run the risk of getting pointers from already + // freed memory. + AgpsState* acquiredState = mStatePtr->mAcquiredState; + AgpsState* releasedState = mStatePtr->mReleasedState; + AgpsState* pendindState = mStatePtr->mPendingState; + AgpsState* releasingState = mStatePtr->mReleasingState; + + delete acquiredState; + delete releasedState; + delete pendindState; + delete releasingState; + linked_list_destroy(&mSubscribers); + + if (NULL != mAPN) { + delete[] mAPN; + mAPN = NULL; + } +} + +void AgpsStateMachine::setAPN(const char* apn, unsigned int len) +{ + if (NULL != mAPN) { + delete mAPN; + } + + if (NULL != apn) { + mAPN = new char[len+1]; + memcpy(mAPN, apn, len); + mAPN[len] = NULL; + + mAPNLen = len; + } else { + mAPN = NULL; + mAPNLen = 0; + } +} + +void AgpsStateMachine::onRsrcEvent(AgpsRsrcStatus event) +{ + switch (event) + { + case RSRC_GRANTED: + case RSRC_RELEASED: + case RSRC_DENIED: + mStatePtr = mStatePtr->onRsrcEvent(event, NULL); + break; + default: + LOC_LOGW("AgpsStateMachine: unrecognized event %d", event); + break; + } +} + +void AgpsStateMachine::notifySubscribers(Notification& notification) const +{ + if (notification.postNotifyDelete) { + // just any non NULL value to get started + Subscriber* s = (Subscriber*)~0; + while (NULL != s) { + s = NULL; + // if the last param sets to true, _search will delete + // the node from the list for us. But the problem is + // once that is done, _search returns, leaving the + // rest of the list unprocessed. So we need a loop. + linked_list_search(mSubscribers, (void**)&s, notifySubscriber, + (void*)¬ification, true); + } + } else { + // no loop needed if it the last param sets to false, which + // mean nothing gets deleted from the list. + linked_list_search(mSubscribers, NULL, notifySubscriber, + (void*)¬ification, false); + } +} + +void AgpsStateMachine::addSubscriber(Subscriber* subscriber) const +{ + Subscriber* s = NULL; + Notification notification((const Subscriber*)subscriber); + linked_list_search(mSubscribers, (void**)&s, + hasSubscriber, (void*)¬ification, false); + + if (NULL == s) { + linked_list_add(mSubscribers, subscriber->clone(), deleteObj); + } +} + +void AgpsStateMachine::sendRsrcRequest(AGpsStatusValue action) const +{ + Subscriber* s = NULL; + Notification notification(Notification::BROADCAST_ALL); + linked_list_search(mSubscribers, (void**)&s, hasSubscriber, + (void*)¬ification, false); + + if ((NULL == s) == (GPS_RELEASE_AGPS_DATA_CONN == action)) { + AGpsStatus nifRequest; + nifRequest.size = sizeof(nifRequest); + nifRequest.type = mType; + nifRequest.status = action; + +#ifdef QCOM_FEATURE_IPV6 + if (s == NULL) { + nifRequest.ipv4_addr = INADDR_NONE; + nifRequest.ipv6_addr[0] = 0; + } else { + s->setIPAddresses(nifRequest.ipv4_addr, (char*)nifRequest.ipv6_addr); + } +#else + if (s == NULL) { + nifRequest.ipaddr = INADDR_NONE; + } else { + nifRequest.ipaddr = s->ID; + } +#endif + + CALLBACK_LOG_CALLFLOW("agps_cb", %s, loc_get_agps_status_name(action)); + (*mServicer)(&nifRequest); + } +} + +void AgpsStateMachine::subscribeRsrc(Subscriber *subscriber) +{ + mStatePtr = mStatePtr->onRsrcEvent(RSRC_SUBSCRIBE, (void*)subscriber); +} + +bool AgpsStateMachine::unsubscribeRsrc(Subscriber *subscriber) +{ + Subscriber* s = NULL; + Notification notification((const Subscriber*)subscriber); + linked_list_search(mSubscribers, (void**)&s, + hasSubscriber, (void*)¬ification, false); + + if (NULL != s) { + mStatePtr = mStatePtr->onRsrcEvent(RSRC_UNSUBSCRIBE, (void*)s); + return true; + } + return false; +} + +bool AgpsStateMachine::hasActiveSubscribers() const +{ + Subscriber* s = NULL; + Notification notification(Notification::BROADCAST_ACTIVE); + linked_list_search(mSubscribers, (void**)&s, + hasSubscriber, (void*)¬ification, false); + return NULL != s; +} diff --git a/loc_api/libloc_api_50001/loc_eng_agps.h b/loc_api/libloc_api_50001/loc_eng_agps.h new file mode 100755 index 00000000..1fd0f450 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_agps.h @@ -0,0 +1,274 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __LOC_ENG_AGPS_H__ +#define __LOC_ENG_AGPS_H__ + +#include +#include +#include +#include +#include +#include +#include + +// forward declaration +class AgpsStateMachine; +class Subscriber; + +// NIF resource events +typedef enum { + RSRC_SUBSCRIBE, + RSRC_UNSUBSCRIBE, + RSRC_GRANTED, + RSRC_RELEASED, + RSRC_DENIED, + RSRC_STATUS_MAX +} AgpsRsrcStatus; + +// information bundle for subscribers +struct Notification { + // goes to every subscriber + static const int BROADCAST_ALL; + // goes to every ACTIVE subscriber + static const int BROADCAST_ACTIVE; + // goes to every INACTIVE subscriber + static const int BROADCAST_INACTIVE; + + // go to a specific subscriber + const Subscriber* rcver; + // broadcast + const int groupID; + // the new resource status event + const AgpsRsrcStatus rsrcStatus; + // should the subscriber be deleted after the notification + const bool postNotifyDelete; + + // convenient constructor + inline Notification(const int broadcast, + const AgpsRsrcStatus status, + const bool deleteAfterwards) : + rcver(NULL), groupID(broadcast), rsrcStatus(status), + postNotifyDelete(deleteAfterwards) {} + + // convenient constructor + inline Notification(const Subscriber* subscriber, + const AgpsRsrcStatus status, + const bool deleteAfterwards) : + rcver(subscriber), groupID(-1), rsrcStatus(status), + postNotifyDelete(deleteAfterwards) {} + + // convenient constructor + inline Notification(const int broadcast) : + rcver(NULL), groupID(broadcast), rsrcStatus(RSRC_STATUS_MAX), + postNotifyDelete(false) {} + + // convenient constructor + inline Notification(const Subscriber* subscriber) : + rcver(subscriber), groupID(-1), rsrcStatus(RSRC_STATUS_MAX), + postNotifyDelete(false) {} +}; + +class AgpsState { + // allows AgpsStateMachine to access private data + // no class members are public. We don't want + // anyone but state machine to use state. + friend class AgpsStateMachine; + + // state transitions are done here. + // Each state implements its own transitions (of course). + inline virtual AgpsState* onRsrcEvent(AgpsRsrcStatus event, void* data) = 0; + +protected: + // handle back to state machine + const AgpsStateMachine* mStateMachine; + // each state has pointers to all 3 states + // one of which is to itself. + AgpsState* mReleasedState; + AgpsState* mAcquiredState; + AgpsState* mPendingState; + AgpsState* mReleasingState; + + inline AgpsState(const AgpsStateMachine *stateMachine) : + mStateMachine(stateMachine), + mReleasedState(NULL), + mAcquiredState(NULL), + mPendingState(NULL), + mReleasingState(NULL) {} + virtual ~AgpsState() {} + +public: + // for logging purpose + inline virtual char* whoami() = 0; +}; + +class AgpsStateMachine { + // allows AgpsState to access private data + // each state is really internal data to the + // state machine, so it should be able to + // access anything within the state machine. + friend class AgpsState; + + // handle to whoever provides the service + void (* const mServicer)(AGpsStatus* status); + // NIF type: AGNSS or INTERNET. + const AGpsType mType; + // pointer to the current state. + AgpsState* mStatePtr; + // a linked list of subscribers. + void* mSubscribers; + // apn to the NIF. Each state machine tracks + // resource state of a particular NIF. For each + // NIF, there is also an active APN. + char* mAPN; + // for convenience, we don't do strlen each time. + unsigned int mAPNLen; +#ifdef QCOM_FEATURE_IPV6 + // bear + AGpsBearerType mBearer; +#endif + // ipv4 address for routing + +public: + AgpsStateMachine(void (*servicer)(AGpsStatus* status), AGpsType type); + virtual ~AgpsStateMachine(); + + // self explanatory methods below + void setAPN(const char* apn, unsigned int len); + inline const char* getAPN() const { return (const char*)mAPN; } +#ifdef QCOM_FEATURE_IPV6 + inline void setBearer(AGpsBearerType bearer) { mBearer = bearer; } + inline AGpsBearerType getBearer() const { return mBearer; } +#endif + inline AGpsType getType() const { return (AGpsType)mType; } + + // someone, a ATL client or BIT, is asking for NIF + void subscribeRsrc(Subscriber *subscriber); + + // someone, a ATL client or BIT, is done with NIF + bool unsubscribeRsrc(Subscriber *subscriber); + + // add a subscriber in the linked list, if not already there. + void addSubscriber(Subscriber* subscriber) const; + + void onRsrcEvent(AgpsRsrcStatus event); + + // put the data together and send the FW + void sendRsrcRequest(AGpsStatusValue action) const; + + inline bool hasSubscribers() const + { return !linked_list_empty(mSubscribers); } + + bool hasActiveSubscribers() const; + + inline void dropAllSubscribers() const + { linked_list_flush(mSubscribers); } + + // private. Only a state gets to call this. + void notifySubscribers(Notification& notification) const; +}; + +// each subscriber is a AGPS client. In the case of ATL, there could be +// multiple clients from modem. In the case of BIT, there is only one +// cilent from BIT daemon. +struct Subscriber { + const int ID; + const AgpsStateMachine* mStateMachine; + inline Subscriber(const int id, + const AgpsStateMachine* stateMachine) : + ID(id), mStateMachine(stateMachine) {} + inline virtual ~Subscriber() {} + + virtual void setIPAddresses(int &v4, char* v6) = 0; + + inline virtual bool equals(const Subscriber *s) const + { return ID == s->ID; } + + // notifies a subscriber a new NIF resource status, usually + // either GRANTE, DENIED, or RELEASED + virtual bool notifyRsrcStatus(Notification ¬ification) = 0; + + virtual bool waitForCloseComplete() { return false; } + virtual void setInactive() {} + virtual bool isInactive() { return false; } + + virtual Subscriber* clone() = 0; + // checks if this notification is for me, i.e. + // either has my id, or has a broadcast id. + bool forMe(Notification ¬ification); +}; + +// BITSubscriber, created with requests from BIT daemon +struct BITSubscriber : public Subscriber { + inline BITSubscriber(const AgpsStateMachine* stateMachine, + unsigned int ipv4, char* ipv6) : + Subscriber(ipv4, stateMachine) + { + if (NULL == ipv6) { + ipv6Addr[0] = NULL; + } else { + memcpy(ipv6Addr, ipv6, sizeof(ipv6Addr)); + } + } + + virtual bool notifyRsrcStatus(Notification ¬ification); + + inline virtual void setIPAddresses(int &v4, char* v6) + { v4 = ID; memcpy(v6, ipv6Addr, sizeof(ipv6Addr)); } + + virtual Subscriber* clone() + { + return new BITSubscriber(mStateMachine, ID, ipv6Addr); + } + + virtual bool equals(const Subscriber *s) const; + +private: + char ipv6Addr[16]; +}; + +// ATLSubscriber, created with requests from ATL +struct ATLSubscriber : public Subscriber { + const LocApiAdapter* mLocAdapter; + inline ATLSubscriber(const int id, + const AgpsStateMachine* stateMachine, + const LocApiAdapter* adapter) : + Subscriber(id, stateMachine), mLocAdapter(adapter) {} + virtual bool notifyRsrcStatus(Notification ¬ification); + + inline virtual void setIPAddresses(int &v4, char* v6) + { v4 = INADDR_NONE; v6[0] = 0; } + + inline virtual Subscriber* clone() + { + return new ATLSubscriber(ID, mStateMachine, mLocAdapter); + } +}; + +#endif //__LOC_ENG_AGPS_H__ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp new file mode 100755 index 00000000..f2f9a501 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp @@ -0,0 +1,180 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include +#include +#include +#include +#include +#include + +#include "log_util.h" + +#include "loc_eng_dmn_conn_glue_msg.h" +#include "loc_eng_dmn_conn_handler.h" +#include "loc_eng_dmn_conn.h" + +static int loc_api_server_msgqid; +static int loc_api_resp_msgqid; + +static const char * global_loc_api_q_path = GPSONE_LOC_API_Q_PATH; +static const char * global_loc_api_resp_q_path = GPSONE_LOC_API_RESP_Q_PATH; + +static int loc_api_server_proc_init(void *context) +{ + loc_api_server_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_q_path, O_RDWR); + loc_api_resp_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_resp_q_path, O_RDWR); + + LOC_LOGD("%s:%d] loc_api_server_msgqid = %d\n", __func__, __LINE__, loc_api_server_msgqid); + return 0; +} + +static int loc_api_server_proc_pre(void *context) +{ + return 0; +} + +static int loc_api_server_proc(void *context) +{ + int length, sz; + int result = 0; + static int cnt = 0; + struct ctrl_msgbuf * p_cmsgbuf; + struct ctrl_msgbuf cmsg_resp; + + sz = sizeof(struct ctrl_msgbuf) + 256; + p_cmsgbuf = (struct ctrl_msgbuf *) malloc(sz); + + if (!p_cmsgbuf) { + LOC_LOGE("%s:%d] Out of memory\n", __func__, __LINE__); + return -1; + } + + cnt ++; + LOC_LOGD("%s:%d] %d listening on %s...\n", __func__, __LINE__, cnt, (char *) context); + length = loc_eng_dmn_conn_glue_msgrcv(loc_api_server_msgqid, p_cmsgbuf, sz); + if (length <= 0) { + LOC_LOGE("%s:%d] fail receiving msg from gpsone_daemon, retry later\n", __func__, __LINE__); + usleep(1000); + return 0; + } + + LOC_LOGD("%s:%d] received ctrl_type = %d\n", __func__, __LINE__, p_cmsgbuf->ctrl_type); + switch(p_cmsgbuf->ctrl_type) { + case GPSONE_LOC_API_IF_REQUEST: + result = loc_eng_dmn_conn_loc_api_server_if_request_handler(p_cmsgbuf, length); + break; + + case GPSONE_LOC_API_IF_RELEASE: + result = loc_eng_dmn_conn_loc_api_server_if_release_handler(p_cmsgbuf, length); + break; + + case GPSONE_UNBLOCK: + LOC_LOGD("%s:%d] GPSONE_UNBLOCK\n", __func__, __LINE__); + break; + + default: + LOC_LOGE("%s:%d] unsupported ctrl_type = %d\n", + __func__, __LINE__, p_cmsgbuf->ctrl_type); + break; + } + + free(p_cmsgbuf); + return 0; +} + +static int loc_api_server_proc_post(void *context) +{ + LOC_LOGD("%s:%d]\n", __func__, __LINE__); + loc_eng_dmn_conn_glue_msgremove( global_loc_api_q_path, loc_api_server_msgqid); + loc_eng_dmn_conn_glue_msgremove( global_loc_api_resp_q_path, loc_api_resp_msgqid); + return 0; +} + +static int loc_eng_dmn_conn_unblock_proc(void) +{ + struct ctrl_msgbuf cmsgbuf; + cmsgbuf.ctrl_type = GPSONE_UNBLOCK; + LOC_LOGD("%s:%d]\n", __func__, __LINE__); + loc_eng_dmn_conn_glue_msgsnd(loc_api_server_msgqid, & cmsgbuf, sizeof(cmsgbuf)); + return 0; +} + +static struct loc_eng_dmn_conn_thelper thelper; + +int loc_eng_dmn_conn_loc_api_server_launch(thelper_create_thread create_thread_cb, + const char * loc_api_q_path, const char * resp_q_path, void *agps_handle) +{ + int result; + + loc_api_handle = agps_handle; + + if (loc_api_q_path) global_loc_api_q_path = loc_api_q_path; + if (resp_q_path) global_loc_api_resp_q_path = resp_q_path; + + result = loc_eng_dmn_conn_launch_thelper( &thelper, + loc_api_server_proc_init, + loc_api_server_proc_pre, + loc_api_server_proc, + loc_api_server_proc_post, + create_thread_cb, + (char *) global_loc_api_q_path); + if (result != 0) { + LOC_LOGE("%s:%d]\n", __func__, __LINE__); + return -1; + } + return 0; +} + +int loc_eng_dmn_conn_loc_api_server_unblock(void) +{ + loc_eng_dmn_conn_unblock_thelper(&thelper); + loc_eng_dmn_conn_unblock_proc(); + return 0; +} + +int loc_eng_dmn_conn_loc_api_server_join(void) +{ + loc_eng_dmn_conn_join_thelper(&thelper); + return 0; +} + +int loc_eng_dmn_conn_loc_api_server_data_conn(int status) { + struct ctrl_msgbuf cmsgbuf; + cmsgbuf.ctrl_type = GPSONE_LOC_API_RESPONSE; + cmsgbuf.cmsg.cmsg_response.result = status; + LOC_LOGD("%s:%d] status = %d",__func__, __LINE__, status); + if (loc_eng_dmn_conn_glue_msgsnd(loc_api_resp_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { + LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); + return -1; + } + return 0; + +} + diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h new file mode 100755 index 00000000..414fd553 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h @@ -0,0 +1,53 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_DATA_SERVER_H +#define LOC_ENG_DATA_SERVER_H + +#include "loc_eng_dmn_conn_thread_helper.h" + +#ifdef _ANDROID_ + +#define GPSONE_LOC_API_Q_PATH "/data/misc/gpsone_d/gpsone_loc_api_q" +#define GPSONE_LOC_API_RESP_Q_PATH "/data/misc/gpsone_d/gpsone_loc_api_resp_q" + +#else + +#define GPSONE_LOC_API_Q_PATH "/tmp/gpsone_loc_api_q" +#define GPSONE_LOC_API_RESP_Q_PATH "/tmp/gpsone_loc_api_resp_q" + +#endif + +int loc_eng_dmn_conn_loc_api_server_launch(thelper_create_thread create_thread_cb, + const char * loc_api_q_path, const char * ctrl_q_path, void *agps_handle); +int loc_eng_dmn_conn_loc_api_server_unblock(void); +int loc_eng_dmn_conn_loc_api_server_join(void); +int loc_eng_dmn_conn_loc_api_server_data_conn(int); + +#endif /* LOC_ENG_DATA_SERVER_H */ + diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c new file mode 100755 index 00000000..9cd19228 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c @@ -0,0 +1,223 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +#include + +#include + +#include "log_util.h" + +#include "loc_eng_dmn_conn_glue_msg.h" +#include "loc_eng_dmn_conn_handler.h" + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgget + +DESCRIPTION + This function get a message queue + + q_path - name path of the message queue + mode - + +DEPENDENCIES + None + +RETURN VALUE + message queue id + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgget(const char * q_path, int mode) +{ + int msgqid; + msgqid = loc_eng_dmn_conn_glue_pipeget(q_path, mode); + return msgqid; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgremove + +DESCRIPTION + remove a message queue + + q_path - name path of the message queue + msgqid - message queue id + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgremove(const char * q_path, int msgqid) +{ + int result; + result = loc_eng_dmn_conn_glue_piperemove(q_path, msgqid); + return result; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgsnd + +DESCRIPTION + Send a message + + msgqid - message queue id + msgp - pointer to the message to be sent + msgsz - size of the message + +DEPENDENCIES + None + +RETURN VALUE + number of bytes sent out or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgsnd(int msgqid, const void * msgp, size_t msgsz) +{ + int result; + struct ctrl_msgbuf *pmsg = (struct ctrl_msgbuf *) msgp; + pmsg->msgsz = msgsz; + + result = loc_eng_dmn_conn_glue_pipewrite(msgqid, msgp, msgsz); + if (result != (int) msgsz) { + LOC_LOGE("%s:%d] pipe broken %d, msgsz = %d\n", __func__, __LINE__, result, (int) msgsz); + return -1; + } + + return result; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgrcv + +DESCRIPTION + receive a message + + msgqid - message queue id + msgp - pointer to the buffer to hold the message + msgsz - size of the buffer + +DEPENDENCIES + None + +RETURN VALUE + number of bytes received or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgrcv(int msgqid, void *msgp, size_t msgbufsz) +{ + int result; + struct ctrl_msgbuf *pmsg = (struct ctrl_msgbuf *) msgp; + + result = loc_eng_dmn_conn_glue_piperead(msgqid, &(pmsg->msgsz), sizeof(pmsg->msgsz)); + if (result != sizeof(pmsg->msgsz)) { + LOC_LOGE("%s:%d] pipe broken %d\n", __func__, __LINE__, result); + return -1; + } + + if (msgbufsz < pmsg->msgsz) { + LOC_LOGE("%s:%d] msgbuf is too small %d < %d\n", __func__, __LINE__, (int) msgbufsz, (int) pmsg->msgsz); + return -1; + } + + result = loc_eng_dmn_conn_glue_piperead(msgqid, (uint8_t *) msgp + sizeof(pmsg->msgsz), pmsg->msgsz - sizeof(pmsg->msgsz)); + if (result != (int) (pmsg->msgsz - sizeof(pmsg->msgsz))) { + LOC_LOGE("%s:%d] pipe broken %d, msgsz = %d\n", __func__, __LINE__, result, (int) pmsg->msgsz); + return -1; + } + + return pmsg->msgsz; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgunblock + +DESCRIPTION + unblock a message queue + + msgqid - message queue id + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgunblock(int msgqid) +{ + return loc_eng_dmn_conn_glue_pipeunblock(msgqid); +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_msgflush + +DESCRIPTION + flush out the message in a queue + + msgqid - message queue id + +DEPENDENCIES + None + +RETURN VALUE + number of bytes that are flushed out. + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_msgflush(int msgqid) +{ + int length; + char buf[128]; + + do { + length = loc_eng_dmn_conn_glue_piperead(msgqid, buf, 128); + LOC_LOGD("%s:%d] %s\n", __func__, __LINE__, buf); + } while(length); + return length; +} + diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h new file mode 100755 index 00000000..8bc6f2a3 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h @@ -0,0 +1,51 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_DMN_CONN_GLUE_MSG_H +#define LOC_ENG_DMN_CONN_GLUE_MSG_H + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + + +#include +#include "loc_eng_dmn_conn_glue_pipe.h" + +int loc_eng_dmn_conn_glue_msgget(const char * q_path, int mode); +int loc_eng_dmn_conn_glue_msgremove(const char * q_path, int msgqid); +int loc_eng_dmn_conn_glue_msgsnd(int msgqid, const void * msgp, size_t msgsz); +int loc_eng_dmn_conn_glue_msgrcv(int msgqid, void *msgp, size_t msgsz); +int loc_eng_dmn_conn_glue_msgflush(int msgqid); +int loc_eng_dmn_conn_glue_msgunblock(int msgqid); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* LOC_ENG_DMN_CONN_GLUE_MSG_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c new file mode 100755 index 00000000..74769088 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c @@ -0,0 +1,206 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +#include +#include + +// #include +#include +// #include +#include +#include + +#include "loc_eng_dmn_conn_glue_pipe.h" +#include "log_util.h" + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_pipeget + +DESCRIPTION + create a named pipe. + + pipe_name - pipe name path + mode - mode + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_pipeget(const char * pipe_name, int mode) +{ + int fd; + int result; + + LOC_LOGD("%s, mode = %d\n", pipe_name, mode); + result = mkfifo(pipe_name, 0666); + + if ((result == -1) && (errno != EEXIST)) { + LOC_LOGE("failed: %s\n", strerror(errno)); + return result; + } + + fd = open(pipe_name, mode); + if (fd <= 0) + { + LOC_LOGE("failed: %s\n", strerror(errno)); + } + LOC_LOGD("fd = %d, %s\n", fd, pipe_name); + return fd; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_piperemove + +DESCRIPTION + remove a pipe + + pipe_name - pipe name path + fd - fd for the pipe + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_piperemove(const char * pipe_name, int fd) +{ + close(fd); + if (pipe_name) unlink(pipe_name); + LOC_LOGD("fd = %d, %s\n", fd, pipe_name); + return 0; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_pipewrite + +DESCRIPTION + write to a pipe + + fd - fd of a pipe + buf - buffer for the data to write + sz - size of the data in buffer + +DEPENDENCIES + None + +RETURN VALUE + number of bytes written or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_pipewrite(int fd, const void * buf, size_t sz) +{ + int result; + + result = write(fd, buf, sz); + + /* @todo check for non EINTR & EAGAIN, shall not do select again, select_tut Law 7) */ + + /* LOC_LOGD("fd = %d, buf = 0x%lx, size = %d, result = %d\n", fd, (long) buf, (int) sz, (int) result); */ + return result; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_piperead + +DESCRIPTION + read from a pipe + + fd - fd for the pipe + buf - buffer to hold the data read from pipe + sz - size of the buffer + +DEPENDENCIES + None + +RETURN VALUE + number of bytes read from pipe or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_piperead(int fd, void * buf, size_t sz) +{ + int len; + + len = read(fd, buf, sz); + + /* @todo check for non EINTR & EAGAIN, shall not do select again, select_tut Law 7) */ + + /* LOC_LOGD("fd = %d, buf = 0x%lx, size = %d, len = %d\n", fd, (long) buf, (int) sz, len); */ + return len; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_glue_pipeunblock + +DESCRIPTION + unblock a pipe + + fd - fd for the pipe + +DEPENDENCIES + None + +RETURN VALUE + 0 for success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_glue_pipeunblock(int fd) +{ + int result; + struct flock flock_v; + LOC_LOGD("\n"); +// result = fcntl(fd, F_SETFL, fcntl(fd, F_GETFL, 0) | O_NDELAY); + flock_v.l_type = F_UNLCK; + flock_v.l_len = 32; + result = fcntl(fd, F_SETLK, &flock_v); + if (result < 0) { + LOC_LOGE("fcntl failure, %s\n", strerror(errno)); + } + + return result; +} diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h new file mode 100755 index 00000000..3136e411 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h @@ -0,0 +1,50 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_DMN_CONN_GLUE_PIPE_H +#define LOC_ENG_DMN_CONN_GLUE_PIPE_H + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include + +int loc_eng_dmn_conn_glue_pipeget(const char * pipe_name, int mode); +int loc_eng_dmn_conn_glue_piperemove(const char * pipe_name, int fd); +int loc_eng_dmn_conn_glue_pipewrite(int fd, const void * buf, size_t sz); +int loc_eng_dmn_conn_glue_piperead(int fd, void * buf, size_t sz); + +int loc_eng_dmn_conn_glue_pipeflush(int fd); +int loc_eng_dmn_conn_glue_pipeunblock(int fd); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* LOC_ENG_DMN_CONN_GLUE_PIPE_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp new file mode 100755 index 00000000..fd15f001 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp @@ -0,0 +1,78 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +#include +#include +#include + +#include "log_util.h" +#include "loc_eng_msg.h" +#include "loc_eng_dmn_conn.h" +#include "loc_eng_dmn_conn_handler.h" + +void* loc_api_handle = NULL; + +int loc_eng_dmn_conn_loc_api_server_if_request_handler(struct ctrl_msgbuf *pmsg, int len) +{ + LOC_LOGD("%s:%d]\n", __func__, __LINE__); +#ifndef DEBUG_DMN_LOC_API + if (NULL == loc_api_handle) { + LOC_LOGE("%s:%d] NO agps data handle\n", __func__, __LINE__); + return 1; + } + + loc_eng_msg_request_bit *msg( + new loc_eng_msg_request_bit(loc_api_handle, + pmsg->cmsg.cmsg_if_request.is_supl, + pmsg->cmsg.cmsg_if_request.ipv4_addr, + (char*)pmsg->cmsg.cmsg_if_request.ipv6_addr)); + loc_eng_msg_sender(loc_api_handle, msg); + +#else + loc_eng_dmn_conn_loc_api_server_data_conn(GPSONE_LOC_API_IF_REQUEST_SUCCESS); +#endif + return 0; +} + +int loc_eng_dmn_conn_loc_api_server_if_release_handler(struct ctrl_msgbuf *pmsg, int len) +{ + LOC_LOGD("%s:%d]\n", __func__, __LINE__); +#ifndef DEBUG_DMN_LOC_API + loc_eng_msg_release_bit *msg( + new loc_eng_msg_release_bit(loc_api_handle, + pmsg->cmsg.cmsg_if_request.is_supl, + pmsg->cmsg.cmsg_if_request.ipv4_addr, + (char*)pmsg->cmsg.cmsg_if_request.ipv6_addr)); + loc_eng_msg_sender(loc_api_handle, msg); +#else + loc_eng_dmn_conn_loc_api_server_data_conn(GPSONE_LOC_API_IF_RELEASE_SUCCESS); +#endif + return 0; +} + diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h new file mode 100755 index 00000000..833e971b --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h @@ -0,0 +1,82 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_DATA_SERVER_HANDLER +#define LOC_ENG_DATA_SERVER_HANDLER + +#include +#include + +enum { + /* 0x0 - 0xEF is reserved for daemon internal */ + GPSONE_LOC_API_IF_REQUEST = 0xF0, + GPSONE_LOC_API_IF_RELEASE, + GPSONE_LOC_API_RESPONSE, + GPSONE_UNBLOCK, +}; + +enum { + GPSONE_LOC_API_IF_REQUEST_SUCCESS = 0xF0, + GPSONE_LOC_API_IF_RELEASE_SUCCESS, + GPSONE_LOC_API_IF_FAILURE, +}; + + +struct ctrl_msg_response { + int result; +}; + +struct ctrl_msg_unblock { + int reserved; +}; + +struct ctrl_msg_if_request { + unsigned is_supl; /* 1: use Android SUPL connection; 0: use Android default internet connection */ + unsigned long ipv4_addr; + unsigned char ipv6_addr[16]; +}; + +/* do not change this structure */ +struct ctrl_msgbuf { + size_t msgsz; + uint16_t reserved1; + uint32_t reserved2; + uint8_t ctrl_type; + union { + struct ctrl_msg_response cmsg_response; + struct ctrl_msg_unblock cmsg_unblock; + struct ctrl_msg_if_request cmsg_if_request; + } cmsg; +}; + +extern void* loc_api_handle; + +int loc_eng_dmn_conn_loc_api_server_if_request_handler(struct ctrl_msgbuf *pmsg, int len); +int loc_eng_dmn_conn_loc_api_server_if_release_handler(struct ctrl_msgbuf *pmsg, int len); + +#endif /* LOC_ENG_DATA_SERVER_HANDLER */ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c new file mode 100755 index 00000000..478b686f --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c @@ -0,0 +1,398 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include + +#include "log_util.h" +#include "loc_eng_dmn_conn_thread_helper.h" + +/*=========================================================================== +FUNCTION thelper_signal_init + +DESCRIPTION + This function will initialize the conditional variable resources. + + thelper - thelper instance + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int thelper_signal_init(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result; + thelper->thread_exit = 0; + thelper->thread_ready = 0; + result = pthread_cond_init( &thelper->thread_cond, NULL); + if (result) { + return result; + } + + result = pthread_mutex_init(&thelper->thread_mutex, NULL); + if (result) { + pthread_cond_destroy(&thelper->thread_cond); + } + return result; +} + +/*=========================================================================== +FUNCTION + +DESCRIPTION + This function will destroy the conditional variable resources + + thelper - pointer to thelper instance + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int thelper_signal_destroy(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result, ret_result = 0; + result = pthread_cond_destroy( &thelper->thread_cond); + if (result) { + ret_result = result; + } + + result = pthread_mutex_destroy(&thelper->thread_mutex); + if (result) { + ret_result = result; + } + + return ret_result; +} + +/*=========================================================================== +FUNCTION thelper_signal_wait + +DESCRIPTION + This function will be blocked on the conditional variable until thelper_signal_ready + is called + + thelper - pointer to thelper instance + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int thelper_signal_wait(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result = 0; + + pthread_mutex_lock(&thelper->thread_mutex); + if (!thelper->thread_ready && !thelper->thread_exit) { + result = pthread_cond_wait(&thelper->thread_cond, &thelper->thread_mutex); + } + + if (thelper->thread_exit) { + result = -1; + } + pthread_mutex_unlock(&thelper->thread_mutex); + + return result; +} + +/*=========================================================================== +FUNCTION thelper_signal_ready + +DESCRIPTION + This function will wake up the conditional variable + + thelper - pointer to thelper instance + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int thelper_signal_ready(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result; + + LOC_LOGD("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + + pthread_mutex_lock(&thelper->thread_mutex); + thelper->thread_ready = 1; + result = pthread_cond_signal(&thelper->thread_cond); + pthread_mutex_unlock(&thelper->thread_mutex); + + return result; +} + +/*=========================================================================== +FUNCTION thelper_signal_block + +DESCRIPTION + This function will set the thread ready to 0 to block the thelper_signal_wait + + thelper - pointer to thelper instance + +DEPENDENCIES + None + +RETURN VALUE + if thread_ready is set + +SIDE EFFECTS + N/A + +===========================================================================*/ +int thelper_signal_block(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result = thelper->thread_ready; + + LOC_LOGD("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + + pthread_mutex_lock(&thelper->thread_mutex); + thelper->thread_ready = 0; + pthread_mutex_unlock(&thelper->thread_mutex); + + return result; +} + +/*=========================================================================== +FUNCTION thelper_main + +DESCRIPTION + This function is the main thread. It will be launched as a child thread + + data - pointer to the instance + +DEPENDENCIES + None + +RETURN VALUE + NULL + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void * thelper_main(void *data) +{ + int result = 0; + struct loc_eng_dmn_conn_thelper * thelper = (struct loc_eng_dmn_conn_thelper *) data; + + if (thelper->thread_proc_init) { + result = thelper->thread_proc_init(thelper->thread_context); + if (result < 0) { + thelper->thread_exit = 1; + thelper_signal_ready(thelper); + LOC_LOGE("%s:%d] error: 0x%lx\n", __func__, __LINE__, (long) thelper); + return NULL; + } + } + + thelper_signal_ready(thelper); + + if (thelper->thread_proc_pre) { + result = thelper->thread_proc_pre(thelper->thread_context); + if (result < 0) { + thelper->thread_exit = 1; + LOC_LOGE("%s:%d] error: 0x%lx\n", __func__, __LINE__, (long) thelper); + return NULL; + } + } + + do { + if (thelper->thread_proc) { + result = thelper->thread_proc(thelper->thread_context); + if (result < 0) { + thelper->thread_exit = 1; + LOC_LOGE("%s:%d] error: 0x%lx\n", __func__, __LINE__, (long) thelper); + } + } + } while (thelper->thread_exit == 0); + + if (thelper->thread_proc_post) { + result = thelper->thread_proc_post(thelper->thread_context); + } + + if (result != 0) { + LOC_LOGE("%s:%d] error: 0x%lx\n", __func__, __LINE__, (long) thelper); + } + return NULL; +} + +static void thelper_main_2(void *data) +{ + thelper_main(data); + return; +} + + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_launch_thelper + +DESCRIPTION + This function will initialize the thread context and launch the thelper_main + + thelper - pointer to thelper instance + thread_proc_init - The initialization function pointer + thread_proc_pre - The function to call before task loop and after initialization + thread_proc - The task loop + thread_proc_post - The function to call after the task loop + context - the context for the above four functions + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_launch_thelper(struct loc_eng_dmn_conn_thelper * thelper, + int (*thread_proc_init) (void * context), + int (*thread_proc_pre) (void * context), + int (*thread_proc) (void * context), + int (*thread_proc_post) (void * context), + thelper_create_thread create_thread_cb, + void * context) +{ + int result; + + thelper_signal_init(thelper); + + if (context) { + thelper->thread_context = context; + } + + thelper->thread_proc_init = thread_proc_init; + thelper->thread_proc_pre = thread_proc_pre; + thelper->thread_proc = thread_proc; + thelper->thread_proc_post = thread_proc_post; + + LOC_LOGD("%s:%d] 0x%lx call pthread_create\n", __func__, __LINE__, (long) thelper); + if (create_thread_cb) { + result = 0; + thelper->thread_id = create_thread_cb("loc_eng_dmn_conn", + thelper_main_2, (void *)thelper); + } else { + result = pthread_create(&thelper->thread_id, NULL, + thelper_main, (void *)thelper); + } + + if (result != 0) { + LOC_LOGE("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + return -1; + } + + LOC_LOGD("%s:%d] 0x%lx pthread_create done\n", __func__, __LINE__, (long) thelper); + + thelper_signal_wait(thelper); + + LOC_LOGD("%s:%d] 0x%lx pthread ready\n", __func__, __LINE__, (long) thelper); + return thelper->thread_exit; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_unblock_thelper + +DESCRIPTION + This function unblocks thelper_main to release the thread + + thelper - pointer to thelper instance + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_unblock_thelper(struct loc_eng_dmn_conn_thelper * thelper) +{ + LOC_LOGD("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + thelper->thread_exit = 1; + return 0; +} + +/*=========================================================================== +FUNCTION loc_eng_dmn_conn_join_thelper + + thelper - pointer to thelper instance + +DESCRIPTION + This function will wait for the thread of thelper_main to finish + +DEPENDENCIES + None + +RETURN VALUE + 0: success or negative value for failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_dmn_conn_join_thelper(struct loc_eng_dmn_conn_thelper * thelper) +{ + int result; + + LOC_LOGD("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + result = pthread_join(thelper->thread_id, NULL); + if (result != 0) { + LOC_LOGE("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + } + LOC_LOGD("%s:%d] 0x%lx\n", __func__, __LINE__, (long) thelper); + + thelper_signal_destroy(thelper); + + return result; +} + diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h new file mode 100755 index 00000000..07869f90 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h @@ -0,0 +1,74 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef __LOC_ENG_DMN_CONN_THREAD_HELPER_H__ +#define __LOC_ENG_DMN_CONN_THREAD_HELPER_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include + +struct loc_eng_dmn_conn_thelper { + unsigned char thread_exit; + unsigned char thread_ready; + pthread_cond_t thread_cond; + pthread_mutex_t thread_mutex; + pthread_t thread_id; + void * thread_context; + int (*thread_proc_init) (void * context); + int (*thread_proc_pre) (void * context); + int (*thread_proc) (void * context); + int (*thread_proc_post) (void * context); +}; + +typedef pthread_t (* thelper_create_thread)(const char* name, void (*start)(void *), void* arg); +int loc_eng_dmn_conn_launch_thelper(struct loc_eng_dmn_conn_thelper * thelper, + int (*thread_proc_init) (void * context), + int (*thread_proc_pre) (void * context), + int (*thread_proc) (void * context), + int (*thread_proc_post) (void * context), + thelper_create_thread create_thread_cb, + void * context); + +int loc_eng_dmn_conn_unblock_thelper(struct loc_eng_dmn_conn_thelper * thelper); +int loc_eng_dmn_conn_join_thelper(struct loc_eng_dmn_conn_thelper * thelper); + +/* if only need to use signal */ +int thelper_signal_init(struct loc_eng_dmn_conn_thelper * thelper); +int thelper_signal_destroy(struct loc_eng_dmn_conn_thelper * thelper); +int thelper_signal_wait(struct loc_eng_dmn_conn_thelper * thelper); +int thelper_signal_ready(struct loc_eng_dmn_conn_thelper * thelper); +int thelper_signal_block(struct loc_eng_dmn_conn_thelper * thelper); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __LOC_ENG_DMN_CONN_THREAD_HELPER_H__ */ diff --git a/loc_api/libloc_api_50001/loc_eng_log.cpp b/loc_api/libloc_api_50001/loc_eng_log.cpp new file mode 100755 index 00000000..d813cd65 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_log.cpp @@ -0,0 +1,292 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng" + +#include "hardware/gps.h" +#include "loc.h" +#include "loc_log.h" +#include "loc_eng_log.h" +#include "loc_eng_msg_id.h" + +/* GPS status names */ +static loc_name_val_s_type gps_status_name[] = +{ + NAME_VAL( GPS_STATUS_NONE ), + NAME_VAL( GPS_STATUS_SESSION_BEGIN ), + NAME_VAL( GPS_STATUS_SESSION_END ), + NAME_VAL( GPS_STATUS_ENGINE_ON ), + NAME_VAL( GPS_STATUS_ENGINE_OFF ), +}; +static int gps_status_num = sizeof(gps_status_name) / sizeof(loc_name_val_s_type); + +/* Find Android GPS status name */ +const char* loc_get_gps_status_name(GpsStatusValue gps_status) +{ + return loc_get_name_from_val(gps_status_name, gps_status_num, + (long) gps_status); +} + + + +static loc_name_val_s_type loc_eng_msgs[] = +{ + NAME_VAL( LOC_ENG_MSG_QUIT ), + NAME_VAL( LOC_ENG_MSG_ENGINE_DOWN ), + NAME_VAL( LOC_ENG_MSG_ENGINE_UP ), + NAME_VAL( LOC_ENG_MSG_START_FIX ), + NAME_VAL( LOC_ENG_MSG_STOP_FIX ), + NAME_VAL( LOC_ENG_MSG_SET_POSITION_MODE ), + NAME_VAL( LOC_ENG_MSG_SET_TIME ), + NAME_VAL( LOC_ENG_MSG_INJECT_XTRA_DATA ), + NAME_VAL( LOC_ENG_MSG_INJECT_LOCATION ), + NAME_VAL( LOC_ENG_MSG_DELETE_AIDING_DATA ), + NAME_VAL( LOC_ENG_MSG_SET_APN ), + NAME_VAL( LOC_ENG_MSG_SET_SERVER_URL ), + NAME_VAL( LOC_ENG_MSG_SET_SERVER_IPV4 ), + NAME_VAL( LOC_ENG_MSG_ENABLE_DATA ), + NAME_VAL( LOC_ENG_MSG_SUPL_VERSION ), + NAME_VAL( LOC_ENG_MSG_SET_SENSOR_CONTROL_CONFIG ), + NAME_VAL( LOC_ENG_MSG_SET_SENSOR_PROPERTIES ), + NAME_VAL( LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG ), + NAME_VAL( LOC_ENG_MSG_MUTE_SESSION ), + NAME_VAL( LOC_ENG_MSG_ATL_OPEN_SUCCESS ), + NAME_VAL( LOC_ENG_MSG_ATL_CLOSED ), + NAME_VAL( LOC_ENG_MSG_ATL_OPEN_FAILED ), + NAME_VAL( LOC_ENG_MSG_REPORT_POSITION ), + NAME_VAL( LOC_ENG_MSG_REPORT_SV ), + NAME_VAL( LOC_ENG_MSG_REPORT_STATUS ), + NAME_VAL( LOC_ENG_MSG_REPORT_NMEA ), + NAME_VAL( LOC_ENG_MSG_REQUEST_ATL ), + NAME_VAL( LOC_ENG_MSG_RELEASE_ATL ), + NAME_VAL( LOC_ENG_MSG_REQUEST_BIT ), + NAME_VAL( LOC_ENG_MSG_RELEASE_BIT ), + NAME_VAL( LOC_ENG_MSG_REQUEST_NI ), + NAME_VAL( LOC_ENG_MSG_INFORM_NI_RESPONSE ), + NAME_VAL( LOC_ENG_MSG_REQUEST_XTRA_DATA ), + NAME_VAL( LOC_ENG_MSG_REQUEST_TIME ) +}; +static int loc_eng_msgs_num = sizeof(loc_eng_msgs) / sizeof(loc_name_val_s_type); + +/* Find Android GPS status name */ +const char* loc_get_msg_name(int id) +{ + return loc_get_name_from_val(loc_eng_msgs, loc_eng_msgs_num, (long) id); +} + + + +static loc_name_val_s_type loc_eng_position_modes[] = +{ + NAME_VAL( LOC_POSITION_MODE_STANDALONE ), + NAME_VAL( LOC_POSITION_MODE_MS_BASED ), + NAME_VAL( LOC_POSITION_MODE_MS_ASSISTED ), + NAME_VAL( LOC_POSITION_MODE_RESERVED_1 ), + NAME_VAL( LOC_POSITION_MODE_RESERVED_2 ), + NAME_VAL( LOC_POSITION_MODE_RESERVED_3 ), + NAME_VAL( LOC_POSITION_MODE_RESERVED_4 ) +}; +static int loc_eng_position_mode_num = sizeof(loc_eng_position_modes) / sizeof(loc_name_val_s_type); + +const char* loc_get_position_mode_name(GpsPositionMode mode) +{ + return loc_get_name_from_val(loc_eng_position_modes, loc_eng_position_mode_num, (long) mode); +} + + + +static loc_name_val_s_type loc_eng_position_recurrences[] = +{ + NAME_VAL( GPS_POSITION_RECURRENCE_PERIODIC ), + NAME_VAL( GPS_POSITION_RECURRENCE_SINGLE ) +}; +static int loc_eng_position_recurrence_num = sizeof(loc_eng_position_recurrences) / sizeof(loc_name_val_s_type); + +const char* loc_get_position_recurrence_name(GpsPositionRecurrence recur) +{ + return loc_get_name_from_val(loc_eng_position_recurrences, loc_eng_position_recurrence_num, (long) recur); +} + + + +static loc_name_val_s_type loc_eng_aiding_data_bits[] = +{ + NAME_VAL( GPS_DELETE_EPHEMERIS ), + NAME_VAL( GPS_DELETE_ALMANAC ), + NAME_VAL( GPS_DELETE_POSITION ), + NAME_VAL( GPS_DELETE_TIME ), + NAME_VAL( GPS_DELETE_IONO ), + NAME_VAL( GPS_DELETE_UTC ), + NAME_VAL( GPS_DELETE_HEALTH ), + NAME_VAL( GPS_DELETE_SVDIR ), + NAME_VAL( GPS_DELETE_SVSTEER ), + NAME_VAL( GPS_DELETE_SADATA ), + NAME_VAL( GPS_DELETE_RTI ), + NAME_VAL( GPS_DELETE_CELLDB_INFO ) +#ifdef QCOM_FEATURE_DELEXT + ,NAME_VAL( GPS_DELETE_ALMANAC_CORR ), + NAME_VAL( GPS_DELETE_FREQ_BIAS_EST ), + NAME_VAL( GPS_DELETE_EPHEMERIS_GLO ), + NAME_VAL( GPS_DELETE_ALMANAC_GLO ), + NAME_VAL( GPS_DELETE_SVDIR_GLO ), + NAME_VAL( GPS_DELETE_SVSTEER_GLO ), + NAME_VAL( GPS_DELETE_ALMANAC_CORR_GLO ), + NAME_VAL( GPS_DELETE_TIME_GPS ), + NAME_VAL( GPS_DELETE_TIME_GLO ) +#endif +}; +static int loc_eng_aiding_data_bit_num = sizeof(loc_eng_aiding_data_bits) / sizeof(loc_name_val_s_type); + +const char* loc_get_aiding_data_mask_names(GpsAidingData data) +{ + return NULL; +} + + +static loc_name_val_s_type loc_eng_agps_types[] = +{ +#ifdef QCOM_FEATURE_IPV6 + NAME_VAL( AGPS_TYPE_INVALID ), + NAME_VAL( AGPS_TYPE_ANY ), +#endif + NAME_VAL( AGPS_TYPE_SUPL ), + NAME_VAL( AGPS_TYPE_C2K ) +#ifdef QCOM_FEATURE_IPV6 + ,NAME_VAL( AGPS_TYPE_WWAN_ANY ) +#endif +}; +static int loc_eng_agps_type_num = sizeof(loc_eng_agps_types) / sizeof(loc_name_val_s_type); + +const char* loc_get_agps_type_name(AGpsType type) +{ + return loc_get_name_from_val(loc_eng_agps_types, loc_eng_agps_type_num, (long) type); +} + + +static loc_name_val_s_type loc_eng_ni_types[] = +{ + NAME_VAL( GPS_NI_TYPE_VOICE ), + NAME_VAL( GPS_NI_TYPE_UMTS_SUPL ), + NAME_VAL( GPS_NI_TYPE_UMTS_CTRL_PLANE ) +}; +static int loc_eng_ni_type_num = sizeof(loc_eng_ni_types) / sizeof(loc_name_val_s_type); + +const char* loc_get_ni_type_name(GpsNiType type) +{ + return loc_get_name_from_val(loc_eng_ni_types, loc_eng_ni_type_num, (long) type); +} + + +static loc_name_val_s_type loc_eng_ni_responses[] = +{ + NAME_VAL( GPS_NI_RESPONSE_ACCEPT ), + NAME_VAL( GPS_NI_RESPONSE_DENY ), + NAME_VAL( GPS_NI_RESPONSE_DENY ) +}; +static int loc_eng_ni_reponse_num = sizeof(loc_eng_ni_responses) / sizeof(loc_name_val_s_type); + +const char* loc_get_ni_response_name(GpsUserResponseType response) +{ + return loc_get_name_from_val(loc_eng_ni_responses, loc_eng_ni_reponse_num, (long) response); +} + + +static loc_name_val_s_type loc_eng_ni_encodings[] = +{ + NAME_VAL( GPS_ENC_NONE ), + NAME_VAL( GPS_ENC_SUPL_GSM_DEFAULT ), + NAME_VAL( GPS_ENC_SUPL_UTF8 ), + NAME_VAL( GPS_ENC_SUPL_UCS2 ), + NAME_VAL( GPS_ENC_UNKNOWN ) +}; +static int loc_eng_ni_encoding_num = sizeof(loc_eng_ni_encodings) / sizeof(loc_name_val_s_type); + +const char* loc_get_ni_encoding_name(GpsNiEncodingType encoding) +{ + return loc_get_name_from_val(loc_eng_ni_encodings, loc_eng_ni_encoding_num, (long) encoding); +} + +#ifdef QCOM_FEATURE_IPV6 +static loc_name_val_s_type loc_eng_agps_bears[] = +{ + NAME_VAL( AGPS_APN_BEARER_INVALID ), + NAME_VAL( AGPS_APN_BEARER_IPV4 ), + NAME_VAL( AGPS_APN_BEARER_IPV4 ), + NAME_VAL( AGPS_APN_BEARER_IPV4V6 ) +}; +static int loc_eng_agps_bears_num = sizeof(loc_eng_agps_bears) / sizeof(loc_name_val_s_type); + +const char* loc_get_agps_bear_name(AGpsBearerType bearer) +{ + return loc_get_name_from_val(loc_eng_agps_bears, loc_eng_agps_bears_num, (long) bearer); +} +#endif + +static loc_name_val_s_type loc_eng_server_types[] = +{ + NAME_VAL( LOC_AGPS_CDMA_PDE_SERVER ), + NAME_VAL( LOC_AGPS_CUSTOM_PDE_SERVER ), + NAME_VAL( LOC_AGPS_MPC_SERVER ), + NAME_VAL( LOC_AGPS_SUPL_SERVER ) +}; +static int loc_eng_server_types_num = sizeof(loc_eng_server_types) / sizeof(loc_name_val_s_type); + +const char* loc_get_server_type_name(LocServerType type) +{ + return loc_get_name_from_val(loc_eng_server_types, loc_eng_server_types_num, (long) type); +} + +static loc_name_val_s_type loc_eng_position_sess_status_types[] = +{ + NAME_VAL( LOC_SESS_SUCCESS ), + NAME_VAL( LOC_SESS_INTERMEDIATE ), + NAME_VAL( LOC_SESS_FAILURE ) +}; +static int loc_eng_position_sess_status_num = sizeof(loc_eng_position_sess_status_types) / sizeof(loc_name_val_s_type); + +const char* loc_get_position_sess_status_name(enum loc_sess_status status) +{ + return loc_get_name_from_val(loc_eng_position_sess_status_types, loc_eng_position_sess_status_num, (long) status); +} + +static loc_name_val_s_type loc_eng_agps_status_names[] = +{ + NAME_VAL( GPS_REQUEST_AGPS_DATA_CONN ), + NAME_VAL( GPS_RELEASE_AGPS_DATA_CONN ), + NAME_VAL( GPS_AGPS_DATA_CONNECTED ), + NAME_VAL( GPS_AGPS_DATA_CONN_DONE ), + NAME_VAL( GPS_AGPS_DATA_CONN_FAILED ) +}; +static int loc_eng_agps_status_num = sizeof(loc_eng_agps_status_names) / sizeof(loc_name_val_s_type); + +const char* loc_get_agps_status_name(AGpsStatusValue status) +{ + return loc_get_name_from_val(loc_eng_agps_status_names, loc_eng_agps_status_num, (long) status); +} diff --git a/loc_api/libloc_api_50001/loc_eng_log.h b/loc_api/libloc_api_50001/loc_eng_log.h new file mode 100755 index 00000000..eff1593b --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_log.h @@ -0,0 +1,62 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_ENG_LOG_H +#define LOC_ENG_LOG_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#include +#include +#include "loc_eng_msg_id.h" + +const char* loc_get_gps_status_name(GpsStatusValue gps_status); +const char* loc_get_msg_name(int id); +const char* loc_get_position_mode_name(GpsPositionMode mode); +const char* loc_get_position_recurrence_name(GpsPositionRecurrence recur); +const char* loc_get_aiding_data_mask_names(GpsAidingData data); +const char* loc_get_agps_type_name(AGpsType type); +const char* loc_get_ni_type_name(GpsNiType type); +const char* loc_get_ni_response_name(GpsUserResponseType response); +const char* loc_get_ni_encoding_name(GpsNiEncodingType encoding); +#ifdef QCOM_FEATURE_IPV6 +const char* loc_get_agps_bear_name(AGpsBearerType bear); +#endif +const char* loc_get_server_type_name(LocServerType type); +const char* loc_get_position_sess_status_name(enum loc_sess_status status); +const char* loc_get_agps_status_name(AGpsStatusValue status); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_ENG_LOG_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_msg.cpp b/loc_api/libloc_api_50001/loc_eng_msg.cpp new file mode 100755 index 00000000..97c0457c --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_msg.cpp @@ -0,0 +1,133 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +#include "loc_eng_msg.h" +#include "loc_eng_dmn_conn_glue_msg.h" + +#ifdef _ANDROID_ + +#define LOC_ENG_MSG_REQ_Q_PATH "/data/misc/gpsone_d/loc_eng_msg_req_q" + +#else + +#define LOC_ENG_MSG_REQ_Q_PATH "/tmp/loc_eng_msg_req_q" + +#endif + +int loc_eng_msgget(int * p_req_msgq) +{ + * p_req_msgq = loc_eng_dmn_conn_glue_msgget(LOC_ENG_MSG_REQ_Q_PATH, O_RDWR); + return 0; +} + +int loc_eng_msgremove(int req_msgq) +{ + loc_eng_dmn_conn_glue_piperemove(LOC_ENG_MSG_REQ_Q_PATH, req_msgq); + return 0; +} + +int loc_eng_msgsnd(int msgqid, void * msgp) +{ + int ret = loc_eng_dmn_conn_glue_pipewrite(msgqid, msgp, sizeof(void*)); + return ret; +} + +int loc_eng_msgsnd_raw(int msgqid, void * msgp, unsigned int msgsz) +{ + int result; + + struct msgbuf * pmsg = (struct msgbuf *) msgp; + + if (msgsz < sizeof(struct msgbuf)) { + LOC_LOGE("%s:%d] msgbuf is too small %d\n", __func__, __LINE__, msgsz); + return -1; + } + + pmsg->msgsz = msgsz; + + result = loc_eng_dmn_conn_glue_pipewrite(msgqid, msgp, msgsz); + if (result != (int) msgsz) { + LOC_LOGE("%s:%d] pipe broken %d, msgsz = %d\n", __func__, __LINE__, result, (int) msgsz); + return -1; + } + return result; +} + +int loc_eng_msgrcv(int msgqid, void ** msgp) +{ + int ret = loc_eng_dmn_conn_glue_piperead(msgqid, msgp, sizeof(void*)); + return ret; +} + +int loc_eng_msgrcv_raw(int msgqid, void *msgp, unsigned int msgsz) +{ + int result; + struct msgbuf * pmsg = (struct msgbuf *) msgp; + + if (msgsz < sizeof(struct msgbuf)) { + LOC_LOGE("%s:%d] msgbuf is too small %d\n", __func__, __LINE__, msgsz); + return -1; + } + + result = loc_eng_dmn_conn_glue_piperead(msgqid, msgp, sizeof(struct msgbuf)); + if (result != sizeof(struct msgbuf)) { + LOC_LOGE("%s:%d] pipe broken %d\n", __func__, __LINE__, result); + return -1; + } + + if (msgsz < pmsg->msgsz) { + LOC_LOGE("%s:%d] msgbuf is too small %d < %d\n", __func__, __LINE__, (int) msgsz, (int) pmsg->msgsz); + return -1; + } + + if (pmsg->msgsz > sizeof(struct msgbuf)) { + /* there is msg body */ + msgp += sizeof(struct msgbuf); + + result = loc_eng_dmn_conn_glue_piperead(msgqid, msgp, pmsg->msgsz - sizeof(struct msgbuf)); + + if (result != (int) (pmsg->msgsz - sizeof(struct msgbuf))) { + LOC_LOGE("%s:%d] pipe broken %d, msgid = %p, msgsz = %d\n", __func__, __LINE__, result, + (pmsg->msgid), (int) pmsg->msgsz); + return -1; + } + } + + return pmsg->msgsz; +} + +int loc_eng_msgflush(int msgqid) +{ + return loc_eng_dmn_conn_glue_msgflush(msgqid); +} + +int loc_eng_msgunblock(int msgqid) +{ + return loc_eng_dmn_conn_glue_pipeunblock(msgqid); +} diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h new file mode 100755 index 00000000..41548f09 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -0,0 +1,584 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_MSG_H +#define LOC_ENG_MSG_H + + +#include +#include +#include +#include "log_util.h" +#include "loc.h" +#include "loc_eng_log.h" +#include "loc_eng_msg_id.h" + + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct loc_eng_msg { + const void* owner; + const int msgid; + inline loc_eng_msg(void* instance, int id) : + owner(instance), msgid(id) + { + LOC_LOGV("creating msg %s", loc_get_msg_name(msgid)); + } + virtual ~loc_eng_msg() + { + LOC_LOGV("deleting msg %s", loc_get_msg_name(msgid)); + } +}; + +struct loc_eng_msg_suple_version : public loc_eng_msg { + const int supl_version; + inline loc_eng_msg_suple_version(void* instance, int version) : + loc_eng_msg(instance, LOC_ENG_MSG_SUPL_VERSION), + supl_version(version) + { + LOC_LOGV("SUPL Version: %d", version); + } +}; + +struct loc_eng_msg_sensor_control_config : public loc_eng_msg { + const int sensorsDisabled; + inline loc_eng_msg_sensor_control_config(void* instance, int disabled) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_CONTROL_CONFIG), + sensorsDisabled(disabled) + { + LOC_LOGV("Sensors Disabled: %d", disabled); + } +}; + +struct loc_eng_msg_sensor_properties : public loc_eng_msg { + const float gyroBiasVarianceRandomWalk; + inline loc_eng_msg_sensor_properties(void* instance, float gyroBiasRandomWalk) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_PROPERTIES), + gyroBiasVarianceRandomWalk(gyroBiasRandomWalk) + { + LOC_LOGV("Gyro Bias Random Walk: %f", gyroBiasRandomWalk); + } +}; + +struct loc_eng_msg_sensor_perf_control_config : public loc_eng_msg { + const int controlMode; + const int accelSamplesPerBatch; + const int accelBatchesPerSec; + const int gyroSamplesPerBatch; + const int gyroBatchesPerSec; + inline loc_eng_msg_sensor_perf_control_config(void* instance, int controlMode, + int accelSamplesPerBatch, int accelBatchesPerSec, + int gyroSamplesPerBatch, int gyroBatchesPerSec) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG), + controlMode(controlMode), + accelSamplesPerBatch(accelSamplesPerBatch), + accelBatchesPerSec(accelBatchesPerSec), + gyroSamplesPerBatch(gyroSamplesPerBatch), + gyroBatchesPerSec(gyroBatchesPerSec) + { + LOC_LOGV("Sensor Perf Control Config (performanceControlMode)(%u) " + "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u)\n", + controlMode, + accelSamplesPerBatch, + accelBatchesPerSec, + gyroSamplesPerBatch, + gyroBatchesPerSec + ); + } +}; + + +struct loc_eng_msg_position_mode : public loc_eng_msg { + const LocPositionMode pMode; + const GpsPositionRecurrence pRecurrence; + const uint32_t minInterval; + const uint32_t preferredAccuracy; + const uint32_t preferredTime; + inline loc_eng_msg_position_mode() : + loc_eng_msg(NULL, LOC_ENG_MSG_SET_POSITION_MODE), + pMode(LOC_POSITION_MODE_STANDALONE), + pRecurrence(0), minInterval(0), + preferredAccuracy(0), preferredTime(0) {} + inline loc_eng_msg_position_mode(void* instance, + LocPositionMode mode, + GpsPositionRecurrence recurrence, + uint32_t min_interval, + uint32_t preferred_accuracy, + uint32_t preferred_time) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_POSITION_MODE), + pMode(mode), pRecurrence(recurrence), minInterval(min_interval), + preferredAccuracy(preferred_accuracy), preferredTime(preferred_time) + { + LOC_LOGV("Position mode: %s\n Position recurrence: %s\n min interval: %d\n preferred accuracy: %d\n preferred time: %d", + loc_get_position_mode_name(pMode), + loc_get_position_recurrence_name(pRecurrence), + minInterval, + preferredAccuracy, + preferredTime); + } +}; + +struct loc_eng_msg_set_time : public loc_eng_msg { + const GpsUtcTime time; + const int64_t timeReference; + const int uncertainty; + inline loc_eng_msg_set_time(void* instance, + GpsUtcTime t, + int64_t tf, + int unc) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_TIME), + time(t), timeReference(tf), uncertainty(unc) + { + LOC_LOGV("time: %lld\n timeReference: %lld\n uncertainty: %d", + time, timeReference, uncertainty); + } +}; + +struct loc_eng_msg_inject_location : public loc_eng_msg { + const double latitude; + const double longitude; + const float accuracy; + inline loc_eng_msg_inject_location(void* instance, double lat, + double longi, float accur) : + loc_eng_msg(instance, LOC_ENG_MSG_INJECT_LOCATION), + latitude(lat), longitude(longi), accuracy(accur) + { + LOC_LOGV("latitude: %f\n longitude: %f\n accuracy: %f", + latitude, longitude, accuracy); + } +}; + +struct loc_eng_msg_delete_aiding_data : public loc_eng_msg { + const GpsAidingData type; + inline loc_eng_msg_delete_aiding_data(void* instance, GpsAidingData data) : + loc_eng_msg(instance, LOC_ENG_MSG_DELETE_AIDING_DATA), type(data) + { + LOC_LOGV("aiding data msak %d", type); + } +}; + +struct loc_eng_msg_report_position : public loc_eng_msg { + const GpsLocation location; + const void* locationExt; + const enum loc_sess_status status; + inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, void* locExt, + enum loc_sess_status st) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), + location(loc), locationExt(locExt), status(st) + { +#ifdef QCOM_FEATURE_ULP + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %s", + location.flags, location.position_source, location.latitude, location.longitude, + location.altitude, location.speed, location.bearing, location.accuracy, + location.timestamp, location.rawDataSize, location.rawData, + loc_get_position_sess_status_name(status)); +#else + LOC_LOGV("flags: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n Session status: %s", + location.flags, location.latitude, location.longitude, + location.altitude, location.speed, location.bearing, location.accuracy, + location.timestamp, loc_get_position_sess_status_name(status)); +#endif + } +}; + +struct loc_eng_msg_report_sv : public loc_eng_msg { + const GpsSvStatus svStatus; + const void* svExt; + inline loc_eng_msg_report_sv(void* instance, GpsSvStatus &sv, void* ext) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_SV), svStatus(sv), svExt(ext) + { + LOC_LOGV("num sv: %d\n ephemeris mask: %dxn almanac mask: %x\n used in fix mask: %x\n sv: prn snr elevation azimuth", + svStatus.num_svs, svStatus.ephemeris_mask, svStatus.almanac_mask, svStatus.used_in_fix_mask); + for (int i = 0; i < svStatus.num_svs && i < GPS_MAX_SVS; i++) { + LOC_LOGV(" %d: %d %f %f %f\n ", + i, + svStatus.sv_list[i].prn, + svStatus.sv_list[i].snr, + svStatus.sv_list[i].elevation, + svStatus.sv_list[i].azimuth); + } + } +}; + +struct loc_eng_msg_report_status : public loc_eng_msg { + const GpsStatusValue status; + inline loc_eng_msg_report_status(void* instance, GpsStatusValue engineStatus) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_STATUS), status(engineStatus) + { + LOC_LOGV("status: %s", loc_get_gps_status_name(status)); + } +}; + +struct loc_eng_msg_report_nmea : public loc_eng_msg { + char* const nmea; + const int length; + inline loc_eng_msg_report_nmea(void* instance, + const char* data, + int len) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_NMEA), + nmea(new char[len]), length(len) + { + memcpy((void*)nmea, (void*)data, len); + LOC_LOGV("length: %d\n nmea: %p - %c%c%c", + length, nmea, nmea[3], nmea[4], nmea[5]); + } + inline ~loc_eng_msg_report_nmea() + { + delete[] nmea; + } +}; + +struct loc_eng_msg_request_bit : public loc_eng_msg { + const unsigned int isSupl; + const int ipv4Addr; + char* const ipv6Addr; + inline loc_eng_msg_request_bit(void* instance, + unsigned int is_supl, + int ipv4, + char* ipv6) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_BIT), + isSupl(is_supl), ipv4Addr(ipv4), + ipv6Addr(NULL == ipv6 ? NULL : new char[16]) + { + if (NULL != ipv6Addr) + memcpy(ipv6Addr, ipv6, 16); + LOC_LOGV("isSupl: %d, ipv4: %d.%d.%d.%d, ipv6: %s", isSupl, + (unsigned char)ipv4>>24, + (unsigned char)ipv4>>16, + (unsigned char)ipv4>>8, + (unsigned char)ipv4, + NULL != ipv6Addr ? ipv6Addr : ""); + } + + inline ~loc_eng_msg_request_bit() + { + if (NULL != ipv6Addr) { + delete[] ipv6Addr; + } + } +}; + +struct loc_eng_msg_release_bit : public loc_eng_msg { + const unsigned int isSupl; + const int ipv4Addr; + char* const ipv6Addr; + inline loc_eng_msg_release_bit(void* instance, + unsigned int is_supl, + int ipv4, + char* ipv6) : + loc_eng_msg(instance, LOC_ENG_MSG_RELEASE_BIT), + isSupl(is_supl), ipv4Addr(ipv4), + ipv6Addr(NULL == ipv6 ? NULL : new char[16]) + { + if (NULL != ipv6Addr) + memcpy(ipv6Addr, ipv6, 16); + LOC_LOGV("isSupl: %d, ipv4: %d.%d.%d.%d, ipv6: %s", isSupl, + (unsigned char)ipv4>>24, + (unsigned char)ipv4>>16, + (unsigned char)ipv4>>8, + (unsigned char)ipv4, + NULL != ipv6Addr ? ipv6Addr : ""); + } + + inline ~loc_eng_msg_release_bit() + { + if (NULL != ipv6Addr) { + delete[] ipv6Addr; + } + } +}; + +struct loc_eng_msg_request_atl : public loc_eng_msg { + const int handle; + const AGpsType type; + inline loc_eng_msg_request_atl(void* instance, int hndl, + AGpsType agps_type) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_ATL), + handle(hndl), type(agps_type) + { + LOC_LOGV("handle: %d\n agps type: %s", + handle, + loc_get_agps_type_name(type)); + } +}; + +struct loc_eng_msg_release_atl : public loc_eng_msg { + const int handle; + inline loc_eng_msg_release_atl(void* instance, int hndl) : + loc_eng_msg(instance, LOC_ENG_MSG_RELEASE_ATL), handle(hndl) + { + LOC_LOGV("handle: %d", handle); + } +}; + +struct loc_eng_msg_request_ni : public loc_eng_msg { + const GpsNiNotification notify; + const void *passThroughData; + inline loc_eng_msg_request_ni(void* instance, + GpsNiNotification ¬if, const void* data) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_NI), + notify(notif), passThroughData(data) + { + LOC_LOGV("id: %d\n type: %s\n flags: %d\n time out: %d\n default response: %s\n requestor id encoding: %s\n text encoding: %s\n passThroughData: %p", + notify.notification_id, + loc_get_ni_type_name(notify.ni_type), + notify.notify_flags, + notify.timeout, + loc_get_ni_response_name(notify.default_response), + loc_get_ni_encoding_name(notify.requestor_id_encoding), + loc_get_ni_encoding_name(notify.text_encoding), + passThroughData); + } +}; + +struct loc_eng_msg_inform_ni_response : public loc_eng_msg { + const GpsUserResponseType response; + const void *passThroughData; + inline loc_eng_msg_inform_ni_response(void* instance, + GpsUserResponseType resp, + const void* data) : + loc_eng_msg(instance, LOC_ENG_MSG_INFORM_NI_RESPONSE), + response(resp), passThroughData(data) + { + LOC_LOGV("response: %s\n passThroughData: %p", + loc_get_ni_response_name(response), + passThroughData); + } + inline ~loc_eng_msg_inform_ni_response() + { + // this is a bit weird since passThroughData is not + // allocated by this class. But there is no better way. + // passThroughData actually won't be NULL here. + // But better safer than sorry. + if (NULL != passThroughData) { + free((void*)passThroughData); + } + } +}; + +struct loc_eng_msg_set_apn : public loc_eng_msg { + char* const apn; + inline loc_eng_msg_set_apn(void* instance, const char* name, int len) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_APN), + apn(new char[len+1]) + { + memcpy((void*)apn, (void*)name, len); + apn[len] = 0; + LOC_LOGV("apn: %s", apn); + } + inline ~loc_eng_msg_set_apn() + { + delete[] apn; + } +}; + + + +struct loc_eng_msg_set_server_ipv4 : public loc_eng_msg { + const unsigned int nl_addr; + const int port; + const LocServerType serverType; + inline loc_eng_msg_set_server_ipv4(void* instance, + unsigned int ip, + int p, + LocServerType type) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_SERVER_IPV4), + nl_addr(ip), port(p), serverType(type) + { + LOC_LOGV("addr: %x\n , port: %d\n type: %s", nl_addr, port, loc_get_server_type_name(serverType)); + } +}; + + +struct loc_eng_msg_set_server_url : public loc_eng_msg { + const int len; + char* const url; + inline loc_eng_msg_set_server_url(void* instance, + const char* urlString, + int url_len) : + loc_eng_msg(instance, LOC_ENG_MSG_SET_SERVER_URL), + len(url_len), url(new char[len+1]) + { + memcpy((void*)url, (void*)urlString, url_len); + url[len] = 0; + LOC_LOGV("url: %s", url); + } + inline ~loc_eng_msg_set_server_url() + { + delete[] url; + } +}; + +struct loc_eng_msg_inject_xtra_data : public loc_eng_msg { + char* const data; + const int length; + inline loc_eng_msg_inject_xtra_data(void* instance, char* d, int l) : + loc_eng_msg(instance, LOC_ENG_MSG_INJECT_XTRA_DATA), + data(new char[l]), length(l) + { + memcpy((void*)data, (void*)d, l); + LOC_LOGV("length: %d\n data: %p", length, data); + } + inline ~loc_eng_msg_inject_xtra_data() + { + delete[] data; + } +}; + +#ifdef QCOM_FEATURE_IPV6 +struct loc_eng_msg_atl_open_success : public loc_eng_msg { + const AGpsStatusValue agpsType; + const int length; + char* const apn; + const AGpsBearerType bearerType; + inline loc_eng_msg_atl_open_success(void* instance, + AGpsStatusValue atype, + const char* name, + int len, + AGpsBearerType btype) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_SUCCESS), + agpsType(atype), length(len), + apn(new char[len+1]), bearerType(btype) + { + memcpy((void*)apn, (void*)name, len); + apn[len] = 0; + LOC_LOGV("agps type: %s\n apn: %s\n bearer type: %s", + loc_get_agps_type_name(agpsType), + apn, + loc_get_agps_bear_name(bearerType)); + } + inline ~loc_eng_msg_atl_open_success() + { + delete[] apn; + } +}; +#else +struct loc_eng_msg_atl_open_success : public loc_eng_msg { + const int length; + char* const apn; + inline loc_eng_msg_atl_open_success(void* instance, + const char* name, + int len) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_SUCCESS), + length(len), + apn(new char[len+1]) + { + memcpy((void*)apn, (void*)name, len); + apn[len] = 0; + LOC_LOGV("apn: %s\n", + apn); + } + inline ~loc_eng_msg_atl_open_success() + { + delete[] apn; + } +}; +#endif + +#ifdef QCOM_FEATURE_IPV6 +struct loc_eng_msg_atl_open_failed : public loc_eng_msg { + const AGpsStatusValue agpsType; + inline loc_eng_msg_atl_open_failed(void* instance, + AGpsStatusValue atype) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_FAILED), + agpsType(atype) + { + LOC_LOGV("agps type %s", + loc_get_agps_type_name(agpsType)); + } +}; +#else +struct loc_eng_msg_atl_open_failed : public loc_eng_msg { + inline loc_eng_msg_atl_open_failed(void* instance) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_FAILED) + { + LOC_LOGV(""); + } +}; +#endif + +#ifdef QCOM_FEATURE_IPV6 +struct loc_eng_msg_atl_closed : public loc_eng_msg { + const AGpsStatusValue agpsType; + inline loc_eng_msg_atl_closed(void* instance, + AGpsStatusValue atype) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_CLOSED), + agpsType(atype) + { + LOC_LOGV("agps type %s", + loc_get_agps_type_name(agpsType)); + } +}; +#else +struct loc_eng_msg_atl_closed : public loc_eng_msg { + inline loc_eng_msg_atl_closed(void* instance) : + loc_eng_msg(instance, LOC_ENG_MSG_ATL_CLOSED) + { + LOC_LOGV(""); + } +}; +#endif + +struct loc_eng_msg_set_data_enable : public loc_eng_msg { + const int enable; + char* const apn; + const int length; + inline loc_eng_msg_set_data_enable(void* instance, + const char* name, + int len, + int yes) : + loc_eng_msg(instance, LOC_ENG_MSG_ENABLE_DATA), + enable(yes), apn(new char[len+1]), length(len) + { + memcpy((void*)apn, (void*)name, len); + apn[len] = 0; + LOC_LOGV("apn: %s\n enable: %d", apn, enable); + } + inline ~loc_eng_msg_set_data_enable() + { + delete[] apn; + } +}; + +void loc_eng_msg_sender(void* loc_eng_data_p, void* msg); +int loc_eng_msgget(int * p_req_msgq); +int loc_eng_msgremove(int req_msgq); +int loc_eng_msgsnd(int msgqid, void * msgp); +int loc_eng_msgrcv(int msgqid, void ** msgp); +int loc_eng_msgsnd_raw(int msgqid, void * msgp, unsigned int msgsz); +int loc_eng_msgrcv_raw(int msgqid, void *msgp, unsigned int msgsz); +int loc_eng_msgflush(int msgqid); +int loc_eng_msgunblock(int msgqid); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* LOC_ENG_MSG_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_msg_id.h b/loc_api/libloc_api_50001/loc_eng_msg_id.h new file mode 100755 index 00000000..f05f1f44 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_msg_id.h @@ -0,0 +1,90 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_ENG_MSG_ID_H +#define LOC_ENG_MSG_ID_H + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct msgbuf { + unsigned int msgsz; + void* msgid; +}; + +enum loc_eng_msg_ids_t { + /* 0x 0 - 0xEF is reserved for daemon internal */ + /* 0xF0 - 0x1FF is reserved for daemon & framework communication */ + LOC_ENG_MSG_QUIT = 0x200, + + LOC_ENG_MSG_ENGINE_DOWN, + LOC_ENG_MSG_ENGINE_UP, + + LOC_ENG_MSG_START_FIX, + LOC_ENG_MSG_STOP_FIX, + LOC_ENG_MSG_SET_POSITION_MODE, + LOC_ENG_MSG_SET_TIME, + LOC_ENG_MSG_INJECT_XTRA_DATA, + LOC_ENG_MSG_INJECT_LOCATION, + LOC_ENG_MSG_DELETE_AIDING_DATA, + LOC_ENG_MSG_SET_APN, + LOC_ENG_MSG_SET_SERVER_URL, + LOC_ENG_MSG_SET_SERVER_IPV4, + LOC_ENG_MSG_ENABLE_DATA, + + LOC_ENG_MSG_SUPL_VERSION, + LOC_ENG_MSG_SET_SENSOR_CONTROL_CONFIG, + LOC_ENG_MSG_SET_SENSOR_PROPERTIES, + LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG, + LOC_ENG_MSG_MUTE_SESSION, + + LOC_ENG_MSG_ATL_OPEN_SUCCESS, + LOC_ENG_MSG_ATL_CLOSED, + LOC_ENG_MSG_ATL_OPEN_FAILED, + + LOC_ENG_MSG_REPORT_POSITION, + LOC_ENG_MSG_REPORT_SV, + LOC_ENG_MSG_REPORT_STATUS, + LOC_ENG_MSG_REPORT_NMEA, + LOC_ENG_MSG_REQUEST_BIT, + LOC_ENG_MSG_RELEASE_BIT, + LOC_ENG_MSG_REQUEST_ATL, + LOC_ENG_MSG_RELEASE_ATL, + LOC_ENG_MSG_REQUEST_NI, + LOC_ENG_MSG_INFORM_NI_RESPONSE, + LOC_ENG_MSG_REQUEST_XTRA_DATA, + LOC_ENG_MSG_REQUEST_TIME, + LOC_ENG_MSG_REQUEST_POSITION +}; + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* LOC_ENG_MSG_ID_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_ni.cpp b/loc_api/libloc_api_50001/loc_eng_ni.cpp new file mode 100755 index 00000000..c2d78af8 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_ni.cpp @@ -0,0 +1,313 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng" + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include "log_util.h" + +/*============================================================================= + * + * DATA DECLARATION + * + *============================================================================*/ + +/*============================================================================= + * + * FUNCTION DECLARATIONS + * + *============================================================================*/ +static void* ni_thread_proc(void *args); + +/*=========================================================================== + +FUNCTION loc_eng_ni_request_handler + +DESCRIPTION + Displays the NI request and awaits user input. If a previous request is + in session, it is ignored. + +RETURN VALUE + none + +===========================================================================*/ +void loc_eng_ni_request_handler(loc_eng_data_s_type &loc_eng_data, + const GpsNiNotification *notif, + const void* passThrough) +{ + ENTRY_LOG(); + char lcs_addr[32]; // Decoded LCS address for UMTS CP NI + loc_eng_ni_data_s_type* loc_eng_ni_data_p = &loc_eng_data.loc_eng_ni_data; + + if (NULL == loc_eng_data.ni_notify_cb) { + EXIT_LOG(%s, "loc_eng_ni_init hasn't happened yet."); + return; + } + + /* If busy, use default or deny */ + if (NULL != loc_eng_ni_data_p->rawRequest) + { + /* XXX Consider sending a NO RESPONSE reply or queue the request */ + LOC_LOGW("loc_eng_ni_request_handler, notification in progress, new NI request ignored, type: %d", + notif->ni_type); + if (NULL != passThrough) { + free((void*)passThrough); + } + } + else { + /* Save request */ + loc_eng_ni_data_p->rawRequest = (void*)passThrough; + + /* Fill in notification */ + ((GpsNiNotification*)notif)->notification_id = loc_eng_ni_data_p->reqID; + + if (notif->notify_flags == GPS_NI_PRIVACY_OVERRIDE) + { + loc_eng_mute_one_session(loc_eng_data); + } + + /* Log requestor ID and text for debugging */ + LOC_LOGI("Notification: notif_type: %d, timeout: %d, default_resp: %d", notif->ni_type, notif->timeout, notif->default_response); + LOC_LOGI(" requestor_id: %s (encoding: %d)", notif->requestor_id, notif->requestor_id_encoding); + LOC_LOGI(" text: %s text (encoding: %d)", notif->text, notif->text_encoding); + if (notif->extras[0]) + { + LOC_LOGI(" extras: %s", notif->extras); + } + + /* For robustness, spawn a thread at this point to timeout to clear up the notification status, even though + * the OEM layer in java does not do so. + **/ + loc_eng_ni_data_p->respTimeLeft = 5 + (notif->timeout != 0 ? notif->timeout : LOC_NI_NO_RESPONSE_TIME); + LOC_LOGI("Automatically sends 'no response' in %d seconds (to clear status)\n", loc_eng_ni_data_p->respTimeLeft); + + int rc = 0; + rc = pthread_create(&loc_eng_ni_data_p->thread, NULL, ni_thread_proc, &loc_eng_data); + if (rc) + { + LOC_LOGE("Loc NI thread is not created.\n"); + } + rc = pthread_detach(loc_eng_ni_data_p->thread); + if (rc) + { + LOC_LOGE("Loc NI thread is not detached.\n"); + } + + CALLBACK_LOG_CALLFLOW("ni_notify_cb - id", %d, notif->notification_id); + loc_eng_data.ni_notify_cb((GpsNiNotification*)notif); + } + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== + +FUNCTION ni_thread_proc + +===========================================================================*/ +static void* ni_thread_proc(void *args) +{ + ENTRY_LOG(); + + loc_eng_data_s_type* loc_eng_data_p = (loc_eng_data_s_type*)args; + loc_eng_ni_data_s_type* loc_eng_ni_data_p = &loc_eng_data_p->loc_eng_ni_data; + int rc = 0; /* return code from pthread calls */ + + struct timeval present_time; + struct timespec expire_time; + + LOC_LOGD("Starting Loc NI thread...\n"); + pthread_mutex_lock(&loc_eng_ni_data_p->tLock); + /* Calculate absolute expire time */ + gettimeofday(&present_time, NULL); + expire_time.tv_sec = present_time.tv_sec + loc_eng_ni_data_p->respTimeLeft; + expire_time.tv_nsec = present_time.tv_usec * 1000; + LOC_LOGD("ni_thread_proc-Time out set for abs time %ld with delay %d sec\n", + (long) expire_time.tv_sec, loc_eng_ni_data_p->respTimeLeft ); + + while (!loc_eng_ni_data_p->respRecvd) + { + rc = pthread_cond_timedwait(&loc_eng_ni_data_p->tCond, + &loc_eng_ni_data_p->tLock, + &expire_time); + if (rc == ETIMEDOUT) + { + loc_eng_ni_data_p->resp = GPS_NI_RESPONSE_NORESP; + LOC_LOGD("ni_thread_proc-Thread time out after valting for specified time. Ret Val %d\n",rc ); + break; + } + } + LOC_LOGD("ni_thread_proc-Java layer has sent us a user response and return value from " + "pthread_cond_timedwait = %d\n",rc ); + loc_eng_ni_data_p->respRecvd = FALSE; /* Reset the user response flag for the next session*/ + + // adding this check to support modem restart, in which case, we need the thread + // to exit without calling sending data to loc_eng_msg_q. We made sure that + // rawRequest is NULL in loc_eng_ni_reset_on_engine_restart() + loc_eng_msg_inform_ni_response *msg = NULL; + + if (NULL != loc_eng_ni_data_p->rawRequest) { + loc_eng_data_s_type *loc_eng_data_p = (loc_eng_data_s_type*)args; + msg = new loc_eng_msg_inform_ni_response(loc_eng_data_p, + loc_eng_ni_data_p->resp, + loc_eng_ni_data_p->rawRequest); + loc_eng_ni_data_p->rawRequest = NULL; + } + pthread_mutex_unlock(&loc_eng_ni_data_p->tLock); + + loc_eng_ni_data_p->respTimeLeft = 0; + loc_eng_ni_data_p->reqID++; + + if (NULL != msg) { + loc_eng_msg_sender(loc_eng_data_p, msg); + } + + EXIT_LOG(%s, VOID_RET); + return NULL; +} + +void loc_eng_ni_reset_on_engine_restart(loc_eng_data_s_type &loc_eng_data) +{ + ENTRY_LOG(); + loc_eng_ni_data_s_type* loc_eng_ni_data_p = &loc_eng_data.loc_eng_ni_data; + + if (NULL == loc_eng_data.ni_notify_cb) { + EXIT_LOG(%s, "loc_eng_ni_init hasn't happened yet."); + return; + } + + // only if modem has requested but then died. + if (NULL != loc_eng_ni_data_p->rawRequest) { + free(loc_eng_ni_data_p->rawRequest); + loc_eng_ni_data_p->rawRequest = NULL; + + pthread_mutex_lock(&loc_eng_ni_data_p->tLock); + // the goal is to wake up ni_thread_proc + // and let it exit. + loc_eng_ni_data_p->respRecvd = TRUE; + pthread_cond_signal(&loc_eng_ni_data_p->tCond); + pthread_mutex_unlock(&loc_eng_ni_data_p->tLock); + } + + EXIT_LOG(%s, VOID_RET); +} + +/*=========================================================================== +FUNCTION loc_eng_ni_init + +DESCRIPTION + This function initializes the NI interface + +DEPENDENCIES + NONE + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_ni_init(loc_eng_data_s_type &loc_eng_data, GpsNiCallbacks *callbacks) +{ + ENTRY_LOG_CALLFLOW(); + + if (NULL == callbacks->notify_cb) { + EXIT_LOG(%s, "loc_eng_ni_init: failed, no cb."); + } else if (NULL != loc_eng_data.ni_notify_cb) { + EXIT_LOG(%s, "loc_eng_ni_init: already inited."); + } else { + loc_eng_ni_data_s_type* loc_eng_ni_data_p = &loc_eng_data.loc_eng_ni_data; + loc_eng_ni_data_p->respTimeLeft = 0; + loc_eng_ni_data_p->respRecvd = FALSE; + loc_eng_ni_data_p->rawRequest = NULL; + loc_eng_ni_data_p->reqID = 0; + pthread_cond_init(&loc_eng_ni_data_p->tCond, NULL); + pthread_mutex_init(&loc_eng_ni_data_p->tLock, NULL); + + loc_eng_data.ni_notify_cb = callbacks->notify_cb; + EXIT_LOG(%s, VOID_RET); + } +} + +/*=========================================================================== +FUNCTION loc_eng_ni_respond + +DESCRIPTION + This function receives user response from upper layer framework + +DEPENDENCIES + NONE + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_ni_respond(loc_eng_data_s_type &loc_eng_data, + int notif_id, GpsUserResponseType user_response) +{ + ENTRY_LOG_CALLFLOW(); + loc_eng_ni_data_s_type* loc_eng_ni_data_p = &loc_eng_data.loc_eng_ni_data; + + if (NULL == loc_eng_data.ni_notify_cb) { + EXIT_LOG(%s, "loc_eng_ni_init hasn't happened yet."); + return; + } + + if (notif_id == loc_eng_ni_data_p->reqID && + NULL != loc_eng_ni_data_p->rawRequest) + { + LOC_LOGI("loc_eng_ni_respond: send user response %d for notif %d", user_response, notif_id); + pthread_mutex_lock(&loc_eng_ni_data_p->tLock); + loc_eng_ni_data_p->resp = user_response; + loc_eng_ni_data_p->respRecvd = TRUE; + pthread_cond_signal(&loc_eng_ni_data_p->tCond); + pthread_mutex_unlock(&loc_eng_ni_data_p->tLock); + } + else { + LOC_LOGE("loc_eng_ni_respond: reqID %d and notif_id %d mismatch or rawRequest %p, response: %d", + loc_eng_ni_data_p->reqID, notif_id, loc_eng_ni_data_p->rawRequest, user_response); + } + + EXIT_LOG(%s, VOID_RET); +} diff --git a/loc_api/libloc_api_50001/loc_eng_ni.h b/loc_api/libloc_api_50001/loc_eng_ni.h new file mode 100755 index 00000000..9b1c5f34 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_ni.h @@ -0,0 +1,50 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_ENG_NI_H +#define LOC_ENG_NI_H + +#include + +#define LOC_NI_NO_RESPONSE_TIME 20 /* secs */ +#define LOC_NI_NOTIF_KEY_ADDRESS "Address" + +typedef struct { + pthread_t thread; /* NI thread */ + int respTimeLeft; /* examine time for NI response */ + bool respRecvd; /* NI User reponse received or not from Java layer*/ + void* rawRequest; + int reqID; /* ID to check against response */ + GpsUserResponseType resp; + pthread_cond_t tCond; + pthread_mutex_t tLock; +} loc_eng_ni_data_s_type; + + +#endif /* LOC_ENG_NI_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_xtra.cpp b/loc_api/libloc_api_50001/loc_eng_xtra.cpp new file mode 100755 index 00000000..ebc7c6fb --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_xtra.cpp @@ -0,0 +1,90 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng" + +#include +#include +#include "log_util.h" + + +/*=========================================================================== +FUNCTION loc_eng_xtra_init + +DESCRIPTION + Initialize XTRA module. + +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_xtra_init (loc_eng_data_s_type &loc_eng_data, + GpsXtraCallbacks* callbacks) +{ + loc_eng_xtra_data_s_type *xtra_module_data_ptr; + + xtra_module_data_ptr = &loc_eng_data.xtra_module_data; + xtra_module_data_ptr->download_request_cb = callbacks->download_request_cb; + + return 0; +} + +/*=========================================================================== +FUNCTION loc_eng_xtra_inject_data + +DESCRIPTION + Injects XTRA file into the engine but buffers the data if engine is busy. + +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + >0: failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_xtra_inject_data(loc_eng_data_s_type &loc_eng_data, + char* data, int length) +{ + loc_eng_msg_inject_xtra_data *msg(new loc_eng_msg_inject_xtra_data(&loc_eng_data, + data, length)); + loc_eng_msg_sender(&loc_eng_data, msg); + + return 0; +} diff --git a/loc_api/libloc_api_50001/loc_eng_xtra.h b/loc_api/libloc_api_50001/loc_eng_xtra.h new file mode 100755 index 00000000..7e01e146 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_xtra.h @@ -0,0 +1,46 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_ENG_XTRA_H +#define LOC_ENG_XTRA_H + +#include + +// Module data +typedef struct +{ + // loc_eng_ioctl_cb_data_s_type ioctl_cb_data; + gps_xtra_download_request download_request_cb; + + // XTRA data buffer + char *xtra_data_for_injection; // NULL if no pending data + int xtra_data_len; +} loc_eng_xtra_data_s_type; + +#endif // LOC_ENG_XTRA_H diff --git a/loc_api/loc_api_v02/Android.mk b/loc_api/loc_api_v02/Android.mk new file mode 100755 index 00000000..b6c7a66e --- /dev/null +++ b/loc_api/loc_api_v02/Android.mk @@ -0,0 +1,43 @@ +ifneq ($(BUILD_TINY_ANDROID),true) + +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_MODULE := libloc_api_v02 + +LOCAL_MODULE_TAGS := optional + +LOCAL_SHARED_LIBRARIES := \ + libutils \ + libcutils \ + libqmi_cci \ + libqmi_csi \ + libqmi_common_so \ + libloc_adapter \ + libgps.utils + +LOCAL_SRC_FILES += \ + LocApiV02Adapter.cpp \ + loc_api_v02_log.c \ + loc_api_v02_client.c \ + loc_api_sync_req.c \ + location_service_v02.c + +LOCAL_CFLAGS += \ + -fno-short-enums \ + -D_ANDROID_ + +## Includes +LOCAL_C_INCLUDES := \ + $(TOP)/vendor/qcom/proprietary/qmi-framework/inc \ + $(TOP)/vendor/qcom/proprietary/qmi-framework/qcci/inc \ + $(TOP)/vendor/qcom/proprietary/qmi-framework/common/inc \ + $(TARGET_OUT_HEADERS)/libloc_eng \ + $(TARGET_OUT_HEADERS)/gps.utils + +LOCAL_PRELINK_MODULE := false + +include $(BUILD_SHARED_LIBRARY) + +endif # not BUILD_TINY_ANDROID diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp new file mode 100755 index 00000000..e223983b --- /dev/null +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -0,0 +1,2056 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include + +#include +#include +#include "LocApiV02Adapter.h" +#include "loc_api_v02_client.h" +#include "loc_api_v02_log.h" +#include "loc_api_sync_req.h" +#include "LocApiAdapter.h" + +#define LOG_NDEBUG 0 +#define LOG_TAG "LocSvc_adapter" +#include "loc_util_log.h" + + +/* Default session id ; TBD needs incrementing for each */ +#define LOC_API_V02_DEF_SESSION_ID (1) + +/* Default minimium interval in ms */ +#define LOC_API_V02_DEF_MIN_INTERVAL (1000) + +/* Default horizontal accuracy in meters*/ +#define LOC_API_V02_DEF_HORZ_ACCURACY (50) + +/* Default timeout in ms; TBD: needs implementing */ +#define LOC_API_V02_DEF_TIMEOUT (120000) + +/* UMTS CP Address key*/ +#define LOC_NI_NOTIF_KEY_ADDRESS "Address" + +/* GPS SV Id offset */ +#define GPS_SV_ID_OFFSET (1) + +/* GLONASS SV Id offset */ +#define GLONASS_SV_ID_OFFSET (65) + +/* SV ID range */ +#define SV_ID_RANGE (32) + + + +/* static event callbacks that call the LocApiV02Adapter callbacks*/ + +/* global event callback, call the eventCb function in loc api adapter v02 + instance */ +static void globalEventCb(locClientHandleType clientHandle, + uint32_t eventId, + const locClientEventIndUnionType eventPayload, + void* pClientCookie) +{ + MODEM_LOG_CALLFLOW(%s, loc_get_v02_event_name(eventId)); + LocApiV02Adapter *locApiV02AdapterInstance = + (LocApiV02Adapter *)pClientCookie; + + LOC_LOGV ("%s:%d] client = %p, event id = %d, client cookie ptr = %p\n", + __func__, __LINE__, clientHandle, eventId, pClientCookie); + + // return if null is passed + if( NULL == locApiV02AdapterInstance) + { + LOC_LOGE ("%s:%d] NULL object passed : client = %p, event id = %d\n", + __func__, __LINE__, clientHandle, eventId); + return; + } + locApiV02AdapterInstance->eventCb(clientHandle, + eventId, + eventPayload); +} + +/* global response callback, it calls the sync request process + indication function to unblock the request that is waiting on this + response indication*/ +static void globalRespCb(locClientHandleType clientHandle, + uint32_t respId, + const locClientRespIndUnionType respPayload, + void* pClientCookie) +{ + MODEM_LOG_CALLFLOW(%s, loc_get_v02_event_name(respId)); + LocApiV02Adapter *locApiV02AdapterInstance = + (LocApiV02Adapter *)pClientCookie; + + + LOC_LOGV ("%s:%d] client = %p, resp id = %d, client cookie ptr = %p\n", + __func__, __LINE__, clientHandle, respId, pClientCookie); + + if( NULL == locApiV02AdapterInstance) + { + LOC_LOGE ("%s:%d] NULL object passed : client = %p, resp id = %d\n", + __func__, __LINE__, clientHandle, respId); + return; + } + // process the sync call + // use pDeleteAssistDataInd as a dummy pointer + loc_sync_process_ind(clientHandle, respId, + (void *)respPayload.pDeleteAssistDataInd); +} + +/* global error callback, it will call the handle service down + function in the loc api adapter instance. */ +static void globalErrorCb (locClientHandleType clientHandle, + locClientErrorEnumType errorId, + void *pClientCookie) +{ + LocApiV02Adapter *locApiV02AdapterInstance = + (LocApiV02Adapter *)pClientCookie; + + LOC_LOGV ("%s:%d] client = %p, error id = %d\n, client cookie ptr = %p\n", + __func__, __LINE__, clientHandle, errorId, pClientCookie); + if( NULL == locApiV02AdapterInstance) + { + LOC_LOGE ("%s:%d] NULL object passed : client = %p, error id = %d\n", + __func__, __LINE__, clientHandle, errorId); + return; + } + locApiV02AdapterInstance->errorCb(clientHandle, + errorId); +} + +/* global structure containing the callbacks */ +locClientCallbacksType globalCallbacks = +{ + sizeof(locClientCallbacksType), + globalEventCb, + globalRespCb, + globalErrorCb +}; + +/* Constructor for LocApiV02Adapter */ +LocApiV02Adapter :: LocApiV02Adapter(LocEng &locEng): + LocApiAdapter(locEng), clientHandle( LOC_CLIENT_INVALID_HANDLE_VALUE), + eventMask(convertMask(locEng.eventMask)), navigating(false), + fixCriteria (LOC_POSITION_MODE_MS_BASED, GPS_POSITION_RECURRENCE_PERIODIC, + LOC_API_V02_DEF_MIN_INTERVAL, LOC_API_V02_DEF_HORZ_ACCURACY, + LOC_API_V02_DEF_TIMEOUT ) +{ + // initialize loc_sync_req interface + loc_sync_req_init(); +} + +/* Destructor for LocApiV02Adapter */ +LocApiV02Adapter :: ~LocApiV02Adapter() +{ + deInitLocClient(); +} + +/* close Loc API V02 client */ +int LocApiV02Adapter :: deInitLocClient() +{ + return ( eLOC_CLIENT_SUCCESS == locClientClose(&clientHandle)) ? 0 : -1 ; +} + +/* Initialize a loc api v02 client */ +enum loc_api_adapter_err LocApiV02Adapter :: reinit() +{ + locClientStatusEnumType status; + /* If the client is already open close it first */ + if(LOC_CLIENT_INVALID_HANDLE_VALUE != clientHandle) + { + status = locClientClose(&clientHandle); + if( eLOC_CLIENT_SUCCESS != status) + { + LOC_LOGE ("%s:%d]: locClientClose failed, status = %d\n", __func__, + __LINE__, status); + return (LOC_API_ADAPTER_ERR_FAILURE); + } + } + + LOC_LOGV ("%s:%d]: reference to this = %p passed in \n", __func__, + __LINE__, this); + /* initialize the loc api v02 interface, note that + the locClientOpen() function will block if the + service is unavailable for a fixed time out */ + + status = locClientOpen( + eventMask, &globalCallbacks, &clientHandle, (void *)this); + + if (eLOC_CLIENT_SUCCESS != status || + clientHandle == LOC_CLIENT_INVALID_HANDLE_VALUE ) + { + LOC_LOGE ("%s:%d]: locClientOpen failed, status = %s\n", __func__, + __LINE__, loc_get_v02_client_status_name(status)); + return (LOC_API_ADAPTER_ERR_FAILURE); + } + + // return SUCCESS + return (LOC_API_ADAPTER_ERR_SUCCESS); +} + +/* start positioning session */ +enum loc_api_adapter_err LocApiV02Adapter :: startFix() +{ + locClientStatusEnumType status; + locClientReqUnionType req_union; + + qmiLocStartReqMsgT_v02 start_msg; + + qmiLocSetOperationModeReqMsgT_v02 set_mode_msg; + qmiLocSetOperationModeIndMsgT_v02 set_mode_ind; + + // clear all fields, validity masks + memset (&start_msg, 0, sizeof(start_msg)); + memset (&set_mode_msg, 0, sizeof(set_mode_msg)); + memset (&set_mode_ind, 0, sizeof(set_mode_ind)); + + LOC_LOGV("%s:%d]: start \n", __func__, __LINE__); + + // fill in the start request + switch(fixCriteria.mode) + { + case LOC_POSITION_MODE_MS_BASED: + set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_MSB_V02; + break; + + case LOC_POSITION_MODE_MS_ASSISTED: + set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_MSA_V02; + break; + + case LOC_POSITION_MODE_RESERVED_4: + set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_CELL_ID_V02; + break; + + default: + set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_STANDALONE_V02; + break; + } + + req_union.pSetOperationModeReq = &set_mode_msg; + + // send the mode first, before the start message. + status = loc_sync_send_req(clientHandle, + QMI_LOC_SET_OPERATION_MODE_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_OPERATION_MODE_IND_V02, + &set_mode_ind); // NULL? + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != set_mode_ind.status) + { + LOC_LOGE ("%s:%d]: set opertion mode failed status = %s, " + "ind..status = %s\n", __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(set_mode_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; // error + } + + if(fixCriteria.min_interval > 0) + { + start_msg.minInterval_valid = 1; + start_msg.minInterval = fixCriteria.min_interval; + } + + start_msg.horizontalAccuracyLevel_valid = 1; + + if (fixCriteria.preferred_accuracy <= 100) + { + // fix needs high accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_HIGH_V02; + } + else if (fixCriteria.preferred_accuracy <= 1000) + { + //fix needs med accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_MED_V02; + } + else + { + //fix needs low accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_LOW_V02; + } + + start_msg.fixRecurrence_valid = 1; + if(GPS_POSITION_RECURRENCE_SINGLE == fixCriteria.recurrence) + { + start_msg.fixRecurrence = eQMI_LOC_RECURRENCE_SINGLE_V02; + } + else + { + start_msg.fixRecurrence = eQMI_LOC_RECURRENCE_PERIODIC_V02; + } + + //dummy session id + // TBD: store session ID, check for session id in pos reports. + start_msg.sessionId = LOC_API_V02_DEF_SESSION_ID;; + + req_union.pStartReq = &start_msg; + + status = locClientSendReq (clientHandle, QMI_LOC_START_REQ_V02, + req_union ); + + if( eLOC_CLIENT_SUCCESS == status) + { + navigating = true; + return LOC_API_ADAPTER_ERR_SUCCESS; + } + + // start_fix failed so MO fix is not in progress + navigating = false; + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; +} + +/* stop a positioning session */ +enum loc_api_adapter_err LocApiV02Adapter :: stopFix() +{ + locClientStatusEnumType status; + locClientReqUnionType req_union; + + qmiLocStopReqMsgT_v02 stop_msg; + + LOC_LOGD(" %s:%d]: stop called \n", __func__, __LINE__); + + memset(&stop_msg, 0, sizeof(stop_msg)); + + // dummy session id + stop_msg.sessionId = LOC_API_V02_DEF_SESSION_ID; + + req_union.pStopReq = &stop_msg; + + status = locClientSendReq(clientHandle, + QMI_LOC_STOP_REQ_V02, + req_union); + + if( eLOC_CLIENT_SUCCESS == status) + { + navigating = false; + return LOC_API_ADAPTER_ERR_SUCCESS; + } + + LOC_LOGE("%s:%d]: error = %s\n",__func__, __LINE__, + loc_get_v02_client_status_name(status)); + return (LOC_API_ADAPTER_ERR_GENERAL_FAILURE); +} + +/* set the positioning fix criteria */ +enum loc_api_adapter_err LocApiV02Adapter :: setPositionMode( + LocPositionMode mode, GpsPositionRecurrence recurrence, + uint32_t min_interval, uint32_t preferred_accuracy, + uint32_t preferred_time) +{ + + LOC_LOGV ("%s:%d]: interval = %d, mode = %d, recurrence = %d, preferred_accuracy = %d\n",__func__, __LINE__, + min_interval, mode, recurrence, preferred_accuracy); + + //store the fix criteria + fixCriteria.mode = mode; + + fixCriteria.recurrence = recurrence; + + if(min_interval == 0) + { + fixCriteria.min_interval = MIN_POSSIBLE_FIX_INTERVAL; + } + else + { + fixCriteria.min_interval = min_interval; + } + + fixCriteria.preferred_accuracy = preferred_accuracy; + + fixCriteria.preferred_time = preferred_time; + + if(true == navigating) + { + //fix is in progress, send a restart + LOC_LOGD ("%s:%d]: fix is in progress restarting the fix with new " + "criteria\n", __func__, __LINE__); + + return( startFix()); + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* inject time into the position engine */ +enum loc_api_adapter_err LocApiV02Adapter :: + setTime(GpsUtcTime time, int64_t timeReference, int uncertainty) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + qmiLocInjectUtcTimeReqMsgT_v02 inject_time_msg; + qmiLocInjectUtcTimeIndMsgT_v02 inject_time_ind; + + memset(&inject_time_msg, 0, sizeof(inject_time_msg)); + + inject_time_ind.status = eQMI_LOC_GENERAL_FAILURE_V02; + + inject_time_msg.timeUtc = time; + + inject_time_msg.timeUtc += (int64_t)(android::elapsedRealtime() - timeReference); + + inject_time_msg.timeUnc = uncertainty; + + req_union.pInjectUtcTimeReq = &inject_time_msg; + + LOC_LOGV ("%s:%d]: uncertainty = %d\n", __func__, __LINE__, + uncertainty); + + status = loc_sync_send_req(clientHandle, + QMI_LOC_INJECT_UTC_TIME_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INJECT_UTC_TIME_IND_V02, + &inject_time_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != inject_time_ind.status) + { + LOC_LOGE ("%s:%d] status = %s, ind..status = %s\n", __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(inject_time_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* inject position into the position engine */ +enum loc_api_adapter_err LocApiV02Adapter :: + injectPosition(double latitude, double longitude, float accuracy) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + qmiLocInjectPositionReqMsgT_v02 inject_pos_msg; + qmiLocInjectPositionIndMsgT_v02 inject_pos_ind; + + memset(&inject_pos_msg, 0, sizeof(inject_pos_msg)); + + inject_pos_msg.latitude_valid = 1; + inject_pos_msg.latitude = latitude; + + inject_pos_msg.longitude_valid = 1; + inject_pos_msg.longitude = longitude; + + inject_pos_msg.horUncCircular_valid = 1; + + inject_pos_msg.horUncCircular = accuracy; //meters assumed + + inject_pos_msg.horConfidence_valid = 1; + + inject_pos_msg.horConfidence = 63; // 63% (1 std dev assumed) + + /* Log */ + LOC_LOGD("%s:%d]: Lat=%lf, Lon=%lf, Acc=%.2lf\n", __func__, __LINE__, + inject_pos_msg.latitude, inject_pos_msg.longitude, + inject_pos_msg.horUncCircular); + + req_union.pInjectPositionReq = &inject_pos_msg; + + status = loc_sync_send_req(clientHandle, + QMI_LOC_INJECT_POSITION_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INJECT_POSITION_IND_V02, + &inject_pos_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != inject_pos_ind.status) + { + LOC_LOGE ("%s:%d]: error! status = %s, inject_pos_ind.status = %s\n", + __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(inject_pos_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* delete assistance date */ +enum loc_api_adapter_err LocApiV02Adapter :: deleteAidingData(GpsAidingData f) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + qmiLocDeleteAssistDataReqMsgT_v02 delete_req; + qmiLocDeleteAssistDataIndMsgT_v02 delete_resp; + + memset(&delete_req, 0, sizeof(delete_req)); + memset(&delete_resp, 0, sizeof(delete_resp)); + + if( f == GPS_DELETE_ALL ) + { + delete_req.deleteAllFlag = true; + } + + else + { + /* to keep track of svInfoList for GPS and GLO*/ + uint32_t curr_sv_len = 0; + uint32_t curr_sv_idx = 0; + uint32_t sv_id = 0; + + if((f & GPS_DELETE_EPHEMERIS ) || ( f & GPS_DELETE_ALMANAC )) + { + /* do delete for all GPS SV's */ + + curr_sv_len += SV_ID_RANGE; + + sv_id = GPS_SV_ID_OFFSET; + + delete_req.deleteSvInfoList_valid = 1; + + delete_req.deleteSvInfoList_len = curr_sv_len; + + LOC_LOGV("%s:%d]: Delete GPS SV info for index %d to %d" + "and sv id %d to %d \n", + __func__, __LINE__, curr_sv_idx, curr_sv_len - 1, + sv_id, sv_id+SV_ID_RANGE); + + for( uint32_t i = curr_sv_idx; i< curr_sv_len ; i++, sv_id++ ) + { + delete_req.deleteSvInfoList[i].gnssSvId = sv_id; + + delete_req.deleteSvInfoList[i].system = eQMI_LOC_SV_SYSTEM_GPS_V02; + + if(f & GPS_DELETE_EPHEMERIS ) + { + // set ephemeris mask for all GPS SV's + delete_req.deleteSvInfoList[i].deleteSvInfoMask |= + QMI_LOC_MASK_DELETE_EPHEMERIS_V02; + } + + if( f & GPS_DELETE_ALMANAC ) + { + delete_req.deleteSvInfoList[i].deleteSvInfoMask |= + QMI_LOC_MASK_DELETE_ALMANAC_V02; + } + } + // increment the current index + curr_sv_idx += SV_ID_RANGE; + + } + +#ifdef QCOM_FEATURE_DELEXT + if( f & GPS_DELETE_TIME_GPS ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GPS_TIME_V02; + } +#endif + if(f & GPS_DELETE_POSITION ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_POSITION_V02; + } + + if(f & GPS_DELETE_TIME ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_TIME_V02; + } + + if(f & GPS_DELETE_IONO ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_IONO_V02; + } + + if(f & GPS_DELETE_UTC ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_UTC_V02; + } + + if(f & GPS_DELETE_HEALTH ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_HEALTH_V02; + } + + if(f & GPS_DELETE_SVDIR ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GPS_SVDIR_V02; + } + if(f & GPS_DELETE_SADATA ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_SADATA_V02; + } + if(f & GPS_DELETE_RTI ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_RTI_V02; + } + if(f & GPS_DELETE_CELLDB_INFO ) + { + delete_req.deleteCellDbDataMask_valid = 1; + delete_req.deleteCellDbDataMask = + ( QMI_LOC_MASK_DELETE_CELLDB_POS_V02 | + QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 | + QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 | + QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 | + QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 | + QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 | + QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 | + QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 | + QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 | + QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02) ; + + } +#ifdef QCOM_FEATURE_DELEXT + if(f & GPS_DELETE_ALMANAC_CORR ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02; + } + if(f & GPS_DELETE_FREQ_BIAS_EST ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02; + } + if ( (f & GPS_DELETE_EPHEMERIS_GLO ) || (f & GPS_DELETE_ALMANAC_GLO )) + { + /* do delete for all GLONASS SV's (65 - 96) + */ + curr_sv_len += SV_ID_RANGE; + + sv_id = GLONASS_SV_ID_OFFSET; + + delete_req.deleteSvInfoList_valid = 1; + + delete_req.deleteSvInfoList_len = curr_sv_len; + + LOC_LOGV("%s:%d]: Delete GLO SV info for index %d to %d" + "and sv id %d to %d \n", + __func__, __LINE__, curr_sv_idx, curr_sv_len - 1, + sv_id, sv_id+SV_ID_RANGE); + + + for( uint32_t i = curr_sv_idx; i< curr_sv_len ; i++, sv_id++ ) + { + delete_req.deleteSvInfoList[i].gnssSvId = sv_id; + + delete_req.deleteSvInfoList[i].system = eQMI_LOC_SV_SYSTEM_GLONASS_V02; + + if(f & GPS_DELETE_EPHEMERIS ) + { + // set ephemeris mask for all GPS SV's + delete_req.deleteSvInfoList[i].deleteSvInfoMask |= + QMI_LOC_MASK_DELETE_EPHEMERIS_V02; + } + + if( f & GPS_DELETE_ALMANAC ) + { + delete_req.deleteSvInfoList[i].deleteSvInfoMask |= + QMI_LOC_MASK_DELETE_ALMANAC_V02; + } + } + curr_sv_idx += SV_ID_RANGE; + } + + if(f & GPS_DELETE_SVDIR_GLO ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GLO_SVDIR_V02; + } + + if(f & GPS_DELETE_SVSTEER_GLO ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02; + } + + if(f & GPS_DELETE_ALMANAC_CORR_GLO ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02; + } + + if(f & GPS_DELETE_TIME_GLO ) + { + delete_req.deleteGnssDataMask_valid = 1; + delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GLO_TIME_V02; + } +#endif + } + + req_union.pDeleteAssistDataReq = &delete_req; + + status = loc_sync_send_req(clientHandle, + QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_DELETE_ASSIST_DATA_IND_V02, + &delete_resp); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != delete_resp.status) + { + LOC_LOGE ("%s:%d]: error! status = %s, delete_resp.status = %s\n", + __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(delete_resp.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* send NI user repsonse to the engine */ +enum loc_api_adapter_err LocApiV02Adapter :: + informNiResponse(GpsUserResponseType userResponse, + const void* passThroughData) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + + qmiLocNiUserRespReqMsgT_v02 ni_resp; + qmiLocNiUserRespIndMsgT_v02 ni_resp_ind; + + qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *request_pass_back = + (qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *)passThroughData; + + memset(&ni_resp,0, sizeof(ni_resp)); + + memset(&ni_resp_ind,0, sizeof(ni_resp_ind)); + + switch (userResponse) + { + case GPS_NI_RESPONSE_ACCEPT: + ni_resp.userResp = eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02; + break; + case GPS_NI_RESPONSE_DENY: + ni_resp.userResp = eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02; + break; + case GPS_NI_RESPONSE_NORESP: + ni_resp.userResp = eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02; + break; + default: + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + } + + LOC_LOGV(" %s:%d]: NI response: %d\n", __func__, __LINE__, + ni_resp.userResp); + + ni_resp.notificationType = request_pass_back->notificationType; + + // copy SUPL payload from request + if(request_pass_back->NiSuplInd_valid == 1) + { + ni_resp.NiSuplPayload_valid = 1; + memcpy(&(ni_resp.NiSuplPayload), &(request_pass_back->NiSuplInd), + sizeof(qmiLocNiSuplNotifyVerifyStructT_v02)); + + } + // should this be an "else if"?? we don't need to decide + + // copy UMTS-CP payload from request + if( request_pass_back->NiUmtsCpInd_valid == 1 ) + { + ni_resp.NiUmtsCpPayload_valid = 1; + memcpy(&(ni_resp.NiUmtsCpPayload), &(request_pass_back->NiUmtsCpInd), + sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02)); + } + + //copy Vx payload from the request + if( request_pass_back->NiVxInd_valid == 1) + { + ni_resp.NiVxPayload_valid = 1; + memcpy(&(ni_resp.NiVxPayload), &(request_pass_back->NiVxInd), + sizeof(qmiLocNiVxNotifyVerifyStructT_v02)); + } + + // copy Vx service interaction payload from the request + if(request_pass_back->NiVxServiceInteractionInd_valid == 1) + { + ni_resp.NiVxServiceInteractionPayload_valid = 1; + memcpy(&(ni_resp.NiVxServiceInteractionPayload), + &(request_pass_back->NiVxServiceInteractionInd), + sizeof(qmiLocNiVxServiceInteractionStructT_v02)); + } + + req_union.pNiUserRespReq = &ni_resp; + + status = loc_sync_send_req ( + clientHandle, QMI_LOC_NI_USER_RESPONSE_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_NI_USER_RESPONSE_IND_V02, &ni_resp_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != ni_resp_ind.status) + { + LOC_LOGE ("%s:%d]: error! status = %s, ni_resp_ind.status = %s\n", + __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(ni_resp_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* Set UMTs SLP server URL */ +enum loc_api_adapter_err LocApiV02Adapter :: setServer( + const char* url, int len) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + qmiLocSetServerReqMsgT_v02 set_server_req; + qmiLocSetServerIndMsgT_v02 set_server_ind; + + if(len <=0 || len > sizeof(set_server_req.urlAddr)) + { + LOC_LOGE("%s:%d]: len = %d greater than max allowed url length\n", + __func__, __LINE__, len); + + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + } + + memset(&set_server_req, 0, sizeof(set_server_req)); + + LOC_LOGD("%s:%d]:, url = %s, len = %d\n", __func__, __LINE__, url, len); + + set_server_req.serverType = eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02; + + set_server_req.urlAddr_valid = 1; + + strlcpy(set_server_req.urlAddr, url, sizeof(set_server_req.urlAddr)); + + req_union.pSetServerReq = &set_server_req; + + status = loc_sync_send_req(clientHandle, + QMI_LOC_SET_SERVER_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_SERVER_IND_V02, + &set_server_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != set_server_ind.status) + { + LOC_LOGE ("%s:%d]: error status = %s, set_server_ind.status = %s\n", + __func__,__LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(set_server_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +enum loc_api_adapter_err LocApiV02Adapter :: + setServer(unsigned int ip, int port, LocServerType type) +{ + locClientReqUnionType req_union; + locClientStatusEnumType status; + qmiLocSetServerReqMsgT_v02 set_server_req; + qmiLocSetServerIndMsgT_v02 set_server_ind; + qmiLocServerTypeEnumT_v02 set_server_cmd; + + switch (type) { + case LOC_AGPS_MPC_SERVER: + set_server_cmd = eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02; + break; + case LOC_AGPS_CUSTOM_PDE_SERVER: + set_server_cmd = eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02; + break; + default: + set_server_cmd = eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02; + break; + } + + memset(&set_server_req, 0, sizeof(set_server_req)); + + LOC_LOGD("%s:%d]:, ip = %u, port = %d\n", __func__, __LINE__, ip, port); + + set_server_req.serverType = set_server_cmd; + set_server_req.ipv4Addr_valid = 1; + set_server_req.ipv4Addr.addr = ip; + set_server_req.ipv4Addr.port = port; + + req_union.pSetServerReq = &set_server_req; + + status = loc_sync_send_req(clientHandle, + QMI_LOC_SET_SERVER_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_SERVER_IND_V02, + &set_server_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != set_server_ind.status) + { + LOC_LOGE ("%s:%d]: error status = %s, set_server_ind.status = %s\n", + __func__,__LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(set_server_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* Inject XTRA data, this module breaks down the XTRA + file into "chunks" and injects them one at a time */ +enum loc_api_adapter_err LocApiV02Adapter :: setXtraData( + char* data, int length) +{ + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; + int total_parts; + uint8_t part; + uint16_t len_injected; + + locClientReqUnionType req_union; + qmiLocInjectPredictedOrbitsDataReqMsgT_v02 inject_xtra; + qmiLocInjectPredictedOrbitsDataIndMsgT_v02 inject_xtra_ind; + + req_union.pInjectPredictedOrbitsDataReq = &inject_xtra; + + LOC_LOGD("%s:%d]: xtra size = %d\n", __func__, __LINE__, length); + + inject_xtra.formatType_valid = 1; + inject_xtra.formatType = eQMI_LOC_PREDICTED_ORBITS_XTRA_V02; + inject_xtra.totalSize = length; + + total_parts = ((length - 1) / QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) + 1; + + inject_xtra.totalParts = total_parts; + + len_injected = 0; // O bytes injected + + // XTRA injection starts with part 1 + for (part = 1; part <= total_parts; part++) + { + inject_xtra.partNum = part; + + if (QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 > (length - len_injected)) + { + inject_xtra.partData_len = length - len_injected; + } + else + { + inject_xtra.partData_len = QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02; + } + + // copy data into the message + memcpy(inject_xtra.partData, data+len_injected, inject_xtra.partData_len); + + LOC_LOGD("[%s:%d] part %d/%d, len = %d, total injected = %d\n", + __func__, __LINE__, + inject_xtra.partNum, total_parts, inject_xtra.partData_len, + len_injected); + + status = loc_sync_send_req( clientHandle, + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, + &inject_xtra_ind); + + if (status != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != inject_xtra_ind.status || + inject_xtra.partNum != inject_xtra_ind.partNum) + { + LOC_LOGE ("%s:%d]: failed status = %s, inject_pos_ind.status = %s," + " part num = %d, ind.partNum = %d\n", __func__, __LINE__, + loc_get_v02_client_status_name(status), + loc_get_v02_qmi_status_name(inject_xtra_ind.status), + inject_xtra.partNum, inject_xtra_ind.partNum); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + break; + } + + len_injected += inject_xtra.partData_len; + LOC_LOGD("%s:%d]: XTRA injected length: %d\n", __func__, __LINE__, + len_injected); + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} +#ifdef QCOM_FEATURE_IPV6 +enum loc_api_adapter_err LocApiV02Adapter :: atlOpenStatus( + int handle, int is_succ, char* apn, AGpsBearerType bear, + AGpsType agpsType) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + qmiLocInformLocationServerConnStatusReqMsgT_v02 conn_status_req; + qmiLocInformLocationServerConnStatusIndMsgT_v02 conn_status_ind; + + LOC_LOGD("%s:%d]: ATL open handle = %d, is_succ = %d, " + "APN = [%s], bearer = %d \n", __func__, __LINE__, + handle, is_succ, apn, bear); + + memset(&conn_status_req, 0, sizeof(conn_status_req)); + memset(&conn_status_ind, 0, sizeof(conn_status_ind)); + + // Fill in data + conn_status_req.connHandle = handle; + + conn_status_req.requestType = eQMI_LOC_SERVER_REQUEST_OPEN_V02; + + if(is_succ) + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02; + + strlcpy(conn_status_req.apnProfile.apnName, apn, + sizeof(conn_status_req.apnProfile.apnName) ); + + switch(bear) + { + case AGPS_APN_BEARER_IPV4: + conn_status_req.apnProfile.pdnType = + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02; + break; + + case AGPS_APN_BEARER_IPV6: + conn_status_req.apnProfile.pdnType = + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02; + break; + + case AGPS_APN_BEARER_IPV4V6: + conn_status_req.apnProfile.pdnType = + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02; + break; + + default: + LOC_LOGE("%s:%d]:invalid bearer type\n",__func__,__LINE__); + return LOC_API_ADAPTER_ERR_INVALID_HANDLE; + } + + conn_status_req.apnProfile_valid = 1; + } + else + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02; + } + + req_union.pInformLocationServerConnStatusReq = &conn_status_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, + &conn_status_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != conn_status_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(conn_status_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; + +} +#else +enum loc_api_adapter_err LocApiV02Adapter :: atlOpenStatus( + int handle, int is_succ, char* apn, AGpsType agpsType) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + qmiLocInformLocationServerConnStatusReqMsgT_v02 conn_status_req; + qmiLocInformLocationServerConnStatusIndMsgT_v02 conn_status_ind; + + LOC_LOGD("%s:%d]: ATL open handle = %d, is_succ = %d, " + "APN = [%s] \n", __func__, __LINE__, + handle, is_succ, apn); + + memset(&conn_status_req, 0, sizeof(conn_status_req)); + memset(&conn_status_ind, 0, sizeof(conn_status_ind)); + + // Fill in data + conn_status_req.connHandle = handle; + + conn_status_req.requestType = eQMI_LOC_SERVER_REQUEST_OPEN_V02; + + if(is_succ) + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02; + + strlcpy(conn_status_req.apnProfile.apnName, apn, + sizeof(conn_status_req.apnProfile.apnName) ); + + + conn_status_req.apnProfile.pdnType = + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02; + + conn_status_req.apnProfile_valid = 1; + } + else + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02; + } + + req_union.pInformLocationServerConnStatusReq = &conn_status_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, + &conn_status_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != conn_status_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(conn_status_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; + +} +#endif +/* close atl connection */ +enum loc_api_adapter_err LocApiV02Adapter :: atlCloseStatus( + int handle, int is_succ) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + qmiLocInformLocationServerConnStatusReqMsgT_v02 conn_status_req; + qmiLocInformLocationServerConnStatusIndMsgT_v02 conn_status_ind; + + LOC_LOGD("%s:%d]: ATL close handle = %d, is_succ = %d\n", + __func__, __LINE__, handle, is_succ); + + memset(&conn_status_req, 0, sizeof(conn_status_req)); + memset(&conn_status_ind, 0, sizeof(conn_status_ind)); + + // Fill in data + conn_status_req.connHandle = handle; + + conn_status_req.requestType = eQMI_LOC_SERVER_REQUEST_CLOSE_V02; + + if(is_succ) + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02; + } + else + { + conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02; + } + + req_union.pInformLocationServerConnStatusReq = &conn_status_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, + &conn_status_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != conn_status_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(conn_status_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* set the SUPL version */ +enum loc_api_adapter_err LocApiV02Adapter :: setSUPLVersion(uint32_t version) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + + qmiLocSetProtocolConfigParametersReqMsgT_v02 supl_config_req; + qmiLocSetProtocolConfigParametersIndMsgT_v02 supl_config_ind; + + LOC_LOGD("%s:%d]: supl version = %d\n", __func__, __LINE__, version); + + + memset(&supl_config_req, 0, sizeof(supl_config_req)); + memset(&supl_config_ind, 0, sizeof(supl_config_ind)); + + supl_config_req.suplVersion_valid = 1; + // SUPL version from MSByte to LSByte: + // (reserved)(major version)(minor version)(serviceIndicator) + + supl_config_req.suplVersion = (version == 0x00020000)? + eQMI_LOC_SUPL_VERSION_2_0_V02 : eQMI_LOC_SUPL_VERSION_1_0_V02; + + req_union.pSetProtocolConfigParametersReq = &supl_config_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, + &supl_config_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != supl_config_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(supl_config_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* set the Sensor Configuration */ +enum loc_api_adapter_err LocApiV02Adapter :: setSensorControlConfig(int sensorsDisabled) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + + qmiLocSetSensorControlConfigReqMsgT_v02 sensor_config_req; + qmiLocSetSensorControlConfigIndMsgT_v02 sensor_config_ind; + + LOC_LOGD("%s:%d]: sensors disabled = %d\n", __func__, __LINE__, sensorsDisabled); + + memset(&sensor_config_req, 0, sizeof(sensor_config_req)); + memset(&sensor_config_ind, 0, sizeof(sensor_config_ind)); + + sensor_config_req.sensorsUsage_valid = 1; + sensor_config_req.sensorsUsage = (sensorsDisabled == 1) ? eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 + : eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02; + + req_union.pSetSensorControlConfigReq = &sensor_config_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, + &sensor_config_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != sensor_config_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(sensor_config_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* set the Sensor Properties */ +enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(float gyroBiasVarianceRandomWalk) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + + qmiLocSetSensorPropertiesReqMsgT_v02 sensor_prop_req; + qmiLocSetSensorPropertiesIndMsgT_v02 sensor_prop_ind; + + LOC_LOGI("%s:%d]: sensors prop gyroBiasRandomWalk = %f\n", + __func__, __LINE__, gyroBiasVarianceRandomWalk); + + memset(&sensor_prop_req, 0, sizeof(sensor_prop_req)); + memset(&sensor_prop_ind, 0, sizeof(sensor_prop_ind)); + + sensor_prop_req.gyroBiasVarianceRandomWalk_valid = 1; + sensor_prop_req.gyroBiasVarianceRandomWalk = gyroBiasVarianceRandomWalk; + + req_union.pSetSensorPropertiesReq = &sensor_prop_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, + &sensor_prop_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != sensor_prop_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(sensor_prop_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* set the Sensor Performance Config */ +enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int controlMode, + int accelSamplesPerBatch, int accelBatchesPerSec, + int gyroSamplesPerBatch, int gyroBatchesPerSec) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + + qmiLocSetSensorPerformanceControlConfigReqMsgT_v02 sensor_perf_config_req; + qmiLocSetSensorPerformanceControlConfigIndMsgT_v02 sensor_perf_config_ind; + + LOC_LOGD("%s:%d]: Sensor Perf Control Config (performanceControlMode)(%u) " + "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u)\n", + __FUNCTION__, + __LINE__, + controlMode, + accelSamplesPerBatch, + accelBatchesPerSec, + gyroSamplesPerBatch, + gyroBatchesPerSec + ); + + memset(&sensor_perf_config_req, 0, sizeof(sensor_perf_config_req)); + memset(&sensor_perf_config_ind, 0, sizeof(sensor_perf_config_ind)); + + sensor_perf_config_req.performanceControlMode_valid = 1; + sensor_perf_config_req.performanceControlMode = (qmiLocSensorPerformanceControlModeEnumT_v02)controlMode; + sensor_perf_config_req.accelSamplingSpec_valid = 1; + sensor_perf_config_req.accelSamplingSpec.batchesPerSecond = accelBatchesPerSec; + sensor_perf_config_req.accelSamplingSpec.samplesPerBatch = accelSamplesPerBatch; + sensor_perf_config_req.gyroSamplingSpec_valid = 1; + sensor_perf_config_req.gyroSamplingSpec.batchesPerSecond = gyroBatchesPerSec; + sensor_perf_config_req.gyroSamplingSpec.samplesPerBatch = gyroSamplesPerBatch; + + req_union.pSetSensorPerformanceControlConfigReq = &sensor_perf_config_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, + &sensor_perf_config_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != sensor_perf_config_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(sensor_perf_config_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + +/* Convert event mask from loc eng to loc_api_v02 format */ +locClientEventMaskType LocApiV02Adapter :: convertMask( + LOC_API_ADAPTER_EVENT_MASK_T mask) +{ + locClientEventMaskType eventMask = 0; + LOC_LOGD("%s:%d]: adapter mask = %u\n", __func__, __LINE__, mask); + + if(mask & LOC_API_ADAPTER_BIT_PARSED_POSITION_REPORT) + eventMask |= QMI_LOC_EVENT_MASK_POSITION_REPORT_V02; + + if(mask & LOC_API_ADAPTER_BIT_SATELLITE_REPORT) + eventMask |= QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02; + + /* treat NMEA_1Hz and NMEA_POSITION_REPORT the same*/ + if( (mask & LOC_API_ADAPTER_BIT_NMEA_POSITION_REPORT) || + (mask & LOC_API_ADAPTER_BIT_NMEA_1HZ_REPORT) ) + eventMask |= QMI_LOC_EVENT_MASK_NMEA_V02; + + if(mask & LOC_API_ADAPTER_BIT_NI_NOTIFY_VERIFY_REQUEST) + eventMask |= QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02; + + if(mask & LOC_API_ADAPTER_BIT_ASSISTANCE_DATA_REQUEST) + { + // TBD: This needs to be decoupled in the HAL + eventMask |= QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02; + eventMask |= QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02; + eventMask |= QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02; + } + + if(mask & LOC_API_ADAPTER_BIT_STATUS_REPORT) + { + eventMask |= (QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 | + QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02); + } + + if(mask & LOC_API_ADAPTER_BIT_LOCATION_SERVER_REQUEST) + eventMask |= QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02; + + return eventMask; +} + +/* Convert error from loc_api_v02 to loc eng format*/ +enum loc_api_adapter_err LocApiV02Adapter :: convertErr( + locClientStatusEnumType status) +{ + switch( status) + { + case LOC_API_ADAPTER_ERR_SUCCESS: + return LOC_API_ADAPTER_ERR_SUCCESS; + + case eLOC_CLIENT_FAILURE_GENERAL: + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + + case eLOC_CLIENT_FAILURE_UNSUPPORTED: + return LOC_API_ADAPTER_ERR_UNSUPPORTED; + + case eLOC_CLIENT_FAILURE_INVALID_PARAMETER: + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + + case eLOC_CLIENT_FAILURE_ENGINE_BUSY: + return LOC_API_ADAPTER_ERR_ENGINE_BUSY; + + case eLOC_CLIENT_FAILURE_PHONE_OFFLINE: + return LOC_API_ADAPTER_ERR_PHONE_OFFLINE; + + case eLOC_CLIENT_FAILURE_TIMEOUT: + return LOC_API_ADAPTER_ERR_TIMEOUT; + + case eLOC_CLIENT_FAILURE_INVALID_HANDLE: + return LOC_API_ADAPTER_ERR_INVALID_HANDLE; + + case eLOC_CLIENT_FAILURE_SERVICE_NOT_PRESENT: + return LOC_API_ADAPTER_ERR_SERVICE_NOT_PRESENT; + + default: + return LOC_API_ADAPTER_ERR_FAILURE; + } +} + +/* convert position report to loc eng format and send the converted + position to loc eng */ + +void LocApiV02Adapter :: reportPosition ( + const qmiLocEventPositionReportIndMsgT_v02 *location_report_ptr) +{ + GpsLocation location; + + memset(&location, 0, sizeof (GpsLocation)); + location.size = sizeof(location); + // Process the position from final and intermediate reports + + if( (location_report_ptr->sessionStatus == eQMI_LOC_SESS_STATUS_SUCCESS_V02) || + (location_report_ptr->sessionStatus == eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02) + ) + { + // Latitude & Longitude + if( (location_report_ptr->latitude_valid == 1 ) && + (location_report_ptr->longitude_valid == 1) && + (location_report_ptr->latitude != 0 || + location_report_ptr->longitude!= 0)) + { + location.flags |= GPS_LOCATION_HAS_LAT_LONG; + location.latitude = location_report_ptr->latitude; + location.longitude = location_report_ptr->longitude; + + // Time stamp (UTC) + if(location_report_ptr->timestampUtc_valid == 1) + { + location.timestamp = location_report_ptr->timestampUtc; + } + + // Altitude + if(location_report_ptr->altitudeWrtEllipsoid_valid == 1 ) + { + location.flags |= GPS_LOCATION_HAS_ALTITUDE; + location.altitude = location_report_ptr->altitudeWrtEllipsoid; + } + + // Speed + if((location_report_ptr->speedHorizontal_valid == 1) && + (location_report_ptr->speedVertical_valid ==1 ) ) + { + location.flags |= GPS_LOCATION_HAS_SPEED; + location.speed = sqrt( + (location_report_ptr->speedHorizontal * + location_report_ptr->speedHorizontal) + + (location_report_ptr->speedVertical * + location_report_ptr->speedVertical) ); + } + + // Heading + if(location_report_ptr->heading_valid == 1) + { + location.flags |= GPS_LOCATION_HAS_BEARING; + location.bearing = location_report_ptr->heading; + } + + // Uncertainty (circular) + if( (location_report_ptr->horUncCircular_valid ) ) + { + location.flags |= GPS_LOCATION_HAS_ACCURACY; + location.accuracy = location_report_ptr->horUncCircular; + } + + LocApiAdapter::reportPosition( location, + locEngHandle.extPosInfo((void*)location_report_ptr), + (location_report_ptr->sessionStatus + == eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 ? + LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS)); + } + } + else + { + LocApiAdapter::reportPosition(location, + NULL, + LOC_SESS_FAILURE); + + LOC_LOGD("%s:%d]: Ignoring position report with sess status = %d, " + "fix id = %u\n", __func__, __LINE__, + location_report_ptr->sessionStatus, + location_report_ptr->fixId ); + } +} + +/* convert satellite report to loc eng format and send the converted + report to loc eng */ +void LocApiV02Adapter :: reportSv ( + const qmiLocEventGnssSvInfoIndMsgT_v02 *gnss_report_ptr) +{ + GpsSvStatus SvStatus; + int num_svs_max, i; + const qmiLocSvInfoStructT_v02 *sv_info_ptr; + + LOC_LOGV ("%s:%d]: num of sv = %d\n", __func__, __LINE__, + gnss_report_ptr->svList_len); + + num_svs_max = 0; + memset (&SvStatus, 0, sizeof (GpsSvStatus)); + if(gnss_report_ptr->svList_valid == 1) + { + num_svs_max = gnss_report_ptr->svList_len; + if(num_svs_max > GPS_MAX_SVS) + { + num_svs_max = GPS_MAX_SVS; + } + SvStatus.num_svs = 0; + for(i = 0; i < num_svs_max; i++) + { + sv_info_ptr = &(gnss_report_ptr->svList[i]); + if((sv_info_ptr->validMask & QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02) && + (sv_info_ptr->validMask & QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02) + && (sv_info_ptr->gnssSvId != 0 )) + { + if(sv_info_ptr->system == eQMI_LOC_SV_SYSTEM_GPS_V02) + { + SvStatus.sv_list[SvStatus.num_svs].size = sizeof(GpsSvStatus); + SvStatus.sv_list[SvStatus.num_svs].prn = (int)sv_info_ptr->gnssSvId; + + // We only have the data field to report gps eph and alm mask + if(sv_info_ptr->validMask & + QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02) + { + if(sv_info_ptr->svInfoMask & + QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02) + { + SvStatus.ephemeris_mask |= (1 << (sv_info_ptr->gnssSvId-1)); + } + if(sv_info_ptr->svInfoMask & + QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02) + { + SvStatus.almanac_mask |= (1 << (sv_info_ptr->gnssSvId-1)); + } + } + + if((sv_info_ptr->validMask & + QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02) + && + (sv_info_ptr->svStatus == eQMI_LOC_SV_STATUS_TRACK_V02)) + { + SvStatus.used_in_fix_mask |= (1 << (sv_info_ptr->gnssSvId-1)); + } + } + // SBAS: GPS RPN: 120-151, + // In exteneded measurement report, we follow nmea standard, + // which is from 33-64. + else if(sv_info_ptr->system == eQMI_LOC_SV_SYSTEM_SBAS_V02) + { + SvStatus.sv_list[SvStatus.num_svs].prn = + sv_info_ptr->gnssSvId + 33 - 120; + } + // Gloness: Slot id: 1-32 + // In extended measurement report, we follow nmea standard, + // which is 65-96 + else if(sv_info_ptr->system == eQMI_LOC_SV_SYSTEM_GLONASS_V02) + { + SvStatus.sv_list[SvStatus.num_svs].prn = + sv_info_ptr->gnssSvId + (65-1); + } + // Unsupported SV system + else + { + continue; + } + } + + if(sv_info_ptr->validMask & QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ) + { + SvStatus.sv_list[SvStatus.num_svs].snr = sv_info_ptr->snr; + } + + if(sv_info_ptr->validMask & QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02) + { + SvStatus.sv_list[SvStatus.num_svs].elevation = sv_info_ptr->elevation; + } + + if(sv_info_ptr->validMask & QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02) + { + SvStatus.sv_list[SvStatus.num_svs].azimuth = sv_info_ptr->azimuth; + } + + SvStatus.num_svs++; + } + } + + if (SvStatus.num_svs != 0) + { + LOC_LOGV ("%s:%d]: firing SV callback\n", __func__, __LINE__); + LocApiAdapter::reportSv(SvStatus, + locEngHandle.extSvInfo((void*)gnss_report_ptr)); + } +} + +/* convert engine state report to loc eng format and send the converted + report to loc eng */ +void LocApiV02Adapter :: reportEngineState ( + const qmiLocEventEngineStateIndMsgT_v02 *engine_state_ptr) +{ + GpsStatusValue status; + + LOC_LOGV("%s:%d]: state = %d\n", __func__, __LINE__, + engine_state_ptr->engineState); + + status = GPS_STATUS_NONE; + if (engine_state_ptr->engineState == eQMI_LOC_ENGINE_STATE_ON_V02) + { + status = GPS_STATUS_ENGINE_ON; + } + else if (engine_state_ptr->engineState == eQMI_LOC_ENGINE_STATE_OFF_V02) + { + status = GPS_STATUS_ENGINE_OFF; + } + LocApiAdapter::reportStatus(status); +} + +/* convert fix session state report to loc eng format and send the converted + report to loc eng */ +void LocApiV02Adapter :: reportFixSessionState ( + const qmiLocEventFixSessionStateIndMsgT_v02 *fix_session_state_ptr) +{ + GpsStatusValue status; + LOC_LOGD("%s:%d]: state = %d\n", __func__, __LINE__, + fix_session_state_ptr->sessionState); + + status = GPS_STATUS_NONE; + if (fix_session_state_ptr->sessionState == eQMI_LOC_FIX_SESSION_STARTED_V02) + { + status = GPS_STATUS_SESSION_BEGIN; + } + else if (fix_session_state_ptr->sessionState + == eQMI_LOC_FIX_SESSION_FINISHED_V02) + { + status = GPS_STATUS_SESSION_END; + } + LocApiAdapter::reportStatus(status); +} + +/* convert NMEA report to loc eng format and send the converted + report to loc eng */ +void LocApiV02Adapter :: reportNmea ( + const qmiLocEventNmeaIndMsgT_v02 *nmea_report_ptr) +{ + + LocApiAdapter::reportNmea(nmea_report_ptr->nmea, + strlen(nmea_report_ptr->nmea)); + + LOC_LOGD("%s:%d]: $%c%c%c\n", __func__, __LINE__, + nmea_report_ptr->nmea[3], nmea_report_ptr->nmea[4], + nmea_report_ptr->nmea[5]); +} + +/* convert and report an ATL request to loc engine */ +void LocApiV02Adapter :: reportAtlRequest( + const qmiLocEventLocationServerConnectionReqIndMsgT_v02 * server_request_ptr) +{ + uint32_t connHandle = server_request_ptr->connHandle; + // service ATL open request; copy the WWAN type + if(server_request_ptr->requestType == eQMI_LOC_SERVER_REQUEST_OPEN_V02 ) + { + AGpsType agpsType; +#ifdef QCOM_FEATURE_IPV6 + switch(server_request_ptr->wwanType) + { + case eQMI_LOC_WWAN_TYPE_INTERNET_V02: + agpsType = AGPS_TYPE_WWAN_ANY; + break; + + case eQMI_LOC_WWAN_TYPE_AGNSS_V02: + agpsType = AGPS_TYPE_SUPL; + break; + + default: + agpsType = AGPS_TYPE_WWAN_ANY; + break; + } +#else + agpsType = AGPS_TYPE_SUPL; +#endif + LocApiAdapter::requestATL(connHandle, agpsType); + } + + // service the ATL close request + else if (server_request_ptr->requestType == eQMI_LOC_SERVER_REQUEST_CLOSE_V02) + { + LocApiAdapter::releaseATL(connHandle); + } +} + +/* conver the NI report to loc eng format and send t loc engine */ +void LocApiV02Adapter :: reportNiRequest( + const qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *ni_req_ptr) +{ + GpsNiNotification notif; + + /* initialize the notification*/ + memset(notif.extras, 0, sizeof notif.extras); + memset(notif.text, 0, sizeof notif.text); + memset(notif.requestor_id, 0, sizeof notif.requestor_id); + + /* NI timeout gets overwritten in LocApiAdapter, + initializing to 0 here */ + notif.timeout = 0; + + notif.text_encoding = GPS_ENC_NONE ; + + notif.requestor_id_encoding = GPS_ENC_UNKNOWN; + + notif.notify_flags = 0; + + notif.default_response = GPS_NI_RESPONSE_NORESP; + + /*Handle Vx request */ + if(ni_req_ptr->NiVxInd_valid == 1) + { + const qmiLocNiVxNotifyVerifyStructT_v02 *vx_req = &(ni_req_ptr->NiVxInd); + + notif.ni_type = GPS_NI_TYPE_VOICE; + + // Requestor ID, the requestor id recieved is NULL terminated + hexcode(notif.requestor_id, sizeof notif.requestor_id, + (char *)vx_req->requestorId, vx_req->requestorId_len ); + } + + /* Handle UMTS CP request*/ + else if(ni_req_ptr->NiUmtsCpInd_valid == 1) + { + const qmiLocNiUmtsCpNotifyVerifyStructT_v02 *umts_cp_req = + &ni_req_ptr->NiUmtsCpInd; + + notif.ni_type = GPS_NI_TYPE_UMTS_CTRL_PLANE; + + /* notificationText should always be a NULL terminated string */ + hexcode(notif.text, sizeof notif.text, + (char *)umts_cp_req->notificationText, + umts_cp_req->notificationText_len); + + /* Store requestor ID */ + hexcode(notif.requestor_id, sizeof(notif.requestor_id), + (char *)umts_cp_req->requestorId.codedString, + umts_cp_req->requestorId.codedString_len); + + /* convert encodings */ + notif.text_encoding = convertNiEncoding(umts_cp_req->dataCodingScheme); + + notif.requestor_id_encoding = + convertNiEncoding(umts_cp_req->requestorId.dataCodingScheme); + + /* LCS address (using extras field) */ + if ( umts_cp_req->clientAddress_len != 0) + { + char lcs_addr[32]; // Decoded LCS address for UMTS CP NI + + // Copy LCS Address into notif.extras in the format: Address = 012345 + strlcat(notif.extras, LOC_NI_NOTIF_KEY_ADDRESS, sizeof (notif.extras)); + strlcat(notif.extras, " = ", sizeof notif.extras); + int addr_len = 0; + const char *address_source = NULL; + address_source = (char *)umts_cp_req->clientAddress; + // client Address is always NULL terminated + addr_len = decodeAddress(lcs_addr, sizeof(lcs_addr), address_source, + umts_cp_req->clientAddress_len); + + // The address is ASCII string + if (addr_len) + { + strlcat(notif.extras, lcs_addr, sizeof notif.extras); + } + } + + } + else if(ni_req_ptr->NiSuplInd_valid == 1) + { + const qmiLocNiSuplNotifyVerifyStructT_v02 *supl_req = + &ni_req_ptr->NiSuplInd; + + notif.ni_type = GPS_NI_TYPE_UMTS_SUPL; + + // Client name + if (supl_req->valid_flags & QMI_LOC_SUPL_CLIENT_NAME_MASK_V02) + { + hexcode(notif.text, sizeof(notif.text), + (char *)supl_req->clientName.formattedString, + supl_req->clientName.formattedString_len); + LOC_LOGV("%s:%d]: SUPL NI: client_name: %s \n", __func__, __LINE__, + notif.text); + } + else + { + LOC_LOGV("%s:%d]: SUPL NI: client_name not present.", + __func__, __LINE__); + } + + // Requestor ID + if (supl_req->valid_flags & QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02) + { + hexcode(notif.requestor_id, sizeof notif.requestor_id, + (char*)supl_req->requestorId.formattedString, + supl_req->requestorId.formattedString_len ); + + LOC_LOGV("%s:%d]: SUPL NI: requestor_id: %s \n", __func__, __LINE__, + notif.requestor_id); + } + else + { + LOC_LOGV("%s:%d]: SUPL NI: requestor_id not present.", + __func__, __LINE__); + } + + // Encoding type + if (supl_req->valid_flags & QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02) + { + notif.text_encoding = convertNiEncoding(supl_req->dataCodingScheme); + + notif.requestor_id_encoding = convertNiEncoding(supl_req->dataCodingScheme); + } + else + { + notif.text_encoding = notif.requestor_id_encoding = GPS_ENC_UNKNOWN; + } + + } //ni_req_ptr->NiSuplInd_valid == 1 + + else + { + LOC_LOGE("%s:%d]: unknown request event \n",__func__, __LINE__); + return; + } + + // Set default_response & notify_flags + convertNiNotifyVerifyType(¬if, ni_req_ptr->notificationType); + + qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *ni_req_copy_ptr = + (qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *)malloc(sizeof(*ni_req_copy_ptr)); + + if( NULL != ni_req_copy_ptr) + { + memcpy(ni_req_copy_ptr, ni_req_ptr, sizeof(*ni_req_copy_ptr)); + + LocApiAdapter::requestNiNotify(notif, (const void*)ni_req_copy_ptr); + } + else + { + LOC_LOGE("%s:%d]: Error copying NI request\n", __func__, __LINE__); + } + +} + +/* convert Ni Encoding type from QMI_LOC to loc eng format */ +GpsNiEncodingType LocApiV02Adapter ::convertNiEncoding( + qmiLocNiDataCodingSchemeEnumT_v02 loc_encoding) +{ + GpsNiEncodingType enc = GPS_ENC_UNKNOWN; + + switch (loc_encoding) + { + case eQMI_LOC_NI_SUPL_UTF8_V02: + enc = GPS_ENC_SUPL_UTF8; + break; + case eQMI_LOC_NI_SUPL_UCS2_V02: + enc = GPS_ENC_SUPL_UCS2; + break; + case eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02: + enc = GPS_ENC_SUPL_GSM_DEFAULT; + break; + case eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02: + enc = GPS_ENC_SUPL_GSM_DEFAULT; // SS_LANGUAGE_UNSPEC = GSM + break; + default: + break; + } + + return enc; +} + +/*convert NI notify verify type from QMI LOC to loc eng format*/ +bool LocApiV02Adapter :: convertNiNotifyVerifyType ( + GpsNiNotification *notif, + qmiLocNiNotifyVerifyEnumT_v02 notif_priv) +{ + switch (notif_priv) + { + case eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02: + notif->notify_flags = 0; + break; + + case eQMI_LOC_NI_USER_NOTIFY_ONLY_V02: + notif->notify_flags = GPS_NI_NEED_NOTIFY; + break; + + case eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02: + notif->notify_flags = GPS_NI_NEED_NOTIFY | GPS_NI_NEED_VERIFY; + notif->default_response = GPS_NI_RESPONSE_ACCEPT; + break; + + case eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02: + notif->notify_flags = GPS_NI_NEED_NOTIFY | GPS_NI_NEED_VERIFY; + notif->default_response = GPS_NI_RESPONSE_DENY; + break; + + case eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02: + notif->notify_flags = GPS_NI_PRIVACY_OVERRIDE; + break; + + default: + return false; + } + + return true; +} + +/* event callback registered with the loc_api v02 interface */ +void LocApiV02Adapter :: eventCb(locClientHandleType clientHandle, + uint32_t eventId, locClientEventIndUnionType eventPayload) +{ + LOC_LOGD("%s:%d]: event id = %d\n", __func__, __LINE__, + eventId); + + switch(eventId) + { + //Position Report + case QMI_LOC_EVENT_POSITION_REPORT_IND_V02: + reportPosition(eventPayload.pPositionReportEvent); + break; + + // Satellite report + case QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02: + reportSv(eventPayload.pGnssSvInfoReportEvent); + break; + + // Status report + case QMI_LOC_EVENT_ENGINE_STATE_IND_V02: + reportEngineState(eventPayload.pEngineState); + break; + + case QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02: + reportFixSessionState(eventPayload.pFixSessionState); + break; + + // NMEA + case QMI_LOC_EVENT_NMEA_IND_V02: + reportNmea(eventPayload.pNmeaReportEvent); + break; + + // XTRA request + case QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02: + LOC_LOGD("%s:%d]: XTRA download request\n", __func__, + __LINE__); + requestXtraData(); + break; + + // time request + case QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02: + LOC_LOGD("%s:%d]: Time request\n", __func__, + __LINE__); + requestTime(); + break; + + //position request + case QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02: + LOC_LOGD("%s:%d]: Position request\n", __func__, + __LINE__); + //requestPosition(); + break; + + // NI request + case QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02: + reportNiRequest(eventPayload.pNiNotifyVerifyReqEvent); + break; + + // AGPS connection request + case QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02: + reportAtlRequest(eventPayload.pLocationServerConnReqEvent); + break; + } +} + +/* Call the service LocApiAdapter down event*/ +void LocApiV02Adapter :: errorCb(locClientHandleType handle, + locClientErrorEnumType errorId) +{ + if(errorId == eLOC_CLIENT_ERROR_SERVICE_UNAVAILABLE) + { + LOC_LOGE("%s:%d]: Service unavailable error\n", + __func__, __LINE__); + + LocApiAdapter::handleEngineDownEvent(); + + /* immediately send the engine up event so that + the loc engine re-initializes the adapter and the + loc-api_v02 interface */ + + LocApiAdapter::handleEngineUpEvent(); + } +} + +/* return a Loc API adapter */ +LocApiAdapter* getLocApiAdapter(LocEng &locEng) +{ + return(new LocApiV02Adapter(locEng)); +} diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.h b/loc_api/loc_api_v02/LocApiV02Adapter.h new file mode 100755 index 00000000..487e98eb --- /dev/null +++ b/loc_api/loc_api_v02/LocApiV02Adapter.h @@ -0,0 +1,197 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_API_V_0_2_ADAPTER_H +#define LOC_API_V_0_2_ADAPTER_H + +#include +#include "loc_api_v02_client.h" +#include +#include + +/* Fix criteria structure*/ +struct LocApiV02FixCriteria +{ + LocPositionMode mode; + GpsPositionRecurrence recurrence; + uint32_t min_interval ; + uint32_t preferred_accuracy ; + uint32_t preferred_time; + + /* Constructor for the structure */ + inline LocApiV02FixCriteria (LocPositionMode mode, + GpsPositionRecurrence recur, + uint32_t min_int, + uint32_t pref_acc, + uint32_t pref_time) : + mode(mode), recurrence(recur), min_interval(min_int), + preferred_accuracy(pref_acc), preferred_time(pref_time) {} +}; + +/* This class derives from the LocApiAdapter class. + The members of this class are responsible for converting + the Loc API V02 data structures into Loc Engine data structures. + This class also implements some of the virtual functions that + handle the requests from loc engine. */ +class LocApiV02Adapter : public LocApiAdapter { + + /* loc api v02 handle*/ + locClientHandleType clientHandle; + + /* events the client is registered for */ + locClientEventMaskType eventMask; + + /* current session state */ + bool navigating; + + /* current fix criteria, for Loc aPI V02 this is + stored when set_position_mode is called and + sent out with Loc aPI V02 start message when the + start_fix() is called by loc engine. */ + LocApiV02FixCriteria fixCriteria; + + /* Convert event mask from loc eng to loc_api_v02 format */ + locClientEventMaskType convertMask(LOC_API_ADAPTER_EVENT_MASK_T mask); + + /* Convert error from loc_api_v02 to loc eng format*/ + enum loc_api_adapter_err convertErr(locClientStatusEnumType status); + + /* convert Ni Encoding type from QMI_LOC to loc eng format */ + GpsNiEncodingType convertNiEncoding( + qmiLocNiDataCodingSchemeEnumT_v02 loc_encoding); + + /*convert NI notify verify type from QMI LOC to loc eng format*/ + bool convertNiNotifyVerifyType (GpsNiNotification *notif, + qmiLocNiNotifyVerifyEnumT_v02 notif_priv); + + /* close Loc API V02 client */ + int deInitLocClient(); + + /* convert position report to loc eng format and send the converted + position to loc eng */ + void reportPosition + (const qmiLocEventPositionReportIndMsgT_v02 *location_report_ptr); + + /* convert satellite report to loc eng format and send the converted + report to loc eng */ + void reportSv (const qmiLocEventGnssSvInfoIndMsgT_v02 *gnss_report_ptr); + + /* convert engine state report to loc eng format and send the converted + report to loc eng */ + void reportEngineState ( + const qmiLocEventEngineStateIndMsgT_v02 *engine_state_ptr); + + /* convert fix session report to loc eng format and send the converted + report to loc eng */ + void reportFixSessionState ( + const qmiLocEventFixSessionStateIndMsgT_v02 *fix_session_state_ptr); + + /* convert NMEA report to loc eng format and send the converted + report to loc eng */ + void reportNmea (const qmiLocEventNmeaIndMsgT_v02 *nmea_report_ptr); + + /* convert and report an ATL request to loc engine */ + void reportAtlRequest( + const qmiLocEventLocationServerConnectionReqIndMsgT_v02 + *server_request_ptr); + + /* convert and report NI request to loc eng */ + void reportNiRequest( + const qmiLocEventNiNotifyVerifyReqIndMsgT_v02 *ni_req_ptr); + +public: + LocApiV02Adapter(LocEng &locEng); + ~LocApiV02Adapter(); + + /* event callback registered with the loc_api v02 interface */ + void eventCb(locClientHandleType client_handle, + uint32_t loc_event_id, + locClientEventIndUnionType loc_event_payload); + + /* error callback, this function handles the service unavailable + error */ + void errorCb(locClientHandleType handle, + locClientErrorEnumType errorId); + + virtual enum loc_api_adapter_err reinit(); + + virtual enum loc_api_adapter_err startFix(); + + virtual enum loc_api_adapter_err stopFix(); + + virtual enum loc_api_adapter_err + setPositionMode(LocPositionMode mode, GpsPositionRecurrence recurrence, + uint32_t min_interval, uint32_t preferred_accuracy, + uint32_t preferred_time); + + virtual enum loc_api_adapter_err + setTime(GpsUtcTime time, int64_t timeReference, int uncertainty); + + virtual enum loc_api_adapter_err + injectPosition(double latitude, double longitude, float accuracy); + + virtual enum loc_api_adapter_err + deleteAidingData(GpsAidingData f); + + virtual enum loc_api_adapter_err + informNiResponse(GpsUserResponseType userResponse, + const void* passThroughData); + + virtual enum loc_api_adapter_err + setServer(const char* url, int len); + virtual enum loc_api_adapter_err + setServer(unsigned int ip, int port, LocServerType type); + virtual enum loc_api_adapter_err + setXtraData(char* data, int length); +#ifdef QCOM_FEATURE_IPV6 + virtual enum loc_api_adapter_err + atlOpenStatus(int handle, int is_succ, char* apn, AGpsBearerType bear, + AGpsType agpsType); +#else + virtual enum loc_api_adapter_err + atlOpenStatus(int handle, int is_succ, char* apn, + AGpsType agpsType); +#endif + virtual enum loc_api_adapter_err atlCloseStatus(int handle, int is_succ); + virtual enum loc_api_adapter_err setSUPLVersion(uint32_t version); + + virtual enum loc_api_adapter_err + setSensorControlConfig(int sensorUsage); + + virtual enum loc_api_adapter_err + setSensorProperties(float gyroBiasVarianceRandomWalk); + + virtual enum loc_api_adapter_err + setSensorPerfControlConfig(int controlMode, + int accelSamplesPerBatch, + int accelBatchesPerSec, + int gyroSamplesPerBatch, + int gyroBatchesPerSec); +}; + +#endif //LOC_API_V_0_2_ADAPTER_H diff --git a/loc_api/loc_api_v02/loc_api_sync_req.c b/loc_api/loc_api_v02/loc_api_sync_req.c new file mode 100755 index 00000000..b75f1630 --- /dev/null +++ b/loc_api/loc_api_v02/loc_api_sync_req.c @@ -0,0 +1,548 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "loc_api_v02_client.h" +#include "loc_api_v02_log.h" +#include "loc_api_sync_req.h" + +/* Logging */ +// Uncomment to log verbose logs +#define LOG_NDEBUG 1 + +// log debug logs +#define LOG_NDDEBUG 1 +#define LOG_TAG "LocSvc_api_v02" +#include "loc_util_log.h" + +#define LOC_SYNC_REQ_BUFFER_SIZE 8 + +pthread_mutex_t loc_sync_call_mutex = PTHREAD_MUTEX_INITIALIZER; + +static bool loc_sync_call_initialized = false; + +typedef struct { + pthread_mutex_t sync_req_lock; + + /* Client ID */ + locClientHandleType client_handle; + + /* waiting conditional variable */ + pthread_cond_t ind_arrived_cond; + + /* Callback waiting data block, protected by loc_cb_data_mutex */ + bool ind_is_selected; /* is cb selected? */ + bool ind_is_waiting; /* is waiting? */ + bool ind_has_arrived; /* callback has arrived */ + uint32_t req_id; /* sync request */ + void *recv_ind_payload_ptr; /* received payload */ + uint32_t recv_ind_id; /* received ind */ + +} loc_sync_req_data_s_type; + +typedef struct { + bool in_use; /* at least one sync call is active */ + bool slot_in_use[LOC_SYNC_REQ_BUFFER_SIZE]; + loc_sync_req_data_s_type slots[LOC_SYNC_REQ_BUFFER_SIZE]; +} loc_sync_req_array_s_type; + +/*************************************************************************** + * DATA FOR ASYNCHRONOUS RPC PROCESSING + **************************************************************************/ +loc_sync_req_array_s_type loc_sync_array; + +/*=========================================================================== + +FUNCTION loc_sync_req_init + +DESCRIPTION + Initialize this module + +DEPENDENCIES + N/A + +RETURN VALUE + none + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_sync_req_init() +{ + LOC_LOGV(" %s:%d]:\n", __func__, __LINE__); + pthread_mutex_lock(&loc_sync_call_mutex); + if(true == loc_sync_call_initialized) + { + LOC_LOGD("%s:%d]:already initialized\n", __func__, __LINE__); + pthread_mutex_unlock(&loc_sync_call_mutex); + return; + } + + loc_sync_array.in_use = false; + + memset(loc_sync_array.slot_in_use, 0, sizeof(loc_sync_array.slot_in_use)); + + int i; + for (i = 0; i < LOC_SYNC_REQ_BUFFER_SIZE; i++) + { + loc_sync_req_data_s_type *slot = &loc_sync_array.slots[i]; + + pthread_mutex_init(&slot->sync_req_lock, NULL); + pthread_cond_init(&slot->ind_arrived_cond, NULL); + + slot->client_handle = LOC_CLIENT_INVALID_HANDLE_VALUE; + slot->ind_is_selected = false; /* is ind selected? */ + slot->ind_is_waiting = false; /* is waiting? */ + slot->ind_has_arrived = false; /* callback has arrived */ + slot->recv_ind_id = 0; /* ind to wait for */ + slot->recv_ind_payload_ptr = NULL; + slot->req_id = 0; /* req id */ + } + + loc_sync_call_initialized = true; + pthread_mutex_unlock(&loc_sync_call_mutex); +} + + +/*=========================================================================== + +FUNCTION loc_sync_process_ind + +DESCRIPTION + Wakes up blocked API calls to check if the needed callback has arrived + +DEPENDENCIES + N/A + +RETURN VALUE + none + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_sync_process_ind( + locClientHandleType client_handle, /* handle of the client */ + uint32_t ind_id , /* ind id */ + void *ind_payload_ptr /* payload */ +) +{ + + LOC_LOGV("%s:%d]: received indication, handle = %d ind_id = %d \n", + __func__,__LINE__, client_handle, ind_id); + + pthread_mutex_lock(&loc_sync_call_mutex); + + if (!loc_sync_array.in_use) + { + LOC_LOGD("%s:%d]: loc_sync_array not in use \n", + __func__, __LINE__); + pthread_mutex_unlock(&loc_sync_call_mutex); + return; + } + + bool in_use = false, consumed = false; + int i; + + for (i = 0; i < LOC_SYNC_REQ_BUFFER_SIZE && !consumed; i++) + { + loc_sync_req_data_s_type *slot = &loc_sync_array.slots[i]; + + in_use |= loc_sync_array.slot_in_use[i]; + + pthread_mutex_lock(&slot->sync_req_lock); + + if ( (loc_sync_array.slot_in_use[i]) && (slot->client_handle == client_handle) + && (ind_id == slot->recv_ind_id) && (!slot->ind_has_arrived)) + { + // copy the payload to the slot waiting for this ind + size_t payload_size = 0; + + LOC_LOGV("%s:%d]: found slot %d selected for ind %u \n", + __func__, __LINE__, i, ind_id); + + if(true == locClientGetSizeByRespIndId(ind_id, &payload_size) && + NULL != slot->recv_ind_payload_ptr && NULL != ind_payload_ptr) + { + LOC_LOGV("%s:%d]: copying ind payload size = %u \n", + __func__, __LINE__, payload_size); + + memcpy(slot->recv_ind_payload_ptr, ind_payload_ptr, payload_size); + + consumed = true; + + } + /* Received a callback while waiting, wake up thread to check it */ + if (slot->ind_is_waiting) + { + slot->recv_ind_id = ind_id; + + pthread_cond_signal(&slot->ind_arrived_cond); + } + else + { + /* If callback arrives before wait, remember it */ + LOC_LOGV("%s:%d]: ind %u arrived before wait was called \n", + __func__, __LINE__, ind_id); + + slot->ind_has_arrived = true; + } + } + pthread_mutex_unlock(&slot->sync_req_lock); + } + + if (!in_use) { + loc_sync_array.in_use = false; + } + + pthread_mutex_unlock(&loc_sync_call_mutex); +} + +/*=========================================================================== + +FUNCTION loc_alloc_slot + +DESCRIPTION + Allocates a buffer slot for the synchronous API call + +DEPENDENCIES + N/A + +RETURN VALUE + Select ID (>=0) : successful + -1 : buffer full + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_alloc_slot() +{ + int i, select_id = -1; /* no free buffer */ + + pthread_mutex_lock(&loc_sync_call_mutex); + + for (i = 0; i < LOC_SYNC_REQ_BUFFER_SIZE; i++) + { + if (!loc_sync_array.slot_in_use[i]) + { + select_id = i; + loc_sync_array.slot_in_use[i] = 1; + loc_sync_array.in_use = true; + break; + } + } + + pthread_mutex_unlock(&loc_sync_call_mutex); + LOC_LOGV("%s:%d]: returning slot %d\n", + __func__, __LINE__, select_id); + return select_id; +} + +/*=========================================================================== + +FUNCTION loc_free_slot + +DESCRIPTION + Frees a buffer slot after the synchronous API call + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_free_slot(int select_id) +{ + int i; + loc_sync_req_data_s_type *slot; + + pthread_mutex_lock(&loc_sync_call_mutex); + + LOC_LOGD("%s:%d]: freeing slot %d\n", __func__, __LINE__, select_id); + + loc_sync_array.slot_in_use[select_id] = 0; + + slot = &loc_sync_array.slots[select_id]; + + slot->client_handle = LOC_CLIENT_INVALID_HANDLE_VALUE; + slot->ind_is_selected = false; /* is ind selected? */ + slot->ind_is_waiting = false; /* is waiting? */ + slot->ind_has_arrived = false; /* callback has arrived */ + slot->recv_ind_id = 0; /* ind to wait for */ + slot->recv_ind_payload_ptr = NULL; + slot->req_id = 0; + + // check if all slots are now free + for (i = 0; i < LOC_SYNC_REQ_BUFFER_SIZE; i++) + { + if (loc_sync_array.slot_in_use[i]) break; + } + + if (i >= LOC_SYNC_REQ_BUFFER_SIZE) + { + loc_sync_array.in_use = false; + } + + pthread_mutex_unlock(&loc_sync_call_mutex); +} + +/*=========================================================================== + +FUNCTION loc_sync_select_ind + +DESCRIPTION + Selects which indication to wait for. + + +DEPENDENCIES + N/A + +RETURN VALUE + Select ID (>=0) : successful + -ENOMEM : out of buffer + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_sync_select_ind( + locClientHandleType client_handle, /* Client handle */ + uint32_t ind_id, /* ind Id wait for */ + uint32_t req_id, /* req id */ + void * ind_payload_ptr /* ptr where payload should be copied to*/ +) +{ + int select_id = loc_alloc_slot(); + + LOC_LOGV("%s:%d]: client handle %d, ind_id %u, req_id %u \n", + __func__, __LINE__, client_handle, ind_id, req_id); + + if (select_id < 0) + { + LOC_LOGE("%s:%d]: buffer full for this synchronous req %s \n", + __func__, __LINE__, loc_get_v02_event_name(req_id)); + return -ENOMEM; + } + + loc_sync_req_data_s_type *slot = &loc_sync_array.slots[select_id]; + + pthread_mutex_lock(&slot->sync_req_lock); + + slot->client_handle = client_handle; + slot->ind_is_selected = true; + slot->ind_is_waiting = false; + slot->ind_has_arrived = false; + + slot->recv_ind_id = ind_id; + slot->req_id = req_id; + slot->recv_ind_payload_ptr = ind_payload_ptr; //store the payload ptr + + pthread_mutex_unlock(&slot->sync_req_lock); + + return select_id; +} + + +/*=========================================================================== + +FUNCTION loc_sync_wait_for_ind + +DESCRIPTION + Waits for a selected indication. The wait expires in timeout_seconds seconds. + If the function is called before an existing wait has finished, it will + immediately return error. + +DEPENDENCIES + N/A + +RETURN VALUE + 0 on SUCCESS, -ve value on failure + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_sync_wait_for_ind( + int select_id, /* ID from loc_sync_select_ind() */ + int timeout_seconds, /* Timeout in this number of seconds */ + uint32_t ind_id +) +{ + if (select_id < 0 || select_id >= LOC_SYNC_REQ_BUFFER_SIZE || !loc_sync_array.slot_in_use[select_id]) + { + LOC_LOGE("%s:%d]: invalid select_id: %d \n", + __func__, __LINE__, select_id); + + return (-EINVAL); + } + + loc_sync_req_data_s_type *slot = &loc_sync_array.slots[select_id]; + + int ret_val = 0; /* the return value of this function: 0 = no error */ + int rc; /* return code from pthread calls */ + + struct timeval present_time; + struct timespec expire_time; + + pthread_mutex_lock(&slot->sync_req_lock); + + do + { + if (slot->ind_has_arrived) + { + ret_val = 0; /* success */ + break; + } + + if (slot->ind_is_waiting) + { + LOC_LOGW("%s:%d]: already waiting in this slot %d\n", __func__, + __LINE__, select_id); + ret_val = -EBUSY; // busy + break; + } + + /* Calculate absolute expire time */ + gettimeofday(&present_time, NULL); + expire_time.tv_sec = present_time.tv_sec; + expire_time.tv_nsec = present_time.tv_usec * 1000; + expire_time.tv_sec += timeout_seconds; + + /* Take new wait request */ + slot->ind_is_waiting = true; + + /* Waiting */ + rc = pthread_cond_timedwait(&slot->ind_arrived_cond, + &slot->sync_req_lock, &expire_time); + + slot->ind_is_waiting = false; + + if(rc == ETIMEDOUT) + { + LOC_LOGE("%s:%d]: slot %d, timed out for ind_id %s\n", + __func__, __LINE__, select_id, loc_get_v02_event_name(ind_id)); + ret_val = -ETIMEDOUT; //time out + } + + } while (0); + + pthread_mutex_unlock(&slot->sync_req_lock); + loc_free_slot(select_id); + + return ret_val; +} + +/*=========================================================================== + +FUNCTION loc_sync_send_req + +DESCRIPTION + Synchronous req call (thread safe) + +DEPENDENCIES + N/A + +RETURN VALUE + Loc API 2.0 status + +SIDE EFFECTS + N/A + +===========================================================================*/ +locClientStatusEnumType loc_sync_send_req +( + locClientHandleType client_handle, + uint32_t req_id, /* req id */ + locClientReqUnionType req_payload, + uint32_t timeout_msec, + uint32_t ind_id, //ind ID to block for, usually the same as req_id */ + void *ind_payload_ptr /* can be NULL*/ +) +{ + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS ; + int select_id; + int rc = 0; + + // Select the callback we are waiting for + select_id = loc_sync_select_ind(client_handle, ind_id, req_id, + ind_payload_ptr); + + if (select_id >= 0) + { + status = locClientSendReq (client_handle, req_id, req_payload); + LOC_LOGV("%s:%d]: select_id = %d,locClientSendReq returned %d\n", + __func__, __LINE__, select_id, status); + + if (status != eLOC_CLIENT_SUCCESS ) + { + loc_free_slot(select_id); + } + else + { + // Wait for the indication callback + if (( rc = loc_sync_wait_for_ind( select_id, + timeout_msec / 1000, + ind_id) ) < 0) + { + if ( rc == -ETIMEDOUT) + status = eLOC_CLIENT_FAILURE_TIMEOUT; + else + status = eLOC_CLIENT_FAILURE_INTERNAL; + + // Callback waiting failed + LOC_LOGE("%s:%d]: loc_api_wait_for_ind failed, err %d, " + "select id %d, status %s", __func__, __LINE__, rc , + select_id, loc_get_v02_client_status_name(status)); + } + else + { + status = eLOC_CLIENT_SUCCESS; + LOC_LOGV("%s:%d]: success (select id %d)\n", + __func__, __LINE__, select_id); + } + } + } /* select id */ + + return status; +} + + diff --git a/loc_api/loc_api_v02/loc_api_sync_req.h b/loc_api/loc_api_v02/loc_api_sync_req.h new file mode 100755 index 00000000..8c7f7f19 --- /dev/null +++ b/loc_api/loc_api_v02/loc_api_sync_req.h @@ -0,0 +1,68 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef LOC_SYNC_REQ_H +#define LOC_SYNC_REQ_H + +#ifdef __cplusplus +extern "C" +{ +#endif +#include +#include +#include "loc_api_v02_client.h" + +#define LOC_ENGINE_SYNC_REQUEST_TIMEOUT (1000) // 1 second + +/* Init function */ +extern void loc_sync_req_init(); + + +/* Process Loc API indications to wake up blocked user threads */ +extern void loc_sync_process_ind( + locClientHandleType client_handle, /* handle of the client */ + uint32_t ind_id , /* respInd id */ + void *ind_payload_ptr /* payload */ +); + +/* Thread safe synchronous request, using Loc API status return code */ +extern locClientStatusEnumType loc_sync_send_req +( + locClientHandleType client_handle, + uint32_t req_id, /* req id */ + locClientReqUnionType req_payload, + uint32_t timeout_msec, + uint32_t ind_id, //ind ID to block for, usually the same as req_id */ + void *ind_payload_ptr /* can be NULL*/ +); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_SYNC_REQ_H */ diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c new file mode 100755 index 00000000..4d34adc4 --- /dev/null +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -0,0 +1,1867 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "qmi_client.h" +#include "qmi_idl_lib.h" +#include "qmi_cci_target_ext.h" + +#if defined( _ANDROID_) +#include "qmi_cci_target.h" +#include "qmi_cci_common.h" +#elif defined(LOC_UTIL_TARGET_OFF_TARGET) +#include +#include +#include +#endif //_ANDROID_ + +#include +#include +#include +#include +#include +#include "loc_api_v02_client.h" +#include "loc_api_v02_log.h" + +#define LOG_NDEBUG 0 +#define LOG_TAG "LocSvc_api_v02" + +#include "loc_util_log.h" + +#ifdef LOC_UTIL_TARGET_OFF_TARGET + +// timeout in ms before send_msg_sync should return +#define LOC_CLIENT_ACK_TIMEOUT (5000) + +// timeout in ms before a sync request should return +#define LOC_CLIENT_SYNC_REQ_TIMEOUT (5000) + +#else + +// timeout in ms before send_msg_sync should return +#define LOC_CLIENT_ACK_TIMEOUT (1000) + +// timeout in ms before a sync request should return +#define LOC_CLIENT_SYNC_REQ_TIMEOUT (1000) + +#endif //LOC_UTIL_TARGET_OFF_TARGET + +//timeout in ms to wait for the service to come up +#define LOC_CLIENT_SERVICE_TIMEOUT (20000) + +/* Table to relate eventId, size and mask value used to enable the event*/ +typedef struct +{ + uint32_t eventId; + size_t eventSize; + locClientEventMaskType eventMask; +}locClientEventIndTableStructT; + + +static locClientEventIndTableStructT locClientEventIndTable[]= { + + // position report ind + { QMI_LOC_EVENT_POSITION_REPORT_IND_V02, + sizeof(qmiLocEventPositionReportIndMsgT_v02), + QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 }, + + // satellite report ind + { QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, + sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), + QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 }, + + // NMEA report ind + { QMI_LOC_EVENT_NMEA_IND_V02, + sizeof(qmiLocEventNmeaIndMsgT_v02), + QMI_LOC_EVENT_MASK_NMEA_V02 }, + + //NI event ind + { QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, + sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 }, + + //Time Injection Request Ind + { QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, + sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 }, + + //Predicted Orbits Injection Request + { QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, + sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 }, + + //Position Injection Request Ind + { QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, + sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 } , + + //Engine State Report Ind + { QMI_LOC_EVENT_ENGINE_STATE_IND_V02, + sizeof(qmiLocEventEngineStateIndMsgT_v02), + QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 }, + + //Fix Session State Report Ind + { QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, + sizeof(qmiLocEventFixSessionStateIndMsgT_v02), + QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 }, + + //Wifi Request Indication + { QMI_LOC_EVENT_WIFI_REQ_IND_V02, + sizeof(qmiLocEventWifiReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_WIFI_REQ_V02 }, + + //Sensor Streaming Ready Status Ind + { QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, + sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), + QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 }, + + // Time Sync Request Indication + { QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, + sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 }, + + //Set Spi Streaming Report Event + { QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, + sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), + QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 }, + + //Location Server Connection Request event + { QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, + sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), + QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 } +}; + +/* table to relate the respInd Id with its size */ +typedef struct +{ + uint32_t respIndId; + size_t respIndSize; +}locClientRespIndTableStructT; + +static locClientRespIndTableStructT locClientRespIndTable[]= { + + // get service revision ind + { QMI_LOC_GET_SERVICE_REVISION_IND_V02, + sizeof(qmiLocGetServiceRevisionIndMsgT_v02)}, + + // Get Fix Criteria Resp Ind + { QMI_LOC_GET_FIX_CRITERIA_IND_V02, + sizeof(qmiLocGetFixCriteriaIndMsgT_v02)}, + + // NI User Resp In + { QMI_LOC_NI_USER_RESPONSE_IND_V02, + sizeof(qmiLocNiUserRespIndMsgT_v02)}, + + //Inject Predicted Orbits Data Resp Ind + { QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, + sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02)}, + + //Get Predicted Orbits Data Src Resp Ind + { QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, + sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02)}, + + // Get Predicted Orbits Data Validity Resp Ind + { QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, + sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02)}, + + // Inject UTC Time Resp Ind + { QMI_LOC_INJECT_UTC_TIME_IND_V02, + sizeof(qmiLocInjectUtcTimeIndMsgT_v02)}, + + //Inject Position Resp Ind + { QMI_LOC_INJECT_POSITION_IND_V02, + sizeof(qmiLocInjectPositionIndMsgT_v02)}, + + //Set Engine Lock Resp Ind + { QMI_LOC_SET_ENGINE_LOCK_IND_V02, + sizeof(qmiLocSetEngineLockIndMsgT_v02)}, + + //Get Engine Lock Resp Ind + { QMI_LOC_GET_ENGINE_LOCK_IND_V02, + sizeof(qmiLocGetEngineLockIndMsgT_v02)}, + + //Set SBAS Config Resp Ind + { QMI_LOC_SET_SBAS_CONFIG_IND_V02, + sizeof(qmiLocSetSbasConfigIndMsgT_v02)}, + + //Get SBAS Config Resp Ind + { QMI_LOC_GET_SBAS_CONFIG_IND_V02, + sizeof(qmiLocGetSbasConfigIndMsgT_v02)}, + + //Set NMEA Types Resp Ind + { QMI_LOC_SET_NMEA_TYPES_IND_V02, + sizeof(qmiLocSetNmeaTypesIndMsgT_v02)}, + + //Get NMEA Types Resp Ind + { QMI_LOC_GET_NMEA_TYPES_IND_V02, + sizeof(qmiLocGetNmeaTypesIndMsgT_v02)}, + + //Set Low Power Mode Resp Ind + { QMI_LOC_SET_LOW_POWER_MODE_IND_V02, + sizeof(qmiLocSetLowPowerModeIndMsgT_v02)}, + + //Get Low Power Mode Resp Ind + { QMI_LOC_GET_LOW_POWER_MODE_IND_V02, + sizeof(qmiLocGetLowPowerModeIndMsgT_v02)}, + + //Set Server Resp Ind + { QMI_LOC_SET_SERVER_IND_V02, + sizeof(qmiLocSetServerIndMsgT_v02)}, + + //Get Server Resp Ind + { QMI_LOC_GET_SERVER_IND_V02, + sizeof(qmiLocGetServerIndMsgT_v02)}, + + //Delete Assist Data Resp Ind + { QMI_LOC_DELETE_ASSIST_DATA_IND_V02, + sizeof(qmiLocDeleteAssistDataIndMsgT_v02)}, + + //Set XTRA-T Session Control Resp Ind + { QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, + sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02)}, + + //Get XTRA-T Session Control Resp Ind + { QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, + sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02)}, + + //Inject Wifi Position Resp Ind + { QMI_LOC_INJECT_WIFI_POSITION_IND_V02, + sizeof(qmiLocInjectWifiPositionIndMsgT_v02)}, + + //Notify Wifi Status Resp Ind + { QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, + sizeof(qmiLocNotifyWifiStatusIndMsgT_v02)}, + + //Get Registered Events Resp Ind + { QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, + sizeof(qmiLocGetRegisteredEventsIndMsgT_v02)}, + + //Set Operation Mode Resp Ind + { QMI_LOC_SET_OPERATION_MODE_IND_V02, + sizeof(qmiLocSetOperationModeIndMsgT_v02)}, + + //Get Operation Mode Resp Ind + { QMI_LOC_GET_OPERATION_MODE_IND_V02, + sizeof(qmiLocGetOperationModeIndMsgT_v02)}, + + //Set SPI Status Resp Ind + { QMI_LOC_SET_SPI_STATUS_IND_V02, + sizeof(qmiLocSetSpiStatusIndMsgT_v02)}, + + //Inject Sensor Data Resp Ind + { QMI_LOC_INJECT_SENSOR_DATA_IND_V02, + sizeof(qmiLocInjectSensorDataIndMsgT_v02)}, + + //Inject Time Sync Data Resp Ind + { QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, + sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02)}, + + //Set Cradle Mount config Resp Ind + { QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, + sizeof(qmiLocSetCradleMountConfigIndMsgT_v02)}, + + //Get Cradle Mount config Resp Ind + { QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, + sizeof(qmiLocGetCradleMountConfigIndMsgT_v02)}, + + //Set External Power config Resp Ind + { QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, + sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02)}, + + //Get External Power config Resp Ind + { QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, + sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02)}, + + //Location server connection status + { QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, + sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02)}, + + //Set Protocol Config Parameters + { QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, + sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02)}, + + //Get Protocol Config Parameters + { QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, + sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02)}, + + //Set Sensor Control Config + { QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, + sizeof(qmiLocSetSensorControlConfigIndMsgT_v02)}, + + //Get Sensor Control Config + { QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, + sizeof(qmiLocGetSensorControlConfigIndMsgT_v02)}, + + //Set Sensor Properties + { QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, + sizeof(qmiLocSetSensorPropertiesIndMsgT_v02)}, + + //Get Sensor Properties + { QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, + sizeof(qmiLocGetSensorPropertiesIndMsgT_v02)}, + + //Set Sensor Performance Control Config + { QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, + sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02)}, + + //Get Sensor Performance Control Config + { QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, + sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02)}, + //Inject SUPL certificate + { QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, + sizeof(qmiLocInjectSuplCertificateIndMsgT_v02) }, + + //Delete SUPL certificate + { QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, + sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02) }, + + // Set Position Engine Config + { QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, + sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02)}, + + // Get Position Engine Config + { QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, + sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02)} + +}; + + +/** whether indication is an event or a response */ +typedef enum { eventIndType =0, respIndType = 1 } locClientIndEnumT; + + +/** @struct locClientInternalState + */ + +typedef struct +{ + // client cookie + void *pClientCookie; + //QCCI handle for this control point + qmi_client_type userHandle; + + // callbacks registered by the clients + locClientEventIndCbType eventCallback; + locClientRespIndCbType respCallback; + locClientErrorCbType errorCallback; + + // the event mask the client has registered for + locClientEventMaskType eventRegMask; + +}locClientCallbackDataType; + +/*=========================================================================== + * + * FUNCTION DECLARATION + * + *==========================================================================*/ + +/** locClientGetSizeAndTypeByIndId + * @brief this function gets the size and the type (event, + * response)of the indication structure from its ID + * @param [in] indId ID of the indication + * @param [out] type event or response indication + * @param [out] size size of the indications + * + * @return true if the ID was found, false otherwise */ + +static bool locClientGetSizeAndTypeByIndId (uint32_t indId, size_t *pIndSize, + locClientIndEnumT *pIndType) +{ + // look in the event table + if(true == locClientGetSizeByEventIndId(indId, pIndSize)) + { + *pIndType = eventIndType; + + LOC_LOGV("%s:%d]: indId %d is an event size = %d\n", __func__, __LINE__, + indId, (uint32_t)*pIndSize); + return true; + } + + //else look in response table + if(true == locClientGetSizeByRespIndId(indId, pIndSize)) + { + *pIndType = respIndType; + + LOC_LOGV("%s:%d]: indId %d is a resp size = %d\n", __func__, __LINE__, + indId, (uint32_t)*pIndSize); + return true; + } + + // Id not found + LOC_LOGW("%s:%d]: indId %d not found\n", __func__, __LINE__, indId); + return false; +} + +/** isClientRegisteredForEvent +* @brief checks the mask to identify if the client has +* registered for the specified event Id +* @param [in] eventIndId +* @param [in] eventRegMask +* @return true if client regstered for event; else false */ + +static bool isClientRegisteredForEvent( + locClientEventMaskType eventRegMask, + uint32_t eventIndId) +{ + size_t idx = 0, eventIndTableSize = 0; + + // look in the event table + eventIndTableSize = + (sizeof(locClientEventIndTable)/sizeof(locClientEventIndTableStructT)); + + for(idx=0; idxresp.result == QMI_RESULT_SUCCESS ) + { + status = eLOC_CLIENT_SUCCESS; + } + else + { + switch(pResponse->resp.error) + { + case QMI_ERR_MALFORMED_MSG_V01: + status = eLOC_CLIENT_FAILURE_INVALID_PARAMETER; + break; + + case QMI_ERR_DEVICE_IN_USE_V01: + status = eLOC_CLIENT_FAILURE_ENGINE_BUSY; + break; + + default: + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + } + LOC_LOGV("%s:%d]: result = %d, error = %d, status = %d\n", + __func__, __LINE__, pResponse->resp.result, + pResponse->resp.error, status); + return status; +} + +/** convertQmiErrorToLocError + @brief converts a qmi service error type to + locClientErrorEnumType + @param [in] error received QMI service. + @return locClientErrorEnumType corresponding to the error. +*/ + +static locClientErrorEnumType convertQmiErrorToLocError( + qmi_client_error_type error) +{ + locClientErrorEnumType locError ; + switch(error) + { + case QMI_SERVICE_ERR: + locError = eLOC_CLIENT_ERROR_SERVICE_UNAVAILABLE; + break; + + default: + locError = eLOC_CLIENT_ERROR_SERVICE_UNAVAILABLE; + break; + } + LOC_LOGV("%s:%d]: qmi error = %d, loc error = %d\n", + __func__, __LINE__, error, locError); + return locError; +} + +/** locClienHandlePosReportInd + * @brief Validates a position report ind + * @param [in] msg_id + * @param [in] ind_buf + * @param [in] ind_buf_len + * @return true if pos report is valid, false otherwise +*/ +static bool locClientHandlePosReportInd +( + uint32_t msg_id, + const void* ind_buf, + uint32_t ind_buf_len +) +{ + // validate position report + qmiLocEventPositionReportIndMsgT_v02 *posReport = + (qmiLocEventPositionReportIndMsgT_v02 *)ind_buf; + + LOC_LOGV ("%s:%d]: len = %d lat = %f, lon = %f, alt = %f\n", + __func__, __LINE__, ind_buf_len, + posReport->latitude, posReport->longitude, + posReport->altitudeWrtEllipsoid); + + return true; +} +//----------------------------------------------------------------------------- + +/** locClientHandleSatReportInd + * @brief Validates a satellite report indication. Dk + * @param [in] msg_id + * @param [in] ind_buf + * @param [in] ind_buf_len + * @return true if sat report is valid, false otherwise +*/ +static bool locClientHandleSatReportInd +( + uint32_t msg_id, + const void* ind_buf, + uint32_t ind_buf_len +) +{ + // validate sat reports + unsigned int idx = 0; + qmiLocEventGnssSvInfoIndMsgT_v02 *satReport = + (qmiLocEventGnssSvInfoIndMsgT_v02 *)ind_buf; + + LOC_LOGV ("%s:%d]: len = %u , altitude assumed = %u, num SV's = %u" + " validity = %d \n ", __func__, __LINE__, + ind_buf_len, satReport->altitudeAssumed, + satReport->svList_len, satReport->svList_valid); + //Log SV report + for( idx = 0; idx svList_len; idx++ ) + { + LOC_LOGV("%s:%d]: valid_mask = %x, prn = %u, system = %d, " + "status = %d \n", __func__, __LINE__, + satReport->svList[idx].validMask, satReport->svList[idx].gnssSvId, + satReport->svList[idx].system, satReport->svList[idx].svStatus); + } + + return true; +} + + +/** locClientHandleNmeaReportInd + * @brief Validate a NMEA report indication. + * @param [in] msg_id + * @param [in] ind_buf + * @param [in] ind_buf_len + * @return true if nmea report is valid, false otherwise +*/ + + +static bool locClientHandleNmeaReportInd +( + uint32_t msg_id, + const void* ind_buf, + uint32_t ind_buf_len +) +{ + // validate NMEA report + return true; +} + +/** locClientHandleGetServiceRevisionRespInd + * @brief Handles a Get Service Revision Rresponse indication. + * @param [in] msg_id + * @param [in] ind_buf + * @param [in] ind_buf_len + * @return true if service revision is valid, false otherwise +*/ + +static bool locClientHandleGetServiceRevisionRespInd +( + uint32_t msg_id, + const void* ind_buf, + uint32_t ind_buf_len +) +{ + LOC_LOGV("%s:%d] :\n", __func__, __LINE__); + return true; +} + +/** locClientHandleIndication + * @brief looks at each indication and calls the appropriate + * validation handler + * @param [in] indId + * @param [in] indBuffer + * @param [in] indSize + * @return true if indication was validated; else false */ + +static bool locClientHandleIndication( + uint32_t indId, + void* indBuffer, + size_t indSize + ) +{ + bool status = false; + switch(indId) + { + // handle the event indications + //------------------------------------------------------------------------- + + // handle position report + case QMI_LOC_EVENT_POSITION_REPORT_IND_V02: + { + status = locClientHandlePosReportInd(indId, indBuffer, indSize); + break; + } + // handle satellite report + case QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02: + { + status = locClientHandleSatReportInd(indId, indBuffer, indSize); + break; + } + + // handle NMEA report + case QMI_LOC_EVENT_NMEA_IND_V02: + { + status = locClientHandleNmeaReportInd(indId, indBuffer, indSize); + break; + } + + // handle NI Notify Verify Request Ind + case QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02: + { + // locClientHandleNiReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle Time Inject request Ind + case QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02: + { + // locClientHandleTimeInjectReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle XTRA data Inject request Ind + case QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02: + { + // locClientHandleXtraInjectReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle position inject request Ind + case QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02: + { + // locClientHandlePositionInjectReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle engine state Ind + case QMI_LOC_EVENT_ENGINE_STATE_IND_V02: + { + // locClientHandleEngineStateInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle fix session state Ind + case QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02: + { + // locClientHandleFixSessionStateInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle Wifi request Ind + case QMI_LOC_EVENT_WIFI_REQ_IND_V02: + { + // locClientHandleWifiReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle sensor streaming ready status Ind + case QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02: + { + // locClientHandleSensorStreamingReadyInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle time sync Ind + case QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02: + { + // locClientHandleTimeSyncReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // handle set streaming report ind + case QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02: + { + // locClientHandleSetSpiStreamingInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02: + { + //locClientHandleLocServerConnReqInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + //------------------------------------------------------------------------- + + // handle the response indications + //------------------------------------------------------------------------- + + // Get service Revision response indication + case QMI_LOC_GET_SERVICE_REVISION_IND_V02: + { + status = locClientHandleGetServiceRevisionRespInd(indId, + indBuffer, indSize); + break; + } + // predicted orbits data response indication + case QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02: + { + //locClientHandleInjectPredictedOrbitsDataInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_INJECT_SENSOR_DATA_IND_V02 : + { + //locClientHandleInjectSensorDataInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02: + { + //locClientHandleGetProtocolConfigParametersInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02: + { + //locClientHandleSetProtocolConfigParametersInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02: + { + //locClientHandleGetExtPowerConfigInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02: + { + //locClientHandleGetCradleMountConfigInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02: + { + //locClientHandleGetSensorControlConfigInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02: + { + //locClientHandleGetSensorPerformanceControlConfigInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02: + { + //locClientHandleGetSensorPropertiesInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02: + { + //locClientHandleSetSensorPerformanceControlConfigInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02: + { + // locClientHandleSetPositionEngineConfigParam( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02: + { + // locClientHandleSetPositionEngineConfigParam( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + // for indications that only have a "status" field + case QMI_LOC_NI_USER_RESPONSE_IND_V02: + case QMI_LOC_INJECT_UTC_TIME_IND_V02: + case QMI_LOC_INJECT_POSITION_IND_V02: + case QMI_LOC_SET_ENGINE_LOCK_IND_V02: + case QMI_LOC_SET_SBAS_CONFIG_IND_V02: + case QMI_LOC_SET_NMEA_TYPES_IND_V02: + case QMI_LOC_SET_LOW_POWER_MODE_IND_V02: + case QMI_LOC_SET_SERVER_IND_V02: + case QMI_LOC_DELETE_ASSIST_DATA_IND_V02: + case QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02: + case QMI_LOC_INJECT_WIFI_POSITION_IND_V02: + case QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02: + case QMI_LOC_SET_OPERATION_MODE_IND_V02: + case QMI_LOC_SET_SPI_STATUS_IND_V02: + case QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02: + case QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02: + case QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02: + case QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02: + case QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02: + case QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02: + case QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02: + case QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02: + { + status = true; + break; + } + default: + LOC_LOGW("%s:%d]: unknown ind id %d\n", __func__, __LINE__, + (uint32_t)indId); + status = false; + break; + } + return status; +} + + +/** locClientErrorCb + * @brief handles the QCCI error events, this is called by the + * QCCI infrastructure when the service is no longer + * available. + * @param [in] user handle + * @param [in] error + * @param [in] *err_cb_data + */ + +static void locClientErrorCb +( + qmi_client_type user_handle, + qmi_client_error_type error, + void *err_cb_data +) +{ + locClientCallbackDataType* pCallbackData = + (locClientCallbackDataType *)err_cb_data; + + /* copy the errorCallback function pointer from the callback + * data to local variable. This is to protect against the race + * condition between open/close and error callback. + */ + locClientErrorCbType localErrorCallback = + pCallbackData->errorCallback; + + LOC_LOGD("%s:%d]: Service Error %d received, pCallbackData = %p\n", + __func__, __LINE__, error, err_cb_data); + + /* call the error callback + * To avoid calling the errorCallback after locClientClose + * is called, check pCallbackData->errorCallback again here + */ + + if( (NULL != pCallbackData) && + (NULL != localErrorCallback) && + (NULL != pCallbackData->errorCallback) ) + { + //invoke the error callback for the corresponding client + localErrorCallback( + (locClientHandleType)pCallbackData, + convertQmiErrorToLocError(error), + pCallbackData->pClientCookie); + } +} + + +/** locClientIndCb + * @brief handles the indications sent from the service, if a + * response indication was received then the it is sent + * to the response callback. If a event indication was + * received then it is sent to the event callback + * @param [in] user handle + * @param [in] msg_id + * @param [in] ind_buf + * @param [in] ind_buf_len + * @param [in] ind_cb_data */ + +static void locClientIndCb +( + qmi_client_type user_handle, + unsigned int msg_id, + void *ind_buf, + unsigned int ind_buf_len, + void *ind_cb_data +) +{ + locClientIndEnumT indType; + size_t indSize = 0; + qmi_client_error_type rc ; + locClientCallbackDataType* pCallbackData = + (locClientCallbackDataType *)ind_cb_data; + + LOC_LOGV("%s:%d]: Indication: msg_id=%d buf_len=%d pCallbackData = %p\n", + __func__, __LINE__, (uint32_t)msg_id, ind_buf_len, + pCallbackData); + + // check callback data + if(NULL == pCallbackData) + { + LOC_LOGE("%s:%d]: invalid callback data", __func__, __LINE__); + return; + } + + // check user handle + if(memcmp(&pCallbackData->userHandle, &user_handle, sizeof(user_handle))) + { + LOC_LOGE("%s:%d]: invalid user_handle got 0x%x expected 0x%x\n", + __func__, __LINE__, + user_handle, pCallbackData->userHandle); + return; + } + // Get the indication size and type ( eventInd or respInd) + if( true == locClientGetSizeAndTypeByIndId(msg_id, &indSize, &indType)) + { + void *indBuffer = NULL; + + // if the client did not register for this event then just drop it + if( (eventIndType == indType) && + ( (NULL == pCallbackData->eventCallback) || + (false == isClientRegisteredForEvent(pCallbackData->eventRegMask, msg_id)) ) ) + { + LOC_LOGW("%s:%d]: client is not registered for event %d\n", + __func__, __LINE__, (uint32_t)msg_id); + return; + } + + // decode the indication + indBuffer = malloc(indSize); + + if(NULL == indBuffer) + { + LOC_LOGE("%s:%d]: memory allocation failed\n", __func__, __LINE__); + return; + } + + // decode the indication + rc = qmi_client_message_decode( + user_handle, + QMI_IDL_INDICATION, + msg_id, + ind_buf, + ind_buf_len, + indBuffer, + indSize); + + if( rc == QMI_NO_ERR ) + { + //validate indication + if (true == locClientHandleIndication(msg_id, indBuffer, indSize)) + { + if(eventIndType == indType) + { + locClientEventIndUnionType eventIndUnion; + + /* copy the eventCallback function pointer from the callback + * data to local variable. This is to protect against the race + * condition between open/close and indication callback. + */ + locClientEventIndCbType localEventCallback = + pCallbackData->eventCallback; + + // dummy event + eventIndUnion.pPositionReportEvent = + (qmiLocEventPositionReportIndMsgT_v02 *)indBuffer; + + /* call the event callback + * To avoid calling the eventCallback after locClientClose + * is called, check pCallbackData->eventCallback again here + */ + if((NULL != localEventCallback) && + (NULL != pCallbackData->eventCallback)) + { + localEventCallback( + (locClientHandleType)pCallbackData, + msg_id, + eventIndUnion, + pCallbackData->pClientCookie); + } + } + else if(respIndType == indType) + { + locClientRespIndUnionType respIndUnion; + + /* copy the respCallback function pointer from the callback + * data to local variable. This is to protect against the race + * condition between open/close and indication callback. + */ + locClientRespIndCbType localRespCallback = + pCallbackData->respCallback; + + // dummy to suppress compiler warnings + respIndUnion.pDeleteAssistDataInd = + (qmiLocDeleteAssistDataIndMsgT_v02 *)indBuffer; + + /* call the response callback + * To avoid calling the respCallback after locClientClose + * is called, check pCallbackData->respCallback again here + */ + if((NULL != localRespCallback) && + (NULL != pCallbackData->respCallback)) + { + localRespCallback( + (locClientHandleType)pCallbackData, + msg_id, + respIndUnion, + pCallbackData->pClientCookie); + } + } + } + else // error handling indication + { + LOC_LOGE("%s:%d]: Error handling the indication %d\n", + __func__, __LINE__, (uint32_t)msg_id); + } + } + else + { + LOC_LOGE("%s:%d]: Error decoding indication %d\n", + __func__, __LINE__, rc); + } + if(indBuffer) + { + free (indBuffer); + } + } + else // Id not found + { + LOC_LOGE("%s:%d]: Error indication not found %d\n", + __func__, __LINE__,(uint32_t)msg_id); + } + return; +} + + +/** locClientRegisterEventMask + * @brief registers the event mask with loc service + * @param [in] clientHandle + * @param [in] eventRegMask + * @return true if indication was validated; else false */ + +static bool locClientRegisterEventMask( + locClientHandleType clientHandle, + locClientEventMaskType eventRegMask) +{ + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; + locClientReqUnionType reqUnion; + qmiLocRegEventsReqMsgT_v02 regEventsReq; + + memset(®EventsReq, 0, sizeof(regEventsReq)); + + regEventsReq.eventRegMask = eventRegMask; + reqUnion.pRegEventsReq = ®EventsReq; + + status = locClientSendReq(clientHandle, + QMI_LOC_REG_EVENTS_REQ_V02, + reqUnion); + + if(eLOC_CLIENT_SUCCESS != status ) + { + LOC_LOGE("%s:%d] status %s\n", __func__, __LINE__, + loc_get_v02_client_status_name(status) ); + return false; + } + + return true; +} + +/** validateRequest + @brief validates the input request + @param [in] reqId request ID + @param [in] reqPayload Union of pointers to message payload + @param [out] ppOutData Pointer to void *data if successful + @param [out] pOutLen Pointer to length of data if succesful. + @return false on failure, true on Success +*/ + +static bool validateRequest( + uint32_t reqId, + const locClientReqUnionType reqPayload, + void **ppOutData, + uint32_t *pOutLen ) + +{ + bool noPayloadFlag = false; + + LOC_LOGV("%s:%d]: reqId = %d\n", __func__, __LINE__, reqId); + switch(reqId) + { + case QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02: + { + *pOutLen = sizeof(qmiLocInformClientRevisionReqMsgT_v02); + break; + } + + case QMI_LOC_REG_EVENTS_REQ_V02: + { + *pOutLen = sizeof(qmiLocRegEventsReqMsgT_v02); + break; + } + + case QMI_LOC_START_REQ_V02: + { + *pOutLen = sizeof(qmiLocStartReqMsgT_v02); + break; + } + + case QMI_LOC_STOP_REQ_V02: + { + *pOutLen = sizeof(qmiLocStopReqMsgT_v02); + break; + } + + case QMI_LOC_NI_USER_RESPONSE_REQ_V02: + { + *pOutLen = sizeof(qmiLocNiUserRespReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_UTC_TIME_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectUtcTimeReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_POSITION_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectPositionReqMsgT_v02); + break; + } + + case QMI_LOC_SET_ENGINE_LOCK_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetEngineLockReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SBAS_CONFIG_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetSbasConfigReqMsgT_v02); + break; + } + + case QMI_LOC_SET_NMEA_TYPES_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetNmeaTypesReqMsgT_v02); + break; + } + + case QMI_LOC_SET_LOW_POWER_MODE_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetLowPowerModeReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SERVER_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetServerReqMsgT_v02); + break; + } + + case QMI_LOC_DELETE_ASSIST_DATA_REQ_V02: + { + *pOutLen = sizeof(qmiLocDeleteAssistDataReqMsgT_v02); + break; + } + + case QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_WIFI_POSITION_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectWifiPositionReqMsgT_v02); + break; + } + + case QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02: + { + *pOutLen = sizeof(qmiLocNotifyWifiStatusReqMsgT_v02); + break; + } + + case QMI_LOC_SET_OPERATION_MODE_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetOperationModeReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SPI_STATUS_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetSpiStatusReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_SENSOR_DATA_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectSensorDataReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02); + break; + } + + case QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetCradleMountConfigReqMsgT_v02); + break; + } + + case QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02); + break; + } + + case QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02: + { + *pOutLen = sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02); + break; + } + + case QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02); + break; + } + + case QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02: + { + *pOutLen = sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetSensorControlConfigReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetSensorPropertiesReqMsgT_v02); + break; + } + + case QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectSuplCertificateReqMsgT_v02); + break; + } + case QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02: + { + *pOutLen = sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02); + break; + } + case QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02: + { + *pOutLen = sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02); + break; + } + case QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02: + { + *pOutLen = sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02); + break; + } + + // ALL requests with no payload + case QMI_LOC_GET_SERVICE_REVISION_REQ_V02: + case QMI_LOC_GET_FIX_CRITERIA_REQ_V02: + case QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02: + case QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02: + case QMI_LOC_GET_ENGINE_LOCK_REQ_V02: + case QMI_LOC_GET_SBAS_CONFIG_REQ_V02: + case QMI_LOC_GET_NMEA_TYPES_REQ_V02: + case QMI_LOC_GET_LOW_POWER_MODE_REQ_V02: + case QMI_LOC_GET_SERVER_REQ_V02: + case QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02: + case QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02: + case QMI_LOC_GET_OPERATION_MODE_REQ_V02: + case QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02: + case QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02: + case QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02: + case QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02: + case QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02: + { + noPayloadFlag = true; + break; + } + + default: + LOC_LOGW("%s:%d]: Error unknown reqId=%d\n", __func__, __LINE__, + reqId); + return false; + } + if(true == noPayloadFlag) + { + *ppOutData = NULL; + *pOutLen = 0; + } + else + { + //set dummy pointer for request union + *ppOutData = (void*) reqPayload.pInformClientRevisionReq; + } + LOC_LOGV("%s:%d]: reqId=%d, len = %d\n", __func__, __LINE__, + reqId, *pOutLen); + return true; +} + +/** locClientQmiCtrlPointInit + @brief wait for the service to come up or timeout; when the + service comes up initialize the control point and set + internal handle and indication callback. + @param pQmiClient, +*/ + +static locClientStatusEnumType locClientQmiCtrlPointInit( + locClientCallbackDataType *pLocClientCbData) +{ + uint32_t num_services, num_entries = 10; + qmi_client_type clnt, notifier; + qmi_client_os_params os_params; + + // num instances of this service + qmi_service_info serviceInfo[5]; + + qmi_client_error_type rc = QMI_NO_ERR; + + // Get the service object for the qmiLoc Service + qmi_idl_service_object_type locClientServiceObject = + loc_get_service_object_v02(); + + // Verify that qmiLoc_get_service_object did not return NULL + if (NULL == locClientServiceObject) + { + LOC_LOGE("%s:%d]: qmiLoc_get_service_object_v02 failed\n" , + __func__, __LINE__ ); + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + + // register for service notification + rc = qmi_client_notifier_init(locClientServiceObject, &os_params, ¬ifier); + + if(rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: qmi_client_notifier_init failed\n", + __func__, __LINE__ ); + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + /* If service is not up wait on a signal until the service is up + * or a timeout occurs. */ + + QMI_CCI_OS_SIGNAL_WAIT(&os_params, LOC_CLIENT_SERVICE_TIMEOUT); + + if(QMI_CCI_OS_SIGNAL_TIMED_OUT(&os_params)) + { + // timed out, return with error + LOC_LOGE("%s:%d]: timed out waiting for service\n", + __func__, __LINE__); + + return(eLOC_CLIENT_FAILURE_TIMEOUT); + } + else + { + // get the service addressing information + rc = qmi_client_get_service_list( locClientServiceObject, NULL, NULL, + &num_services); + LOC_LOGV("%s:%d]: qmi_client_get_service_list() returned %d " + "num_services = %d\n", __func__, __LINE__, rc, + num_services); + + if(rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: qmi_client_get_service_list failed even though" + "service is up !!!\n", __func__, __LINE__); + + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + } + + //get service info to be used in qmi_client_init + rc = qmi_client_get_service_list( locClientServiceObject, serviceInfo, + &num_entries, &num_services); + + LOC_LOGV("%s:%d]: qmi_client_get_service_list()" + " returned %d num_entries = %d num_services = %d\n", + __func__, __LINE__, + rc, num_entries, num_services); + + if(rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: qmi_client_get_service_list Error %d \n", + __func__, __LINE__, rc); + + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + LOC_LOGV("%s:%d]: passing the pointer %p to qmi_client_init \n", + __func__, __LINE__, pLocClientCbData); + // initialize the client + rc = qmi_client_init(&serviceInfo[0], locClientServiceObject, + locClientIndCb, (void *) pLocClientCbData, + NULL, &clnt); + + if(rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: qmi_client_init error %d\n", + __func__, __LINE__, rc); + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + LOC_LOGV("%s:%d]: passing the pointer %p to" + "qmi_client_register_error_cb \n", + __func__, __LINE__, pLocClientCbData); + + // register error callback + rc = qmi_client_register_error_cb(clnt, + locClientErrorCb, (void *) pLocClientCbData); + + if( QMI_NO_ERR != rc) + { + LOC_LOGE("%s:%d]: could not register QCCI error callback error:%d\n", + __func__, __LINE__, rc); + return (eLOC_CLIENT_FAILURE_INTERNAL); + } + + // copy the clnt handle returned in qmi_client_init + memcpy(&(pLocClientCbData->userHandle), &clnt, sizeof(qmi_client_type)); + + return(eLOC_CLIENT_SUCCESS); + +} +//----------------------- END INTERNAL FUNCTIONS ---------------------------------------- + +/** locClientOpen + @brief Connects a location client to the location engine. If the connection + is successful, returns a handle that the location client uses for + future location operations. + + @param [in] eventRegMask Mask of asynchronous events the client is + interested in receiving + @param [in] eventIndCb Function to be invoked to handle an event. + @param [in] respIndCb Function to be invoked to handle a response + indication. + @param [out] locClientHandle Handle to be used by the client + for any subsequent requests. + + @return + One of the following error codes: + - eLOC_CLIENT_SUCCESS -- If the connection is opened. + - non-zero error code(see locClientStatusEnumType)-- On failure. +*/ + +locClientStatusEnumType locClientOpen ( + locClientEventMaskType eventRegMask, + const locClientCallbacksType* pLocClientCallbacks, + locClientHandleType* pLocClientHandle, + const void* pClientCookie) +{ + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; + locClientCallbackDataType *pCallbackData = NULL; + + LOC_LOGV("%s:%d] \n", __func__, __LINE__); + + do + { + // check input parameters + if( (NULL == pLocClientCallbacks) || (NULL == pLocClientHandle) + || (NULL == pLocClientCallbacks->respIndCb) || + (pLocClientCallbacks->size != sizeof(locClientCallbacksType))) + { + LOC_LOGE("%s:%d]: Invalid parameters in locClientOpen\n", + __func__, __LINE__); + status = eLOC_CLIENT_FAILURE_INVALID_PARAMETER; + break; + } + + // Allocate memory for the callback data + pCallbackData = + ( locClientCallbackDataType*)calloc( + 1, sizeof(locClientCallbackDataType)); + + if(NULL == pCallbackData) + { + LOC_LOGE("%s:%d]: Could not allocate memory for callback data \n", + __func__, __LINE__); + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + /* Initialize the QMI control point; this function will block + * until a service is up or a timeout occurs. If the connection to + * the service succeeds the callback data will be filled in with + * a qmi_client value. + */ + + + EXIT_LOG_CALLFLOW(%s, "loc client open"); + status = locClientQmiCtrlPointInit(pCallbackData); + + LOC_LOGV ("%s:%d] locClientQmiCtrlPointInit returned %d\n", + __func__, __LINE__, status); + + if(status != eLOC_CLIENT_SUCCESS) + { + free(pCallbackData); + pCallbackData = NULL; + break; + } + + // set the handle to the callback data + *pLocClientHandle = (locClientHandleType)pCallbackData; + + if(true != locClientRegisterEventMask(*pLocClientHandle,eventRegMask)) + { + LOC_LOGE("%s:%d]: Error sending registration mask\n", + __func__, __LINE__); + + // release the client + locClientClose(pLocClientHandle); + + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + /* Initialize rest of the client structure now that the connection + * to the service has been created successfully. + */ + + //fill in the event callback + pCallbackData->eventCallback = pLocClientCallbacks->eventIndCb; + + //fill in the response callback + pCallbackData->respCallback = pLocClientCallbacks->respIndCb; + + //fill in the error callback + pCallbackData->errorCallback = pLocClientCallbacks->errorCb; + + //set the client event registration mask + pCallbackData->eventRegMask = eventRegMask; + + // set the client cookie + pCallbackData->pClientCookie = (void *)pClientCookie; + + LOC_LOGD("%s:%d]: returning handle = 0x%x, user_handle=0x%x, status = %d\n", + __func__, __LINE__, *pLocClientHandle, + pCallbackData->userHandle, status); + + }while(0); + + if(eLOC_CLIENT_SUCCESS != status) + { + *pLocClientHandle = LOC_CLIENT_INVALID_HANDLE_VALUE; + } + + return(status); +} + +/** locClientClose + @brief Disconnects a client from the location engine. + @param [in] pLocClientHandle Pointer to the handle returned by the + locClientOpen() function. + @return + One of the following error codes: + - 0 (eLOC_CLIENT_SUCCESS) - On success. + - non-zero error code(see locClientStatusEnumType) - On failure. +*/ + +locClientStatusEnumType locClientClose( + locClientHandleType* pLocClientHandle) +{ + qmi_client_error_type rc = QMI_NO_ERR; //No error + + if(NULL == pLocClientHandle) + { + // invalid handle + LOC_LOGE("%s:%d]: invalid pointer to handle \n", + __func__, __LINE__); + + return(eLOC_CLIENT_FAILURE_INVALID_PARAMETER); + } + + // convert handle to callback data + locClientCallbackDataType *pCallbackData = + (locClientCallbackDataType *)(*pLocClientHandle); + + LOC_LOGV("%s:%d]:\n", __func__, __LINE__ ); + + // check the input handle for sanity + if(NULL == pCallbackData || + NULL == pCallbackData->userHandle) + { + // invalid handle + LOC_LOGE("%s:%d]: invalid handle \n", + __func__, __LINE__); + + return(eLOC_CLIENT_FAILURE_INVALID_HANDLE); + } + + LOC_LOGV("locClientClose releasing handle 0x%x, user handle 0x%x\n", + *pLocClientHandle, pCallbackData->userHandle ); + + // NEXT call goes out to modem. We log the callflow before it + // actually happens to ensure the this comes before resp callflow + // back from the modem, to avoid confusing log order. We trust + // that the QMI framework is robust. + EXIT_LOG_CALLFLOW(%s, "loc client close"); + // release the handle + rc = qmi_client_release(pCallbackData->userHandle); + if(QMI_NO_ERR != rc ) + { + LOC_LOGW("%s:%d]: qmi_client_release error %d for client %p\n", + __func__, __LINE__, rc, pCallbackData->userHandle); + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + /* clear the memory allocated to callback data to minimize the chances + * of a race condition occurring between close and the indication + * callback + */ + memset(pCallbackData, 0, sizeof(*pCallbackData)); + + // free the memory assigned in locClientOpen + free(pCallbackData); + pCallbackData= NULL; + + // set the handle to invalid value + *pLocClientHandle = LOC_CLIENT_INVALID_HANDLE_VALUE; + + return eLOC_CLIENT_SUCCESS; +} + +/** locClientSendReq + @brief Sends a message to the location engine. If the locClientSendMsg() + function is successful, the client should expect an indication + (except start, stop, event reg and sensor injection messages), + through the registered callback in the locOpen() function. The + indication will contain the status of the request and if status is a + success, indication also contains the payload + associated with response. + @param [in] handle Handle returned by the locClientOpen() + function. + @param [in] reqId message ID of the request + @param [in] reqPayload Payload of the request, can be NULL + if request has no payload + + @return + One of the following error codes: + - 0 (eLOC_CLIENT_SUCCESS ) - On success. + - non-zero error code (see locClientStatusEnumType) - On failure. +*/ + +locClientStatusEnumType locClientSendReq( + locClientHandleType handle, + uint32_t reqId, + locClientReqUnionType reqPayload ) +{ + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; + qmi_client_error_type rc = QMI_NO_ERR; //No error + qmiLocGenRespMsgT_v02 resp; + uint32_t reqLen = 0; + void *pReqData = NULL; + locClientCallbackDataType *pCallbackData = + (locClientCallbackDataType *)handle; + + // check the input handle for sanity + if(NULL == pCallbackData || + NULL == pCallbackData->userHandle ) + { + // did not find the handle in the client List + LOC_LOGE("%s:%d]: invalid handle \n", + __func__, __LINE__); + + return(eLOC_CLIENT_FAILURE_INVALID_HANDLE); + } + + // validate that the request is correct + if (validateRequest(reqId, reqPayload, &pReqData, &reqLen) == false) + { + + LOC_LOGE("%s:%d] error invalid request\n", __func__, + __LINE__); + + return(eLOC_CLIENT_FAILURE_INVALID_PARAMETER); + } + + LOC_LOGV("%s:%d] sending reqId= %d, len = %d\n", __func__, + __LINE__, reqId, reqLen); + + // NEXT call goes out to modem. We log the callflow before it + // actually happens to ensure the this comes before resp callflow + // back from the modem, to avoid confusing log order. We trust + // that the QMI framework is robust. + EXIT_LOG_CALLFLOW(%s, loc_get_v02_event_name(reqId)); + + rc = qmi_client_send_msg_sync( + pCallbackData->userHandle, + reqId, + pReqData, + reqLen, + &resp, + sizeof(resp), + LOC_CLIENT_ACK_TIMEOUT); + + LOC_LOGV("%s:%d] qmi_client_send_msg_sync returned %d\n", __func__, + __LINE__, rc); + + if (rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: send_msg_sync error: %d\n",__func__, __LINE__, rc); + return(eLOC_CLIENT_FAILURE_INTERNAL); + } + + // map the QCCI response to Loc API v02 status + status = convertQmiResponseToLocStatus(&resp); + + return(status); +} + +/** locClientGetSizeByRespIndId + * @brief Get the size of the response indication structure, + * from a specified id + * @param [in] respIndId + * @param [out] pRespIndSize + * @return true if resp ID was found; else false +*/ + +bool locClientGetSizeByRespIndId(uint32_t respIndId, size_t *pRespIndSize) +{ + size_t idx = 0, respIndTableSize = 0; + respIndTableSize = (sizeof(locClientRespIndTable)/sizeof(locClientRespIndTableStructT)); + for(idx=0; idx +#include "location_service_v02.h" //QMI LOC Service data types definitions +#include +#include + +/****************************************************************************** + * Constants and configuration + *****************************************************************************/ + +/** @addtogroup constants_macros +@{ */ + +/** Specific value of #locClientHandleType, indicating an invalid handle. */ +#define LOC_CLIENT_INVALID_HANDLE_VALUE (NULL) + +/** @} */ /* end_addtogroup constants_macros */ + +/** @addtogroup data_types +@{ */ + +/** Location client handle used to represent a specific client. Negative values + are invalid handles. */ +typedef void* locClientHandleType; + +/** Data type for events and event masks. + @newpage */ +typedef uint64_t locClientEventMaskType; + +/** Location client status values. + @vertspace +*/ +typedef enum +{ + eLOC_CLIENT_SUCCESS = 0, + /**< Request was successful. */ + + eLOC_CLIENT_FAILURE_GENERAL = 1, + /**< Failed because of a general failure. */ + + eLOC_CLIENT_FAILURE_UNSUPPORTED = 2, + /**< Failed because the service does not support the command. */ + + eLOC_CLIENT_FAILURE_INVALID_PARAMETER = 3, + /**< Failed because the request contained invalid parameters. */ + + eLOC_CLIENT_FAILURE_ENGINE_BUSY = 4, + /**< Failed because the engine is busy. */ + + eLOC_CLIENT_FAILURE_PHONE_OFFLINE = 5, + /**< Failed because the phone is offline. */ + + eLOC_CLIENT_FAILURE_TIMEOUT = 6, + /**< Failed because of a timeout. */ + + eLOC_CLIENT_FAILURE_SERVICE_NOT_PRESENT = 7, + /**< Failed because the service is not present. */ + + eLOC_CLIENT_FAILURE_SERVICE_VERSION_UNSUPPORTED = 8, + /**< Failed because the service version is unsupported. */ + + eLOC_CLIENT_FAILURE_CLIENT_VERSION_UNSUPPORTED = 9, + /**< Failed because the service does not support client version. */ + + eLOC_CLIENT_FAILURE_INVALID_HANDLE = 10, + /**< Failed because an invalid handle was specified. */ + + eLOC_CLIENT_FAILURE_INTERNAL = 11, + /**< Failed because of an internal error in the service. */ + + eLOC_CLIENT_FAILURE_NOT_INITIALIZED = 12 + /**< Failed because the service has not been initialized. */ + +}locClientStatusEnumType; + +/** Loc Client error values +*/ + +typedef enum +{ + eLOC_CLIENT_ERROR_SERVICE_UNAVAILABLE = 1 + /**< Service is no longer available, the client should + close the existing connection and reopen the connection + upon getting this error. + */ +}locClientErrorEnumType; + + +/** @} */ /* end_addtogroup data_types */ + +/** @addtogroup send_request +@{ */ + +/** @brief Request messages the client can send to the location engine. + + The following requests do not have any data associated, so they do not have a + payload structure defined: + + - GetServiceRevision + - GetFixCriteria + - GetPredictedOrbitsDataSource + - GetPredictedOrbitsDataValidity + - GetEngineLock + - GetSbasConfigReq + - GetRegisteredEvents + - GetNmeaTypes + - GetLowPowerMode + - GetXtraTSessionControl + - GetRegisteredEvents + - GetOperationMode + - GetCradleMountConfig + - GetExternalPowerConfig +*/ +typedef union +{ + const qmiLocInformClientRevisionReqMsgT_v02* pInformClientRevisionReq; + /**< Notifies the service about the revision the client is using. + + The client does not receive any indications corresponding to this + request. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02. */ + + const qmiLocRegEventsReqMsgT_v02* pRegEventsReq; + /**< Changes the events the client is interested in receiving. + + The client does not receive any indications corresponding to this + request. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_REG_EVENTS_REQ_V02. */ + + const qmiLocStartReqMsgT_v02* pStartReq; + /**< Starts a positioning session. + + The client receives the following indications: position report, + satellite report, fix session report, and NMEA report (if applicable). + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_START_REQ_V02. */ + + const qmiLocStopReqMsgT_v02* pStopReq; + /**< Stops a positioning session. The client receives a fix session report + denoting that the fix session ended after this message was sent. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_STOP_REQ_V02. */ + + const qmiLocNiUserRespReqMsgT_v02* pNiUserRespReq; + /**< Informs the service about the user response for a network-initiated call. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_NI_USER_RESPONSE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_NI_USER_RESPONSE_REQ_V02. */ + + const qmiLocInjectPredictedOrbitsDataReqMsgT_v02* pInjectPredictedOrbitsDataReq; + /**< Injects the predicted orbits data into the service. + + When all predicted orbits data parts have been injected, the client + receives the following indication containing a response: + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02. + + The client injects successive data parts without waiting for this + indication as long as locClientSendReq() returns successfully. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02. */ + + const qmiLocInjectUtcTimeReqMsgT_v02* pInjectUtcTimeReq; + /**< Injects UTC time into the service. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_UTC_TIME_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_UTC_TIME_REQ_V02. */ + + const qmiLocInjectPositionReqMsgT_v02* pInjectPositionReq; + /**< Injects a position into the service. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_POSITION_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_POSITION_REQ_V02. */ + + const qmiLocSetEngineLockReqMsgT_v02* pSetEngineLockReq; + /**< Sets the location engine lock. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_ENGINE_LOCK_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_ENGINE_LOCK_REQ_V02. */ + + const qmiLocSetSbasConfigReqMsgT_v02* pSetSbasConfigReq; + /**< Sets the SBAS configuration. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SBAS_CONFIG_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SBAS_CONFIG_REQ_V02 . */ + + const qmiLocSetNmeaTypesReqMsgT_v02* pSetNmeaTypesReq; + /**< Sets the NMEA types configuration. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_NMEA_TYPES_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_NMEA_TYPES_REQ_V02. */ + + const qmiLocSetLowPowerModeReqMsgT_v02* pSetLowPowerModeReq; + /**< Sets the Low Power mode configuration. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_LOW_POWER_MODE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_LOW_POWER_MODE_REQ_V02. */ + + const qmiLocSetServerReqMsgT_v02* pSetServerReq; + /**< Sets the A-GPS server type and address. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SERVER_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SERVER_REQ_V02. */ + + const qmiLocGetServerReqMsgT_v02* pGetServerReq; + /**< Gets the A-GPS server type and address. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_SERVER_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_SERVER_REQ_V02. */ + + const qmiLocDeleteAssistDataReqMsgT_v02* pDeleteAssistDataReq; + /**< Deletes the aiding data from the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_DELETE_ASSIST_DATA_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_DELETE_ASSIST_DATA_REQ_V02. */ + + const qmiLocSetXtraTSessionControlReqMsgT_v02* pSetXtraTSessionControlReq; + /**< Sets XTRA-T session control in the engine. If the request is accepted by + the service, the client receives the following indication containing a + response: QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02. */ + + const qmiLocInjectWifiPositionReqMsgT_v02* pInjectWifiPositionReq; + /**< Injects a WiFi position into the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_WIFI_POSITION_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_WIFI_POSITION_REQ_V02. */ + + const qmiLocNotifyWifiStatusReqMsgT_v02* pNotifyWifiStatusReq; + /**< Notifies the engine about the WiFi status. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02. */ + + const qmiLocSetOperationModeReqMsgT_v02* pSetOperationModeReq; + /**< Sets the engine Operation mode. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_OPERATION_MODE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_OPERATION_MODE_REQ_V02. */ + + const qmiLocSetSpiStatusReqMsgT_v02* pSetSpiStatusReq; + /**< Sends the stationary position status to the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SPI_STATUS_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SPI_STATUS_REQ_V02. */ + + const qmiLocInjectSensorDataReqMsgT_v02* pInjectSensorDataReq; + /**< Injects sensor data into the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_SENSOR_DATA_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_SENSOR_DATA_REQ_V02. */ + + const qmiLocInjectTimeSyncDataReqMsgT_v02* pInjectTimeSyncReq; + /**< Injects time synchronization information into the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02. */ + + const qmiLocSetCradleMountConfigReqMsgT_v02* pSetCradleMountConfigReq; + /**< Sets the cradle mount state information in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + SET_CRADLE_MOUNT_CONFIG_REQ_V02. + + To send this request, set the reqId field in locClientSendReq() to + SET_CRADLE_MOUNT_CONFIG_IND_V02. */ + + const qmiLocSetExternalPowerConfigReqMsgT_v02* pSetExternalPowerConfigReq; + /**< Sets external power configuration state in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02. */ + + const qmiLocInformLocationServerConnStatusReqMsgT_v02* + pInformLocationServerConnStatusReq; + /**< Informs the engine about the connection status to the location server. + + This can be sent in response to a + QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 request. The + service sends back a QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 + response indication for this request. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02.*/ + + const qmiLocSetProtocolConfigParametersReqMsgT_v02* + pSetProtocolConfigParametersReq; + /**< Sets the protocol configuration parameters in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. */ + + const qmiLocGetProtocolConfigParametersReqMsgT_v02* + pGetProtocolConfigParametersReq; + /**< Retrieves protocol configuration parameters from the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. + @newpage */ + + const qmiLocSetSensorControlConfigReqMsgT_v02* + pSetSensorControlConfigReq; + /**< Sets the sensor control configuration parameters in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02. + @newpage */ + + const qmiLocSetSensorPerformanceControlConfigReqMsgT_v02* + pSetSensorPerformanceControlConfigReq; + /**< Sets the sensor performance configuration parameters in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. + @newpage */ + + const qmiLocSetSensorPropertiesReqMsgT_v02* pSetSensorPropertiesReq; + /**< Sets the sensor properties in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02. + @newpage */ + + const qmiLocInjectSuplCertificateReqMsgT_v02* pInjectSuplCertificateReq; + /**< Injects a SUPL certificate into the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02. + @newpage */ + + const qmiLocDeleteSuplCertificateReqMsgT_v02* pDeleteSuplCertificateReq; + /**< Deletes a SUPL certificate from the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02. + @newpage */ + + const qmiLocSetPositionEngineConfigParametersReqMsgT_v02* + pSetPositionEngineConfigParametersReq; + /**< Sets Position Engine configuration. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND _V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. + @newpage */ + + const qmiLocGetPositionEngineConfigParametersReqMsgT_v02* + pGetPositionEngineConfigParametersReq; + /**< Gets Position Engine configuration. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. + @newpage */ + +}locClientReqUnionType; + + +/** @brief Event indications that are sent by the service. +*/ +typedef union +{ + const qmiLocEventPositionReportIndMsgT_v02* pPositionReportEvent; + /**< Contains the position information. + + This event is generated after QMI_LOC_START_REQ_V02 is sent. If + periodic fix criteria is specified, this event is generated multiple + times periodically at the specified rate until QMI_LOC_STOP_REQ_V02 is + sent. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_POSITION_REPORT_IND_V02. */ + + const qmiLocEventGnssSvInfoIndMsgT_v02* pGnssSvInfoReportEvent; + /**< Contains the GNSS satellite information. + + This event is generated after QMI_LOC_START_REQ_V02 is sent. This event + is generated at 1 Hz if the location engine is tracking satellites to + make a location fix. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_GNSS_INFO_IND_V02. */ + + const qmiLocEventNmeaIndMsgT_v02* pNmeaReportEvent; + /**< Contains an NMEA report sentence. The entire NMEA report consisting + of multiple sentences is sent at a 1Hz rate. + This event is generated after QMI_LOC_START_REQ_V02 is sent. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_NMEA_IND_V02. */ + + const qmiLocEventNiNotifyVerifyReqIndMsgT_v02* pNiNotifyVerifyReqEvent; + /**< Notifies a location client when the network triggers a positioning request + to the mobile. + + Upon getting this event, the location client displays the + network-initiated fix request in a dialog and prompts the user to accept + or deny the request. The client responds to this request with the message + QMI_LOC_NI_USER_RESPONSE_REQ_V02. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02. */ + + const qmiLocEventInjectTimeReqIndMsgT_v02* pInjectTimeReqEvent; + /**< Asks the client for time assistance. + + The client responds to this request with the message + QMI_LOC_INJECT_UTC_TIME_REQ_V02. + + The eventIndId field in the event indication callback is + set to QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02. */ + + const qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02* + pInjectPredictedOrbitsReqEvent; + /**< Asks the client for predicted orbits data assistance. + + The client responds to this request with the message + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02. */ + + const qmiLocEventInjectPositionReqIndMsgT_v02* pInjectPositionReqEvent; + /**< Asks the client for position assistance. + + The client responds to this request with the message + QMI_LOC_INJECT_POSITION_REQ_V02. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02. */ + + const qmiLocEventEngineStateIndMsgT_v02* pEngineState; + /**< Sent by the engine whenever it turns on or off. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_ENGINE_STATE_IND_V02. */ + + const qmiLocEventFixSessionStateIndMsgT_v02* pFixSessionState; + /**< Sent by the engine when a location session begins or ends. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02. */ + + const qmiLocEventWifiReqIndMsgT_v02* pWifiReqEvent; + /**< Sent by the engine when it needs WiFi support. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_WIFI_REQ_IND_V02. */ + + const qmiLocEventSensorStreamingReadyStatusIndMsgT_v02* + pSensorStreamingReadyStatusEvent; + /**< Notifies the client that the engine is ready to accept sensor data. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02. */ + + const qmiLocEventTimeSyncReqIndMsgT_v02* pTimeSyncReqEvent; + /**< Sent by the engine when it needs to synchronize its time with the sensor + processor time. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02. */ + + const qmiLocEventSetSpiStreamingReportIndMsgT_v02* + pSetSpiStreamingReportEvent; + /**< Asks the client to start/stop sending a Stationary Position Indicator + (SPI) stream. + + The eventIndId field in the event indication callback is set to + QMI_LOC_SET_SPI_STREAMING_REPORT_IND_V02. */ + + const qmiLocEventLocationServerConnectionReqIndMsgT_v02* + pLocationServerConnReqEvent; + /**< Sent by the engine to ask the client to open or close a connection to + a location server. + + The client responds to this request by sending the + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 message. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02. + @newpage */ + +}locClientEventIndUnionType; + + +/** @brief Response indications that are sent by the service. */ +typedef union +{ + const qmiLocGetServiceRevisionIndMsgT_v02* pGetServiceRevisionInd; + /**< Response to the request, QMI_LOC_GET_SERVICE_REVISION_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SERVICE_REVISION_IND_V02. */ + + const qmiLocGetFixCriteriaIndMsgT_v02* pGetFixCriteriaInd; + /**< Response to the request, QMI_LOC_GET_FIX_CRITERIA_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_FIX_CRITERIA_IND_V02. */ + + const qmiLocNiUserRespIndMsgT_v02* pNiUserRespInd; + /**< Response to the request, QMI_LOC_NI_USER_RESPONSE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_NI_USER_RESPONSE_IND_V02. */ + + const qmiLocInjectPredictedOrbitsDataIndMsgT_v02* + pInjectPredictedOrbitsDataInd; + /**< Sent after a predicted orbits data part has been successfully injected. + + The client waits for this indication before injecting the next part. + This indication is sent in response to + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02. */ + + const qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02* + pGetPredictedOrbitsDataSourceInd; + /**< Response to the request, + QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02. */ + + const qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02* + pGetPredictedOrbitsDataValidityInd; + /**< Response to the request, + QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02. */ + + const qmiLocInjectUtcTimeIndMsgT_v02* pInjectUtcTimeInd; + /**< Response to the request, QMI_LOC_INJECT_UTC_TIME_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_UTC_TIME_IND_V02. */ + + const qmiLocInjectPositionIndMsgT_v02* pInjectPositionInd; + /**< Response to the request, QMI_LOC_INJECT_POSITION_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_POSITION_IND_V02. */ + + const qmiLocSetEngineLockIndMsgT_v02* pSetEngineLockInd; + /**< Response to the request, QMI_LOC_SET_ENGINE_LOCK_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_ENGINE_LOCK_IND_V02. */ + + const qmiLocGetEngineLockIndMsgT_v02* pGetEngineLockInd; + /**< Response to the request, QMI_LOC_GET_ENGINE_LOCK_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_ENGINE_LOCK_IND_V02. */ + + const qmiLocSetSbasConfigIndMsgT_v02* pSetSbasConfigInd; + /**< Response to the request, QMI_LOC_SET_SBAS_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SBAS_CONFIG_IND_V02. */ + + const qmiLocGetSbasConfigIndMsgT_v02* pGetSbasConfigInd; + /**< Response to the request, QMI_LOC_GET_SBAS_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SBAS_CONFIG_IND_V02. */ + + const qmiLocSetNmeaTypesIndMsgT_v02* pSetNmeaTypesInd; + /**< Response to the request, QMI_LOC_SET_NMEA_TYPES_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_NMEA_TYPES_IND_V02. */ + + const qmiLocGetNmeaTypesIndMsgT_v02* pGetNmeaTypesInd; + /**< Response to the request, QMI_LOC_GET_NMEA_TYPES_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_NMEA_TYPES_IND_V02. */ + + const qmiLocSetLowPowerModeIndMsgT_v02* pSetLowPowerModeInd; + /**< Response to the request, QMI_LOC_SET_LOW_POWER_MODE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_LOW_POWER_MODE_IND_V02. */ + + const qmiLocGetLowPowerModeIndMsgT_v02* pGetLowPowerModeInd; + /**< Response to the request, QMI_LOC_GET_LOW_POWER_MODE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_LOW_POWER_MODE_IND_V02. */ + + const qmiLocSetServerIndMsgT_v02* pSetServerInd; + /**< Response to the request, QMI_LOC_SET_SERVER_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SERVER_IND_V02. */ + + const qmiLocGetServerIndMsgT_v02* pGetServerInd; + /**< Response to the request, QMI_LOC_GET_SERVER_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SERVER_IND_V02. */ + + const qmiLocDeleteAssistDataIndMsgT_v02* pDeleteAssistDataInd; + /**< Response to the request, QMI_LOC_DELETE_ASSIST_DATA_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_DELETE_ASSIST_DATA_IND_V02. */ + + const qmiLocSetXtraTSessionControlIndMsgT_v02* pSetXtraTSessionControlInd; + /**< Response to the request, QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02. */ + + const qmiLocGetXtraTSessionControlIndMsgT_v02* pGetXtraTSessionControlInd; + /**< Response to the request, QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02. */ + + const qmiLocInjectWifiPositionIndMsgT_v02* pInjectWifiPositionInd; + /**< Response to the request, QMI_LOC_INJECT_WIFI_POSITION_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_WIFI_POSITION_IND_V02. */ + + const qmiLocNotifyWifiStatusIndMsgT_v02* pNotifyWifiStatusInd; + /**< Response to the request, QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02. */ + + const qmiLocGetRegisteredEventsIndMsgT_v02* pGetRegisteredEventsInd; + /**< Response to the request, QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_REGISTERED_EVENTS_IND_V02. */ + + const qmiLocSetOperationModeIndMsgT_v02* pSetOperationModeInd; + /**< Response to the request, QMI_LOC_SET_OPERATION_MODE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_OPERATION_MODE_IND_V02. */ + + const qmiLocGetOperationModeIndMsgT_v02* pGetOperationModeInd; + /**< Response to the request, QMI_LOC_GET_OPERATION_MODE_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_OPERATION_MODE_IND_V02. */ + + const qmiLocSetSpiStatusIndMsgT_v02* pSetSpiStatusInd; + /**< Response to the request, QMI_LOC_SET_SPI_STATUS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SPI_STATUS_IND_V02. */ + + const qmiLocInjectSensorDataIndMsgT_v02* pInjectSensorDataInd; + /**< Response to the request, QMI_LOC_INJECT_SENSOR_DATA_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_SENSOR_DATA_IND_V02. */ + + const qmiLocInjectTimeSyncDataIndMsgT_v02* pInjectTimeSyncDataInd; + /**< Response to the request, QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02. */ + + const qmiLocSetCradleMountConfigIndMsgT_v02* pSetCradleMountConfigInd; + /**< Response to the request, QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02. */ + + const qmiLocGetCradleMountConfigIndMsgT_v02* pGetCradleMountConfigInd; + /**< Response to the request, QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02. */ + + const qmiLocSetExternalPowerConfigIndMsgT_v02* pSetExternalPowerConfigInd; + /**< Response to the request, QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02. */ + + const qmiLocGetExternalPowerConfigIndMsgT_v02* pGetExternalPowerConfigInd; + /**< Response to the request, QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02. */ + + const qmiLocInformLocationServerConnStatusIndMsgT_v02* + pInformLocationServerConnStatusInd; + /**< Response to the request, + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02.*/ + + const qmiLocSetProtocolConfigParametersIndMsgT_v02* + pSetProtocolConfigParametersInd; + /**< Response to the request, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. */ + + const qmiLocGetProtocolConfigParametersIndMsgT_v02* + pGetProtocolConfigParametersInd; + /**< Response to the request, + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. + @newpage */ + + const qmiLocSetSensorControlConfigIndMsgT_v02* pSetSensorControlConfigInd; + /**< Response to the request, + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02. + @newpage */ + + const qmiLocGetSensorControlConfigIndMsgT_v02* pGetSensorControlConfigInd; + /**< Response to the request, + QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02. + @newpage */ + + const qmiLocSetSensorPropertiesIndMsgT_v02* pSetSensorPropertiesInd; + /**< Response to the request, + QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02. + @newpage */ + + const qmiLocGetSensorPropertiesIndMsgT_v02* pGetSensorPropertiesInd; + /**< Response to the request, + QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02. + @newpage */ + + const qmiLocSetSensorPerformanceControlConfigIndMsgT_v02* + pSetSensorPerformanceControlConfigInd; + /**< Response to the request, + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. + @newpage */ + + const qmiLocGetSensorPerformanceControlConfigIndMsgT_v02* + pGetSensorPerformanceControlConfigInd; + /**< Response to the request, + QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. + @newpage */ + + const qmiLocInjectSuplCertificateIndMsgT_v02* pInjectSuplCertificateInd; + /**< Response to the request, + QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02. + @newpage */ + + const qmiLocDeleteSuplCertificateIndMsgT_v02* pDeleteSuplCertificateInd; + /**< Response to the request, + QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02. + The respIndId field in the response indication callback is set to + QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02. + @newpage */ + + const qmiLocSetPositionEngineConfigParametersIndMsgT_v02* + pSetPositionEngineConfigParametersInd; + /**< Response to the request, + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. + @newpage */ + + const qmiLocGetPositionEngineConfigParametersIndMsgT_v02* + pGetPositionEngineConfigParametersInd; + /**< Response to the request, + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_ET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. + @newpage */ + +}locClientRespIndUnionType; + +/** @} */ /* end_addtogroup send_request */ + +/** @addtogroup data_types +@{ */ + +/** Location event indication callback function type. The Location service can + generate two types of indications: + + - Asynchronous events indications, such as time injection request and satellite + reports. The client specifies the asynchronous events it is interested in + receiving through the event mask (see locClientOpen()). + - Response indications that are generated as a response to a request. For + example, the QMI_LOC_GET_FIX_CRITERIA_REQ_V02 request generates the + indication, QMI_LOC_GET_FIX_CRITERIA_IND_V02. + + This callback handles the asynchronous event indications. + + @vertspace + @param handle Location client for this event. Only the client who + registered for the corresponding event receives + this callback. + @param eventIndId ID of the event indication. + @param eventIndPayload Event indication payload. + @param pClientCookie Pointer to the cookie the client specified during + registration. +*/ +typedef void (*locClientEventIndCbType)( + locClientHandleType handle, + uint32_t eventIndId, + const locClientEventIndUnionType eventIndPayload, + void *pClientCookie +); + +/** Location response indication callback function type. The Location service can + generate two types of indications: + + - Asynchronous events indications, such as time injection request and satellite + reports. The client specifies the asynchronous events it is interested in + receiving through the event mask (see locClientOpen()). + - Response indications that are generated as a response to a request. For + example, the QMI_LOC_GET_FIX_CRITERIA_REQ_V02 request generates the + indication, QMI_LOC_GET_FIX_CRITERIA_IND_V02. + + This callback handles the response indications. + + @vertspace + @param handle Location client who sent the request for which this + response indication is generated. + @param respIndId ID of the response. It is the same value as the ID + of request sent to the engine. + @param respIndPayload Payload of the response indication. + @param pClientCookie Pointer to the cookie the client specified during + registration. + + @newpage +*/ +typedef void (*locClientRespIndCbType)( + locClientHandleType handle, + uint32_t respIndId, + const locClientRespIndUnionType respIndPayload, + void *pClientCookie +); + +/** Location error callback function type. This function will be + called to inform the client that the service is no longer + available. When the client receives this callback it must + close the existing connection and reopen the client connection. + + + @vertspace + @param handle Location client who sent the request for which this + error indication is generated. + @param errorId Error ID. + @param errorCbdata Payload associated with the error indication. + + @newpage +*/ +typedef void (*locClientErrorCbType)( + locClientHandleType handle, + locClientErrorEnumType errorId, + void* pClientCookie + ); + + +/** Callback functions to be registered during locClientOpen +*/ + +typedef struct +{ + uint32_t size; + /**< Size of the structure */ + locClientEventIndCbType eventIndCb; + /**< Event Indication callback */ + locClientRespIndCbType respIndCb; + /**< Response Indication callback */ + locClientErrorCbType errorCb; + /**< Error Indication callback */ +}locClientCallbacksType; + +/** @} */ /* end_addtogroup data_types */ + +/*=========================================================================== + * + * FUNCTION DECLARATION + * + *==========================================================================*/ + +/** @addtogroup open_client +@{ */ +/*========================================================================== + locClientOpen */ +/** + @latexonly\label{hdr:locClientOpenFunction}@endlatexonly Connects a location + client to the location engine. If the connection is successful, this function + returns a handle that the location client uses for future location operations. + + @datatype + #locClientStatusEnumType\n + #locClientEventMaskType\n + #locClientCallbacksType *\n + #locClientHandleType *\n + #void * + + @vertspace + @param[in] eventRegMask Mask of asynchronous events the client is + interested in receiving. + @param[in] pLocClientCallbacks Pointer to structure containing the + callbacks. + @param[out] pLocClientHandle Pointer to the handle to be used by the + client for any subsequent requests. + @param[in] pLocClientCookie Pointer to a "cookie" to be returned to the + client along with the callbacks. + + @return + One of the following error codes: + - eLOC_CLIENT_SUCCESS -- If the connection is opened. + - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. + + @dependencies + None. + @newpage +*/ +extern locClientStatusEnumType locClientOpen ( + locClientEventMaskType eventRegMask, + const locClientCallbacksType* pLocClientCallbacks, + locClientHandleType* pLocClientHandle, + const void* pLocClientCookie +); + +/** @} */ /* end_addtogroup open_client */ + +/** @addtogroup close_client +@{ */ +/*========================================================================== + locClientClose */ +/** + @latexonly\label{hdr:locClientCloseFunction}@endlatexonly Disconnects a client + from the location engine and sets the handle to + LOC_CLIENT_INVALID_HANDLE_VALUE. + + @datatype + #locClientStatusEnumType\n + #locClientHandleType + + @vertspace + @param[in] pLocClientHandle Pointer to the handle returned by the + locClientOpen() function. + + @return + One of the following error codes: + - 0 (eLOC_CLIENT_SUCCESS) -- On success. + - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. + + @dependencies + None. + @newpage +*/ +extern locClientStatusEnumType locClientClose ( + locClientHandleType* pLocClientHandle +); + +/** @} */ /* end_addtogroup close_client */ + +/** @addtogroup send_request +@{ */ +/*============================================================================= + locClientSendReq */ +/** + @latexonly\label{hdr:locClientSendReqFunction}@endlatexonly Sends a message to + the location engine. If this function is successful, the client expects an + indication (except start, stop, event registration, and sensor injection + messages) through the registered callback in the locClientOpen() function. + + The indication contains the status of the request. If the status is a success, + the indication also contains the payload associated with response. + + @datatype + #locClientStatusEnumType\n + #locClientHandleType\n + #locClientReqUnionType + + @vertspace + @param[in] handle Handle returned by the locClientOpen() function. + @param[in] reqId QMI_LOC service message ID of the request. + @param[in] pReqPayload Payload of the request. This can be NULL if the request + has no payload. + + @return + One of the following error codes: + - 0 (eLOC_CLIENT_SUCCESS) -- On success. + - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. + + @dependencies + None. + + @structure + locClientReqUnionType + @newpage +*/ +extern locClientStatusEnumType locClientSendReq( + locClientHandleType handle, + uint32_t reqId, + locClientReqUnionType reqPayload +); + +/** @} */ /* end_addtogroup send_request */ + +/** @addtogroup get_size_event +@{ */ +/*============================================================================= + locClientGetSizeByEventIndId */ +/** + Gets the size of the event indication structure from a specified ID. + + @datatype + #locClientGetSizeByEventIndId + + @vertspace + @param[in] eventIndId Event indicator ID. + @param[out] pEventIndSize Pointer to the size of the structure. + + @return + true -- The event ID was found.\n + false -- Otherwise. + + @dependencies + None. + + @structure + locClientEventIndUnionType + @newpage +*/ +extern bool locClientGetSizeByEventIndId( + uint32_t eventIndId, + size_t *pEventIndSize); + +/** @} */ /* end_addtogroup get_size_event */ + +/** @addtogroup get_size_response +@{ */ +/*============================================================================= + locClientGetSizeByRespIndId */ + +/** + Gets the size of the response indication structure from a specified ID. + + @datatype + #locClientGetSizeByRespIndId + + @vertspace + @param[in] respIndId Response indicator ID. + @param[out] pRespIndSize Pointer to the size of the structure. + + @return + true -- The response ID was found.\n + false -- Otherwise. + + @dependencies + None. + + @structure + locClientRespIndUnionType + @newpage +*/ +extern bool locClientGetSizeByRespIndId( + uint32_t respIndId, + size_t *pRespIndSize); + +/*=============================================================================*/ + +/** @} */ /* end_addtogroup get_size_response */ + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_V02_CLIENT_H*/ diff --git a/loc_api/loc_api_v02/loc_api_v02_log.c b/loc_api/loc_api_v02/loc_api_v02_log.c new file mode 100755 index 00000000..78792607 --- /dev/null +++ b/loc_api/loc_api_v02/loc_api_v02_log.c @@ -0,0 +1,243 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#include +#include + +static loc_name_val_s_type loc_v02_event_name[] = +{ + NAME_VAL(QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02), + NAME_VAL(QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02), + NAME_VAL(QMI_LOC_REG_EVENTS_REQ_V02), + NAME_VAL(QMI_LOC_REG_EVENTS_RESP_V02), + NAME_VAL(QMI_LOC_START_REQ_V02), + NAME_VAL(QMI_LOC_START_RESP_V02), + NAME_VAL(QMI_LOC_STOP_REQ_V02), + NAME_VAL(QMI_LOC_STOP_RESP_V02), + NAME_VAL(QMI_LOC_EVENT_POSITION_REPORT_IND_V02), + NAME_VAL(QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02), + NAME_VAL(QMI_LOC_EVENT_NMEA_IND_V02), + NAME_VAL(QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_ENGINE_STATE_IND_V02), + NAME_VAL(QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02), + NAME_VAL(QMI_LOC_EVENT_WIFI_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02), + NAME_VAL(QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02), + NAME_VAL(QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02), + NAME_VAL(QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02), + NAME_VAL(QMI_LOC_GET_SERVICE_REVISION_REQ_V02), + NAME_VAL(QMI_LOC_GET_SERVICE_REVISION_RESP_V02), + NAME_VAL(QMI_LOC_GET_SERVICE_REVISION_IND_V02), + NAME_VAL(QMI_LOC_GET_FIX_CRITERIA_REQ_V02), + NAME_VAL(QMI_LOC_GET_FIX_CRITERIA_RESP_V02), + NAME_VAL(QMI_LOC_GET_FIX_CRITERIA_IND_V02), + NAME_VAL(QMI_LOC_NI_USER_RESPONSE_REQ_V02), + NAME_VAL(QMI_LOC_NI_USER_RESPONSE_RESP_V02), + NAME_VAL(QMI_LOC_NI_USER_RESPONSE_IND_V02), + NAME_VAL(QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02), + NAME_VAL(QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02), + NAME_VAL(QMI_LOC_INJECT_UTC_TIME_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_UTC_TIME_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_UTC_TIME_IND_V02), + NAME_VAL(QMI_LOC_INJECT_POSITION_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_POSITION_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_POSITION_IND_V02), + NAME_VAL(QMI_LOC_SET_ENGINE_LOCK_REQ_V02), + NAME_VAL(QMI_LOC_SET_ENGINE_LOCK_RESP_V02), + NAME_VAL(QMI_LOC_SET_ENGINE_LOCK_IND_V02), + NAME_VAL(QMI_LOC_GET_ENGINE_LOCK_REQ_V02), + NAME_VAL(QMI_LOC_GET_ENGINE_LOCK_RESP_V02), + NAME_VAL(QMI_LOC_GET_ENGINE_LOCK_IND_V02), + NAME_VAL(QMI_LOC_SET_SBAS_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_SET_SBAS_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_SET_SBAS_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_GET_SBAS_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_GET_SBAS_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_GET_SBAS_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_SET_NMEA_TYPES_REQ_V02), + NAME_VAL(QMI_LOC_SET_NMEA_TYPES_RESP_V02), + NAME_VAL(QMI_LOC_SET_NMEA_TYPES_IND_V02), + NAME_VAL(QMI_LOC_GET_NMEA_TYPES_REQ_V02), + NAME_VAL(QMI_LOC_GET_NMEA_TYPES_RESP_V02), + NAME_VAL(QMI_LOC_GET_NMEA_TYPES_IND_V02), + NAME_VAL(QMI_LOC_SET_LOW_POWER_MODE_REQ_V02), + NAME_VAL(QMI_LOC_SET_LOW_POWER_MODE_RESP_V02), + NAME_VAL(QMI_LOC_SET_LOW_POWER_MODE_IND_V02), + NAME_VAL(QMI_LOC_GET_LOW_POWER_MODE_REQ_V02), + NAME_VAL(QMI_LOC_GET_LOW_POWER_MODE_RESP_V02), + NAME_VAL(QMI_LOC_GET_LOW_POWER_MODE_IND_V02), + NAME_VAL(QMI_LOC_SET_SERVER_REQ_V02), + NAME_VAL(QMI_LOC_SET_SERVER_RESP_V02), + NAME_VAL(QMI_LOC_SET_SERVER_IND_V02), + NAME_VAL(QMI_LOC_GET_SERVER_REQ_V02), + NAME_VAL(QMI_LOC_GET_SERVER_RESP_V02), + NAME_VAL(QMI_LOC_GET_SERVER_IND_V02), + NAME_VAL(QMI_LOC_DELETE_ASSIST_DATA_REQ_V02), + NAME_VAL(QMI_LOC_DELETE_ASSIST_DATA_RESP_V02), + NAME_VAL(QMI_LOC_DELETE_ASSIST_DATA_IND_V02), + NAME_VAL(QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02), + NAME_VAL(QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02), + NAME_VAL(QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02), + NAME_VAL(QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02), + NAME_VAL(QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02), + NAME_VAL(QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02), + NAME_VAL(QMI_LOC_INJECT_WIFI_POSITION_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_WIFI_POSITION_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_WIFI_POSITION_IND_V02), + NAME_VAL(QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02), + NAME_VAL(QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02), + NAME_VAL(QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02), + NAME_VAL(QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02), + NAME_VAL(QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02), + NAME_VAL(QMI_LOC_GET_REGISTERED_EVENTS_IND_V02), + NAME_VAL(QMI_LOC_SET_OPERATION_MODE_REQ_V02), + NAME_VAL(QMI_LOC_SET_OPERATION_MODE_RESP_V02), + NAME_VAL(QMI_LOC_SET_OPERATION_MODE_IND_V02), + NAME_VAL(QMI_LOC_GET_OPERATION_MODE_REQ_V02), + NAME_VAL(QMI_LOC_GET_OPERATION_MODE_RESP_V02), + NAME_VAL(QMI_LOC_GET_OPERATION_MODE_IND_V02), + NAME_VAL(QMI_LOC_SET_SPI_STATUS_REQ_V02), + NAME_VAL(QMI_LOC_SET_SPI_STATUS_RESP_V02), + NAME_VAL(QMI_LOC_SET_SPI_STATUS_IND_V02), + NAME_VAL(QMI_LOC_INJECT_SENSOR_DATA_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_SENSOR_DATA_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_SENSOR_DATA_IND_V02), + NAME_VAL(QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02), + NAME_VAL(QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02), + NAME_VAL(QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02), + NAME_VAL(QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02), + NAME_VAL(QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02), + NAME_VAL(QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02), + NAME_VAL(QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02), + NAME_VAL(QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02), + NAME_VAL(QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02), + NAME_VAL(QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02), + NAME_VAL(QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02), + NAME_VAL(QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02), + NAME_VAL(QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02), + NAME_VAL(QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02), + NAME_VAL(QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02), + NAME_VAL(QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02), + NAME_VAL(QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02), + NAME_VAL(QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02), + NAME_VAL(QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02), + NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02), + NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02), + NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02), +}; +static int loc_v02_event_num = sizeof(loc_v02_event_name) / sizeof(loc_name_val_s_type); + +const char* loc_get_v02_event_name(uint32_t event) +{ + return loc_get_name_from_val(loc_v02_event_name, loc_v02_event_num, (long) event); +} + +static loc_name_val_s_type loc_v02_client_status_name[] = +{ + NAME_VAL(eLOC_CLIENT_SUCCESS), + NAME_VAL(eLOC_CLIENT_FAILURE_GENERAL), + NAME_VAL(eLOC_CLIENT_FAILURE_UNSUPPORTED), + NAME_VAL(eLOC_CLIENT_FAILURE_INVALID_PARAMETER), + NAME_VAL(eLOC_CLIENT_FAILURE_ENGINE_BUSY), + NAME_VAL(eLOC_CLIENT_FAILURE_PHONE_OFFLINE), + NAME_VAL(eLOC_CLIENT_FAILURE_TIMEOUT), + NAME_VAL(eLOC_CLIENT_FAILURE_SERVICE_NOT_PRESENT), + NAME_VAL(eLOC_CLIENT_FAILURE_SERVICE_VERSION_UNSUPPORTED), + NAME_VAL(eLOC_CLIENT_FAILURE_CLIENT_VERSION_UNSUPPORTED), + NAME_VAL(eLOC_CLIENT_FAILURE_INVALID_HANDLE), + NAME_VAL(eLOC_CLIENT_FAILURE_INTERNAL), + NAME_VAL(eLOC_CLIENT_FAILURE_NOT_INITIALIZED), +}; +static int loc_v02_client_status_num = sizeof(loc_v02_client_status_name) / sizeof(loc_name_val_s_type); + +const char* loc_get_v02_client_status_name(locClientStatusEnumType status) +{ + return loc_get_name_from_val(loc_v02_client_status_name, loc_v02_client_status_num, (long) status); +} + + +static loc_name_val_s_type loc_v02_qmi_status_name[] = +{ + QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02, + eQMI_LOC_SUCCESS_V02, + eQMI_LOC_GENERAL_FAILURE_V02, + eQMI_LOC_UNSUPPORTED_V02, + eQMI_LOC_INVALID_PARAMETER_V02, + eQMI_LOC_ENGINE_BUSY_V02, + eQMI_LOC_PHONE_OFFLINE_V02, + eQMI_LOC_TIMEOUT_V02, + QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 +}; +static int loc_v02_qmi_status_num = sizeof(loc_v02_qmi_status_name) / sizeof(loc_name_val_s_type); + +const char* loc_get_v02_qmi_status_name(qmiLocStatusEnumT_v02 status) +{ + return loc_get_name_from_val(loc_v02_qmi_status_name, loc_v02_qmi_status_num, (long) status); +} diff --git a/loc_api/loc_api_v02/loc_api_v02_log.h b/loc_api/loc_api_v02/loc_api_v02_log.h new file mode 100755 index 00000000..c63972f9 --- /dev/null +++ b/loc_api/loc_api_v02/loc_api_v02_log.h @@ -0,0 +1,50 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_API_V02_LOG_H +#define LOC_API_V02_LOG_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#include +#include + +const char* loc_get_v02_event_name(uint32_t event); +const char* loc_get_v02_client_status_name(locClientStatusEnumType status); +const char* loc_get_v02_qmi_status_name(qmiLocStatusEnumT_v02 status); + + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_API_V02_LOG_H */ diff --git a/loc_api/loc_api_v02/loc_util_log.h b/loc_api/loc_api_v02/loc_util_log.h new file mode 100755 index 00000000..f1b675e3 --- /dev/null +++ b/loc_api/loc_api_v02/loc_util_log.h @@ -0,0 +1,81 @@ +/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_UTIL_LOG_H +#define LOC_UTIL_LOG_H + +#ifdef FEATURE_LOC_API_V02_QNX_MOD +//error logs +#define LOC_LOGE(...) printf(__VA_ARGS__) +//warning logs +#define LOC_LOGW(...) printf(__VA_ARGS__) +// debug logs +#define LOC_LOGD(...) printf(__VA_ARGS__) +//info logs +#define LOC_LOGI(...) printf(__VA_ARGS__) +//verbose logs +#define LOC_LOGV(...) printf(__VA_ARGS__) + +#define MODEM_LOG_CALLFLOW(SPEC, VAL) +#define EXIT_LOG_CALLFLOW(SPEC, VAL) + +#endif //FEATURE_LOC_API_V02_QNX_MOD + +#ifdef LOC_UTIL_TARGET_OFF_TARGET + +#include + +//error logs +#define LOC_LOGE(...) printf(__VA_ARGS__) +//warning logs +#define LOC_LOGW(...) printf(__VA_ARGS__) +// debug logs +#define LOC_LOGD(...) printf(__VA_ARGS__) +//info logs +#define LOC_LOGI(...) printf(__VA_ARGS__) +//verbose logs +#define LOC_LOGV(...) printf(__VA_ARGS__) + +// get around strl*: not found in glibc +// TBD:look for presence of eglibc other libraries +// with strlcpy supported. +#define strlcpy(X,Y,Z) strcpy(X,Y) +#define strlcat(X,Y,Z) strcat(X,Y) + +#define MODEM_LOG_CALLFLOW(SPEC, VAL) +#define EXIT_LOG_CALLFLOW(SPEC, VAL) + +#elif defined(_ANDROID_) + +#include + +#endif //LOC_UTIL_TARGET_OFF_TARGET + + +#endif //LOC_UTIL_LOG_H diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c new file mode 100755 index 00000000..37d93f6f --- /dev/null +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -0,0 +1,2223 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "stdint.h" +#include "qmi_idl_lib_internal.h" +#include "location_service_v02.h" +#include "common_v01.h" + + +/*Type Definitions*/ +static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsTimeOfWeekMs), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDOPStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, PDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, HDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, VDOP), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorUsageIndicatorStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, usageMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, aidingIndicatorMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, validMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, healthStatus), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svStatus), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svInfoMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, elevation), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, azimuth), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, snr), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQosIncl), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQos), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, numFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, timeBetweenFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posMode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), + QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxNotifyVerifyStructT_v02, userRespTimerInSeconds), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplQopStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, validMask), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, horizontalAccuracy), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, verticalAccuracy), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, maxLocAge), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, delay), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, addr), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), + QMI_LOC_IPV6_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, suplServerAddrTypeMask), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), + 7, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), + 8, 0, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), + 9, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), + QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), + QMI_LOC_NI_SUPL_HASH_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, posMethod), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), + 5, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), + 5, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), + 6, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), + QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, invokeId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), + QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, locationType), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), + 11, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), + 11, 0, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), + 4, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), + QMI_LOC_MAX_NTP_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), + 14, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxFileSizeInBytes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxPartSize), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), + QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), + 14, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorControlConfigSamplingSpecStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, samplesPerBatch), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, batchesPerSecond), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, injectEnable), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), + 18, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsDataValidityStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, startTimeInUTC), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, durationHours), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAltitudeSrcInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, source), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, linkage), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, coverage), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDeleteSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, deleteSvInfoMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixTimeStructT_v02, wifiPositionTime), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lat), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lon), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, hepe), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, numApsUsed), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, fixErrorCode), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), + QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, rssi), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, channel), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, apQualifier), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, timeOffset), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, xAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, yAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, zAxis), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, timeOfFirstSample), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), + QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), + 26, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), + QMI_LOC_MAX_APN_NAME_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +/*Message Definitions*/ +static const uint8_t qmiLocGenRespMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGenRespMsgT_v02, resp), + 0, 1 +}; + +static const uint8_t qmiLocInformClientRevisionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformClientRevisionReqMsgT_v02, revision) +}; + +static const uint8_t qmiLocRegEventsReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocRegEventsReqMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocStartReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) +}; + +static const uint8_t qmiLocStopReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStopReqMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionStatus), + + 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence_valid)), + 0x16, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x1B, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence_valid)), + 0x1D, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc_valid)), + 0x21, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP_valid)), + 0x24, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), + 0x25, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds_valid)), + 0x26, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime_valid)), + 0x27, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), + 0, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc_valid)), + 0x29, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), + 2, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId) +}; + +static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, altitudeAssumed), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), + QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), + 3, 0 +}; + +static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), + QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 +}; + +static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd) - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), + 4, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), + 10, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), + 12, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), + 13, 0 +}; + +static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo) - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), + 15, 0 +}; + +static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), + 16, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), + 17, 0 +}; + +static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, latitude), + + 0x02, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, longitude), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x04, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, timestampUtc) +}; + +static const uint8_t qmiLocEventEngineStateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventEngineStateIndMsgT_v02, engineState) +}; + +static const uint8_t qmiLocEventFixSessionStateIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventWifiReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) +}; + +static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), + 19, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), + 19, 0 +}; + +static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventTimeSyncReqIndMsgT_v02, refCounter) +}; + +static const uint8_t qmiLocEventSetSpiStreamingReportIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventSetSpiStreamingReportIndMsgT_v02, enable) +}; + +static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) +}; + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision) +}; + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * static const uint8_t qmiLocGetFixCriteriaReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) +}; + +static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, userResp), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload) - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), + 4, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), + 10, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), + 12, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), + 13, 0 +}; + +static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalSize), + + 0x02, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalParts), + + 0x03, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partNum), + + 0x04, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData), + ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) & 0xFF), ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData_len), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType_valid)), + 0x10, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) +}; + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataSourceReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), + 16, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), + 17, 0 +}; + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataValidityReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), + 20, 0 +}; + +static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUtc), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUnc) +}; + +static const uint8_t qmiLocInjectUtcTimeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence_valid)), + 0x13, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x16, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence_valid)), + 0x18, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo_valid)), + 0x1A, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), + 21, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), + 0x1B, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) +}; + +static const uint8_t qmiLocInjectPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetEngineLockReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockReqMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetEngineLockIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockIndMsgT_v02, status) +}; + +/* + * qmiLocGetEngineLockReqMsgT is empty + * static const uint8_t qmiLocGetEngineLockReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetEngineLockIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetSbasConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigReqMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetSbasConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * static const uint8_t qmiLocGetSbasConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSbasConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetNmeaTypesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesReqMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetNmeaTypesIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesIndMsgT_v02, status) +}; + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * static const uint8_t qmiLocGetNmeaTypesReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetNmeaTypesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetLowPowerModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeReqMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetLowPowerModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * static const uint8_t qmiLocGetLowPowerModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetLowPowerModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), + 7, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocSetServerIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) +}; + +static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, status), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), + 7, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteAllFlag), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), + QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), + 22, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) +}; + +static const uint8_t qmiLocDeleteAssistDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetXtraTSessionControlReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlReqMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocSetXtraTSessionControlIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlIndMsgT_v02, status) +}; + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * static const uint8_t qmiLocGetXtraTSessionControlReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetXtraTSessionControlIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), + 23, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), + 24, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), + QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), + 25, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) +}; + +static const uint8_t qmiLocInjectWifiPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocNotifyWifiStatusReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusReqMsgT_v02, wifiStatus) +}; + +static const uint8_t qmiLocNotifyWifiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusIndMsgT_v02, status) +}; + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * static const uint8_t qmiLocGetRegisteredEventsReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetRegisteredEventsIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocSetOperationModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeReqMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetOperationModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetOperationModeReqMsgT is empty + * static const uint8_t qmiLocGetOperationModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetOperationModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetSpiStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, stationary), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) +}; + +static const uint8_t qmiLocSetSpiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), + 27, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), + 27, 0 +}; + +static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) +}; + +static const uint8_t qmiLocInjectTimeSyncDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, refCounter), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcRxTime), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcTxTime) +}; + +static const uint8_t qmiLocInjectTimeSyncDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataIndMsgT_v02, status) +}; + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * static const uint8_t qmiLocGetCradleMountConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetCradleMountConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * static const uint8_t qmiLocGetExternalPowerConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetExternalPowerConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigReqMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, requestType), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, statusType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile) - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), + 28, 0 +}; + +static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersReqMsgT_v02, getProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) +}; + +static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorControlConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) +}; + +static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status) +}; + +/* + * qmiLocGetSensorPropertiesReqMsgT is empty + * static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), + 18, 0 +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) +}; + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), + 18, 0 +}; + +static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData), + ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData) - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData_len) +}; + +static const uint8_t qmiLocInjectSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocDeleteSuplCertificateReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) +}; + +static const uint8_t qmiLocDeleteSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersReqMsgT_v02, getPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) +}; + +/* Type Table */ +static const qmi_idl_type_table_entry loc_type_table_v02[] = { + {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, + {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, + {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, + {sizeof(qmiLocSvInfoStructT_v02), qmiLocSvInfoStructT_data_v02}, + {sizeof(qmiLocNiVxNotifyVerifyStructT_v02), qmiLocNiVxNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiSuplFormattedStringStructT_v02), qmiLocNiSuplFormattedStringStructT_data_v02}, + {sizeof(qmiLocNiSuplQopStructT_v02), qmiLocNiSuplQopStructT_data_v02}, + {sizeof(qmiLocIpV4AddrStructType_v02), qmiLocIpV4AddrStructType_data_v02}, + {sizeof(qmiLocIpV6AddrStructType_v02), qmiLocIpV6AddrStructType_data_v02}, + {sizeof(qmiLocNiSuplServerInfoStructT_v02), qmiLocNiSuplServerInfoStructT_data_v02}, + {sizeof(qmiLocNiSuplNotifyVerifyStructT_v02), qmiLocNiSuplNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, + {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, + {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, + {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, + {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, + {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, + {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, + {sizeof(qmiLocWifiFixTimeStructT_v02), qmiLocWifiFixTimeStructT_data_v02}, + {sizeof(qmiLocWifiFixPosStructT_v02), qmiLocWifiFixPosStructT_data_v02}, + {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, + {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02} +}; + +/* Message Table */ +static const qmi_idl_message_table_entry loc_message_table_v02[] = { + {sizeof(qmiLocGenRespMsgT_v02), qmiLocGenRespMsgT_data_v02}, + {sizeof(qmiLocInformClientRevisionReqMsgT_v02), qmiLocInformClientRevisionReqMsgT_data_v02}, + {sizeof(qmiLocRegEventsReqMsgT_v02), qmiLocRegEventsReqMsgT_data_v02}, + {sizeof(qmiLocStartReqMsgT_v02), qmiLocStartReqMsgT_data_v02}, + {sizeof(qmiLocStopReqMsgT_v02), qmiLocStopReqMsgT_data_v02}, + {sizeof(qmiLocEventPositionReportIndMsgT_v02), qmiLocEventPositionReportIndMsgT_data_v02}, + {sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), qmiLocEventGnssSvInfoIndMsgT_data_v02}, + {sizeof(qmiLocEventNmeaIndMsgT_v02), qmiLocEventNmeaIndMsgT_data_v02}, + {sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), qmiLocEventInjectTimeReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), qmiLocEventInjectPositionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventEngineStateIndMsgT_v02), qmiLocEventEngineStateIndMsgT_data_v02}, + {sizeof(qmiLocEventFixSessionStateIndMsgT_v02), qmiLocEventFixSessionStateIndMsgT_data_v02}, + {sizeof(qmiLocEventWifiReqIndMsgT_v02), qmiLocEventWifiReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02}, + {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, + {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetFixCriteriaIndMsgT_v02), qmiLocGetFixCriteriaIndMsgT_data_v02}, + {sizeof(qmiLocNiUserRespReqMsgT_v02), qmiLocNiUserRespReqMsgT_data_v02}, + {sizeof(qmiLocNiUserRespIndMsgT_v02), qmiLocNiUserRespIndMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02), qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02), qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02), qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02), qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeReqMsgT_v02), qmiLocInjectUtcTimeReqMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeIndMsgT_v02), qmiLocInjectUtcTimeIndMsgT_data_v02}, + {sizeof(qmiLocInjectPositionReqMsgT_v02), qmiLocInjectPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectPositionIndMsgT_v02), qmiLocInjectPositionIndMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockReqMsgT_v02), qmiLocSetEngineLockReqMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockIndMsgT_v02), qmiLocSetEngineLockIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetEngineLockIndMsgT_v02), qmiLocGetEngineLockIndMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigReqMsgT_v02), qmiLocSetSbasConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigIndMsgT_v02), qmiLocSetSbasConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSbasConfigIndMsgT_v02), qmiLocGetSbasConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesReqMsgT_v02), qmiLocSetNmeaTypesReqMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesIndMsgT_v02), qmiLocSetNmeaTypesIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetNmeaTypesIndMsgT_v02), qmiLocGetNmeaTypesIndMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeReqMsgT_v02), qmiLocSetLowPowerModeReqMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeIndMsgT_v02), qmiLocSetLowPowerModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetLowPowerModeIndMsgT_v02), qmiLocGetLowPowerModeIndMsgT_data_v02}, + {sizeof(qmiLocSetServerReqMsgT_v02), qmiLocSetServerReqMsgT_data_v02}, + {sizeof(qmiLocSetServerIndMsgT_v02), qmiLocSetServerIndMsgT_data_v02}, + {sizeof(qmiLocGetServerReqMsgT_v02), qmiLocGetServerReqMsgT_data_v02}, + {sizeof(qmiLocGetServerIndMsgT_v02), qmiLocGetServerIndMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataReqMsgT_v02), qmiLocDeleteAssistDataReqMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataIndMsgT_v02), qmiLocDeleteAssistDataIndMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02), qmiLocSetXtraTSessionControlReqMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02), qmiLocSetXtraTSessionControlIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02), qmiLocGetXtraTSessionControlIndMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionReqMsgT_v02), qmiLocInjectWifiPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionIndMsgT_v02), qmiLocInjectWifiPositionIndMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusReqMsgT_v02), qmiLocNotifyWifiStatusReqMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusIndMsgT_v02), qmiLocNotifyWifiStatusIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetRegisteredEventsIndMsgT_v02), qmiLocGetRegisteredEventsIndMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeReqMsgT_v02), qmiLocSetOperationModeReqMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeIndMsgT_v02), qmiLocSetOperationModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetOperationModeIndMsgT_v02), qmiLocGetOperationModeIndMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusReqMsgT_v02), qmiLocSetSpiStatusReqMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusIndMsgT_v02), qmiLocSetSpiStatusIndMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataReqMsgT_v02), qmiLocInjectSensorDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataIndMsgT_v02), qmiLocInjectSensorDataIndMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02), qmiLocInjectTimeSyncDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02), qmiLocInjectTimeSyncDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetCradleMountConfigIndMsgT_v02), qmiLocGetCradleMountConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigReqMsgT_v02), qmiLocSetCradleMountConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigIndMsgT_v02), qmiLocSetCradleMountConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02), qmiLocGetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02), qmiLocSetExternalPowerConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02), qmiLocSetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02), qmiLocInformLocationServerConnStatusReqMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02), qmiLocInformLocationServerConnStatusIndMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02), qmiLocSetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02), qmiLocSetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02), qmiLocGetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02), qmiLocGetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigReqMsgT_v02), qmiLocSetSensorControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigIndMsgT_v02), qmiLocSetSensorControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02), qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateReqMsgT_v02), qmiLocInjectSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateIndMsgT_v02), qmiLocInjectSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02), qmiLocDeleteSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02), qmiLocDeleteSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02} +}; + +/* Predefine the Type Table Object */ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02; + +/*Referenced Tables Array*/ +static const qmi_idl_type_table_object *loc_qmi_idl_type_table_object_referenced_tables_v02[] = +{&loc_qmi_idl_type_table_object_v02, &common_qmi_idl_type_table_object_v01}; + +/*Type Table Object*/ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { + sizeof(loc_type_table_v02)/sizeof(qmi_idl_type_table_entry ), + sizeof(loc_message_table_v02)/sizeof(qmi_idl_message_table_entry), + 1, + loc_type_table_v02, + loc_message_table_v02, + loc_qmi_idl_type_table_object_referenced_tables_v02 +}; + +/*Arrays of service_message_table_entries for commands, responses and indications*/ +static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, + {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, + {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 32}, + {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, + {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 19), 0}, + {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 21), 0}, + {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 23), 1075}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 25), 1053}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 27), 0}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 29), 0}, + {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 31), 18}, + {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 33), 112}, + {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 35), 7}, + {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 37), 0}, + {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 39), 4}, + {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 41), 0}, + {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 43), 7}, + {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 45), 0}, + {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 47), 4}, + {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 49), 0}, + {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 51), 297}, + {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 53), 11}, + {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 55), 929}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 57), 4}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 59), 0}, + {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 61), 694}, + {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 63), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 65), 0}, + {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 67), 7}, + {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 69), 0}, + {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 71), 8}, + {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 73), 1425}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 75), 21}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 79), 11}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 77), 0}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 83), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 81), 0}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 85), 129}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 87), 18}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 89), 11}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 91), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 93), 0}, + {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 95), 7}, + {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 97), 0}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 99), 21}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 101), 0}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 103), 2009}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 105), 4}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 107), 12}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 109), 7} +}; + +static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_REG_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_START_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_STOP_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVICE_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_FIX_CRITERIA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NI_USER_RESPONSE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_UTC_TIME_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_ASSIST_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_WIFI_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SPI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7} +}; + +static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { + {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 224}, + {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, + {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, + {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1068}, + {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, + {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, + {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, + {QMI_LOC_EVENT_ENGINE_STATE_IND_V02, TYPE16(0, 12), 7}, + {QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, TYPE16(0, 13), 11}, + {QMI_LOC_EVENT_WIFI_REQ_IND_V02, TYPE16(0, 14), 12}, + {QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, TYPE16(0, 15), 16}, + {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, + {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, + {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, + {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 20), 14}, + {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 22), 28}, + {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 24), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 26), 12}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 28), 790}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 30), 20}, + {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 32), 7}, + {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 34), 7}, + {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 36), 7}, + {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 38), 14}, + {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 40), 7}, + {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 42), 11}, + {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 44), 7}, + {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 46), 14}, + {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 48), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 50), 11}, + {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 52), 7}, + {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 54), 304}, + {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 56), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 58), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 60), 11}, + {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 62), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 64), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 66), 18}, + {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 68), 7}, + {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 70), 14}, + {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 72), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 74), 22}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 76), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 80), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 78), 18}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 84), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 82), 14}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 86), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 88), 18}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 90), 25}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 92), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 94), 14}, + {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 96), 7}, + {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 98), 14}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 100), 14}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 102), 28}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 104), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 106), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 108), 14}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 110), 19} +}; + +/*Service Object*/ +const struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { + 0x02, + 0x02, + 16, + 2248, + { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, + { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, + &loc_qmi_idl_type_table_object_v02 +}; + +/* Service Object Accessor */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ){ + if ( LOC_V02_IDL_MAJOR_VERS != idl_maj_version || LOC_V02_IDL_MINOR_VERS != idl_min_version + || LOC_V02_IDL_TOOL_VERS != library_version) + { + return NULL; + } + return (qmi_idl_service_object_type)&loc_qmi_idl_service_object_v02; +} + diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h new file mode 100755 index 00000000..2f288145 --- /dev/null +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -0,0 +1,5914 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef LOC_SERVICE_H +#define LOC_SERVICE_H +/** + @file location_service_v02.h + + @brief This is the public header file which defines the loc service Data structures. + + This header file defines the types and structures that were defined in + loc. It contains the constant values defined, enums, structures, + messages, and service message IDs (in that order) Structures that were + defined in the IDL as messages contain mandatory elements, optional + elements, a combination of mandatory and optional elements (mandatory + always come before optionals in the structure), or nothing (null message) + + An optional element in a message is preceded by a uint8_t value that must be + set to true if the element is going to be included. When decoding a received + message, the uint8_t values will be set to true or false by the decode + routine, and should be checked before accessing the values that they + correspond to. + + Variable sized arrays are defined as static sized arrays with an unsigned + integer (32 bit) preceding it that must be set to the number of elements + in the array that are valid. For Example: + + uint32_t test_opaque_len; + uint8_t test_opaque[16]; + + If only 4 elements are added to test_opaque[] then test_opaque_len must be + set to 4 before sending the message. When decoding, the _len value is set + by the decode routine and should be checked so that the correct number of + elements in the array will be accessed. + +*/ + +/** @defgroup loc_qmi_consts Constant values defined in the IDL */ +/** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ +/** @defgroup loc_qmi_enums Enumerated types used in QMI messages */ +/** @defgroup loc_qmi_messages Structures sent as QMI messages */ +/** @defgroup loc_qmi_aggregates Aggregate types used in QMI messages */ +/** @defgroup loc_qmi_accessor Accessor for QMI service object */ +/** @defgroup loc_qmi_version Constant values for versioning information */ + +#include +#include "qmi_idl_lib.h" +#include "common_v01.h" + + +#ifdef __cplusplus +extern "C" { +#endif + +/** @addtogroup loc_qmi_version + @{ + */ +/** Major Version Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MAJOR_VERS 0x02 +/** Revision Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MINOR_VERS 0x04 +/** Major Version Number of the qmi_idl_compiler used to generate this file */ +#define LOC_V02_IDL_TOOL_VERS 0x02 +/** Maximum Defined Message ID */ +#define LOC_V02_MAX_MESSAGE_ID 0x005F; +/** + @} + */ + + +/** @addtogroup loc_qmi_consts + @{ + */ + +/** Maximum number of satellites in the satellite report. */ +#define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 + +/** Maximum NMEA string length. */ +#define QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 200 + +/** Maximum length of the requestor ID string. */ +#define QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02 200 + +/** Session ID byte length. */ +#define QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02 4 + +/** Maximum client name length allowed. */ +#define QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02 64 + +/** Maximum URL length accepted by the location engine. */ +#define QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 255 + +/** IPV6 address length in bytes. */ +#define QMI_LOC_IPV6_ADDR_LENGTH_V02 8 + +/** SUPL hash length. */ +#define QMI_LOC_NI_SUPL_HASH_LENGTH_V02 8 + +/** Maximum client address length allowed. */ +#define QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02 20 + +/** Maximum codeword length allowed. */ +#define QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02 20 + +/** Maximum number of NTP Servers sent out with this event. */ +#define QMI_LOC_MAX_NTP_SERVERS_V02 3 + +/** Maximum number of predicted orbits servers supported in the location + engine. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 + +/** Maximum part length that can be injected. The client should + also look at the maxPartSize field in the predicted orbits injection + request indication and pick the minimum of the two. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 1024 + +/** Maximum length of the delete SV information list */ +#define QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02 128 + +/** MAC address length in bytes. */ +#define QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02 6 + +/** Maximum number of APs that the sender can report. */ +#define QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02 50 + +/** Maximum number of samples that can be injected in a TLV. */ +#define QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02 50 + +/** Maximum APN string length allowed. */ +#define QMI_LOC_MAX_APN_NAME_LENGTH_V02 100 + +/** Maximum APN profiles supported. */ +#define QMI_LOC_MAX_APN_PROFILES_V02 6 + +/** Maximum length of SUPL CERT. */ +#define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Response Message; Generic response definition. This message is used to tell + clients whether their message was accepted for further + processing or rejected. */ +typedef struct { + + /* Mandatory */ + /* Result Code */ + qmi_response_type_v01 resp; +}qmiLocGenRespMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Informs the service of the minor revision of the interface + definition that the control point implements. */ +typedef struct { + + /* Mandatory */ + /* Revision */ + uint32_t revision; + /**< Revision that the control point is using. \n + - Type: Unsigned integer */ +}qmiLocInformClientRevisionReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocEventRegMaskT_v02; +#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001) /**< The control point must enable this mask to receive position report + event indications. */ +#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002) /**< The control point must enable this mask to receive satellite report + event indications. These reports are sent at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004) /**< The control point must enable this mask to receive NMEA reports for + position and satellites in view. The report is at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008) /**< The control point must enable this mask to receive NI notify verify request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010) /**< The control point must enable this mask to receive time injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020) /**< The control point must enable this mask to receive predicted orbits request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040) /**< The control point must enable this mask to receive position injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080) /**< The control point must enable this mask to receive engine state report + event indications. */ +#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100) /**< The control point must enable this mask to receive fix session status report + event indications. */ +#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200) /**< The control point must enable this mask to receive WiFi position request + event indications. */ +#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400) /**< The control point must enable this mask to receive notifications from the + GPS engine indicating its readiness to accept data from the + sensors (accelerometer, gyrometer, etc.). */ +#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800) /**< The control point must enable this mask to receive time-sync requests from + the GPS engine. Time sync enables the GPS engine to synchronize + its clock with the sensor processor's clock. */ +#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000) /**< The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. */ +#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000) /**< The control point must enable this mask to receive location server requests. + These requests are generated when the service wishes to establish a + connection with a location server. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to register for events from the + location subsystem. */ +typedef struct { + + /* Mandatory */ + /* Event Registration Mask */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Specifies the events that the control point is interested in receiving. + Refer to the definition of the following bitmasks: \n + + - 0x00000001 -- POSITION_REPORT \n + - 0x00000002 -- GNSS_SV_INFO \n + - 0x00000004 -- NMEA \n + - 0x00000008 -- NI_NOTIFY_VERIFY_REQ \n + - 0x00000010 -- INJECT_TIME_REQ \n + - 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ \n + - 0x00000040 -- INJECT_POSITION_REQ \n + - 0x00000080 -- ENGINE_STATE \n + - 0x00000100 -- FIX_SESSION_STATE \n + - 0x00000200 -- WIFI_REQ \n + - 0x00000400 -- SENSOR_STREAMING_READY_STATUS \n + - 0x00000800 -- TIME_SYNC_REQ \n + - 0x00001000 -- SET_SPI_STREAMING_REPORT \n + - 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ + + Multiple events can be registered by ORing the individual masks and + sending them in this TLV. All unused bits in this mask must be set to 0. + */ +}qmiLocRegEventsReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. + Request a single position fix. */ + eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, + QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixRecurrenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ + eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. + High accuracy. */ + eQMI_LOC_ACCURACY_HIGH_V02 = 3, + QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAccuracyLevelEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. + Intermediate reports are turned off. */ + eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, + QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocIntermediateReportStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; The control point sends this message when it wants to + initiate a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session as identified by the control point. The session ID + is reported back in the position reports. The control point must + specify the same session ID in the QMI_LOC_STOP_REQ message. \n + - Type: Unsigned integer \n + - Range: 0 to 255 + */ + + /* Optional */ + /* Recurrence Type */ + uint8_t fixRecurrence_valid; /**< Must be set to true if fixRecurrence is being passed */ + qmiLocFixRecurrenceEnumT_v02 fixRecurrence; + /**< Specifies the type of session in which the control point is interested. + If this TLV is not specified, recurrence defaults to SINGLE. + + Valid values: \n + - 0x00000001 -- Request periodic fixes \n + - 0x00000002 -- Request a single fix + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Specifies the horizontal accuracy level required by the control point. + If not specified, accuracy defaults to LOW. + + Valid values: \n + - 0x00000001 -- LOW: Client requires low horizontal accuracy.\n + - 0x00000002 -- MED: Client requires medium horizontal accuracy.\n + - 0x00000003 -- HIGH: Client requires high horizontal accuracy. + */ + + /* Optional */ + /* Enable/Disable Intermediate Reports */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Specifies if the control point is interested in receiving intermediate + reports. The control point must explicitly set this field to OFF if it + does not wish to receive intermediate position reports. Intermediate + position reports are generated at 1 Hz and are ON by default. If + intermediate reports are turned ON, the client receives position reports + even if the accuracy criteria are not met. The status in such a position + report is set to IN_PROGRESS in order for the control point to identify + intermediate reports. + + Valid values: \n + - 0x00000001 -- ON: Client is interested in receiving intermediate reports \n + - 0x00000002 -- OFF: Client is not interested in receiving intermediate reports + */ + + /* Optional */ + /* Minimum Interval Between Position Reports */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Minimum time interval, specified by the control point, that must elapse between + position reports. \n + - Type: Unsigned integer \n + - Units: Milliseconds \n + - Default: 1000 ms + */ +}qmiLocStartReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; The control point sends this message when it wants to + stop a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + (QMI_LOC_START_REQ).\n + - Type: Unsigned integer \n + - Range: 0 to 255 */ +}qmiLocStopReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPosTechMaskT_v02; +#define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSESSIONSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SESS_STATUS_SUCCESS_V02 = 0, /**< Session was successful. */ + eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 = 1, /**< Session still in progress. Further position reports will be + generated until either the fix criteria specified by the client + are met or the client response timeout occurs. */ + eQMI_LOC_SESS_STATUS_GENERAL_FAILURE_V02 = 2, /**< Session failed. */ + eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ + eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ + eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ + eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. + Fix request failed because the engine is locked. */ + eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, + QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSessionStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gpsWeek; + /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n + - Type: Unsigned integer \n + - Units: Weeks */ + + uint32_t gpsTimeOfWeekMs; + /**< Amount of time into the current GPS week. \n + - Type: Unsigned integer \n + - Units: Milliseconds */ +}qmiLocGPSTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + float PDOP; + /**< Position dilution of precision.\n + - Type: Floating point \n + - Range: 1 (highest accuracy) to 50 (lowest accuracy)\n + - PDOP = square root of (HDOP^2 + VDOP^2) */ + + float HDOP; + /**< Horizontal dilution of precision.\n + - Type: Floating point \n + - Range: 1 (highest accuracy) to 50 (lowest accuracy) */ + + float VDOP; + /**< Vertical dilution of precision.\n + - Type: Floating point. \n + - Range: 1 (highest accuracy) to 50 (lowest accuracy) */ +}qmiLocDOPStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocSensorUsageMaskT_v02; +#define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ +#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyrometer was used. */ +typedef uint32_t qmiLocSensorAidedMaskT_v02; +#define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ +#define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ +#define QMI_LOC_SENSOR_AIDED_MASK_POSITION_V02 ((qmiLocSensorAidedMaskT_v02)0x00000004) /**< Bitmask to specify whether a sensor was used to calculate position. */ +#define QMI_LOC_SENSOR_AIDED_MASK_VELOCITY_V02 ((qmiLocSensorAidedMaskT_v02)0x00000008) /**< Bitmask to specify whether a sensor was used to calculate velocity. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSensorUsageMaskT_v02 usageMask; + /**< Specifies which sensors are used. + + Valid bitmasks are specified by the following constants: \n + - 0x00000001 -- SENSOR_USED_ACCEL \n + - 0x00000002 -- SENSOR_USED_GYRO */ + + qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; + /**< Specifies which results are aided by sensors. + + Valid bitmasks are specified by the following constants: \n + - 0x00000001 -- AIDED_HEADING \n + - 0x00000002 -- AIDED_SPEED \n + - 0x00000004 -- AIDED_POSITION \n + - 0x00000008 -- AIDED_VELOCITY */ +}qmiLocSensorUsageIndicatorStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCTIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_TIME_SRC_INVALID_V02 = 0, /**< Invalid time. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER_V02 = 1, /**< Time is set by the 1x system. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING_V02 = 2, /**< Time is set by WCDMA/GSM time tagging (i.e., + associating network time with GPS time). */ + eQMI_LOC_TIME_SRC_EXTERNAL_INPUT_V02 = 3, /**< Time is set by an external injection. */ + eQMI_LOC_TIME_SRC_TOW_DECODE_V02 = 4, /**< Time is set after decoding over-the-air GPS navigation data + from one GPS satellite. */ + eQMI_LOC_TIME_SRC_TOW_CONFIRMED_V02 = 5, /**< Time is set after decoding over-the-air GPS navigation data + from multiple satellites. */ + eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED_V02 = 6, /**< Both time of the week and the GPS week number are known. */ + eQMI_LOC_TIME_SRC_NAV_SOLUTION_V02 = 7, /**< Time is set by the position engine after the fix is obtained. */ + eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME_V02 = 8, /**< Time is set by the position engine after performing SFT. + This is done when the clock time uncertainty is large. */ + eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ + eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ + eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ + eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network + Source of the time is unknown */ + eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, + QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocTimeSourceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCRELIABILITYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ + eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ + eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ + eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed + Location reliability is high; strong cross-check passed */ + eQMI_LOC_RELIABILITY_HIGH_V02 = 4, + QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocReliabilityEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; This message is used to send the position report to the + control point. */ +typedef struct { + + /* Mandatory */ + /* Session Status */ + qmiLocSessionStatusEnumT_v02 sessionStatus; + /**< Session status. + + Valid values: \n + - 0x00000000 -- SESS_STATUS_SUCCESS \n + - 0x00000001 -- SESS_STATUS_IN_PROGRESS \n + - 0x00000002 -- SESS_STATUS_GENERAL_FAILURE \n + - 0x00000003 -- SESS_STATUS_TIMEOUT \n + - 0x00000004 -- SESS_STATUS_USER_END \n + - 0x00000005 -- SESS_STATUS_BAD_PARAMETER \n + - 0x00000006 -- SESS_STATUS_PHONE_OFFLINE \n + - 0x00000007 -- SESS_STATUS_ENGINE_LOCKED + */ + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + QMI_LOC_START_REQ. \n + - Type: Unsigned integer \n + - Range: 0 to 255 */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). \n + - Type: Floating point \n + - Units: Degrees \n + - Range: -90.0 to 90.0 \n + - Positive values indicate northern latitude \n + - Negative values indicate southern latitude */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum).\n + - Type: Floating point \n + - Units: Degrees \n + - Range: -180.0 to 180.0 \n + - Positive values indicate eastern longitude \n + - Negative values indicate western longitude */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Elliptical Horizontal Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Type: Floating point \n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal uncertainty confidence.\n + - Type: Unsigned integer \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \n + - 0x00000000 -- RELIABILITY_NOT_SET \n + - 0x00000001 -- RELIABILITY_VERY_LOW \n + - 0x00000002 -- RELIABILITY_LOW \n + - 0x00000003 -- RELIABILITY_MEDIUM \n + - 0x00000004 -- RELIABILITY_HIGH + */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Type: Floating point \n + - Units: Meters/second */ + + /* Optional */ + /* Speed Uncertainty */ + uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ + float speedUnc; + /**< Speed uncertainty.\n + - Type: Floating point \n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Type: Floating point \n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence.\n + - Type: Unsigned integer \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \n + - 0x00000000 -- RELIABILITY_NOT_SET \n + - 0x00000001 -- RELIABILITY_VERY_LOW \n + - 0x00000002 -- RELIABILITY_LOW \n + - 0x00000003 -- RELIABILITY_MEDIUM \n + - 0x00000004 -- RELIABILITY_HIGH */ + + /* Optional */ + /* Vertical Speed */ + uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ + float speedVertical; + /**< Vertical speed.\n + - Type: Floating point \n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading.\n + - Type: Floating point \n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty.\n + - Type: Floating point \n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. \n + - Type: Floating point */ + + /* Optional */ + /* Technology Used */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: \n + - 0x00000001 -- SATELLITE \n + - 0x00000002 -- CELLID \n + - 0x00000004 -- WIFI */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + /**< \n Dilution of precision associated with this position. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Type: Unsigned integer \n + - Units: Milliseconds since Jan. 1, 1970 */ + + /* Optional */ + /* Leap Seconds */ + uint8_t leapSeconds_valid; /**< Must be set to true if leapSeconds is being passed */ + uint8_t leapSeconds; + /**< Leap second information. If leapSeconds is not available, + timestampUtc is calculated based on a hard-coded value + for leap seconds. \n + - Type: Unsigned integer \n + - Units: Seconds */ + + /* Optional */ + /* GPS Time \n */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + /**< \n The number of weeks since Jan. 5, 1980, and + milliseconds into the current week. */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Type: Floating point \n + - Units: Milliseconds */ + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. + + Valid values: \n + - 0x00000000 -- TIME_SRC_INVALID \n + - 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER \n + - 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING \n + - 0x00000003 -- TIME_SRC_EXTERNAL_ INPUT \n + - 0x00000004 -- TIME_SRC_TOW_DECODE \n + - 0x00000005 -- TIME_SRC_TOW_CONFIRMED \n + - 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED \n + - 0x00000007 -- TIME_SRC_NAV_SOLUTION \n + - 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + /**< \n Whether sensor data was used in computing the position in this + position report. */ + + /* Optional */ + /* Fix Count for This Session */ + uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ + uint32_t fixId; + /**< Fix count for the session. Starts with 0 and increments by one + for each successive position report for a particular session. */ +}qmiLocEventPositionReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSYSTEMENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ + eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ + eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ + eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. + GLONASS satellite. */ + eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, + QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvSystemEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ + eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. + SV is being tracked. */ + eQMI_LOC_SV_STATUS_TRACK_V02 = 3, + QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvStatusEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocSvInfoValidMaskT_v02; +#define QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000001) /**< System field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000002) /**< gnssSvId field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_HEALTH_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000004) /**< healthStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000008) /**< processStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000010) /**< svInfoMask field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000020) /**< Elevation field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000040) /**< Azimuth field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000080) /**< SNR field is valid in SV information. */ +typedef uint8_t qmiLocSvInfoMaskT_v02; +#define QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02 ((qmiLocSvInfoMaskT_v02)0x01) /**< Ephemeris is available for this SV. */ +#define QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02 ((qmiLocSvInfoMaskT_v02)0x02) /**< Almanac is available for this SV. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSvInfoValidMaskT_v02 validMask; + /**< Bitmask indicating which of the fields in this TLV are valid. + + Valid bitmasks: \n + - 0x00000001 -- VALID_SYSTEM \n + - 0x00000002 -- VALID_GNSS_SVID \n + - 0x00000004 -- VALID_HEALTH_STATUS \n + - 0x00000008 -- VALID_PROCESS_STATUS \n + - 0x00000010 -- VALID_SVINFO_MASK \n + - 0x00000020 -- VALID_ELEVATION \n + - 0x00000040 -- VALID_AZIMUTH \n + - 0x00000080 -- VALID_SNR + + */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + + Valid values: \n + - 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \n + - 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \n + - 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \n + - 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \n + - 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + */ + + uint16_t gnssSvId; + /**< GNSS SV ID. \n + + - Type: Unsigned integer \n + - Range: \n + -- For GPS: 1 to 32 \n + -- For SBAS: 33 to 64 \n + -- For GLONASS: 65 to 96 */ + + uint8_t healthStatus; + /**< Health status. \n + - Type: Unsigned integer \n + - Range: 0 = unhealthy; 1 = healthy */ + + qmiLocSvStatusEnumT_v02 svStatus; + /**< SV processing status. \n + Valid values:\n + - 0x00000001 -- SV_STATUS_IDLE \n + - 0x00000002 -- SV_STATUS_SEARCH \n + - 0x00000003 -- SV_STATUS_TRACK + */ + + qmiLocSvInfoMaskT_v02 svInfoMask; + /**< Whether almanac and ephemeris information is available. \n + Valid bitmasks: \n + - 0x01 -- SVINFO_HAS_EPHEMERIS \n + - 0x02 -- SVINFO_HAS_ALMANAC + */ + + float elevation; + /**< SV elevation angle.\n + - Type: Floating point \n + - Units: Degrees \n + - Range: 0 to 90 */ + + float azimuth; + /**< SV azimuth angle.\n + - Type: Floating point \n + - Units: Degrees \n + - Range: 0 to 360 */ + + float snr; + /**< SV signal-to-noise ratio. \n + - Type: Floating point \n + - Units: dB-Hz */ +}qmiLocSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to send a satellite report to the control point. */ +typedef struct { + + /* Mandatory */ + /* Altitude Source */ + uint8_t altitudeAssumed; + /**< Altitude assumed or calculated:\n + - 0x00 (FALSE) -- Valid altitude is calculated \n + - 0x01 (TRUE) -- Valid altitude is assumed; there may not be enough + satellites to determine precise altitude */ + + /* Optional */ + /* Satellite Info */ + uint8_t svList_valid; /**< Must be set to true if svList is being passed */ + uint32_t svList_len; /**< Must be set to # of elements in svList */ + qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; + /**< \n SV information list. */ +}qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to send NMEA sentences to the control point. */ +typedef struct { + + /* Mandatory */ + /* NMEA String */ + char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; + /**< NMEA string. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 201 */ +}qmiLocEventNmeaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNINOTIFYVERIFYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. + Notify and Verify, and require a response. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, + QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiNotifyVerifyEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ + eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ + eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. + MS-based preferred, but MS-assisted allowed. */ + eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, + QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxPosModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_OCTET_V02 = 0, /**< Encoding is OCTET. */ + eQMI_LOC_NI_VX_EXN_PROTOCOL_MSG_V02 = 1, /**< Encoding is EXN PROTOCOL MSG. */ + eQMI_LOC_NI_VX_ASCII_V02 = 2, /**< Encoding is ASCII. */ + eQMI_LOC_NI_VX_IA5_V02 = 3, /**< Encoding is IA5. */ + eQMI_LOC_NI_VX_UNICODE_V02 = 4, /**< Encoding is UNICODE. */ + eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ + eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ + eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ + eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. + Encoding is GSM. */ + eQMI_LOC_NI_VX_GSM_V02 = 9, + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t posQosIncl; + /**< Whether quality of service is included:\n + - 0x01 (TRUE) -- QoS is included \n + - 0x00 (FALSE) -- QoS is not included */ + + uint8_t posQos; + /**< Position QoS timeout. \n + - Type: Unsigned integer \n + - Units: Seconds \n + - Range: 0 to 255 */ + + uint32_t numFixes; + /**< Number of fixes allowed. \n + - Type: Unsigned integer */ + + uint32_t timeBetweenFixes; + /**< Time between fixes.\n + - Type: Unsigned integer \n + - Units: Seconds */ + + qmiLocNiVxPosModeEnumT_v02 posMode; + /**< Position mode. + + Valid values: \n + - 0x00000001 -- NI_VX_MS_ASSISTED_ONLY \n + - 0x00000002 -- NI_VX_MS_BASED_ONLY \n + - 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED \n + - 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED + */ + + qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; + /**< VX encoding scheme. + + Valid values: \n + - 0x00000000 -- NI_VX_OCTET \n + - 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG \n + - 0x00000002 -- NI_VX_ASCII \n + - 0x00000003 -- NI_VX_IA5 \n + - 0x00000004 -- NI_VX_UNICODE \n + - 0x00000005 -- NI_VX_SHIFT_JIS \n + - 0x00000006 -- NI_VX_KOREAN \n + - 0x00000007 -- NI_VX_LATIN_HEBREW \n + - 0x00000008 -- NI_VX_LATIN \n + - 0x00000009 -- NI_VX_GSM + */ + + uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ + uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; + /**< Requestor ID. \n + - Type: Array of bytes \n + - Maximum array length: 200 + */ + + uint16_t userRespTimerInSeconds; + /**< Time to wait for the user to respond. \n + - Type: Unsigned integer \n + - Units: Seconds */ +}qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLPOSMETHODENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_V02 = 1, /**< Set assisted. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_V02 = 2, /**< Set based. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_PREF_V02 = 3, /**< Set assisted preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_PREF_V02 = 4, /**< Set based preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AUTONOMOUS_GPS_V02 = 5, /**< Standalone GPS. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ + eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ + eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ + eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. + No position. */ + eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, + QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplPosMethodEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIDATACODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SS_GERMAN_V02 = 12, /**< Language is German. */ + eQMI_LOC_NI_SS_ENGLISH_V02 = 13, /**< Language is English. */ + eQMI_LOC_NI_SS_ITALIAN_V02 = 14, /**< Language is Italian. */ + eQMI_LOC_NI_SS_FRENCH_V02 = 15, /**< Language is French. */ + eQMI_LOC_NI_SS_SPANISH_V02 = 16, /**< Language is Spanish. */ + eQMI_LOC_NI_SS_DUTCH_V02 = 17, /**< Language is Dutch. */ + eQMI_LOC_NI_SS_SWEDISH_V02 = 18, /**< Language is Swedish. */ + eQMI_LOC_NI_SS_DANISH_V02 = 19, /**< Language is Danish. */ + eQMI_LOC_NI_SS_PORTUGUESE_V02 = 20, /**< Language is Portuguese. */ + eQMI_LOC_NI_SS_FINNISH_V02 = 21, /**< Language is Finnish. */ + eQMI_LOC_NI_SS_NORWEGIAN_V02 = 22, /**< Language is Norwegian. */ + eQMI_LOC_NI_SS_GREEK_V02 = 23, /**< Language is Greek. */ + eQMI_LOC_NI_SS_TURKISH_V02 = 24, /**< Language is Turkish. */ + eQMI_LOC_NI_SS_HUNGARIAN_V02 = 25, /**< Language is Hungarian. */ + eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ + eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ + eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ + eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. + Encoding is GSM default. */ + eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, + QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiDataCodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLFORMATENUMTYPE_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_FORMAT_LOGICAL_NAME_V02 = 0, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_EMAIL_ADDRESS_V02 = 1, /**< SUPL email address format. */ + eQMI_LOC_NI_SUPL_FORMAT_MSISDN_V02 = 2, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_URL_V02 = 3, /**< SUPL URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ + eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ + eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity + SUPL unknown format. */ + eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, + QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplFormatEnumType_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplFormatEnumType_v02 formatType; + /**< Format of the formatted string. + + Valid values: \n + - 0x00000000 -- FORMAT_LOGICAL_NAME \n + - 0x00000001 -- FORMAT_EMAIL_ADDRESS \n + - 0x00000002 -- FORMAT_MSISDN \n + - 0x00000003 -- FORMAT_URL \n + - 0x00000004 -- FORMAT_SIP_URL \n + - 0x00000005 -- FORMAT_MIN \n + - 0x00000006 -- FORMAT_MDN \n + - 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY \n + - 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN + */ + + uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ + uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Formatted string. \n + - Type: Byte array \n + - Maximum string length: 64 + */ +}qmiLocNiSuplFormattedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocSuplQopValidMaskT_v02; +#define QMI_LOC_NI_SUPL_MASK_QOP_HORZ_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x01) /**< Horizontal accuracy is valid in the Quality of Position (QoP). */ +#define QMI_LOC_NI_SUPL_MASK_QOP_VER_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x02) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_MAXAGE_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x04) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_DELAY_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x08) /**< Vertical accuracy is valid in the QoP. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSuplQopValidMaskT_v02 validMask; + /**< Bit field indicating which fields are valid in this value. + + Valid bitmasks: \n + - 0x01 -- QOP_HORZ_ACC_VALID \n + - 0x02 -- QOP_VER_ACC_VALID \n + - 0x04 -- QOP_MAXAGE_VALID \n + - 0x08 -- QOP_DELAY_VALID */ + + uint8_t horizontalAccuracy; + /**< Horizontal accuracy. \n + - Type: Unsigned integer \n + - Units: Meters */ + + uint8_t verticalAccuracy; + /**< Vertical accuracy. \n + - Type: Unsigned integer \n + - Units: Meters */ + + uint16_t maxLocAge; + /**< Maximum age of the location if the engine sends a previously + computed position. \n + - Type: Unsigned integer \n + - Units: Seconds */ + + uint8_t delay; + /**< Delay the server is willing to tolerate for the fix. \n + - Type: Unsigned integer \n + - Units: Seconds */ +}qmiLocNiSuplQopStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocServerAddrTypeMaskT_v02; +#define QMI_LOC_SERVER_ADDR_TYPE_IPV4_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x01) /**< IPV4 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_IPV6_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x02) /**< IPV6 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_URL_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x04) /**< URL server address type. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t addr; + /**< IPV4 address. \n + - Type: Unsigned integer */ + + uint16_t port; + /**< IPV4 port. \n + - Type: Unsigned integer */ +}qmiLocIpV4AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; + /**< IPV6 address. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 8 */ + + uint32_t port; + /**< IPV6 port. \n + - Type: Unsigned integer */ +}qmiLocIpV6AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerAddrTypeMaskT_v02 suplServerAddrTypeMask; + /**< Mask specifying the valid fields in this value. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ + + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< IPV4 address and port. */ + + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< IPV6 address and port. */ + + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 256 + */ +}qmiLocNiSuplServerInfoStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocNiSuplNotifyVerifyValidMaskT_v02; +#define QMI_LOC_SUPL_SERVER_INFO_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000001) /**< Mask to denote that the server information + is present in an NI SUPL notify verify request event. This mask is set in + the valid_flags field of a notify verify structure. */ +#define QMI_LOC_SUPL_SESSION_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000002) /**< Mask to denote that the SUPL session ID + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_HASH_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000004) /**< Mask to denote that the SUPL hash is present + in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_POS_METHOD_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000008) /**< Mask to denote that the position method is present + in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000010) /**< Mask to denote that the data coding scheme + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_CLIENT_NAME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000040) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_QOP_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000080) /**< Mask to denote that the quality of position + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_USER_RESP_TIMER_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; + /**< Indicates which of the following fields are present in this value. + + Valid bitmasks: \n + - 0x00000001 -- SUPL_SERVER_INFO \n + - 0x00000002 -- SUPL_SESSION_ID \n + - 0x00000004 -- SUPL_HASH \n + - 0x00000008 -- SUPL_POS_METHOD \n + - 0x00000010 -- SUPL_DATA_CODING_SCHEME \n + - 0x00000020 -- SUPL_REQUESTOR_ID \n + - 0x00000040 -- SUPL_CLIENT_NAME \n + - 0x00000080 -- SUPL_QOP \n + - 0x00000100 -- SUPL_USER_RESP_TIMER + */ + + qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; + /**< SUPL server information. */ + + uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; + /**< SUPL session ID. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 4 */ + + uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; + /**< Hash for SUPL_INIT; used to validate that the message was not + corrupted. \n + - Type: Array of unsigned integers \n + - Length of the array: 8 */ + + qmiLocNiSuplPosMethodEnumT_v02 posMethod; + /**< GPS mode to be used for the fix. + + Valid values: \n + - 0x00000001 -- AGPS_SETASSISTED \n + - 0x00000002 -- AGPS_SETBASED \n + - 0x00000003 -- AGPS_SETASSISTED_PREF \n + - 0x00000004 -- AGPS_SETBASED_PREF \n + - 0x00000005 -- AUTONOMOUS_GPS \n + - 0x00000006 -- AFLT \n + - 0x00000007 -- ECID \n + - 0x00000008 -- EOTD \n + - 0x00000009 -- OTDOA \n + - 0x0000000A -- NO_POSITION + */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Data coding scheme applies to both the requestor ID and the client + name. + + Valid values: \n + - 0x0000000C -- NI_SS_GERMAN \n + - 0x0000000D -- NI_SS_ENGLISH \n + - 0x0000000E -- NI_SS_ITALIAN \n + - 0x0000000F -- NI_SS_FRENCH \n + - 0x00000010 -- NI_SS_SPANISH \n + - 0x00000011 -- NI_SS_DUTCH \n + - 0x00000012 -- NI_SS_SWEDISH \n + - 0x00000013 -- NI_SS_DANISH \n + - 0x00000014 -- NI_SS_PORTUGUESE \n + - 0x00000015 -- NI_SS_FINNISH \n + - 0x00000016 -- NI_SS_NORWEGIAN \n + - 0x00000017 -- NI_SS_GREEK \n + - 0x00000018 -- NI_SS_TURKISH \n + - 0x00000019 -- NI_SS_HUNGARIAN \n + - 0x0000001A -- NI_SS_POLISH \n + - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n + - 0x0000001C -- NI_SUPL_UTF8 \n + - 0x0000001D -- NI_SUPL_UCS2 \n + - 0x0000001E -- NI_SUPL_GSM_DEFAULT + */ + + qmiLocNiSuplFormattedStringStructT_v02 requestorId; + /**< Requestor ID. The encoding scheme for requestor_id is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplFormattedStringStructT_v02 clientName; + /**< Client name. The encoding scheme for client_name is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplQopStructT_v02 suplQop; + /**< SUPL QoP. */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Type: Unsigned integer \n + - Units: Seconds */ +}qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. + Initial location. */ + eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, + QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiLocationTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Identifies the coding scheme of the coded string. + + Valid values: \n + - 0x0000000C -- NI_SS_GERMAN \n + - 0x0000000D -- NI_SS_ENGLISH \n + - 0x0000000E -- NI_SS_ITALIAN \n + - 0x0000000F -- NI_SS_FRENCH \n + - 0x00000010 -- NI_SS_SPANISH \n + - 0x00000011 -- NI_SS_DUTCH \n + - 0x00000012 -- NI_SS_SWEDISH \n + - 0x00000013 -- NI_SS_DANISH \n + - 0x00000014 -- NI_SS_PORTUGUESE \n + - 0x00000015 -- NI_SS_FINNISH \n + - 0x00000016 -- NI_SS_NORWEGIAN \n + - 0x00000017 -- NI_SS_GREEK \n + - 0x00000018 -- NI_SS_TURKISH \n + - 0x00000019 -- NI_SS_HUNGARIAN \n + - 0x0000001A -- NI_SS_POLISH \n + - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n + - 0x0000001C -- NI_SUPL_UTF8 \n + - 0x0000001D -- NI_SUPL_UCS2 \n + - 0x0000001E -- NI_SUPL_GSM_DEFAULT + + */ + + uint32_t codedString_len; /**< Must be set to # of elements in codedString */ + uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; + /**< Coded string. \n + - Type: Array of bytes \n + - Maximum string length: 20 */ +}qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint16_t qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02; +#define QMI_LOC_UMTS_CP_INVOKE_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0001) /**< Mask to denote that the invoke ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0002) /**< Mask to denote that the data coding scheme + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_NOTIFICATION_TEXT_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0004) /**< Mask to denote that the notification text + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CLIENT_ADDRESS_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0008) /**< Mask to denote that the client address + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_LOCATION_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0010) /**< Mask to denote that the location type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_REQUESTOR_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CODEWORD_STRING_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0040) /**< Mask to denote that the code word string + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_SERVICE_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0080) /**< Mask to denote that the service type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_USER_RESP_TIMER_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; + /**< Fields that are valid in this value. + + Valid bitmasks: \n + - 0x0001 -- INVOKE_ID_MASK \n + - 0x0002 -- DATA_CODING_SCHEME_MASK \n + - 0x0004 -- NOTIFICATION_TEXT_MASK \n + - 0x0008 -- CLIENT_ADDRESS_MASK \n + - 0x0010 -- LOCATION_TYPE_MASK \n + - 0x0020 -- REQUESTOR_ID_MASK \n + - 0x0040 -- CODEWORD_STRING_MASK \n + - 0x0080 -- SERVICE_TYPE_MASK \n + - 0x0100 -- USER_RESP_TIMER_MASK + */ + + uint8_t invokeId; + /**< Supplementary Services invoke ID. \n + - Type: Unsigned integer */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Type of data encoding scheme for the text. + Applies to both the notification text and the client address. + + Valid values: \n + - 0x0000000C -- NI_SS_GERMAN \n + - 0x0000000D -- NI_SS_ENGLISH \n + - 0x0000000E -- NI_SS_ITALIAN \n + - 0x0000000F -- NI_SS_FRENCH \n + - 0x00000010 -- NI_SS_SPANISH \n + - 0x00000011 -- NI_SS_DUTCH \n + - 0x00000012 -- NI_SS_SWEDISH \n + - 0x00000013 -- NI_SS_DANISH \n + - 0x00000014 -- NI_SS_PORTUGUESE \n + - 0x00000015 -- NI_SS_FINNISH \n + - 0x00000016 -- NI_SS_NORWEGIAN \n + - 0x00000017 -- NI_SS_GREEK \n + - 0x00000018 -- NI_SS_TURKISH \n + - 0x00000019 -- NI_SS_HUNGARIAN \n + - 0x0000001A -- NI_SS_POLISH \n + - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n + - 0x0000001C -- NI_SUPL_UTF8 \n + - 0x0000001D -- NI_SUPL_UCS2 \n + - 0x0000001E -- NI_SUPL_GSM_DEFAULT + */ + + uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ + uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Notification text; the encoding method is specified in + dataCodingScheme. \n + - Type: Array of bytes \n + - Maximum array length: 64 */ + + uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ + uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; + /**< Client address; the encoding method is specified in + dataCodingScheme. \n + - Maximum array length: 20 */ + + qmiLocNiLocationTypeEnumT_v02 locationType; + /**< Location type. + + Valid values: \n + - 0x00000001 -- CURRENT_LOCATION \n + - 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION \n + - 0x00000004 -- INITIAL_LOCATION + */ + + qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; + /**< Requestor ID; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; + /**< Codeword string; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + uint8_t lcsServiceTypeId; + /**< Service type ID. \n + - Type: Unsigned integer */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Type: Unsigned integer \n + - Units: Seconds */ +}qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISERVICEINTERACTIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO_V02 = 1, /**< Service interaction between ongoing NI and incoming MO sessions. */ + QMILOCNISERVICEINTERACTIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiServiceInteractionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; + /**< Ongoing NI session request; this information is currently not filled. */ + + qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; + /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. + + Valid values: \n + - 0x00000001 -- ONGOING_NI_INCOMING_MO + */ +}qmiLocNiVxServiceInteractionStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Indicates an NI notify/verify request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \n + - 0x00000001 -- NO_NOTIFY_NO_VERIFY \n + - 0x00000002 -- NOTIFY_ONLY \n + - 0x00000003 -- ALLOW_NO_RESP \n + - 0x00000004 -- NOT_ALLOW_NO_RESP \n + - 0x00000005 -- PRIVACY_OVERRIDE + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; + /**< \n Optional NI Vx request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; + /**< \n Optional NI service interaction payload. */ +}qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< Assistance server URL. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 256 */ +}qmiLocAssistanceServerUrlStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t delayThreshold; + /**< The time server is to be skipped if a one-way delay to the server + exceeds this threshold. \n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ + qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; + /**< List of Time Server URL's that are recommended by the service for time + information, the list is ordered, the client is to use the first + server specified in the list as the primary URL to fetch NTP time, + the second one as secondary, and so on. \n + - Maximum server list items: 3 */ +}qmiLocTimeServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject time information. */ +typedef struct { + + /* Optional */ + /* Time Server Info */ + uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ + qmiLocTimeServerListStructT_v02 timeServerInfo; + /**< \n Contains information about the time servers recommended by the + location service for NTP time. */ +}qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t maxFileSizeInBytes; + /**< Maximum allowable predicted orbits file size (in bytes). \n + - Type: Unsigned integer */ + + uint32_t maxPartSize; + /**< Maximum allowable predicted orbits file chunk size (in bytes). \n + - Type: Unsigned integer */ +}qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t serverList_len; /**< Must be set to # of elements in serverList */ + qmiLocAssistanceServerUrlStructT_v02 serverList[QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02]; + /**< List of predicted orbits URLs. The list is ordered, so the client + must use the first server specified in the list as the primary URL + from which to download predicted orbits data, the second one as + secondary, and so on. \n + - Maximum number of servers that can be specified: 3 */ +}qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Allowed Sizes */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject a position. */ +typedef struct { + + /* Mandatory */ + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum).\n + - Type: Floating point \n + - Units: Degrees \n + - Range: -90.0 to 90.0 \n + - Positive values indicate northern latitude \n + - Negative values indicate southern latitude */ + + /* Mandatory */ + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum).\n + - Type: Floating point \n + - Units: Degrees \n + - Range: -180.0 to 180.0 \n + - Positive values indicate eastern longitude \n + - Negative values indicate western longitude */ + + /* Mandatory */ + /* Circular Horizontal Uncertainty */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Type: Floating point \n + - Units: Meters */ + + /* Mandatory */ + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp.\n + - Type: Unsigned integer \n + - Units: Milliseconds since Jan. 1, 1970 */ +}qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. + Location engine is off. */ + eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, + QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocEngineStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the engine state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Engine State */ + qmiLocEngineStateEnumT_v02 engineState; + /**< Location engine state. + + Valid values: \n + - 0x00000001 -- ON \n + - 0x00000002 -- OFF + */ +}qmiLocEventEngineStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. + Location fix session has ended. */ + eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, + QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixSessionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the fix session state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Session State */ + qmiLocFixSessionStateEnumT_v02 sessionState; + /**< LOC fix session state. + + Valid values: \n + - 0x00000001 -- STARTED \n + - 0x00000002 -- FINISHED + */ + + /* Optional */ + /* Session ID */ + uint8_t sessionId_valid; /**< Must be set to true if sessionId is being passed */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request. + This may not be specified for a fix session corresponding to + a network-initiated request. \n + - Type: Unsigned integer \n + - Range: 0 to 255 */ +}qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ + eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. + Stop periodic fixes request. */ + eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, + QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends a WiFi request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Request Type */ + qmiLocWifiRequestEnumT_v02 requestType; + /**< Request type as specified in qmiWifiRequestEnumT. + + Valid values: \n + - 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES \n + - 0x00000001 -- START_PERIODIC_KEEP_WARM \n + - 0x00000002 -- STOP_PERIODIC_FIXES + */ + + /* Optional */ + /* Time Between Fixes */ + uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ + uint16_t tbfInMs; + /**< Time between fixes for a periodic request.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ +}qmiLocEventWifiReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t samplesPerBatch; + /**< Specifies the number of samples per batch the GNSS location engine is to + receive. The sensor sampling frequency can be computed as follows: \n + + samplingFrequency = samplesPerBatch * batchesPerSecond \n + + samplesPerBatch must be a non-zero positive value. + */ + + uint16_t batchesPerSecond; + /**< Number of sensor-data batches the GNSS location engine is to receive + per second. The rate is specified in integral number of batches per + second (Hz). \n + + batchesPerSecond must be a non-zero positive value. + */ +}qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t injectEnable; + /**< Whether the GNSS location engine is ready to accept data from this + sensor. + + Valid values: \n + - 0x01 (TRUE) -- GNSS location engine is ready to accept sensor data \n + - 0x00 (FALSE) -- GNSS location engine is not ready to accept sensor + data + */ + + qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; + /**< Rate at which the GNSS engine would like the sensor to be sampled. \n + The rate is specified in integral number of samples per second (Hz)\n + and batches per second. + */ +}qmiLocSensorReadyStatusStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point if the GNSS location engine is + ready to accept sensor data. */ +typedef struct { + + /* Optional */ + /* Accelerometer Accept Ready */ + uint8_t accelReady_valid; /**< Must be set to true if accelReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 accelReady; + /**< \n Whether the GNSS location engine is ready to accept accelerometer + sensor data. + */ + + /* Optional */ + /* Gyrometer Accept Ready */ + uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 gyroReady; + /**< \n Whether the GNSS location engine is ready to accept gyrometer sensor + data. + */ +}qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point to inject time synchronization + data. */ +typedef struct { + + /* Mandatory */ + /* Opaque Time Sync Reference Counter */ + uint32_t refCounter; + /**< This TLV is sent to registered control points. It is sent by + the location engine when it needs to synchronize location engine and + control point (sensor processor) times. + This TLV must be echoed back in the Time Sync Inject request. \n + - Type: Unsigned integer */ +}qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to enable Stationary Position + Indicator (SPI) streaming reports. */ +typedef struct { + + /* Mandatory */ + /* Enable/Disable SPI Requests */ + uint8_t enable; + /**< Whether the client is to start or stop sending an SPI status stream.\n + - 0x01 (TRUE) -- Client is to start sending an SPI status stream\n + - 0x00 (FALSE) -- Client is to stop sending an SPI status stream */ +}qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. + Bring up the WWAN type used for AGNSS connections. */ + eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, + QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWWANTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. + Close a connection to the location server. */ + eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, + QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the client to open or close a connection + to the assisted GPS location server. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Identifies a connection across Open and Close request events. \n + - Type: Unsigned integer */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Open or close a connection to the location server. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* WWAN Type */ + qmiLocWWANTypeEnumT_v02 wwanType; + /**< Identifies the WWAN type for this request. \n + Valid values: \n + - 0x00000000 -- WWAN_TYPE_INTERNET \n + - 0x00000001 -- WWAN_TYPE_AGNSS + */ +}qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ + eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ + eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is unsupported. */ + eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ + eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ + eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. + Request failed because it timed out. */ + eQMI_LOC_TIMEOUT_V02 = 6, + QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocStatusEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * typedef struct { + * }qmiLocGetServiceRevisionReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Client can query the service revision using this message. */ +typedef struct { + + /* Mandatory */ + /* Get Revision Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Revision request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Mandatory */ + /* Interface Definition Minor Revision */ + uint32_t revision; + /**< Revision of the service. This is the minor revision of the interface that + the service implements. Minor revision updates of the service are always + backward compatible. \n + - Type: Unsigned integer */ +}qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * typedef struct { + * }qmiLocGetFixCriteriaReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the fix criteria from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Fix Criteria Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Fix Criteria request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Horizontal accuracy level. + + Valid values: \n + - 0x00000001 -- LOW: Client requires low horizontal accuracy. \n + - 0x00000002 -- MED: Client requires medium horizontal accuracy. \n + - 0x00000003 -- HIGH: Client requires high horizontal accuracy. + */ + + /* Optional */ + /* Enable/Disable Intermediate Fixes */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Intermediate Report state (ON, OFF).\n + The client must explicitly set this field to OFF to stop receiving + intermediate position reports. Intermediate position reports are + generated at \n 1 Hz and are ON by default. If intermediate reports + are turned ON, the client receives position reports even if the + accuracy criteria is not met. The status in the position report is + set to IN_PROGRESS for intermediate reports. \n + Valid values: \n + - 0x00000001 -- ON: Client is interested in receiving intermediate reports \n + - 0x00000002 -- OFF: Client is not interested in receiving intermediate reports + */ + + /* Optional */ + /* Mimimum Interval Between Fixes */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Time that must elapse before alerting the client. \n + - Type: Unsigned integer \n + - Units: Milliseconds */ +}qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. + User did not respond to notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, + QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiUserRespEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* User Response */ + qmiLocNiUserRespEnumT_v02 userResp; + /**< User accepted or denied. + + Valid values: \n + - 0x00000001 -- NOTIFY_VERIFY_ACCEPT \n + - 0x00000002 -- NOTIFY_VERIFY_DENY \n + - 0x00000003 -- NOTIFY_VERIFY_NORESP + */ + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \n + - 0x00000001 -- NO_NOTIFY_NO_VERIFY \n + - 0x00000002 -- NOTIFY_ONLY \n + - 0x00000003 -- ALLOW_NO_RESP \n + - 0x00000004 -- NOT_ALLOW_NO_RESP \n + - 0x00000005 -- PRIVACY_OVERRIDE + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; + /**< \n Optional NI VX request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; + /**< \n Optional NI service interaction payload. */ +}qmiLocNiUserRespReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* NI User Response Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the NI User Response request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocNiUserRespIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_PREDICTED_ORBITS_XTRA_V02 = 0, /**< Default is QCOM-XTRA format. */ + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPredictedOrbitsDataFormatEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Total Size */ + uint32_t totalSize; + /**< Total size of the predicted orbits data to be injected. \n + - Type: Unsigned integer \n + - Units: Bytes */ + + /* Mandatory */ + /* Total Parts */ + uint16_t totalParts; + /**< Total number of parts into which the predicted orbits data is + divided. \n + - Type: Unsigned integer */ + + /* Mandatory */ + /* Part Number */ + uint16_t partNum; + /**< Number of the current predicted orbits data part; starts at 1. \n + - Type: Unsigned integer */ + + /* Mandatory */ + /* Data */ + uint32_t partData_len; /**< Must be set to # of elements in partData */ + char partData[QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02]; + /**< Predicted orbits data. \n + - Type: Array of bytes \n + - Maximum length of the array: 1024 + */ + + /* Optional */ + /* Format Type */ + uint8_t formatType_valid; /**< Must be set to true if formatType is being passed */ + qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; + /**< Predicted orbits data format. + + Valid values: \n + - 0x00000000 -- PREDICTED_ORBITS_XTRA + */ +}qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Data Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Data Injection request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Part Number */ + uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ + uint16_t partNum; + /**< Number of the predicted orbits data part for which this indication + is sent; starts at 1. \n + - Type: Unsigned integer */ +}qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataSourceReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data source. */ +typedef struct { + + /* Mandatory */ + /* Predicted Oribits Data Source Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for a predicted orbits data source. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Allowed Sizes */ + uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataValidityReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint64_t startTimeInUTC; + /**< Predicted orbits data is valid starting from this time. \n + - Type: Unsigned integer \n + - Units: Seconds (since Jan. 1, 1970) + */ + + uint16_t durationHours; + /**< Duration from the start time for which the data is valid.\n + - Type: Unsigned integer \n + - Units: Hours + */ +}qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data validity. */ +typedef struct { + + /* Mandatory */ + /* Predicted Orbits Data Validity Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for predicted orbits data validity. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Validity Info */ + uint8_t validityInfo_valid; /**< Must be set to true if validityInfo is being passed */ + qmiLocPredictedOrbitsDataValidityStructT_v02 validityInfo; +}qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time */ + uint64_t timeUtc; + /**< UTC time since Jan. 1, 1970.\n + - Type: Unsigned integer \n + - Units: Milliseconds + */ + + /* Mandatory */ + /* Time Uncertainty */ + uint32_t timeUnc; + /**< Time uncertainty.\n + - Type: Unsigned integer \n + - Units: Milliseconds + */ +}qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Time Injection request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_UNKNOWN_V02 = 0, /**< Source is unknown. */ + eQMI_LOC_ALT_SRC_GPS_V02 = 1, /**< GPS is the source. */ + eQMI_LOC_ALT_SRC_CELL_ID_V02 = 2, /**< Cell ID provided the source. */ + eQMI_LOC_ALT_SRC_ENHANCED_CELL_ID_V02 = 3, /**< Source is enhanced cell ID. */ + eQMI_LOC_ALT_SRC_WIFI_V02 = 4, /**< WiFi is the source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ + eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ + eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. + Other sources. */ + eQMI_LOC_ALT_SRC_OTHER_V02 = 9, + QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ + eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. + Fully independent. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, + QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcLinkageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal + position coordinates only. + Altitude uncertainty applies to the position of the device + regardless of horizontal position (within the horizontal + uncertainty region, if provided). */ + eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcUncertaintyCoverageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocAltSrcEnumT_v02 source; + /**< Specifies the source of the altitude. + + Valid values: \n + - 0x00000000 -- ALT_SRC_UNKNOWN \n + - 0x00000001 -- ALT_SRC_GPS \n + - 0x00000002 -- ALT_SRC_CELL_ID \n + - 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID \n + - 0x00000004 -- ALT_SRC_WIFI \n + - 0x00000005 -- ALT_SRC_TERRESTRIAL \n + - 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID \n + - 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE \n + - 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER \n + - 0x00000009 -- ALT_SRC_OTHER + */ + + qmiLocAltSrcLinkageEnumT_v02 linkage; + /**< Specifies the dependency between the horizontal and + altitude position components. + + Valid values: \n + - 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED \n + - 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT \n + - 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG \n + - 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT + */ + + qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; + /**< Specifies the region of uncertainty. + + Valid values: \n + - 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED \n + - 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid at the + injected horizontal position coordinates only. \n + - 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to the + position of the device regardless of horizontal position + (within the horizontal uncertainty region, if provided). + */ +}qmiLocAltitudeSrcInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position Source is GNSS. */ + eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position Source is Cell ID. */ + eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position Source is Enhanced Cell ID. */ + eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position Source is WiFi. */ + eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position Source is Terrestrial. */ + eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position Source is GNSS Terrestrial Hybrid. + Other sources. */ + eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, + QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPositionSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects a position to the location engine. */ +typedef struct { + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum).\n + - Type: Floating point \n + - Units: Degrees \n + - Range: -90.0 to 90.0 \n + - Positive values indicate northern latitude \n + - Negative values indicate southern latitude + */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum).\n + - Type: Floating point \n + - Units: Degrees \n + - Range: -180.0 to 180.0 \n + - Positive values indicate eastern longitude \n + - Negative values indicate western longitude + */ + + /* Optional */ + /* Circular Horizontal Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal confidence, as defined by ETSI TS 101 109.\n + - Type: Unsigned integer \n + - Units: Percent (0 to 99) \n + - 0 -- invalid value \n + - 100 to 256 -- not used \n + - If 100 is received, reinterpret to 99 \n + This field must be specified together with horizontal uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \n + - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n + - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n + - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n + - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n + - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Type: Floating point \n + - Units: Meters; positive = height, negative = depth */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid + or altitudeWrtMeanSeaLevel is specified.\n + - Type: Floating point \n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical confidence, as defined by ETSI TS 101 109.\n + - Type: Unsigned integer \n + - Units: Percent (0-99) \n + - 0 -- invalid value\n + - 100 to 256 -- not used \n + - If 100 is received, reinterpret to 99\n + This field must be specified together with the vertical uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \n + - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n + - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n + - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n + - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n + - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + */ + + /* Optional */ + /* Altitude Source Info */ + uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ + qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; + /**< \n Specifies information regarding the altitude source. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Type: Unsigned integer \n + - Units: Milliseconds (since Jan. 1, 1970) */ + + /* Optional */ + /* Position Age */ + uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ + int32_t timestampAge; + /**< Position age, which is an estimate of how long ago this fix was made. \n + - Type: Signed integer \n + - Units: Milliseconds */ + + /* Optional */ + /* Position Source */ + uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ + qmiLocPositionSrcEnumT_v02 positionSrc; + /**< Source from where this position was obtained. + Valid values: \n + - 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS \n + - 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID \n + - 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID \n + - 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI \n + - 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL \n + - 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID \n + - 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER \n + + If altitude is specified and altitude source is not specified, the engine + assumes that altitude was obtained using the specified Position source. + If altitude and altitude source both are specified then the engine assumes + that only latitude, longitude were obtained using the specified Position + Source. + */ +}qmiLocInjectPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects a position to the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Position Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Position Injection request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocInjectPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ + eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ + eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. + Lock all position sessions. */ + eQMI_LOC_LOCK_ALL_V02 = 4, + QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocLockEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Lock Type */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + + */ +}qmiLocSetEngineLockReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Set Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Engine Lock request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetEngineLockReqMsgT is empty + * typedef struct { + * }qmiLocGetEngineLockReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Get Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Engine Lock request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Lock Type */ + uint8_t lockType_valid; /**< Must be set to true if lockType is being passed */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + */ +}qmiLocGetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* SBAS Config */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. \n + - 0x01 (TRUE) -- SBAS configuration is enabled \n + - 0x00 (FALSE) -- SBAS configuration is disabled */ +}qmiLocSetSbasConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* Set SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set SBAS Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSbasConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the SBAS configuration from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get SBAS Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* SBAS Config */ + uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. \n + - 0x01 (TRUE) -- SBAS configuration is enabled \n + - 0x00 (FALSE) -- SBAS configuration is disabled */ +}qmiLocGetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocNmeaSentenceMaskT_v02; +#define QMI_LOC_NMEA_MASK_GGA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000001) /**< Enable GGA type. */ +#define QMI_LOC_NMEA_MASK_RMC_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000002) /**< Enable RMC type. */ +#define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ +#define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ +#define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* NMEA Sentence Types */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< Bitmasks of NMEA types to enable. + + Valid bitmasks: \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG + */ +}qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* Set NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of Set NMEA Types request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * typedef struct { + * }qmiLocGetNmeaTypesReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the NMEA types from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NMEA Types request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* NMEA Sentence Types */ + uint8_t nmeaSentenceType_valid; /**< Must be set to true if nmeaSentenceType is being passed */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< NMEA types to enable. + + Valid bitmasks: \n + - 0x0000ffff -- NMEA_MASK_ALL \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG + */ +}qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Enable Low Power Mode */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Set LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Low Power Mode request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * typedef struct { + * }qmiLocGetLowPowerModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the LPM status from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get LPM request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Enable/Disable LPM */ + uint8_t lowPowerMode_valid; /**< Must be set to true if lowPowerMode is being passed */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ + eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ + eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. + Server type is custom PDE. */ + eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, + QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL address. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 256 + */ +}qmiLocSetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Set Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Server request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* Server Address Type */ + uint8_t serverAddrTypeMask_valid; /**< Must be set to true if serverAddrTypeMask is being passed */ + qmiLocServerAddrTypeMaskT_v02 serverAddrTypeMask; + /**< Type of address the client wants. If unspecified, the + indication will contain all the types of addresses + it has for the specified server type. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ +}qmiLocGetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Server request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 256 + */ +}qmiLocGetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001) /**< Mask to delete GPS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002) /**< Mask to delete GPS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004) /**< Mask to delete GPS time. */ +#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008) /**< Mask to delete almanac correlation. */ +#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010) /**< Mask to delete GLONASS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020) /**< Mask to delete GLONASS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040) /**< Mask to delete GLONASS time. */ +#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080) /**< Mask to delete GLONASS almanac correlation */ +#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100) /**< Mask to delete SBAS SVDIR */ +#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200) /**< Mask to delete SBAS SVSTEER */ +#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400) /**< Mask to delete position estimate */ +#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800) /**< Mask to delete time estimate */ +#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000) /**< Mask to delete IONO */ +#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000) /**< Mask to delete UTC estimate */ +#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000) /**< Mask to delete SV health record */ +#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000) /**< Mask to delete SADATA */ +#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000) /**< Mask to delete RTI */ +#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000) /**< Mask to delete SV_NO_EXIST */ +#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000) /**< Mask to delete frequency bias estimate */ +typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ +#define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ +#define QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000004) /**< Mask to delete cell database OTA position */ +#define QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000008) /**< Mask to delete cell database external reference position */ +#define QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000010) /**< Mask to delete cell database time tag */ +#define QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000020) /**< Mask to delete cell database cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000040) /**< Mask to delete cell database cached cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000080) /**< Mask to delete cell database last service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000100) /**< Mask to delete cell database current service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000200) /**< Mask to delete cell database neighbor information */ +typedef uint32_t qmiLocDeleteClockInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000001) /**< Mask to delete time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_FREQ_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000002) /**< Mask to delete frequency estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_WEEK_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000004) /**< Mask to delete week number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_RTC_TIME_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000008) /**< Mask to delete RTC time from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_TRANSFER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000010) /**< Mask to delete time transfer from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GPSTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000020) /**< Mask to delete GPS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLOTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000040) /**< Mask to delete GLONASS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLODAY_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000080) /**< Mask to delete GLONASS day number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO4YEAR_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000100) /**< Mask to delete GLONASS four year number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000200) /**< Mask to delete GLONASS RF GRP delay from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_DISABLE_TT_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000400) /**< Mask to delete disable TT from clock information */ +typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_EPHEMERIS_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x01) /**< Delete ephemeris for the satellite */ +#define QMI_LOC_MASK_DELETE_ALMANAC_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x02) /**< Delete almanac for the satellite */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gnssSvId; + /**< SV ID of the satellite whose data is to be deleted. \n + - Type: Unsigned integer \n + - Range: \n + - For GPS: 1 to 32 \n + - For SBAS: 33 to 64 \n + - For GLONASS: 65 to 96 */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + Valid values: \n + - 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \n + - 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \n + - 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \n + - 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \n + - 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + */ + + qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; + /**< Indicates if the ephemeris or almanac for a satellite + is to be deleted. \n + Valid values: \n + - 0x01 -- DELETE_EPHEMERIS \n + - 0x02 -- DELETE_ALMANAC + */ +}qmiLocDeleteSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete All */ + uint8_t deleteAllFlag; + /**< Whether all assistance data is to be deleted. + Valid values: \n + - 0x01 (TRUE) -- All assistance data is to be deleted; + if this flag is set, all the other information + contained in the optional fields for this + message are ignored \n + - 0x00 (FALSE) -- The optional fields in the message are to be used + to determine which data is to be deleted */ + + /* Optional */ + /* Delete SV Info */ + uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ + uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ + qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; + /**< \n List of satellites for which the assitance data is to be deleted. + */ + + /* Optional */ + /* Delete GNSS Data */ + uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ + qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; + /**< Mask for the GNSS data that is to be deleted. + Valid values: \n + - 0x00000001 -- DELETE_GPS_SVDIR \n + - 0x00000002 -- DELETE_GPS_SVSTEER \n + - 0x00000004 -- DELETE_GPS_TIME\n + - 0x00000008 -- DELETE_GPS_ALM_CORR \n + - 0x00000010 -- DELETE_GLO_SVDIR \n + - 0x00000020 -- DELETE_GLO_SVSTEER \n + - 0x00000040 -- DELETE_GLO_TIME \n + - 0x00000080 -- DELETE_GLO_ALM_CORR \n + - 0x00000100 -- DELETE_SBAS_SVDIR \n + - 0x00000200 -- DELETE_SBAS_SVSTEER \n + - 0x00000400 -- DELETE_POSITION \n + - 0x00000800 -- DELETE_TIME \n + - 0x00001000 -- DELETE_IONO \n + - 0x00002000 -- DELETE_UTC \n + - 0x00004000 -- DELETE_HEALTH \n + - 0x00008000 -- DELETE_SADATA \n + - 0x00010000 -- DELETE_RTI \n + - 0x00020000 -- DELETE_SV_NO_EXIST \n + - 0x00040000 -- DELETE_FREQ_BIAS_EST + */ + + /* Optional */ + /* Delete Cell Database */ + uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ + qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; + /**< Mask for the cell database assistance data that is to be deleted. \n + Valid values: \n + - 0x00000001 -- DELETE_CELLDB_POS \n + - 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS \n + - 0x00000004 -- DELETE_CELLDB_OTA_POS \n + - 0x00000008 -- DELETE_CELLDB_EXT_REF_POS \n + - 0x00000010 -- DELETE_CELLDB_TIMETAG \n + - 0x00000020 -- DELETE_CELLDB_CELLID \n + - 0x00000040 -- DELETE_CELLDB_CACHED_CELLID \n + - 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL \n + - 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL \n + - 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO + */ + + /* Optional */ + /* Delete Clock Info */ + uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ + qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; + /**< Mask for the clock information assistance data that is to be deleted. \n + Valid values: \n + - 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST \n + - 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST \n + - 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER \n + - 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME \n + - 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER \n + - 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST \n + - 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST \n + - 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER \n + - 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER \n + - 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY \n + - 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT + */ +}qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete Assist Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Assist Data request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Enable XTRA-T */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Set XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set XTRA-T Session Control request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * typedef struct { + * }qmiLocGetXtraTSessionControlReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the XTRA-T session control value from the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Get XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get XTRA-T Session Control request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Enable/Disable XTRA-T */ + uint8_t xtraTSessionControl_valid; /**< Must be set to true if xtraTSessionControl is being passed */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t wifiPositionTime; + /**< Common counter (typically, the number of milliseconds since bootup). + This field is only to be provided if the modem and host processors are + synchronized. \n + - Type: Unsigned integer */ +}qmiLocWifiFixTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIFIXERRORCODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_FIX_ERROR_SUCCESS_V02 = 0, /**< WiFi fix is successful. */ + eQMI_LOC_WIFI_FIX_ERROR_WIFI_NOT_AVAILABLE_V02 = 1, /**< WiFi fix failed because WiFi is not available on the device. */ + eQMI_LOC_WIFI_FIX_ERROR_NO_AP_FOUND_V02 = 2, /**< WiFi fix failed because no access points were found. */ + eQMI_LOC_WIFI_FIX_ERROR_UNAUTHORIZED_V02 = 3, /**< WiFi fix failed because the server denied access due to bad authorization + code. */ + eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ + eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. + This may be because the APs found are not in the database. + WiFi fix failed, but the cause could not be determined. */ + eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, + QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiFixErrorCodeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double lat; + /**< WiFi position latitude. \n + - Type: Floating point \n + - Units: Degrees */ + + double lon; + /**< WiFi position longitude. \n + - Type: Floating point \n + - Units: Degrees */ + + uint16_t hepe; + /**< WiFi position HEPE.\n + - Type: Unsigned integer \n + - Units: Meters */ + + uint8_t numApsUsed; + /**< Number of Access Points (AP) used to generate a fix. \n + - Type: Unsigned integer */ + + qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; + /**< WiFi position error code; set to 0 if the fix succeeds. This position + is only used by a module if the value is 0. If there was a failure, + the error code provided by the WiFi positioning system can be provided + here. + + Valid values: \n + - 0x00000000 -- ERROR_SUCCESS \n + - 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE \n + - 0x00000002 -- ERROR_NO_AP_FOUND \n + - 0x00000003 -- ERROR_UNAUTHORIZED \n + - 0x00000004 -- ERROR_SERVER_UNAVAILABLE \n + - 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED \n + - 0x00000006 -- ERROR_UNKNOWN + */ +}qmiLocWifiFixPosStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocWifiApQualifierMaskT_v02; +#define QMI_LOC_WIFI_AP_QUALIFIER_BEING_USED_V02 ((qmiLocWifiApQualifierMaskT_v02)0x01) /**< Access point is being used by the WPS. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_HIDDEN_SSID_V02 ((qmiLocWifiApQualifierMaskT_v02)0x02) /**< AP does not broadcast SSID. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_PRIVATE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x04) /**< AP has encryption turned on. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_INFRASTRUCTURE_MODE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x08) /**< AP is in infrastructure mode and not in ad-hoc/unknown mode. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t macAddr[QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02]; + /**< Associated MAC address of the AP. \n + - Type: Array of unsigned integers \n + - Address length: 6 + */ + + int32_t rssi; + /**< Receive signal strength indicator.\n + - Type: Signed integer \n + - Units: dBm (offset with +100 dB) */ + + uint16_t channel; + /**< WiFi channel on which a beacon was received. \n + - Type: Unsigned integer */ + + qmiLocWifiApQualifierMaskT_v02 apQualifier; + /**< A bitmask of Boolean qualifiers for APs. + All unused bits in this mask must be set to 0. \n + Valid values: \n + - 0x01 -- BEING_USED \n + - 0x02 -- HIDDEN_SSID \n + - 0x04 -- PRIVATE \n + - 0x08 -- INFRASTRUCTURE_MODE + */ +}qmiLocWifiApInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects the WiFi position. */ +typedef struct { + + /* Optional */ + /* WiFi Fix Time */ + uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ + qmiLocWifiFixTimeStructT_v02 wifiFixTime; + /**< \n Time of WiFi position fix. */ + + /* Optional */ + /* WiFi Position */ + uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ + qmiLocWifiFixPosStructT_v02 wifiFixPosition; + /**< \n WiFi position fix. */ + + /* Optional */ + /* WiFi Access Point Information */ + uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ + uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ + qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; + /**< \n AP scan list. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horizontalReliability_valid; /**< Must be set to true if horizontalReliability is being passed */ + qmiLocReliabilityEnumT_v02 horizontalReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \n + - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n + - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n + - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n + - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n + - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + */ +}qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects the WiFi position. */ +typedef struct { + + /* Mandatory */ + /* Inject WiFi Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject WiFi Position request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. + WiFi is not available. */ + eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, + QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Availablility of WiFi */ + qmiLocWifiStatusEnumT_v02 wifiStatus; + /**< WiFi status information. + + Valid values: \n + - 0x00000001 -- WIFI_STATUS_AVAILABLE \n + - 0x00000002 -- WIFI_STATUS_UNAVAILABLE + */ +}qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Status of Notify WiFi Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WiFi Status request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * typedef struct { + * }qmiLocGetRegisteredEventsReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the mask of the events for which a client has + registered. */ +typedef struct { + + /* Mandatory */ + /* Get Registered Events Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Registered Events request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Event Registration Mask */ + uint8_t eventRegMask_valid; /**< Must be set to true if eventRegMask is being passed */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Event registration mask. + + Valid bitmasks: \n + - 0x00000001 -- POSITION_REPORT \n + - 0x00000002 -- GNSS_SV_INFO \n + - 0x00000004 -- NMEA \n + - 0x00000008 -- NI_NOTIFY_VERIFY_REQ \n + - 0x00000010 -- INJECT_TIME_REQ \n + - 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ \n + - 0x00000040 -- INJECT_POSITION_REQ \n + - 0x00000080 -- ENGINE_STATE \n + - 0x00000100 -- FIX_SESSION_STATE \n + - 0x00000200 -- WIFI_REQ \n + - 0x00000400 -- SENSOR_STREAMING_READY_STATUS \n + - 0x00000800 -- TIME_SYNC_REQ \n + - 0x00001000 -- SET_SPI_STREAMING_REPORT \n + - 0x00002000 -- LOCATION_SERVER__CONNECTION_REQ + */ +}qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCOPERATIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ + eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ + eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ + eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. + Use cell ID. For 1x, this mode corresponds to + AFLT. */ + eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, + QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocOperationModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Operation Mode */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Preferred operation mode. + + Valid values: \n + - 0x00000001 -- OPER_MODE_DEFAULT \n + - 0x00000002 -- OPER_MODE_MSB \n + - 0x00000003 -- OPER_MODE_MSA \n + - 0x00000004 -- OPER_MODE_STANDALONE \n + - 0x00000005 -- OPER_MODE_CELL_ID + */ +}qmiLocSetOperationModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Set Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Operation Mode request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetOperationModeReqMsgT is empty + * typedef struct { + * }qmiLocGetOperationModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the current operation mode from the engine. */ +typedef struct { + + /* Mandatory */ + /* Get Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Operation Mode request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Operation Mode */ + uint8_t operationMode_valid; /**< Must be set to true if operationMode is being passed */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Current operation mode. + + Valid values: \n + - 0x00000001 -- OPER_MODE_DEFAULT \n + - 0x00000002 -- OPER_MODE_MSB \n + - 0x00000003 -- OPER_MODE_MSA \n + - 0x00000004 -- OPER_MODE_STANDALONE \n + - 0x00000005 -- OPER_MODE_CELL_ID + */ +}qmiLocGetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Stationary Status */ + uint8_t stationary; + /**< Whether the device is stationary:\n + - 0x00 (FALSE) -- Device is not stationary \n + - 0x01 (TRUE) -- Device is stationary */ + + /* Optional */ + /* Confidence */ + uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ + uint8_t confidenceStationary; + /**< Confidence in the Stationary state expressed as a percentage.\n + - Type: Unsigned integer \n + - Range: 0 to 100 */ +}qmiLocSetSpiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Status of SPI Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the SPI Status request. \n + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetSpiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint8_t qmiLocSensorDataFlagMaskT_v02; +#define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting + the sensor data. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t timeOffset; + /**< Sample time offset. This time offset must be + relative to the sensor time of the first sample.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + float xAxis; + /**< Sensor x-axis sample. \n + - Type: Floating point \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyrometer: ( (rads)/(seconds^2) ) */ + + float yAxis; + /**< Sensor y-axis sample. \n + - Type: Floating point \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyrometer: ( (rads)/(seconds^2) ) */ + + float zAxis; + /**< Sensor z-axis sample. \n + - Type: Floating point \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyrometer: ( (rads)/(seconds^2) ) */ +}qmiLoc3AxisSensorSampleStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t timeOfFirstSample; + /**< Denotes a full 32-bit time tag of the first (oldest) sample in this + message. \n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + qmiLocSensorDataFlagMaskT_v02 flags; + /**< Flags to indicate any deviation from the default measurement + assumptions. All unused bits in this field must be set to 0. + + Valid bitmasks: \n + - 0x01 -- SIGN REVERSAL + */ + + uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ + qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; + /**< Variable length array to specify sensor samples. \n + - Maximum length of the array: 50 */ +}qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< An opaque identifier that is sent in by the client that will be echoed + in the indication so the client can relate the indication to the + request. \n + - Type: Unsigned integer */ + + /* Optional */ + /* 3-Axis Accelerometer Data */ + uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; + /**< \n Accelerometer sensor samples. */ + + /* Optional */ + /* 3-Axis Gyrometer Data */ + uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; + /**< \n Gyrometer sensor samples. */ +}qmiLocInjectSensorDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Sensor Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Sensor Data request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< An opaque identifier that was sent in by the client echoed + so the client can relate the indication to the request. \n + - Type: Unsigned integer */ + + /* Optional */ + /* Accelerometer Samples Accepted */ + uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ + uint8_t threeAxisAccelSamplesAccepted; + /**< This field lets the client know how many 3-axis accelerometer samples + were accepted. */ + + /* Optional */ + /* Gyrometer Samples Accepted */ + uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ + uint8_t threeAxisGyroSamplesAccepted; + /**< This field lets the client know how many 3-axis gyrometer samples were + accepted. */ +}qmiLocInjectSensorDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Reference Time Sync Counter */ + uint32_t refCounter; + /**< Must be set to the value that was sent to the control point when the + GNSS location engine requested time sync injection. \n + - Type: Unsigned integer */ + + /* Mandatory */ + /* Sensor Receive Time */ + uint32_t sensorProcRxTime; + /**< The value of the sensor time when the control point received the + Time Sync Inject request from the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + /* Mandatory */ + /* Sensor Transmit Time */ + uint32_t sensorProcTxTime; + /**< The value of the sensor time when the control point injects this message + for use by the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ +}qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Inject Time Sync Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Time Sync Data request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle + Unknown cradle mount state */ + eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, + QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocCradleMountStateEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetCradleMountConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Cradle Mount Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Cradle Mount State */ + uint8_t cradleMountState_valid; /**< Must be set to true if cradleMountState is being passed */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \n + - 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \n + - 0x00000001 -- CRADLE_STATE_MOUNTED \n + - 0x00000002 -- CRADLE_STATE_UNKNOWN + */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence of the Cradle Mount state expressed as a percentage.\n + - Type: Unsigned integer \n + - Range: 0 to 100 */ +}qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Cradle Mount State */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \n + - 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \n + - 0x00000001 -- CRADLE_STATE_MOUNTED \n + - 0x00000002 -- CRADLE_STATE_UNKNOWN */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence in the Cradle Mount state expressed as a percentage.\n + - Type: Unsigned integer \n + - Range: 0 to 100 */ +}qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Cradle Mount Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. + Unknown external power state. */ + eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, + QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocExternalPowerConfigEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetExternalPowerConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get External Power Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* External Power State */ + uint8_t externalPowerState_valid; /**< Must be set to true if externalPowerState is being passed */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \n + - 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \n + - 0x00000001 -- EXTERNAL_POWER_CONNECTED \n + - 0x00000002 -- EXTERNAL_POWER_UNKNOWN + */ +}qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* External Power State */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \n + - 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \n + - 0x00000001 -- EXTERNAL_POWER_CONNECTED \n + - 0x00000002 -- EXTERNAL_POWER_UNKNOWN + */ +}qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set External Power Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. + PPP PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, + QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerPDNEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerPDNEnumT_v02 pdnType; + /**< PDN type of the Access Point Name (APN) profile. + + Valid values: \n + - 0x00000001 -- PDN_TYPE_IPV4 \n + - 0x00000002 -- PDN_TYPE_IPV6 \n + - 0x00000003 -- PDN_TYPE_IPV4V6 \n + - 0x00000004 -- PDN_TYPE_PPP + */ + + char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; + /**< APN name. \n + - Type: NULL-terminated string \n + - Maximum string length (including NULL terminator): 101 + */ +}qmiLocApnProfilesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. + Location server request failed. */ + eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, + QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerReqStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Connection handle that the service specified in the + Location Server Connection request event. \n + - Type: Unsigned integer */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Type of connection request service that was specified in the + Location Server Connection Request event. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* Connection Status */ + qmiLocServerReqStatusEnumT_v02 statusType; + /**< Status of the Connection request. + + Valid values: \n + - 0x00000001 -- STATUS_SUCCESS = 1 \n + - 0x00000002 -- STATUS_FAILURE = 2 + + */ + + /* Optional */ + /* APN Profile */ + uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ + qmiLocApnProfilesStructT_v02 apnProfile; + /**< \n APN profile information is present only when requestType + is OPEN and statusType is SUCCESS. */ +}qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Status of Inform Loc Server Conn Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inform Location Server Connection Status request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. + V2 VX version. */ + eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, + QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocVxVersionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. + SUPL version 2.0. */ + eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, + QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSuplVersionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. \n + - 0x01 (TRUE) -- SUPL security is enabled \n + - 0x00 (FALSE) -- SUPL security is disabled */ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \n + - 0x00000001 -- VX_VERSION_V1_ONLY \n + - 0x00000002 -- VX_VERSION_V2_ONLY + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ +}qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000001) /**< Mask for the SUPL security configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000002) /**< Mask for the VX version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000004) /**< Mask for the SUPL version configuration parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Set Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ + qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; + /**< This field is sent only if the status is not a success. And if it is + not successful, this field will identify the parameters that were not + set successfully. + + Valid bitmasks: \n + - 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \n + - 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \n + - 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + */ +}qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + + Valid bitmasks: \n + - 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \n + - 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \n + - 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + */ +}qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Get Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. \n + - 0x01 (TRUE) -- SUPL security is enabled \n + - 0x00 (FALSE) -- SUPL security is disabled */ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \n + - 0x00000001 -- VX_VERSION_V1_ONLY \n + - 0x00000002 -- VX_VERSION_V2_ONLY + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ +}qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02 = 0, /**< Sensors data should be requested whenever a position request is + received. If sensor data are injected, the positioning engine + attempts to improve the heading and positioning performance using sensors. + This is the default. + + Inertial sensors are not to be used to aid heading and position + improvement. */ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorsControlConfigSensorUseEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the sensor control configuration. */ +typedef struct { + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid heading and positioning + performance. + + Valid values:\n + - 0x00000000 -- SENSORS USE ENABLED: \n + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. \n + - 0x00000001 -- SENSORS USE DISABLED: \n + Inertial sensors are not to be used to aid in heading and + position improvement. + */ +}qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Control Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Control Configuration request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid the heading and positioning + performance. + + Valid values:\n + - 0x00000000 -- SENSORS USE ENABLED: \n + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. \n + - 0x00000001 -- SENSORS USE DISABLED: \n + Inertial sensors are not to be used to aid in the heading and + position improvement. + */ +}qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Optional */ + /* Gyro Bias Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk parameter as a positive + floating-point value. This value does not have any internal defaults. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: radians^2/second^4 + + */ +}qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Properties request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ +}qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorPropertiesReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorPropertiesReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Properties request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Gyro Bias Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk parameter as a positive + floating-point value. This value does not have any internal defaults. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: radians^2/seconds^4 + + */ +}qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. + This mode can optimize power consumption and give a + power-balanced positioning and heading enhancement using + inertial sensors + Sensors usage is to be forced ON. + This mode can be requested by the control point when + power consumption is not a restriction to the use of + inertial sensors. */ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorPerformanceControlModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Optional */ + /* Sensor Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensors data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensors control configuration. + + Valid values: \n + - 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data injection + based on internal criteria. This is the default. \n + - 0x00000001 -- FORCED: \n + The GNSS location engine must request use of sensors every time the GNSS + location engine turns on. + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data. The sensor data rate is specified in terms of the nominal + number of samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + */ + + /* Optional */ + /* Gyrometer Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data. The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + */ +}qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Performance Control Configuration request. \n + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Failed Configuration */ + uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ + qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; + /**< This field is sent only if the status is not a success. + When sent, this field identifies which configuration failed. \n + Valid bitmasks: \n + - 0x0000000000000001 -- PERFORMANCE_MODE \n + - 0x0000000000000002 -- ACCEL_SAMPLING_SPEC \n + - 0x0000000000000004 -- GYRO_SAMPLING_SPEC + */ +}qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorPerformanceControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor performance control + configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensor Performance Control Configuration request. \n + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensor data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensor control configuration. + + Valid values: \n + - 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data injection + based on internal criteria. This is the default. \n + - 0x0000001 -- FORCED: \n + The GNSS location engine must request use of the sensors every time the GNSS + location engine turns on. + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data. The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + */ + + /* Optional */ + /* Gyrometer Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data. The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + */ +}qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Inject a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate Id */ + uint8_t suplCertId; + /**< Certificate Id of the Supl Certificate + Type: Unsigned Integer + Units: Bytes + Range: 0-9 */ + + /* Mandatory */ + /* SUPL certificate Data */ + uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ + uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; + /**< The supl Certificate contents + Type: Array of bytes. + - Maximum certificate size : 2000 bytes */ +}qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Inject a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* Supl Certificate Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the inject SUPL certificate request. \n + + Valid Values: + - 0x00000000 -- SUCCESS\n + - 0x00000001 -- GENERAL_FAILURE\n + - 0x00000002 -- UNSUPPORTED\n + - 0x00000003 -- INVALID_PARAMETER\n + - 0x00000004 -- ENGINE_BUSY\n + - 0x00000005 -- PHONE_OFFLINE\n + - 0x00000006 -- LOC_TIMEOUT\n + */ +}qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Delete a SUPL certificate. */ +typedef struct { + + /* Optional */ + /* SUPL Certificate Id */ + uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ + uint8_t suplCertId; + /**< Certificate Id of the Supl Certificate to be deleted + Type: Unsigned Integer \n + Units: Bytes \n + Range: 0-9 \n + If suplCertId is not specified then + "all" supl certificates will be deleted. */ +}qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Delete a SUPL certificate. */ +typedef struct { + + /* Mandatory */ + /* SUPL certifcate Deletion Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the delete SUPL certificate request. \n + + Valid Values: + - 0x00000000 -- SUCCESS\n + - 0x00000001 -- GENERAL_FAILURE\n + - 0x00000002 -- UNSUPPORTED\n + - 0x00000003 -- INVALID_PARAMETER\n + - 0x00000004 -- ENGINE_BUSY\n + - 0x00000005 -- PHONE_OFFLINE\n + - 0x00000006 -- LOC_TIMEOUT\n + */ +}qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< This field denotes if the position engine uses the + injected position in direct position calculation. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< This field denotes if the position engine filters the + SV usage in the fix. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< This field denotes if the position engine stores assistance data + in the persistent memory. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Controls how the injected position will be used in position engine.\n + Valid values: \n + - 0x01 (TRUE) -- Use the injected position in direct position + calculation. \n + - 0x00 (FALSE) -- Do not use the injected position in direct position + calculation. \n + The default value is TRUE, the injected position is used in direct + position calculation by default. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Controls if SV usage will be filtered in a position fix. + Valid values:\n + - 0x01 (TRUE) -- Filter the usage of SV's in the fix. \n + - 0x00 (FALSE) -- Do not filter the usage of SV's in the fix. \n + The default value is FALSE, the SV usage is not filtered in the + fix by default. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Controls whether assistance data should be stored in + the persistent memory. \n + Valid values:\n + - 0x01 (TRUE) -- Store assistance data in persistent memory. \n + - 0x00 (FALSE) -- Do not store assistance data in persistent memory. \n + The default value is TRUE, the assistance data is stored in + persistent memory by default. + */ +}qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Mandatory */ + /* Set Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ + qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; + /**< This field will be sent only if the status is not a success. + Identifies the parameters that were not set successfully. + + Valid bitmasks: \n + - 0x00000001 -- INJECTED_POSITION_CONTROL \n + - 0x00000002 -- FILTER_SV_USAGE \n + - 0x00000004 -- STORE_ASSIST_DATA + */ +}qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + Valid bitmasks: \n + - 0x00000001 -- INJECTED_POSITION_CONTROL \n + - 0x00000002 -- FILTER_SV_USAGE \n + - 0x00000004 -- STORE_ASSIST_DATA + */ +}qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Get Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000005 -- PHONE_OFFLINE \n + - 0x00000006 -- LOC_TIMEOUT + */ + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Specifies if the injected position is used for direct calculation + in the position engine.\n + Valid values: \n + - 0x01 (TRUE) -- The injected position is used in direct position + calculation. \n + - 0x00 (FALSE) -- The injected position is not used direct position + calculation. \n + The default value is TRUE, the injected position is used in direct + position calculation by default. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Specifies if SV usage is filtered in a position fix. + Valid values: \n + - 0x01 (TRUE) -- SV usage is filtered in the fix. \n + - 0x00 (FALSE) -- SV usage is not filtered in the fix. \n + The default value is FALSE, the SV usage is not filtered in the + fix by default. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Specifies if assistance data is stored in the persistent memory. \n + Valid values: \n + 0x01 (TRUE) -- Assistance data is stored in persistent memory. \n + 0x00 (FALSE) -- Assistance data is not stored in persistent memory. \n + The default value is TRUE, the assistance data is stored in + persistent memory by default. + */ +}qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/*Service Message Definition*/ +/** @addtogroup loc_qmi_msg_ids + @{ + */ +#define QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02 0x0020 +#define QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02 0x0020 +#define QMI_LOC_REG_EVENTS_REQ_V02 0x0021 +#define QMI_LOC_REG_EVENTS_RESP_V02 0x0021 +#define QMI_LOC_START_REQ_V02 0x0022 +#define QMI_LOC_START_RESP_V02 0x0022 +#define QMI_LOC_STOP_REQ_V02 0x0023 +#define QMI_LOC_STOP_RESP_V02 0x0023 +#define QMI_LOC_EVENT_POSITION_REPORT_IND_V02 0x0024 +#define QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02 0x0025 +#define QMI_LOC_EVENT_NMEA_IND_V02 0x0026 +#define QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02 0x0027 +#define QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02 0x0028 +#define QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02 0x0029 +#define QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02 0x002A +#define QMI_LOC_EVENT_ENGINE_STATE_IND_V02 0x002B +#define QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02 0x002C +#define QMI_LOC_EVENT_WIFI_REQ_IND_V02 0x002D +#define QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02 0x002E +#define QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02 0x002F +#define QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02 0x0030 +#define QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 0x0031 +#define QMI_LOC_GET_SERVICE_REVISION_REQ_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_RESP_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_IND_V02 0x0032 +#define QMI_LOC_GET_FIX_CRITERIA_REQ_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_RESP_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_IND_V02 0x0033 +#define QMI_LOC_NI_USER_RESPONSE_REQ_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_RESP_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_IND_V02 0x0034 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02 0x0035 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02 0x0037 +#define QMI_LOC_INJECT_UTC_TIME_REQ_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_RESP_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_IND_V02 0x0038 +#define QMI_LOC_INJECT_POSITION_REQ_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_RESP_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_IND_V02 0x0039 +#define QMI_LOC_SET_ENGINE_LOCK_REQ_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_RESP_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_IND_V02 0x003A +#define QMI_LOC_GET_ENGINE_LOCK_REQ_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_RESP_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_IND_V02 0x003B +#define QMI_LOC_SET_SBAS_CONFIG_REQ_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_RESP_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_IND_V02 0x003C +#define QMI_LOC_GET_SBAS_CONFIG_REQ_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_RESP_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_IND_V02 0x003D +#define QMI_LOC_SET_NMEA_TYPES_REQ_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_RESP_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_IND_V02 0x003E +#define QMI_LOC_GET_NMEA_TYPES_REQ_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_RESP_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_IND_V02 0x003F +#define QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_RESP_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_IND_V02 0x0040 +#define QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_RESP_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_IND_V02 0x0041 +#define QMI_LOC_SET_SERVER_REQ_V02 0x0042 +#define QMI_LOC_SET_SERVER_RESP_V02 0x0042 +#define QMI_LOC_SET_SERVER_IND_V02 0x0042 +#define QMI_LOC_GET_SERVER_REQ_V02 0x0043 +#define QMI_LOC_GET_SERVER_RESP_V02 0x0043 +#define QMI_LOC_GET_SERVER_IND_V02 0x0043 +#define QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_RESP_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_IND_V02 0x0044 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02 0x0045 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02 0x0046 +#define QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_RESP_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_IND_V02 0x0047 +#define QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02 0x0048 +#define QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_IND_V02 0x0049 +#define QMI_LOC_SET_OPERATION_MODE_REQ_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_RESP_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_IND_V02 0x004A +#define QMI_LOC_GET_OPERATION_MODE_REQ_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_RESP_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_IND_V02 0x004B +#define QMI_LOC_SET_SPI_STATUS_REQ_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_RESP_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_IND_V02 0x004C +#define QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_RESP_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_IND_V02 0x004D +#define QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02 0x004E +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 0x004F +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02 0x0050 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02 0x0051 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02 0x0052 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 0x0053 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0054 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0055 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02 0x0056 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02 0x0057 +#define QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02 0x0058 +#define QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02 0x0059 +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005A +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005B +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02 0x005C +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02 0x005D +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005E +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F +/** + @} + */ + +/* Service Object Accessor */ +/** @addtogroup wms_qmi_accessor + @{ + */ +/** This function is used internally by the autogenerated code. Clients should use the + macro loc_get_service_object_v02( ) that takes in no arguments. */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ); + +/** This macro should be used to get the service object */ +#define loc_get_service_object_v02( ) \ + loc_get_service_object_internal_v02( \ + LOC_V02_IDL_MAJOR_VERS, LOC_V02_IDL_MINOR_VERS, \ + LOC_V02_IDL_TOOL_VERS ) +/** + @} + */ + + +#ifdef __cplusplus +} +#endif +#endif + diff --git a/loc_api/ulp/inc/ulp.h b/loc_api/ulp/inc/ulp.h new file mode 100755 index 00000000..6321bb9c --- /dev/null +++ b/loc_api/ulp/inc/ulp.h @@ -0,0 +1,76 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef ULP_H +#define ULP_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#include + +typedef int (ulp_report_position_cb) +( + void* owner, + const GpsLocation* location_report_ptr, + unsigned int ext_data_length, + unsigned char* ext_data +); + +/** Represents the standard ulp module interface. */ +typedef struct { + /** set to sizeof(ulpInterface) */ + size_t size; + + /** + * Starts the ulp module. 0: success + */ + int (*init)( void* owner, ulp_report_position_cb* cb); + + /** Starts the ulp engine. 0: success */ + int (*start_fix)( void ); + + /** Stops the ulp engine. 0: success */ + int (*stop_fix)( void ); + + /** Closes the interface */ + int (*destroy)( void ); + +} ulpInterface; + +typedef const ulpInterface* (get_ulp_interface) (void); + + +#ifdef __cplusplus +} +#endif +#endif /* ULP_H */ + diff --git a/utils/Android.mk b/utils/Android.mk new file mode 100755 index 00000000..7ce454f8 --- /dev/null +++ b/utils/Android.mk @@ -0,0 +1,45 @@ +ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) +ifneq ($(BUILD_TINY_ANDROID),true) +#Compile this library only for builds with the latest modem image + +LOCAL_PATH := $(call my-dir) + +include $(CLEAR_VARS) + +## Libs +LOCAL_SHARED_LIBRARIES := \ + libutils \ + libcutils + +LOCAL_SRC_FILES += \ + loc_log.cpp \ + loc_cfg.cpp \ + msg_q.c \ + linked_list.c + +LOCAL_CFLAGS += \ + -fno-short-enums \ + -D_ANDROID_ + +## Includes +LOCAL_C_INCLUDES:= + +LOCAL_COPY_HEADERS_TO:= gps.utils/ +LOCAL_COPY_HEADERS:= \ + loc_log.h \ + loc_cfg.h \ + log_util.h \ + linked_list.h \ + msg_q.h + +LOCAL_MODULE := libgps.utils + +LOCAL_MODULE_TAGS := optional + +LOCAL_PRELINK_MODULE := false + +LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES) +include $(BUILD_SHARED_LIBRARY) +endif # not BUILD_TINY_ANDROID +endif # BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE + diff --git a/utils/linked_list.c b/utils/linked_list.c new file mode 100755 index 00000000..16f2aa22 --- /dev/null +++ b/utils/linked_list.c @@ -0,0 +1,328 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "linked_list.h" +#include +#include + +#define LOG_TAG "LocSvc_utils_ll" +#include "log_util.h" + +#include +#include + +typedef struct list_element { + struct list_element* next; + struct list_element* prev; + void* data_ptr; + void (*dealloc_func)(void*); +}list_element; + +typedef struct list_state { + list_element* p_head; + list_element* p_tail; +} list_state; + +/* ----------------------- END INTERNAL FUNCTIONS ---------------------------------------- */ + +/*=========================================================================== + + FUNCTION: linked_list_init + + ===========================================================================*/ +linked_list_err_type linked_list_init(void** list_data) +{ + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_PARAMETER; + } + + list_state* tmp_list; + tmp_list = (list_state*)calloc(1, sizeof(list_state)); + if( tmp_list == NULL ) + { + LOC_LOGE("%s: Unable to allocate space for list!\n", __FUNCTION__); + return eLINKED_LIST_FAILURE_GENERAL; + } + + tmp_list->p_head = NULL; + tmp_list->p_tail = NULL; + + *list_data = tmp_list; + + return eLINKED_LIST_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: linked_list_destroy + + ===========================================================================*/ +linked_list_err_type linked_list_destroy(void** list_data) +{ + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_HANDLE; + } + + list_state* p_list = (list_state*)*list_data; + + linked_list_flush(p_list); + + free(*list_data); + *list_data = NULL; + + return eLINKED_LIST_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: linked_list_add + + ===========================================================================*/ +linked_list_err_type linked_list_add(void* list_data, void *data_obj, void (*dealloc)(void*)) +{ + LOC_LOGD("%s: Adding to list data_obj = 0x%08X\n", __FUNCTION__, data_obj); + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_HANDLE; + } + + if( data_obj == NULL ) + { + LOC_LOGE("%s: Invalid input parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_PARAMETER; + } + + list_state* p_list = (list_state*)list_data; + list_element* elem = (list_element*)malloc(sizeof(list_element)); + if( elem == NULL ) + { + LOC_LOGE("%s: Memory allocation failed\n", __FUNCTION__); + return eLINKED_LIST_FAILURE_GENERAL; + } + + /* Copy data to newly created element */ + elem->data_ptr = data_obj; + elem->next = NULL; + elem->prev = NULL; + elem->dealloc_func = dealloc; + + /* Replace head element */ + list_element* tmp = p_list->p_head; + p_list->p_head = elem; + /* Point next to the previous head element */ + p_list->p_head->next = tmp; + + if( tmp != NULL ) + { + tmp->prev = p_list->p_head; + } + else + { + p_list->p_tail = p_list->p_head; + } + + return eLINKED_LIST_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: linked_list_remove + + ===========================================================================*/ +linked_list_err_type linked_list_remove(void* list_data, void **data_obj) +{ + LOC_LOGD("%s: Removing from list\n", __FUNCTION__); + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_HANDLE; + } + + if( data_obj == NULL ) + { + LOC_LOGE("%s: Invalid input parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_PARAMETER; + } + + list_state* p_list = (list_state*)list_data; + if( p_list->p_tail == NULL ) + { + return eLINKED_LIST_UNAVAILABLE_RESOURCE; + } + + list_element* tmp = p_list->p_tail; + + /* Replace tail element */ + p_list->p_tail = tmp->prev; + + if( p_list->p_tail != NULL ) + { + p_list->p_tail->next = NULL; + } + else + { + p_list->p_head = p_list->p_tail; + } + + /* Copy data to output param */ + *data_obj = tmp->data_ptr; + + /* Free allocated list element */ + free(tmp); + + return eLINKED_LIST_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: linked_list_empty + + ===========================================================================*/ +int linked_list_empty(void* list_data) +{ + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return (int)eLINKED_LIST_INVALID_HANDLE; + } + else + { + list_state* p_list = (list_state*)list_data; + return p_list->p_head == NULL ? 1 : 0; + } +} + +/*=========================================================================== + + FUNCTION: linked_list_flush + + ===========================================================================*/ +linked_list_err_type linked_list_flush(void* list_data) +{ + if( list_data == NULL ) + { + LOC_LOGE("%s: Invalid list parameter!\n", __FUNCTION__); + return eLINKED_LIST_INVALID_HANDLE; + } + + list_state* p_list = (list_state*)list_data; + + /* Remove all dynamically allocated elements */ + while( p_list->p_head != NULL ) + { + list_element* tmp = p_list->p_head->next; + + /* Free data pointer if told to do so. */ + if( p_list->p_head->dealloc_func != NULL ) + { + p_list->p_head->dealloc_func(p_list->p_head->data_ptr); + } + + /* Free list element */ + free(p_list->p_head); + + p_list->p_head = tmp; + } + + p_list->p_tail = NULL; + + return eLINKED_LIST_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: linked_list_search + + ===========================================================================*/ +linked_list_err_type linked_list_search(void* list_data, void **data_p, + bool (*equal)(void* data_0, void* data), + void* data_0, bool rm_if_found) +{ + LOC_LOGD("%s: Search the list\n", __FUNCTION__); + if( list_data == NULL || NULL == equal ) + { + LOC_LOGE("%s: Invalid list parameter! list_data %p equal %p\n", + __FUNCTION__, list_data, equal); + return eLINKED_LIST_INVALID_HANDLE; + } + + list_state* p_list = (list_state*)list_data; + if( p_list->p_tail == NULL ) + { + return eLINKED_LIST_UNAVAILABLE_RESOURCE; + } + + list_element* tmp = p_list->p_head; + + if (NULL != data_p) { + *data_p = NULL; + } + + while (NULL != tmp) { + if ((*equal)(data_0, tmp->data_ptr)) { + if (NULL != data_p) { + *data_p = tmp->data_ptr; + } + + if (rm_if_found) { + if (NULL == tmp->prev) { + p_list->p_head = tmp->next; + } else { + tmp->prev->next = tmp->next; + } + + if (NULL == tmp->next) { + p_list->p_tail = tmp->prev; + } else { + tmp->next->prev = tmp->prev; + } + + tmp->prev = tmp->next = NULL; + + // dealloc data if it is not copied out && caller + // has given us a dealloc function pointer. + if (NULL == data_p && NULL != tmp->dealloc_func) { + tmp->dealloc_func(tmp->data_ptr); + } + free(tmp); + } + + tmp = NULL; + } else { + tmp = tmp->next; + } + } + + return eLINKED_LIST_SUCCESS; +} + diff --git a/utils/linked_list.h b/utils/linked_list.h new file mode 100755 index 00000000..cfc945a7 --- /dev/null +++ b/utils/linked_list.h @@ -0,0 +1,217 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef __LINKED_LIST_H__ +#define __LINKED_LIST_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include +#include + +/** Linked List Return Codes */ +typedef enum +{ + eLINKED_LIST_SUCCESS = 0, + /**< Request was successful. */ + eLINKED_LIST_FAILURE_GENERAL = -1, + /**< Failed because of a general failure. */ + eLINKED_LIST_INVALID_PARAMETER = -2, + /**< Failed because the request contained invalid parameters. */ + eLINKED_LIST_INVALID_HANDLE = -3, + /**< Failed because an invalid handle was specified. */ + eLINKED_LIST_UNAVAILABLE_RESOURCE = -4, + /**< Failed because an there were not enough resources. */ + eLINKED_LIST_INSUFFICIENT_BUFFER = -5, + /**< Failed because an the supplied buffer was too small. */ +}linked_list_err_type; + +/*=========================================================================== +FUNCTION linked_list_init + +DESCRIPTION + Initializes internal structures for linked list. + + list_data: State of list to be initialized. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_init(void** list_data); + +/*=========================================================================== +FUNCTION linked_list_destroy + +DESCRIPTION + Destroys internal structures for linked list. + + p_list_data: State of list to be destroyed. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_destroy(void** list_data); + +/*=========================================================================== +FUNCTION linked_list_add + +DESCRIPTION + Adds an element to the head of the linked list. The passed in data pointer + is not modified or freed. Passed in data_obj is expected to live throughout + the use of the linked_list (i.e. data is not allocated internally) + + p_list_data: List to add data to the head of. + data_obj: Pointer to data to add into list + dealloc: Function used to deallocate memory for this element. Pass NULL + if you do not want data deallocated during a flush operation + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_add(void* list_data, void *data_obj, void (*dealloc)(void*)); + +/*=========================================================================== +FUNCTION linked_list_remove + +DESCRIPTION + Retrieves data from the list tail. data_obj is the tail element from the list + passed in by linked_list_add. + + p_list_data: List to remove the tail from. + data_obj: Pointer to data removed from list + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_remove(void* list_data, void **data_obj); + +/*=========================================================================== +FUNCTION linked_list_empty + +DESCRIPTION + Tells whether the list currently contains any elements + + p_list_data: List to check if empty. + +DEPENDENCIES + N/A + +RETURN VALUE + 0/FALSE : List contains elements + 1/TRUE : List is Empty + Otherwise look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +int linked_list_empty(void* list_data); + +/*=========================================================================== +FUNCTION linked_list_flush + +DESCRIPTION + Removes all elements from the list and deallocates them using the provided + dealloc function while adding elements. + + p_list_data: List to remove all elements from. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_flush(void* list_data); + +/*=========================================================================== +FUNCTION linked_list_search + +DESCRIPTION + Searches for an element in the linked list. + + p_list_data: List handle. + data_p: to be stored with the data found; NUll if no match. + if data_p passed in as NULL, then no write to it. + equal: Function ptr takes in a list element, and returns + indication if this the one looking for. + data_0: The data being compared against. + rm_if_found: Should data be removed if found? + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +linked_list_err_type linked_list_search(void* list_data, void **data_p, + bool (*equal)(void* data_0, void* data), + void* data_0, bool rm_if_found); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __LINKED_LIST_H__ */ diff --git a/utils/loc_cfg.cpp b/utils/loc_cfg.cpp new file mode 100755 index 00000000..de960788 --- /dev/null +++ b/utils/loc_cfg.cpp @@ -0,0 +1,272 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_utils_cfg" + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/*============================================================================= + * + * GLOBAL DATA DECLARATION + * + *============================================================================*/ + +/* Parameter data */ +loc_gps_cfg_s_type gps_conf; + +/* Parameter spec table */ + +loc_param_s_type loc_parameter_table[] = +{ + {"INTERMEDIATE_POS", &gps_conf.INTERMEDIATE_POS, 'n'}, + {"ACCURACY_THRES", &gps_conf.ACCURACY_THRES, 'n'}, + {"ENABLE_WIPER", &gps_conf.ENABLE_WIPER, 'n'}, + /* DEBUG LEVELS: 0 - none, 1 - Error, 2 - Warning, 3 - Info + 4 - Debug, 5 - Verbose */ + {"DEBUG_LEVEL", &gps_conf.DEBUG_LEVEL, 'n'}, + {"SUPL_VER", &gps_conf.SUPL_VER, 'n'}, + {"CAPABILITIES", &gps_conf.CAPABILITIES, 'n'}, + {"TIMESTAMP", &gps_conf.TIMESTAMP, 'n'}, + {"GYRO_BIAS_RANDOM_WALK", &gps_conf.GYRO_BIAS_RANDOM_WALK, 'f'}, + {"SENSOR_ACCEL_BATCHES_PER_SEC", &gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, 'n'}, + {"SENSOR_ACCEL_SAMPLES_PER_BATCH", &gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, 'n'}, + {"SENSOR_GYRO_BATCHES_PER_SEC", &gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, 'n'}, + {"SENSOR_GYRO_SAMPLES_PER_BATCH", &gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, 'n'}, + {"SENSOR_CONTROL_MODE", &gps_conf.SENSOR_CONTROL_MODE, 'n'}, + {"SENSOR_USAGE", &gps_conf.SENSOR_USAGE, 'n'}, +}; + +int loc_param_num = sizeof(loc_parameter_table) / sizeof(loc_param_s_type); + +/*=========================================================================== +FUNCTION loc_default_parameters + +DESCRIPTION + Resets the parameters to default + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A +===========================================================================*/ + +static void loc_default_parameters() +{ + /* defaults */ + gps_conf.INTERMEDIATE_POS = 0; + gps_conf.ACCURACY_THRES = 0; + gps_conf.ENABLE_WIPER = 0; + gps_conf.DEBUG_LEVEL = 3; /* debug level */ + gps_conf.SUPL_VER = 0x10000; + gps_conf.CAPABILITIES = 0x7; + gps_conf.TIMESTAMP = 0; + + gps_conf.GYRO_BIAS_RANDOM_WALK = 0; + + gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC = 2; + gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH = 5; + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC = 2; + gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH = 5; + gps_conf.SENSOR_CONTROL_MODE = 0; /* AUTO */ + gps_conf.SENSOR_USAGE = 0; /* Enabled */ + + /* Value MUST be set by OEMs in configuration for sensor-assisted + navigation to work. There is NO default value */ + gps_conf.GYRO_BIAS_RANDOM_WALK_VALID = 0; + + /* reset logging mechanism */ + loc_logger_init(gps_conf.DEBUG_LEVEL, 0); +} + +/*=========================================================================== +FUNCTION trim_space + +DESCRIPTION + Removes leading and trailing spaces of the string + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A +===========================================================================*/ +void trim_space(char *org_string) +{ + char *scan_ptr, *write_ptr; + char *first_nonspace = NULL, *last_nonspace = NULL; + + scan_ptr = write_ptr = org_string; + + while (*scan_ptr) + { + if ( !isspace(*scan_ptr) && first_nonspace == NULL) + { + first_nonspace = scan_ptr; + } + + if (first_nonspace != NULL) + { + *(write_ptr++) = *scan_ptr; + if ( !isspace(*scan_ptr)) + { + last_nonspace = write_ptr; + } + } + + scan_ptr++; + } + + if (last_nonspace) { *last_nonspace = '\0'; } +} + +/*=========================================================================== +FUNCTION loc_read_gps_conf + +DESCRIPTION + Reads the gps.conf file and sets global parameter data + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A +===========================================================================*/ +void loc_read_gps_conf(void) +{ + FILE *gps_conf_fp = NULL; + char input_buf[LOC_MAX_PARAM_LINE]; /* declare a char array */ + char *lasts; + char *param_name, *param_str_value; + int param_int_value = 0; + double param_double_value = 0; + int i; + + loc_default_parameters(); + + if((gps_conf_fp = fopen(GPS_CONF_FILE, "r")) != NULL) + { + LOC_LOGD("%s: using %s", __FUNCTION__, GPS_CONF_FILE); + } + else + { + LOC_LOGW("%s: no %s file, using defaults", __FUNCTION__, GPS_CONF_FILE); + return; /* no parameter file */ + } + + while(fgets(input_buf, LOC_MAX_PARAM_LINE, gps_conf_fp) != NULL) + { + /* Separate variable and value */ + param_name = strtok_r(input_buf, "=", &lasts); + if (param_name == NULL) continue; /* skip lines that do not contain "=" */ + param_str_value = strtok_r(NULL, "=", &lasts); + if (param_str_value == NULL) continue; /* skip lines that do not contain two operands */ + + /* Trim leading and trailing spaces */ + trim_space(param_name); + trim_space(param_str_value); + + // printf("*(%s) = (%s)\n", param_name, param_str_value); + + /* Parse numerical value */ + if (param_str_value[0] == '0' && tolower(param_str_value[1]) == 'x') + { + /* hex */ + param_int_value = (int) strtol(¶m_str_value[2], (char**) NULL, 16); + } + else { + param_double_value = (double) atof(param_str_value); /* float */ + param_int_value = atoi(param_str_value); /* dec */ + } + + if (strcmp("GYRO_BIAS_RANDOM_WALK", param_name) == 0) + { + gps_conf.GYRO_BIAS_RANDOM_WALK_VALID = 1; + } + + for(i = 0; i < loc_param_num; i++) + { + if (strcmp(loc_parameter_table[i].param_name, param_name) == 0 && + loc_parameter_table[i].param_ptr) + { + switch (loc_parameter_table[i].param_type) + { + case 's': + if (strcmp(param_str_value, "NULL") == 0) + { + *((char*)loc_parameter_table[i].param_ptr) = '\0'; + } + else { + strlcpy((char*) loc_parameter_table[i].param_ptr, + param_str_value, + LOC_MAX_PARAM_STRING + 1); + } + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %s", __FUNCTION__, param_name, (char*)loc_parameter_table[i].param_ptr); + break; + case 'n': + *((int *)loc_parameter_table[i].param_ptr) = param_int_value; + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %d", __FUNCTION__, param_name, param_int_value); + break; + case 'f': + *((double *)loc_parameter_table[i].param_ptr) = param_double_value; + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %f", __FUNCTION__, param_name, param_double_value); + break; + default: + LOC_LOGE("%s: PARAM %s parameter type must be n or n", __FUNCTION__, param_name); + } + } + } + } + + fclose(gps_conf_fp); + + /* Initialize logging mechanism with parsed data */ + loc_logger_init(gps_conf.DEBUG_LEVEL, gps_conf.TIMESTAMP); +} diff --git a/utils/loc_cfg.h b/utils/loc_cfg.h new file mode 100755 index 00000000..ffeb83c4 --- /dev/null +++ b/utils/loc_cfg.h @@ -0,0 +1,98 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_CFG_H +#define LOC_CFG_H + +#define LOC_MAX_PARAM_NAME 36 +#define LOC_MAX_PARAM_STRING 80 +#define LOC_MAX_PARAM_LINE 80 + +// Don't want to overwrite the pre-def'ed value +#ifndef GPS_CONF_FILE +#define GPS_CONF_FILE "/etc/gps.conf" //??? platform independent +#endif + +/*============================================================================= + * + * MODULE TYPE DECLARATION + * + *============================================================================*/ +typedef struct +{ + char param_name[LOC_MAX_PARAM_NAME]; + void *param_ptr; + char param_type; /* 'n' for number; 's' for string */ +} loc_param_s_type; + +/* GPS.conf support */ +typedef struct loc_gps_cfg_s +{ + unsigned long INTERMEDIATE_POS; + unsigned long ACCURACY_THRES; + unsigned long ENABLE_WIPER; + unsigned long DEBUG_LEVEL; + unsigned long SUPL_VER; + unsigned long CAPABILITIES; + unsigned long TIMESTAMP; + unsigned long GYRO_BIAS_RANDOM_WALK_VALID; + double GYRO_BIAS_RANDOM_WALK; + unsigned long SENSOR_ACCEL_BATCHES_PER_SEC; + unsigned long SENSOR_ACCEL_SAMPLES_PER_BATCH; + unsigned long SENSOR_GYRO_BATCHES_PER_SEC; + unsigned long SENSOR_GYRO_SAMPLES_PER_BATCH; + unsigned long SENSOR_CONTROL_MODE; + unsigned long SENSOR_USAGE; + // char string_val[LOC_MAX_PARAM_STRING + 1]; /* An example string value */ +} loc_gps_cfg_s_type; + +/*============================================================================= + * + * MODULE EXTERNAL DATA + * + *============================================================================*/ + +#ifdef __cplusplus +extern "C" { +#endif + +extern loc_gps_cfg_s_type gps_conf; + +/*============================================================================= + * + * MODULE EXPORTED FUNCTIONS + * + *============================================================================*/ +extern void loc_read_gps_conf(void); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_CFG_H */ diff --git a/utils/loc_log.cpp b/utils/loc_log.cpp new file mode 100755 index 00000000..e4fb76c4 --- /dev/null +++ b/utils/loc_log.cpp @@ -0,0 +1,183 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 + +#include +#include +#include +#include "loc_log.h" +#include "msg_q.h" + +#include "log_util.h" + +// Logging Improvements +const char *loc_logger_boolStr[]={"False","True"}; +const char VOID_RET[] = "None"; +const char FROM_AFW[] = "===>"; +const char TO_MODEM[] = "--->"; +const char FROM_MODEM[] = "<---"; +const char TO_AFW[] = "<==="; +const char EXIT_TAG[] = "Exiting"; +const char ENTRY_TAG[] = "Entering"; + +/* Logging Mechanism */ +loc_logger_s_type loc_logger; + +/* Get names from value */ +const char* loc_get_name_from_mask(loc_name_val_s_type table[], int table_size, long mask) +{ + int i; + for (i = 0; i < table_size; i++) + { + if (table[i].val & (long) mask) + { + return table[i].name; + } + } + return UNKNOWN_STR; +} + +/* Get names from value */ +const char* loc_get_name_from_val(loc_name_val_s_type table[], int table_size, long value) +{ + int i; + for (i = 0; i < table_size; i++) + { + if (table[i].val == (long) value) + { + return table[i].name; + } + } + return UNKNOWN_STR; +} + +static loc_name_val_s_type loc_msg_q_status[] = +{ + NAME_VAL( eMSG_Q_SUCCESS ), + NAME_VAL( eMSG_Q_FAILURE_GENERAL ), + NAME_VAL( eMSG_Q_INVALID_PARAMETER ), + NAME_VAL( eMSG_Q_INVALID_HANDLE ), + NAME_VAL( eMSG_Q_UNAVAILABLE_RESOURCE ), + NAME_VAL( eMSG_Q_INSUFFICIENT_BUFFER ) +}; +static int loc_msg_q_status_num = sizeof(loc_msg_q_status) / sizeof(loc_name_val_s_type); + +/* Find msg_q status name */ +const char* loc_get_msg_q_status(int status) +{ + return loc_get_name_from_val(loc_msg_q_status, loc_msg_q_status_num, (long) status); +} + +const char* log_succ_fail_string(int is_succ) +{ + return is_succ? "successful" : "failed"; +} + + +/*=========================================================================== + +FUNCTION loc_get_time + +DESCRIPTION + Logs a callback event header. + The pointer time_string should point to a buffer of at least 13 bytes: + + XX:XX:XX.000\0 + +RETURN VALUE + The time string + +===========================================================================*/ +char *loc_get_time(char *time_string, unsigned long buf_size) +{ + struct timeval now; /* sec and usec */ + struct tm now_tm; /* broken-down time */ + char hms_string[80]; /* HH:MM:SS */ + + gettimeofday(&now, NULL); + localtime_r(&now.tv_sec, &now_tm); + + strftime(hms_string, sizeof hms_string, "%H:%M:%S", &now_tm); + snprintf(time_string, buf_size, "%s.%03d", hms_string, (int) (now.tv_usec / 1000)); + + return time_string; +} + + +/*=========================================================================== +FUNCTION loc_logger_init + +DESCRIPTION + Initializes the state of DEBUG_LEVEL and TIMESTAMP + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A +===========================================================================*/ +void loc_logger_init(unsigned long debug, unsigned long timestamp) +{ + loc_logger.DEBUG_LEVEL = debug; + loc_logger.TIMESTAMP = timestamp; +} + + +/*=========================================================================== +FUNCTION get_timestamp + +DESCRIPTION + Generates a timestamp using the current system time + +DEPENDENCIES + N/A + +RETURN VALUE + Char pointer to the parameter str + +SIDE EFFECTS + N/A +===========================================================================*/ +char * get_timestamp(char *str, unsigned long buf_size) +{ + struct timeval tv; + struct timezone tz; + int hh, mm, ss; + gettimeofday(&tv, &tz); + hh = tv.tv_sec/3600%24; + mm = (tv.tv_sec%3600)/60; + ss = tv.tv_sec%60; + snprintf(str, buf_size, "%02d:%02d:%02d.%06ld", hh, mm, ss, tv.tv_usec); + return str; +} + diff --git a/utils/loc_log.h b/utils/loc_log.h new file mode 100755 index 00000000..8b071a48 --- /dev/null +++ b/utils/loc_log.h @@ -0,0 +1,66 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_LOG_H +#define LOC_LOG_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +#include + +typedef struct +{ + char name[128]; + long val; +} loc_name_val_s_type; + +#define NAME_VAL(x) {"" #x "", x } + +#define UNKNOWN_STR "UNKNOWN" + +#define CHECK_MASK(type, value, mask_var, mask) \ + ((mask_var & mask) ? (type) value : (type) (-1)) + +/* Get names from value */ +const char* loc_get_name_from_mask(loc_name_val_s_type table[], int table_size, long mask); +const char* loc_get_name_from_val(loc_name_val_s_type table[], int table_size, long value); +const char* loc_get_msg_q_status(int status); + +extern const char* log_succ_fail_string(int is_succ); + +extern char *loc_get_time(char *time_string, unsigned long buf_size); + +#ifdef __cplusplus +} +#endif + +#endif /* LOC_LOG_H */ diff --git a/utils/log_util.h b/utils/log_util.h new file mode 100755 index 00000000..15d0b892 --- /dev/null +++ b/utils/log_util.h @@ -0,0 +1,151 @@ +/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef __LOG_UTIL_H__ +#define __LOG_UTIL_H__ + +#ifdef __cplusplus +extern "C" +{ +#endif +/*============================================================================= + * + * LOC LOGGER TYPE DECLARATION + * + *============================================================================*/ +/* LOC LOGGER */ +typedef struct loc_logger_s +{ + unsigned long DEBUG_LEVEL; + unsigned long TIMESTAMP; +} loc_logger_s_type; + +/*============================================================================= + * + * EXTERNAL DATA + * + *============================================================================*/ +extern loc_logger_s_type loc_logger; + +// Logging Improvements +extern const char *loc_logger_boolStr[]; + +extern const char *boolStr[]; +extern const char VOID_RET[]; +extern const char FROM_AFW[]; +extern const char TO_MODEM[]; +extern const char FROM_MODEM[]; +extern const char TO_AFW[]; +extern const char EXIT_TAG[]; +extern const char ENTRY_TAG[]; +/*============================================================================= + * + * MODULE EXPORTED FUNCTIONS + * + *============================================================================*/ +extern void loc_logger_init(unsigned long debug, unsigned long timestamp); +extern char* get_timestamp(char* str, unsigned long buf_size); + + +#include + +#ifndef DEBUG_DMN_LOC_API + +/* LOGGING MACROS */ +#define LOC_LOGE(...) ALOGE("E/"__VA_ARGS__) + +#define LOC_LOGW(...) \ +if (loc_logger.DEBUG_LEVEL >= 2) { ALOGE("W/"__VA_ARGS__); } \ +else if (loc_logger.DEBUG_LEVEL <= 0) { ALOGW("W/"__VA_ARGS__); } + +#define LOC_LOGI(...) \ +if (loc_logger.DEBUG_LEVEL >= 3) { ALOGE("I/"__VA_ARGS__); } \ +else if (loc_logger.DEBUG_LEVEL <= 0) { ALOGI("W/"__VA_ARGS__); } + +#define LOC_LOGD(...) \ +if (loc_logger.DEBUG_LEVEL >= 4) { ALOGE("D/"__VA_ARGS__); } \ +else if (loc_logger.DEBUG_LEVEL <= 0) { ALOGD("W/"__VA_ARGS__); } + +#define LOC_LOGV(...) \ +if (loc_logger.DEBUG_LEVEL >= 5) { ALOGE("V/"__VA_ARGS__); } \ +else if (loc_logger.DEBUG_LEVEL <= 0) { ALOGV("W/"__VA_ARGS__); } + +#else /* DEBUG_DMN_LOC_API */ + +#define LOC_LOGE(...) ALOGE("E/"__VA_ARGS__) + +#define LOC_LOGW(...) ALOGW("W/"__VA_ARGS__) + +#define LOC_LOGI(...) ALOGI("I/"__VA_ARGS__) + +#define LOC_LOGD(...) ALOGD("D/"__VA_ARGS__) + +#define LOC_LOGV(...) ALOGV("V/"__VA_ARGS__) + +#endif /* DEBUG_DMN_LOC_API */ + +/*============================================================================= + * + * LOGGING IMPROVEMENT MACROS + * + *============================================================================*/ +#define LOG_(LOC_LOG, ID, WHAT, SPEC, VAL) \ + do { \ + if (loc_logger.TIMESTAMP) { \ + char ts[32]; \ + LOC_LOG("[%s] %s %s line %d " #SPEC, \ + get_timestamp(ts, sizeof(ts)), ID, WHAT, __LINE__, VAL); \ + } else { \ + LOC_LOG("%s %s line %d " #SPEC, \ + ID, WHAT, __LINE__, VAL); \ + } \ + } while(0) + + +#define LOG_I(ID, WHAT, SPEC, VAL) LOG_(LOC_LOGI, ID, WHAT, SPEC, VAL) +#define LOG_V(ID, WHAT, SPEC, VAL) LOG_(LOC_LOGV, ID, WHAT, SPEC, VAL) + +#define ENTRY_LOG() LOG_V(ENTRY_TAG, __func__, %s, "") +#define EXIT_LOG(SPEC, VAL) LOG_V(EXIT_TAG, __func__, SPEC, VAL) + + +// Used for logging callflow from Android Framework +#define ENTRY_LOG_CALLFLOW() LOG_I(FROM_AFW, __func__, %s, "") +// Used for logging callflow to Modem +#define EXIT_LOG_CALLFLOW(SPEC, VAL) LOG_I(TO_MODEM, __func__, SPEC, VAL) +// Used for logging callflow from Modem(TO_MODEM, __func__, %s, "") +#define MODEM_LOG_CALLFLOW(SPEC, VAL) LOG_I(FROM_MODEM, __func__, SPEC, VAL) +// Used for logging callflow to Android Framework +#define CALLBACK_LOG_CALLFLOW(CB, SPEC, VAL) LOG_I(TO_AFW, CB, SPEC, VAL) + +#ifdef __cplusplus +} +#endif + +#endif // __LOG_UTIL_H__ diff --git a/utils/msg_q.c b/utils/msg_q.c new file mode 100755 index 00000000..252921ef --- /dev/null +++ b/utils/msg_q.c @@ -0,0 +1,322 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "msg_q.h" + +#define LOG_TAG "LocSvc_utils_q" +#include "log_util.h" + +#include "linked_list.h" +#include +#include +#include + +typedef struct msg_q { + void* msg_list; /* Linked list to store information */ + pthread_cond_t list_cond; /* Condition variable for waiting on msg queue */ + pthread_mutex_t list_mutex; /* Mutex for exclusive access to message queue */ + int unblocked; /* Has this message queue been unblocked? */ +} msg_q; + +/*=========================================================================== +FUNCTION convert_linked_list_err_type + +DESCRIPTION + Converts from one set of enum values to another. + + linked_list_val: Value to convert to msg_q_enum_type + +DEPENDENCIES + N/A + +RETURN VALUE + Corresponding linked_list_enum_type in msg_q_enum_type + +SIDE EFFECTS + N/A + +===========================================================================*/ +static msq_q_err_type convert_linked_list_err_type(linked_list_err_type linked_list_val) +{ + switch( linked_list_val ) + { + case eLINKED_LIST_SUCCESS: + return eMSG_Q_SUCCESS; + case eLINKED_LIST_INVALID_PARAMETER: + return eMSG_Q_INVALID_PARAMETER; + case eLINKED_LIST_INVALID_HANDLE: + return eMSG_Q_INVALID_HANDLE; + case eLINKED_LIST_UNAVAILABLE_RESOURCE: + return eMSG_Q_UNAVAILABLE_RESOURCE; + case eLINKED_LIST_INSUFFICIENT_BUFFER: + return eMSG_Q_INSUFFICIENT_BUFFER; + + case eLINKED_LIST_FAILURE_GENERAL: + default: + return eMSG_Q_FAILURE_GENERAL; + } +} + +/* ----------------------- END INTERNAL FUNCTIONS ---------------------------------------- */ + +/*=========================================================================== + + FUNCTION: msg_q_init + + ===========================================================================*/ +msq_q_err_type msg_q_init(void** msg_q_data) +{ + if( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_PARAMETER; + } + + msg_q* tmp_msg_q; + tmp_msg_q = (msg_q*)calloc(1, sizeof(msg_q)); + if( tmp_msg_q == NULL ) + { + LOC_LOGE("%s: Unable to allocate space for message queue!\n", __FUNCTION__); + return eMSG_Q_FAILURE_GENERAL; + } + + if( linked_list_init(&tmp_msg_q->msg_list) != 0 ) + { + LOC_LOGE("%s: Unable to initialize storage list!\n", __FUNCTION__); + free(tmp_msg_q); + return eMSG_Q_FAILURE_GENERAL; + } + + if( pthread_mutex_init(&tmp_msg_q->list_mutex, NULL) != 0 ) + { + LOC_LOGE("%s: Unable to initialize list mutex!\n", __FUNCTION__); + linked_list_destroy(&tmp_msg_q->msg_list); + free(tmp_msg_q); + return eMSG_Q_FAILURE_GENERAL; + } + + if( pthread_cond_init(&tmp_msg_q->list_cond, NULL) != 0 ) + { + LOC_LOGE("%s: Unable to initialize msg q cond var!\n", __FUNCTION__); + linked_list_destroy(&tmp_msg_q->msg_list); + pthread_mutex_destroy(&tmp_msg_q->list_mutex); + free(tmp_msg_q); + return eMSG_Q_FAILURE_GENERAL; + } + + tmp_msg_q->unblocked = 0; + + *msg_q_data = tmp_msg_q; + + return eMSG_Q_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: msg_q_destroy + + ===========================================================================*/ +msq_q_err_type msg_q_destroy(void** msg_q_data) +{ + if( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_HANDLE; + } + + msg_q* p_msg_q = (msg_q*)*msg_q_data; + + linked_list_destroy(&p_msg_q->msg_list); + pthread_mutex_destroy(&p_msg_q->list_mutex); + pthread_cond_destroy(&p_msg_q->list_cond); + + p_msg_q->unblocked = 0; + + free(*msg_q_data); + *msg_q_data = NULL; + + return eMSG_Q_SUCCESS; +} + +/*=========================================================================== + + FUNCTION: msg_q_snd + + ===========================================================================*/ +msq_q_err_type msg_q_snd(void* msg_q_data, void* msg_obj, void (*dealloc)(void*)) +{ + msq_q_err_type rv; + if( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_HANDLE; + } + if( msg_obj == NULL ) + { + LOC_LOGE("%s: Invalid msg_obj parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_PARAMETER; + } + + msg_q* p_msg_q = (msg_q*)msg_q_data; + + pthread_mutex_lock(&p_msg_q->list_mutex); + LOC_LOGD("%s: Sending message with handle = 0x%08X\n", __FUNCTION__, msg_obj); + + if( p_msg_q->unblocked ) + { + LOC_LOGE("%s: Message queue has been unblocked.\n", __FUNCTION__); + pthread_mutex_unlock(&p_msg_q->list_mutex); + return eMSG_Q_UNAVAILABLE_RESOURCE; + } + + rv = convert_linked_list_err_type(linked_list_add(p_msg_q->msg_list, msg_obj, dealloc)); + + /* Show data is in the message queue. */ + pthread_cond_signal(&p_msg_q->list_cond); + + pthread_mutex_unlock(&p_msg_q->list_mutex); + + LOC_LOGD("%s: Finished Sending message with handle = 0x%08X\n", __FUNCTION__, msg_obj); + + return rv; +} + +/*=========================================================================== + + FUNCTION: msg_q_rcv + + ===========================================================================*/ +msq_q_err_type msg_q_rcv(void* msg_q_data, void** msg_obj) +{ + msq_q_err_type rv; + if( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_HANDLE; + } + + if( msg_obj == NULL ) + { + LOC_LOGE("%s: Invalid msg_obj parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_PARAMETER; + } + + msg_q* p_msg_q = (msg_q*)msg_q_data; + + LOC_LOGD("%s: Waiting on message\n", __FUNCTION__); + + pthread_mutex_lock(&p_msg_q->list_mutex); + + if( p_msg_q->unblocked ) + { + LOC_LOGE("%s: Message queue has been unblocked.\n", __FUNCTION__); + pthread_mutex_unlock(&p_msg_q->list_mutex); + return eMSG_Q_UNAVAILABLE_RESOURCE; + } + + /* Wait for data in the message queue */ + while( linked_list_empty(p_msg_q->msg_list) && !p_msg_q->unblocked ) + { + pthread_cond_wait(&p_msg_q->list_cond, &p_msg_q->list_mutex); + } + + rv = convert_linked_list_err_type(linked_list_remove(p_msg_q->msg_list, msg_obj)); + + pthread_mutex_unlock(&p_msg_q->list_mutex); + + LOC_LOGD("%s: Received message %p rv = %d\n", __FUNCTION__, *msg_obj, rv); + + return rv; +} + +/*=========================================================================== + + FUNCTION: msg_q_flush + + ===========================================================================*/ +msq_q_err_type msg_q_flush(void* msg_q_data) +{ + msq_q_err_type rv; + if ( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_HANDLE; + } + + msg_q* p_msg_q = (msg_q*)msg_q_data; + + LOC_LOGD("%s: Flushing Message Queue\n", __FUNCTION__); + + pthread_mutex_lock(&p_msg_q->list_mutex); + + /* Remove all elements from the list */ + rv = convert_linked_list_err_type(linked_list_flush(p_msg_q->msg_list)); + + pthread_mutex_unlock(&p_msg_q->list_mutex); + + LOC_LOGD("%s: Message Queue flushed\n", __FUNCTION__); + + return rv; +} + +/*=========================================================================== + + FUNCTION: msg_q_unblock + + ===========================================================================*/ +msq_q_err_type msg_q_unblock(void* msg_q_data) +{ + if ( msg_q_data == NULL ) + { + LOC_LOGE("%s: Invalid msg_q_data parameter!\n", __FUNCTION__); + return eMSG_Q_INVALID_HANDLE; + } + + msg_q* p_msg_q = (msg_q*)msg_q_data; + pthread_mutex_lock(&p_msg_q->list_mutex); + + if( p_msg_q->unblocked ) + { + LOC_LOGE("%s: Message queue has been unblocked.\n", __FUNCTION__); + pthread_mutex_unlock(&p_msg_q->list_mutex); + return eMSG_Q_UNAVAILABLE_RESOURCE; + } + + LOC_LOGD("%s: Unblocking Message Queue\n", __FUNCTION__); + /* Unblocking message queue */ + p_msg_q->unblocked = 1; + + /* Allow all the waiters to wake up */ + pthread_cond_broadcast(&p_msg_q->list_cond); + + pthread_mutex_unlock(&p_msg_q->list_mutex); + + LOC_LOGD("%s: Message Queue unblocked\n", __FUNCTION__); + + return eMSG_Q_SUCCESS; +} diff --git a/utils/msg_q.h b/utils/msg_q.h new file mode 100755 index 00000000..4171540a --- /dev/null +++ b/utils/msg_q.h @@ -0,0 +1,189 @@ +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef __MSG_Q_H__ +#define __MSG_Q_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include + +/** Linked List Return Codes */ +typedef enum +{ + eMSG_Q_SUCCESS = 0, + /**< Request was successful. */ + eMSG_Q_FAILURE_GENERAL = -1, + /**< Failed because of a general failure. */ + eMSG_Q_INVALID_PARAMETER = -2, + /**< Failed because the request contained invalid parameters. */ + eMSG_Q_INVALID_HANDLE = -3, + /**< Failed because an invalid handle was specified. */ + eMSG_Q_UNAVAILABLE_RESOURCE = -4, + /**< Failed because an there were not enough resources. */ + eMSG_Q_INSUFFICIENT_BUFFER = -5, + /**< Failed because an the supplied buffer was too small. */ +}msq_q_err_type; + +/*=========================================================================== +FUNCTION msg_q_init + +DESCRIPTION + Initializes internal structures for message queue. + + msg_q_data: State of message queue to be initialized. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_init(void** msg_q_data); + +/*=========================================================================== +FUNCTION msg_q_destroy + +DESCRIPTION + Releases internal structures for message queue. + + msg_q_data: State of message queue to be released. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_destroy(void** msg_q_data); + +/*=========================================================================== +FUNCTION msg_q_snd + +DESCRIPTION + Sends data to the message queue. The passed in data pointer + is not modified or freed. Passed in msg_obj is expected to live throughout + the use of the msg_q (i.e. data is not allocated internally) + + msg_q_data: Message Queue to add the element to. + msgp: Pointer to data to add into message queue. + dealloc: Function used to deallocate memory for this element. Pass NULL + if you do not want data deallocated during a flush operation + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_snd(void* msg_q_data, void* msg_obj, void (*dealloc)(void*)); + +/*=========================================================================== +FUNCTION msg_q_rcv + +DESCRIPTION + Retrieves data from the message queue. msg_obj is the oldest message received + and pointer is simply removed from message queue. + + msg_q_data: Message Queue to copy data from into msgp. + msg_obj: Pointer to space to copy msg_q contents to. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_rcv(void* msg_q_data, void** msg_obj); + +/*=========================================================================== +FUNCTION msg_q_flush + +DESCRIPTION + Function removes all elements from the message queue. + + msg_q_data: Message Queue to remove elements from. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_flush(void* msg_q_data); + +/*=========================================================================== +FUNCTION msg_q_unblock + +DESCRIPTION + This function will stop use of the message queue. All waiters will wake up + and likely receive nothing from the queue resulting in a negative return + value. The message queue can no longer be used until it is destroyed + and initialized again after calling this function. + + msg_q_data: Message queue to unblock. + +DEPENDENCIES + N/A + +RETURN VALUE + Look at error codes above. + +SIDE EFFECTS + N/A + +===========================================================================*/ +msq_q_err_type msg_q_unblock(void* msg_q_data); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __MSG_Q_H__ */ From 3088fe911741c9bcdd50c02d299cb81a863e8a4c Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Tue, 17 Jul 2012 16:41:00 -0700 Subject: [PATCH 03/33] gps: jb porting with qcom enhanced features based from AU_LINUX_ANDROID_ICS.04.00.04.00.205 Change-Id: I0af1da1438a136e98b59110641ce5c7714da220b --- loc_api/Android.mk | 19 +- loc_api/libloc_api-rpc-50001/Android.mk | 0 .../libloc_api-rpc-glue/Android.mk | 0 .../rpc_inc/LocApiRpcAdapter.h | 15 +- .../libloc_api-rpc-glue/rpc_inc/debug.h | 6 +- .../rpc_inc/loc_api_fixup.h | 0 .../libloc_api-rpc-glue/rpc_inc/loc_api_log.h | 0 .../rpc_inc/loc_api_rpc_glue.h | 0 .../rpc_inc/loc_api_sync_call.h | 0 .../rpc_inc/loc_apicb_appinit.h | 0 .../src/LocApiRpcAdapter.cpp | 120 +- .../libloc_api-rpc-glue/src/loc_api_fixup.c | 0 .../libloc_api-rpc-glue/src/loc_api_log.c | 0 .../src/loc_api_rpc_glue.c | 28 +- .../src/loc_api_sync_call.c | 22 +- .../src/loc_apicb_appinit.c | 0 .../libloc_api-rpc-stub/Android.mk | 0 .../inc/loc_api_rpcgen_cb_rpc.h | 0 .../inc/loc_api_rpcgen_common_rpc.h | 0 .../inc/loc_api_rpcgen_rpc.h | 0 .../inc/loc_apicb_appinit.h | 0 .../src/loc_api_rpcgen_cb_svc.c | 0 .../src/loc_api_rpcgen_cb_xdr.c | 0 .../src/loc_api_rpcgen_clnt.c | 0 .../src/loc_api_rpcgen_common_xdr.c | 0 .../src/loc_api_rpcgen_xdr.c | 0 .../src/loc_apicb_appinit.c | 0 .../libloc_api-rpc-stub/xdr/loc_api.xdr | 0 .../libloc_api-rpc-stub/xdr/loc_api_cb.xdr | 0 .../xdr/loc_api_common.xdr | 0 loc_api/libloc_api-rpc/Android.mk | 0 loc_api/libloc_api-rpc/gen-1240/Makefile.xdr | 0 .../libloc_api-rpc/gen-1240/loc_api_fixup.c | 0 .../gen-1240/loc_api_rpc_glue.c | 0 loc_api/libloc_api-rpc/gen-3200/Makefile.xdr | 0 loc_api/libloc_api-rpc/gen-3200/loc_api.xdr | 0 .../libloc_api-rpc/gen-3200/loc_api_cb.xdr | 0 .../gen-3200/loc_api_common.xdr | 0 .../libloc_api-rpc/gen-3200/loc_api_fixup.c | 0 .../gen-3200/loc_api_rpc_glue.c | 0 .../libloc_api-rpc/inc-1240/loc_api_fixup.h | 0 .../inc-1240/loc_apicb_appinit.h | 0 .../libloc_api-rpc/inc-3200/loc_api_fixup.h | 0 .../inc-3200/loc_apicb_appinit.h | 0 loc_api/libloc_api-rpc/inc/debug.h | 0 loc_api/libloc_api-rpc/inc/loc_api_rpc_glue.h | 0 .../libloc_api-rpc/src/loc_apicb_appinit.c | 0 loc_api/libloc_api/Android.mk | 0 loc_api/libloc_api/loc_eng.cpp | 0 loc_api/libloc_api/loc_eng.h | 0 loc_api/libloc_api/loc_eng_ioctl.cpp | 0 loc_api/libloc_api/loc_eng_ioctl.h | 0 loc_api/libloc_api/loc_eng_ni.cpp | 0 loc_api/libloc_api/loc_eng_ni.h | 0 loc_api/libloc_api/loc_eng_xtra.cpp | 0 loc_api/libloc_api/loc_eng_xtra.h | 0 loc_api/libloc_api_50001/Android.mk | 18 +- loc_api/libloc_api_50001/LocApiAdapter.cpp | 20 +- loc_api/libloc_api_50001/LocApiAdapter.h | 40 +- loc_api/libloc_api_50001/gps.c | 0 loc_api/libloc_api_50001/loc.cpp | 381 +- loc_api/libloc_api_50001/loc.h | 3 + loc_api/libloc_api_50001/loc_eng.cpp | 785 +-- loc_api/libloc_api_50001/loc_eng.h | 88 +- loc_api/libloc_api_50001/loc_eng_agps.cpp | 123 +- loc_api/libloc_api_50001/loc_eng_agps.h | 68 +- loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp | 72 +- loc_api/libloc_api_50001/loc_eng_dmn_conn.h | 8 +- .../loc_eng_dmn_conn_glue_msg.c | 0 .../loc_eng_dmn_conn_glue_msg.h | 0 .../loc_eng_dmn_conn_glue_pipe.c | 0 .../loc_eng_dmn_conn_glue_pipe.h | 0 .../loc_eng_dmn_conn_handler.cpp | 148 +- .../loc_eng_dmn_conn_handler.h | 23 +- .../loc_eng_dmn_conn_thread_helper.c | 0 .../loc_eng_dmn_conn_thread_helper.h | 0 loc_api/libloc_api_50001/loc_eng_log.cpp | 36 +- loc_api/libloc_api_50001/loc_eng_log.h | 4 +- loc_api/libloc_api_50001/loc_eng_msg.cpp | 0 loc_api/libloc_api_50001/loc_eng_msg.h | 431 +- loc_api/libloc_api_50001/loc_eng_msg_id.h | 41 +- loc_api/libloc_api_50001/loc_eng_ni.cpp | 0 loc_api/libloc_api_50001/loc_eng_ni.h | 0 loc_api/libloc_api_50001/loc_eng_xtra.cpp | 0 loc_api/libloc_api_50001/loc_eng_xtra.h | 0 loc_api/loc_api_v02/Android.mk | 0 loc_api/loc_api_v02/LocApiV02Adapter.cpp | 362 +- loc_api/loc_api_v02/LocApiV02Adapter.h | 53 +- loc_api/loc_api_v02/loc_api_sync_req.c | 8 +- loc_api/loc_api_v02/loc_api_sync_req.h | 0 loc_api/loc_api_v02/loc_api_v02_client.c | 421 +- loc_api/loc_api_v02/loc_api_v02_client.h | 142 +- loc_api/loc_api_v02/loc_api_v02_log.c | 23 +- loc_api/loc_api_v02/loc_api_v02_log.h | 0 loc_api/loc_api_v02/loc_util_log.h | 40 +- loc_api/loc_api_v02/location_service_v02.c | 1017 +++- loc_api/loc_api_v02/location_service_v02.h | 4251 ++++++++++++----- loc_api/ulp/inc/ulp.h | 25 +- utils/Android.mk | 2 + utils/linked_list.c | 0 utils/linked_list.h | 0 utils/loc_cfg.cpp | 230 +- utils/loc_cfg.h | 42 +- utils/loc_log.cpp | 0 utils/loc_log.h | 0 utils/log_util.h | 0 utils/msg_q.c | 2 +- utils/msg_q.h | 0 108 files changed, 6524 insertions(+), 2593 deletions(-) mode change 100755 => 100644 loc_api/Android.mk mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/Android.mk mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/Android.mk mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-1240/Makefile.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-1240/loc_api_fixup.c mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/Makefile.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/loc_api.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/loc_api_cb.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/loc_api_common.xdr mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/loc_api_fixup.c mode change 100755 => 100644 loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c mode change 100755 => 100644 loc_api/libloc_api-rpc/inc-1240/loc_api_fixup.h mode change 100755 => 100644 loc_api/libloc_api-rpc/inc-1240/loc_apicb_appinit.h mode change 100755 => 100644 loc_api/libloc_api-rpc/inc-3200/loc_api_fixup.h mode change 100755 => 100644 loc_api/libloc_api-rpc/inc-3200/loc_apicb_appinit.h mode change 100755 => 100644 loc_api/libloc_api-rpc/inc/debug.h mode change 100755 => 100644 loc_api/libloc_api-rpc/inc/loc_api_rpc_glue.h mode change 100755 => 100644 loc_api/libloc_api-rpc/src/loc_apicb_appinit.c mode change 100755 => 100644 loc_api/libloc_api/Android.mk mode change 100755 => 100644 loc_api/libloc_api/loc_eng.cpp mode change 100755 => 100644 loc_api/libloc_api/loc_eng.h mode change 100755 => 100644 loc_api/libloc_api/loc_eng_ioctl.cpp mode change 100755 => 100644 loc_api/libloc_api/loc_eng_ioctl.h mode change 100755 => 100644 loc_api/libloc_api/loc_eng_ni.cpp mode change 100755 => 100644 loc_api/libloc_api/loc_eng_ni.h mode change 100755 => 100644 loc_api/libloc_api/loc_eng_xtra.cpp mode change 100755 => 100644 loc_api/libloc_api/loc_eng_xtra.h mode change 100755 => 100644 loc_api/libloc_api_50001/Android.mk mode change 100755 => 100644 loc_api/libloc_api_50001/LocApiAdapter.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/LocApiAdapter.h mode change 100755 => 100644 loc_api/libloc_api_50001/gps.c mode change 100755 => 100644 loc_api/libloc_api_50001/loc.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_agps.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_agps.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_log.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_log.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_msg.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_msg.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_msg_id.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_ni.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_ni.h mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_xtra.cpp mode change 100755 => 100644 loc_api/libloc_api_50001/loc_eng_xtra.h mode change 100755 => 100644 loc_api/loc_api_v02/Android.mk mode change 100755 => 100644 loc_api/loc_api_v02/LocApiV02Adapter.cpp mode change 100755 => 100644 loc_api/loc_api_v02/LocApiV02Adapter.h mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_sync_req.c mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_sync_req.h mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_v02_client.c mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_v02_client.h mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_v02_log.c mode change 100755 => 100644 loc_api/loc_api_v02/loc_api_v02_log.h mode change 100755 => 100644 loc_api/loc_api_v02/loc_util_log.h mode change 100755 => 100644 loc_api/loc_api_v02/location_service_v02.c mode change 100755 => 100644 loc_api/loc_api_v02/location_service_v02.h mode change 100755 => 100644 loc_api/ulp/inc/ulp.h mode change 100755 => 100644 utils/Android.mk mode change 100755 => 100644 utils/linked_list.c mode change 100755 => 100644 utils/linked_list.h mode change 100755 => 100644 utils/loc_cfg.cpp mode change 100755 => 100644 utils/loc_cfg.h mode change 100755 => 100644 utils/loc_log.cpp mode change 100755 => 100644 utils/loc_log.h mode change 100755 => 100644 utils/log_util.h mode change 100755 => 100644 utils/msg_q.c mode change 100755 => 100644 utils/msg_q.h diff --git a/loc_api/Android.mk b/loc_api/Android.mk old mode 100755 new mode 100644 index 7e09d5f9..7e1e35f8 --- a/loc_api/Android.mk +++ b/loc_api/Android.mk @@ -1,11 +1,3 @@ -# Copyright (c) 2009, QUALCOMM USA, INC. -# All rights reserved. -# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -# · Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -# · Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -# · Neither the name of the QUALCOMM USA, INC. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - ifneq ($(BOARD_VENDOR_QCOM_GPS_LOC_API_HARDWARE),) LOCAL_PATH := $(call my-dir) @@ -19,12 +11,15 @@ GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api-rpc-50001/ GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api-rpc/ GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api/ -else - -GPS_DIR_LIST += $(LOCAL_PATH)/loc_api_v02/ - endif #TARGET_NO_RPC +#add QMI libraries for QMI targets +QMI_BOARD_PLATFORM_LIST := msm8960 + +ifeq ($(call is-board-platform-in-list,$(QMI_BOARD_PLATFORM_LIST)),true) +GPS_DIR_LIST += $(LOCAL_PATH)/loc_api_v02/ +endif #is-board-platform-in-list + GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api_50001/ #call the subfolders diff --git a/loc_api/libloc_api-rpc-50001/Android.mk b/loc_api/libloc_api-rpc-50001/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h old mode 100755 new mode 100644 index 7b1f59ba..4898d7d9 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/LocApiRpcAdapter.h @@ -38,6 +38,8 @@ class LocApiRpcAdapter : public LocApiAdapter { // RPC communication establishment rpc_loc_client_handle_type client_handle; rpc_loc_event_mask_type eMask; + int dataEnableLastSet; + char apnLastSet[MAX_APN_LEN]; static const rpc_loc_event_mask_type locBits[]; static rpc_loc_event_mask_type convertMask(LOC_API_ADAPTER_EVENT_MASK_T mask); @@ -71,10 +73,11 @@ public: virtual enum loc_api_adapter_err stopFix(); virtual enum loc_api_adapter_err - setPositionMode(LocPositionMode mode, GpsPositionRecurrence recurrence, - uint32_t min_interval, uint32_t preferred_accuracy, uint32_t preferred_time); + setPositionMode(const LocPosMode *mode); + inline virtual enum loc_api_adapter_err + enableData(int enable) { return enableData(enable, false); } virtual enum loc_api_adapter_err - enableData(int enable); + enableData(int enable, boolean force); virtual enum loc_api_adapter_err setTime(GpsUtcTime time, int64_t timeReference, int uncertainty); virtual enum loc_api_adapter_err @@ -83,8 +86,10 @@ public: deleteAidingData(GpsAidingData f); virtual enum loc_api_adapter_err informNiResponse(GpsUserResponseType userResponse, const void* passThroughData); + inline virtual enum loc_api_adapter_err + setAPN(char* apn, int len) { return setAPN(apn, len, false); } virtual enum loc_api_adapter_err - setAPN(char* apn, int len); + setAPN(char* apn, int len, boolean force); virtual enum loc_api_adapter_err setServer(const char* url, int len); virtual enum loc_api_adapter_err @@ -97,6 +102,8 @@ public: atlCloseStatus(int handle, int is_succ); virtual enum loc_api_adapter_err setSUPLVersion(uint32_t version); + + virtual void setInSession(bool inSession); }; #endif //LOC_API_RPC_ADAPTER_H diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h old mode 100755 new mode 100644 index 8b20a3f5..3f00b654 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/debug.h @@ -37,7 +37,7 @@ #define PRINT(x...) do { \ fprintf(stdout, "%s(%d) ", __FUNCTION__, __LINE__); \ fprintf(stdout, ##x); \ - LOGD(x); \ + ALOGD(x); \ } while(0) #ifdef DEBUG @@ -55,14 +55,14 @@ #define E(x...) do { \ fprintf(stderr, "%s(%d) ", __FUNCTION__, __LINE__); \ fprintf(stderr, ##x); \ - LOGE(x); \ + ALOGE(x); \ } while(0) #define FAILIF(cond, msg...) do { \ if (__builtin_expect (cond, 0)) { \ fprintf(stderr, "%s:%s:(%d): ", __FILE__, __FUNCTION__, __LINE__); \ fprintf(stderr, ##msg); \ - LOGE(##msg); \ + ALOGE(##msg); \ } \ } while(0) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_fixup.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_log.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_rpc_glue.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_api_sync_call.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/rpc_inc/loc_apicb_appinit.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp old mode 100755 new mode 100644 index 48b3a0fe..843a8ae9 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -119,8 +119,10 @@ const rpc_loc_event_mask_type LocApiRpcAdapter::locBits[] = LocApiRpcAdapter::LocApiRpcAdapter(LocEng &locEng) : LocApiAdapter(locEng), client_handle(RPC_LOC_CLIENT_HANDLE_INVALID), - eMask(convertMask(locEng.eventMask)) + eMask(convertMask(locEng.eventMask)), + dataEnableLastSet(-1) { + memset(apnLastSet, 0, sizeof(apnLastSet)); loc_api_glue_init(); } @@ -298,9 +300,7 @@ LocApiRpcAdapter::stopFix() { } enum loc_api_adapter_err -LocApiRpcAdapter::setPositionMode(LocPositionMode mode, - GpsPositionRecurrence recurrence, uint32_t min_interval, - uint32_t preferred_accuracy, uint32_t preferred_time) +LocApiRpcAdapter::setPositionMode(const LocPosMode *posMode) { rpc_loc_ioctl_data_u_type ioctl_data; rpc_loc_fix_criteria_s_type *fix_criteria_ptr; @@ -308,10 +308,13 @@ LocApiRpcAdapter::setPositionMode(LocPositionMode mode, rpc_loc_operation_mode_e_type op_mode; int ret_val; - LOGD ("loc_eng_set_position mode, client = %d, interval = %d, mode = %d\n", - (int32) client_handle, min_interval, mode); + if (NULL != posMode) + fixCriteria = *posMode; - switch (mode) + ALOGD ("loc_eng_set_position mode, client = %d, interval = %d, mode = %d\n", + (int32) client_handle, fixCriteria.min_interval, fixCriteria.mode); + + switch (fixCriteria.mode) { case LOC_POSITION_MODE_MS_BASED: op_mode = RPC_LOC_OPER_MODE_MSB; @@ -339,29 +342,22 @@ LocApiRpcAdapter::setPositionMode(LocPositionMode mode, fix_criteria_ptr = &ioctl_data.rpc_loc_ioctl_data_u_type_u.fix_criteria; fix_criteria_ptr->valid_mask = RPC_LOC_FIX_CRIT_VALID_PREFERRED_OPERATION_MODE | RPC_LOC_FIX_CRIT_VALID_RECURRENCE_TYPE; - fix_criteria_ptr->min_interval = min_interval; + fix_criteria_ptr->min_interval = fixCriteria.min_interval; fix_criteria_ptr->preferred_operation_mode = op_mode; - if (min_interval > 0) { - fix_criteria_ptr->min_interval = min_interval; - fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL; - }else if(min_interval == 0) - { - /*If the framework passes in 0 transalate it into the maximum frequency we can report positions - which is 1 Hz or once very second */ - fix_criteria_ptr->min_interval = MIN_POSSIBLE_FIX_INTERVAL; - fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL; - } - if (preferred_accuracy > 0) { - fix_criteria_ptr->preferred_accuracy = preferred_accuracy; + fix_criteria_ptr->min_interval = fixCriteria.min_interval; + fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_MIN_INTERVAL; + + if (fixCriteria.preferred_accuracy > 0) { + fix_criteria_ptr->preferred_accuracy = fixCriteria.preferred_accuracy; fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_PREFERRED_ACCURACY; } - if (preferred_time > 0) { - fix_criteria_ptr->preferred_response_time = preferred_time; + if (fixCriteria.preferred_time > 0) { + fix_criteria_ptr->preferred_response_time = fixCriteria.preferred_time; fix_criteria_ptr->valid_mask |= RPC_LOC_FIX_CRIT_VALID_PREFERRED_RESPONSE_TIME; } - switch (recurrence) { + switch (fixCriteria.recurrence) { case GPS_POSITION_RECURRENCE_SINGLE: fix_criteria_ptr->recurrence_type = RPC_LOC_SINGLE_FIX; break; @@ -484,20 +480,42 @@ LocApiRpcAdapter::informNiResponse(GpsUserResponseType userResponse, } enum loc_api_adapter_err - LocApiRpcAdapter::setAPN(char* apn, int len) +LocApiRpcAdapter::setAPN(char* apn, int len, boolean force) { - rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, {0}}; - ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].srv_system_type = LOC_APN_PROFILE_SRV_SYS_MAX; - ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].pdp_type = LOC_APN_PROFILE_PDN_TYPE_IPV4; - memcpy(&(ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].apn_name), apn, len+1); + enum loc_api_adapter_err rtv = LOC_API_ADAPTER_ERR_SUCCESS; + int size = sizeof(apnLastSet); + if (force || memcmp(apnLastSet, apn, size)) { + if (len < size) { + // size will be not larger than its original value + size = len + 1; + } + memcpy(apnLastSet, apn, size); - return convertErr( - loc_eng_ioctl (client_handle, - RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, - &ioctl_data, - LOC_IOCTL_DEFAULT_TIMEOUT, - NULL) - ); + if (false == navigating) { + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, {0}}; + ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].srv_system_type = LOC_APN_PROFILE_SRV_SYS_MAX; + ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].pdp_type = LOC_APN_PROFILE_PDN_TYPE_IPV4; + memcpy(&(ioctl_data.rpc_loc_ioctl_data_u_type_u.apn_profiles[0].apn_name), apn, size); + + rtv = convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_SET_LBS_APN_PROFILE, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); + } + } + return rtv; +} + +void LocApiRpcAdapter::setInSession(bool inSession) +{ + LocApiAdapter::setInSession(inSession); + if (false == navigating) { + enableData(dataEnableLastSet, true); + setAPN(apnLastSet, sizeof(apnLastSet)-1, true); + } } enum loc_api_adapter_err @@ -567,18 +585,26 @@ LocApiRpcAdapter::setServer(unsigned int ip, int port, LocServerType type) } enum loc_api_adapter_err -LocApiRpcAdapter::enableData(int enable) +LocApiRpcAdapter::enableData(int enable, boolean force) { - rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_DATA_ENABLE, {0}}; + enum loc_api_adapter_err rtv = LOC_API_ADAPTER_ERR_SUCCESS; + if (force || dataEnableLastSet != enable) { + dataEnableLastSet = enable; - ioctl_data.rpc_loc_ioctl_data_u_type_u.data_enable = enable; - return convertErr( - loc_eng_ioctl (client_handle, - RPC_LOC_IOCTL_SET_DATA_ENABLE, - &ioctl_data, - LOC_IOCTL_DEFAULT_TIMEOUT, - NULL) - ); + if (false == navigating) { + rpc_loc_ioctl_data_u_type ioctl_data = {RPC_LOC_IOCTL_SET_DATA_ENABLE, {0}}; + + ioctl_data.rpc_loc_ioctl_data_u_type_u.data_enable = enable; + rtv = convertErr( + loc_eng_ioctl (client_handle, + RPC_LOC_IOCTL_SET_DATA_ENABLE, + &ioctl_data, + LOC_IOCTL_DEFAULT_TIMEOUT, + NULL) + ); + } + } + return rtv; } enum loc_api_adapter_err @@ -652,7 +678,9 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca location.flags |= GPS_LOCATION_HAS_ACCURACY; location.accuracy = location_report_ptr->hor_unc_circular; } - + //Mark the location source as from GNSS + location.flags |= LOCATION_HAS_SOURCE_INFO; + location.position_source = ULP_LOCATION_IS_FROM_GNSS; LOC_LOGV("reportPosition: fire callback\n"); LocApiAdapter::reportPosition(location, locEngHandle.extPosInfo((void*)location_report_ptr), diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_fixup.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_log.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c old mode 100755 new mode 100644 index 10b2d221..02eadf7f --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_rpc_glue.c @@ -62,8 +62,8 @@ /* Logging Improvement */ #include "log_util.h" -/* Uncomment to force LOGD messages */ -// #define LOGD LOGI +/* Uncomment to force ALOGD messages */ +// #define ALOGD ALOGI /*===================================================================== External declarations @@ -316,30 +316,23 @@ rpc_loc_client_handle_type loc_open ( rpc_loc_open_args args; args.event_reg_mask = event_reg_mask; - int i; + int i, j = LOC_API_CB_MAX_CLIENTS; for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) { - if (loc_glue_callback_table[i].cb_func == event_callback || - loc_glue_callback_table[i].user == userData) + if (loc_glue_callback_table[i].user == userData) { LOC_LOGW("Client already opened service (callback=%p)...\n", event_callback); break; + } else if (j == LOC_API_CB_MAX_CLIENTS && + loc_glue_callback_table[i].user == NULL) { + j = i; } } if (i == LOC_API_CB_MAX_CLIENTS) { - for (i = 0; i < LOC_API_CB_MAX_CLIENTS; i++) - { - if (loc_glue_callback_table[i].cb_func == NULL) - { - loc_glue_callback_table[i].cb_func = event_callback; - loc_glue_callback_table[i].rpc_cb = rpc_cb; - loc_glue_callback_table[i].user = userData; - break; - } - } + i = j; } if (i == LOC_API_CB_MAX_CLIENTS) @@ -348,6 +341,10 @@ rpc_loc_client_handle_type loc_open ( return RPC_LOC_CLIENT_HANDLE_INVALID; } + loc_glue_callback_table[i].cb_func = event_callback; + loc_glue_callback_table[i].rpc_cb = rpc_cb; + loc_glue_callback_table[i].user = userData; + args.event_callback = loc_glue_callback_table[i].cb_id; LOC_LOGV("cb_id=%d, func=0x%x", i, (unsigned int) event_callback); @@ -405,6 +402,7 @@ void loc_clear(rpc_loc_client_handle_type handle) { loc_glue_callback_table[i].cb_func = NULL; loc_glue_callback_table[i].rpc_cb = NULL; loc_glue_callback_table[i].handle = -1; + loc_glue_callback_table[i].user = NULL; break; } } diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c old mode 100755 new mode 100644 index e2a5786f..c488ff5d --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c @@ -195,7 +195,7 @@ void loc_api_callback_process_sync_call( { int i; - LOGV("loc_handle = 0x%lx, loc_event = 0x%lx", loc_handle, loc_event); + ALOGV("loc_handle = 0x%lx, loc_event = 0x%lx", loc_handle, loc_event); for (i = 0; i < loc_sync_data.num_of_slots; i++) { loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; @@ -211,7 +211,7 @@ void loc_api_callback_process_sync_call( slot->loc_cb_received_event_mask = loc_event; - LOGV("signal slot %d in_use %d, loc_handle 0x%lx, event_mask 0x%1x, ioctl_type %d", i, slot->in_use, slot->loc_handle, (int) slot->loc_cb_wait_event_mask, (int) slot->ioctl_type); + ALOGV("signal slot %d in_use %d, loc_handle 0x%lx, event_mask 0x%1x, ioctl_type %d", i, slot->in_use, slot->loc_handle, (int) slot->loc_cb_wait_event_mask, (int) slot->ioctl_type); pthread_cond_signal(&slot->loc_cb_arrived_cond); slot->signal_sent = 1; @@ -252,7 +252,7 @@ static int loc_lock_a_slot() loc_sync_call_slot_s_type *slot = &loc_sync_data.slots[i]; if (pthread_mutex_trylock(&slot->lock) == EBUSY) { - LOGV("trylock EBUSY : %d", i); + ALOGV("trylock EBUSY : %d", i); continue; } @@ -266,7 +266,7 @@ static int loc_lock_a_slot() */ break; } - /* LOGV("slot %d in_use = %d, not_available = %d : %d", i, slot->in_use, slot->not_available, i); */ + /* ALOGV("slot %d in_use = %d, not_available = %d : %d", i, slot->in_use, slot->not_available, i); */ pthread_mutex_unlock(&slot->lock); } @@ -417,7 +417,7 @@ static int loc_api_wait_callback( if (rc == ETIMEDOUT) { ret_val = RPC_LOC_API_TIMEOUT; /* Timed out */ - LOGE("TIMEOUT: %d", select_id); + ALOGE("TIMEOUT: %d", select_id); } else { /* Obtained the first awaited callback */ @@ -462,7 +462,7 @@ int loc_api_sync_ioctl if (select_id < 0 || select_id >= loc_sync_data.num_of_slots) { - LOGE("slot not available ioctl_type = %s", + ALOGE("slot not available ioctl_type = %s", loc_get_ioctl_type_name(ioctl_type)); return rc; } @@ -474,17 +474,17 @@ int loc_api_sync_ioctl if (rc != RPC_LOC_API_SUCCESS) { - LOGE("loc_ioctl failed select_id = %d, ioctl_type %s, returned %s", + ALOGE("loc_ioctl failed select_id = %d, ioctl_type %s, returned %s", select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); } else { - LOGV("select_id = %d, ioctl_type %d, returned RPC_LOC_API_SUCCESS", + ALOGV("select_id = %d, ioctl_type %d, returned RPC_LOC_API_SUCCESS", select_id, ioctl_type); // Wait for the callback of loc_ioctl if ((rc = loc_api_wait_callback(select_id, timeout_msec / 1000, NULL, &callback_data)) != 0) { // Callback waiting failed - LOGE("callback wait failed select_id = %d, ioctl_type %s, returned %s", + ALOGE("callback wait failed select_id = %d, ioctl_type %s, returned %s", select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); } else @@ -493,10 +493,10 @@ int loc_api_sync_ioctl if (callback_data.status != RPC_LOC_API_SUCCESS) { rc = callback_data.status; - LOGE("callback status failed select_id = %d, ioctl_type %s, returned %s", + ALOGE("callback status failed select_id = %d, ioctl_type %s, returned %s", select_id, loc_get_ioctl_type_name(ioctl_type), loc_get_ioctl_status_name(rc)); } else { - LOGV("callback status success select_id = %d, ioctl_type %d, returned %d", + ALOGV("callback status success select_id = %d, ioctl_type %d, returned %d", select_id, ioctl_type, rc); } } /* wait callback */ diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_apicb_appinit.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_cb_rpc.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_common_rpc.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_api_rpcgen_rpc.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/inc/loc_apicb_appinit.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_svc.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_cb_xdr.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_clnt.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_common_xdr.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_api_rpcgen_xdr.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/src/loc_apicb_appinit.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_cb.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-stub/xdr/loc_api_common.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/Android.mk b/loc_api/libloc_api-rpc/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr b/loc_api/libloc_api-rpc/gen-1240/Makefile.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-1240/loc_api_fixup.c b/loc_api/libloc_api-rpc/gen-1240/loc_api_fixup.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc/gen-1240/loc_api_rpc_glue.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr b/loc_api/libloc_api-rpc/gen-3200/Makefile.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api.xdr b/loc_api/libloc_api-rpc/gen-3200/loc_api.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api_cb.xdr b/loc_api/libloc_api-rpc/gen-3200/loc_api_cb.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api_common.xdr b/loc_api/libloc_api-rpc/gen-3200/loc_api_common.xdr old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api_fixup.c b/loc_api/libloc_api-rpc/gen-3200/loc_api_fixup.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c b/loc_api/libloc_api-rpc/gen-3200/loc_api_rpc_glue.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc-1240/loc_api_fixup.h b/loc_api/libloc_api-rpc/inc-1240/loc_api_fixup.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc-1240/loc_apicb_appinit.h b/loc_api/libloc_api-rpc/inc-1240/loc_apicb_appinit.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc-3200/loc_api_fixup.h b/loc_api/libloc_api-rpc/inc-3200/loc_api_fixup.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc-3200/loc_apicb_appinit.h b/loc_api/libloc_api-rpc/inc-3200/loc_apicb_appinit.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc/debug.h b/loc_api/libloc_api-rpc/inc/debug.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/inc/loc_api_rpc_glue.h b/loc_api/libloc_api-rpc/inc/loc_api_rpc_glue.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api-rpc/src/loc_apicb_appinit.c b/loc_api/libloc_api-rpc/src/loc_apicb_appinit.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/Android.mk b/loc_api/libloc_api/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng.cpp b/loc_api/libloc_api/loc_eng.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng.h b/loc_api/libloc_api/loc_eng.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_ioctl.cpp b/loc_api/libloc_api/loc_eng_ioctl.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_ioctl.h b/loc_api/libloc_api/loc_eng_ioctl.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_ni.cpp b/loc_api/libloc_api/loc_eng_ni.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_ni.h b/loc_api/libloc_api/loc_eng_ni.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_xtra.cpp b/loc_api/libloc_api/loc_eng_xtra.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api/loc_eng_xtra.h b/loc_api/libloc_api/loc_eng_xtra.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/Android.mk b/loc_api/libloc_api_50001/Android.mk old mode 100755 new mode 100644 index 0a5a0a10..4e5973d6 --- a/loc_api/libloc_api_50001/Android.mk +++ b/loc_api/libloc_api_50001/Android.mk @@ -3,6 +3,7 @@ ifneq ($(BUILD_TINY_ANDROID),true) BIT_ENABLED_BOARD_PLATFORM_LIST := msm7630_fusion BIT_ENABLED_BOARD_PLATFORM_LIST += msm8660 +BIT_ENABLED_BOARD_PLATFORM_LIST += msm8960 ifeq ($(call is-board-platform-in-list,$(BIT_ENABLED_BOARD_PLATFORM_LIST)),true) FEATURE_GNSS_BIT_API := true endif # is-board-platform-in-list @@ -57,8 +58,7 @@ LOCAL_SHARED_LIBRARIES := \ libutils \ libcutils \ libloc_adapter \ - libgps.utils \ - libdl + libgps.utils LOCAL_SRC_FILES += \ loc_eng.cpp \ @@ -78,13 +78,17 @@ LOCAL_SRC_FILES += \ loc_eng_dmn_conn_glue_msg.c \ loc_eng_dmn_conn_glue_pipe.c +# if QMI is supported then link to loc_api_v02 +ifeq ($(call is-board-platform-in-list,$(QMI_BOARD_PLATFORM_LIST)),true) +LOCAL_SHARED_LIBRARIES += libloc_api_v02 +else ## Check if RPC is not unsupported ifneq ($(TARGET_NO_RPC),true) LOCAL_SHARED_LIBRARIES += libloc_api-rpc-qc -else -LOCAL_SHARED_LIBRARIES += libloc_api_v02 endif #TARGET_NO_RPC +endif #is-board-platform-in-list + LOCAL_CFLAGS += \ -fno-short-enums \ -D_ANDROID_ @@ -109,7 +113,8 @@ LOCAL_SHARED_LIBRARIES := \ libutils \ libcutils \ libloc_eng \ - libgps.utils + libgps.utils \ + libdl LOCAL_SRC_FILES += \ loc.cpp \ @@ -121,7 +126,8 @@ LOCAL_CFLAGS += \ ## Includes LOCAL_C_INCLUDES:= \ - $(TARGET_OUT_HEADERS)/gps.utils + $(TARGET_OUT_HEADERS)/gps.utils \ + hardware/qcom/gps/loc_api/ulp/inc LOCAL_PRELINK_MODULE := false LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp old mode 100755 new mode 100644 index e631642d..b7ebc6f5 --- a/loc_api/libloc_api_50001/LocApiAdapter.cpp +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -44,11 +44,12 @@ LocEng::LocEng(void* caller, gps_acquire_wakelock acqwl, gps_release_wakelock relwl, loc_msg_sender msgSender, + loc_msg_sender msgUlpSender, loc_ext_parser posParser, loc_ext_parser svParser) : owner(caller), eventMask(emask), acquireWakelock(acqwl), - releaseWakeLock(relwl), sendMsge(msgSender), + releaseWakeLock(relwl), sendMsge(msgSender), sendUlpMsg(msgUlpSender), extPosInfo(NULL == posParser ? noProc : posParser), extSvInfo(NULL == svParser ? noProc : svParser) { @@ -56,7 +57,7 @@ LocEng::LocEng(void* caller, } LocApiAdapter::LocApiAdapter(LocEng &locEng) : - locEngHandle(locEng) + locEngHandle(locEng), fixCriteria(), navigating(false) { LOC_LOGD("LocApiAdapter created"); } @@ -119,13 +120,24 @@ void LocApiAdapter::reportPosition(GpsLocation &location, location, locationExt, status)); - locEngHandle.sendMsge(locEngHandle.owner, msg); + if (locEngHandle.sendUlpMsg) { + locEngHandle.sendUlpMsg(locEngHandle.owner, msg); + } else { + locEngHandle.sendMsge(locEngHandle.owner, msg); + } } void LocApiAdapter::reportSv(GpsSvStatus &svStatus, void* svExt) { loc_eng_msg_report_sv *msg(new loc_eng_msg_report_sv(locEngHandle.owner, svStatus, svExt)); - locEngHandle.sendMsge(locEngHandle.owner, msg); + + //We want to send SV info to ULP to help it in determining GNSS signal strength + //ULP will forward the SV reports to HAL without any modifications + if (locEngHandle.sendUlpMsg) { + locEngHandle.sendUlpMsg(locEngHandle.owner, msg); + } else { + locEngHandle.sendMsge(locEngHandle.owner, msg); + } } void LocApiAdapter::reportStatus(GpsStatusValue status) diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h old mode 100755 new mode 100644 index 033a034c..1c5e02b2 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -32,9 +32,13 @@ #include #include #include +#include #include +#include -#define MIN_POSSIBLE_FIX_INTERVAL 1000 /* msec */ +#define MAX_APN_LEN 100 +#define MAX_URL_LEN 256 +#define smaller_of(a, b) (((a) > (b)) ? (b) : (a)) enum loc_api_adapter_err { LOC_API_ADAPTER_ERR_SUCCESS = 0, @@ -85,6 +89,7 @@ struct LocEng { const gps_acquire_wakelock acquireWakelock; const gps_release_wakelock releaseWakeLock; const loc_msg_sender sendMsge; + const loc_msg_sender sendUlpMsg; const loc_ext_parser extPosInfo; const loc_ext_parser extSvInfo; @@ -93,6 +98,7 @@ struct LocEng { gps_acquire_wakelock acqwl, gps_release_wakelock relwl, loc_msg_sender msgSender, + loc_msg_sender msgUlpSender, loc_ext_parser posParser, loc_ext_parser svParser); }; @@ -100,6 +106,8 @@ struct LocEng { class LocApiAdapter { protected: const LocEng locEngHandle; + LocPosMode fixCriteria; + bool navigating; LocApiAdapter(LocEng &locEng); @@ -157,22 +165,14 @@ public: inline virtual enum loc_api_adapter_err setXtraData(char* data, int length) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} -#ifdef QCOM_FEATURE_IPV6 inline virtual enum loc_api_adapter_err atlOpenStatus(int handle, int is_succ, char* apn, AGpsBearerType bear, AGpsType agpsType) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} -#else - inline virtual enum loc_api_adapter_err - atlOpenStatus(int handle, int is_succ, char* apn, AGpsType agpsType) - {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} -#endif inline virtual enum loc_api_adapter_err atlCloseStatus(int handle, int is_succ) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err - setPositionMode(LocPositionMode mode, GpsPositionRecurrence recurrence, - uint32_t min_interval, uint32_t preferred_accuracy, - uint32_t preferred_time) + setPositionMode(const LocPosMode *posMode) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err setServer(const char* url, int len) @@ -187,16 +187,32 @@ public: inline virtual enum loc_api_adapter_err setSUPLVersion(uint32_t version) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} + inline virtual enum loc_api_adapter_err + setLPPConfig(uint32_t profile) + {LOC_LOGW("%s: default implementation invoked", __func__); + return LOC_API_ADAPTER_ERR_SUCCESS; } inline virtual enum loc_api_adapter_err setSensorControlConfig(int sensorUsage) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err - setSensorProperties(float gyroBiasVarianceRandomWalk) + setSensorProperties(bool gyroBiasVarianceRandomWalk_valid, float gyroBiasVarianceRandomWalk, + bool accelBiasVarianceRandomWalk_valid, float accelBiasVarianceRandomWalk, + bool angleBiasVarianceRandomWalk_valid, float angleBiasVarianceRandomWalk, + bool rateBiasVarianceRandomWalk_valid, float rateBiasVarianceRandomWalk, + bool velocityBiasVarianceRandomWalk_valid, float velocityBiasVarianceRandomWalk) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, - int gyroSamplesPerBatch, int gyroBatchesPerSec) + int gyroSamplesPerBatch, int gyroBatchesPerSec, int algorithmConfig) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} + inline virtual enum loc_api_adapter_err + setExtPowerConfig(int isBatteryCharging) + {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} + + inline const LocPosMode& getPositionMode() const {return fixCriteria;} + + inline bool isInSession() { return navigating; } + inline virtual void setInSession(bool inSession) { navigating = inSession; } }; LocApiAdapter* getLocApiAdapter(LocEng &locEng); diff --git a/loc_api/libloc_api_50001/gps.c b/loc_api/libloc_api_50001/gps.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp old mode 100755 new mode 100644 index 16bed3b1..c0378fdf --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011 - 2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -33,7 +33,17 @@ #include #include #include +#include +#include +#include +#include +#include +#include + +//Globals defns +static const ulpInterface * loc_eng_ulp_inf = NULL; +static const ulpInterface * loc_eng_get_ulp_inf(void); static gps_location_callback gps_loc_cb = NULL; static gps_sv_status_callback gps_sv_cb = NULL; @@ -52,9 +62,12 @@ static int loc_set_position_mode(GpsPositionMode mode, GpsPositionRecurrence re uint32_t min_interval, uint32_t preferred_accuracy, uint32_t preferred_time); static const void* loc_get_extension(const char* name); -#ifdef QCOM_FEATURE_ULP -static int loc_update_criteria(UlpLocationCriteria criteria); -#endif +//ULP/Hybrid provider Function definitions +static int loc_update_criteria(UlpLocationCriteria criteria); +static int loc_ulp_network_init(UlpNetworkLocationCallbacks *callbacks); +static int loc_ulp_send_network_position(UlpNetworkPositionReport *position_report); +static int loc_ulp_phone_context_init(UlpPhoneContextCallbacks *callback); +static int loc_ulp_phone_context_settings_update(UlpPhoneContextSettings *settings); // Defines the GpsInterface in gps.h static const GpsInterface sLocEngInterface = @@ -68,24 +81,16 @@ static const GpsInterface sLocEngInterface = loc_inject_location, loc_delete_aiding_data, loc_set_position_mode, - loc_get_extension -#ifdef QCOM_FEATURE_ULP - ,loc_update_criteria -#endif + loc_get_extension, + loc_update_criteria }; // Function declarations for sLocEngAGpsInterface static void loc_agps_init(AGpsCallbacks* callbacks); -#ifdef QCOM_FEATURE_IPV6 static int loc_agps_open(AGpsType agpsType, const char* apn, AGpsBearerType bearerType); static int loc_agps_closed(AGpsType agpsType); static int loc_agps_open_failed(AGpsType agpsType); -#else -static int loc_agps_open(const char* apn); -static int loc_agps_closed(); -static int loc_agps_open_failed(); -#endif static int loc_agps_set_server(AGpsType type, const char *hostname, int port); static const AGpsInterface sLocEngAGpsInterface = @@ -136,7 +141,6 @@ static const AGpsRilInterface sLocEngAGpsRilInterface = loc_agps_ril_update_network_availability }; -#ifdef QCOM_FEATURE_ULP static bool loc_inject_raw_command(char* command, int length); static const InjectRawCmdInterface sLocEngInjectRawCmdInterface = @@ -144,9 +148,81 @@ static const InjectRawCmdInterface sLocEngInjectRawCmdInterface = sizeof(InjectRawCmdInterface), loc_inject_raw_command }; -#endif +//ULP/Hybrid provider interfaces +static const UlpNetworkInterface sUlpNetworkInterface = +{ + sizeof(UlpNetworkInterface), + loc_ulp_network_init, + loc_ulp_send_network_position +}; +static const UlpPhoneContextInterface sLocEngUlpPhoneContextInterface = +{ + sizeof(UlpPhoneContextInterface), + loc_ulp_phone_context_init, + loc_ulp_phone_context_settings_update +}; static loc_eng_data_s_type loc_afw_data; +static int gss_fd = 0; + +#define TARGET_NAME_OTHER 0 +#define TARGET_NAME_APQ8064_STANDALONE 1 +#define TARGET_NAME_APQ8064_FUSION3 2 + +static int read_a_line(const char * file_path, char * line, int line_size) +{ + FILE *fp; + int result = 0; + + * line = '\0'; + fp = fopen(file_path, "r" ); + if( fp == NULL ) { + LOC_LOGE("open failed: %s: %s\n", file_path, strerror(errno)); + result = -1; + } else { + int len; + fgets(line, line_size, fp); + len = strlen(line); + len = len < line_size - 1? len : line_size - 1; + line[len] = '\0'; + LOC_LOGD("cat %s: %s", file_path, line); + fclose(fp); + } + return result; +} + +#define LINE_LEN 100 +#define STR_LIQUID "Liquid" +#define STR_SURF "Surf" +#define STRLEN_LIQUID (sizeof(STR_LIQUID) - 1) +#define STRLEN_SURF (sizeof(STR_SURF) - 1) +#define IS_STR_END(c) ((c) == '\0' || (c) == '\n' || (c) == '\r') + +static int get_target_name(void) +{ + int target_name = TARGET_NAME_OTHER; + + char hw_platform[] = "/sys/devices/system/soc/soc0/hw_platform"; // "Liquid" or "Surf" + char id[] = "/sys/devices/system/soc/soc0/id"; //109 + char mdm[] = "/dev/mdm"; // No such file or directory + + char line[LINE_LEN]; + + read_a_line( hw_platform, line, LINE_LEN); + if(( !memcmp(line, STR_LIQUID, STRLEN_LIQUID) && IS_STR_END(line[STRLEN_LIQUID]) ) || + ( !memcmp(line, STR_SURF, STRLEN_SURF) && IS_STR_END(line[STRLEN_SURF]) ) + ) { + if (!read_a_line( mdm, line, LINE_LEN)) { + target_name = TARGET_NAME_APQ8064_FUSION3; + } else { + read_a_line( id, line, LINE_LEN); + if(!strncmp(line, "109", strlen("109"))) { + target_name = TARGET_NAME_APQ8064_STANDALONE; + } + } + } + return target_name; +} /*=========================================================================== FUNCTION gps_get_hardware_interface @@ -189,8 +265,26 @@ const GpsInterface* gps_get_hardware_interface () // for gps.c extern "C" const GpsInterface* get_gps_interface() { + loc_eng_read_config(); + //We load up libulp module at this point itself if ULP configured to be On + if(gps_conf.CAPABILITIES & ULP_CAPABILITY) { + loc_eng_ulp_inf = loc_eng_get_ulp_inf(); + } return &sLocEngInterface; } + +static void loc_free_msg(void* msg) +{ + delete (loc_eng_msg*)msg; +} + + +void loc_ulp_msg_sender(void* loc_eng_data_p, void* msg) +{ + LocEngContext* loc_eng_context = (LocEngContext*)((loc_eng_data_s_type*)loc_eng_data_p)->context; + msg_q_snd((void*)loc_eng_context->ulp_q, msg, loc_free_msg); +} + /*=========================================================================== FUNCTION loc_init @@ -233,10 +327,28 @@ static int loc_init(GpsCallbacks* callbacks) gps_loc_cb = callbacks->location_cb; gps_sv_cb = callbacks->sv_status_cb; - int ret_val = loc_eng_init(loc_afw_data, &clientCallbacks, event); + if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) + { + gps_conf.CAPABILITIES &= ~(GPS_CAPABILITY_MSA | GPS_CAPABILITY_MSB); + gss_fd = open("/dev/gss", O_RDONLY); + if (gss_fd < 0) { + LOC_LOGE("GSS open failed: %s\n", strerror(errno)); + return NULL; + } + LOC_LOGD("GSS open success! CAPABILITIES %0x\n", gps_conf.CAPABILITIES); + } - EXIT_LOG(%d, ret_val); - return ret_val; + int retVal = -1; + if (loc_eng_ulp_inf == NULL) + retVal = loc_eng_init(loc_afw_data, &clientCallbacks, event, + NULL); + else + retVal = loc_eng_init(loc_afw_data, &clientCallbacks, event, + loc_ulp_msg_sender); + int ret_val1 = loc_eng_ulp_init(loc_afw_data, loc_eng_ulp_inf); + LOC_LOGD("loc_eng_ulp_init returned %d\n",ret_val1); + EXIT_LOG(%d, retVal); + return retVal; } /*=========================================================================== @@ -261,6 +373,15 @@ static void loc_cleanup() loc_eng_cleanup(loc_afw_data); gps_loc_cb = NULL; gps_sv_cb = NULL; + + /* + * if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) + * { + * close(gss_fd); + * LOC_LOGD("GSS shutdown.\n"); + * } + */ + EXIT_LOG(%s, VOID_RET); } @@ -349,9 +470,10 @@ static int loc_set_position_mode(GpsPositionMode mode, locMode = LOC_POSITION_MODE_STANDALONE; break; } - int ret_val = loc_eng_set_position_mode(loc_afw_data, locMode, - recurrence, min_interval, - preferred_accuracy, preferred_time); + + LocPosMode params(locMode, recurrence, min_interval, + preferred_accuracy, preferred_time, NULL, NULL); + int ret_val = loc_eng_set_position_mode(loc_afw_data, params); EXIT_LOG(%d, ret_val); return ret_val; @@ -437,7 +559,6 @@ static void loc_delete_aiding_data(GpsAidingData f) EXIT_LOG(%s, VOID_RET); } -#ifdef QCOM_FEATURE_ULP /*=========================================================================== FUNCTION loc_update_criteria @@ -462,7 +583,6 @@ static int loc_update_criteria(UlpLocationCriteria criteria) EXIT_LOG(%d, ret_val); return ret_val; } -#endif /*=========================================================================== FUNCTION loc_get_extension @@ -502,19 +622,32 @@ static const void* loc_get_extension(const char* name) else if (strcmp(name, AGPS_RIL_INTERFACE) == 0) { - ret_val = &sLocEngAGpsRilInterface; + char baseband[PROPERTY_VALUE_MAX]; + property_get("ro.baseband", baseband, "msm"); + if (strcmp(baseband, "csfb") == 0) + { + ret_val = &sLocEngAGpsRilInterface; + } } -#ifdef QCOM_FEATURE_ULP else if (strcmp(name, ULP_RAW_CMD_INTERFACE) == 0) { ret_val = &sLocEngInjectRawCmdInterface; } -#endif + else if(strcmp(name, ULP_PHONE_CONTEXT_INTERFACE) == 0) + { + ret_val = &sLocEngUlpPhoneContextInterface; + } + else if(strcmp(name, ULP_NETWORK_INTERFACE) == 0) + { + //Return a valid value for ULP Network Interface only if ULP + //turned on in gps.conf + if(gps_conf.CAPABILITIES & ULP_CAPABILITY) + ret_val = &sUlpNetworkInterface; + } else { LOC_LOGE ("get_extension: Invalid interface passed in\n"); } - EXIT_LOG(%p, ret_val); return ret_val; } @@ -559,7 +692,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 static int loc_agps_open(AGpsType agpsType, const char* apn, AGpsBearerType bearerType) { @@ -569,16 +701,6 @@ static int loc_agps_open(AGpsType agpsType, EXIT_LOG(%d, ret_val); return ret_val; } -#else -static int loc_agps_open(const char* apn) -{ - ENTRY_LOG(); - int ret_val = loc_eng_agps_open(loc_afw_data, apn); - - EXIT_LOG(%d, ret_val); - return ret_val; -} -#endif /*=========================================================================== FUNCTION loc_agps_closed @@ -597,7 +719,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 static int loc_agps_closed(AGpsType agpsType) { ENTRY_LOG(); @@ -606,16 +727,6 @@ static int loc_agps_closed(AGpsType agpsType) EXIT_LOG(%d, ret_val); return ret_val; } -#else -static int loc_agps_closed() -{ - ENTRY_LOG(); - int ret_val = loc_eng_agps_closed(loc_afw_data); - - EXIT_LOG(%d, ret_val); - return ret_val; -} -#endif /*=========================================================================== FUNCTION loc_agps_open_failed @@ -634,7 +745,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 int loc_agps_open_failed(AGpsType agpsType) { ENTRY_LOG(); @@ -643,16 +753,6 @@ int loc_agps_open_failed(AGpsType agpsType) EXIT_LOG(%d, ret_val); return ret_val; } -#else -int loc_agps_open_failed() -{ - ENTRY_LOG(); - int ret_val = loc_eng_agps_open_failed(loc_afw_data); - - EXIT_LOG(%d, ret_val); - return ret_val; -} -#endif /*=========================================================================== FUNCTION loc_agps_set_server @@ -818,7 +918,6 @@ static void loc_agps_ril_update_network_availability(int available, const char* EXIT_LOG(%s, VOID_RET); } -#ifdef QCOM_FEATURE_ULP /*=========================================================================== FUNCTION loc_inject_raw_command @@ -842,18 +941,13 @@ static bool loc_inject_raw_command(char* command, int length) EXIT_LOG(%s, loc_logger_boolStr[ret_val!=0]); return ret_val; } -#endif static void loc_cb(GpsLocation* location, void* locExt) { ENTRY_LOG(); if (NULL != gps_loc_cb && NULL != location) { -#ifdef QCOM_FEATURE_ULP CALLBACK_LOG_CALLFLOW("location_cb - from", %d, location->position_source); -#else - CALLBACK_LOG_CALLFLOW("location_cb - at", %llu, location->timestamp); -#endif gps_loc_cb(location); } EXIT_LOG(%s, VOID_RET); @@ -868,3 +962,156 @@ static void sv_cb(GpsSvStatus* sv_status, void* svExt) } EXIT_LOG(%s, VOID_RET); } +/*=========================================================================== +FUNCTION loc_eng_get_ulp_inf + +DESCRIPTION + This function checks if ULP is enabled, and loads the libulp2.so and + returns its interface + +DEPENDENCIES + None + +RETURN VALUE + interface pointer to libulp: no error + NULL: errors + +SIDE EFFECTS + N/A + +===========================================================================*/ +const ulpInterface * loc_eng_get_ulp_inf(void) +{ + ENTRY_LOG(); + void *handle; + const char *error; + get_ulp_interface* get_ulp_inf; + const ulpInterface* loc_eng_ulpInf = NULL; + + if (!(gps_conf.CAPABILITIES & ULP_CAPABILITY)) { + LOC_LOGD ("%s, ULP is not configured to be On in gps.conf\n", __func__); + goto exit; + } + dlerror(); /* Clear any existing error */ + + handle = dlopen ("libulp2.so", RTLD_NOW); + + if (!handle) + { + if ((error = dlerror()) != NULL) { + LOC_LOGE ("%s, dlopen for libulp.so failed, error = %s\n", __func__, error); + } + goto exit; + } + dlerror(); /* Clear any existing error */ + get_ulp_inf = (get_ulp_interface*) dlsym(handle, "ulp_get_interface"); + if ((error = dlerror()) != NULL) { + LOC_LOGE ("%s, dlsym for ulpInterface failed, error = %s\n", __func__, error); + goto exit; + } + + // Initialize the ULP interface + loc_eng_ulpInf = get_ulp_inf(); + +exit: + EXIT_LOG(%d, loc_eng_ulpInf == NULL); + return loc_eng_ulpInf; +} + +/*=========================================================================== +FUNCTION loc_ulp_network_init + +DESCRIPTION + Initialize the ULP network interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_ulp_phone_context_init(UlpPhoneContextCallbacks *callbacks) +{ + ENTRY_LOG(); + int ret_val = loc_eng_ulp_phone_context_init(loc_afw_data, callbacks); + EXIT_LOG(%d, ret_val); + return ret_val; +} +/*=========================================================================== +FUNCTION loc_ulp_phone_context_settings_update + +DESCRIPTION + This is used to inform the ULP module of phone settings changes carried out + by the users +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ + +static int loc_ulp_phone_context_settings_update(UlpPhoneContextSettings *settings) +{ + ENTRY_LOG(); + int ret_val = -1; + ret_val = loc_eng_ulp_phone_context_settings_update(loc_afw_data, settings); + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_ulp_network_init + +DESCRIPTION + Initialize the ULP network interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +static int loc_ulp_network_init(UlpNetworkLocationCallbacks *callbacks) +{ + ENTRY_LOG(); + int ret_val = loc_eng_ulp_network_init(loc_afw_data, callbacks); + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_ulp_send_network_position + +DESCRIPTION + Ulp send data + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_ulp_send_network_position(UlpNetworkPositionReport *position_report) +{ + ENTRY_LOG(); + int ret_val = -1; + ret_val = loc_eng_ulp_send_network_position(loc_afw_data, position_report); + EXIT_LOG(%d, ret_val); + return ret_val; +} diff --git a/loc_api/libloc_api_50001/loc.h b/loc_api/libloc_api_50001/loc.h old mode 100755 new mode 100644 index bf942373..233b34c3 --- a/loc_api/libloc_api_50001/loc.h +++ b/loc_api/libloc_api_50001/loc.h @@ -38,6 +38,8 @@ extern "C" { #include #include +#define MIN_POSSIBLE_FIX_INTERVAL 1000 /* msec */ + typedef enum loc_server_type { LOC_AGPS_CDMA_PDE_SERVER, LOC_AGPS_CUSTOM_PDE_SERVER, @@ -78,6 +80,7 @@ enum loc_sess_status { LOC_SESS_FAILURE }; +void loc_ulp_msg_sender(void* loc_eng_data_p, void* msg); #ifdef __cplusplus } diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp old mode 100755 new mode 100644 index 4d032dce..9958ca56 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2009-2012 Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -43,7 +43,6 @@ #include #include #include -#include #include "LocApiAdapter.h" @@ -59,8 +58,7 @@ #include #include #include - -#include "ulp.h" +#include #include "log_util.h" #include "loc_eng_log.h" @@ -68,31 +66,79 @@ #define SUCCESS TRUE #define FAILURE FALSE - static void loc_eng_deferred_action_thread(void* context); static void* loc_eng_create_msg_q(); static void loc_eng_free_msg(void* msg); -struct LocEngContext { - // Data variables used by deferred action thread - const void* deferred_q; - const pthread_t deferred_action_thread; - static LocEngContext* get(gps_create_thread threadCreator); - void drop(); - static pthread_mutex_t lock; - static pthread_cond_t cond; -private: - int counter; - static LocEngContext *me; - LocEngContext(gps_create_thread threadCreator); -}; - pthread_mutex_t LocEngContext::lock = PTHREAD_MUTEX_INITIALIZER; pthread_cond_t LocEngContext::cond = PTHREAD_COND_INITIALIZER; LocEngContext* LocEngContext::me = NULL; +boolean gpsConfigAlreadyRead = false; + +loc_gps_cfg_s_type gps_conf; + +/* Parameter spec table */ +static loc_param_s_type loc_parameter_table[] = +{ + {"INTERMEDIATE_POS", &gps_conf.INTERMEDIATE_POS, NULL, 'n'}, + {"ACCURACY_THRES", &gps_conf.ACCURACY_THRES, NULL, 'n'}, + {"ENABLE_WIPER", &gps_conf.ENABLE_WIPER, NULL, 'n'}, + {"SUPL_VER", &gps_conf.SUPL_VER, NULL, 'n'}, + {"CAPABILITIES", &gps_conf.CAPABILITIES, NULL, 'n'}, + {"GYRO_BIAS_RANDOM_WALK", &gps_conf.GYRO_BIAS_RANDOM_WALK, &gps_conf.GYRO_BIAS_RANDOM_WALK_VALID, 'f'}, + {"ACCEL_RANDOM_WALK_SPECTRAL_DENSITY", &gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY, &gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID, 'f'}, + {"ANGLE_RANDOM_WALK_SPECTRAL_DENSITY", &gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY, &gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID, 'f'}, + {"RATE_RANDOM_WALK_SPECTRAL_DENSITY", &gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY, &gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY_VALID, 'f'}, + {"VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY", &gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY, &gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_VALID, 'f'}, + {"SENSOR_ACCEL_BATCHES_PER_SEC", &gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, NULL, 'n'}, + {"SENSOR_ACCEL_SAMPLES_PER_BATCH", &gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, NULL, 'n'}, + {"SENSOR_GYRO_BATCHES_PER_SEC", &gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, NULL, 'n'}, + {"SENSOR_GYRO_SAMPLES_PER_BATCH", &gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, NULL, 'n'}, + {"SENSOR_CONTROL_MODE", &gps_conf.SENSOR_CONTROL_MODE, NULL, 'n'}, + {"SENSOR_USAGE", &gps_conf.SENSOR_USAGE, NULL, 'n'}, + {"QUIPC_ENABLED", &gps_conf.QUIPC_ENABLED, NULL, 'n'}, + {"LPP_PROFILE", &gps_conf.LPP_PROFILE, NULL, 'n'}, +}; + +static void loc_default_parameters(void) +{ + /* defaults */ + gps_conf.INTERMEDIATE_POS = 0; + gps_conf.ACCURACY_THRES = 0; + gps_conf.ENABLE_WIPER = 0; + gps_conf.SUPL_VER = 0x10000; + gps_conf.CAPABILITIES = 0x7; + + gps_conf.GYRO_BIAS_RANDOM_WALK = 0; + gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC = 2; + gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH = 5; + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC = 2; + gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH = 5; + gps_conf.SENSOR_CONTROL_MODE = 0; /* AUTO */ + gps_conf.SENSOR_USAGE = 0; /* Enabled */ + gps_conf.SENSOR_ALGORITHM_CONFIG_MASK = 0; /* INS Disabled = FALSE*/ + + /* Values MUST be set by OEMs in configuration for sensor-assisted + navigation to work. There are NO default values */ + gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY = 0; + gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY = 0; + gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY = 0; + gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY = 0; + + gps_conf.GYRO_BIAS_RANDOM_WALK_VALID = 0; + gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID = 0; + gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID = 0; + gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY_VALID = 0; + gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_VALID = 0; + + /* LTE Positioning Profile configuration is disable by default*/ + gps_conf.LPP_PROFILE = 0; +} LocEngContext::LocEngContext(gps_create_thread threadCreator) : deferred_q((const void*)loc_eng_create_msg_q()), + //TODO: should we conditionally create ulp msg q? + ulp_q((const void*)loc_eng_create_msg_q()), deferred_action_thread(threadCreator("loc_eng",loc_eng_deferred_action_thread, this)), counter(0) { @@ -106,11 +152,6 @@ LocEngContext* LocEngContext::get(gps_create_thread threadCreator) pthread_mutex_lock(&lock); // gonna need mutex protection here... if (NULL == me) { - // gps.conf is not part of the context class. But we only want to parse the conf - // file once. This is the only good place to ensure that. - // In fact one day the conf file should go into context as well. - loc_read_gps_conf(); - me = new LocEngContext(threadCreator); } me->counter++; @@ -134,6 +175,7 @@ void LocEngContext::drop() pthread_cond_wait(&cond, &lock); msg_q_destroy((void**)&deferred_q); + msg_q_destroy((void**)&ulp_q); delete me; me = NULL; } @@ -162,13 +204,6 @@ static void loc_eng_handle_engine_down(loc_eng_data_s_type &loc_eng_data) ; static void loc_eng_handle_engine_up(loc_eng_data_s_type &loc_eng_data) ; static char extra_data[100]; - -#ifdef QCOM_FEATURE_ULP -// ULP integration -static const ulpInterface* locEngUlpInf = NULL; -static int loc_eng_ulp_init(void* handle) ; -#endif - /********************************************************************* * Initialization checking macros *********************************************************************/ @@ -221,14 +256,15 @@ SIDE EFFECTS ===========================================================================*/ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, - LOC_API_ADAPTER_EVENT_MASK_T event) + LOC_API_ADAPTER_EVENT_MASK_T event, + void (*loc_external_msg_sender) (void*, void*)) + { ENTRY_LOG_CALLFLOW(); - if (NULL == callbacks || 0 == event) { LOC_LOGE("loc_eng_init: bad parameters cb %p eMask %d", callbacks, event); EXIT_LOG(%d, 0); - return 0; + return NULL; } STATE_CHECK((NULL == loc_eng_data.context), @@ -258,12 +294,8 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, // loc_eng_data.fix_session_status -- GPS_STATUS_NONE; // loc_eng_data.mute_session_state -- LOC_MUTE_SESS_NONE; -#ifdef QCOM_FEATURE_ULP - loc_eng_ulp_init(&loc_eng_data); -#endif - LocEng locEngHandle(&loc_eng_data, event, loc_eng_data.acquire_wakelock_cb, - loc_eng_data.release_wakelock_cb, loc_eng_msg_sender, + loc_eng_data.release_wakelock_cb, loc_eng_msg_sender, loc_external_msg_sender, callbacks->location_ext_parser, callbacks->sv_ext_parser); loc_eng_data.client_handle = getLocApiAdapter(locEngHandle); @@ -302,16 +334,35 @@ static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data) msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, supl_msg, loc_eng_free_msg); + loc_eng_msg_lpp_config *lpp_msg(new loc_eng_msg_lpp_config(&loc_eng_data, + gps_conf.LPP_PROFILE)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + lpp_msg, loc_eng_free_msg); + loc_eng_msg_sensor_control_config *sensor_control_config_msg( new loc_eng_msg_sensor_control_config(&loc_eng_data, gps_conf.SENSOR_USAGE)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, sensor_control_config_msg, loc_eng_free_msg); - /* Make sure this is specified by the user in the gps.conf file */ - if(gps_conf.GYRO_BIAS_RANDOM_WALK_VALID) + /* Make sure at least one of the sensor property is specified by the user in the gps.conf file. */ + if( gps_conf.GYRO_BIAS_RANDOM_WALK_VALID || + gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID || + gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID || + gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY_VALID || + gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_VALID ) { loc_eng_msg_sensor_properties *sensor_properties_msg( - new loc_eng_msg_sensor_properties(&loc_eng_data, gps_conf.GYRO_BIAS_RANDOM_WALK)); + new loc_eng_msg_sensor_properties(&loc_eng_data, + gps_conf.GYRO_BIAS_RANDOM_WALK_VALID, + gps_conf.GYRO_BIAS_RANDOM_WALK, + gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID, + gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY, + gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID, + gps_conf.ANGLE_RANDOM_WALK_SPECTRAL_DENSITY, + gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY_VALID, + gps_conf.RATE_RANDOM_WALK_SPECTRAL_DENSITY, + gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_VALID, + gps_conf.VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, sensor_properties_msg, loc_eng_free_msg); } @@ -322,7 +373,8 @@ static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data) gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, - gps_conf.SENSOR_GYRO_BATCHES_PER_SEC)); + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, + gps_conf.SENSOR_ALGORITHM_CONFIG_MASK)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, sensor_perf_control_conf_msg, loc_eng_free_msg); } @@ -355,7 +407,7 @@ void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data) // XTRA has no state, so we are fine with it. // we need to check and clear NI - +#if 0 // we need to check and clear ATL if (NULL != loc_eng_data.agnss_nif) { delete loc_eng_data.agnss_nif; @@ -365,8 +417,8 @@ void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data) delete loc_eng_data.internet_nif; loc_eng_data.internet_nif = NULL; } - - if (loc_eng_data.navigating) +#endif + if (loc_eng_data.client_handle->isInSession()) { LOC_LOGD("loc_eng_cleanup: fix not stopped. stop it now."); loc_eng_stop(loc_eng_data); @@ -380,8 +432,8 @@ void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data) // De-initialize ulp if (locEngUlpInf != NULL) { - locEngUlpInf->destroy (); locEngUlpInf = NULL; + msg_q_destroy( &loc_eng_data.ulp_q); } if (loc_eng_data.client_handle != NULL) @@ -430,10 +482,18 @@ int loc_eng_start(loc_eng_data_s_type &loc_eng_data) ENTRY_LOG_CALLFLOW(); INIT_CHECK(loc_eng_data.context, return -1); - loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_START_FIX)); - msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, - msg, loc_eng_free_msg); - + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + //Pass the start messgage to ULP if present & activated + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, ULP_MSG_START_FIX)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q, + msg, loc_eng_free_msg); + }else + { + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_START_FIX)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + } EXIT_LOG(%d, 0); return 0; } @@ -443,20 +503,13 @@ static int loc_eng_start_handler(loc_eng_data_s_type &loc_eng_data) ENTRY_LOG(); int ret_val = LOC_API_ADAPTER_ERR_SUCCESS; - if (!loc_eng_data.navigating) { -#ifdef QCOM_FEATURE_ULP - if (NULL == locEngUlpInf || - locEngUlpInf->start_fix () == 1) { - ret_val = loc_eng_data.client_handle->startFix(); - } -#else + if (!loc_eng_data.client_handle->isInSession()) { ret_val = loc_eng_data.client_handle->startFix(); -#endif if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS || ret_val == LOC_API_ADAPTER_ERR_ENGINE_DOWN) { - loc_eng_data.navigating = TRUE; + loc_eng_data.client_handle->setInSession(TRUE); } } @@ -465,7 +518,7 @@ static int loc_eng_start_handler(loc_eng_data_s_type &loc_eng_data) } /*=========================================================================== -FUNCTION loc_eng_stop +FUNCTION loc_eng_stop_wrapper DESCRIPTION Stops the tracking session @@ -485,9 +538,18 @@ int loc_eng_stop(loc_eng_data_s_type &loc_eng_data) ENTRY_LOG_CALLFLOW(); INIT_CHECK(loc_eng_data.context, return -1); - loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_STOP_FIX)); - msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, - msg, loc_eng_free_msg); + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + //Pass the start messgage to ULP if present & activated + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, ULP_MSG_STOP_FIX)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q, + msg, loc_eng_free_msg); + }else + { + loc_eng_msg *msg(new loc_eng_msg(&loc_eng_data, LOC_ENG_MSG_STOP_FIX)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + msg, loc_eng_free_msg); + } EXIT_LOG(%d, 0); return 0; @@ -498,14 +560,7 @@ static int loc_eng_stop_handler(loc_eng_data_s_type &loc_eng_data) ENTRY_LOG(); int ret_val = LOC_API_ADAPTER_ERR_SUCCESS; - if (loc_eng_data.navigating) { -#ifdef QCOM_FEATURE_ULP - // Stops the ULP - if (locEngUlpInf != NULL) - { - locEngUlpInf->stop_fix (); - } -#endif + if (loc_eng_data.client_handle->isInSession()) { ret_val = loc_eng_data.client_handle->stopFix(); if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS && @@ -514,7 +569,7 @@ static int loc_eng_stop_handler(loc_eng_data_s_type &loc_eng_data) loc_inform_gps_status(loc_eng_data, GPS_STATUS_SESSION_END); } - loc_eng_data.navigating = FALSE; + loc_eng_data.client_handle->setInSession(FALSE); } EXIT_LOG(%d, ret_val); @@ -561,18 +616,12 @@ SIDE EFFECTS ===========================================================================*/ int loc_eng_set_position_mode(loc_eng_data_s_type &loc_eng_data, - LocPositionMode mode, - GpsPositionRecurrence recurrence, - uint32_t min_interval, - uint32_t preferred_accuracy, - uint32_t preferred_time) + LocPosMode ¶ms) { ENTRY_LOG_CALLFLOW(); INIT_CHECK(loc_eng_data.context, return -1); loc_eng_msg_position_mode *msg( - new loc_eng_msg_position_mode(&loc_eng_data, mode, - recurrence, min_interval, - preferred_accuracy, preferred_time)); + new loc_eng_msg_position_mode(&loc_eng_data, params)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, msg, loc_eng_free_msg); @@ -683,6 +732,7 @@ void loc_eng_delete_aiding_data(loc_eng_data_s_type &loc_eng_data, GpsAidingData } /*=========================================================================== + FUNCTION loc_inform_gps_state DESCRIPTION @@ -760,7 +810,7 @@ static void loc_eng_agps_reinit(loc_eng_data_s_type &loc_eng_data) loc_eng_data.c2k_host_buf, loc_eng_data.c2k_port_buf); } - EXIT_LOG(%p, VOID_RET); + EXIT_LOG(%s, VOID_RET); } /*=========================================================================== FUNCTION loc_eng_agps_init @@ -788,20 +838,21 @@ void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbac loc_eng_data.agps_status_cb = callbacks->status_cb; loc_eng_data.agnss_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, - AGPS_TYPE_SUPL); -#ifdef QCOM_FEATURE_IPV6 + AGPS_TYPE_SUPL, + false); loc_eng_data.internet_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, - AGPS_TYPE_WWAN_ANY); -#else - loc_eng_data.internet_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, - AGPS_TYPE_SUPL); -#endif + AGPS_TYPE_WWAN_ANY, + false); + loc_eng_data.wifi_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, + AGPS_TYPE_WIFI, + true); #ifdef FEATURE_GNSS_BIT_API { char baseband[PROPERTY_VALUE_MAX]; property_get("ro.baseband", baseband, "msm"); - if ((strcmp(baseband,"svlte2a") == 0)) + if ((strcmp(baseband,"svlte2a") == 0) || + (strcmp(baseband,"msm") == 0)) { loc_eng_dmn_conn_loc_api_server_launch(callbacks->create_thread_cb, NULL, NULL, &loc_eng_data); @@ -810,7 +861,7 @@ void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbac #endif /* FEATURE_GNSS_BIT_API */ loc_eng_agps_reinit(loc_eng_data); - EXIT_LOG(%p, VOID_RET); + EXIT_LOG(%s, VOID_RET); } /*=========================================================================== @@ -830,7 +881,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType, const char* apn, AGpsBearerType bearerType) { @@ -856,33 +906,6 @@ int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType, EXIT_LOG(%d, 0); return 0; } -#else -int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, - const char* apn) -{ - ENTRY_LOG_CALLFLOW(); - INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, - return -1); - - if (apn == NULL) - { - LOC_LOGE("APN Name NULL\n"); - return 0; - } - - LOC_LOGD("loc_eng_agps_open APN name = [%s]", apn); - - int apn_len = smaller_of(strlen (apn), MAX_APN_LEN); - loc_eng_msg_atl_open_success *msg( - new loc_eng_msg_atl_open_success(&loc_eng_data, apn, - apn_len)); - msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, - msg, loc_eng_free_msg); - - EXIT_LOG(%d, 0); - return 0; -} -#endif /*=========================================================================== FUNCTION loc_eng_agps_closed @@ -901,7 +924,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType) { ENTRY_LOG_CALLFLOW(); @@ -915,21 +937,6 @@ int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType) EXIT_LOG(%d, 0); return 0; } -#else -int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data) -{ - ENTRY_LOG_CALLFLOW(); - INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, - return -1); - - loc_eng_msg_atl_closed *msg(new loc_eng_msg_atl_closed(&loc_eng_data)); - msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, - msg, loc_eng_free_msg); - - EXIT_LOG(%d, 0); - return 0; -} -#endif /*=========================================================================== FUNCTION loc_eng_agps_open_failed @@ -948,7 +955,6 @@ SIDE EFFECTS N/A ===========================================================================*/ -#ifdef QCOM_FEATURE_IPV6 int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType) { ENTRY_LOG_CALLFLOW(); @@ -962,21 +968,6 @@ int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsTyp EXIT_LOG(%d, 0); return 0; } -#else -int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data) -{ - ENTRY_LOG_CALLFLOW(); - INIT_CHECK(loc_eng_data.context && loc_eng_data.agps_status_cb, - return -1); - - loc_eng_msg_atl_open_failed *msg(new loc_eng_msg_atl_open_failed(&loc_eng_data)); - msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, - msg, loc_eng_free_msg); - - EXIT_LOG(%d, 0); - return 0; -} -#endif /*=========================================================================== @@ -1205,9 +1196,10 @@ static void loc_eng_report_status (loc_eng_data_s_type &loc_eng_data, GpsStatusV } // Session End is not reported during Android navigating state + boolean navigating = loc_eng_data.client_handle->isInSession(); if (status != GPS_STATUS_NONE && - !(status == GPS_STATUS_SESSION_END && loc_eng_data.navigating) && - !(status == GPS_STATUS_SESSION_BEGIN && !loc_eng_data.navigating)) + !(status == GPS_STATUS_SESSION_END && navigating) && + !(status == GPS_STATUS_SESSION_BEGIN && !navigating)) { if (loc_eng_data.mute_session_state != LOC_MUTE_SESS_IN_SESSION) { @@ -1275,15 +1267,10 @@ void loc_eng_handle_engine_up(loc_eng_data_s_type &loc_eng_data) loc_eng_report_status(loc_eng_data, GPS_STATUS_ENGINE_ON); // modem is back up. If we crashed in the middle of navigating, we restart. - if (loc_eng_data.navigating) { - loc_eng_data.client_handle->setPositionMode( - loc_eng_data.position_mode.pMode, - loc_eng_data.position_mode.pRecurrence, - loc_eng_data.position_mode.minInterval, - loc_eng_data.position_mode.preferredAccuracy, - loc_eng_data.position_mode.preferredTime); - // not mutex protected, assuming fw won't call start twice without a - // stop call in between. + if (loc_eng_data.client_handle->isInSession()) { + // This sets the copy in adapter to modem + loc_eng_data.client_handle->setPositionMode(NULL); + loc_eng_data.client_handle->setInSession(false); loc_eng_start_handler(loc_eng_data); } EXIT_LOG(%s, VOID_RET); @@ -1380,10 +1367,7 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_SET_POSITION_MODE: { loc_eng_msg_position_mode *pmMsg = (loc_eng_msg_position_mode*)msg; - loc_eng_data_p->client_handle->setPositionMode(pmMsg->pMode, pmMsg->pRecurrence, - pmMsg->minInterval,pmMsg->preferredAccuracy, - pmMsg->preferredTime); - memcpy((void*)&loc_eng_data_p->position_mode, (void*)pmMsg, sizeof(*pmMsg)); + loc_eng_data_p->client_handle->setPositionMode(&(pmMsg->pMode)); } break; @@ -1426,6 +1410,13 @@ static void loc_eng_deferred_action_thread(void* arg) } break; + case LOC_ENG_MSG_LPP_CONFIG: + { + loc_eng_msg_lpp_config *svMsg = (loc_eng_msg_lpp_config*)msg; + loc_eng_data_p->client_handle->setLPPConfig(svMsg->lpp_config); + } + break; + case LOC_ENG_MSG_SET_SENSOR_CONTROL_CONFIG: { loc_eng_msg_sensor_control_config *sccMsg = (loc_eng_msg_sensor_control_config*)msg; @@ -1436,7 +1427,16 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_SET_SENSOR_PROPERTIES: { loc_eng_msg_sensor_properties *spMsg = (loc_eng_msg_sensor_properties*)msg; - loc_eng_data_p->client_handle->setSensorProperties(spMsg->gyroBiasVarianceRandomWalk); + loc_eng_data_p->client_handle->setSensorProperties(spMsg->gyroBiasVarianceRandomWalk_valid, + spMsg->gyroBiasVarianceRandomWalk, + spMsg->accelRandomWalk_valid, + spMsg->accelRandomWalk, + spMsg->angleRandomWalk_valid, + spMsg->angleRandomWalk, + spMsg->rateRandomWalk_valid, + spMsg->rateRandomWalk, + spMsg->velocityRandomWalk_valid, + spMsg->velocityRandomWalk); } break; @@ -1444,18 +1444,27 @@ static void loc_eng_deferred_action_thread(void* arg) { loc_eng_msg_sensor_perf_control_config *spccMsg = (loc_eng_msg_sensor_perf_control_config*)msg; loc_eng_data_p->client_handle->setSensorPerfControlConfig(spccMsg->controlMode, spccMsg->accelSamplesPerBatch, spccMsg->accelBatchesPerSec, - spccMsg->gyroSamplesPerBatch, spccMsg->gyroBatchesPerSec); + spccMsg->gyroSamplesPerBatch, spccMsg->gyroBatchesPerSec, spccMsg->algorithmConfig); + } + break; + + case LOC_ENG_MSG_EXT_POWER_CONFIG: + { + loc_eng_msg_ext_power_config *pwrMsg = (loc_eng_msg_ext_power_config*)msg; + loc_eng_data_p->client_handle->setExtPowerConfig(pwrMsg->isBatteryCharging); } break; case LOC_ENG_MSG_REPORT_POSITION: if (loc_eng_data_p->mute_session_state != LOC_MUTE_SESS_IN_SESSION) { + bool reported = false; loc_eng_msg_report_position *rpMsg = (loc_eng_msg_report_position*)msg; if (loc_eng_data_p->location_cb != NULL) { if (LOC_SESS_FAILURE == rpMsg->status) { // in case we want to handle the failure case loc_eng_data_p->location_cb(NULL, NULL); + reported = true; } // what's in the else if is... (line by line) // 1. this is a good fix; or @@ -1472,8 +1481,23 @@ static void loc_eng_deferred_action_thread(void* arg) (rpMsg->location.accuracy > gps_conf.ACCURACY_THRES)))) { loc_eng_data_p->location_cb((GpsLocation*)&(rpMsg->location), (void*)rpMsg->locationExt); + reported = true; } } + + // if we have reported this fix + if (reported && + // and if this is a singleshot + GPS_POSITION_RECURRENCE_SINGLE == + loc_eng_data_p->client_handle->getPositionMode().recurrence) { + if (LOC_SESS_INTERMEDIATE == rpMsg->status) { + // modem could be still working for a final fix, + // although we no longer need it. So stopFix(). + loc_eng_data_p->client_handle->stopFix(); + } + // turn off the session flag. + loc_eng_data_p->client_handle->setInSession(false); + } } break; @@ -1500,15 +1524,22 @@ static void loc_eng_deferred_action_thread(void* arg) gettimeofday(&tv, (struct timezone *) NULL); int64_t now = tv.tv_sec * 1000LL + tv.tv_usec / 1000; CALLBACK_LOG_CALLFLOW("nmea_cb", %p, nmMsg->nmea); + loc_eng_data_p->nmea_cb(now, nmMsg->nmea, nmMsg->length); } break; case LOC_ENG_MSG_REQUEST_BIT: { + AgpsStateMachine* stateMachine; loc_eng_msg_request_bit* brqMsg = (loc_eng_msg_request_bit*)msg; - AgpsStateMachine* stateMachine = (brqMsg->isSupl) ? - loc_eng_data_p->agnss_nif : - loc_eng_data_p->internet_nif; + if (brqMsg->ifType == LOC_ENG_IF_REQUEST_TYPE_SUPL) { + stateMachine = loc_eng_data_p->agnss_nif; + } else if (brqMsg->ifType == LOC_ENG_IF_REQUEST_TYPE_ANY) { + stateMachine = loc_eng_data_p->internet_nif; + } else { + LOC_LOGD("%s]%d: unknown I/F request type = 0x%x\n", __func__, __LINE__, brqMsg->ifType); + break; + } BITSubscriber subscriber(stateMachine, brqMsg->ipv4Addr, brqMsg->ipv6Addr); stateMachine->subscribeRsrc((Subscriber*)&subscriber); @@ -1517,10 +1548,16 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_RELEASE_BIT: { + AgpsStateMachine* stateMachine; loc_eng_msg_release_bit* brlMsg = (loc_eng_msg_release_bit*)msg; - AgpsStateMachine* stateMachine = (brlMsg->isSupl) ? - loc_eng_data_p->agnss_nif : - loc_eng_data_p->internet_nif; + if (brlMsg->ifType == LOC_ENG_IF_REQUEST_TYPE_SUPL) { + stateMachine = loc_eng_data_p->agnss_nif; + } else if (brlMsg->ifType == LOC_ENG_IF_REQUEST_TYPE_ANY) { + stateMachine = loc_eng_data_p->internet_nif; + } else { + LOC_LOGD("%s]%d: unknown I/F request type = 0x%x\n", __func__, __LINE__, brlMsg->ifType); + break; + } BITSubscriber subscriber(stateMachine, brlMsg->ipv4Addr, brlMsg->ipv6Addr); stateMachine->unsubscribeRsrc((Subscriber*)&subscriber); @@ -1530,12 +1567,15 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_REQUEST_ATL: { loc_eng_msg_request_atl* arqMsg = (loc_eng_msg_request_atl*)msg; - AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == arqMsg->type) ? + boolean backwardCompatibleMode = AGPS_TYPE_INVALID == arqMsg->type; + AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == arqMsg->type || + backwardCompatibleMode) ? loc_eng_data_p->agnss_nif : loc_eng_data_p->internet_nif; ATLSubscriber subscriber(arqMsg->handle, stateMachine, - loc_eng_data_p->client_handle); + loc_eng_data_p->client_handle, + backwardCompatibleMode); stateMachine->subscribeRsrc((Subscriber*)&subscriber); } @@ -1546,18 +1586,44 @@ static void loc_eng_deferred_action_thread(void* arg) loc_eng_msg_release_atl* arlMsg = (loc_eng_msg_release_atl*)msg; ATLSubscriber s1(arlMsg->handle, loc_eng_data_p->agnss_nif, - loc_eng_data_p->client_handle); + loc_eng_data_p->client_handle, + false); // attempt to unsubscribe from agnss_nif first if (! loc_eng_data_p->agnss_nif->unsubscribeRsrc((Subscriber*)&s1)) { ATLSubscriber s2(arlMsg->handle, loc_eng_data_p->internet_nif, - loc_eng_data_p->client_handle); + loc_eng_data_p->client_handle, + false); // if unsuccessful, try internet_nif loc_eng_data_p->internet_nif->unsubscribeRsrc((Subscriber*)&s2); } } break; + case LOC_ENG_MSG_REQUEST_WIFI: + { + loc_eng_msg_request_wifi *wrqMsg = (loc_eng_msg_request_wifi *)msg; + if (wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC || + wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM) { + AgpsStateMachine* stateMachine = loc_eng_data_p->wifi_nif; + WIFISubscriber subscriber(stateMachine, wrqMsg->ssid, wrqMsg->password, wrqMsg->senderId); + stateMachine->subscribeRsrc((Subscriber*)&subscriber); + } else { + LOC_LOGE("%s]%d ERROR: unknown sender ID", __func__, __LINE__); + break; + } + } + break; + + case LOC_ENG_MSG_RELEASE_WIFI: + { + AgpsStateMachine* stateMachine = loc_eng_data_p->wifi_nif; + loc_eng_msg_release_wifi* wrlMsg = (loc_eng_msg_release_wifi*)msg; + WIFISubscriber subscriber(stateMachine, wrlMsg->ssid, wrlMsg->password, wrlMsg->senderId); + stateMachine->unsubscribeRsrc((Subscriber*)&subscriber); + } + break; + case LOC_ENG_MSG_REQUEST_XTRA_DATA: if (loc_eng_data_p->xtra_module_data.download_request_cb != NULL) { @@ -1593,15 +1659,22 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_ATL_OPEN_SUCCESS: { loc_eng_msg_atl_open_success *aosMsg = (loc_eng_msg_atl_open_success*)msg; -#ifdef QCOM_FEATURE_IPV6 - AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == aosMsg->agpsType) ? - loc_eng_data_p->agnss_nif : - loc_eng_data_p->internet_nif; + AgpsStateMachine* stateMachine; + switch (aosMsg->agpsType) { + case AGPS_TYPE_WIFI: { + stateMachine = loc_eng_data_p->wifi_nif; + break; + } + case AGPS_TYPE_SUPL: { + stateMachine = loc_eng_data_p->agnss_nif; + break; + } + default: { + stateMachine = loc_eng_data_p->internet_nif; + } + } stateMachine->setBearer(aosMsg->bearerType); -#else - AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; -#endif stateMachine->setAPN(aosMsg->apn, aosMsg->length); stateMachine->onRsrcEvent(RSRC_GRANTED); } @@ -1610,13 +1683,20 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_ATL_CLOSED: { loc_eng_msg_atl_closed *acsMsg = (loc_eng_msg_atl_closed*)msg; -#ifdef QCOM_FEATURE_IPV6 - AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == acsMsg->agpsType) ? - loc_eng_data_p->agnss_nif : - loc_eng_data_p->internet_nif; -#else - AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; -#endif + AgpsStateMachine* stateMachine; + switch (acsMsg->agpsType) { + case AGPS_TYPE_WIFI: { + stateMachine = loc_eng_data_p->wifi_nif; + break; + } + case AGPS_TYPE_SUPL: { + stateMachine = loc_eng_data_p->agnss_nif; + break; + } + default: { + stateMachine = loc_eng_data_p->internet_nif; + } + } stateMachine->onRsrcEvent(RSRC_RELEASED); } @@ -1625,13 +1705,20 @@ static void loc_eng_deferred_action_thread(void* arg) case LOC_ENG_MSG_ATL_OPEN_FAILED: { loc_eng_msg_atl_open_failed *aofMsg = (loc_eng_msg_atl_open_failed*)msg; -#ifdef QCOM_FEATURE_IPV6 - AgpsStateMachine* stateMachine = (AGPS_TYPE_SUPL == aofMsg->agpsType) ? - loc_eng_data_p->agnss_nif : - loc_eng_data_p->internet_nif; -#else - AgpsStateMachine* stateMachine = loc_eng_data_p->agnss_nif; -#endif + AgpsStateMachine* stateMachine; + switch (aofMsg->agpsType) { + case AGPS_TYPE_WIFI: { + stateMachine = loc_eng_data_p->wifi_nif; + break; + } + case AGPS_TYPE_SUPL: { + stateMachine = loc_eng_data_p->agnss_nif; + break; + } + default: { + stateMachine = loc_eng_data_p->internet_nif; + } + } stateMachine->onRsrcEvent(RSRC_DENIED); } @@ -1645,6 +1732,36 @@ static void loc_eng_deferred_action_thread(void* arg) loc_eng_handle_engine_up(*loc_eng_data_p); break; + case LOC_ENG_MSG_REQUEST_NETWORK_POSIITON: + { + loc_eng_msg_request_network_position *nlprequestmsg = (loc_eng_msg_request_network_position*)msg; + //loc_eng_handle_request_network_position(nlprequestmsg ); + LOC_LOGD("Received n/w position request from ULP.Request type %d Periodicity: %d\n", + nlprequestmsg->networkPosRequest.request_type, + nlprequestmsg->networkPosRequest.interval_ms); + if(loc_eng_data_p->ulp_network_callback != NULL) + { + loc_eng_data_p->ulp_network_callback((UlpNetworkRequestPos*)&(nlprequestmsg->networkPosRequest)); + } + else + LOC_LOGE("Ulp Network call back not initialized"); + } + break; + + case LOC_ENG_MSG_REQUEST_PHONE_CONTEXT: + { + loc_eng_msg_request_phone_context *contextReqMsg = (loc_eng_msg_request_phone_context*)msg; + LOC_LOGD("Received phone context request from ULP.context_type 0x%x,request_type 0x%x ", + contextReqMsg->contextRequest.context_type,contextReqMsg->contextRequest.request_type) + if(loc_eng_data_p->ulp_phone_context_req_cb != NULL) + { + loc_eng_data_p->ulp_phone_context_req_cb((UlpPhoneContextRequest*)&(contextReqMsg->contextRequest)); + } + else + LOC_LOGE("Ulp Phone context request call back not initialized"); + } + break; + default: LOC_LOGE("unsupported msgid = %d\n", msg->msgid); break; @@ -1675,52 +1792,6 @@ static void loc_eng_deferred_action_thread(void* arg) EXIT_LOG(%s, VOID_RET); } -/*=========================================================================== -FUNCTION loc_eng_report_position_ulp - -DESCRIPTION - Report a ULP position - p_ulp_pos_absolute, ULP position in absolute coordinates - -DEPENDENCIES - None - -RETURN VALUE - 0: SUCCESS - others: error - -SIDE EFFECTS - N/A - -===========================================================================*/ -static int loc_eng_report_position_ulp (void* handle, - const GpsLocation* location_report_ptr, - unsigned int ext_data_length, - unsigned char* ext_data) -{ - ENTRY_LOG(); - loc_eng_data_s_type* loc_eng_data_p = (loc_eng_data_s_type*)handle; - - INIT_CHECK(loc_eng_data_p->context && loc_eng_data_p->client_handle, - return -1); - - if (ext_data_length > sizeof (extra_data)) - { - ext_data_length = sizeof (extra_data); - } - - memcpy(extra_data, - ext_data, - ext_data_length); - - loc_eng_data_p->client_handle->reportPosition((GpsLocation&)*location_report_ptr, - NULL, LOC_SESS_SUCCESS); - - EXIT_LOG(%d, 0); - return 0; -} - -#ifdef QCOM_FEATURE_ULP /*=========================================================================== FUNCTION loc_eng_ulp_init @@ -1739,41 +1810,17 @@ SIDE EFFECTS N/A ===========================================================================*/ -static int loc_eng_ulp_init(void* owner) +int loc_eng_ulp_init(loc_eng_data_s_type &loc_eng_data, const ulpInterface * loc_eng_ulpInf) { ENTRY_LOG(); - int ret_val; - void *handle; - const char *error; - get_ulp_interface* get_ulp_inf; + int ret_val=-1; - if (!(gps_conf.CAPABILITIES & ULP_CAPABILITY)) { - LOC_LOGD ("%s, ULP is not supported\n", __func__); - ret_val = -1; - goto exit; - } - - handle = dlopen ("libulp.so", RTLD_NOW); - if (!handle) + if(loc_eng_ulpInf != NULL) { - LOC_LOGE ("%s, dlopen for libulp.so failed\n", __func__); - ret_val = -1; - goto exit; + // Initialize the ULP interface + ((ulpInterface *)loc_eng_ulpInf)->init(loc_eng_data); + loc_eng_data.ulp_initialized = TRUE; } - dlerror(); /* Clear any existing error */ - - get_ulp_inf = (get_ulp_interface*) dlsym(handle, "ulp_get_interface"); - if ((error = dlerror()) != NULL) { - LOC_LOGE ("%s, dlsym for ulpInterface failed, error = %s\n", __func__, error); - ret_val = -1; - goto exit; - } - - locEngUlpInf = get_ulp_inf(); - - // Initialize the ULP interface - locEngUlpInf->init (owner, loc_eng_report_position_ulp); - ret_val = 0; exit: EXIT_LOG(%d, ret_val); @@ -1830,9 +1877,193 @@ int loc_eng_update_criteria(loc_eng_data_s_type &loc_eng_data, ENTRY_LOG_CALLFLOW(); INIT_CHECK(loc_eng_data.context, return -1); int ret_val; - ret_val = 0; + + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + LOC_LOGD("SJ:loc_eng_update_criteria: valid 0x%x action:%d, minTime:%ld, minDistance:%f, singleShot:%d, horizontalAccuracy:%d, powerRequirement:%d \n", + criteria.valid_mask, criteria.action, criteria.min_interval, criteria.min_distance, criteria.recurrence_type, criteria.preferred_horizontal_accuracy, + criteria.preferred_power_consumption ); + ulp_msg_update_criteria *msg( + new ulp_msg_update_criteria(&loc_eng_data,criteria)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q + , msg, loc_eng_free_msg); + ret_val = 0; + }else + { + ret_val = -1; + } + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_ulp_phone_context_settings_update + +DESCRIPTION + This is used to inform the ULP module of phone settings changes carried out + by the users +DEPENDENCIES + N/A + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ + +int loc_eng_ulp_phone_context_settings_update(loc_eng_data_s_type &loc_eng_data, + UlpPhoneContextSettings *settings) +{ + ENTRY_LOG(); + int ret_val = -1; + + LOC_LOGD("loc_eng_ulp_phone_context_settings: context_type - 0x%x is_agps_enabled - %d " + "is_battery_charging %d ,is_gps_enabled %d, is_network_position_available %d," + "is_wifi_setting_enabled %d, is_agps_setting_enabled %d, is_enh_location_services_enabled %d\n", + settings->context_type ,settings->is_agps_enabled,settings->is_battery_charging, + settings->is_gps_enabled, settings->is_network_position_available, + settings->is_wifi_setting_enabled, settings->is_agps_enabled, + settings->is_enh_location_services_enabled ); + + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + ulp_msg_inject_phone_context_settings *msg + (new ulp_msg_inject_phone_context_settings(&loc_eng_data, *settings)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q, msg, loc_eng_free_msg); + ret_val = 0; + } + + // Send battery information to modem for processing. + if(settings->context_type & ULP_PHONE_CONTEXT_BATTERY_CHARGING_STATE) + { + loc_eng_msg_ext_power_config *msg(new loc_eng_msg_ext_power_config(&loc_eng_data, settings->is_battery_charging)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, msg, loc_eng_free_msg); + } EXIT_LOG(%d, ret_val); return ret_val; } -#endif +/*=========================================================================== +FUNCTION loc_eng_ulp_network_init + +DESCRIPTION + Initialize the ULP network interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_ulp_phone_context_init(loc_eng_data_s_type &loc_eng_data,UlpPhoneContextCallbacks *callback) +{ + ENTRY_LOG(); + loc_eng_data.ulp_phone_context_req_cb = callback->ulp_request_phone_context_cb ; + int ret_val =0; + EXIT_LOG(%d, ret_val); + return ret_val; +} + +/*=========================================================================== +FUNCTION loc_eng_ulp_network_init + +DESCRIPTION + Initialize the ULP network interface. + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_ulp_network_init(loc_eng_data_s_type &loc_eng_data, + UlpNetworkLocationCallbacks *callbacks) +{ + ENTRY_LOG_CALLFLOW(); + loc_eng_data.ulp_network_callback = callbacks->ulp_network_location_request_cb; + int ret_val =0; + EXIT_LOG(%d, ret_val); + return ret_val; +} + + +/*=========================================================================== +FUNCTION loc_eng_ulp_send_network_position + +DESCRIPTION + Ulp send data + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_ulp_send_network_position(loc_eng_data_s_type &loc_eng_data, + UlpNetworkPositionReport *position_report) +{ + ENTRY_LOG(); + int ret_val = 0; + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + ulp_msg_inject_network_position *msg + (new ulp_msg_inject_network_position(&loc_eng_data, *position_report)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q + , msg, loc_eng_free_msg); + ret_val = 0; + }else + { + ret_val = -1; + } + EXIT_LOG(%d, ret_val); + return ret_val; +} +/*=========================================================================== +FUNCTION loc_eng_read_config + +DESCRIPTION + Initiates the reading of the gps config file stored in /etc dir + +DEPENDENCIES + None + +RETURN VALUE + 0: success + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_read_config(void) +{ + ENTRY_LOG_CALLFLOW(); + if(gpsConfigAlreadyRead == false) + { + // Initialize our defaults before reading of configuration file overwrites them. + loc_default_parameters(); + // Ee only want to parse the conf file once. This is a good place to ensure that. + // In fact one day the conf file should go into context. + UTIL_READ_CONF(GPS_CONF_FILE, loc_parameter_table); + gpsConfigAlreadyRead = true; + } else { + LOC_LOGV("GPS Config file has already been read\n"); + } + + EXIT_LOG(%d, 0); + return 0; +} + diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h old mode 100755 new mode 100644 index 73578ec8..e1cf95cc --- a/loc_api/libloc_api_50001/loc_eng.h +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2009-2012 Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -36,6 +36,7 @@ extern "C" { // Uncomment to keep all LOG messages (LOGD, LOGI, LOGV, etc.) #define MAX_NUM_ATL_CONNECTIONS 2 + // Define boolean type to be used by libgps on loc api module typedef unsigned char boolean; @@ -67,16 +68,27 @@ typedef unsigned char boolean; #define FAILURE FALSE #define INVALID_ATL_CONNECTION_HANDLE -1 -#define MAX_APN_LEN 100 -#define MAX_URL_LEN 256 -#define smaller_of(a, b) (((a) > (b)) ? (b) : (a)) - enum loc_mute_session_e_type { LOC_MUTE_SESS_NONE = 0, LOC_MUTE_SESS_WAIT, LOC_MUTE_SESS_IN_SESSION }; +struct LocEngContext { + // Data variables used by deferred action thread + const void* deferred_q; + const void* ulp_q; + const pthread_t deferred_action_thread; + static LocEngContext* get(gps_create_thread threadCreator); + void drop(); + static pthread_mutex_t lock; + static pthread_cond_t cond; +private: + int counter; + static LocEngContext *me; + LocEngContext(gps_create_thread threadCreator); +}; + // Module data typedef struct { @@ -89,6 +101,8 @@ typedef struct gps_ni_notify_callback ni_notify_cb; gps_acquire_wakelock acquire_wakelock_cb; gps_release_wakelock release_wakelock_cb; + ulp_network_location_request ulp_network_callback; + ulp_request_phone_context ulp_phone_context_req_cb; boolean intermediateFix; AGpsStatusValue agps_status; // used to defer stopping the GPS engine until AGPS data calls are done @@ -97,11 +111,10 @@ typedef struct loc_eng_xtra_data_s_type xtra_module_data; loc_eng_ni_data_s_type loc_eng_ni_data; - boolean navigating; - // AGPS state machines AgpsStateMachine* agnss_nif; AgpsStateMachine* internet_nif; + AgpsStateMachine* wifi_nif; // GPS engine status GpsStatusValue engine_status; @@ -112,8 +125,6 @@ typedef struct void* context; - loc_eng_msg_position_mode position_mode; - // For muting session broadcast loc_mute_session_e_type mute_session_state; @@ -127,12 +138,47 @@ typedef struct int mpc_host_set; char mpc_host_buf[101]; int mpc_port_buf; + bool ulp_initialized; } loc_eng_data_s_type; +#include "ulp.h" + +/* GPS.conf support */ +typedef struct loc_gps_cfg_s +{ + unsigned long INTERMEDIATE_POS; + unsigned long ACCURACY_THRES; + unsigned long ENABLE_WIPER; + unsigned long SUPL_VER; + unsigned long CAPABILITIES; + uint8_t GYRO_BIAS_RANDOM_WALK_VALID; + double GYRO_BIAS_RANDOM_WALK; + unsigned long SENSOR_ACCEL_BATCHES_PER_SEC; + unsigned long SENSOR_ACCEL_SAMPLES_PER_BATCH; + unsigned long SENSOR_GYRO_BATCHES_PER_SEC; + unsigned long SENSOR_GYRO_SAMPLES_PER_BATCH; + unsigned long SENSOR_CONTROL_MODE; + unsigned long SENSOR_USAGE; + unsigned long QUIPC_ENABLED; + unsigned long LPP_PROFILE; + unsigned long SENSOR_ALGORITHM_CONFIG_MASK; + uint8_t ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID; + double ACCEL_RANDOM_WALK_SPECTRAL_DENSITY; + uint8_t ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID; + double ANGLE_RANDOM_WALK_SPECTRAL_DENSITY; + uint8_t RATE_RANDOM_WALK_SPECTRAL_DENSITY_VALID; + double RATE_RANDOM_WALK_SPECTRAL_DENSITY; + uint8_t VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_VALID; + double VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY; +} loc_gps_cfg_s_type; + +extern loc_gps_cfg_s_type gps_conf; int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, - LOC_API_ADAPTER_EVENT_MASK_T event); + LOC_API_ADAPTER_EVENT_MASK_T event, + void (*loc_external_msg_sender) (void*, void*)); +int loc_eng_ulp_init(loc_eng_data_s_type &loc_eng_data, const ulpInterface * loc_eng_ulpInf); int loc_eng_start(loc_eng_data_s_type &loc_eng_data); int loc_eng_stop(loc_eng_data_s_type &loc_eng_data); void loc_eng_cleanup(loc_eng_data_s_type &loc_eng_data); @@ -145,29 +191,19 @@ int loc_eng_inject_location(loc_eng_data_s_type &loc_eng_data, void loc_eng_delete_aiding_data(loc_eng_data_s_type &loc_eng_data, GpsAidingData f); int loc_eng_set_position_mode(loc_eng_data_s_type &loc_eng_data, - LocPositionMode mode, GpsPositionRecurrence recurrence, - uint32_t min_interval, uint32_t preferred_accuracy, - uint32_t preferred_time); + LocPosMode ¶ms); const void* loc_eng_get_extension(loc_eng_data_s_type &loc_eng_data, const char* name); -#ifdef QCOM_FEATURE_ULP int loc_eng_update_criteria(loc_eng_data_s_type &loc_eng_data, UlpLocationCriteria criteria); -#endif + void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbacks); -#ifdef QCOM_FEATURE_IPV6 int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType, const char* apn, AGpsBearerType bearerType); int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType); int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data, AGpsType agpsType); -#else -int loc_eng_agps_open(loc_eng_data_s_type &loc_eng_data, const char* apn); -int loc_eng_agps_closed(loc_eng_data_s_type &loc_eng_data); -int loc_eng_agps_open_failed(loc_eng_data_s_type &loc_eng_data); -#endif - int loc_eng_set_server_proxy(loc_eng_data_s_type &loc_eng_data, LocServerType type, const char *hostname, int port); @@ -196,7 +232,15 @@ extern void loc_eng_ni_request_handler(loc_eng_data_s_type &loc_eng_data, const GpsNiNotification *notif, const void* passThrough); extern void loc_eng_ni_reset_on_engine_restart(loc_eng_data_s_type &loc_eng_data); +int loc_eng_ulp_network_init(loc_eng_data_s_type &loc_eng_data, UlpNetworkLocationCallbacks *callbacks); +int loc_eng_ulp_phone_context_settings_update(loc_eng_data_s_type &loc_eng_data, + UlpPhoneContextSettings *settings); +int loc_eng_ulp_phone_context_init(loc_eng_data_s_type &loc_eng_data, + UlpPhoneContextCallbacks *callback); +int loc_eng_ulp_send_network_position(loc_eng_data_s_type &loc_eng_data, + UlpNetworkPositionReport *position_report); +int loc_eng_read_config(void); #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/loc_api/libloc_api_50001/loc_eng_agps.cpp b/loc_api/libloc_api_50001/loc_eng_agps.cpp old mode 100755 new mode 100644 index 07475680..e9524d57 --- a/loc_api/libloc_api_50001/loc_eng_agps.cpp +++ b/loc_api/libloc_api_50001/loc_eng_agps.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -87,7 +87,7 @@ const int Notification::BROADCAST_INACTIVE = 0x80000002; //====================================================================== -// Subscriber: BITSubscriber / ATLSubscriber +// Subscriber: BITSubscriber / ATLSubscriber / WIFISubscriber //====================================================================== bool Subscriber::forMe(Notification ¬ification) { @@ -120,14 +120,17 @@ bool BITSubscriber::notifyRsrcStatus(Notification ¬ification) case RSRC_UNSUBSCRIBE: case RSRC_RELEASED: loc_eng_dmn_conn_loc_api_server_data_conn( + LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, GPSONE_LOC_API_IF_RELEASE_SUCCESS); break; case RSRC_DENIED: loc_eng_dmn_conn_loc_api_server_data_conn( + LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, GPSONE_LOC_API_IF_FAILURE); break; case RSRC_GRANTED: loc_eng_dmn_conn_loc_api_server_data_conn( + LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, GPSONE_LOC_API_IF_REQUEST_SUCCESS); break; default: @@ -150,20 +153,56 @@ bool ATLSubscriber::notifyRsrcStatus(Notification ¬ification) ((LocApiAdapter*)mLocAdapter)->atlCloseStatus(ID, 1); break; case RSRC_DENIED: + { + AGpsType type = mBackwardCompatibleMode ? + AGPS_TYPE_INVALID : mStateMachine->getType(); ((LocApiAdapter*)mLocAdapter)->atlOpenStatus(ID, 0, (char*)mStateMachine->getAPN(), -#ifdef QCOM_FEATURE_IPV6 mStateMachine->getBearer(), -#endif - mStateMachine->getType()); + type); + } break; case RSRC_GRANTED: + { + AGpsType type = mBackwardCompatibleMode ? + AGPS_TYPE_INVALID : mStateMachine->getType(); ((LocApiAdapter*)mLocAdapter)->atlOpenStatus(ID, 1, (char*)mStateMachine->getAPN(), -#ifdef QCOM_FEATURE_IPV6 mStateMachine->getBearer(), -#endif - mStateMachine->getType()); + type); + } + break; + default: + notify = false; + } + } + + return notify; +} + +bool WIFISubscriber::notifyRsrcStatus(Notification ¬ification) +{ + bool notify = forMe(notification); + + if (notify) { + switch(notification.rsrcStatus) + { + case RSRC_UNSUBSCRIBE: + break; + case RSRC_RELEASED: + loc_eng_dmn_conn_loc_api_server_data_conn( + senderId, + GPSONE_LOC_API_IF_RELEASE_SUCCESS); + break; + case RSRC_DENIED: + loc_eng_dmn_conn_loc_api_server_data_conn( + senderId, + GPSONE_LOC_API_IF_FAILURE); + break; + case RSRC_GRANTED: + loc_eng_dmn_conn_loc_api_server_data_conn( + senderId, + GPSONE_LOC_API_IF_REQUEST_SUCCESS); break; default: notify = false; @@ -276,23 +315,25 @@ AgpsState* AgpsPendingState::onRsrcEvent(AgpsRsrcStatus event, void* data) Subscriber* subscriber = (Subscriber*) data; if (subscriber->waitForCloseComplete()) { subscriber->setInactive(); - if (!mStateMachine->hasActiveSubscribers()) { - // no more subscribers, move to RELEASED state - nextState = mReleasingState; - } } else { // auto notify this subscriber of the unsubscribe Notification notification(subscriber, event, true); mStateMachine->notifySubscribers(notification); + } - // now check if there is any subscribers left - if (!mStateMachine->hasSubscribers()) { - // no more subscribers, move to RELEASED state - nextState = mReleasedState; + // now check if there is any subscribers left + if (!mStateMachine->hasSubscribers()) { + // no more subscribers, move to RELEASED state + nextState = mReleasedState; - // tell connecivity service we can release NIF - mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); - } + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); + } else if (!mStateMachine->hasActiveSubscribers()) { + // only inactive subscribers, move to RELEASING state + nextState = mReleasingState; + + // tell connecivity service we can release NIF + mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); } } break; @@ -381,13 +422,13 @@ AgpsState* AgpsAcquiredState::onRsrcEvent(AgpsRsrcStatus event, void* data) // now check if there is any subscribers left if (!mStateMachine->hasSubscribers()) { // no more subscribers, move to RELEASED state - nextState = mReleasingState; + nextState = mReleasedState; // tell connecivity service we can release NIF mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); } else if (!mStateMachine->hasActiveSubscribers()) { - // no more subscribers, move to RELEASED state - nextState = mReleasedState; + // only inactive subscribers, move to RELEASING state + nextState = mReleasingState; // tell connecivity service we can release NIF mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); @@ -469,21 +510,14 @@ AgpsState* AgpsReleasingState::onRsrcEvent(AgpsRsrcStatus event, void* data) // now check if there is any subscribers left if (!mStateMachine->hasSubscribers()) { - // no more subscribers, move to RELEASED state - nextState = mReleasingState; - - // tell connecivity service we can release NIF - mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); - } else if (!mStateMachine->hasActiveSubscribers()) { // no more subscribers, move to RELEASED state nextState = mReleasedState; - - // tell connecivity service we can release NIF - mStateMachine->sendRsrcRequest(GPS_RELEASE_AGPS_DATA_CONN); } } break; + case RSRC_DENIED: + // A race condition subscriber unsubscribes before AFW denies resource. case RSRC_RELEASED: { nextState = mAcquiredState; @@ -503,7 +537,6 @@ AgpsState* AgpsReleasingState::onRsrcEvent(AgpsRsrcStatus event, void* data) break; case RSRC_GRANTED: - case RSRC_DENIED: default: LOC_LOGE("%s: unrecognized event %d", whoami(), event); // no state change. @@ -520,11 +553,13 @@ AgpsState* AgpsReleasingState::onRsrcEvent(AgpsRsrcStatus event, void* data) //====================================================================== AgpsStateMachine::AgpsStateMachine(void (*servicer)(AGpsStatus* status), - AGpsType type) : + AGpsType type, + bool enforceSingleSubscriber) : mServicer(servicer), mType(type), mStatePtr(new AgpsReleasedState(this)), mAPN(NULL), - mAPNLen(0) + mAPNLen(0), + mEnforceSingleSubscriber(enforceSingleSubscriber) { linked_list_init(&mSubscribers); @@ -643,7 +678,7 @@ void AgpsStateMachine::addSubscriber(Subscriber* subscriber) const void AgpsStateMachine::sendRsrcRequest(AGpsStatusValue action) const { Subscriber* s = NULL; - Notification notification(Notification::BROADCAST_ALL); + Notification notification(Notification::BROADCAST_ACTIVE); linked_list_search(mSubscribers, (void**)&s, hasSubscriber, (void*)¬ification, false); @@ -653,20 +688,15 @@ void AgpsStateMachine::sendRsrcRequest(AGpsStatusValue action) const nifRequest.type = mType; nifRequest.status = action; -#ifdef QCOM_FEATURE_IPV6 if (s == NULL) { nifRequest.ipv4_addr = INADDR_NONE; nifRequest.ipv6_addr[0] = 0; + nifRequest.ssid[0] = '\0'; + nifRequest.password[0] = '\0'; } else { s->setIPAddresses(nifRequest.ipv4_addr, (char*)nifRequest.ipv6_addr); + s->setWifiInfo(nifRequest.ssid, nifRequest.password); } -#else - if (s == NULL) { - nifRequest.ipaddr = INADDR_NONE; - } else { - nifRequest.ipaddr = s->ID; - } -#endif CALLBACK_LOG_CALLFLOW("agps_cb", %s, loc_get_agps_status_name(action)); (*mServicer)(&nifRequest); @@ -675,7 +705,12 @@ void AgpsStateMachine::sendRsrcRequest(AGpsStatusValue action) const void AgpsStateMachine::subscribeRsrc(Subscriber *subscriber) { - mStatePtr = mStatePtr->onRsrcEvent(RSRC_SUBSCRIBE, (void*)subscriber); + if (mEnforceSingleSubscriber && hasSubscribers()) { + Notification notification(Notification::BROADCAST_ALL, RSRC_DENIED, true); + notifySubscriber(¬ification, subscriber); + } else { + mStatePtr = mStatePtr->onRsrcEvent(RSRC_SUBSCRIBE, (void*)subscriber); + } } bool AgpsStateMachine::unsubscribeRsrc(Subscriber *subscriber) diff --git a/loc_api/libloc_api_50001/loc_eng_agps.h b/loc_api/libloc_api_50001/loc_eng_agps.h old mode 100755 new mode 100644 index 1fd0f450..a0873d04 --- a/loc_api/libloc_api_50001/loc_eng_agps.h +++ b/loc_api/libloc_api_50001/loc_eng_agps.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -37,6 +37,7 @@ #include #include #include +#include "loc_eng_msg.h" // forward declaration class AgpsStateMachine; @@ -149,23 +150,20 @@ class AgpsStateMachine { char* mAPN; // for convenience, we don't do strlen each time. unsigned int mAPNLen; -#ifdef QCOM_FEATURE_IPV6 // bear AGpsBearerType mBearer; -#endif // ipv4 address for routing + bool mEnforceSingleSubscriber; public: - AgpsStateMachine(void (*servicer)(AGpsStatus* status), AGpsType type); + AgpsStateMachine(void (*servicer)(AGpsStatus* status), AGpsType type, bool enforceSingleSubscriber); virtual ~AgpsStateMachine(); // self explanatory methods below void setAPN(const char* apn, unsigned int len); inline const char* getAPN() const { return (const char*)mAPN; } -#ifdef QCOM_FEATURE_IPV6 inline void setBearer(AGpsBearerType bearer) { mBearer = bearer; } inline AGpsBearerType getBearer() const { return mBearer; } -#endif inline AGpsType getType() const { return (AGpsType)mType; } // someone, a ATL client or BIT, is asking for NIF @@ -206,6 +204,7 @@ struct Subscriber { inline virtual ~Subscriber() {} virtual void setIPAddresses(int &v4, char* v6) = 0; + inline virtual void setWifiInfo(char* ssid, char* password) {} inline virtual bool equals(const Subscriber *s) const { return ID == s->ID; } @@ -256,10 +255,13 @@ private: // ATLSubscriber, created with requests from ATL struct ATLSubscriber : public Subscriber { const LocApiAdapter* mLocAdapter; + const bool mBackwardCompatibleMode; inline ATLSubscriber(const int id, const AgpsStateMachine* stateMachine, - const LocApiAdapter* adapter) : - Subscriber(id, stateMachine), mLocAdapter(adapter) {} + const LocApiAdapter* adapter, + const bool compatibleMode) : + Subscriber(id, stateMachine), mLocAdapter(adapter), + mBackwardCompatibleMode(compatibleMode){} virtual bool notifyRsrcStatus(Notification ¬ification); inline virtual void setIPAddresses(int &v4, char* v6) @@ -267,7 +269,55 @@ struct ATLSubscriber : public Subscriber { inline virtual Subscriber* clone() { - return new ATLSubscriber(ID, mStateMachine, mLocAdapter); + return new ATLSubscriber(ID, mStateMachine, mLocAdapter, + mBackwardCompatibleMode); + } +}; + +// WIFISubscriber, created with requests from MSAPM or QuIPC +struct WIFISubscriber : public Subscriber { + char * mSSID; + char * mPassword; + loc_if_req_sender_id_e_type senderId; + bool mIsInactive; + inline WIFISubscriber(const AgpsStateMachine* stateMachine, + char * ssid, char * password, loc_if_req_sender_id_e_type sender_id) : + Subscriber(sender_id, stateMachine), + mSSID(NULL == ssid ? NULL : new char[SSID_BUF_SIZE]), + mPassword(NULL == password ? NULL : new char[SSID_BUF_SIZE]), + senderId(sender_id) + { + if (NULL != mSSID) + strlcpy(mSSID, ssid, SSID_BUF_SIZE); + if (NULL != mPassword) + strlcpy(mPassword, password, SSID_BUF_SIZE); + mIsInactive = false; + } + + virtual bool notifyRsrcStatus(Notification ¬ification); + + inline virtual void setIPAddresses(int &v4, char* v6) {} + + inline virtual void setWifiInfo(char* ssid, char* password) + { + if (NULL != mSSID) + strlcpy(ssid, mSSID, SSID_BUF_SIZE); + else + ssid[0] = '\0'; + if (NULL != mPassword) + strlcpy(password, mPassword, SSID_BUF_SIZE); + else + password[0] = '\0'; + } + + inline virtual bool waitForCloseComplete() { return true; } + + inline virtual void setInactive() { mIsInactive = true; } + inline virtual bool isInactive() { return mIsInactive; } + + virtual Subscriber* clone() + { + return new WIFISubscriber(mStateMachine, mSSID, mPassword, senderId); } }; diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp old mode 100755 new mode 100644 index f2f9a501..2bb2d810 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -33,23 +33,54 @@ #include #include #include +#include +#include +#include #include "log_util.h" #include "loc_eng_dmn_conn_glue_msg.h" #include "loc_eng_dmn_conn_handler.h" #include "loc_eng_dmn_conn.h" +#include "loc_eng_msg.h" static int loc_api_server_msgqid; static int loc_api_resp_msgqid; +static int quipc_msgqid; +static int msapm_msgqid; static const char * global_loc_api_q_path = GPSONE_LOC_API_Q_PATH; static const char * global_loc_api_resp_q_path = GPSONE_LOC_API_RESP_Q_PATH; +static const char * global_quipc_ctrl_q_path = QUIPC_CTRL_Q_PATH; +static const char * global_msapm_ctrl_q_path = MSAPM_CTRL_Q_PATH; static int loc_api_server_proc_init(void *context) { loc_api_server_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_q_path, O_RDWR); + //change mode/group for the global_loc_api_q_path pipe + int result = chmod (global_loc_api_q_path, 0660); + if (result != 0) + { + LOC_LOGE("failed to change mode for %s, error = %s\n", global_loc_api_q_path, strerror(errno)); + } + + struct group * gps_group = getgrnam("gps"); + if (gps_group != NULL) + { + result = chown (global_loc_api_q_path, -1, gps_group->gr_gid); + if (result != 0) + { + LOC_LOGE("chown for pipe failed, gid = %d, result = %d, error = %s\n", gps_group->gr_gid, result, strerror(errno)); + } + } + else + { + LOC_LOGE("getgrnam for gps failed, error code = %d\n", errno); + } + loc_api_resp_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_resp_q_path, O_RDWR); + quipc_msgqid = loc_eng_dmn_conn_glue_msgget(global_quipc_ctrl_q_path, O_RDWR); + msapm_msgqid = loc_eng_dmn_conn_glue_msgget(global_msapm_ctrl_q_path , O_RDWR); LOC_LOGD("%s:%d] loc_api_server_msgqid = %d\n", __func__, __LINE__, loc_api_server_msgqid); return 0; @@ -80,6 +111,7 @@ static int loc_api_server_proc(void *context) LOC_LOGD("%s:%d] %d listening on %s...\n", __func__, __LINE__, cnt, (char *) context); length = loc_eng_dmn_conn_glue_msgrcv(loc_api_server_msgqid, p_cmsgbuf, sz); if (length <= 0) { + free(p_cmsgbuf); LOC_LOGE("%s:%d] fail receiving msg from gpsone_daemon, retry later\n", __func__, __LINE__); usleep(1000); return 0; @@ -114,6 +146,8 @@ static int loc_api_server_proc_post(void *context) LOC_LOGD("%s:%d]\n", __func__, __LINE__); loc_eng_dmn_conn_glue_msgremove( global_loc_api_q_path, loc_api_server_msgqid); loc_eng_dmn_conn_glue_msgremove( global_loc_api_resp_q_path, loc_api_resp_msgqid); + loc_eng_dmn_conn_glue_msgremove( global_quipc_ctrl_q_path, quipc_msgqid); + loc_eng_dmn_conn_glue_msgremove( global_msapm_ctrl_q_path, msapm_msgqid); return 0; } @@ -165,16 +199,40 @@ int loc_eng_dmn_conn_loc_api_server_join(void) return 0; } -int loc_eng_dmn_conn_loc_api_server_data_conn(int status) { +int loc_eng_dmn_conn_loc_api_server_data_conn(int sender_id, int status) { struct ctrl_msgbuf cmsgbuf; + LOC_LOGD("%s:%d] quipc_msgqid = %d\n", __func__, __LINE__, quipc_msgqid); cmsgbuf.ctrl_type = GPSONE_LOC_API_RESPONSE; cmsgbuf.cmsg.cmsg_response.result = status; - LOC_LOGD("%s:%d] status = %d",__func__, __LINE__, status); - if (loc_eng_dmn_conn_glue_msgsnd(loc_api_resp_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { - LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); - return -1; + switch (sender_id) { + case LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC: { + LOC_LOGD("%s:%d] sender_id = LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC", __func__, __LINE__); + if (loc_eng_dmn_conn_glue_msgsnd(quipc_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { + LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); + return -1; + } + break; + } + case LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM: { + LOC_LOGD("%s:%d] sender_id = LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM", __func__, __LINE__); + if (loc_eng_dmn_conn_glue_msgsnd(msapm_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { + LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); + return -1; + } + break; + } + case LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON: { + LOC_LOGD("%s:%d] sender_id = LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON", __func__, __LINE__); + if (loc_eng_dmn_conn_glue_msgsnd(loc_api_resp_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { + LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); + return -1; + } + break; + } + default: { + LOC_LOGD("%s:%d] invalid sender ID!", __func__, __LINE__); + } } return 0; - } diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h old mode 100755 new mode 100644 index 414fd553..f6692487 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn.h +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -35,11 +35,15 @@ #define GPSONE_LOC_API_Q_PATH "/data/misc/gpsone_d/gpsone_loc_api_q" #define GPSONE_LOC_API_RESP_Q_PATH "/data/misc/gpsone_d/gpsone_loc_api_resp_q" +#define QUIPC_CTRL_Q_PATH "/data/misc/gpsone_d/quipc_ctrl_q" +#define MSAPM_CTRL_Q_PATH "/data/misc/gpsone_d/msapm_ctrl_q" #else #define GPSONE_LOC_API_Q_PATH "/tmp/gpsone_loc_api_q" #define GPSONE_LOC_API_RESP_Q_PATH "/tmp/gpsone_loc_api_resp_q" +#define QUIPC_CTRL_Q_PATH "/tmp/quipc_ctrl_q" +#define MSAPM_CTRL_Q_PATH "/tmp/msapm_ctrl_q" #endif @@ -47,7 +51,7 @@ int loc_eng_dmn_conn_loc_api_server_launch(thelper_create_thread create_thread const char * loc_api_q_path, const char * ctrl_q_path, void *agps_handle); int loc_eng_dmn_conn_loc_api_server_unblock(void); int loc_eng_dmn_conn_loc_api_server_join(void); -int loc_eng_dmn_conn_loc_api_server_data_conn(int); +int loc_eng_dmn_conn_loc_api_server_data_conn(int, int); #endif /* LOC_ENG_DATA_SERVER_H */ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_msg.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp old mode 100755 new mode 100644 index fd15f001..6077b721 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -47,15 +47,79 @@ int loc_eng_dmn_conn_loc_api_server_if_request_handler(struct ctrl_msgbuf *pmsg, return 1; } - loc_eng_msg_request_bit *msg( - new loc_eng_msg_request_bit(loc_api_handle, - pmsg->cmsg.cmsg_if_request.is_supl, - pmsg->cmsg.cmsg_if_request.ipv4_addr, - (char*)pmsg->cmsg.cmsg_if_request.ipv6_addr)); - loc_eng_msg_sender(loc_api_handle, msg); + if (NULL != loc_api_handle) { + loc_if_req_type_e_type type; + switch (pmsg->cmsg.cmsg_if_request.type) { + case IF_REQUEST_TYPE_SUPL: + { + LOC_LOGD("IF_REQUEST_TYPE_SUPL"); + type = LOC_ENG_IF_REQUEST_TYPE_SUPL; + break; + } + case IF_REQUEST_TYPE_WIFI: + { + LOC_LOGD("IF_REQUEST_TYPE_WIFI"); + type = LOC_ENG_IF_REQUEST_TYPE_WIFI; + break; + } + case IF_REQUEST_TYPE_ANY: + { + LOC_LOGD("IF_REQUEST_TYPE_ANY"); + type = LOC_ENG_IF_REQUEST_TYPE_ANY; + break; + } + default: + { + LOC_LOGD("invalid IF_REQUEST_TYPE!"); + return -1; + } + } + switch (pmsg->cmsg.cmsg_if_request.sender_id) { + case IF_REQUEST_SENDER_ID_QUIPC: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_QUIPC"); + loc_eng_msg_request_wifi *msg( + new loc_eng_msg_request_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } + case IF_REQUEST_SENDER_ID_MSAPM: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_MSAPM"); + loc_eng_msg_request_wifi *msg( + new loc_eng_msg_request_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } + case IF_REQUEST_SENDER_ID_GPSONE_DAEMON: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_GPSONE_DAEMON"); + loc_eng_msg_request_bit *msg( + new loc_eng_msg_request_bit(loc_api_handle, + type, + pmsg->cmsg.cmsg_if_request.ipv4_addr, + (char*)pmsg->cmsg.cmsg_if_request.ipv6_addr)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } + default: + { + LOC_LOGD("invalid IF_REQUEST_SENDER_ID!"); + return -1; + } + } + } #else - loc_eng_dmn_conn_loc_api_server_data_conn(GPSONE_LOC_API_IF_REQUEST_SUCCESS); + loc_eng_dmn_conn_loc_api_server_data_conn(LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, GPSONE_LOC_API_IF_REQUEST_SUCCESS); #endif return 0; } @@ -64,14 +128,76 @@ int loc_eng_dmn_conn_loc_api_server_if_release_handler(struct ctrl_msgbuf *pmsg, { LOC_LOGD("%s:%d]\n", __func__, __LINE__); #ifndef DEBUG_DMN_LOC_API - loc_eng_msg_release_bit *msg( + loc_if_req_type_e_type type; + switch (pmsg->cmsg.cmsg_if_request.type) { + case IF_REQUEST_TYPE_SUPL: + { + LOC_LOGD("IF_REQUEST_TYPE_SUPL"); + type = LOC_ENG_IF_REQUEST_TYPE_SUPL; + break; + } + case IF_REQUEST_TYPE_WIFI: + { + LOC_LOGD("IF_REQUEST_TYPE_WIFI"); + type = LOC_ENG_IF_REQUEST_TYPE_WIFI; + break; + } + case IF_REQUEST_TYPE_ANY: + { + LOC_LOGD("IF_REQUEST_TYPE_ANY"); + type = LOC_ENG_IF_REQUEST_TYPE_ANY; + break; + } + default: + { + LOC_LOGD("invalid IF_REQUEST_TYPE!"); + return -1; + } + } + switch (pmsg->cmsg.cmsg_if_request.sender_id) { + case IF_REQUEST_SENDER_ID_QUIPC: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_QUIPC"); + loc_eng_msg_release_wifi *msg( + new loc_eng_msg_release_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } + case IF_REQUEST_SENDER_ID_MSAPM: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_MSAPM"); + loc_eng_msg_release_wifi *msg( + new loc_eng_msg_release_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } + case IF_REQUEST_SENDER_ID_GPSONE_DAEMON: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_GPSONE_DAEMON"); + loc_eng_msg_release_bit *msg( new loc_eng_msg_release_bit(loc_api_handle, - pmsg->cmsg.cmsg_if_request.is_supl, + type, pmsg->cmsg.cmsg_if_request.ipv4_addr, (char*)pmsg->cmsg.cmsg_if_request.ipv6_addr)); loc_eng_msg_sender(loc_api_handle, msg); + break; + } + default: + { + LOC_LOGD("invalid IF_REQUEST_SENDER_ID!"); + return -1; + } + } #else - loc_eng_dmn_conn_loc_api_server_data_conn(GPSONE_LOC_API_IF_RELEASE_SUCCESS); + loc_eng_dmn_conn_loc_api_server_data_conn(LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, GPSONE_LOC_API_IF_RELEASE_SUCCESS); #endif return 0; } diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h old mode 100755 new mode 100644 index 833e971b..7aa22bfb --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -32,6 +32,9 @@ #include #include +//for SSID_BUF_SIZE +#include + enum { /* 0x0 - 0xEF is reserved for daemon internal */ GPSONE_LOC_API_IF_REQUEST = 0xF0, @@ -55,10 +58,26 @@ struct ctrl_msg_unblock { int reserved; }; +typedef enum { + IF_REQUEST_TYPE_SUPL = 0, + IF_REQUEST_TYPE_WIFI, + IF_REQUEST_TYPE_ANY +} ctrl_if_req_type_e_type; + +typedef enum { + IF_REQUEST_SENDER_ID_QUIPC = 0, + IF_REQUEST_SENDER_ID_MSAPM, + IF_REQUEST_SENDER_ID_GPSONE_DAEMON, + IF_REQUEST_SENDER_ID_MODEM +} ctrl_if_req_sender_id_e_type; + struct ctrl_msg_if_request { - unsigned is_supl; /* 1: use Android SUPL connection; 0: use Android default internet connection */ + ctrl_if_req_type_e_type type; + ctrl_if_req_sender_id_e_type sender_id; unsigned long ipv4_addr; unsigned char ipv6_addr[16]; + char ssid[SSID_BUF_SIZE]; + char password[SSID_BUF_SIZE]; }; /* do not change this structure */ diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.c old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_thread_helper.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_log.cpp b/loc_api/libloc_api_50001/loc_eng_log.cpp old mode 100755 new mode 100644 index d813cd65..843f558f --- a/loc_api/libloc_api_50001/loc_eng_log.cpp +++ b/loc_api/libloc_api_50001/loc_eng_log.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012 Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -31,7 +31,6 @@ #define LOG_TAG "LocSvc_eng" #include "hardware/gps.h" -#include "loc.h" #include "loc_log.h" #include "loc_eng_log.h" #include "loc_eng_msg_id.h" @@ -88,10 +87,24 @@ static loc_name_val_s_type loc_eng_msgs[] = NAME_VAL( LOC_ENG_MSG_RELEASE_ATL ), NAME_VAL( LOC_ENG_MSG_REQUEST_BIT ), NAME_VAL( LOC_ENG_MSG_RELEASE_BIT ), + NAME_VAL( LOC_ENG_MSG_REQUEST_WIFI ), + NAME_VAL( LOC_ENG_MSG_RELEASE_WIFI ), NAME_VAL( LOC_ENG_MSG_REQUEST_NI ), NAME_VAL( LOC_ENG_MSG_INFORM_NI_RESPONSE ), NAME_VAL( LOC_ENG_MSG_REQUEST_XTRA_DATA ), - NAME_VAL( LOC_ENG_MSG_REQUEST_TIME ) + NAME_VAL( LOC_ENG_MSG_REQUEST_TIME ), + NAME_VAL( LOC_ENG_MSG_EXT_POWER_CONFIG ), + NAME_VAL( LOC_ENG_MSG_REQUEST_POSITION ), + NAME_VAL( LOC_ENG_MSG_REQUEST_PHONE_CONTEXT ), + NAME_VAL( LOC_ENG_MSG_REQUEST_NETWORK_POSIITON ), + NAME_VAL( ULP_MSG_UPDATE_CRITERIA ), + NAME_VAL( ULP_MSG_START_FIX ), + NAME_VAL( ULP_MSG_STOP_FIX ), + NAME_VAL( ULP_MSG_INJECT_PHONE_CONTEXT_SETTINGS ), + NAME_VAL( ULP_MSG_INJECT_NETWORK_POSITION ), + NAME_VAL( ULP_MSG_REPORT_QUIPC_POSITION ), + NAME_VAL( ULP_MSG_REQUEST_COARSE_POSITION ), + NAME_VAL( LOC_ENG_MSG_LPP_CONFIG ) }; static int loc_eng_msgs_num = sizeof(loc_eng_msgs) / sizeof(loc_name_val_s_type); @@ -149,9 +162,8 @@ static loc_name_val_s_type loc_eng_aiding_data_bits[] = NAME_VAL( GPS_DELETE_SVSTEER ), NAME_VAL( GPS_DELETE_SADATA ), NAME_VAL( GPS_DELETE_RTI ), - NAME_VAL( GPS_DELETE_CELLDB_INFO ) -#ifdef QCOM_FEATURE_DELEXT - ,NAME_VAL( GPS_DELETE_ALMANAC_CORR ), + NAME_VAL( GPS_DELETE_CELLDB_INFO ), + NAME_VAL( GPS_DELETE_ALMANAC_CORR ), NAME_VAL( GPS_DELETE_FREQ_BIAS_EST ), NAME_VAL( GPS_DELETE_EPHEMERIS_GLO ), NAME_VAL( GPS_DELETE_ALMANAC_GLO ), @@ -160,7 +172,6 @@ static loc_name_val_s_type loc_eng_aiding_data_bits[] = NAME_VAL( GPS_DELETE_ALMANAC_CORR_GLO ), NAME_VAL( GPS_DELETE_TIME_GPS ), NAME_VAL( GPS_DELETE_TIME_GLO ) -#endif }; static int loc_eng_aiding_data_bit_num = sizeof(loc_eng_aiding_data_bits) / sizeof(loc_name_val_s_type); @@ -172,15 +183,11 @@ const char* loc_get_aiding_data_mask_names(GpsAidingData data) static loc_name_val_s_type loc_eng_agps_types[] = { -#ifdef QCOM_FEATURE_IPV6 NAME_VAL( AGPS_TYPE_INVALID ), NAME_VAL( AGPS_TYPE_ANY ), -#endif NAME_VAL( AGPS_TYPE_SUPL ), - NAME_VAL( AGPS_TYPE_C2K ) -#ifdef QCOM_FEATURE_IPV6 - ,NAME_VAL( AGPS_TYPE_WWAN_ANY ) -#endif + NAME_VAL( AGPS_TYPE_C2K ), + NAME_VAL( AGPS_TYPE_WWAN_ANY ) }; static int loc_eng_agps_type_num = sizeof(loc_eng_agps_types) / sizeof(loc_name_val_s_type); @@ -233,7 +240,7 @@ const char* loc_get_ni_encoding_name(GpsNiEncodingType encoding) return loc_get_name_from_val(loc_eng_ni_encodings, loc_eng_ni_encoding_num, (long) encoding); } -#ifdef QCOM_FEATURE_IPV6 + static loc_name_val_s_type loc_eng_agps_bears[] = { NAME_VAL( AGPS_APN_BEARER_INVALID ), @@ -247,7 +254,6 @@ const char* loc_get_agps_bear_name(AGpsBearerType bearer) { return loc_get_name_from_val(loc_eng_agps_bears, loc_eng_agps_bears_num, (long) bearer); } -#endif static loc_name_val_s_type loc_eng_server_types[] = { diff --git a/loc_api/libloc_api_50001/loc_eng_log.h b/loc_api/libloc_api_50001/loc_eng_log.h old mode 100755 new mode 100644 index eff1593b..e8a82793 --- a/loc_api/libloc_api_50001/loc_eng_log.h +++ b/loc_api/libloc_api_50001/loc_eng_log.h @@ -37,7 +37,7 @@ extern "C" #include #include -#include "loc_eng_msg_id.h" +#include const char* loc_get_gps_status_name(GpsStatusValue gps_status); const char* loc_get_msg_name(int id); @@ -48,9 +48,7 @@ const char* loc_get_agps_type_name(AGpsType type); const char* loc_get_ni_type_name(GpsNiType type); const char* loc_get_ni_response_name(GpsUserResponseType response); const char* loc_get_ni_encoding_name(GpsNiEncodingType encoding); -#ifdef QCOM_FEATURE_IPV6 const char* loc_get_agps_bear_name(AGpsBearerType bear); -#endif const char* loc_get_server_type_name(LocServerType type); const char* loc_get_position_sess_status_name(enum loc_sess_status status); const char* loc_get_agps_status_name(AGpsStatusValue status); diff --git a/loc_api/libloc_api_50001/loc_eng_msg.cpp b/loc_api/libloc_api_50001/loc_eng_msg.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h old mode 100755 new mode 100644 index 41548f09..4a1cae63 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012 Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -35,14 +35,83 @@ #include #include "log_util.h" #include "loc.h" -#include "loc_eng_log.h" +#include #include "loc_eng_msg_id.h" - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ +struct LocPosMode +{ + LocPositionMode mode; + GpsPositionRecurrence recurrence; + uint32_t min_interval; + uint32_t preferred_accuracy; + uint32_t preferred_time; + char credentials[14]; + char provider[8]; + LocPosMode(LocPositionMode m, GpsPositionRecurrence recr, + uint32_t gap, uint32_t accu, uint32_t time, + const char* cred, const char* prov) : + mode(m), recurrence(recr), + min_interval(gap < MIN_POSSIBLE_FIX_INTERVAL ? MIN_POSSIBLE_FIX_INTERVAL : gap), + preferred_accuracy(accu), preferred_time(time) { + memset(credentials, 0, sizeof(credentials)); + memset(provider, 0, sizeof(provider)); + if (NULL != cred) { + memcpy(credentials, cred, sizeof(credentials)-1); + } + if (NULL != prov) { + memcpy(provider, prov, sizeof(provider)-1); + } + } + + LocPosMode() : + mode(LOC_POSITION_MODE_MS_BASED), recurrence(GPS_POSITION_RECURRENCE_PERIODIC), + min_interval(MIN_POSSIBLE_FIX_INTERVAL), preferred_accuracy(50), preferred_time(120000) { + memset(credentials, 0, sizeof(credentials)); + memset(provider, 0, sizeof(provider)); + } + + inline bool equals(const LocPosMode &anotherMode) const + { + return anotherMode.mode == mode && + anotherMode.recurrence == recurrence && + anotherMode.min_interval == min_interval && + anotherMode.preferred_accuracy == preferred_accuracy && + anotherMode.preferred_time == preferred_time && + !strncmp(anotherMode.credentials, credentials, sizeof(credentials)-1) && + !strncmp(anotherMode.provider, provider, sizeof(provider)-1); + } + + inline void logv() const + { + LOC_LOGV ("Position mode: %s\n Position recurrence: %s\n min interval: %d\n preferred accuracy: %d\n preferred time: %d\n credentials: %s provider: %s", + loc_get_position_mode_name(mode), + loc_get_position_recurrence_name(recurrence), + min_interval, + preferred_accuracy, + preferred_time, + credentials, + provider); + } +}; + +typedef enum { + LOC_ENG_IF_REQUEST_TYPE_SUPL = 0, + LOC_ENG_IF_REQUEST_TYPE_WIFI, + LOC_ENG_IF_REQUEST_TYPE_ANY +} loc_if_req_type_e_type; + +typedef enum { + LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC = 0, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM, + LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, + LOC_ENG_IF_REQUEST_SENDER_ID_MODEM, + LOC_ENG_IF_REQUEST_SENDER_ID_UNKNOWN +} loc_if_req_sender_id_e_type; + struct loc_eng_msg { const void* owner; const int msgid; @@ -50,10 +119,12 @@ struct loc_eng_msg { owner(instance), msgid(id) { LOC_LOGV("creating msg %s", loc_get_msg_name(msgid)); + LOC_LOGV("creating msg ox%x", msgid); } virtual ~loc_eng_msg() { LOC_LOGV("deleting msg %s", loc_get_msg_name(msgid)); + LOC_LOGV("deleting msg ox%x", msgid); } }; @@ -67,6 +138,26 @@ struct loc_eng_msg_suple_version : public loc_eng_msg { } }; +struct loc_eng_msg_lpp_config : public loc_eng_msg { + const int lpp_config; + inline loc_eng_msg_lpp_config(void *instance, int profile) : + loc_eng_msg(instance, LOC_ENG_MSG_LPP_CONFIG), + lpp_config(profile) + { + LOC_LOGV("lpp profile: %d", profile); + } +}; + +struct loc_eng_msg_ext_power_config : public loc_eng_msg { + const int isBatteryCharging; + inline loc_eng_msg_ext_power_config(void* instance, int isBattCharging) : + loc_eng_msg(instance, LOC_ENG_MSG_EXT_POWER_CONFIG), + isBatteryCharging(isBattCharging) + { + LOC_LOGV("isBatteryCharging: %d", isBatteryCharging); + } +}; + struct loc_eng_msg_sensor_control_config : public loc_eng_msg { const int sensorsDisabled; inline loc_eng_msg_sensor_control_config(void* instance, int disabled) : @@ -78,12 +169,51 @@ struct loc_eng_msg_sensor_control_config : public loc_eng_msg { }; struct loc_eng_msg_sensor_properties : public loc_eng_msg { + const bool gyroBiasVarianceRandomWalk_valid; const float gyroBiasVarianceRandomWalk; - inline loc_eng_msg_sensor_properties(void* instance, float gyroBiasRandomWalk) : + const bool accelRandomWalk_valid; + const float accelRandomWalk; + const bool angleRandomWalk_valid; + const float angleRandomWalk; + const bool rateRandomWalk_valid; + const float rateRandomWalk; + const bool velocityRandomWalk_valid; + const float velocityRandomWalk; + inline loc_eng_msg_sensor_properties(void* instance, bool gyroBiasRandomWalk_valid, float gyroBiasRandomWalk, + bool accelRandomWalk_valid, float accelRandomWalk, + bool angleRandomWalk_valid, float angleRandomWalk, + bool rateRandomWalk_valid, float rateRandomWalk, + bool velocityRandomWalk_valid, float velocityRandomWalk) : loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_PROPERTIES), - gyroBiasVarianceRandomWalk(gyroBiasRandomWalk) + gyroBiasVarianceRandomWalk_valid(gyroBiasRandomWalk_valid), + gyroBiasVarianceRandomWalk(gyroBiasRandomWalk), + accelRandomWalk_valid(accelRandomWalk_valid), + accelRandomWalk(accelRandomWalk), + angleRandomWalk_valid(angleRandomWalk_valid), + angleRandomWalk(angleRandomWalk), + rateRandomWalk_valid(rateRandomWalk_valid), + rateRandomWalk(rateRandomWalk), + velocityRandomWalk_valid(velocityRandomWalk_valid), + velocityRandomWalk(velocityRandomWalk) { - LOC_LOGV("Gyro Bias Random Walk: %f", gyroBiasRandomWalk); + LOC_LOGV("Sensor properties validity, Gyro Random walk: %d Accel Random Walk: %d " + "Angle Random Walk: %d Rate Random Walk: %d " + "Velocity Random Walk: %d", + gyroBiasRandomWalk_valid, + accelRandomWalk_valid, + angleRandomWalk_valid, + rateRandomWalk_valid, + velocityRandomWalk_valid + ); + LOC_LOGV("Sensor properties, Gyro Random walk: %f Accel Random Walk: %f " + "Angle Random Walk: %f Rate Random Walk: %f " + "Velocity Random Walk: %f", + gyroBiasRandomWalk, + accelRandomWalk, + angleRandomWalk, + rateRandomWalk, + velocityRandomWalk + ); } }; @@ -93,55 +223,40 @@ struct loc_eng_msg_sensor_perf_control_config : public loc_eng_msg { const int accelBatchesPerSec; const int gyroSamplesPerBatch; const int gyroBatchesPerSec; + const int algorithmConfig; inline loc_eng_msg_sensor_perf_control_config(void* instance, int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, - int gyroSamplesPerBatch, int gyroBatchesPerSec) : + int gyroSamplesPerBatch, int gyroBatchesPerSec, + int algorithmConfig) : loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG), controlMode(controlMode), accelSamplesPerBatch(accelSamplesPerBatch), accelBatchesPerSec(accelBatchesPerSec), gyroSamplesPerBatch(gyroSamplesPerBatch), - gyroBatchesPerSec(gyroBatchesPerSec) + gyroBatchesPerSec(gyroBatchesPerSec), + algorithmConfig(algorithmConfig) { LOC_LOGV("Sensor Perf Control Config (performanceControlMode)(%u) " - "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u)\n", + "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u), algorithmConfig(%u)\n", controlMode, accelSamplesPerBatch, accelBatchesPerSec, gyroSamplesPerBatch, - gyroBatchesPerSec + gyroBatchesPerSec, + algorithmConfig ); } }; struct loc_eng_msg_position_mode : public loc_eng_msg { - const LocPositionMode pMode; - const GpsPositionRecurrence pRecurrence; - const uint32_t minInterval; - const uint32_t preferredAccuracy; - const uint32_t preferredTime; - inline loc_eng_msg_position_mode() : - loc_eng_msg(NULL, LOC_ENG_MSG_SET_POSITION_MODE), - pMode(LOC_POSITION_MODE_STANDALONE), - pRecurrence(0), minInterval(0), - preferredAccuracy(0), preferredTime(0) {} + const LocPosMode pMode; inline loc_eng_msg_position_mode(void* instance, - LocPositionMode mode, - GpsPositionRecurrence recurrence, - uint32_t min_interval, - uint32_t preferred_accuracy, - uint32_t preferred_time) : + LocPosMode &mode) : loc_eng_msg(instance, LOC_ENG_MSG_SET_POSITION_MODE), - pMode(mode), pRecurrence(recurrence), minInterval(min_interval), - preferredAccuracy(preferred_accuracy), preferredTime(preferred_time) + pMode(mode) { - LOC_LOGV("Position mode: %s\n Position recurrence: %s\n min interval: %d\n preferred accuracy: %d\n preferred time: %d", - loc_get_position_mode_name(pMode), - loc_get_position_recurrence_name(pRecurrence), - minInterval, - preferredAccuracy, - preferredTime); + pMode.logv(); } }; @@ -193,18 +308,10 @@ struct loc_eng_msg_report_position : public loc_eng_msg { loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), location(loc), locationExt(locExt), status(st) { -#ifdef QCOM_FEATURE_ULP - LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %s", + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d", location.flags, location.position_source, location.latitude, location.longitude, location.altitude, location.speed, location.bearing, location.accuracy, - location.timestamp, location.rawDataSize, location.rawData, - loc_get_position_sess_status_name(status)); -#else - LOC_LOGV("flags: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n Session status: %s", - location.flags, location.latitude, location.longitude, - location.altitude, location.speed, location.bearing, location.accuracy, - location.timestamp, loc_get_position_sess_status_name(status)); -#endif + location.timestamp, location.rawDataSize, location.rawData,status); } }; @@ -256,23 +363,23 @@ struct loc_eng_msg_report_nmea : public loc_eng_msg { }; struct loc_eng_msg_request_bit : public loc_eng_msg { - const unsigned int isSupl; + const loc_if_req_type_e_type ifType; const int ipv4Addr; char* const ipv6Addr; inline loc_eng_msg_request_bit(void* instance, - unsigned int is_supl, + loc_if_req_type_e_type type, int ipv4, char* ipv6) : loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_BIT), - isSupl(is_supl), ipv4Addr(ipv4), + ifType(type), ipv4Addr(ipv4), ipv6Addr(NULL == ipv6 ? NULL : new char[16]) { if (NULL != ipv6Addr) memcpy(ipv6Addr, ipv6, 16); - LOC_LOGV("isSupl: %d, ipv4: %d.%d.%d.%d, ipv6: %s", isSupl, - (unsigned char)ipv4>>24, - (unsigned char)ipv4>>16, - (unsigned char)ipv4>>8, + LOC_LOGV("ifType: %d, ipv4: %d.%d.%d.%d, ipv6: %s", ifType, + (unsigned char)(ipv4>>24), + (unsigned char)(ipv4>>16), + (unsigned char)(ipv4>>8), (unsigned char)ipv4, NULL != ipv6Addr ? ipv6Addr : ""); } @@ -285,24 +392,61 @@ struct loc_eng_msg_request_bit : public loc_eng_msg { } }; +struct loc_eng_msg_request_wifi : public loc_eng_msg { + const loc_if_req_type_e_type ifType; + const loc_if_req_sender_id_e_type senderId; + char* const ssid; + char* const password; + inline loc_eng_msg_request_wifi(void* instance, + loc_if_req_type_e_type type, + loc_if_req_sender_id_e_type sender_id, + char* s, + char* p) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_WIFI), + ifType(type), senderId(sender_id), + ssid(NULL == s ? NULL : new char[SSID_BUF_SIZE]), + password(NULL == p ? NULL : new char[SSID_BUF_SIZE]) + { + if (NULL != ssid) + strlcpy(ssid, s, SSID_BUF_SIZE); + if (NULL != password) + strlcpy(password, p, SSID_BUF_SIZE); + LOC_LOGV("ifType: %d, senderId: %d, ssid: %s, password: %s", + ifType, + senderId, + NULL != ssid ? ssid : "", + NULL != password ? password : ""); + } + + inline ~loc_eng_msg_request_wifi() + { + if (NULL != ssid) { + delete[] ssid; + } + if (NULL != password) { + delete[] password; + } + } +}; + struct loc_eng_msg_release_bit : public loc_eng_msg { - const unsigned int isSupl; + const loc_if_req_type_e_type ifType; const int ipv4Addr; char* const ipv6Addr; inline loc_eng_msg_release_bit(void* instance, - unsigned int is_supl, + loc_if_req_type_e_type type, int ipv4, char* ipv6) : loc_eng_msg(instance, LOC_ENG_MSG_RELEASE_BIT), - isSupl(is_supl), ipv4Addr(ipv4), + ifType(type), ipv4Addr(ipv4), ipv6Addr(NULL == ipv6 ? NULL : new char[16]) { if (NULL != ipv6Addr) memcpy(ipv6Addr, ipv6, 16); - LOC_LOGV("isSupl: %d, ipv4: %d.%d.%d.%d, ipv6: %s", isSupl, - (unsigned char)ipv4>>24, - (unsigned char)ipv4>>16, - (unsigned char)ipv4>>8, + LOC_LOGV("ifType: %d, ipv4: %d.%d.%d.%d, ipv6: %s", ifType, + (unsigned char)(ipv4>>24), + (unsigned char)(ipv4>>16), + (unsigned char)(ipv4>>8), (unsigned char)ipv4, NULL != ipv6Addr ? ipv6Addr : ""); } @@ -315,6 +459,44 @@ struct loc_eng_msg_release_bit : public loc_eng_msg { } }; +struct loc_eng_msg_release_wifi : public loc_eng_msg { + const loc_if_req_type_e_type ifType; + const loc_if_req_sender_id_e_type senderId; + char* const ssid; + char* const password; + inline loc_eng_msg_release_wifi(void* instance, + loc_if_req_type_e_type type, + loc_if_req_sender_id_e_type sender_id, + char* s, + char* p) : + loc_eng_msg(instance, LOC_ENG_MSG_RELEASE_WIFI), + ifType(type), senderId(sender_id), + ssid(NULL == s ? NULL : new char[SSID_BUF_SIZE]), + password(NULL == p ? NULL : new char[SSID_BUF_SIZE]) + { + if (NULL != s) + strlcpy(ssid, s, SSID_BUF_SIZE); + if (NULL != p) + strlcpy(password, p, SSID_BUF_SIZE); + LOC_LOGV("ifType: %d, senderId: %d, ssid: %s, password: %s", + ifType, + senderId, + NULL != ssid ? ssid : "", + NULL != password ? password : ""); + } + + inline ~loc_eng_msg_release_wifi() + { + if (NULL != ssid) { + delete[] ssid; + } + if (NULL != password) { + delete[] password; + } + } +}; + + struct loc_eng_msg_request_atl : public loc_eng_msg { const int handle; const AGpsType type; @@ -452,7 +634,6 @@ struct loc_eng_msg_inject_xtra_data : public loc_eng_msg { } }; -#ifdef QCOM_FEATURE_IPV6 struct loc_eng_msg_atl_open_success : public loc_eng_msg { const AGpsStatusValue agpsType; const int length; @@ -479,30 +660,7 @@ struct loc_eng_msg_atl_open_success : public loc_eng_msg { delete[] apn; } }; -#else -struct loc_eng_msg_atl_open_success : public loc_eng_msg { - const int length; - char* const apn; - inline loc_eng_msg_atl_open_success(void* instance, - const char* name, - int len) : - loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_SUCCESS), - length(len), - apn(new char[len+1]) - { - memcpy((void*)apn, (void*)name, len); - apn[len] = 0; - LOC_LOGV("apn: %s\n", - apn); - } - inline ~loc_eng_msg_atl_open_success() - { - delete[] apn; - } -}; -#endif -#ifdef QCOM_FEATURE_IPV6 struct loc_eng_msg_atl_open_failed : public loc_eng_msg { const AGpsStatusValue agpsType; inline loc_eng_msg_atl_open_failed(void* instance, @@ -514,17 +672,7 @@ struct loc_eng_msg_atl_open_failed : public loc_eng_msg { loc_get_agps_type_name(agpsType)); } }; -#else -struct loc_eng_msg_atl_open_failed : public loc_eng_msg { - inline loc_eng_msg_atl_open_failed(void* instance) : - loc_eng_msg(instance, LOC_ENG_MSG_ATL_OPEN_FAILED) - { - LOC_LOGV(""); - } -}; -#endif -#ifdef QCOM_FEATURE_IPV6 struct loc_eng_msg_atl_closed : public loc_eng_msg { const AGpsStatusValue agpsType; inline loc_eng_msg_atl_closed(void* instance, @@ -536,15 +684,6 @@ struct loc_eng_msg_atl_closed : public loc_eng_msg { loc_get_agps_type_name(agpsType)); } }; -#else -struct loc_eng_msg_atl_closed : public loc_eng_msg { - inline loc_eng_msg_atl_closed(void* instance) : - loc_eng_msg(instance, LOC_ENG_MSG_ATL_CLOSED) - { - LOC_LOGV(""); - } -}; -#endif struct loc_eng_msg_set_data_enable : public loc_eng_msg { const int enable; @@ -567,6 +706,98 @@ struct loc_eng_msg_set_data_enable : public loc_eng_msg { } }; +struct loc_eng_msg_request_network_position : public loc_eng_msg { + const UlpNetworkRequestPos networkPosRequest; + inline loc_eng_msg_request_network_position (void* instance, UlpNetworkRequestPos networkPosReq) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_NETWORK_POSIITON), + networkPosRequest(networkPosReq) + { + LOC_LOGV("network position request: desired pos source %d\n request type: %d\n interval ms: %d ", + networkPosReq.desired_position_source, + networkPosReq.request_type, + networkPosReq.interval_ms); + } +}; + +struct loc_eng_msg_request_phone_context : public loc_eng_msg { + const UlpPhoneContextRequest contextRequest; + inline loc_eng_msg_request_phone_context (void* instance, UlpPhoneContextRequest contextReq) : + loc_eng_msg(instance, LOC_ENG_MSG_REQUEST_PHONE_CONTEXT), + contextRequest(contextReq) + { + LOC_LOGV("phone context request: request type 0x%x context type: 0x%x ", + contextRequest.request_type, + contextRequest.context_type); + } +}; + +struct ulp_msg_update_criteria : public loc_eng_msg { + const UlpLocationCriteria locationCriteria; + inline ulp_msg_update_criteria (void* instance, UlpLocationCriteria criteria) : + loc_eng_msg(instance, ULP_MSG_UPDATE_CRITERIA), + locationCriteria(criteria) + { + LOC_LOGV("location criteria: aciton %d\n valid mask: %d\n provider source: %d\n accuracy %d\n recurrence type %d\n min interval %d\n power consumption %d\n intermediate pos %d ", + locationCriteria.action, + locationCriteria.valid_mask, + locationCriteria.provider_source, + locationCriteria.preferred_horizontal_accuracy, + locationCriteria.recurrence_type, + locationCriteria.min_interval, + locationCriteria.preferred_power_consumption, + locationCriteria.intermediate_pos_report_enabled); + } +}; + +struct ulp_msg_inject_phone_context_settings : public loc_eng_msg { + const UlpPhoneContextSettings phoneSetting; + inline ulp_msg_inject_phone_context_settings(void* instance, UlpPhoneContextSettings setting) : + loc_eng_msg(instance, ULP_MSG_INJECT_PHONE_CONTEXT_SETTINGS), + phoneSetting(setting) + { + LOC_LOGV("context type: %d\n gps enabled: %d\n network position available %d\n wifi setting enabled %d\n battery charging %d" + "is_agps_setting_enabled %d, is_enh_location_services_enabled %d\n", + phoneSetting.context_type, + phoneSetting.is_gps_enabled, + phoneSetting.is_network_position_available, + phoneSetting.is_wifi_setting_enabled, + phoneSetting.is_battery_charging, + phoneSetting.is_agps_enabled, + phoneSetting.is_enh_location_services_enabled); + } +}; + +struct ulp_msg_inject_network_position : public loc_eng_msg { + const UlpNetworkPositionReport networkPosition; + inline ulp_msg_inject_network_position(void* instance, UlpNetworkPositionReport networkPos) : + loc_eng_msg(instance, ULP_MSG_INJECT_NETWORK_POSITION), + networkPosition(networkPos) + { + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n accuracy %d", + networkPosition.valid_flag, + networkPosition.position.pos_source, + networkPosition.position.latitude, + networkPosition.position.longitude, + networkPosition.position.HEPE); + } +}; + +struct ulp_msg_report_quipc_position : public loc_eng_msg { + const GpsLocation location; + const int quipc_error_code; + inline ulp_msg_report_quipc_position(void* instance, GpsLocation &loc, + int quipc_err) : + loc_eng_msg(instance, ULP_MSG_REPORT_QUIPC_POSITION), + location(loc), quipc_error_code(quipc_err) + { + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Quipc error: %d", + location.flags, location.position_source, location.latitude, location.longitude, + location.altitude, location.speed, location.bearing, location.accuracy, + location.timestamp, location.rawDataSize, location.rawData, + quipc_error_code); + } +}; + void loc_eng_msg_sender(void* loc_eng_data_p, void* msg); int loc_eng_msgget(int * p_req_msgq); int loc_eng_msgremove(int req_msgq); diff --git a/loc_api/libloc_api_50001/loc_eng_msg_id.h b/loc_api/libloc_api_50001/loc_eng_msg_id.h old mode 100755 new mode 100644 index f05f1f44..ff5a6bd7 --- a/loc_api/libloc_api_50001/loc_eng_msg_id.h +++ b/loc_api/libloc_api_50001/loc_eng_msg_id.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011,2012 Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -76,11 +76,48 @@ enum loc_eng_msg_ids_t { LOC_ENG_MSG_RELEASE_BIT, LOC_ENG_MSG_REQUEST_ATL, LOC_ENG_MSG_RELEASE_ATL, + LOC_ENG_MSG_REQUEST_WIFI, + LOC_ENG_MSG_RELEASE_WIFI, LOC_ENG_MSG_REQUEST_NI, LOC_ENG_MSG_INFORM_NI_RESPONSE, LOC_ENG_MSG_REQUEST_XTRA_DATA, LOC_ENG_MSG_REQUEST_TIME, - LOC_ENG_MSG_REQUEST_POSITION + LOC_ENG_MSG_REQUEST_POSITION, + LOC_ENG_MSG_EXT_POWER_CONFIG, + + // The following messages are added for ulp + LOC_ENG_MSG_REQUEST_PHONE_CONTEXT, + LOC_ENG_MSG_REQUEST_NETWORK_POSIITON, + + /* Following messages are for ulp, start at index 0x600 */ + + // Message is sent by GPS HAL layer to add/remove unique request criteria + ULP_MSG_UPDATE_CRITERIA = 0x600, + + // Message is sent by GPS HAL layer to request ULP to start producing position fixes + + ULP_MSG_START_FIX, + + // Message is sent by Android framework(GpsLocationProvider) + // to request ULP to stop producing position fixes + ULP_MSG_STOP_FIX, + + // Message is sent by Android framework(GpsLocationProvider) + // to inject phone context setting include initial phone context setting and subsequent changes + ULP_MSG_INJECT_PHONE_CONTEXT_SETTINGS, + + // Message is sent by network provider to INJECT the position in UlpNetworkPositionReport format + ULP_MSG_INJECT_NETWORK_POSITION, + + // Message is sent by QUIPC provider in order to report the position in GpsPosition format with QUIPC status + ULP_MSG_REPORT_QUIPC_POSITION, + + // Message is sent by QUIPC module in order to request some info from ULP + ULP_MSG_REQUEST_COARSE_POSITION, + + /* Message is sent by HAL to LOC API to configure LTE Positioning + Profile in modem */ + LOC_ENG_MSG_LPP_CONFIG }; #ifdef __cplusplus diff --git a/loc_api/libloc_api_50001/loc_eng_ni.cpp b/loc_api/libloc_api_50001/loc_eng_ni.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_ni.h b/loc_api/libloc_api_50001/loc_eng_ni.h old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_xtra.cpp b/loc_api/libloc_api_50001/loc_eng_xtra.cpp old mode 100755 new mode 100644 diff --git a/loc_api/libloc_api_50001/loc_eng_xtra.h b/loc_api/libloc_api_50001/loc_eng_xtra.h old mode 100755 new mode 100644 diff --git a/loc_api/loc_api_v02/Android.mk b/loc_api/loc_api_v02/Android.mk old mode 100755 new mode 100644 diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp old mode 100755 new mode 100644 index e223983b..92acfc75 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -26,6 +26,9 @@ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#define LOG_NDEBUG 0 +#define LOG_TAG "LocSvc_adapter" + #include #include #include @@ -40,9 +43,6 @@ #include "loc_api_v02_log.h" #include "loc_api_sync_req.h" #include "LocApiAdapter.h" - -#define LOG_NDEBUG 0 -#define LOG_TAG "LocSvc_adapter" #include "loc_util_log.h" @@ -161,10 +161,7 @@ locClientCallbacksType globalCallbacks = /* Constructor for LocApiV02Adapter */ LocApiV02Adapter :: LocApiV02Adapter(LocEng &locEng): LocApiAdapter(locEng), clientHandle( LOC_CLIENT_INVALID_HANDLE_VALUE), - eventMask(convertMask(locEng.eventMask)), navigating(false), - fixCriteria (LOC_POSITION_MODE_MS_BASED, GPS_POSITION_RECURRENCE_PERIODIC, - LOC_API_V02_DEF_MIN_INTERVAL, LOC_API_V02_DEF_HORZ_ACCURACY, - LOC_API_V02_DEF_TIMEOUT ) + eventMask(convertMask(locEng.eventMask)) { // initialize loc_sync_req interface loc_sync_req_init(); @@ -236,6 +233,7 @@ enum loc_api_adapter_err LocApiV02Adapter :: startFix() memset (&set_mode_ind, 0, sizeof(set_mode_ind)); LOC_LOGV("%s:%d]: start \n", __func__, __LINE__); + fixCriteria.logv(); // fill in the start request switch(fixCriteria.mode) @@ -277,28 +275,27 @@ enum loc_api_adapter_err LocApiV02Adapter :: startFix() return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; // error } - if(fixCriteria.min_interval > 0) - { - start_msg.minInterval_valid = 1; - start_msg.minInterval = fixCriteria.min_interval; - } + start_msg.minInterval_valid = 1; + start_msg.minInterval = fixCriteria.min_interval; - start_msg.horizontalAccuracyLevel_valid = 1; + if (fixCriteria.preferred_accuracy > 0) { + start_msg.horizontalAccuracyLevel_valid = 1; - if (fixCriteria.preferred_accuracy <= 100) - { - // fix needs high accuracy - start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_HIGH_V02; - } - else if (fixCriteria.preferred_accuracy <= 1000) - { - //fix needs med accuracy - start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_MED_V02; - } - else - { - //fix needs low accuracy - start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_LOW_V02; + if (fixCriteria.preferred_accuracy <= 100) + { + // fix needs high accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_HIGH_V02; + } + else if (fixCriteria.preferred_accuracy <= 1000) + { + //fix needs med accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_MED_V02; + } + else + { + //fix needs low accuracy + start_msg.horizontalAccuracyLevel = eQMI_LOC_ACCURACY_LOW_V02; + } } start_msg.fixRecurrence_valid = 1; @@ -313,7 +310,25 @@ enum loc_api_adapter_err LocApiV02Adapter :: startFix() //dummy session id // TBD: store session ID, check for session id in pos reports. - start_msg.sessionId = LOC_API_V02_DEF_SESSION_ID;; + start_msg.sessionId = LOC_API_V02_DEF_SESSION_ID; + + if (fixCriteria.credentials[0] != 0) { + int size1 = sizeof(start_msg.applicationId.applicationName); + int size2 = sizeof(fixCriteria.credentials); + int len = ((size1 < size2) ? size1 : size2) - 1; + memcpy(start_msg.applicationId.applicationName, + fixCriteria.credentials, + len); + + size1 = sizeof(start_msg.applicationId.applicationProvider); + size2 = sizeof(fixCriteria.provider); + len = ((size1 < size2) ? size1 : size2) - 1; + memcpy(start_msg.applicationId.applicationProvider, + fixCriteria.provider, + len); + + start_msg.applicationId_valid = 1; + } req_union.pStartReq = &start_msg; @@ -322,13 +337,9 @@ enum loc_api_adapter_err LocApiV02Adapter :: startFix() if( eLOC_CLIENT_SUCCESS == status) { - navigating = true; return LOC_API_ADAPTER_ERR_SUCCESS; } - // start_fix failed so MO fix is not in progress - navigating = false; - return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; } @@ -355,7 +366,6 @@ enum loc_api_adapter_err LocApiV02Adapter :: stopFix() if( eLOC_CLIENT_SUCCESS == status) { - navigating = false; return LOC_API_ADAPTER_ERR_SUCCESS; } @@ -366,42 +376,28 @@ enum loc_api_adapter_err LocApiV02Adapter :: stopFix() /* set the positioning fix criteria */ enum loc_api_adapter_err LocApiV02Adapter :: setPositionMode( - LocPositionMode mode, GpsPositionRecurrence recurrence, - uint32_t min_interval, uint32_t preferred_accuracy, - uint32_t preferred_time) + const LocPosMode *posMode) { + LOC_LOGV ("%s:%d]: posMode %p",__func__, __LINE__, posMode); - LOC_LOGV ("%s:%d]: interval = %d, mode = %d, recurrence = %d, preferred_accuracy = %d\n",__func__, __LINE__, - min_interval, mode, recurrence, preferred_accuracy); + if (NULL != posMode && + !fixCriteria.equals(*posMode)) { + //making a copy of the fix criteria + fixCriteria = *posMode; - //store the fix criteria - fixCriteria.mode = mode; + LOC_LOGD ("%s:%d]: new fix criteria", __func__, __LINE__); - fixCriteria.recurrence = recurrence; + if(true == navigating) + { + //fix is in progress, send a restart + LOC_LOGD ("%s:%d]: fix is in progress restarting the fix with new " + "criteria\n", __func__, __LINE__); - if(min_interval == 0) - { - fixCriteria.min_interval = MIN_POSSIBLE_FIX_INTERVAL; - } - else - { - fixCriteria.min_interval = min_interval; - } + return( startFix()); + } + } - fixCriteria.preferred_accuracy = preferred_accuracy; - - fixCriteria.preferred_time = preferred_time; - - if(true == navigating) - { - //fix is in progress, send a restart - LOC_LOGD ("%s:%d]: fix is in progress restarting the fix with new " - "criteria\n", __func__, __LINE__); - - return( startFix()); - } - - return LOC_API_ADAPTER_ERR_SUCCESS; + return LOC_API_ADAPTER_ERR_SUCCESS; } /* inject time into the position engine */ @@ -563,13 +559,12 @@ enum loc_api_adapter_err LocApiV02Adapter :: deleteAidingData(GpsAidingData f) } -#ifdef QCOM_FEATURE_DELEXT if( f & GPS_DELETE_TIME_GPS ) { delete_req.deleteGnssDataMask_valid = 1; delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GPS_TIME_V02; } -#endif + if(f & GPS_DELETE_POSITION ) { delete_req.deleteGnssDataMask_valid = 1; @@ -631,7 +626,6 @@ enum loc_api_adapter_err LocApiV02Adapter :: deleteAidingData(GpsAidingData f) QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02) ; } -#ifdef QCOM_FEATURE_DELEXT if(f & GPS_DELETE_ALMANAC_CORR ) { delete_req.deleteGnssDataMask_valid = 1; @@ -705,7 +699,6 @@ enum loc_api_adapter_err LocApiV02Adapter :: deleteAidingData(GpsAidingData f) delete_req.deleteGnssDataMask_valid = 1; delete_req.deleteGnssDataMask |= QMI_LOC_MASK_DELETE_GLO_TIME_V02; } -#endif } req_union.pDeleteAssistDataReq = &delete_req; @@ -1002,7 +995,7 @@ enum loc_api_adapter_err LocApiV02Adapter :: setXtraData( return LOC_API_ADAPTER_ERR_SUCCESS; } -#ifdef QCOM_FEATURE_IPV6 + enum loc_api_adapter_err LocApiV02Adapter :: atlOpenStatus( int handle, int is_succ, char* apn, AGpsBearerType bear, AGpsType agpsType) @@ -1082,68 +1075,7 @@ enum loc_api_adapter_err LocApiV02Adapter :: atlOpenStatus( return LOC_API_ADAPTER_ERR_SUCCESS; } -#else -enum loc_api_adapter_err LocApiV02Adapter :: atlOpenStatus( - int handle, int is_succ, char* apn, AGpsType agpsType) -{ - locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; - locClientReqUnionType req_union; - qmiLocInformLocationServerConnStatusReqMsgT_v02 conn_status_req; - qmiLocInformLocationServerConnStatusIndMsgT_v02 conn_status_ind; - LOC_LOGD("%s:%d]: ATL open handle = %d, is_succ = %d, " - "APN = [%s] \n", __func__, __LINE__, - handle, is_succ, apn); - - memset(&conn_status_req, 0, sizeof(conn_status_req)); - memset(&conn_status_ind, 0, sizeof(conn_status_ind)); - - // Fill in data - conn_status_req.connHandle = handle; - - conn_status_req.requestType = eQMI_LOC_SERVER_REQUEST_OPEN_V02; - - if(is_succ) - { - conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02; - - strlcpy(conn_status_req.apnProfile.apnName, apn, - sizeof(conn_status_req.apnProfile.apnName) ); - - - conn_status_req.apnProfile.pdnType = - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02; - - conn_status_req.apnProfile_valid = 1; - } - else - { - conn_status_req.statusType = eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02; - } - - req_union.pInformLocationServerConnStatusReq = &conn_status_req; - - result = loc_sync_send_req(clientHandle, - QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, - req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, - QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, - &conn_status_ind); - - if(result != eLOC_CLIENT_SUCCESS || - eQMI_LOC_SUCCESS_V02 != conn_status_ind.status) - { - LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", - __func__, __LINE__, - loc_get_v02_client_status_name(result), - loc_get_v02_qmi_status_name(conn_status_ind.status)); - - return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; - } - - return LOC_API_ADAPTER_ERR_SUCCESS; - -} -#endif /* close atl connection */ enum loc_api_adapter_err LocApiV02Adapter :: atlCloseStatus( int handle, int is_succ) @@ -1239,6 +1171,67 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSUPLVersion(uint32_t version) return LOC_API_ADAPTER_ERR_SUCCESS; } +/* set the configuration for LTE positioning profile (LPP) */ +enum loc_api_adapter_err LocApiV02Adapter :: setLPPConfig(uint32_t profile) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + qmiLocSetProtocolConfigParametersReqMsgT_v02 lpp_config_req; + qmiLocSetProtocolConfigParametersIndMsgT_v02 lpp_config_ind; + + LOC_LOGD("%s:%d]: lpp profile = %d\n", __func__, __LINE__, profile); + + memset(&lpp_config_req, 0, sizeof(lpp_config_req)); + memset(&lpp_config_ind, 0, sizeof(lpp_config_ind)); + + lpp_config_req.lppConfig_valid = 1; + // Default RRLP or User or Control plane configuration + switch(profile) + { + /* RRLP */ + case 0: + lpp_config_req.lppConfig = profile; + break; + + /* User plane */ + case 1: + lpp_config_req.lppConfig = QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02; + break; + + case 2: + lpp_config_req.lppConfig = QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02; + break; + + default: + LOC_LOGE("%s:%d]: Invalid LPP Profile Config Setting Provided in gps.conf = %d!", + __FUNCTION__, + __LINE__, + profile); + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + break; + } + + req_union.pSetProtocolConfigParametersReq = &lpp_config_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, + &lpp_config_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != lpp_config_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(lpp_config_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + return LOC_API_ADAPTER_ERR_SUCCESS; +} + /* set the Sensor Configuration */ enum loc_api_adapter_err LocApiV02Adapter :: setSensorControlConfig(int sensorsDisabled) { @@ -1280,7 +1273,11 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorControlConfig(int sensorsD } /* set the Sensor Properties */ -enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(float gyroBiasVarianceRandomWalk) +enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(bool gyroBiasVarianceRandomWalk_valid, float gyroBiasVarianceRandomWalk, + bool accelBiasVarianceRandomWalk_valid, float accelBiasVarianceRandomWalk, + bool angleBiasVarianceRandomWalk_valid, float angleBiasVarianceRandomWalk, + bool rateBiasVarianceRandomWalk_valid, float rateBiasVarianceRandomWalk, + bool velocityBiasVarianceRandomWalk_valid, float velocityBiasVarianceRandomWalk) { locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; locClientReqUnionType req_union; @@ -1288,15 +1285,30 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(float gyroBiasV qmiLocSetSensorPropertiesReqMsgT_v02 sensor_prop_req; qmiLocSetSensorPropertiesIndMsgT_v02 sensor_prop_ind; - LOC_LOGI("%s:%d]: sensors prop gyroBiasRandomWalk = %f\n", - __func__, __LINE__, gyroBiasVarianceRandomWalk); + LOC_LOGI("%s:%d]: sensors prop: gyroBiasRandomWalk = %f, accelRandomWalk = %f, " + "angleRandomWalk = %f, rateRandomWalk = %f, velocityRandomWalk = %f\n", + __func__, __LINE__, gyroBiasVarianceRandomWalk, accelBiasVarianceRandomWalk, + angleBiasVarianceRandomWalk, rateBiasVarianceRandomWalk, velocityBiasVarianceRandomWalk); memset(&sensor_prop_req, 0, sizeof(sensor_prop_req)); memset(&sensor_prop_ind, 0, sizeof(sensor_prop_ind)); - sensor_prop_req.gyroBiasVarianceRandomWalk_valid = 1; + /* Set the validity bit and value for each sensor property */ + sensor_prop_req.gyroBiasVarianceRandomWalk_valid = gyroBiasVarianceRandomWalk_valid; sensor_prop_req.gyroBiasVarianceRandomWalk = gyroBiasVarianceRandomWalk; + sensor_prop_req.accelerationRandomWalkSpectralDensity_valid = accelBiasVarianceRandomWalk_valid; + sensor_prop_req.accelerationRandomWalkSpectralDensity = accelBiasVarianceRandomWalk; + + sensor_prop_req.angleRandomWalkSpectralDensity_valid = angleBiasVarianceRandomWalk_valid; + sensor_prop_req.angleRandomWalkSpectralDensity = angleBiasVarianceRandomWalk; + + sensor_prop_req.rateRandomWalkSpectralDensity_valid = rateBiasVarianceRandomWalk_valid; + sensor_prop_req.rateRandomWalkSpectralDensity = rateBiasVarianceRandomWalk; + + sensor_prop_req.velocityRandomWalkSpectralDensity_valid = velocityBiasVarianceRandomWalk_valid; + sensor_prop_req.velocityRandomWalkSpectralDensity = velocityBiasVarianceRandomWalk; + req_union.pSetSensorPropertiesReq = &sensor_prop_req; result = loc_sync_send_req(clientHandle, @@ -1322,7 +1334,8 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(float gyroBiasV /* set the Sensor Performance Config */ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, - int gyroSamplesPerBatch, int gyroBatchesPerSec) + int gyroSamplesPerBatch, int gyroBatchesPerSec, + int algorithmConfig) { locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; locClientReqUnionType req_union; @@ -1331,14 +1344,16 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont qmiLocSetSensorPerformanceControlConfigIndMsgT_v02 sensor_perf_config_ind; LOC_LOGD("%s:%d]: Sensor Perf Control Config (performanceControlMode)(%u) " - "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u)\n", + "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u) " + "algorithmConfig(%u)\n", __FUNCTION__, __LINE__, controlMode, accelSamplesPerBatch, accelBatchesPerSec, gyroSamplesPerBatch, - gyroBatchesPerSec + gyroBatchesPerSec, + algorithmConfig ); memset(&sensor_perf_config_req, 0, sizeof(sensor_perf_config_req)); @@ -1352,6 +1367,8 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont sensor_perf_config_req.gyroSamplingSpec_valid = 1; sensor_perf_config_req.gyroSamplingSpec.batchesPerSecond = gyroBatchesPerSec; sensor_perf_config_req.gyroSamplingSpec.samplesPerBatch = gyroSamplesPerBatch; + sensor_perf_config_req.algorithmConfig_valid = 1; + sensor_perf_config_req.algorithmConfig = algorithmConfig; req_union.pSetSensorPerformanceControlConfigReq = &sensor_perf_config_req; @@ -1375,6 +1392,65 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont return LOC_API_ADAPTER_ERR_SUCCESS; } +/* set the External Power Config */ +enum loc_api_adapter_err LocApiV02Adapter :: setExtPowerConfig(int isBatteryCharging) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + + qmiLocSetExternalPowerConfigReqMsgT_v02 ext_pwr_req; + qmiLocGetExternalPowerConfigIndMsgT_v02 ext_pwr_ind; + + LOC_LOGI("%s:%d]: Ext Pwr Config (isBatteryCharging)(%u)", + __FUNCTION__, + __LINE__, + isBatteryCharging + ); + + memset(&ext_pwr_req, 0, sizeof(ext_pwr_req)); + memset(&ext_pwr_ind, 0, sizeof(ext_pwr_ind)); + + switch(isBatteryCharging) + { + /* Charging */ + case 1: + ext_pwr_req.externalPowerState = eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02; + break; + + /* Not charging */ + case 0: + ext_pwr_req.externalPowerState = eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02; + break; + + default: + LOC_LOGE("%s:%d]: Invalid ext power state = %d!", + __FUNCTION__, + __LINE__, + isBatteryCharging); + return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; + break; + } + + req_union.pSetExternalPowerConfigReq = &ext_pwr_req; + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, + &ext_pwr_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != ext_pwr_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %d, ind..status = %d ", + __func__, __LINE__, result, ext_pwr_ind.status); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + + return LOC_API_ADAPTER_ERR_SUCCESS; +} + /* Convert event mask from loc eng to loc_api_v02 format */ locClientEventMaskType LocApiV02Adapter :: convertMask( LOC_API_ADAPTER_EVENT_MASK_T mask) @@ -1461,7 +1537,7 @@ void LocApiV02Adapter :: reportPosition ( const qmiLocEventPositionReportIndMsgT_v02 *location_report_ptr) { GpsLocation location; - + LOC_LOGD("Reporting postion from V2 Adapter\n"); memset(&location, 0, sizeof (GpsLocation)); location.size = sizeof(location); // Process the position from final and intermediate reports @@ -1518,7 +1594,9 @@ void LocApiV02Adapter :: reportPosition ( location.flags |= GPS_LOCATION_HAS_ACCURACY; location.accuracy = location_report_ptr->horUncCircular; } - + //Mark the location source as from GNSS + location.flags |= LOCATION_HAS_SOURCE_INFO; + location.position_source = ULP_LOCATION_IS_FROM_GNSS; LocApiAdapter::reportPosition( location, locEngHandle.extPosInfo((void*)location_report_ptr), (location_report_ptr->sessionStatus @@ -1639,7 +1717,7 @@ void LocApiV02Adapter :: reportSv ( } } - if (SvStatus.num_svs != 0) + if (SvStatus.num_svs >= 0) { LOC_LOGV ("%s:%d]: firing SV callback\n", __func__, __LINE__); LocApiAdapter::reportSv(SvStatus, @@ -1713,8 +1791,7 @@ void LocApiV02Adapter :: reportAtlRequest( // service ATL open request; copy the WWAN type if(server_request_ptr->requestType == eQMI_LOC_SERVER_REQUEST_OPEN_V02 ) { - AGpsType agpsType; -#ifdef QCOM_FEATURE_IPV6 + AGpsType agpsType = AGPS_TYPE_WWAN_ANY; switch(server_request_ptr->wwanType) { case eQMI_LOC_WWAN_TYPE_INTERNET_V02: @@ -1729,9 +1806,6 @@ void LocApiV02Adapter :: reportAtlRequest( agpsType = AGPS_TYPE_WWAN_ANY; break; } -#else - agpsType = AGPS_TYPE_SUPL; -#endif LocApiAdapter::requestATL(connHandle, agpsType); } diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.h b/loc_api/loc_api_v02/LocApiV02Adapter.h old mode 100755 new mode 100644 index 487e98eb..04f931ee --- a/loc_api/loc_api_v02/LocApiV02Adapter.h +++ b/loc_api/loc_api_v02/LocApiV02Adapter.h @@ -34,25 +34,6 @@ #include #include -/* Fix criteria structure*/ -struct LocApiV02FixCriteria -{ - LocPositionMode mode; - GpsPositionRecurrence recurrence; - uint32_t min_interval ; - uint32_t preferred_accuracy ; - uint32_t preferred_time; - - /* Constructor for the structure */ - inline LocApiV02FixCriteria (LocPositionMode mode, - GpsPositionRecurrence recur, - uint32_t min_int, - uint32_t pref_acc, - uint32_t pref_time) : - mode(mode), recurrence(recur), min_interval(min_int), - preferred_accuracy(pref_acc), preferred_time(pref_time) {} -}; - /* This class derives from the LocApiAdapter class. The members of this class are responsible for converting the Loc API V02 data structures into Loc Engine data structures. @@ -66,15 +47,6 @@ class LocApiV02Adapter : public LocApiAdapter { /* events the client is registered for */ locClientEventMaskType eventMask; - /* current session state */ - bool navigating; - - /* current fix criteria, for Loc aPI V02 this is - stored when set_position_mode is called and - sent out with Loc aPI V02 start message when the - start_fix() is called by loc engine. */ - LocApiV02FixCriteria fixCriteria; - /* Convert event mask from loc eng to loc_api_v02 format */ locClientEventMaskType convertMask(LOC_API_ADAPTER_EVENT_MASK_T mask); @@ -145,9 +117,7 @@ public: virtual enum loc_api_adapter_err stopFix(); virtual enum loc_api_adapter_err - setPositionMode(LocPositionMode mode, GpsPositionRecurrence recurrence, - uint32_t min_interval, uint32_t preferred_accuracy, - uint32_t preferred_time); + setPositionMode(const LocPosMode *mode); virtual enum loc_api_adapter_err setTime(GpsUtcTime time, int64_t timeReference, int uncertainty); @@ -168,30 +138,27 @@ public: setServer(unsigned int ip, int port, LocServerType type); virtual enum loc_api_adapter_err setXtraData(char* data, int length); -#ifdef QCOM_FEATURE_IPV6 virtual enum loc_api_adapter_err atlOpenStatus(int handle, int is_succ, char* apn, AGpsBearerType bear, AGpsType agpsType); -#else - virtual enum loc_api_adapter_err - atlOpenStatus(int handle, int is_succ, char* apn, - AGpsType agpsType); -#endif virtual enum loc_api_adapter_err atlCloseStatus(int handle, int is_succ); virtual enum loc_api_adapter_err setSUPLVersion(uint32_t version); + virtual enum loc_api_adapter_err setLPPConfig(uint32_t profile); virtual enum loc_api_adapter_err setSensorControlConfig(int sensorUsage); virtual enum loc_api_adapter_err - setSensorProperties(float gyroBiasVarianceRandomWalk); + setSensorProperties(bool gyroBiasVarianceRandomWalk_valid, float gyroBiasVarianceRandomWalk, + bool accelBiasVarianceRandomWalk_valid, float accelBiasVarianceRandomWalk, + bool angleBiasVarianceRandomWalk_valid, float angleBiasVarianceRandomWalk, + bool rateBiasVarianceRandomWalk_valid, float rateBiasVarianceRandomWalk, + bool velocityBiasVarianceRandomWalk_valid, float velocityBiasVarianceRandomWalk); virtual enum loc_api_adapter_err - setSensorPerfControlConfig(int controlMode, - int accelSamplesPerBatch, - int accelBatchesPerSec, - int gyroSamplesPerBatch, - int gyroBatchesPerSec); + setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, + int gyroSamplesPerBatch, int gyroBatchesPerSec, int algorithmConfig); + virtual enum loc_api_adapter_err setExtPowerConfig(int isBatteryCharging); }; #endif //LOC_API_V_0_2_ADAPTER_H diff --git a/loc_api/loc_api_v02/loc_api_sync_req.c b/loc_api/loc_api_v02/loc_api_sync_req.c old mode 100755 new mode 100644 index b75f1630..596a8d35 --- a/loc_api/loc_api_v02/loc_api_sync_req.c +++ b/loc_api/loc_api_v02/loc_api_sync_req.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -25,7 +25,6 @@ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #include #include #include @@ -36,7 +35,6 @@ #include #include "loc_api_v02_client.h" -#include "loc_api_v02_log.h" #include "loc_api_sync_req.h" /* Logging */ @@ -162,7 +160,7 @@ void loc_sync_process_ind( ) { - LOC_LOGV("%s:%d]: received indication, handle = %d ind_id = %d \n", + LOC_LOGV("%s:%d]: received indication, handle = %p ind_id = %u \n", __func__,__LINE__, client_handle, ind_id); pthread_mutex_lock(&loc_sync_call_mutex); @@ -353,7 +351,7 @@ static int loc_sync_select_ind( { int select_id = loc_alloc_slot(); - LOC_LOGV("%s:%d]: client handle %d, ind_id %u, req_id %u \n", + LOC_LOGV("%s:%d]: client handle %p, ind_id %u, req_id %u \n", __func__, __LINE__, client_handle, ind_id, req_id); if (select_id < 0) diff --git a/loc_api/loc_api_v02/loc_api_sync_req.h b/loc_api/loc_api_v02/loc_api_sync_req.h old mode 100755 new mode 100644 diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c old mode 100755 new mode 100644 index 4d34adc4..26ecfd26 --- a/loc_api/loc_api_v02/loc_api_v02_client.c +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -26,6 +26,7 @@ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include #include "qmi_client.h" #include "qmi_idl_lib.h" #include "qmi_cci_target_ext.h" @@ -33,23 +34,15 @@ #if defined( _ANDROID_) #include "qmi_cci_target.h" #include "qmi_cci_common.h" -#elif defined(LOC_UTIL_TARGET_OFF_TARGET) -#include -#include -#include +#define LOG_NDEBUG 0 +#define LOG_TAG "LocSvc_api_v02" #endif //_ANDROID_ #include #include -#include #include #include #include "loc_api_v02_client.h" -#include "loc_api_v02_log.h" - -#define LOG_NDEBUG 0 -#define LOG_TAG "LocSvc_api_v02" - #include "loc_util_log.h" #ifdef LOC_UTIL_TARGET_OFF_TARGET @@ -71,7 +64,8 @@ #endif //LOC_UTIL_TARGET_OFF_TARGET //timeout in ms to wait for the service to come up -#define LOC_CLIENT_SERVICE_TIMEOUT (20000) +#define LOC_CLIENT_SERVICE_TIMEOUT_UNIT (4000) +#define LOC_CLIENT_SERVICE_TIMEOUT_TOTAL (40000) /* Table to relate eventId, size and mask value used to enable the event*/ typedef struct @@ -152,7 +146,22 @@ static locClientEventIndTableStructT locClientEventIndTable[]= { //Location Server Connection Request event { QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), - QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 } + QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 }, + + // NI Geofence Event + { QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, + sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), + QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02}, + + // Geofence General Alert Event + { QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, + sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), + QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02}, + + //Geofence Breach event + { QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, + sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), + QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02} }; /* table to relate the respInd Id with its size */ @@ -345,8 +354,27 @@ static locClientRespIndTableStructT locClientRespIndTable[]= { // Get Position Engine Config { QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, - sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02)} + sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02)}, + //Add a Circular Geofence + { QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, + sizeof(qmiLocAddCircularGeofenceIndMsgT_v02)}, + + //Delete a Geofence + { QMI_LOC_DELETE_GEOFENCE_IND_V02, + sizeof(qmiLocDeleteGeofenceIndMsgT_v02)} , + + //Query a Geofence + { QMI_LOC_QUERY_GEOFENCE_IND_V02, + sizeof(qmiLocQueryGeofenceIndMsgT_v02)}, + + //Edit a Geofence + { QMI_LOC_EDIT_GEOFENCE_IND_V02, + sizeof(qmiLocEditGeofenceIndMsgT_v02)}, + + //Get best available position + { QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, + sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02)} }; @@ -467,7 +495,7 @@ static locClientStatusEnumType convertQmiResponseToLocStatus( locClientStatusEnumType status = eLOC_CLIENT_FAILURE_INTERNAL; // if result == SUCCESS don't look at error code - if(pResponse->resp.result == QMI_RESULT_SUCCESS ) + if(pResponse->resp.result == QMI_RESULT_SUCCESS_V01 ) { status = eLOC_CLIENT_SUCCESS; } @@ -476,6 +504,7 @@ static locClientStatusEnumType convertQmiResponseToLocStatus( switch(pResponse->resp.error) { case QMI_ERR_MALFORMED_MSG_V01: + case QMI_ERR_INVALID_ARG_V01: status = eLOC_CLIENT_FAILURE_INVALID_PARAMETER; break; @@ -749,6 +778,27 @@ static bool locClientHandleIndication( break; } + case QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02: + { + //locClientHandleNiGeofenceNotificationInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02: + { + //locClientHandleGeofenceGenAlertInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02: + { + //locClientHandleGeofenceBreachInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + //------------------------------------------------------------------------- // handle the response indications @@ -761,6 +811,13 @@ static bool locClientHandleIndication( indBuffer, indSize); break; } + + case QMI_LOC_GET_FIX_CRITERIA_IND_V02: + { + status = true; + break; + } + // predicted orbits data response indication case QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02: { @@ -847,6 +904,50 @@ static bool locClientHandleIndication( status = true; break; } + + case QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02: + { + // locClientHandleAddCircularGeofenceInd( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_DELETE_GEOFENCE_IND_V02: + { + // locClientHandleDeleteGeofenceInd( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_EDIT_GEOFENCE_IND_V02: + { + // locClientHandleEditGeofenceInd( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_QUERY_GEOFENCE_IND_V02: + { + // locClientHandleQueryGeofenceInd( + // user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02: + { + status = true; + break; + } + case QMI_LOC_GET_ENGINE_LOCK_IND_V02: + { + status = true; + break; + } + // for indications that only have a "status" field case QMI_LOC_NI_USER_RESPONSE_IND_V02: case QMI_LOC_INJECT_UTC_TIME_IND_V02: @@ -971,7 +1072,7 @@ static void locClientIndCb // check user handle if(memcmp(&pCallbackData->userHandle, &user_handle, sizeof(user_handle))) { - LOC_LOGE("%s:%d]: invalid user_handle got 0x%x expected 0x%x\n", + LOC_LOGE("%s:%d]: invalid user_handle got %p expected %p\n", __func__, __LINE__, user_handle, pCallbackData->userHandle); return; @@ -1315,6 +1416,12 @@ static bool validateRequest( break; } + case QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02: + { + *pOutLen = sizeof(qmiLocGetSensorPropertiesReqMsgT_v02); + break; + } + case QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02: { *pOutLen = sizeof(qmiLocSetSensorPropertiesReqMsgT_v02); @@ -1347,6 +1454,31 @@ static bool validateRequest( *pOutLen = sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02); break; } + case QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02: + { + *pOutLen = sizeof(qmiLocAddCircularGeofenceReqMsgT_v02); + break; + } + case QMI_LOC_DELETE_GEOFENCE_REQ_V02: + { + *pOutLen = sizeof(qmiLocDeleteGeofenceReqMsgT_v02); + break; + } + case QMI_LOC_QUERY_GEOFENCE_REQ_V02: + { + *pOutLen = sizeof(qmiLocQueryGeofenceReqMsgT_v02); + break; + } + case QMI_LOC_EDIT_GEOFENCE_REQ_V02: + { + *pOutLen = sizeof(qmiLocEditGeofenceReqMsgT_v02); + break; + } + case QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02: + { + *pOutLen = sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02); + break; + } // ALL requests with no payload case QMI_LOC_GET_SERVICE_REVISION_REQ_V02: @@ -1364,7 +1496,6 @@ static bool validateRequest( case QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02: case QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02: case QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02: - case QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02: case QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02: { noPayloadFlag = true; @@ -1401,121 +1532,176 @@ static bool validateRequest( static locClientStatusEnumType locClientQmiCtrlPointInit( locClientCallbackDataType *pLocClientCbData) { - uint32_t num_services, num_entries = 10; qmi_client_type clnt, notifier; - qmi_client_os_params os_params; + bool notifierInitFlag = false; + locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; + // instances of this service + qmi_service_info *pServiceInfo = NULL; - // num instances of this service - qmi_service_info serviceInfo[5]; - - qmi_client_error_type rc = QMI_NO_ERR; - - // Get the service object for the qmiLoc Service - qmi_idl_service_object_type locClientServiceObject = - loc_get_service_object_v02(); - - // Verify that qmiLoc_get_service_object did not return NULL - if (NULL == locClientServiceObject) + do { - LOC_LOGE("%s:%d]: qmiLoc_get_service_object_v02 failed\n" , - __func__, __LINE__ ); - return(eLOC_CLIENT_FAILURE_INTERNAL); - } + uint32_t num_services = 0, num_entries = 0; + qmi_client_error_type rc = QMI_NO_ERR; + bool nosignal = false; + // Get the service object for the qmiLoc Service + qmi_idl_service_object_type locClientServiceObject = + loc_get_service_object_v02(); - // register for service notification - rc = qmi_client_notifier_init(locClientServiceObject, &os_params, ¬ifier); + // Verify that qmiLoc_get_service_object did not return NULL + if (NULL == locClientServiceObject) + { + LOC_LOGE("%s:%d]: qmiLoc_get_service_object_v02 failed\n" , + __func__, __LINE__ ); + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } - if(rc != QMI_NO_ERR) - { - LOC_LOGE("%s:%d]: qmi_client_notifier_init failed\n", - __func__, __LINE__ ); - return(eLOC_CLIENT_FAILURE_INTERNAL); - } - - /* If service is not up wait on a signal until the service is up - * or a timeout occurs. */ - - QMI_CCI_OS_SIGNAL_WAIT(&os_params, LOC_CLIENT_SERVICE_TIMEOUT); - - if(QMI_CCI_OS_SIGNAL_TIMED_OUT(&os_params)) - { - // timed out, return with error - LOC_LOGE("%s:%d]: timed out waiting for service\n", - __func__, __LINE__); - - return(eLOC_CLIENT_FAILURE_TIMEOUT); - } - else - { // get the service addressing information rc = qmi_client_get_service_list( locClientServiceObject, NULL, NULL, &num_services); - LOC_LOGV("%s:%d]: qmi_client_get_service_list() returned %d " - "num_services = %d\n", __func__, __LINE__, rc, - num_services); + LOC_LOGV("%s:%d]: qmi_client_get_service_list() first try rc %d, " + "num_services %d", __func__, __LINE__, rc, num_services); + + if (rc != QMI_NO_ERR) { + // bummer, service list is not up. + // We need to try again after a timed wait + qmi_client_os_params os_params; + int timeout = 0; + + // register for service notification + rc = qmi_client_notifier_init(locClientServiceObject, &os_params, ¬ifier); + notifierInitFlag = (NULL != notifier); + + if (rc != QMI_NO_ERR) { + LOC_LOGE("%s:%d]: qmi_client_notifier_init failed %d\n", + __func__, __LINE__, rc); + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + do { + QMI_CCI_OS_SIGNAL_CLEAR(&os_params); + /* If service is not up wait on a signal until the service is up + * or a timeout occurs. */ + QMI_CCI_OS_SIGNAL_WAIT(&os_params, LOC_CLIENT_SERVICE_TIMEOUT_UNIT); + nosignal = QMI_CCI_OS_SIGNAL_TIMED_OUT(&os_params); + + // get the service addressing information + rc = qmi_client_get_service_list(locClientServiceObject, NULL, NULL, + &num_services); + + timeout += LOC_CLIENT_SERVICE_TIMEOUT_UNIT; + + LOC_LOGV("%s:%d]: qmi_client_get_service_list() rc %d, nosignal %d, " + "total timeout %d", __func__, __LINE__, rc, nosignal, timeout); + } while (timeout < LOC_CLIENT_SERVICE_TIMEOUT_TOTAL && nosignal && rc != QMI_NO_ERR); + } + + if (0 == num_services || rc != QMI_NO_ERR) { + if (!nosignal) { + LOC_LOGE("%s:%d]: qmi_client_get_service_list failed even though" + "service is up !!! Error %d \n", __func__, __LINE__, rc); + status = eLOC_CLIENT_FAILURE_INTERNAL; + } else { + LOC_LOGE("%s:%d]: qmi_client_get_service_list failed after retries," + " final Err %d", __func__, __LINE__, rc); + status = eLOC_CLIENT_FAILURE_TIMEOUT; + } + break; + } + + pServiceInfo = + (qmi_service_info *)malloc(num_services * sizeof(qmi_service_info)); + + if(NULL == pServiceInfo) + { + LOC_LOGE("%s:%d]: could not allocate memory for serviceInfo !!\n", + __func__, __LINE__); + + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + //set the number of entries to get equal to the total number of + //services. + num_entries = num_services; + //populate the serviceInfo + rc = qmi_client_get_service_list( locClientServiceObject, pServiceInfo, + &num_entries, &num_services); + + + LOC_LOGV("%s:%d]: qmi_client_get_service_list()" + " returned %d num_entries = %d num_services = %d\n", + __func__, __LINE__, + rc, num_entries, num_services); if(rc != QMI_NO_ERR) { - LOC_LOGE("%s:%d]: qmi_client_get_service_list failed even though" - "service is up !!!\n", __func__, __LINE__); + LOC_LOGE("%s:%d]: qmi_client_get_service_list Error %d \n", + __func__, __LINE__, rc); - return(eLOC_CLIENT_FAILURE_INTERNAL); + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; } - } + LOC_LOGV("%s:%d]: passing the pointer %p to qmi_client_init \n", + __func__, __LINE__, pLocClientCbData); - //get service info to be used in qmi_client_init - rc = qmi_client_get_service_list( locClientServiceObject, serviceInfo, - &num_entries, &num_services); + // initialize the client + //sent the address of the first service found + // if IPC router is present, this will go to the service instance + // enumerated over IPC router, else it will go over the next transport where + // the service was enumerated. + rc = qmi_client_init(&pServiceInfo[0], locClientServiceObject, + locClientIndCb, (void *) pLocClientCbData, + NULL, &clnt); - LOC_LOGV("%s:%d]: qmi_client_get_service_list()" - " returned %d num_entries = %d num_services = %d\n", - __func__, __LINE__, - rc, num_entries, num_services); + if(rc != QMI_NO_ERR) + { + LOC_LOGE("%s:%d]: qmi_client_init error %d\n", + __func__, __LINE__, rc); - if(rc != QMI_NO_ERR) + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + LOC_LOGV("%s:%d]: passing the pointer %p to" + "qmi_client_register_error_cb \n", + __func__, __LINE__, pLocClientCbData); + + // register error callback + rc = qmi_client_register_error_cb(clnt, + locClientErrorCb, (void *) pLocClientCbData); + + if( QMI_NO_ERR != rc) + { + LOC_LOGE("%s:%d]: could not register QCCI error callback error:%d\n", + __func__, __LINE__, rc); + + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + + // copy the clnt handle returned in qmi_client_init + memcpy(&(pLocClientCbData->userHandle), &clnt, sizeof(qmi_client_type)); + + status = eLOC_CLIENT_SUCCESS; + + } while(0); + + /* release the notifier handle */ + if(true == notifierInitFlag) { - LOC_LOGE("%s:%d]: qmi_client_get_service_list Error %d \n", - __func__, __LINE__, rc); - - return(eLOC_CLIENT_FAILURE_INTERNAL); + qmi_client_release(notifier); } - LOC_LOGV("%s:%d]: passing the pointer %p to qmi_client_init \n", - __func__, __LINE__, pLocClientCbData); - // initialize the client - rc = qmi_client_init(&serviceInfo[0], locClientServiceObject, - locClientIndCb, (void *) pLocClientCbData, - NULL, &clnt); - - if(rc != QMI_NO_ERR) + if(NULL != pServiceInfo) { - LOC_LOGE("%s:%d]: qmi_client_init error %d\n", - __func__, __LINE__, rc); - return(eLOC_CLIENT_FAILURE_INTERNAL); + free((void *)pServiceInfo); } - LOC_LOGV("%s:%d]: passing the pointer %p to" - "qmi_client_register_error_cb \n", - __func__, __LINE__, pLocClientCbData); - - // register error callback - rc = qmi_client_register_error_cb(clnt, - locClientErrorCb, (void *) pLocClientCbData); - - if( QMI_NO_ERR != rc) - { - LOC_LOGE("%s:%d]: could not register QCCI error callback error:%d\n", - __func__, __LINE__, rc); - return (eLOC_CLIENT_FAILURE_INTERNAL); - } - - // copy the clnt handle returned in qmi_client_init - memcpy(&(pLocClientCbData->userHandle), &clnt, sizeof(qmi_client_type)); - - return(eLOC_CLIENT_SUCCESS); - + return status; } //----------------------- END INTERNAL FUNCTIONS ---------------------------------------- @@ -1592,6 +1778,8 @@ locClientStatusEnumType locClientOpen ( { free(pCallbackData); pCallbackData = NULL; + LOC_LOGE ("%s:%d] locClientQmiCtrlPointInit returned %d\n", + __func__, __LINE__, status); break; } @@ -1638,6 +1826,7 @@ locClientStatusEnumType locClientOpen ( if(eLOC_CLIENT_SUCCESS != status) { *pLocClientHandle = LOC_CLIENT_INVALID_HANDLE_VALUE; + LOC_LOGE("%s:%d]: Error! status = %d\n", __func__, __LINE__,status); } return(status); @@ -1684,7 +1873,7 @@ locClientStatusEnumType locClientClose( return(eLOC_CLIENT_FAILURE_INVALID_HANDLE); } - LOC_LOGV("locClientClose releasing handle 0x%x, user handle 0x%x\n", + LOC_LOGV("locClientClose releasing handle %p, user handle %p\n", *pLocClientHandle, pCallbackData->userHandle ); // NEXT call goes out to modem. We log the callflow before it @@ -1692,6 +1881,7 @@ locClientStatusEnumType locClientClose( // back from the modem, to avoid confusing log order. We trust // that the QMI framework is robust. EXIT_LOG_CALLFLOW(%s, "loc client close"); + // release the handle rc = qmi_client_release(pCallbackData->userHandle); if(QMI_NO_ERR != rc ) @@ -1713,7 +1903,6 @@ locClientStatusEnumType locClientClose( // set the handle to invalid value *pLocClientHandle = LOC_CLIENT_INVALID_HANDLE_VALUE; - return eLOC_CLIENT_SUCCESS; } @@ -1779,7 +1968,6 @@ locClientStatusEnumType locClientSendReq( // back from the modem, to avoid confusing log order. We trust // that the QMI framework is robust. EXIT_LOG_CALLFLOW(%s, loc_get_v02_event_name(reqId)); - rc = qmi_client_send_msg_sync( pCallbackData->userHandle, reqId, @@ -1801,6 +1989,17 @@ locClientStatusEnumType locClientSendReq( // map the QCCI response to Loc API v02 status status = convertQmiResponseToLocStatus(&resp); + // if the request is to change registered events, update the + // loc api copy of that + if(eLOC_CLIENT_SUCCESS == status && + QMI_LOC_REG_EVENTS_REQ_V02 == reqId) + { + if(NULL != reqPayload.pRegEventsReq ) + { + pCallbackData->eventRegMask = + (locClientEventMaskType)(reqPayload.pRegEventsReq->eventRegMask); + } + } return(status); } diff --git a/loc_api/loc_api_v02/loc_api_v02_client.h b/loc_api/loc_api_v02/loc_api_v02_client.h old mode 100755 new mode 100644 index 2807ad47..0ce7a2e8 --- a/loc_api/loc_api_v02/loc_api_v02_client.h +++ b/loc_api/loc_api_v02/loc_api_v02_client.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -112,9 +112,12 @@ typedef enum eLOC_CLIENT_FAILURE_INTERNAL = 11, /**< Failed because of an internal error in the service. */ - eLOC_CLIENT_FAILURE_NOT_INITIALIZED = 12 + eLOC_CLIENT_FAILURE_NOT_INITIALIZED = 12, /**< Failed because the service has not been initialized. */ + eLOC_CLIENT_FAILURE_NOT_ENOUGH_MEMORY = 13 + /**< Failed because not rnough memory to do the operation.*/ + }locClientStatusEnumType; /** Loc Client error values @@ -154,6 +157,8 @@ typedef enum - GetOperationMode - GetCradleMountConfig - GetExternalPowerConfig + - GetSensorControlConfig + - GetSensorPerformanceControlConfiguration */ typedef union { @@ -451,6 +456,17 @@ typedef union QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. @newpage */ + const qmiLocGetSensorPropertiesReqMsgT_v02* pGetSensorPropertiesReq; + /**< Retrieves the sensor properties from the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02. + @newpage */ + const qmiLocSetSensorPropertiesReqMsgT_v02* pSetSensorPropertiesReq; /**< Sets the sensor properties in the engine. @@ -508,6 +524,65 @@ typedef union QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. @newpage */ + const qmiLocAddCircularGeofenceReqMsgT_v02* pAddCircularGeofenceReq; + /**< Adds a Circular Geofence. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 + @newpage */ + + const qmiLocDeleteGeofenceReqMsgT_v02* pDeleteGeofenceReq; + /**< Deletes a Geofence. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_DELETE_GEOFENCE_IND_V02. + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_DELETE_GEOFENCE_REQ_V02 + @newpage */ + + const qmiLocQueryGeofenceReqMsgT_v02* pQueryGeofenceReq; + /**< Queries a Geofence. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_QUERY_GEOFENCE_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_QUERY_GEOFENCE_REQ_V02 + + @newpage */ + + const qmiLocEditGeofenceReqMsgT_v02* pEditGeofenceReq; + /**< Edits Geofence Parameters. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_EDIT_GEOFENCE_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_EDIT_GEOFENCE_REQ_V02 + + @newpage */ + + const qmiLocGetBestAvailablePositionReqMsgT_v02* + pGetBestAvailablePositionReq; + /**< Get the best available position from location engine + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 + + @newpage */ + }locClientReqUnionType; @@ -636,6 +711,31 @@ typedef union QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02. @newpage */ + const qmiLocEventNiGeofenceNotificationIndMsgT_v02* + pNiGeofenceNotificationEvent; + /**< Sent by the engine to notify the client about changes to a + Network Initiated Geofence. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02. + @newpage */ + + const qmiLocEventGeofenceGenAlertIndMsgT_v02* pGeofenceGenAlertEvent; + /**< Sent by the engine to notify the client about updates that may + affect a Geofence operation. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02. + @newpage */ + + const qmiLocEventGeofenceBreachIndMsgT_v02* pGeofenceBreachEvent; + /**< Sent by the engine to notify the client about a Geofence Breach + Event. + + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02. + @newpage */ + }locClientEventIndUnionType; @@ -951,7 +1051,43 @@ typedef union /**< Response to the request, QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 The respIndId field in the response indication callback is set to - QMI_LOC_ET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. + @newpage */ + + const qmiLocAddCircularGeofenceIndMsgT_v02* pAddCircularGeofenceInd; + /**< Response to the request, + QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 + @newpage */ + + const qmiLocDeleteGeofenceIndMsgT_v02* pDeleteGeofenceInd; + /**< Response to the request, + QMI_LOC_DELETE_GEOFENCE_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_DELETE_GEOFENCE_IND_V02 + @newpage */ + + const qmiLocQueryGeofenceIndMsgT_v02* pQueryGeofenceInd; + /**< Response to the request, + QMI_LOC_QUERY_GEOFENCE_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_QUERY_GEOFENCE_IND_V02 + @newpage */ + + const qmiLocEditGeofenceIndMsgT_v02* pEditGeofenceInd; + /**< Response to the request, + QMI_LOC_EDIT_GEOFENCE_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_EDIT_GEOFENCE_IND_V02 + @newpage */ + + const qmiLocGetBestAvailablePositionIndMsgT_v02* + pGetBestAvailablePositionInd; + /**< Response to the request, + QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 + The respIndId field in the response indication callback is set to + QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 @newpage */ }locClientRespIndUnionType; diff --git a/loc_api/loc_api_v02/loc_api_v02_log.c b/loc_api/loc_api_v02/loc_api_v02_log.c old mode 100755 new mode 100644 index 78792607..6f60ee58 --- a/loc_api/loc_api_v02/loc_api_v02_log.c +++ b/loc_api/loc_api_v02/loc_api_v02_log.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -191,6 +191,24 @@ static loc_name_val_s_type loc_v02_event_name[] = NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02), NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02), NAME_VAL(QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02), + NAME_VAL(QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02), + NAME_VAL(QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02), + NAME_VAL(QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02), + NAME_VAL(QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02), + NAME_VAL(QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02), + NAME_VAL(QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02), + NAME_VAL(QMI_LOC_DELETE_GEOFENCE_REQ_V02), + NAME_VAL(QMI_LOC_DELETE_GEOFENCE_RESP_V02), + NAME_VAL(QMI_LOC_DELETE_GEOFENCE_IND_V02), + NAME_VAL(QMI_LOC_QUERY_GEOFENCE_REQ_V02), + NAME_VAL(QMI_LOC_QUERY_GEOFENCE_RESP_V02), + NAME_VAL(QMI_LOC_QUERY_GEOFENCE_IND_V02), + NAME_VAL(QMI_LOC_EDIT_GEOFENCE_REQ_V02), + NAME_VAL(QMI_LOC_EDIT_GEOFENCE_RESP_V02), + NAME_VAL(QMI_LOC_EDIT_GEOFENCE_IND_V02), + NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02), + NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02), + NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02), }; static int loc_v02_event_num = sizeof(loc_v02_event_name) / sizeof(loc_name_val_s_type); @@ -214,6 +232,7 @@ static loc_name_val_s_type loc_v02_client_status_name[] = NAME_VAL(eLOC_CLIENT_FAILURE_INVALID_HANDLE), NAME_VAL(eLOC_CLIENT_FAILURE_INTERNAL), NAME_VAL(eLOC_CLIENT_FAILURE_NOT_INITIALIZED), + NAME_VAL(eLOC_CLIENT_FAILURE_NOT_ENOUGH_MEMORY), }; static int loc_v02_client_status_num = sizeof(loc_v02_client_status_name) / sizeof(loc_name_val_s_type); @@ -233,6 +252,8 @@ static loc_name_val_s_type loc_v02_qmi_status_name[] = eQMI_LOC_ENGINE_BUSY_V02, eQMI_LOC_PHONE_OFFLINE_V02, eQMI_LOC_TIMEOUT_V02, + eQMI_LOC_CONFIG_NOT_SUPPORTED_V02, + eQMI_LOC_INSUFFICIENT_MEMORY_V02, QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 }; static int loc_v02_qmi_status_num = sizeof(loc_v02_qmi_status_name) / sizeof(loc_name_val_s_type); diff --git a/loc_api/loc_api_v02/loc_api_v02_log.h b/loc_api/loc_api_v02/loc_api_v02_log.h old mode 100755 new mode 100644 diff --git a/loc_api/loc_api_v02/loc_util_log.h b/loc_api/loc_api_v02/loc_util_log.h old mode 100755 new mode 100644 index f1b675e3..4c18a229 --- a/loc_api/loc_api_v02/loc_util_log.h +++ b/loc_api/loc_api_v02/loc_util_log.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2009,2011 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -24,13 +24,18 @@ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * */ - #ifndef LOC_UTIL_LOG_H #define LOC_UTIL_LOG_H -#ifdef FEATURE_LOC_API_V02_QNX_MOD +#if defined(_ANDROID_) +#include "loc_api_v02_log.h" +#include + +#else // no _ANDROID_ + +// common for QNX and Griffon + //error logs #define LOC_LOGE(...) printf(__VA_ARGS__) //warning logs @@ -45,22 +50,17 @@ #define MODEM_LOG_CALLFLOW(SPEC, VAL) #define EXIT_LOG_CALLFLOW(SPEC, VAL) -#endif //FEATURE_LOC_API_V02_QNX_MOD +#define loc_get_v02_event_name(X) #X +#define loc_get_v02_client_status_name(X) #X +#define loc_get_v02_qmi_status_name(X) #X + +//specific to OFF TARGET #ifdef LOC_UTIL_TARGET_OFF_TARGET #include - -//error logs -#define LOC_LOGE(...) printf(__VA_ARGS__) -//warning logs -#define LOC_LOGW(...) printf(__VA_ARGS__) -// debug logs -#define LOC_LOGD(...) printf(__VA_ARGS__) -//info logs -#define LOC_LOGI(...) printf(__VA_ARGS__) -//verbose logs -#define LOC_LOGV(...) printf(__VA_ARGS__) +# include +# include // get around strl*: not found in glibc // TBD:look for presence of eglibc other libraries @@ -68,14 +68,8 @@ #define strlcpy(X,Y,Z) strcpy(X,Y) #define strlcat(X,Y,Z) strcat(X,Y) -#define MODEM_LOG_CALLFLOW(SPEC, VAL) -#define EXIT_LOG_CALLFLOW(SPEC, VAL) - -#elif defined(_ANDROID_) - -#include - #endif //LOC_UTIL_TARGET_OFF_TARGET +#endif //_ANDROID_ #endif //LOC_UTIL_LOG_H diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c old mode 100755 new mode 100644 index 37d93f6f..ebd1a376 --- a/loc_api/loc_api_v02/location_service_v02.c +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -26,6 +26,15 @@ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + + L O C A T I O N _ S E R V I C E _ V 0 2 . C + +GENERAL DESCRIPTION + This is the file which defines the loc service Data structures. + +*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + #include "stdint.h" #include "qmi_idl_lib_internal.h" #include "location_service_v02.h" @@ -33,6 +42,25 @@ /*Type Definitions*/ +static const uint8_t qmiLocApplicationIdStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationProvider), + QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02, + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationName), + QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02, + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion_valid), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion), + QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { QMI_IDL_GENERIC_2_BYTE, QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), @@ -116,7 +144,7 @@ static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), @@ -131,7 +159,7 @@ static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), @@ -169,7 +197,7 @@ static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { }; static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_2_BYTE, QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), QMI_LOC_IPV6_ADDR_LENGTH_V02, @@ -185,11 +213,11 @@ static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), - 7, 0, + 8, 0, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), - 8, 0, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + 9, 0, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, @@ -202,12 +230,12 @@ static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), - 9, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + 10, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), QMI_LOC_NI_SUPL_HASH_LENGTH_V02, @@ -219,13 +247,13 @@ static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), - 5, 0, + 6, 0, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), - 5, 0, + 6, 0, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), - 6, 0, + 7, 0, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), @@ -236,7 +264,7 @@ static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), @@ -254,12 +282,12 @@ static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), @@ -269,10 +297,10 @@ static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), - 11, 0, + 12, 0, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), - 11, 0, + 12, 0, QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), @@ -285,7 +313,7 @@ static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), - 4, 0, + 5, 0, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), @@ -293,7 +321,7 @@ static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { }; static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, @@ -304,11 +332,11 @@ static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), QMI_LOC_MAX_NTP_SERVERS_V02, QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), - 14, 0, + 15, 0, QMI_IDL_FLAG_END_VALUE }; @@ -323,11 +351,11 @@ static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { }; static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), - 14, 0, + 15, 0, QMI_IDL_FLAG_END_VALUE }; @@ -347,7 +375,59 @@ static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), - 18, 0, + 19, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGeofencePositionStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, timestampUtc), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMinor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMajor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading), + QMI_IDL_FLAG_END_VALUE }; @@ -414,7 +494,7 @@ static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { }; static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, @@ -453,11 +533,11 @@ static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { QMI_IDL_GENERIC_1_BYTE, QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), - 26, 0, + 28, 0, QMI_IDL_FLAG_END_VALUE }; @@ -465,13 +545,39 @@ static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), QMI_LOC_MAX_APN_NAME_LENGTH_V02, QMI_IDL_FLAG_END_VALUE }; +static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, radius), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), + + QMI_IDL_FLAG_END_VALUE +}; + /*Message Definitions*/ static const uint8_t qmiLocGenRespMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, @@ -512,10 +618,16 @@ static const uint8_t qmiLocStartReqMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), 0x13, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId), + 0, 0 }; static const uint8_t qmiLocStopReqMsgT_data_v02[] = { @@ -637,7 +749,7 @@ static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { 0x24, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), - 1, 0, + 2, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), 0x25, @@ -653,7 +765,7 @@ static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { 0x27, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), - 0, 0, + 1, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), 0x28, @@ -669,12 +781,19 @@ static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { 0x2A, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), - 2, 0, + 3, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), 0x2B, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId) + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_valid)), + 0x2C, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_len) }; static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { @@ -684,16 +803,16 @@ static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), - 3, 0 + 4, 0 }; static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 }; @@ -707,25 +826,31 @@ static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), - 4, 0, + 5, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), 0x11, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), - 10, 0, + 11, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), 0x12, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), - 12, 0, + 13, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), 0x13, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), - 13, 0 + 14, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), + 32, 0 }; static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { @@ -733,20 +858,20 @@ static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), - 15, 0 + 16, 0 }; static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { 0x01, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), - 16, 0, + 17, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), - 17, 0 + 18, 0 }; static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { @@ -800,13 +925,13 @@ static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), - 19, 0 + 20, 0 }; static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { @@ -835,6 +960,38 @@ static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) }; +static const uint8_t qmiLocEventNiGeofenceNotificationIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, operationType) +}; + +static const uint8_t qmiLocEventGeofenceGenAlertIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceGenAlertIndMsgT_v02, geofenceAlert) +}; + +static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, breachType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition) - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), + 21, 0 +}; + /* * qmiLocGetServiceRevisionReqMsgT is empty * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { @@ -846,9 +1003,27 @@ static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + 0x02, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision) + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString), + QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString), + QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_STRING, + QMI_IDL_OFFSET16ARRAY(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString), + QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 }; /* @@ -872,10 +1047,16 @@ static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), 0x12, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId_valid)), + 0x13, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId), + 0, 0 }; static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { @@ -891,25 +1072,31 @@ static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), - 4, 0, + 5, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), 0x11, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), - 10, 0, + 11, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), 0x12, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), - 12, 0, + 13, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), 0x13, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), - 13, 0 + 14, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), + 32, 0 }; static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { @@ -969,13 +1156,13 @@ static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), - 16, 0, + 17, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), - 17, 0 + 18, 0 }; /* @@ -993,7 +1180,7 @@ static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), - 20, 0 + 22, 0 }; static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { @@ -1067,7 +1254,7 @@ static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { 0x1A, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), - 21, 0, + 23, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), 0x1B, @@ -1216,17 +1403,17 @@ static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), - 7, 0, + 8, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), - 8, 0, + 9, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 }; @@ -1261,17 +1448,17 @@ static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), - 7, 0, + 8, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), - 8, 0, + 9, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 }; @@ -1283,11 +1470,11 @@ static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), - 22, 0, + 24, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), 0x11, @@ -1345,21 +1532,21 @@ static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), - 23, 0, + 25, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), - 24, 0, + 26, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), - 25, 0, + 27, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), 0x13, @@ -1458,13 +1645,13 @@ static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), - 27, 0, + 29, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), 0x12, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), - 27, 0 + 29, 0 }; static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { @@ -1593,7 +1780,7 @@ static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), - 28, 0 + 30, 0 }; static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { @@ -1613,10 +1800,15 @@ static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), 0x12, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) }; static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { @@ -1651,10 +1843,15 @@ static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), 0x12, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) }; static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { @@ -1688,33 +1885,78 @@ static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { }; static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), 0x10, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) }; static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + 0x01, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status) + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) }; -/* - * qmiLocGetSensorPropertiesReqMsgT is empty - * static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { - * }; - */ +static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesReqMsgT_v02, getSensorPropertiesMask) +}; static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { 0x01, QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), 0x10, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) }; static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { @@ -1727,13 +1969,18 @@ static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), - 18, 0, + 19, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), 0x12, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), - 18, 0 + 19, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) }; static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { @@ -1767,13 +2014,18 @@ static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), - 18, 0, + 19, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), 0x12, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), - 18, 0 + 19, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) }; static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { @@ -1862,8 +2114,335 @@ static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) }; +static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, transactionId), + + 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), + 31, 0, + + 0x03, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, breachMask), + + 0x04, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, includePosition), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) +}; + +static const uint8_t qmiLocAddCircularGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) +}; + +static const uint8_t qmiLocDeleteGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocDeleteGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), + 31, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) +}; + +static const uint8_t qmiLocEditGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) +}; + +static const uint8_t qmiLocEditGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) +}; + +static const uint8_t qmiLocGetBestAvailablePositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude_valid)), + 0x12, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc_valid)), + 0x16, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence_valid)), + 0x1B, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence_valid)), + 0x1C, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence_valid)), + 0x21, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc_valid)), + 0x24, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading_valid)), + 0x25, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc_valid)), + 0x26, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation_valid)), + 0x27, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP_valid)), + 0x29, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP), + 2, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage_valid)), + 0x2C, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage), + 3, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_valid)), + 0x2D, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) +}; + /* Type Table */ static const qmi_idl_type_table_entry loc_type_table_v02[] = { + {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, @@ -1884,6 +2463,7 @@ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, + {sizeof(qmiLocGeofencePositionStructT_v02), qmiLocGeofencePositionStructT_data_v02}, {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, @@ -1892,7 +2472,9 @@ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, - {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02} + {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, + {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, + {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02} }; /* Message Table */ @@ -1916,6 +2498,9 @@ static const qmi_idl_message_table_entry loc_message_table_v02[] = { {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), qmiLocEventNiGeofenceNotificationIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), qmiLocEventGeofenceGenAlertIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), qmiLocEventGeofenceBreachIndMsgT_data_v02}, {0, 0}, {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, {0, 0}, @@ -1994,7 +2579,7 @@ static const qmi_idl_message_table_entry loc_message_table_v02[] = { {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, - {0, 0}, + {sizeof(qmiLocGetSensorPropertiesReqMsgT_v02), qmiLocGetSensorPropertiesReqMsgT_data_v02}, {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, @@ -2007,7 +2592,17 @@ static const qmi_idl_message_table_entry loc_message_table_v02[] = { {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02} + {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceReqMsgT_v02), qmiLocAddCircularGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceIndMsgT_v02), qmiLocAddCircularGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceReqMsgT_v02), qmiLocDeleteGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceIndMsgT_v02), qmiLocDeleteGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceReqMsgT_v02), qmiLocQueryGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceIndMsgT_v02), qmiLocQueryGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02} }; /* Predefine the Type Table Object */ @@ -2031,54 +2626,59 @@ static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, - {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 32}, + {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 103}, {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, - {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 19), 0}, - {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 21), 0}, - {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 23), 1075}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 25), 1053}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 27), 0}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 29), 0}, - {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 31), 18}, - {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 33), 112}, - {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 35), 7}, - {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 37), 0}, - {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 39), 4}, - {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 41), 0}, - {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 43), 7}, - {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 45), 0}, - {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 47), 4}, - {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 49), 0}, - {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 51), 297}, - {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 53), 11}, - {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 55), 929}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 57), 4}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 59), 0}, - {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 61), 694}, - {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 63), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 65), 0}, - {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 67), 7}, - {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 69), 0}, - {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 71), 8}, - {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 73), 1425}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 75), 21}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 79), 11}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 77), 0}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 83), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 81), 0}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 85), 129}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 87), 18}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 89), 11}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 91), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 93), 0}, - {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 95), 7}, - {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 97), 0}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 99), 21}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 101), 0}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 103), 2009}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 105), 4}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 107), 12}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 109), 7} + {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 22), 0}, + {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 24), 0}, + {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 26), 1086}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 28), 1053}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 30), 0}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 32), 0}, + {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 34), 18}, + {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 36), 112}, + {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 38), 7}, + {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 40), 0}, + {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 42), 4}, + {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 44), 0}, + {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 46), 7}, + {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 48), 0}, + {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 50), 4}, + {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 52), 0}, + {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 54), 297}, + {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 56), 11}, + {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 58), 929}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 60), 4}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 62), 0}, + {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 64), 694}, + {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 66), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 68), 0}, + {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 70), 7}, + {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 72), 0}, + {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 74), 8}, + {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 76), 1425}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 78), 21}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 82), 11}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 80), 0}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 25}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, + {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, + {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 28}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 110), 12}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 112), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02, TYPE16(0, 114), 52}, + {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, + {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, + {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7} }; static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { @@ -2131,14 +2731,19 @@ static const qmi_idl_service_message_table_entry loc_service_response_messages_v {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7} + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7} }; static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { - {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 224}, + {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 388}, {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, - {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1068}, + {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1079}, {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, @@ -2149,65 +2754,75 @@ static const qmi_idl_service_message_table_entry loc_service_indication_messages {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, - {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 20), 14}, - {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 22), 28}, - {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 24), 7}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 26), 12}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 28), 790}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 30), 20}, - {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 32), 7}, - {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 34), 7}, - {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 36), 7}, - {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 38), 14}, - {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 40), 7}, - {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 42), 11}, - {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 44), 7}, - {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 46), 14}, - {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 48), 7}, - {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 50), 11}, - {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 52), 7}, - {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 54), 304}, - {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 56), 7}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 58), 7}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 60), 11}, - {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 62), 7}, - {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 64), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 66), 18}, - {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 68), 7}, - {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 70), 14}, - {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 72), 7}, - {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 74), 22}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 76), 7}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 80), 7}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 78), 18}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 84), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 82), 14}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 86), 7}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 88), 18}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 90), 25}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 92), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 94), 14}, - {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 96), 7}, - {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 98), 14}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 100), 14}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 102), 28}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 104), 7}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 106), 7}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 108), 14}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 110), 19} + {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 23), 532}, + {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 25), 99}, + {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 27), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 29), 12}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 31), 790}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 33), 20}, + {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 35), 7}, + {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 37), 7}, + {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 39), 7}, + {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 41), 14}, + {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 43), 7}, + {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 45), 11}, + {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 47), 7}, + {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 49), 14}, + {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 51), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 53), 11}, + {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 55), 7}, + {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 57), 304}, + {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 59), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 61), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 63), 11}, + {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 65), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 67), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 69), 18}, + {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 71), 7}, + {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 73), 14}, + {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 75), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 77), 22}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 79), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 83), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 81), 18}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 87), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 32}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, + {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, + {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 35}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 113), 19}, + {QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, TYPE16(0, 19), 14}, + {QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, TYPE16(0, 20), 7}, + {QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, TYPE16(0, 21), 78}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, TYPE16(0, 115), 21}, + {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, + {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, + {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391} }; /*Service Object*/ -const struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { +struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { + 0x05, 0x02, - 0x02, - 16, + 0x10, 2248, { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, - &loc_qmi_idl_type_table_object_v02 + &loc_qmi_idl_type_table_object_v02, + 0x0B, + NULL }; /* Service Object Accessor */ diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h old mode 100755 new mode 100644 index 2f288145..c3d67702 --- a/loc_api/loc_api_v02/location_service_v02.h +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, Code Aurora Forum. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -82,11 +82,11 @@ extern "C" { /** Major Version Number of the IDL used to generate this file */ #define LOC_V02_IDL_MAJOR_VERS 0x02 /** Revision Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MINOR_VERS 0x04 +#define LOC_V02_IDL_MINOR_VERS 0x0B /** Major Version Number of the qmi_idl_compiler used to generate this file */ -#define LOC_V02_IDL_TOOL_VERS 0x02 +#define LOC_V02_IDL_TOOL_VERS 0x05 /** Maximum Defined Message ID */ -#define LOC_V02_MAX_MESSAGE_ID 0x005F; +#define LOC_V02_MAX_MESSAGE_ID 0x0067; /** @} */ @@ -96,6 +96,19 @@ extern "C" { @{ */ +/** Maximum string length for the Provider field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 24 + +/** Maximum string length for the Name field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 32 + +/** Maximum string length for the Version field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 8 + +/** Maximum length of the list containing the SVs that were used to generate + a position report. */ +#define QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02 80 + /** Maximum number of satellites in the satellite report. */ #define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 @@ -133,6 +146,15 @@ extern "C" { engine. */ #define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 +/** Maximum GNSS Measurement Engine Firmware Version String length. */ +#define QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Hosted Software Version String length. */ +#define QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Full Version String length. */ +#define QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 255 + /** Maximum part length that can be injected. The client should also look at the maxPartSize field in the predicted orbits injection request indication and pick the minimum of the two. */ @@ -156,7 +178,7 @@ extern "C" { /** Maximum APN profiles supported. */ #define QMI_LOC_MAX_APN_PROFILES_V02 6 -/** Maximum length of SUPL CERT. */ +/** Maximum length of the SUPL certificate. */ #define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 /** @} @@ -188,45 +210,54 @@ typedef struct { /* Mandatory */ /* Revision */ uint32_t revision; - /**< Revision that the control point is using. \n - - Type: Unsigned integer */ + /**< Revision that the control point is using. */ }qmiLocInformClientRevisionReqMsgT_v02; /* Message */ /** @} */ typedef uint64_t qmiLocEventRegMaskT_v02; -#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001) /**< The control point must enable this mask to receive position report +#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001ull) /**< The control point must enable this mask to receive position report event indications. */ -#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002) /**< The control point must enable this mask to receive satellite report +#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002ull) /**< The control point must enable this mask to receive satellite report event indications. These reports are sent at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004) /**< The control point must enable this mask to receive NMEA reports for +#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004ull) /**< The control point must enable this mask to receive NMEA reports for position and satellites in view. The report is at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008) /**< The control point must enable this mask to receive NI notify verify request +#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008ull) /**< The control point must enable this mask to receive NI notify verify request event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010) /**< The control point must enable this mask to receive time injection request +#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010ull) /**< The control point must enable this mask to receive time injection request event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020) /**< The control point must enable this mask to receive predicted orbits request +#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020ull) /**< The control point must enable this mask to receive predicted orbits request event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040) /**< The control point must enable this mask to receive position injection request +#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040ull) /**< The control point must enable this mask to receive position injection request event indications. */ -#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080) /**< The control point must enable this mask to receive engine state report +#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080ull) /**< The control point must enable this mask to receive engine state report event indications. */ -#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100) /**< The control point must enable this mask to receive fix session status report +#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100ull) /**< The control point must enable this mask to receive fix session status report event indications. */ -#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200) /**< The control point must enable this mask to receive WiFi position request +#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200ull) /**< The control point must enable this mask to receive WiFi position request event indications. */ -#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400) /**< The control point must enable this mask to receive notifications from the +#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400ull) /**< The control point must enable this mask to receive notifications from the GPS engine indicating its readiness to accept data from the - sensors (accelerometer, gyrometer, etc.). */ -#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800) /**< The control point must enable this mask to receive time-sync requests from - the GPS engine. Time sync enables the GPS engine to synchronize + sensors (accelerometer, gyroscope, etc.). */ +#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800ull) /**< The control point must enable this mask to receive time-sync requests + from the GPS engine. Time sync enables the GPS engine to synchronize its clock with the sensor processor's clock. */ -#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000) /**< The control point must enable this mask to receive Stationary Position - Indicator (SPI) streaming report indications. */ -#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000) /**< The control point must enable this mask to receive location server requests. - These requests are generated when the service wishes to establish a - connection with a location server. */ +#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000ull) /**< The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. */ +#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000ull) /**< The control point must enable this mask to receive location server + requests. These requests are generated when the service wishes to + establish a connection with a location server. */ +#define QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00004000ull) /**< The control point must enable this mask to receive notifications + related to network-initiated Geofences. These events notify the client + when a network-initiated Geofence is added, deleted, or edited. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02 ((qmiLocEventRegMaskT_v02)0x00008000ull) /**< The control point must enable this mask to receive Geofence alerts. + These alerts are generated to inform the client of the changes that may + affect Geofence, e.g., if GPS is turned off or if the network is + unavailable. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00010000ull) /**< The control point must enable this mask to receive notifications when + a Geofence is breached. These events are generated when the UE enters + or leaves the perimeter of a Geofence. */ /** @addtogroup loc_qmi_messages @{ */ @@ -238,23 +269,26 @@ typedef struct { /* Event Registration Mask */ qmiLocEventRegMaskT_v02 eventRegMask; /**< Specifies the events that the control point is interested in receiving. - Refer to the definition of the following bitmasks: \n - - - 0x00000001 -- POSITION_REPORT \n - - 0x00000002 -- GNSS_SV_INFO \n - - 0x00000004 -- NMEA \n - - 0x00000008 -- NI_NOTIFY_VERIFY_REQ \n - - 0x00000010 -- INJECT_TIME_REQ \n - - 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ \n - - 0x00000040 -- INJECT_POSITION_REQ \n - - 0x00000080 -- ENGINE_STATE \n - - 0x00000100 -- FIX_SESSION_STATE \n - - 0x00000200 -- WIFI_REQ \n - - 0x00000400 -- SENSOR_STREAMING_READY_STATUS \n - - 0x00000800 -- TIME_SYNC_REQ \n - - 0x00001000 -- SET_SPI_STREAMING_REPORT \n - - 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ - + Refer to the definition of the following bitmasks: + \vspace{0.05in} \begin{itemize1} + \item 0x00000001 -- POSITION_REPORT + \item 0x00000002 -- GNSS_SV_INFO + \item 0x00000004 -- NMEA + \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ + \item 0x00000010 -- INJECT_TIME_REQ + \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ + \item 0x00000040 -- INJECT_POSITION_REQ + \item 0x00000080 -- ENGINE_STATE + \item 0x00000100 -- FIX_SESSION_STATE + \item 0x00000200 -- WIFI_REQ + \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS + \item 0x00000800 -- TIME_SYNC_REQ + \item 0x00001000 -- SET_SPI_STREAMING_REPORT + \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ + \item 0x00004000 -- NI_GEOFENCE_NOTIFICATION + \item 0x00008000 -- GEOFENCE_GEN_ALERT + \item 0x00010000 -- GEOFENCE_BREACH_NOTIFICATION + \end{itemize1} \vspace{0.05in} Multiple events can be registered by ORing the individual masks and sending them in this TLV. All unused bits in this mask must be set to 0. */ @@ -306,6 +340,31 @@ typedef enum { @} */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; + /**< Application provider. */ + + char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; + /**< Application name. */ + + uint8_t applicationVersion_valid; + /**< Specifies whether the application version string contains a valid value: + \begin{itemize1} + \item 0x00 (FALSE) -- Application version string is invalid + \item 0x01 (TRUE) -- Application version string is valid + \vspace{-0.18in} \end{itemize1} */ + + char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; + /**< Application version. */ +}qmiLocApplicationIdStructT_v02; /* Type */ +/** + @} + */ + /** @addtogroup loc_qmi_messages @{ */ @@ -319,7 +378,6 @@ typedef struct { /**< ID of the session as identified by the control point. The session ID is reported back in the position reports. The control point must specify the same session ID in the QMI_LOC_STOP_REQ message. \n - - Type: Unsigned integer \n - Range: 0 to 255 */ @@ -342,10 +400,13 @@ typedef struct { /**< Specifies the horizontal accuracy level required by the control point. If not specified, accuracy defaults to LOW. - Valid values: \n - - 0x00000001 -- LOW: Client requires low horizontal accuracy.\n - - 0x00000002 -- MED: Client requires medium horizontal accuracy.\n - - 0x00000003 -- HIGH: Client requires high horizontal accuracy. + Valid values: + \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} + \end{itemize1} */ /* Optional */ @@ -361,9 +422,14 @@ typedef struct { report is set to IN_PROGRESS in order for the control point to identify intermediate reports. - Valid values: \n - - 0x00000001 -- ON: Client is interested in receiving intermediate reports \n - - 0x00000002 -- OFF: Client is not interested in receiving intermediate reports + Valid values: + \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} + \end{itemize1} */ /* Optional */ @@ -372,10 +438,15 @@ typedef struct { uint32_t minInterval; /**< Minimum time interval, specified by the control point, that must elapse between position reports. \n - - Type: Unsigned integer \n - Units: Milliseconds \n - Default: 1000 ms */ + + /* Optional */ + /* ID of the Application that Sent this Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version. */ }qmiLocStartReqMsgT_v02; /* Message */ /** @} @@ -393,7 +464,6 @@ typedef struct { uint8_t sessionId; /**< ID of the session that was specified in the Start request (QMI_LOC_START_REQ).\n - - Type: Unsigned integer \n - Range: 0 to 255 */ }qmiLocStopReqMsgT_v02; /* Message */ /** @@ -404,6 +474,8 @@ typedef uint32_t qmiLocPosTechMaskT_v02; #define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ #define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ #define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ /** @addtogroup loc_qmi_enums @{ */ @@ -433,12 +505,10 @@ typedef struct { uint16_t gpsWeek; /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n - - Type: Unsigned integer \n - Units: Weeks */ uint32_t gpsTimeOfWeekMs; /**< Amount of time into the current GPS week. \n - - Type: Unsigned integer \n - Units: Milliseconds */ }qmiLocGPSTimeStructT_v02; /* Type */ /** @@ -451,20 +521,23 @@ typedef struct { typedef struct { float PDOP; - /**< Position dilution of precision.\n - - Type: Floating point \n - - Range: 1 (highest accuracy) to 50 (lowest accuracy)\n - - PDOP = square root of (HDOP^2 + VDOP^2) */ + /**< Position dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \item PDOP = square root of (HDOP^2 + VDOP^2) + \vspace{-0.18in} \end{itemize1} */ float HDOP; - /**< Horizontal dilution of precision.\n - - Type: Floating point \n - - Range: 1 (highest accuracy) to 50 (lowest accuracy) */ + /**< Horizontal dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ float VDOP; - /**< Vertical dilution of precision.\n - - Type: Floating point. \n - - Range: 1 (highest accuracy) to 50 (lowest accuracy) */ + /**< Vertical dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ }qmiLocDOPStructT_v02; /* Type */ /** @} @@ -472,7 +545,7 @@ typedef struct { typedef uint32_t qmiLocSensorUsageMaskT_v02; #define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ -#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyrometer was used. */ +#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyroscope was used. */ typedef uint32_t qmiLocSensorAidedMaskT_v02; #define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ #define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ @@ -484,16 +557,19 @@ typedef uint32_t qmiLocSensorAidedMaskT_v02; typedef struct { qmiLocSensorUsageMaskT_v02 usageMask; - /**< Specifies which sensors are used. + /**< Specifies which sensors were used in calculating the position in the + position report. - Valid bitmasks are specified by the following constants: \n - - 0x00000001 -- SENSOR_USED_ACCEL \n - - 0x00000002 -- SENSOR_USED_GYRO */ + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- SENSOR_USED_ACCEL + \item 0x00000002 -- SENSOR_USED_GYRO + \vspace{-0.18in} \end{itemize1} */ qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; - /**< Specifies which results are aided by sensors. + /**< Specifies which results were aided by sensors. - Valid bitmasks are specified by the following constants: \n + Valid bitmasks: \n - 0x00000001 -- AIDED_HEADING \n - 0x00000002 -- AIDED_SPEED \n - 0x00000004 -- AIDED_POSITION \n @@ -562,15 +638,17 @@ typedef struct { qmiLocSessionStatusEnumT_v02 sessionStatus; /**< Session status. - Valid values: \n - - 0x00000000 -- SESS_STATUS_SUCCESS \n - - 0x00000001 -- SESS_STATUS_IN_PROGRESS \n - - 0x00000002 -- SESS_STATUS_GENERAL_FAILURE \n - - 0x00000003 -- SESS_STATUS_TIMEOUT \n - - 0x00000004 -- SESS_STATUS_USER_END \n - - 0x00000005 -- SESS_STATUS_BAD_PARAMETER \n - - 0x00000006 -- SESS_STATUS_PHONE_OFFLINE \n - - 0x00000007 -- SESS_STATUS_ENGINE_LOCKED + Valid values: + \begin{itemize1} + \item 0x00000000 -- SESS_STATUS_SUCCESS + \item 0x00000001 -- SESS_STATUS_IN_PROGRESS + \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE + \item 0x00000003 -- SESS_STATUS_TIMEOUT + \item 0x00000004 -- SESS_STATUS_USER_END + \item 0x00000005 -- SESS_STATUS_BAD_PARAMETER + \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE + \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED + \vspace{-0.18in} \end{itemize1} */ /* Mandatory */ @@ -578,37 +656,39 @@ typedef struct { uint8_t sessionId; /**< ID of the session that was specified in the Start request QMI_LOC_START_REQ. \n - - Type: Unsigned integer \n - Range: 0 to 255 */ /* Optional */ /* Latitude */ uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ double latitude; - /**< Latitude (specified in WGS84 datum). \n - - Type: Floating point \n - - Units: Degrees \n - - Range: -90.0 to 90.0 \n - - Positive values indicate northern latitude \n - - Negative values indicate southern latitude */ + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Longitude */ uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ double longitude; - /**< Longitude (specified in WGS84 datum).\n - - Type: Floating point \n - - Units: Degrees \n - - Range: -180.0 to 180.0 \n - - Positive values indicate eastern longitude \n - - Negative values indicate western longitude */ + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Circular Horizontal Position Uncertainty */ uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -616,7 +696,6 @@ typedef struct { uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ float horUncEllipseSemiMinor; /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -624,7 +703,6 @@ typedef struct { uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ float horUncEllipseSemiMajor; /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -632,7 +710,6 @@ typedef struct { uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ float horUncEllipseOrientAzimuth; /**< Elliptical horizontal uncertainty azimuth of orientation.\n - - Type: Floating point \n - Units: Decimal degrees \n - Range: 0 to 180 */ @@ -641,7 +718,6 @@ typedef struct { uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ uint8_t horConfidence; /**< Horizontal uncertainty confidence.\n - - Type: Unsigned integer \n - Units: Percent \n - Range: 0 to 99 */ @@ -649,14 +725,15 @@ typedef struct { /* Horizontal Reliability */ uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \n - - 0x00000000 -- RELIABILITY_NOT_SET \n - - 0x00000001 -- RELIABILITY_VERY_LOW \n - - 0x00000002 -- RELIABILITY_LOW \n - - 0x00000003 -- RELIABILITY_MEDIUM \n - - 0x00000004 -- RELIABILITY_HIGH + /**< Specifies the reliability of the horizontal position. \n + Valid values: + \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -664,15 +741,13 @@ typedef struct { uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ float speedHorizontal; /**< Horizontal speed.\n - - Type: Floating point \n - Units: Meters/second */ /* Optional */ /* Speed Uncertainty */ uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ float speedUnc; - /**< Speed uncertainty.\n - - Type: Floating point \n + /**< 3-D Speed uncertainty.\n - Units: Meters/second */ /* Optional */ @@ -680,7 +755,6 @@ typedef struct { uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ float altitudeWrtEllipsoid; /**< Altitude with respect to the WGS84 ellipsoid.\n - - Type: Floating point \n - Units: Meters \n - Range: -500 to 15883 */ @@ -689,7 +763,6 @@ typedef struct { uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ float altitudeWrtMeanSeaLevel; /**< Altitude with respect to mean sea level.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -697,7 +770,6 @@ typedef struct { uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ float vertUnc; /**< Vertical uncertainty.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -705,7 +777,6 @@ typedef struct { uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ uint8_t vertConfidence; /**< Vertical uncertainty confidence.\n - - Type: Unsigned integer \n - Units: Percent \n - Range: 0 to 99 */ @@ -713,21 +784,21 @@ typedef struct { /* Vertical Reliability */ uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. - - Valid values: \n - - 0x00000000 -- RELIABILITY_NOT_SET \n - - 0x00000001 -- RELIABILITY_VERY_LOW \n - - 0x00000002 -- RELIABILITY_LOW \n - - 0x00000003 -- RELIABILITY_MEDIUM \n - - 0x00000004 -- RELIABILITY_HIGH */ + /**< Specifies the reliability of the vertical position. \n + Valid values: + \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Vertical Speed */ uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ float speedVertical; /**< Vertical speed.\n - - Type: Floating point \n - Units: Meters/second */ /* Optional */ @@ -735,7 +806,6 @@ typedef struct { uint8_t heading_valid; /**< Must be set to true if heading is being passed */ float heading; /**< Heading.\n - - Type: Floating point \n - Units: Degrees \n - Range: 0 to 359.999 */ @@ -744,7 +814,6 @@ typedef struct { uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ float headingUnc; /**< Heading uncertainty.\n - - Type: Floating point \n - Units: Degrees \n - Range: 0 to 359.999 */ @@ -754,8 +823,7 @@ typedef struct { float magneticDeviation; /**< Difference between the bearing to true north and the bearing shown on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. \n - - Type: Floating point */ + north is east of true north. */ /* Optional */ /* Technology Used */ @@ -765,8 +833,10 @@ typedef struct { Valid bitmasks: \n - 0x00000001 -- SATELLITE \n - - 0x00000002 -- CELLID \n - - 0x00000004 -- WIFI */ + - 0x00000002 -- CELLID \n + - 0x00000004 -- WIFI \n + - 0x00000008 -- SENSORS \n + - 0x00000010 -- REFERENCE_LOCATION */ /* Optional */ /* Dilution of Precision */ @@ -779,7 +849,6 @@ typedef struct { uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ uint64_t timestampUtc; /**< UTC timestamp. \n - - Type: Unsigned integer \n - Units: Milliseconds since Jan. 1, 1970 */ /* Optional */ @@ -789,11 +858,10 @@ typedef struct { /**< Leap second information. If leapSeconds is not available, timestampUtc is calculated based on a hard-coded value for leap seconds. \n - - Type: Unsigned integer \n - Units: Seconds */ /* Optional */ - /* GPS Time \n */ + /* GPS Time */ uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ qmiLocGPSTimeStructT_v02 gpsTime; /**< \n The number of weeks since Jan. 5, 1980, and @@ -804,7 +872,6 @@ typedef struct { uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ float timeUnc; /**< Time uncertainty. \n - - Type: Floating point \n - Units: Milliseconds */ /* Optional */ @@ -813,16 +880,18 @@ typedef struct { qmiLocTimeSourceEnumT_v02 timeSrc; /**< Time source. - Valid values: \n - - 0x00000000 -- TIME_SRC_INVALID \n - - 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER \n - - 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING \n - - 0x00000003 -- TIME_SRC_EXTERNAL_ INPUT \n - - 0x00000004 -- TIME_SRC_TOW_DECODE \n - - 0x00000005 -- TIME_SRC_TOW_CONFIRMED \n - - 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED \n - - 0x00000007 -- TIME_SRC_NAV_SOLUTION \n - - 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME */ + Valid values: + \begin{itemize1} + \item 0x00000000 -- TIME_SRC_INVALID + \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER + \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING + \item 0x00000003 -- TIME_SRC_EXTERNAL_ INPUT + \item 0x00000004 -- TIME_SRC_TOW_DECODE + \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED + \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED + \item 0x00000007 -- TIME_SRC_NAV_SOLUTION + \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Sensor Data Usage */ @@ -837,6 +906,21 @@ typedef struct { uint32_t fixId; /**< Fix count for the session. Starts with 0 and increments by one for each successive position report for a particular session. */ + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ }qmiLocEventPositionReportIndMsgT_v02; /* Message */ /** @} @@ -894,42 +978,46 @@ typedef struct { qmiLocSvInfoValidMaskT_v02 validMask; /**< Bitmask indicating which of the fields in this TLV are valid. - Valid bitmasks: \n - - 0x00000001 -- VALID_SYSTEM \n - - 0x00000002 -- VALID_GNSS_SVID \n - - 0x00000004 -- VALID_HEALTH_STATUS \n - - 0x00000008 -- VALID_PROCESS_STATUS \n - - 0x00000010 -- VALID_SVINFO_MASK \n - - 0x00000020 -- VALID_ELEVATION \n - - 0x00000040 -- VALID_AZIMUTH \n - - 0x00000080 -- VALID_SNR - - */ + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- VALID_SYSTEM + \item 0x00000002 -- VALID_GNSS_SVID + \item 0x00000004 -- VALID_HEALTH_STATUS + \item 0x00000008 -- VALID_PROCESS_STATUS + \item 0x00000010 -- VALID_SVINFO_MASK + \item 0x00000020 -- VALID_ELEVATION + \item 0x00000040 -- VALID_AZIMUTH + \item 0x00000080 -- VALID_SNR + \vspace{-0.18in} \end{itemize1} */ qmiLocSvSystemEnumT_v02 system; /**< Indicates to which constellation this SV belongs. - Valid values: \n - - 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \n - - 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \n - - 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \n - - 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \n - - 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - */ + Valid values: + \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} */ uint16_t gnssSvId; - /**< GNSS SV ID. \n + /**< GNSS SV ID. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For GLONASS: 1 to 32 + \item For SBAS: 120 to 151 + \end{itemize1} \end{itemize1} - - Type: Unsigned integer \n - - Range: \n - -- For GPS: 1 to 32 \n - -- For SBAS: 33 to 64 \n - -- For GLONASS: 65 to 96 */ + The GPS and GLONASS SVs can be disambiguated using the system field. */ uint8_t healthStatus; - /**< Health status. \n - - Type: Unsigned integer \n - - Range: 0 = unhealthy; 1 = healthy */ + /**< Health status. + \begin{itemize1} + \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy + \vspace{-0.18in} \end{itemize1} */ qmiLocSvStatusEnumT_v02 svStatus; /**< SV processing status. \n @@ -948,19 +1036,16 @@ typedef struct { float elevation; /**< SV elevation angle.\n - - Type: Floating point \n - Units: Degrees \n - Range: 0 to 90 */ float azimuth; /**< SV azimuth angle.\n - - Type: Floating point \n - Units: Degrees \n - Range: 0 to 360 */ float snr; /**< SV signal-to-noise ratio. \n - - Type: Floating point \n - Units: dB-Hz */ }qmiLocSvInfoStructT_v02; /* Type */ /** @@ -976,10 +1061,12 @@ typedef struct { /* Mandatory */ /* Altitude Source */ uint8_t altitudeAssumed; - /**< Altitude assumed or calculated:\n - - 0x00 (FALSE) -- Valid altitude is calculated \n - - 0x01 (TRUE) -- Valid altitude is assumed; there may not be enough - satellites to determine precise altitude */ + /**< Whether altitude is assumed or calculated: + \begin{itemize1} + \item 0x00 (FALSE) -- Valid altitude is calculated + \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be + enough satellites to determine precise altitude + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Satellite Info */ @@ -1001,9 +1088,11 @@ typedef struct { /* Mandatory */ /* NMEA String */ char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; - /**< NMEA string. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 201 */ + /**< NMEA string. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 201 + \vspace{-0.18in} \end{itemize1} */ }qmiLocEventNmeaIndMsgT_v02; /* Message */ /** @} @@ -1076,43 +1165,44 @@ typedef struct { uint8_t posQos; /**< Position QoS timeout. \n - - Type: Unsigned integer \n - Units: Seconds \n - Range: 0 to 255 */ uint32_t numFixes; - /**< Number of fixes allowed. \n - - Type: Unsigned integer */ + /**< Number of fixes allowed. */ uint32_t timeBetweenFixes; /**< Time between fixes.\n - - Type: Unsigned integer \n - Units: Seconds */ qmiLocNiVxPosModeEnumT_v02 posMode; /**< Position mode. - Valid values: \n - - 0x00000001 -- NI_VX_MS_ASSISTED_ONLY \n - - 0x00000002 -- NI_VX_MS_BASED_ONLY \n - - 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED \n - - 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED + Valid values: + \begin{itemize1} + \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY + \item 0x00000002 -- NI_VX_MS_BASED_ONLY + \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED + \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED + \vspace{-0.18in} \end{itemize1} */ qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; /**< VX encoding scheme. - Valid values: \n - - 0x00000000 -- NI_VX_OCTET \n - - 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG \n - - 0x00000002 -- NI_VX_ASCII \n - - 0x00000003 -- NI_VX_IA5 \n - - 0x00000004 -- NI_VX_UNICODE \n - - 0x00000005 -- NI_VX_SHIFT_JIS \n - - 0x00000006 -- NI_VX_KOREAN \n - - 0x00000007 -- NI_VX_LATIN_HEBREW \n - - 0x00000008 -- NI_VX_LATIN \n - - 0x00000009 -- NI_VX_GSM + Valid values: + \begin{itemize1} + \item 0x00000000 -- NI_VX_OCTET + \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG + \item 0x00000002 -- NI_VX_ASCII + \item 0x00000003 -- NI_VX_IA5 + \item 0x00000004 -- NI_VX_UNICODE + \item 0x00000005 -- NI_VX_SHIFT_JIS + \item 0x00000006 -- NI_VX_KOREAN + \item 0x00000007 -- NI_VX_LATIN_HEBREW + \item 0x00000008 -- NI_VX_LATIN + \item 0x00000009 -- NI_VX_GSM + \vspace{-0.18in} \end{itemize1} */ uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ @@ -1124,7 +1214,6 @@ typedef struct { uint16_t userRespTimerInSeconds; /**< Time to wait for the user to respond. \n - - Type: Unsigned integer \n - Units: Seconds */ }qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ /** @@ -1213,16 +1302,18 @@ typedef struct { qmiLocNiSuplFormatEnumType_v02 formatType; /**< Format of the formatted string. - Valid values: \n - - 0x00000000 -- FORMAT_LOGICAL_NAME \n - - 0x00000001 -- FORMAT_EMAIL_ADDRESS \n - - 0x00000002 -- FORMAT_MSISDN \n - - 0x00000003 -- FORMAT_URL \n - - 0x00000004 -- FORMAT_SIP_URL \n - - 0x00000005 -- FORMAT_MIN \n - - 0x00000006 -- FORMAT_MDN \n - - 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY \n - - 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN + Valid values: + \begin{itemize1} + \item 0x00000000 -- FORMAT_LOGICAL_NAME + \item 0x00000001 -- FORMAT_EMAIL_ADDRESS + \item 0x00000002 -- FORMAT_MSISDN + \item 0x00000003 -- FORMAT_URL + \item 0x00000004 -- FORMAT_SIP_URL + \item 0x00000005 -- FORMAT_MIN + \item 0x00000006 -- FORMAT_MDN + \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY + \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ @@ -1257,23 +1348,19 @@ typedef struct { uint8_t horizontalAccuracy; /**< Horizontal accuracy. \n - - Type: Unsigned integer \n - Units: Meters */ uint8_t verticalAccuracy; /**< Vertical accuracy. \n - - Type: Unsigned integer \n - Units: Meters */ uint16_t maxLocAge; /**< Maximum age of the location if the engine sends a previously computed position. \n - - Type: Unsigned integer \n - Units: Seconds */ uint8_t delay; /**< Delay the server is willing to tolerate for the fix. \n - - Type: Unsigned integer \n - Units: Seconds */ }qmiLocNiSuplQopStructT_v02; /* Type */ /** @@ -1290,12 +1377,10 @@ typedef uint8_t qmiLocServerAddrTypeMaskT_v02; typedef struct { uint32_t addr; - /**< IPV4 address. \n - - Type: Unsigned integer */ + /**< IPV4 address. */ uint16_t port; - /**< IPV4 port. \n - - Type: Unsigned integer */ + /**< IPV4 port. */ }qmiLocIpV4AddrStructType_v02; /* Type */ /** @} @@ -1312,8 +1397,7 @@ typedef struct { - Maximum length of the array: 8 */ uint32_t port; - /**< IPV6 port. \n - - Type: Unsigned integer */ + /**< IPV6 port. */ }qmiLocIpV6AddrStructType_v02; /* Type */ /** @} @@ -1340,9 +1424,11 @@ typedef struct { /**< IPV6 address and port. */ char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 256 + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ }qmiLocNiSuplServerInfoStructT_v02; /* Type */ /** @@ -1393,16 +1479,18 @@ typedef struct { qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; /**< Indicates which of the following fields are present in this value. - Valid bitmasks: \n - - 0x00000001 -- SUPL_SERVER_INFO \n - - 0x00000002 -- SUPL_SESSION_ID \n - - 0x00000004 -- SUPL_HASH \n - - 0x00000008 -- SUPL_POS_METHOD \n - - 0x00000010 -- SUPL_DATA_CODING_SCHEME \n - - 0x00000020 -- SUPL_REQUESTOR_ID \n - - 0x00000040 -- SUPL_CLIENT_NAME \n - - 0x00000080 -- SUPL_QOP \n - - 0x00000100 -- SUPL_USER_RESP_TIMER + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- SUPL_SERVER_INFO + \item 0x00000002 -- SUPL_SESSION_ID + \item 0x00000004 -- SUPL_HASH + \item 0x00000008 -- SUPL_POS_METHOD + \item 0x00000010 -- SUPL_DATA_CODING_SCHEME + \item 0x00000020 -- SUPL_REQUESTOR_ID + \item 0x00000040 -- SUPL_CLIENT_NAME + \item 0x00000080 -- SUPL_QOP + \item 0x00000100 -- SUPL_USER_RESP_TIMER + \vspace{-0.18in} \end{itemize1} */ qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; @@ -1422,43 +1510,47 @@ typedef struct { qmiLocNiSuplPosMethodEnumT_v02 posMethod; /**< GPS mode to be used for the fix. - Valid values: \n - - 0x00000001 -- AGPS_SETASSISTED \n - - 0x00000002 -- AGPS_SETBASED \n - - 0x00000003 -- AGPS_SETASSISTED_PREF \n - - 0x00000004 -- AGPS_SETBASED_PREF \n - - 0x00000005 -- AUTONOMOUS_GPS \n - - 0x00000006 -- AFLT \n - - 0x00000007 -- ECID \n - - 0x00000008 -- EOTD \n - - 0x00000009 -- OTDOA \n - - 0x0000000A -- NO_POSITION + Valid values: + \begin{itemize1} + \item 0x00000001 -- AGPS_SETASSISTED + \item 0x00000002 -- AGPS_SETBASED + \item 0x00000003 -- AGPS_SETASSISTED_PREF + \item 0x00000004 -- AGPS_SETBASED_PREF + \item 0x00000005 -- AUTONOMOUS_GPS + \item 0x00000006 -- AFLT + \item 0x00000007 -- ECID + \item 0x00000008 -- EOTD + \item 0x00000009 -- OTDOA + \item 0x0000000A -- NO_POSITION + \vspace{-0.18in} \end{itemize1} */ qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Data coding scheme applies to both the requestor ID and the client name. - Valid values: \n - - 0x0000000C -- NI_SS_GERMAN \n - - 0x0000000D -- NI_SS_ENGLISH \n - - 0x0000000E -- NI_SS_ITALIAN \n - - 0x0000000F -- NI_SS_FRENCH \n - - 0x00000010 -- NI_SS_SPANISH \n - - 0x00000011 -- NI_SS_DUTCH \n - - 0x00000012 -- NI_SS_SWEDISH \n - - 0x00000013 -- NI_SS_DANISH \n - - 0x00000014 -- NI_SS_PORTUGUESE \n - - 0x00000015 -- NI_SS_FINNISH \n - - 0x00000016 -- NI_SS_NORWEGIAN \n - - 0x00000017 -- NI_SS_GREEK \n - - 0x00000018 -- NI_SS_TURKISH \n - - 0x00000019 -- NI_SS_HUNGARIAN \n - - 0x0000001A -- NI_SS_POLISH \n - - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n - - 0x0000001C -- NI_SUPL_UTF8 \n - - 0x0000001D -- NI_SUPL_UCS2 \n - - 0x0000001E -- NI_SUPL_GSM_DEFAULT + Valid values: + \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} */ qmiLocNiSuplFormattedStringStructT_v02 requestorId; @@ -1474,7 +1566,6 @@ typedef struct { uint16_t userResponseTimer; /**< Time to wait for the user to respond. \n - - Type: Unsigned integer \n - Units: Seconds */ }qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ /** @@ -1504,26 +1595,28 @@ typedef struct { qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Identifies the coding scheme of the coded string. - Valid values: \n - - 0x0000000C -- NI_SS_GERMAN \n - - 0x0000000D -- NI_SS_ENGLISH \n - - 0x0000000E -- NI_SS_ITALIAN \n - - 0x0000000F -- NI_SS_FRENCH \n - - 0x00000010 -- NI_SS_SPANISH \n - - 0x00000011 -- NI_SS_DUTCH \n - - 0x00000012 -- NI_SS_SWEDISH \n - - 0x00000013 -- NI_SS_DANISH \n - - 0x00000014 -- NI_SS_PORTUGUESE \n - - 0x00000015 -- NI_SS_FINNISH \n - - 0x00000016 -- NI_SS_NORWEGIAN \n - - 0x00000017 -- NI_SS_GREEK \n - - 0x00000018 -- NI_SS_TURKISH \n - - 0x00000019 -- NI_SS_HUNGARIAN \n - - 0x0000001A -- NI_SS_POLISH \n - - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n - - 0x0000001C -- NI_SUPL_UTF8 \n - - 0x0000001D -- NI_SUPL_UCS2 \n - - 0x0000001E -- NI_SUPL_GSM_DEFAULT + Valid values: + \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} */ @@ -1582,46 +1675,49 @@ typedef struct { qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; /**< Fields that are valid in this value. - Valid bitmasks: \n - - 0x0001 -- INVOKE_ID_MASK \n - - 0x0002 -- DATA_CODING_SCHEME_MASK \n - - 0x0004 -- NOTIFICATION_TEXT_MASK \n - - 0x0008 -- CLIENT_ADDRESS_MASK \n - - 0x0010 -- LOCATION_TYPE_MASK \n - - 0x0020 -- REQUESTOR_ID_MASK \n - - 0x0040 -- CODEWORD_STRING_MASK \n - - 0x0080 -- SERVICE_TYPE_MASK \n - - 0x0100 -- USER_RESP_TIMER_MASK + Valid bitmasks: + \begin{itemize1} + \item 0x0001 -- INVOKE_ID_MASK + \item 0x0002 -- DATA_CODING_SCHEME_MASK + \item 0x0004 -- NOTIFICATION_TEXT_MASK + \item 0x0008 -- CLIENT_ADDRESS_MASK + \item 0x0010 -- LOCATION_TYPE_MASK + \item 0x0020 -- REQUESTOR_ID_MASK + \item 0x0040 -- CODEWORD_STRING_MASK + \item 0x0080 -- SERVICE_TYPE_MASK + \item 0x0100 -- USER_RESP_TIMER_MASK + \vspace{-0.18in} \end{itemize1} */ uint8_t invokeId; - /**< Supplementary Services invoke ID. \n - - Type: Unsigned integer */ + /**< Supplementary Services invoke ID. */ qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Type of data encoding scheme for the text. Applies to both the notification text and the client address. - Valid values: \n - - 0x0000000C -- NI_SS_GERMAN \n - - 0x0000000D -- NI_SS_ENGLISH \n - - 0x0000000E -- NI_SS_ITALIAN \n - - 0x0000000F -- NI_SS_FRENCH \n - - 0x00000010 -- NI_SS_SPANISH \n - - 0x00000011 -- NI_SS_DUTCH \n - - 0x00000012 -- NI_SS_SWEDISH \n - - 0x00000013 -- NI_SS_DANISH \n - - 0x00000014 -- NI_SS_PORTUGUESE \n - - 0x00000015 -- NI_SS_FINNISH \n - - 0x00000016 -- NI_SS_NORWEGIAN \n - - 0x00000017 -- NI_SS_GREEK \n - - 0x00000018 -- NI_SS_TURKISH \n - - 0x00000019 -- NI_SS_HUNGARIAN \n - - 0x0000001A -- NI_SS_POLISH \n - - 0x0000001B -- NI_SS_LANGUAGE_UNSPEC \n - - 0x0000001C -- NI_SUPL_UTF8 \n - - 0x0000001D -- NI_SUPL_UCS2 \n - - 0x0000001E -- NI_SUPL_GSM_DEFAULT + Valid values: + \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} */ uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ @@ -1640,10 +1736,12 @@ typedef struct { qmiLocNiLocationTypeEnumT_v02 locationType; /**< Location type. - Valid values: \n - - 0x00000001 -- CURRENT_LOCATION \n - - 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION \n - - 0x00000004 -- INITIAL_LOCATION + Valid values: + \begin{itemize1} + \item 0x00000001 -- CURRENT_LOCATION + \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION + \item 0x00000004 -- INITIAL_LOCATION + \vspace{-0.18in} \end{itemize1} */ qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; @@ -1655,12 +1753,10 @@ typedef struct { qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ uint8_t lcsServiceTypeId; - /**< Service type ID. \n - - Type: Unsigned integer */ + /**< Service type ID. */ uint16_t userResponseTimer; /**< Time to wait for the user to respond. \n - - Type: Unsigned integer \n - Units: Seconds */ }qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ /** @@ -1690,14 +1786,115 @@ typedef struct { qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. - Valid values: \n - - 0x00000001 -- ONGOING_NI_INCOMING_MO + Valid values: + \begin{itemize1} + \item 0x00000001 -- ONGOING_NI_INCOMING_MO + \vspace{-0.18in} \end{itemize1} */ }qmiLocNiVxServiceInteractionStructT_v02; /* Type */ /** @} */ +typedef uint16_t qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WLAN_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0001) /**< Denotes that WLAN measurements are allowed as part of location ID + and multiple location IDs in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_GSM_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0002) /**< Denotes that GSM measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WCDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0004) /**< Denotes that WCDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_CDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0008) /**< Denotes that CDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HRDP_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0010) /**< Denotes that HRDP measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_UMB_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0020) /**< Denotes that UMB measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_LTE_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0040) /**< Denotes that LTE measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WIMAX_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0080) /**< Denotes that WIMAX measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HISTORIC_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0100) /**< Denotes that historical information is allowed as part of + multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_NONSVRV_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0200) /**< Denotes that information about nonserving cells is allowed + as part of multiple location ID in the SUPL_POS_INIT message. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic + triggered session. + The SUPL INIT message indicates a request for an area event + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; +/** + @} + */ + +typedef uint16_t qmiLocNiSuplVer2ExtGnssTypeMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0001) /**< GPS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GLONASS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0002) /**< GLONASS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GALILEO_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0004) /**< Galileo is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_SBAS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0008) /**< SBAS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_QZSS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0010) /**< QZSS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_MODERN_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0020) /**< Modern GPS is allowed to be used as the positioning technology. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02 supportedNetworksMask; + /**< Specifies which type of network measurements are allowed to be sent as + part of the Location ID or Multiple Location IDs parameter in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid bitmasks: + \begin{itemize1} + \item 0x0001 -- SUPPORTED_NETWORK_WLAN + \item 0x0002 -- SUPPORTED_NETWORK_GSM + \item 0x0004 -- SUPPORTED_NETWORK_WCDMA + \item 0x0008 -- SUPPORTED_NETWORK_CDMA + \item 0x0010 -- SUPPORTED_NETWORK_HRDP + \item 0x0020 -- SUPPORTED_NETWORK_UMB + \item 0x0040 -- SUPPORTED_NETWORK_LTE + \item 0x0080 -- SUPPORTED_NETWORK_WIMAX + \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC + \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; + /**< Specifies the type of session trigger requested in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid values: + \begin{itemize1} + \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT + \item 0x00000000 -- TRIGGER_TYPE_PERIODIC + \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT + \vspace{-0.18in} \end{itemize1} */ + + qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; + /**< Specifies which GNSS technologies are allowed as positioning + technologies. + + Valid bitmasks: \n + - 0x0001 -- GNSS_GPS \n + - 0x0002 -- GNSS_GLONASS \n + - 0x0004 -- GNSS_GALILEO \n + - 0x0008 -- GNSS_SBAS \n + - 0x0010 -- GNSS_QZSS \n + - 0x0020 -- GNSS_MODERN_GPS + */ +}qmiLocNiSuplVer2ExtStructT_v02; /* Type */ +/** + @} + */ + /** @addtogroup loc_qmi_messages @{ */ @@ -1709,12 +1906,14 @@ typedef struct { qmiLocNiNotifyVerifyEnumT_v02 notificationType; /**< Type of notification/verification performed. - Valid values: \n - - 0x00000001 -- NO_NOTIFY_NO_VERIFY \n - - 0x00000002 -- NOTIFY_ONLY \n - - 0x00000003 -- ALLOW_NO_RESP \n - - 0x00000004 -- NOT_ALLOW_NO_RESP \n - - 0x00000005 -- PRIVACY_OVERRIDE + Valid values: + \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIFY + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -1740,6 +1939,14 @@ typedef struct { uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtInd_valid; /**< Must be set to true if NiSuplVer2ExtInd is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; + /**< \n Optional NI SUPL Version 2 Extension payload. When present, + this payload is to be used in conjunction with the SUPL + indication payload. */ }qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ /** @} @@ -1751,9 +1958,11 @@ typedef struct { typedef struct { char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< Assistance server URL. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 256 */ + /**< Assistance server URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ }qmiLocAssistanceServerUrlStructT_v02; /* Type */ /** @} @@ -1767,7 +1976,6 @@ typedef struct { uint32_t delayThreshold; /**< The time server is to be skipped if a one-way delay to the server exceeds this threshold. \n - - Type: Unsigned integer \n - Units: Milliseconds */ uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ @@ -1805,12 +2013,10 @@ typedef struct { typedef struct { uint32_t maxFileSizeInBytes; - /**< Maximum allowable predicted orbits file size (in bytes). \n - - Type: Unsigned integer */ + /**< Maximum allowable predicted orbits file size (in bytes). */ uint32_t maxPartSize; - /**< Maximum allowable predicted orbits file chunk size (in bytes). \n - - Type: Unsigned integer */ + /**< Maximum allowable predicted orbits file chunk size (in bytes). */ }qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ /** @} @@ -1864,36 +2070,40 @@ typedef struct { /* Mandatory */ /* Latitude */ double latitude; - /**< Latitude (specified in WGS84 datum).\n - - Type: Floating point \n - - Units: Degrees \n - - Range: -90.0 to 90.0 \n - - Positive values indicate northern latitude \n - - Negative values indicate southern latitude */ + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Mandatory */ /* Longitude */ double longitude; - /**< Longitude (specified in WGS84 datum).\n - - Type: Floating point \n - - Units: Degrees \n - - Range: -180.0 to 180.0 \n - - Positive values indicate eastern longitude \n - - Negative values indicate western longitude */ + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Mandatory */ /* Circular Horizontal Uncertainty */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Type: Floating point \n - Units: Meters */ /* Mandatory */ /* UTC Timestamp */ uint64_t timestampUtc; - /**< UTC timestamp.\n - - Type: Unsigned integer \n - - Units: Milliseconds since Jan. 1, 1970 */ + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ }qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ /** @} @@ -1970,7 +2180,6 @@ typedef struct { /**< ID of the session that was specified in the Start request. This may not be specified for a fix session corresponding to a network-initiated request. \n - - Type: Unsigned integer \n - Range: 0 to 255 */ }qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ /** @@ -2003,10 +2212,12 @@ typedef struct { qmiLocWifiRequestEnumT_v02 requestType; /**< Request type as specified in qmiWifiRequestEnumT. - Valid values: \n - - 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES \n - - 0x00000001 -- START_PERIODIC_KEEP_WARM \n - - 0x00000002 -- STOP_PERIODIC_FIXES + Valid values: + \begin{itemize1} + \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES + \item 0x00000001 -- START_PERIODIC_KEEP_WARM + \item 0x00000002 -- STOP_PERIODIC_FIXES + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2014,7 +2225,6 @@ typedef struct { uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ uint16_t tbfInMs; /**< Time between fixes for a periodic request.\n - - Type: Unsigned integer \n - Units: Milliseconds */ }qmiLocEventWifiReqIndMsgT_v02; /* Message */ /** @@ -2056,10 +2266,13 @@ typedef struct { /**< Whether the GNSS location engine is ready to accept data from this sensor. - Valid values: \n - - 0x01 (TRUE) -- GNSS location engine is ready to accept sensor data \n - - 0x00 (FALSE) -- GNSS location engine is not ready to accept sensor - data + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor + data + \item 0x00 (FALSE) -- GNSS location engine is not ready to accept + sensor data + \vspace{-0.18in} \end{itemize1} */ qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; @@ -2088,10 +2301,10 @@ typedef struct { */ /* Optional */ - /* Gyrometer Accept Ready */ + /* Gyroscope Accept Ready */ uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ qmiLocSensorReadyStatusStructT_v02 gyroReady; - /**< \n Whether the GNSS location engine is ready to accept gyrometer sensor + /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor data. */ }qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ @@ -2112,8 +2325,7 @@ typedef struct { /**< This TLV is sent to registered control points. It is sent by the location engine when it needs to synchronize location engine and control point (sensor processor) times. - This TLV must be echoed back in the Time Sync Inject request. \n - - Type: Unsigned integer */ + This TLV must be echoed back in the Time Sync Inject request. */ }qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ /** @} @@ -2129,9 +2341,11 @@ typedef struct { /* Mandatory */ /* Enable/Disable SPI Requests */ uint8_t enable; - /**< Whether the client is to start or stop sending an SPI status stream.\n - - 0x01 (TRUE) -- Client is to start sending an SPI status stream\n - - 0x00 (FALSE) -- Client is to stop sending an SPI status stream */ + /**< Whether the client is to start or stop sending an SPI status stream. + \begin{itemize1} + \item 0x01 (TRUE) -- Client is to start sending an SPI status stream + \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream + \vspace{-0.18in} \end{itemize1} */ }qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ /** @} @@ -2175,8 +2389,7 @@ typedef struct { /* Mandatory */ /* Connection Handle */ uint32_t connHandle; - /**< Identifies a connection across Open and Close request events. \n - - Type: Unsigned integer */ + /**< Identifies a connection across Open and Close request events. */ /* Mandatory */ /* Request Type */ @@ -2192,15 +2405,290 @@ typedef struct { /* WWAN Type */ qmiLocWWANTypeEnumT_v02 wwanType; /**< Identifies the WWAN type for this request. \n - Valid values: \n - - 0x00000000 -- WWAN_TYPE_INTERNET \n - - 0x00000001 -- WWAN_TYPE_AGNSS + Valid values: + \begin{itemize1} + \item 0x00000000 -- WWAN_TYPE_INTERNET + \item 0x00000001 -- WWAN_TYPE_AGNSS + \vspace{-0.18in} \end{itemize1} */ }qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ /** @} */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ + eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. + An NI Geofence was edited. The control point can query the + Geofence to find the its current state. */ + eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, + QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiGeofenceOperationEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Informs the control point about + network-initiated Geofences. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Operation Type */ + qmiLocNiGeofenceOperationEnumT_v02 operationType; + /**< Operation for which this notification was generated. \n + Valid values: + \begin{itemize1} + \item 0x00000001 -- NI_GEOFENCE_ADDED + \item 0x00000002 -- NI_GEOFENCE_DELETED + \item 0x00000003 -- NI_GEOFENCE_EDITED + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEGENALERTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE_V02 = 1, /**< GNSS is unavailable and GNSS position fixes + cannot be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can + be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage + information is available. + The engine has an invalid time. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, + QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceGenAlertEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of the + Geofence status. */ +typedef struct { + + /* Mandatory */ + /* Geofence General Alert */ + qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; + /**< Specifies the Geofence general alert type. \n + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE + \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE + \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS + \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. + Denotes that a client left the Geofence. */ + eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, + QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceBreachTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Elliptical Horizontal Uncertainty Azimuth */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Horizontal Speed validity bit */ + uint8_t speedHorizontal_valid; + /**< Indicates whether the Horizontal speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Horizontal speed is valid + \item 0x00 (FALSE) -- Horizontal speed is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Horizontal Speed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Units: Meters/second */ + + /* Altitude validity bit */ + uint8_t altitudeWrtEllipsoid_valid; + /**< Indicates whether the altitude field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Altitude field is valid + \item 0x00 (FALSE) -- Altitude field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} + */ + + /* Altitude With Respect to Ellipsoid */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Vertical Uncertainty validity bit */ + uint8_t vertUnc_valid; + /**< Indicates whether the Vertical Uncertainty field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Uncertainty field is valid + \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Uncertainty */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Vertical Speed validity bit */ + uint8_t speedVertical_valid; + /**< Indicates whether the Vertical Speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Speed field is valid + \item 0x00 (FALSE) -- Vertical Speed field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Speed */ + float speedVertical; + /**< Vertical speed.\n + - Units: Meters/second */ + + /* heading validity bit */ + uint8_t heading_valid; + /**< Indicates whether the Heading field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Heading field is valid + \item 0x00 (FALSE) -- Heading field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Heading */ + float heading; + /**< Heading.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ +}qmiLocGeofencePositionStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of + a Geofence breach event. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Geofence Breach Type */ + qmiLocGeofenceBreachTypeEnumT_v02 breachType; + /**< The type of breach that generated this event. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING + \item 0x00000001 -- GEOFENCE_BREACH_TYPE_LEAVING + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Geofence Position */ + uint8_t geofencePosition_valid; /**< Must be set to true if geofencePosition is being passed */ + qmiLocGeofencePositionStructT_v02 geofencePosition; + /**< \n Position of the client when it breached the Geofence. + This TLV is included if the client configures the + Geofence to report position. The position is reported + at the same confidence level that was specified in the + Add Circular Geofence request. */ +}qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ +/** + @} + */ + /** @addtogroup loc_qmi_enums @{ */ @@ -2208,12 +2696,15 @@ typedef enum { QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ - eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is unsupported. */ + eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is not supported. */ eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ - eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. - Request failed because it timed out. */ - eQMI_LOC_TIMEOUT_V02 = 6, + eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ + eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ + eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested + Request failed because the engine could not allocate sufficent + memory for the request. */ + eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocStatusEnumT_v02; /** @@ -2237,14 +2728,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Revision request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Mandatory */ @@ -2252,8 +2745,46 @@ typedef struct { uint32_t revision; /**< Revision of the service. This is the minor revision of the interface that the service implements. Minor revision updates of the service are always - backward compatible. \n - - Type: Unsigned integer */ + backward compatible. */ + + /* Optional */ + /* GNSS Measurement Engine Firmware Version String */ + uint8_t gnssMeFWVerString_valid; /**< Must be set to true if gnssMeFWVerString is being passed */ + char gnssMeFWVerString[QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS measurement engine software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in} \end{itemize1} + + \textbf{Note:} This string is only provided on platforms that have + a measurement engine that supports this version string. On all other + platforms, this optional TLV is not provided. */ + + /* Optional */ + /* GNSS Hosted Software Version String */ + uint8_t gnssHostSWVerString_valid; /**< Must be set to true if gnssHostSWVerString is being passed */ + char gnssHostSWVerString[QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS hosted software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in}\end{itemize1} + + \textbf{Note:} This string is only provided on hosted architectures + (measurement and position engine running on different processors) that + support this version string. On all other platforms, this optional TLV + is not provided. */ + + /* Optional */ + /* GNSS Software Version String */ + uint8_t gnssSWVerString_valid; /**< Must be set to true if gnssSWVerString is being passed */ + char gnssSWVerString[QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Aggregate version of the GNSS software. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ /** @} @@ -2276,14 +2807,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Fix Criteria request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2292,10 +2825,12 @@ typedef struct { qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; /**< Horizontal accuracy level. - Valid values: \n - - 0x00000001 -- LOW: Client requires low horizontal accuracy. \n - - 0x00000002 -- MED: Client requires medium horizontal accuracy. \n - - 0x00000003 -- HIGH: Client requires high horizontal accuracy. + Valid values: + \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2309,18 +2844,27 @@ typedef struct { are turned ON, the client receives position reports even if the accuracy criteria is not met. The status in the position report is set to IN_PROGRESS for intermediate reports. \n - Valid values: \n - - 0x00000001 -- ON: Client is interested in receiving intermediate reports \n - - 0x00000002 -- OFF: Client is not interested in receiving intermediate reports + Valid values: + \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} \end{itemize1} */ /* Optional */ - /* Mimimum Interval Between Fixes */ + /* Minimum Interval Between Fixes */ uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ uint32_t minInterval; /**< Time that must elapse before alerting the client. \n - - Type: Unsigned integer \n - Units: Milliseconds */ + + /* Optional */ + /* ID of the Application that Sent the Position Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version. */ }qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ /** @} @@ -2345,7 +2889,7 @@ typedef enum { @{ */ /** Request Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ + failure is reported in a separate indication. */ typedef struct { /* Mandatory */ @@ -2353,10 +2897,12 @@ typedef struct { qmiLocNiUserRespEnumT_v02 userResp; /**< User accepted or denied. - Valid values: \n - - 0x00000001 -- NOTIFY_VERIFY_ACCEPT \n - - 0x00000002 -- NOTIFY_VERIFY_DENY \n - - 0x00000003 -- NOTIFY_VERIFY_NORESP + Valid values: + \begin{itemize1} + \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT + \item 0x00000002 -- NOTIFY_VERIFY_DENY + \item 0x00000003 -- NOTIFY_VERIFY_NORESP + \vspace{-0.18in} \end{itemize1} */ /* Mandatory */ @@ -2364,12 +2910,14 @@ typedef struct { qmiLocNiNotifyVerifyEnumT_v02 notificationType; /**< Type of notification/verification performed. - Valid values: \n - - 0x00000001 -- NO_NOTIFY_NO_VERIFY \n - - 0x00000002 -- NOTIFY_ONLY \n - - 0x00000003 -- ALLOW_NO_RESP \n - - 0x00000004 -- NOT_ALLOW_NO_RESP \n - - 0x00000005 -- PRIVACY_OVERRIDE + Valid values: + \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIF + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2394,7 +2942,13 @@ typedef struct { /* Network Initiated Service Interaction Request */ uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; - /**< \n Optional NI service interaction payload. */ + /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; + /**< \n Optional SUPL Version 2 Extension payload. */ }qmiLocNiUserRespReqMsgT_v02; /* Message */ /** @} @@ -2404,7 +2958,7 @@ typedef struct { @{ */ /** Indication Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ + failure is reported in a separate indication. */ typedef struct { /* Mandatory */ @@ -2412,14 +2966,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the NI User Response request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocNiUserRespIndMsgT_v02; /* Message */ /** @@ -2448,21 +3004,18 @@ typedef struct { /* Total Size */ uint32_t totalSize; /**< Total size of the predicted orbits data to be injected. \n - - Type: Unsigned integer \n - Units: Bytes */ /* Mandatory */ /* Total Parts */ uint16_t totalParts; /**< Total number of parts into which the predicted orbits data is - divided. \n - - Type: Unsigned integer */ + divided. */ /* Mandatory */ /* Part Number */ uint16_t partNum; - /**< Number of the current predicted orbits data part; starts at 1. \n - - Type: Unsigned integer */ + /**< Number of the current predicted orbits data part; starts at 1. */ /* Mandatory */ /* Data */ @@ -2479,8 +3032,10 @@ typedef struct { qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; /**< Predicted orbits data format. - Valid values: \n - - 0x00000000 -- PREDICTED_ORBITS_XTRA + Valid values: + \begin{itemize1} + \item 0x00000000 -- PREDICTED_ORBITS_XTRA + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ /** @@ -2498,14 +3053,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Data Injection request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2513,8 +3070,7 @@ typedef struct { uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ uint16_t partNum; /**< Number of the predicted orbits data part for which this indication - is sent; starts at 1. \n - - Type: Unsigned integer */ + is sent; starts at 1. */ }qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ /** @} @@ -2533,18 +3089,20 @@ typedef struct { typedef struct { /* Mandatory */ - /* Predicted Oribits Data Source Status */ + /* Predicted Orbits Data Source Status */ qmiLocStatusEnumT_v02 status; /**< Status of the query request for a predicted orbits data source. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2577,13 +3135,11 @@ typedef struct { uint64_t startTimeInUTC; /**< Predicted orbits data is valid starting from this time. \n - - Type: Unsigned integer \n - Units: Seconds (since Jan. 1, 1970) */ uint16_t durationHours; /**< Duration from the start time for which the data is valid.\n - - Type: Unsigned integer \n - Units: Hours */ }qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ @@ -2602,14 +3158,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the query request for predicted orbits data validity. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2631,17 +3189,13 @@ typedef struct { /* UTC Time */ uint64_t timeUtc; /**< UTC time since Jan. 1, 1970.\n - - Type: Unsigned integer \n - - Units: Milliseconds - */ + - Units: Milliseconds */ /* Mandatory */ /* Time Uncertainty */ uint32_t timeUnc; /**< Time uncertainty.\n - - Type: Unsigned integer \n - - Units: Milliseconds - */ + - Units: Milliseconds */ }qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ /** @} @@ -2658,14 +3212,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the UTC Time Injection request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ /** @@ -2736,40 +3292,48 @@ typedef struct { qmiLocAltSrcEnumT_v02 source; /**< Specifies the source of the altitude. - Valid values: \n - - 0x00000000 -- ALT_SRC_UNKNOWN \n - - 0x00000001 -- ALT_SRC_GPS \n - - 0x00000002 -- ALT_SRC_CELL_ID \n - - 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID \n - - 0x00000004 -- ALT_SRC_WIFI \n - - 0x00000005 -- ALT_SRC_TERRESTRIAL \n - - 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID \n - - 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE \n - - 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER \n - - 0x00000009 -- ALT_SRC_OTHER + Valid values: + \begin{itemize1} + \item 0x00000000 -- ALT_SRC_UNKNOWN + \item 0x00000001 -- ALT_SRC_GPS + \item 0x00000002 -- ALT_SRC_CELL_ID + \item 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID + \item 0x00000004 -- ALT_SRC_WIFI + \item 0x00000005 -- ALT_SRC_TERRESTRIAL + \item 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID + \item 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE + \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER + \item 0x00000009 -- ALT_SRC_OTHER + \vspace{-0.18in} \end{itemize1} */ qmiLocAltSrcLinkageEnumT_v02 linkage; /**< Specifies the dependency between the horizontal and altitude position components. - Valid values: \n - - 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED \n - - 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT \n - - 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG \n - - 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED + \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT + \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG + \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT + \vspace{-0.18in} \end{itemize1} */ qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; /**< Specifies the region of uncertainty. - Valid values: \n - - 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED \n - - 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid at the - injected horizontal position coordinates only. \n - - 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to the - position of the device regardless of horizontal position - (within the horizontal uncertainty region, if provided). + Valid values: + \begin{itemize1} + \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED + \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid + at the injected horizontal position coordinates + only. + \item 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to + the position of the device regardless of + horizontal position (within the horizontal + uncertainty region, if provided). + \vspace{-0.18in} \end{itemize1} */ }qmiLocAltitudeSrcInfoStructT_v02; /* Type */ /** @@ -2781,12 +3345,12 @@ typedef struct { */ typedef enum { QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position Source is GNSS. */ - eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position Source is Cell ID. */ - eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position Source is Enhanced Cell ID. */ - eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position Source is WiFi. */ - eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position Source is Terrestrial. */ - eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position Source is GNSS Terrestrial Hybrid. + eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position source is GNSS. */ + eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position source is Cell ID. */ + eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ + eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ + eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ + eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. Other sources. */ eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ @@ -2805,24 +3369,28 @@ typedef struct { /* Latitude */ uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ double latitude; - /**< Latitude (specified in WGS84 datum).\n - - Type: Floating point \n - - Units: Degrees \n - - Range: -90.0 to 90.0 \n - - Positive values indicate northern latitude \n - - Negative values indicate southern latitude + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Longitude */ uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ double longitude; - /**< Longitude (specified in WGS84 datum).\n - - Type: Floating point \n - - Units: Degrees \n - - Range: -180.0 to 180.0 \n - - Positive values indicate eastern longitude \n - - Negative values indicate western longitude + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ @@ -2830,19 +3398,19 @@ typedef struct { uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Type: Floating point \n - Units: Meters */ /* Optional */ /* Horizontal Confidence */ uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ uint8_t horConfidence; - /**< Horizontal confidence, as defined by ETSI TS 101 109.\n - - Type: Unsigned integer \n - - Units: Percent (0 to 99) \n - - 0 -- invalid value \n - - 100 to 256 -- not used \n - - If 100 is received, reinterpret to 99 \n + /**< Horizontal confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0 to 99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} This field must be specified together with horizontal uncertainty. If not specified, the default value will be 50. */ @@ -2852,28 +3420,32 @@ typedef struct { qmiLocReliabilityEnumT_v02 horReliability; /**< Specifies the reliability of the horizontal position. - Valid values: \n - - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n - - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n - - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n - - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n - - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + Valid values: + \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Altitude With Respect to Ellipsoid */ uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Type: Floating point \n - - Units: Meters; positive = height, negative = depth */ + /**< Altitude with respect to the WGS84 ellipsoid. + \begin{itemize1} + \item Units: Meters \begin{itemize1} + \item Positive = height + \item Negative = depth + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Altitude With Respect to Sea Level */ uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ float altitudeWrtMeanSeaLevel; /**< Altitude with respect to mean sea level.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ @@ -2882,19 +3454,19 @@ typedef struct { float vertUnc; /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid or altitudeWrtMeanSeaLevel is specified.\n - - Type: Floating point \n - Units: Meters */ /* Optional */ /* Vertical Confidence */ uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ uint8_t vertConfidence; - /**< Vertical confidence, as defined by ETSI TS 101 109.\n - - Type: Unsigned integer \n - - Units: Percent (0-99) \n - - 0 -- invalid value\n - - 100 to 256 -- not used \n - - If 100 is received, reinterpret to 99\n + /**< Vertical confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0-99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} This field must be specified together with the vertical uncertainty. If not specified, the default value will be 50. */ @@ -2904,12 +3476,14 @@ typedef struct { qmiLocReliabilityEnumT_v02 vertReliability; /**< Specifies the reliability of the vertical position. - Valid values: \n - - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n - - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n - - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n - - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n - - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + Valid values: + \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -2923,7 +3497,6 @@ typedef struct { uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ uint64_t timestampUtc; /**< UTC timestamp. \n - - Type: Unsigned integer \n - Units: Milliseconds (since Jan. 1, 1970) */ /* Optional */ @@ -2931,28 +3504,28 @@ typedef struct { uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ int32_t timestampAge; /**< Position age, which is an estimate of how long ago this fix was made. \n - - Type: Signed integer \n - Units: Milliseconds */ /* Optional */ /* Position Source */ uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ qmiLocPositionSrcEnumT_v02 positionSrc; - /**< Source from where this position was obtained. - Valid values: \n - - 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS \n - - 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID \n - - 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID \n - - 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI \n - - 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL \n - - 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID \n - - 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER \n - - If altitude is specified and altitude source is not specified, the engine - assumes that altitude was obtained using the specified Position source. - If altitude and altitude source both are specified then the engine assumes - that only latitude, longitude were obtained using the specified Position - Source. + /**< Source from which this position was obtained. \n + Valid values: + \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS + \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID + \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID + \item 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI + \item 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL + \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID + \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER + \end{itemize1} \vspace{0.05in} + If altitude is specified and the altitude source is not specified, the engine + assumes that the altitude was obtained using the specified position source. \n + If both altitude and altitude source are specified, the engine assumes + that only latitude and longitude were obtained using the specified position + source. */ }qmiLocInjectPositionReqMsgT_v02; /* Message */ /** @@ -2970,14 +3543,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the UTC Position Injection request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectPositionIndMsgT_v02; /* Message */ /** @@ -3034,14 +3609,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Engine Lock request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetEngineLockIndMsgT_v02; /* Message */ /** @@ -3065,14 +3642,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Engine Lock request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -3101,9 +3680,11 @@ typedef struct { /* Mandatory */ /* SBAS Config */ uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. \n - - 0x01 (TRUE) -- SBAS configuration is enabled \n - - 0x00 (FALSE) -- SBAS configuration is disabled */ + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSbasConfigReqMsgT_v02; /* Message */ /** @} @@ -3120,14 +3701,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set SBAS Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSbasConfigIndMsgT_v02; /* Message */ /** @@ -3151,23 +3734,27 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get SBAS Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* SBAS Config */ uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. \n - - 0x01 (TRUE) -- SBAS configuration is enabled \n - - 0x00 (FALSE) -- SBAS configuration is disabled */ + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetSbasConfigIndMsgT_v02; /* Message */ /** @} @@ -3179,6 +3766,8 @@ typedef uint32_t qmiLocNmeaSentenceMaskT_v02; #define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ #define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ #define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ +#define QMI_LOC_NMEA_MASK_PQXFI_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000020) /**< Enable PQXFI type. */ +#define QMI_LOC_NMEA_MASK_PSTIS_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000040) /**< Enable PSTIS type. */ /** @addtogroup loc_qmi_messages @{ */ @@ -3195,7 +3784,9 @@ typedef struct { - 0x00000002 -- NMEA_MASK_RMC \n - 0x00000004 -- NMEA_MASK_GSV \n - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS */ }qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ /** @@ -3213,14 +3804,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of Set NMEA Types request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ /** @@ -3244,14 +3837,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get NMEA Types request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -3266,7 +3861,9 @@ typedef struct { - 0x00000002 -- NMEA_MASK_RMC \n - 0x00000004 -- NMEA_MASK_GSV \n - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS */ }qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ /** @@ -3301,14 +3898,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Low Power Mode request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ /** @@ -3332,14 +3931,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get LPM request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -3404,9 +4005,11 @@ typedef struct { /* Uniform Resource Locator */ uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL address. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 256 + /**< URL address. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetServerReqMsgT_v02; /* Message */ /** @@ -3424,14 +4027,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Server request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetServerIndMsgT_v02; /* Message */ /** @@ -3485,14 +4090,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Server request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Mandatory */ @@ -3523,9 +4130,11 @@ typedef struct { /* Uniform Resource Locator */ uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 256 + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetServerIndMsgT_v02; /* Message */ /** @@ -3533,25 +4142,25 @@ typedef struct { */ typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; -#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001) /**< Mask to delete GPS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002) /**< Mask to delete GPS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004) /**< Mask to delete GPS time. */ -#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008) /**< Mask to delete almanac correlation. */ -#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010) /**< Mask to delete GLONASS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020) /**< Mask to delete GLONASS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040) /**< Mask to delete GLONASS time. */ -#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080) /**< Mask to delete GLONASS almanac correlation */ -#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100) /**< Mask to delete SBAS SVDIR */ -#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200) /**< Mask to delete SBAS SVSTEER */ -#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400) /**< Mask to delete position estimate */ -#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800) /**< Mask to delete time estimate */ -#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000) /**< Mask to delete IONO */ -#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000) /**< Mask to delete UTC estimate */ -#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000) /**< Mask to delete SV health record */ -#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000) /**< Mask to delete SADATA */ -#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000) /**< Mask to delete RTI */ -#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000) /**< Mask to delete SV_NO_EXIST */ -#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000) /**< Mask to delete frequency bias estimate */ +#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001ull) /**< Mask to delete GPS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002ull) /**< Mask to delete GPS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004ull) /**< Mask to delete GPS time. */ +#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008ull) /**< Mask to delete almanac correlation. */ +#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010ull) /**< Mask to delete GLONASS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020ull) /**< Mask to delete GLONASS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040ull) /**< Mask to delete GLONASS time. */ +#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080ull) /**< Mask to delete GLONASS almanac correlation */ +#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100ull) /**< Mask to delete SBAS SVDIR */ +#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200ull) /**< Mask to delete SBAS SVSTEER */ +#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400ull) /**< Mask to delete position estimate */ +#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800ull) /**< Mask to delete time estimate */ +#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000ull) /**< Mask to delete IONO */ +#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000ull) /**< Mask to delete UTC estimate */ +#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000ull) /**< Mask to delete SV health record */ +#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000ull) /**< Mask to delete SADATA */ +#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000ull) /**< Mask to delete RTI */ +#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000ull) /**< Mask to delete SV_NO_EXIST */ +#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000ull) /**< Mask to delete frequency bias estimate */ typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; #define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ #define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ @@ -3584,21 +4193,25 @@ typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; typedef struct { uint16_t gnssSvId; - /**< SV ID of the satellite whose data is to be deleted. \n - - Type: Unsigned integer \n - - Range: \n - - For GPS: 1 to 32 \n - - For SBAS: 33 to 64 \n - - For GLONASS: 65 to 96 */ + /**< SV ID of the satellite whose data is to be deleted. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ qmiLocSvSystemEnumT_v02 system; /**< Indicates to which constellation this SV belongs. - Valid values: \n - - 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \n - - 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \n - - 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \n - - 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \n - - 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + + Valid values: + \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} */ qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; @@ -3624,20 +4237,23 @@ typedef struct { /* Delete All */ uint8_t deleteAllFlag; /**< Whether all assistance data is to be deleted. - Valid values: \n - - 0x01 (TRUE) -- All assistance data is to be deleted; - if this flag is set, all the other information + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- All assistance data is to be deleted; if + this flag is set, all the other information contained in the optional fields for this - message are ignored \n - - 0x00 (FALSE) -- The optional fields in the message are to be used - to determine which data is to be deleted */ + message are ignored + \item 0x00 (FALSE) -- The optional fields in the message are to be + used to determine which data is to be deleted + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Delete SV Info */ uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; - /**< \n List of satellites for which the assitance data is to be deleted. + /**< \n List of satellites for which the assistance data is to be deleted. */ /* Optional */ @@ -3645,63 +4261,72 @@ typedef struct { uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; /**< Mask for the GNSS data that is to be deleted. - Valid values: \n - - 0x00000001 -- DELETE_GPS_SVDIR \n - - 0x00000002 -- DELETE_GPS_SVSTEER \n - - 0x00000004 -- DELETE_GPS_TIME\n - - 0x00000008 -- DELETE_GPS_ALM_CORR \n - - 0x00000010 -- DELETE_GLO_SVDIR \n - - 0x00000020 -- DELETE_GLO_SVSTEER \n - - 0x00000040 -- DELETE_GLO_TIME \n - - 0x00000080 -- DELETE_GLO_ALM_CORR \n - - 0x00000100 -- DELETE_SBAS_SVDIR \n - - 0x00000200 -- DELETE_SBAS_SVSTEER \n - - 0x00000400 -- DELETE_POSITION \n - - 0x00000800 -- DELETE_TIME \n - - 0x00001000 -- DELETE_IONO \n - - 0x00002000 -- DELETE_UTC \n - - 0x00004000 -- DELETE_HEALTH \n - - 0x00008000 -- DELETE_SADATA \n - - 0x00010000 -- DELETE_RTI \n - - 0x00020000 -- DELETE_SV_NO_EXIST \n - - 0x00040000 -- DELETE_FREQ_BIAS_EST + + Valid values: + \begin{itemize1} + \item 0x00000001 -- DELETE_GPS_SVDIR + \item 0x00000002 -- DELETE_GPS_SVSTEER + \item 0x00000004 -- DELETE_GPS_TIME + \item 0x00000008 -- DELETE_GPS_ALM_CORR + \item 0x00000010 -- DELETE_GLO_SVDIR + \item 0x00000020 -- DELETE_GLO_SVSTEER + \item 0x00000040 -- DELETE_GLO_TIME + \item 0x00000080 -- DELETE_GLO_ALM_CORR + \item 0x00000100 -- DELETE_SBAS_SVDIR + \item 0x00000200 -- DELETE_SBAS_SVSTEER + \item 0x00000400 -- DELETE_POSITION + \item 0x00000800 -- DELETE_TIME + \item 0x00001000 -- DELETE_IONO + \item 0x00002000 -- DELETE_UTC + \item 0x00004000 -- DELETE_HEALTH + \item 0x00008000 -- DELETE_SADATA + \item 0x00010000 -- DELETE_RTI + \item 0x00020000 -- DELETE_SV_NO_EXIST + \item 0x00040000 -- DELETE_FREQ_BIAS_EST + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Delete Cell Database */ uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; - /**< Mask for the cell database assistance data that is to be deleted. \n - Valid values: \n - - 0x00000001 -- DELETE_CELLDB_POS \n - - 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS \n - - 0x00000004 -- DELETE_CELLDB_OTA_POS \n - - 0x00000008 -- DELETE_CELLDB_EXT_REF_POS \n - - 0x00000010 -- DELETE_CELLDB_TIMETAG \n - - 0x00000020 -- DELETE_CELLDB_CELLID \n - - 0x00000040 -- DELETE_CELLDB_CACHED_CELLID \n - - 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL \n - - 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL \n - - 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO + /**< Mask for the cell database assistance data that is to be deleted. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- DELETE_CELLDB_POS + \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS + \item 0x00000004 -- DELETE_CELLDB_OTA_POS + \item 0x00000008 -- DELETE_CELLDB_EXT_REF_POS + \item 0x00000010 -- DELETE_CELLDB_TIMETAG + \item 0x00000020 -- DELETE_CELLDB_CELLID + \item 0x00000040 -- DELETE_CELLDB_CACHED_CELLID + \item 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL + \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL + \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Delete Clock Info */ uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; - /**< Mask for the clock information assistance data that is to be deleted. \n - Valid values: \n - - 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST \n - - 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST \n - - 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER \n - - 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME \n - - 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER \n - - 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST \n - - 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST \n - - 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER \n - - 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER \n - - 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY \n - - 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT + /**< Mask for the clock information assistance data that is to be deleted. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST + \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST + \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER + \item 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME + \item 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER + \item 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST + \item 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST + \item 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER + \item 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER + \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY + \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT + \vspace{-0.18in} \end{itemize1} */ }qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ /** @@ -3720,14 +4345,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Delete Assist Data request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ /** @@ -3762,14 +4389,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set XTRA-T Session Control request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ /** @@ -3794,14 +4423,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get XTRA-T Session Control request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -3824,8 +4455,7 @@ typedef struct { uint32_t wifiPositionTime; /**< Common counter (typically, the number of milliseconds since bootup). This field is only to be provided if the modem and host processors are - synchronized. \n - - Type: Unsigned integer */ + synchronized. */ }qmiLocWifiFixTimeStructT_v02; /* Type */ /** @} @@ -3869,12 +4499,10 @@ typedef struct { uint16_t hepe; /**< WiFi position HEPE.\n - - Type: Unsigned integer \n - Units: Meters */ uint8_t numApsUsed; - /**< Number of Access Points (AP) used to generate a fix. \n - - Type: Unsigned integer */ + /**< Number of Access Points (AP) used to generate a fix. */ qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; /**< WiFi position error code; set to 0 if the fix succeeds. This position @@ -3882,14 +4510,16 @@ typedef struct { the error code provided by the WiFi positioning system can be provided here. - Valid values: \n - - 0x00000000 -- ERROR_SUCCESS \n - - 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE \n - - 0x00000002 -- ERROR_NO_AP_FOUND \n - - 0x00000003 -- ERROR_UNAUTHORIZED \n - - 0x00000004 -- ERROR_SERVER_UNAVAILABLE \n - - 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED \n - - 0x00000006 -- ERROR_UNKNOWN + Valid values: + \begin{itemize1} + \item 0x00000000 -- ERROR_SUCCESS + \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE + \item 0x00000002 -- ERROR_NO_AP_FOUND + \item 0x00000003 -- ERROR_UNAUTHORIZED + \item 0x00000004 -- ERROR_SERVER_UNAVAILABLE + \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED + \item 0x00000006 -- ERROR_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ }qmiLocWifiFixPosStructT_v02; /* Type */ /** @@ -3914,16 +4544,15 @@ typedef struct { int32_t rssi; /**< Receive signal strength indicator.\n - - Type: Signed integer \n - Units: dBm (offset with +100 dB) */ uint16_t channel; - /**< WiFi channel on which a beacon was received. \n - - Type: Unsigned integer */ + /**< WiFi channel on which a beacon was received. */ qmiLocWifiApQualifierMaskT_v02 apQualifier; /**< A bitmask of Boolean qualifiers for APs. - All unused bits in this mask must be set to 0. \n + All unused bits in this mask must be set to 0. + Valid values: \n - 0x01 -- BEING_USED \n - 0x02 -- HIDDEN_SSID \n @@ -3966,12 +4595,14 @@ typedef struct { qmiLocReliabilityEnumT_v02 horizontalReliability; /**< Specifies the reliability of the horizontal position. - Valid values: \n - - 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \n - - 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \n - - 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \n - - 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \n - - 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + Valid values: + \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ /** @@ -3989,14 +4620,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject WiFi Position request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ /** @@ -4028,9 +4661,11 @@ typedef struct { qmiLocWifiStatusEnumT_v02 wifiStatus; /**< WiFi status information. - Valid values: \n - - 0x00000001 -- WIFI_STATUS_AVAILABLE \n - - 0x00000002 -- WIFI_STATUS_UNAVAILABLE + Valid values: + \begin{itemize1} + \item 0x00000001 -- WIFI_STATUS_AVAILABLE + \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE + \vspace{-0.18in} \end{itemize1} */ }qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ /** @@ -4048,14 +4683,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Notify WiFi Status request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ /** @@ -4080,14 +4717,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Registered Events request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4096,21 +4735,23 @@ typedef struct { qmiLocEventRegMaskT_v02 eventRegMask; /**< Event registration mask. - Valid bitmasks: \n - - 0x00000001 -- POSITION_REPORT \n - - 0x00000002 -- GNSS_SV_INFO \n - - 0x00000004 -- NMEA \n - - 0x00000008 -- NI_NOTIFY_VERIFY_REQ \n - - 0x00000010 -- INJECT_TIME_REQ \n - - 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ \n - - 0x00000040 -- INJECT_POSITION_REQ \n - - 0x00000080 -- ENGINE_STATE \n - - 0x00000100 -- FIX_SESSION_STATE \n - - 0x00000200 -- WIFI_REQ \n - - 0x00000400 -- SENSOR_STREAMING_READY_STATUS \n - - 0x00000800 -- TIME_SYNC_REQ \n - - 0x00001000 -- SET_SPI_STREAMING_REPORT \n - - 0x00002000 -- LOCATION_SERVER__CONNECTION_REQ + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- POSITION_REPORT + \item 0x00000002 -- GNSS_SV_INFO + \item 0x00000004 -- NMEA + \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ + \item 0x00000010 -- INJECT_TIME_REQ + \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ + \item 0x00000040 -- INJECT_POSITION_REQ + \item 0x00000080 -- ENGINE_STATE + \item 0x00000100 -- FIX_SESSION_STATE + \item 0x00000200 -- WIFI_REQ + \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS + \item 0x00000800 -- TIME_SYNC_REQ + \item 0x00001000 -- SET_SPI_STREAMING_REPORT + \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ /** @@ -4148,12 +4789,14 @@ typedef struct { qmiLocOperationModeEnumT_v02 operationMode; /**< Preferred operation mode. - Valid values: \n - - 0x00000001 -- OPER_MODE_DEFAULT \n - - 0x00000002 -- OPER_MODE_MSB \n - - 0x00000003 -- OPER_MODE_MSA \n - - 0x00000004 -- OPER_MODE_STANDALONE \n - - 0x00000005 -- OPER_MODE_CELL_ID + Valid values: + \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetOperationModeReqMsgT_v02; /* Message */ /** @@ -4173,14 +4816,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Operation Mode request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetOperationModeIndMsgT_v02; /* Message */ /** @@ -4204,14 +4849,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Operation Mode request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4220,12 +4867,14 @@ typedef struct { qmiLocOperationModeEnumT_v02 operationMode; /**< Current operation mode. - Valid values: \n - - 0x00000001 -- OPER_MODE_DEFAULT \n - - 0x00000002 -- OPER_MODE_MSB \n - - 0x00000003 -- OPER_MODE_MSA \n - - 0x00000004 -- OPER_MODE_STANDALONE \n - - 0x00000005 -- OPER_MODE_CELL_ID + Valid values: + \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetOperationModeIndMsgT_v02; /* Message */ /** @@ -4242,16 +4891,17 @@ typedef struct { /* Mandatory */ /* Stationary Status */ uint8_t stationary; - /**< Whether the device is stationary:\n - - 0x00 (FALSE) -- Device is not stationary \n - - 0x01 (TRUE) -- Device is stationary */ + /**< Whether the device is stationary: + \begin{itemize1} + \item 0x00 (FALSE) -- Device is not stationary + \item 0x01 (TRUE) -- Device is stationary + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Confidence */ uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ uint8_t confidenceStationary; /**< Confidence in the Stationary state expressed as a percentage.\n - - Type: Unsigned integer \n - Range: 0 to 100 */ }qmiLocSetSpiStatusReqMsgT_v02; /* Message */ /** @@ -4268,15 +4918,18 @@ typedef struct { /* Mandatory */ /* Status of SPI Status Request */ qmiLocStatusEnumT_v02 status; - /**< Status of the SPI Status request. \n - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + /**< Status of the SPI Status request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSpiStatusIndMsgT_v02; /* Message */ /** @@ -4286,6 +4939,8 @@ typedef struct { typedef uint8_t qmiLocSensorDataFlagMaskT_v02; #define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting the sensor data. */ +#define QMI_LOC_SENSOR_DATA_FLAG_SENSOR_TIME_IS_MODEM_TIME_V02 ((qmiLocSensorDataFlagMaskT_v02)0x02) /**< Bitmask to specify that the sensor time stamp is the same as the modem + time stamp. */ /** @addtogroup loc_qmi_aggregates @{ */ @@ -4294,26 +4949,22 @@ typedef struct { uint16_t timeOffset; /**< Sample time offset. This time offset must be relative to the sensor time of the first sample.\n - - Type: Unsigned integer \n - Units: Milliseconds */ float xAxis; /**< Sensor x-axis sample. \n - - Type: Floating point \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyrometer: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds^2) ) */ float yAxis; /**< Sensor y-axis sample. \n - - Type: Floating point \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyrometer: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds^2) ) */ float zAxis; /**< Sensor z-axis sample. \n - - Type: Floating point \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyrometer: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds^2) ) */ }qmiLoc3AxisSensorSampleStructT_v02; /* Type */ /** @} @@ -4327,16 +4978,16 @@ typedef struct { uint32_t timeOfFirstSample; /**< Denotes a full 32-bit time tag of the first (oldest) sample in this message. \n - - Type: Unsigned integer \n - Units: Milliseconds */ qmiLocSensorDataFlagMaskT_v02 flags; /**< Flags to indicate any deviation from the default measurement assumptions. All unused bits in this field must be set to 0. - Valid bitmasks: \n - - 0x01 -- SIGN REVERSAL - */ + Valid bitmasks: \begin{itemize1} + \item 0x01 -- SIGN_REVERSAL + \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME + \vspace{-0.18in} \end{itemize1} */ uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; @@ -4360,8 +5011,7 @@ typedef struct { uint32_t opaqueIdentifier; /**< An opaque identifier that is sent in by the client that will be echoed in the indication so the client can relate the indication to the - request. \n - - Type: Unsigned integer */ + request. */ /* Optional */ /* 3-Axis Accelerometer Data */ @@ -4370,10 +5020,10 @@ typedef struct { /**< \n Accelerometer sensor samples. */ /* Optional */ - /* 3-Axis Gyrometer Data */ + /* 3-Axis Gyroscope Data */ uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; - /**< \n Gyrometer sensor samples. */ + /**< \n Gyroscope sensor samples. */ }qmiLocInjectSensorDataReqMsgT_v02; /* Message */ /** @} @@ -4391,36 +5041,37 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject Sensor Data request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Opaque Identifier */ uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ uint32_t opaqueIdentifier; - /**< An opaque identifier that was sent in by the client echoed - so the client can relate the indication to the request. \n - - Type: Unsigned integer */ + /**< Opaque identifier that was sent in by the client echoed + so the client can relate the indication to the request. */ /* Optional */ /* Accelerometer Samples Accepted */ uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ uint8_t threeAxisAccelSamplesAccepted; - /**< This field lets the client know how many 3-axis accelerometer samples + /**< Lets the client know how many 3-axis accelerometer samples were accepted. */ /* Optional */ - /* Gyrometer Samples Accepted */ + /* Gyroscope Samples Accepted */ uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ uint8_t threeAxisGyroSamplesAccepted; - /**< This field lets the client know how many 3-axis gyrometer samples were + /**< Lets the client know how many 3-axis gyroscope samples were accepted. */ }qmiLocInjectSensorDataIndMsgT_v02; /* Message */ /** @@ -4437,29 +5088,26 @@ typedef struct { /* Reference Time Sync Counter */ uint32_t refCounter; /**< Must be set to the value that was sent to the control point when the - GNSS location engine requested time sync injection. \n - - Type: Unsigned integer */ + GNSS location engine requested time sync injection. */ /* Mandatory */ /* Sensor Receive Time */ uint32_t sensorProcRxTime; - /**< The value of the sensor time when the control point received the + /**< Value of the sensor time when the control point received the Time Sync Inject request from the GNSS location engine. Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 millisecond, never stopping until the process is rebooted.\n - - Type: Unsigned integer \n - Units: Milliseconds */ /* Mandatory */ /* Sensor Transmit Time */ uint32_t sensorProcTxTime; - /**< The value of the sensor time when the control point injects this message + /**< Value of the sensor time when the control point injects this message for use by the GNSS location engine. Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 millisecond, never stopping until the process is rebooted.\n - - Type: Unsigned integer \n - Units: Milliseconds */ }qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ /** @@ -4477,14 +5125,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject Time Sync Data request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ /** @@ -4524,14 +5174,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Cradle Mount Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4540,10 +5192,12 @@ typedef struct { qmiLocCradleMountStateEnumT_v02 cradleMountState; /**< Cradle Mount state set by the control point. - Valid values: \n - - 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \n - - 0x00000001 -- CRADLE_STATE_MOUNTED \n - - 0x00000002 -- CRADLE_STATE_UNKNOWN + Valid values: + \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4551,7 +5205,6 @@ typedef struct { uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ uint8_t confidenceCradleMountState; /**< Confidence of the Cradle Mount state expressed as a percentage.\n - - Type: Unsigned integer \n - Range: 0 to 100 */ }qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ /** @@ -4570,17 +5223,18 @@ typedef struct { qmiLocCradleMountStateEnumT_v02 cradleMountState; /**< Cradle Mount state set by the control point. - Valid values: \n - - 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \n - - 0x00000001 -- CRADLE_STATE_MOUNTED \n - - 0x00000002 -- CRADLE_STATE_UNKNOWN */ + Valid values: + \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Cradle Mount Confidence */ uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ uint8_t confidenceCradleMountState; /**< Confidence in the Cradle Mount state expressed as a percentage.\n - - Type: Unsigned integer \n - Range: 0 to 100 */ }qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ /** @@ -4599,14 +5253,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Cradle Mount Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ /** @@ -4646,14 +5302,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get External Power Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4662,10 +5320,12 @@ typedef struct { qmiLocExternalPowerConfigEnumT_v02 externalPowerState; /**< Power state; injected by the control point. - Valid values: \n - - 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \n - - 0x00000001 -- EXTERNAL_POWER_CONNECTED \n - - 0x00000002 -- EXTERNAL_POWER_UNKNOWN + Valid values: + \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ /** @@ -4684,10 +5344,12 @@ typedef struct { qmiLocExternalPowerConfigEnumT_v02 externalPowerState; /**< Power state; injected by the control point. - Valid values: \n - - 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \n - - 0x00000001 -- EXTERNAL_POWER_CONNECTED \n - - 0x00000002 -- EXTERNAL_POWER_UNKNOWN + Valid values: + \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ /** @@ -4706,14 +5368,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set External Power Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ /** @@ -4752,9 +5416,11 @@ typedef struct { */ char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; - /**< APN name. \n - - Type: NULL-terminated string \n - - Maximum string length (including NULL terminator): 101 + /**< APN name. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 101 + \vspace{-0.18in} \end{itemize1} */ }qmiLocApnProfilesStructT_v02; /* Type */ /** @@ -4788,8 +5454,7 @@ typedef struct { /* Connection Handle */ uint32_t connHandle; /**< Connection handle that the service specified in the - Location Server Connection request event. \n - - Type: Unsigned integer */ + Location Server Connection request event. */ /* Mandatory */ /* Request Type */ @@ -4838,14 +5503,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inform Location Server Connection Status request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ /** @@ -4880,6 +5547,9 @@ typedef enum { @} */ +typedef uint32_t qmiLocLppConfigMaskT_v02; +#define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ +#define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ /** @addtogroup loc_qmi_messages @{ */ @@ -4891,9 +5561,11 @@ typedef struct { /* SUPL Security */ uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. \n - - 0x01 (TRUE) -- SUPL security is enabled \n - - 0x00 (FALSE) -- SUPL security is disabled */ + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* VX Version */ @@ -4901,9 +5573,11 @@ typedef struct { qmiLocVxVersionEnumT_v02 vxVersion; /**< VX version. - Valid values: \n - - 0x00000001 -- VX_VERSION_V1_ONLY \n - - 0x00000002 -- VX_VERSION_V2_ONLY + Valid values: + \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4916,15 +5590,29 @@ typedef struct { - 0x00000001 -- SUPL_VERSION_1_0 \n - 0x00000002 -- SUPL_VERSION_2_0 */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ }qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ /** @} */ typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000001) /**< Mask for the SUPL security configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000002) /**< Mask for the VX version configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x00000004) /**< Mask for the SUPL version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000001ull) /**< Mask for the SUPL security configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ /** @addtogroup loc_qmi_messages @{ */ @@ -4937,14 +5625,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Configuration Parameters request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -4955,10 +5645,13 @@ typedef struct { not successful, this field will identify the parameters that were not set successfully. - Valid bitmasks: \n - - 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \n - - 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \n - - 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + Valid bitmasks: + \begin{itemize1} + \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY + \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION + \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ /** @@ -4977,10 +5670,13 @@ typedef struct { qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; /**< Mask denoting the configuration parameters to be retrieved. - Valid bitmasks: \n - - 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \n - - 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \n - - 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + Valid bitmasks: + \begin{itemize1} + \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY + \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION + \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ /** @@ -4999,23 +5695,27 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Configuration Parameters request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* SUPL Security */ uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. \n - - 0x01 (TRUE) -- SUPL security is enabled \n - - 0x00 (FALSE) -- SUPL security is disabled */ + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* VX Version */ @@ -5023,9 +5723,11 @@ typedef struct { qmiLocVxVersionEnumT_v02 vxVersion; /**< VX version. - Valid values: \n - - 0x00000001 -- VX_VERSION_V1_ONLY \n - - 0x00000002 -- VX_VERSION_V2_ONLY + Valid values: + \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5038,6 +5740,19 @@ typedef struct { - 0x00000001 -- SUPL_VERSION_1_0 \n - 0x00000002 -- SUPL_VERSION_2_0 */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ }qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -5075,15 +5790,17 @@ typedef struct { /**< Controls how sensors are used to aid heading and positioning performance. - Valid values:\n - - 0x00000000 -- SENSORS USE ENABLED: \n - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. \n - - 0x00000001 -- SENSORS USE DISABLED: \n - Inertial sensors are not to be used to aid in heading and - position improvement. + Valid values: + \begin{itemize1} + \item 0x00000000 -- SENSORS USE ENABLED: \n + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS USE DISABLED: \n + Inertial sensors are not to be used to aid in heading and + position improvement. + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ /** @@ -5101,14 +5818,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Sensor Control Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ /** @@ -5132,14 +5851,16 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Sensors Control Configuration request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5149,21 +5870,29 @@ typedef struct { /**< Controls how sensors are used to aid the heading and positioning performance. - Valid values:\n - - 0x00000000 -- SENSORS USE ENABLED: \n - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. \n - - 0x00000001 -- SENSORS USE DISABLED: \n - Inertial sensors are not to be used to aid in the heading and - position improvement. + Valid values: + \begin{itemize1} + \item 0x00000000 -- SENSORS USE ENABLED: \n + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS USE DISABLED: \n + Inertial sensors are not to be used to aid in the heading and + position improvement. + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ /** @} */ +typedef uint32_t qmiLocSensorPropertiesMaskT_v02; +#define QMI_LOC_SENSOR_PROPERTIES_MASK_GYRO_BIAS_VARIANCE_RANDOM_WALK_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000001) /**< Denotes the gyro bias variance random walk parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000002) /**< Denotes the velocity random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000004) /**< Denotes the acceleration random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000008) /**< Denotes the angle random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_RATE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000010) /**< Denotes the rate random walk spectral density parameter. */ /** @addtogroup loc_qmi_messages @{ */ @@ -5174,14 +5903,62 @@ typedef struct { typedef struct { /* Optional */ - /* Gyro Bias Variance */ + /* Gyro Bias Random Walk Variance */ uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk parameter as a positive - floating-point value. This value does not have any internal defaults. + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. The gyro bias variance random walk parameter is derived from either the sensors data sheet or a sensors conformance test. \n - - Units: radians^2/second^4 + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 */ }qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ @@ -5203,25 +5980,64 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Sensor Properties request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Set Sensor Properties */ + uint8_t failedSensorPropertiesMask_valid; /**< Must be set to true if failedSensorPropertiesMask is being passed */ + qmiLocSensorPropertiesMaskT_v02 failedSensorPropertiesMask; + /**< This field will be sent only if the status is not a success. + Identifies the parameters that were not set successfully. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ /** @} */ -/* - * qmiLocGetSensorPropertiesReqMsgT is empty - * typedef struct { - * }qmiLocGetSensorPropertiesReqMsgT_v02; - */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Sensor Properties Config Parameters */ + qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; + /**< Mask denoting the sensor properties parameters to be retrieved. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ /** @addtogroup loc_qmi_messages @{ @@ -5234,25 +6050,76 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Sensors Properties request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} */ /* Optional */ - /* Gyro Bias Variance */ + /* Gyro Bias Random Walk Variance */ uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk parameter as a positive - floating-point value. This value does not have any internal defaults. + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. The gyro bias variance random walk parameter is derived from either the sensors data sheet or a sensors conformance test. \n - - Units: radians^2/seconds^4 + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 */ }qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ @@ -5280,6 +6147,9 @@ typedef enum { @} */ +typedef uint32_t qmiLocSensorAlgorithmMaskT_v02; +#define QMI_LOC_SENSOR_ALGORITHM_MASK_DISABLE_INS_POSITIONING_FILTER_V02 ((qmiLocSensorAlgorithmMaskT_v02)0x00000001) /**< Inertial sensors are not to be used in Accelerometer-integrated fashion with + GNSS. They can still be used for aiding in heading improvements. */ /** @addtogroup loc_qmi_messages @{ */ @@ -5295,13 +6165,15 @@ typedef struct { This field is relevant only when sensors have been enabled using the sensors control configuration. - Valid values: \n - - 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data injection - based on internal criteria. This is the default. \n - - 0x00000001 -- FORCED: \n - The GNSS location engine must request use of sensors every time the GNSS - location engine turns on. + Valid values: + \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x00000001 -- FORCED: \n + The GNSS location engine must request use of sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5316,7 +6188,7 @@ typedef struct { */ /* Optional */ - /* Gyrometer Sampling Specification */ + /* Gyroscope Sampling Specification */ uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request @@ -5325,6 +6197,18 @@ typedef struct { However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Sets which sensor algorithms are to be used when processing sensor data. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ }qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ /** @} @@ -5334,6 +6218,7 @@ typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ /** @addtogroup loc_qmi_messages @{ */ @@ -5344,15 +6229,18 @@ typedef struct { /* Mandatory */ /* Set Sensor Perf Control Config Status */ qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Performance Control Configuration request. \n - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + /**< Status of the Set Sensor Performance Control Configuration request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5360,11 +6248,15 @@ typedef struct { uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; /**< This field is sent only if the status is not a success. - When sent, this field identifies which configuration failed. \n - Valid bitmasks: \n - - 0x0000000000000001 -- PERFORMANCE_MODE \n - - 0x0000000000000002 -- ACCEL_SAMPLING_SPEC \n - - 0x0000000000000004 -- GYRO_SAMPLING_SPEC + When sent, this field identifies which configuration failed. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- PERFORMANCE_MODE + \item 0x00000002 -- ACCEL_SAMPLING_SPEC + \item 0x00000004 -- GYRO_SAMPLING_SPEC + \item 0x00000008 -- ALGORITHM_CONFIG + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ /** @@ -5387,15 +6279,18 @@ typedef struct { /* Mandatory */ /* Get Sensor Perf Control Config Status */ qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensor Performance Control Configuration request. \n - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + /**< Status of the Get Sensor Performance Control Configuration request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5406,13 +6301,15 @@ typedef struct { This field is relevant only when sensors have been enabled using the sensor control configuration. - Valid values: \n - - 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data injection - based on internal criteria. This is the default. \n - - 0x0000001 -- FORCED: \n - The GNSS location engine must request use of the sensors every time the GNSS - location engine turns on. + Valid values: + \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x0000001 -- FORCED: \n + The GNSS location engine must request use of the sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -5427,7 +6324,7 @@ typedef struct { */ /* Optional */ - /* Gyrometer Sampling Specification */ + /* Gyroscope Sampling Specification */ uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request @@ -5436,6 +6333,18 @@ typedef struct { However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Informs which sensor algorithms are currently set. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ }qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ /** @} @@ -5444,24 +6353,23 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Request Message; Inject a SUPL certificate to be used in AGNSS sessions. */ +/** Request Message; Injects a SUPL certificate to be used in AGNSS sessions. */ typedef struct { /* Mandatory */ - /* SUPL Certificate Id */ + /* SUPL Certificate ID */ uint8_t suplCertId; - /**< Certificate Id of the Supl Certificate - Type: Unsigned Integer - Units: Bytes - Range: 0-9 */ + /**< Certificate ID of the SUPL certificate. \n + - Units: Bytes \n + - Range: 0 to 9 */ /* Mandatory */ - /* SUPL certificate Data */ + /* SUPL Certificate Data */ uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; - /**< The supl Certificate contents - Type: Array of bytes. - - Maximum certificate size : 2000 bytes */ + /**< SUPL certificate contents. \n + - Type: Array of bytes. \n + - Maximum certificate size: 2000 bytes */ }qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ /** @} @@ -5470,22 +6378,24 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Indication Message; Inject a SUPL certificate to be used in AGNSS sessions. */ +/** Indication Message; Injects a SUPL certificate to be used in AGNSS sessions. */ typedef struct { /* Mandatory */ - /* Supl Certificate Injection Status */ + /* SUPL Certificate Injection Status */ qmiLocStatusEnumT_v02 status; - /**< Status of the inject SUPL certificate request. \n + /**< Status of the Inject SUPL Certificate request. - Valid Values: - - 0x00000000 -- SUCCESS\n - - 0x00000001 -- GENERAL_FAILURE\n - - 0x00000002 -- UNSUPPORTED\n - - 0x00000003 -- INVALID_PARAMETER\n - - 0x00000004 -- ENGINE_BUSY\n - - 0x00000005 -- PHONE_OFFLINE\n - - 0x00000006 -- LOC_TIMEOUT\n + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ /** @@ -5495,19 +6405,18 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Request Message; Delete a SUPL certificate. */ +/** Request Message; Deletes a SUPL certificate. */ typedef struct { /* Optional */ - /* SUPL Certificate Id */ + /* SUPL Certificate ID */ uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ uint8_t suplCertId; - /**< Certificate Id of the Supl Certificate to be deleted - Type: Unsigned Integer \n - Units: Bytes \n - Range: 0-9 \n - If suplCertId is not specified then - "all" supl certificates will be deleted. */ + /**< Certificate ID of the SUPL certificate to be deleted. \n + - Units: Bytes \n + - Range: 0 to 9 \n + If suplCertId is not specified, + all SUPL certificates are deleted. */ }qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ /** @} @@ -5516,22 +6425,24 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Indication Message; Delete a SUPL certificate. */ +/** Indication Message; Deletes a SUPL certificate. */ typedef struct { /* Mandatory */ - /* SUPL certifcate Deletion Status */ + /* SUPL Certificate Deletion Status */ qmiLocStatusEnumT_v02 status; - /**< Status of the delete SUPL certificate request. \n + /**< Status of the Delete SUPL Certificate request. - Valid Values: - - 0x00000000 -- SUCCESS\n - - 0x00000001 -- GENERAL_FAILURE\n - - 0x00000002 -- UNSUPPORTED\n - - 0x00000003 -- INVALID_PARAMETER\n - - 0x00000004 -- ENGINE_BUSY\n - - 0x00000005 -- PHONE_OFFLINE\n - - 0x00000006 -- LOC_TIMEOUT\n + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ }qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ /** @@ -5539,12 +6450,12 @@ typedef struct { */ typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< This field denotes if the position engine uses the - injected position in direct position calculation. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< This field denotes if the position engine filters the +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< Denotes whether the position engine uses the + injected position in a direct position calculation. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< Denotes whether the position engine filters the SV usage in the fix. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< This field denotes if the position engine stores assistance data - in the persistent memory. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< Denotes whether the position engine stores assistance data + in persistent memory. */ /** @addtogroup loc_qmi_messages @{ */ @@ -5556,39 +6467,45 @@ typedef struct { /* Injected Position Control */ uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ uint8_t injectedPositionControl; - /**< Controls how the injected position will be used in position engine.\n - Valid values: \n - - 0x01 (TRUE) -- Use the injected position in direct position - calculation. \n - - 0x00 (FALSE) -- Do not use the injected position in direct position - calculation. \n - The default value is TRUE, the injected position is used in direct - position calculation by default. + /**< Controls how the injected position is used in the position engine. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- Use the injected position in a direct position + calculation + \item 0x00 (FALSE) -- Do not use the injected position in a direct + position calculation + \end{itemize1} + The default value is TRUE. */ /* Optional */ /* Filter SV Usage */ uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ uint8_t filterSvUsage; - /**< Controls if SV usage will be filtered in a position fix. - Valid values:\n - - 0x01 (TRUE) -- Filter the usage of SV's in the fix. \n - - 0x00 (FALSE) -- Do not filter the usage of SV's in the fix. \n - The default value is FALSE, the SV usage is not filtered in the - fix by default. + /**< Controls whether SV usage is filtered in a position fix. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- Filter the usage of SVs in the fix + \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix + \end{itemize1} + The default value is FALSE. */ /* Optional */ /* Store Assist Data */ uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ uint8_t storeAssistData; - /**< Controls whether assistance data should be stored in - the persistent memory. \n - Valid values:\n - - 0x01 (TRUE) -- Store assistance data in persistent memory. \n - - 0x00 (FALSE) -- Do not store assistance data in persistent memory. \n - The default value is TRUE, the assistance data is stored in - persistent memory by default. + /**< Controls whether assistance data is to be stored in + persistent memory. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- Store assistance data in persistent memory + \item 0x00 (FALSE) -- Do not store assistance data in persistent memory + \end{itemize1} + The default value is TRUE. */ }qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ /** @@ -5607,27 +6524,31 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Configuration Parameters request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Failed Parameters */ uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; - /**< This field will be sent only if the status is not a success. - Identifies the parameters that were not set successfully. + /**< Identifies the parameters that were not set successfully. + This field is sent only if the status is other than SUCCESS. - Valid bitmasks: \n - - 0x00000001 -- INJECTED_POSITION_CONTROL \n - - 0x00000002 -- FILTER_SV_USAGE \n - - 0x00000004 -- STORE_ASSIST_DATA + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} */ }qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ /** @@ -5645,10 +6566,13 @@ typedef struct { /* Config Parameters */ qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; /**< Mask denoting the configuration parameters to be retrieved. - Valid bitmasks: \n - - 0x00000001 -- INJECTED_POSITION_CONTROL \n - - 0x00000002 -- FILTER_SV_USAGE \n - - 0x00000004 -- STORE_ASSIST_DATA + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ /** @@ -5667,59 +6591,880 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Configuration Parameters request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000005 -- PHONE_OFFLINE \n - - 0x00000006 -- LOC_TIMEOUT + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Injected Position Control */ uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ uint8_t injectedPositionControl; - /**< Specifies if the injected position is used for direct calculation - in the position engine.\n - Valid values: \n - - 0x01 (TRUE) -- The injected position is used in direct position - calculation. \n - - 0x00 (FALSE) -- The injected position is not used direct position - calculation. \n - The default value is TRUE, the injected position is used in direct - position calculation by default. + /**< Specifies whether the injected position is used for a direct calculation + in the position engine. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- The injected position is used in a direct + position calculation + \item 0x00 (FALSE) -- The injected position is not used in a direct + position calculation + \end{itemize1} + The default value is TRUE. */ /* Optional */ /* Filter SV Usage */ uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ uint8_t filterSvUsage; - /**< Specifies if SV usage is filtered in a position fix. - Valid values: \n - - 0x01 (TRUE) -- SV usage is filtered in the fix. \n - - 0x00 (FALSE) -- SV usage is not filtered in the fix. \n - The default value is FALSE, the SV usage is not filtered in the - fix by default. + /**< Specifies whether SV usage is filtered in a position fix. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- SV usage is filtered in the fix + \item 0x00 (FALSE) -- SV usage is not filtered in the fix + \end{itemize1} + The default value is FALSE. */ /* Optional */ /* Store Assist Data */ uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ uint8_t storeAssistData; - /**< Specifies if assistance data is stored in the persistent memory. \n - Valid values: \n - 0x01 (TRUE) -- Assistance data is stored in persistent memory. \n - 0x00 (FALSE) -- Assistance data is not stored in persistent memory. \n - The default value is TRUE, the assistance data is stored in - persistent memory by default. + /**< Specifies whether assistance data is stored in persistent memory. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- Assistance data is stored in persistent memory + \item 0x00 (FALSE) -- Assistance data is not stored in persistent + memory + \end{itemize1} + The default value is TRUE. */ }qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ /** @} */ +typedef uint8_t qmiLocGeofenceBreachMaskT_v02; +#define QMI_LOC_GEOFENCE_BREACH_ENTERING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x01) /**< If this mask is set, a breach event is reported + when the Geofence is entered. */ +#define QMI_LOC_GEOFENCE_BREACH_LEAVING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x02) /**< If this mask is set, a breach event is reported + when the Geofence is exited. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCERESPONSIVENESSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_LOW_V02 = 0x01, /**< The Geofence is monitored for a breach at a + lower rate. The gap between actual breach and + the time it is reported is higher. This + setting results in lower power usage. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a + medium rate. This is the default setting. + The Geofence is monitored for a breach at a + high rate. The gap between actual breach and + the time it is reported is low. This results + in higher power usage. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, + QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceResponsivenessEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCECONFIDENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_CONFIDENCE_LOW_V02 = 0x01, /**< The Geofence engine indicates a breach with + low confidence. This setting results in lower + power usage. This setting can impact the "yield" because + incorrect breach events may be sent. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with + medium confidence. This is the default setting. + The Geofence engine indicates a breach with + high confidence. This setting results in higher + power usage. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, + QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceConfidenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double latitude; + /**< Latitude of the center of the Geofence. */ + + double longitude; + /**< Longitude of the center of the Geofence. */ + + uint32_t radius; + /**< Radius of the circular Geofence in meters. */ +}qmiLocCircularGeofenceArgsStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. + Position outside a Geofence. */ + eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, + QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofencePositionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Add Circular Geofence + indication. */ + + /* Mandatory */ + /* Circular Geofence Arguments */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Mandatory */ + /* Breach Event Mask */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: + \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ + + /* Mandatory */ + /* Include Position in Breach Event */ + uint8_t includePosition; + /**< Specifies whether the Geofence engine is to include the position + in a breach event. + + Valid values: + \begin{itemize1} + \item 0x01 (TRUE) -- Position will be reported with the breach event + \item 0x00 (FALSE) -- Position will not be reported with the breach + event + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Responsiveness */ + uint8_t responsiveness_valid; /**< Must be set to true if responsiveness is being passed */ + qmiLocGeofenceResponsivenessEnumT_v02 responsiveness; + /**< Specifies the rate of detection for a Geofence breach. + This may impact the time lag between the actual breach event and + when it is reported. This parameter has power implications + and is to be fine-tuned to optimize power savings. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW + \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED + \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Confidence */ + uint8_t confidence_valid; /**< Must be set to true if confidence is being passed */ + qmiLocGeofenceConfidenceEnumT_v02 confidence; + /**< Given a breach event, the confidence determines the probability + that the breach happened at the Geofence boundary. + This parameter has power implications and + is to be fine-tuned to optimize power savings. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW + \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED + \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH + \vspace{-0.18in} \end{itemize1} */ +}qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Add Circular Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Add Circular Geofence request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000008 -- INSUFFICIENT_MEMORY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Add Circular + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Geofence identifier allocated by the engine. + The client must include this identifier in all transactions + pertaining to this Geofence. */ +}qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be deleted. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Delete Geofence + indication. */ +}qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Delete Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Geofence request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was deleted. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Delete + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ +}qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. + The Geofence was initiated by the device. */ + eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, + QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceOriginEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. + The Geofence monitoring is suspended. */ + eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, + QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be queried. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned with the Query Geofence + indication. */ +}qmiLocQueryGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Query Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Query Geofence request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was queried. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Query + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence Origin */ + uint8_t geofenceOrigin_valid; /**< Must be set to true if geofenceOrigin is being passed */ + qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; + /**< Originator of the Geofence. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK + \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Position with Respect to Geofence */ + uint8_t posWrtGeofence_valid; /**< Must be set to true if posWrtGeofence is being passed */ + qmiLocGeofencePositionEnumT_v02 posWrtGeofence; + /**< Indicates if the client is currently inside or outside + the Geofence. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_POSITION_INSIDE + \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Circular Geofence Parameters */ + uint8_t circularGeofenceArgs_valid; /**< Must be set to true if circularGeofenceArgs is being passed */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ +}qmiLocQueryGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence to be edited. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Edit Geofence + request. This parameter will always be present if the + status field is set to SUCCESS. + */ + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Breach Event Mask */ + uint8_t breachMask_valid; /**< Must be set to true if breachMask is being passed */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: + \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocGeofenceConfigParamMaskT_v02; +#define QMI_LOC_GEOFENCE_PARAM_MASK_GEOFENCE_STATE_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000001) /**< Mask for the Geofence state parameter. */ +#define QMI_LOC_GEOFENCE_PARAM_MASK_BREACH_MASK_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000002) /**< Mask for Geofence breach mask parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Edit Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Edit Geofence request. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was edited. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is specified in the Edit Geofence request. */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedParams_valid; /**< Must be set to true if failedParams is being passed */ + qmiLocGeofenceConfigParamMaskT_v02 failedParams; + /**< Specified only when the status is not set to SUCCESS. If + the mask corresponding to a field is set, it indicates that + the Geofence parameter could not be edited. + + Valid values: + \begin{itemize1} + \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE + \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Get Best Available Position indication. */ +}qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Best Available Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Best Available Position request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Get Best + Available Position request. This parameter will + always be present if the status field is set to + SUCCESS. */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Units: Milliseconds */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Major Axis */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation. \n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Circular Confidence */ + uint8_t horCircularConfidence_valid; /**< Must be set to true if horCircularConfidence is being passed */ + uint8_t horCircularConfidence; + /**< Horizontal circular uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Elliptical Confidence */ + uint8_t horEllipticalConfidence_valid; /**< Must be set to true if horEllipticalConfidence is being passed */ + uint8_t horEllipticalConfidence; + /**< Horizontal elliptical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ + float horSpeed; + /**< Horizontal speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Horizontal Speed Uncertainty */ + uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ + float horSpeedUnc; + /**< Horizontal speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level. \n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Vertical Speed */ + uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ + float vertSpeed; + /**< Vertical speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Vertical Speed Uncertainty */ + uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ + float vertSpeedUnc; + /**< Vertical speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading. \n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty. \n + - Type: Floating point \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. */ + + /* Optional */ + /* Technology Used Mask */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + + /* Optional */ + /* GPS Time */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. + + Valid values: + \begin{itemize1} + \item 0x00000000 -- TIME_SRC_INVALID + \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER + \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING + \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT + \item 0x00000004 -- TIME_SRC_TOW_DECODE + \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED + \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED + \item 0x00000007 -- TIME_SRC_NAV_SOLUTION + \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ +}qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ +/** + @} + */ + /*Service Message Definition*/ /** @addtogroup loc_qmi_msg_ids @{ @@ -5884,6 +7629,24 @@ typedef struct { #define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F #define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F #define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F +#define QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02 0x0060 +#define QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02 0x0061 +#define QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02 0x0062 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 0x0063 +#define QMI_LOC_DELETE_GEOFENCE_REQ_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_RESP_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_IND_V02 0x0064 +#define QMI_LOC_QUERY_GEOFENCE_REQ_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_RESP_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_IND_V02 0x0065 +#define QMI_LOC_EDIT_GEOFENCE_REQ_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_RESP_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_IND_V02 0x0066 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 /** @} */ diff --git a/loc_api/ulp/inc/ulp.h b/loc_api/ulp/inc/ulp.h old mode 100755 new mode 100644 index 6321bb9c..50d6c91b --- a/loc_api/ulp/inc/ulp.h +++ b/loc_api/ulp/inc/ulp.h @@ -36,14 +36,7 @@ extern "C" #endif #include - -typedef int (ulp_report_position_cb) -( - void* owner, - const GpsLocation* location_report_ptr, - unsigned int ext_data_length, - unsigned char* ext_data -); +#include "loc_eng.h" /** Represents the standard ulp module interface. */ typedef struct { @@ -51,24 +44,14 @@ typedef struct { size_t size; /** - * Starts the ulp module. 0: success + * Starts the libulp module. 0: success */ - int (*init)( void* owner, ulp_report_position_cb* cb); + int (*init)(loc_eng_data_s_type &loc_eng_data); - /** Starts the ulp engine. 0: success */ - int (*start_fix)( void ); - - /** Stops the ulp engine. 0: success */ - int (*stop_fix)( void ); - - /** Closes the interface */ - int (*destroy)( void ); - -} ulpInterface; +}ulpInterface; typedef const ulpInterface* (get_ulp_interface) (void); - #ifdef __cplusplus } #endif diff --git a/utils/Android.mk b/utils/Android.mk old mode 100755 new mode 100644 index 7ce454f8..4bf04014 --- a/utils/Android.mk +++ b/utils/Android.mk @@ -21,6 +21,8 @@ LOCAL_CFLAGS += \ -fno-short-enums \ -D_ANDROID_ +LOCAL_LDFLAGS += -Wl,--export-dynamic + ## Includes LOCAL_C_INCLUDES:= diff --git a/utils/linked_list.c b/utils/linked_list.c old mode 100755 new mode 100644 diff --git a/utils/linked_list.h b/utils/linked_list.h old mode 100755 new mode 100644 diff --git a/utils/loc_cfg.cpp b/utils/loc_cfg.cpp old mode 100755 new mode 100644 index de960788..574c9581 --- a/utils/loc_cfg.cpp +++ b/utils/loc_cfg.cpp @@ -47,28 +47,14 @@ *============================================================================*/ /* Parameter data */ -loc_gps_cfg_s_type gps_conf; +static uint8_t DEBUG_LEVEL = 3; +static uint8_t TIMESTAMP = 0; /* Parameter spec table */ - -loc_param_s_type loc_parameter_table[] = +static loc_param_s_type loc_parameter_table[] = { - {"INTERMEDIATE_POS", &gps_conf.INTERMEDIATE_POS, 'n'}, - {"ACCURACY_THRES", &gps_conf.ACCURACY_THRES, 'n'}, - {"ENABLE_WIPER", &gps_conf.ENABLE_WIPER, 'n'}, - /* DEBUG LEVELS: 0 - none, 1 - Error, 2 - Warning, 3 - Info - 4 - Debug, 5 - Verbose */ - {"DEBUG_LEVEL", &gps_conf.DEBUG_LEVEL, 'n'}, - {"SUPL_VER", &gps_conf.SUPL_VER, 'n'}, - {"CAPABILITIES", &gps_conf.CAPABILITIES, 'n'}, - {"TIMESTAMP", &gps_conf.TIMESTAMP, 'n'}, - {"GYRO_BIAS_RANDOM_WALK", &gps_conf.GYRO_BIAS_RANDOM_WALK, 'f'}, - {"SENSOR_ACCEL_BATCHES_PER_SEC", &gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, 'n'}, - {"SENSOR_ACCEL_SAMPLES_PER_BATCH", &gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, 'n'}, - {"SENSOR_GYRO_BATCHES_PER_SEC", &gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, 'n'}, - {"SENSOR_GYRO_SAMPLES_PER_BATCH", &gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, 'n'}, - {"SENSOR_CONTROL_MODE", &gps_conf.SENSOR_CONTROL_MODE, 'n'}, - {"SENSOR_USAGE", &gps_conf.SENSOR_USAGE, 'n'}, + {"DEBUG_LEVEL", &DEBUG_LEVEL, NULL, 'n'}, + {"TIMESTAMP", &TIMESTAMP, NULL, 'n'}, }; int loc_param_num = sizeof(loc_parameter_table) / sizeof(loc_param_s_type); @@ -92,29 +78,11 @@ SIDE EFFECTS static void loc_default_parameters() { /* defaults */ - gps_conf.INTERMEDIATE_POS = 0; - gps_conf.ACCURACY_THRES = 0; - gps_conf.ENABLE_WIPER = 0; - gps_conf.DEBUG_LEVEL = 3; /* debug level */ - gps_conf.SUPL_VER = 0x10000; - gps_conf.CAPABILITIES = 0x7; - gps_conf.TIMESTAMP = 0; - - gps_conf.GYRO_BIAS_RANDOM_WALK = 0; - - gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC = 2; - gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH = 5; - gps_conf.SENSOR_GYRO_BATCHES_PER_SEC = 2; - gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH = 5; - gps_conf.SENSOR_CONTROL_MODE = 0; /* AUTO */ - gps_conf.SENSOR_USAGE = 0; /* Enabled */ - - /* Value MUST be set by OEMs in configuration for sensor-assisted - navigation to work. There is NO default value */ - gps_conf.GYRO_BIAS_RANDOM_WALK_VALID = 0; + DEBUG_LEVEL = 3; /* debug level */ + TIMESTAMP = 0; /* reset logging mechanism */ - loc_logger_init(gps_conf.DEBUG_LEVEL, 0); + loc_logger_init(DEBUG_LEVEL, TIMESTAMP); } /*=========================================================================== @@ -161,11 +129,26 @@ void trim_space(char *org_string) if (last_nonspace) { *last_nonspace = '\0'; } } +typedef struct loc_param_v_type +{ + char* param_name; + + char* param_str_value; + int param_int_value; + double param_double_value; +}loc_param_v_type; + /*=========================================================================== -FUNCTION loc_read_gps_conf +FUNCTION loc_set_config_entry DESCRIPTION - Reads the gps.conf file and sets global parameter data + Potentially sets a given configuration table entry based on the passed in + configuration value. This is done by using a string comparison of the + parameter names and those found in the configuration file. + +PARAMETERS: + config_entry: configuration entry in the table to possibly set + config_value: value to store in the entry if the parameter names match DEPENDENCIES N/A @@ -176,97 +159,152 @@ RETURN VALUE SIDE EFFECTS N/A ===========================================================================*/ -void loc_read_gps_conf(void) +void loc_set_config_entry(loc_param_s_type* config_entry, loc_param_v_type* config_value) +{ + if(NULL == config_entry || NULL == config_value) + { + LOC_LOGE("%s: INVALID config entry or parameter", __FUNCTION__); + return; + } + + if (strcmp(config_entry->param_name, config_value->param_name) == 0 && + config_entry->param_ptr) + { + switch (config_entry->param_type) + { + case 's': + if (strcmp(config_value->param_str_value, "NULL") == 0) + { + *((char*)config_entry->param_ptr) = '\0'; + } + else { + strlcpy((char*) config_entry->param_ptr, + config_value->param_str_value, + LOC_MAX_PARAM_STRING + 1); + } + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %s", __FUNCTION__, config_entry->param_name, (char*)config_entry->param_ptr); + + if(NULL != config_entry->param_set) + { + *(config_entry->param_set) = 1; + } + break; + case 'n': + *((int *)config_entry->param_ptr) = config_value->param_int_value; + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %d", __FUNCTION__, config_entry->param_name, config_value->param_int_value); + + if(NULL != config_entry->param_set) + { + *(config_entry->param_set) = 1; + } + break; + case 'f': + *((double *)config_entry->param_ptr) = config_value->param_double_value; + /* Log INI values */ + LOC_LOGD("%s: PARAM %s = %f", __FUNCTION__, config_entry->param_name, config_value->param_double_value); + + if(NULL != config_entry->param_set) + { + *(config_entry->param_set) = 1; + } + break; + default: + LOC_LOGE("%s: PARAM %s parameter type must be n, f, or s", __FUNCTION__, config_entry->param_name); + } + } +} + +/*=========================================================================== +FUNCTION loc_read_conf + +DESCRIPTION + Reads the specified configuration file and sets defined values based on + the passed in configuration table. This table maps strings to values to + set along with the type of each of these values. + +PARAMETERS: + conf_file_name: configuration file to read + config_table: table definition of strings to places to store information + table_length: length of the configuration table + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A +===========================================================================*/ +void loc_read_conf(const char* conf_file_name, loc_param_s_type* config_table, uint32_t table_length) { FILE *gps_conf_fp = NULL; char input_buf[LOC_MAX_PARAM_LINE]; /* declare a char array */ char *lasts; - char *param_name, *param_str_value; - int param_int_value = 0; - double param_double_value = 0; - int i; + loc_param_v_type config_value; + uint32_t i; loc_default_parameters(); - if((gps_conf_fp = fopen(GPS_CONF_FILE, "r")) != NULL) + if((gps_conf_fp = fopen(conf_file_name, "r")) != NULL) { LOC_LOGD("%s: using %s", __FUNCTION__, GPS_CONF_FILE); } else { - LOC_LOGW("%s: no %s file, using defaults", __FUNCTION__, GPS_CONF_FILE); + LOC_LOGW("%s: no %s file found", __FUNCTION__, GPS_CONF_FILE); return; /* no parameter file */ } + /* Clear all validity bits */ + for(i = 0; NULL != config_table && i < table_length; i++) + { + if(NULL != config_table[i].param_set) + { + *(config_table[i].param_set) = 0; + } + } + while(fgets(input_buf, LOC_MAX_PARAM_LINE, gps_conf_fp) != NULL) { + memset(&config_value, 0, sizeof(config_value)); + /* Separate variable and value */ - param_name = strtok_r(input_buf, "=", &lasts); - if (param_name == NULL) continue; /* skip lines that do not contain "=" */ - param_str_value = strtok_r(NULL, "=", &lasts); - if (param_str_value == NULL) continue; /* skip lines that do not contain two operands */ + config_value.param_name = strtok_r(input_buf, "=", &lasts); + if (config_value.param_name == NULL) continue; /* skip lines that do not contain "=" */ + config_value.param_str_value = strtok_r(NULL, "=", &lasts); + if (config_value.param_str_value == NULL) continue; /* skip lines that do not contain two operands */ /* Trim leading and trailing spaces */ - trim_space(param_name); - trim_space(param_str_value); - - // printf("*(%s) = (%s)\n", param_name, param_str_value); + trim_space(config_value.param_name); + trim_space(config_value.param_str_value); /* Parse numerical value */ - if (param_str_value[0] == '0' && tolower(param_str_value[1]) == 'x') + if (config_value.param_str_value[0] == '0' && tolower(config_value.param_str_value[1]) == 'x') { /* hex */ - param_int_value = (int) strtol(¶m_str_value[2], (char**) NULL, 16); + config_value.param_int_value = (int) strtol(&config_value.param_str_value[2], (char**) NULL, 16); } else { - param_double_value = (double) atof(param_str_value); /* float */ - param_int_value = atoi(param_str_value); /* dec */ + config_value.param_double_value = (double) atof(config_value.param_str_value); /* float */ + config_value.param_int_value = atoi(config_value.param_str_value); /* dec */ } - if (strcmp("GYRO_BIAS_RANDOM_WALK", param_name) == 0) + for(i = 0; NULL != config_table && i < table_length; i++) { - gps_conf.GYRO_BIAS_RANDOM_WALK_VALID = 1; + loc_set_config_entry(&config_table[i], &config_value); } for(i = 0; i < loc_param_num; i++) { - if (strcmp(loc_parameter_table[i].param_name, param_name) == 0 && - loc_parameter_table[i].param_ptr) - { - switch (loc_parameter_table[i].param_type) - { - case 's': - if (strcmp(param_str_value, "NULL") == 0) - { - *((char*)loc_parameter_table[i].param_ptr) = '\0'; - } - else { - strlcpy((char*) loc_parameter_table[i].param_ptr, - param_str_value, - LOC_MAX_PARAM_STRING + 1); - } - /* Log INI values */ - LOC_LOGD("%s: PARAM %s = %s", __FUNCTION__, param_name, (char*)loc_parameter_table[i].param_ptr); - break; - case 'n': - *((int *)loc_parameter_table[i].param_ptr) = param_int_value; - /* Log INI values */ - LOC_LOGD("%s: PARAM %s = %d", __FUNCTION__, param_name, param_int_value); - break; - case 'f': - *((double *)loc_parameter_table[i].param_ptr) = param_double_value; - /* Log INI values */ - LOC_LOGD("%s: PARAM %s = %f", __FUNCTION__, param_name, param_double_value); - break; - default: - LOC_LOGE("%s: PARAM %s parameter type must be n or n", __FUNCTION__, param_name); - } - } + loc_set_config_entry(&loc_parameter_table[i], &config_value); } } fclose(gps_conf_fp); /* Initialize logging mechanism with parsed data */ - loc_logger_init(gps_conf.DEBUG_LEVEL, gps_conf.TIMESTAMP); + loc_logger_init(DEBUG_LEVEL, TIMESTAMP); } diff --git a/utils/loc_cfg.h b/utils/loc_cfg.h old mode 100755 new mode 100644 index ffeb83c4..bc3b1c3a --- a/utils/loc_cfg.h +++ b/utils/loc_cfg.h @@ -30,7 +30,9 @@ #ifndef LOC_CFG_H #define LOC_CFG_H -#define LOC_MAX_PARAM_NAME 36 +#include + +#define LOC_MAX_PARAM_NAME 48 #define LOC_MAX_PARAM_STRING 80 #define LOC_MAX_PARAM_LINE 80 @@ -39,6 +41,12 @@ #define GPS_CONF_FILE "/etc/gps.conf" //??? platform independent #endif +#define UTIL_READ_CONF_DEFAULT(filename) \ + loc_read_conf((filename), NULL, 0); + +#define UTIL_READ_CONF(filename, config_table) \ + loc_read_conf((filename), (config_table), sizeof(config_table) / sizeof(config_table[0])) + /*============================================================================= * * MODULE TYPE DECLARATION @@ -48,30 +56,12 @@ typedef struct { char param_name[LOC_MAX_PARAM_NAME]; void *param_ptr; - char param_type; /* 'n' for number; 's' for string */ + uint8_t *param_set; /* was this value set by config file? */ + char param_type; /* 'n' for number, + 's' for string, + 'f' for float */ } loc_param_s_type; -/* GPS.conf support */ -typedef struct loc_gps_cfg_s -{ - unsigned long INTERMEDIATE_POS; - unsigned long ACCURACY_THRES; - unsigned long ENABLE_WIPER; - unsigned long DEBUG_LEVEL; - unsigned long SUPL_VER; - unsigned long CAPABILITIES; - unsigned long TIMESTAMP; - unsigned long GYRO_BIAS_RANDOM_WALK_VALID; - double GYRO_BIAS_RANDOM_WALK; - unsigned long SENSOR_ACCEL_BATCHES_PER_SEC; - unsigned long SENSOR_ACCEL_SAMPLES_PER_BATCH; - unsigned long SENSOR_GYRO_BATCHES_PER_SEC; - unsigned long SENSOR_GYRO_SAMPLES_PER_BATCH; - unsigned long SENSOR_CONTROL_MODE; - unsigned long SENSOR_USAGE; - // char string_val[LOC_MAX_PARAM_STRING + 1]; /* An example string value */ -} loc_gps_cfg_s_type; - /*============================================================================= * * MODULE EXTERNAL DATA @@ -82,14 +72,14 @@ typedef struct loc_gps_cfg_s extern "C" { #endif -extern loc_gps_cfg_s_type gps_conf; - /*============================================================================= * * MODULE EXPORTED FUNCTIONS * *============================================================================*/ -extern void loc_read_gps_conf(void); +extern void loc_read_conf(const char* conf_file_name, + loc_param_s_type* config_table, + uint32_t table_length); #ifdef __cplusplus } diff --git a/utils/loc_log.cpp b/utils/loc_log.cpp old mode 100755 new mode 100644 diff --git a/utils/loc_log.h b/utils/loc_log.h old mode 100755 new mode 100644 diff --git a/utils/log_util.h b/utils/log_util.h old mode 100755 new mode 100644 diff --git a/utils/msg_q.c b/utils/msg_q.c old mode 100755 new mode 100644 index 252921ef..cc024e4c --- a/utils/msg_q.c +++ b/utils/msg_q.c @@ -249,7 +249,7 @@ msq_q_err_type msg_q_rcv(void* msg_q_data, void** msg_obj) pthread_mutex_unlock(&p_msg_q->list_mutex); - LOC_LOGD("%s: Received message %p rv = %d\n", __FUNCTION__, *msg_obj, rv); + LOC_LOGD("%s: Received message 0x%08X rv = %d\n", __FUNCTION__, *msg_obj, rv); return rv; } diff --git a/utils/msg_q.h b/utils/msg_q.h old mode 100755 new mode 100644 From cd9e934abeb63f12f23f565a95b80c192abddddd Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Thu, 2 Aug 2012 12:16:26 -0700 Subject: [PATCH 04/33] gps: merge ics tip into jb Merges the following change lists: Ibdd65ec497ad6996c5d55ca907a995ed63b797cf I75266b7102f8cd06db7b9bf038ee24c0dfbed822 I398704add524a807ddc088dfd28520dad7668784 Change-Id: I29275e65fc98568625eded942587c87b4ac8d1b9 --- loc_api/libloc_api_50001/LocApiAdapter.h | 4 +- loc_api/libloc_api_50001/loc_eng.cpp | 40 ++- loc_api/libloc_api_50001/loc_eng.h | 4 + loc_api/libloc_api_50001/loc_eng_msg.h | 38 ++- loc_api/libloc_api_50001/loc_eng_msg_id.h | 6 +- loc_api/loc_api_v02/LocApiV02Adapter.cpp | 13 + loc_api/loc_api_v02/LocApiV02Adapter.h | 4 +- loc_api/loc_api_v02/location_service_v02.c | 137 +++++++-- loc_api/loc_api_v02/location_service_v02.h | 334 ++++++++++++++++++++- 9 files changed, 541 insertions(+), 39 deletions(-) diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h index 1c5e02b2..57d0eae0 100644 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -203,7 +203,9 @@ public: {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, - int gyroSamplesPerBatch, int gyroBatchesPerSec, int algorithmConfig) + int gyroSamplesPerBatch, int gyroBatchesPerSec, + int accelSamplesPerBatchHigh, int accelBatchesPerSecHigh, + int gyroSamplesPerBatchHigh, int gyroBatchesPerSecHigh, int algorithmConfig) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline virtual enum loc_api_adapter_err setExtPowerConfig(int isBatteryCharging) diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 9958ca56..821d9624 100644 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -94,8 +94,13 @@ static loc_param_s_type loc_parameter_table[] = {"SENSOR_ACCEL_SAMPLES_PER_BATCH", &gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH, NULL, 'n'}, {"SENSOR_GYRO_BATCHES_PER_SEC", &gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, NULL, 'n'}, {"SENSOR_GYRO_SAMPLES_PER_BATCH", &gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, NULL, 'n'}, + {"SENSOR_ACCEL_BATCHES_PER_SEC_HIGH", &gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC_HIGH, NULL, 'n'}, + {"SENSOR_ACCEL_SAMPLES_PER_BATCH_HIGH", &gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH_HIGH, NULL, 'n'}, + {"SENSOR_GYRO_BATCHES_PER_SEC_HIGH", &gps_conf.SENSOR_GYRO_BATCHES_PER_SEC_HIGH, NULL, 'n'}, + {"SENSOR_GYRO_SAMPLES_PER_BATCH_HIGH", &gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH_HIGH, NULL, 'n'}, {"SENSOR_CONTROL_MODE", &gps_conf.SENSOR_CONTROL_MODE, NULL, 'n'}, {"SENSOR_USAGE", &gps_conf.SENSOR_USAGE, NULL, 'n'}, + {"SENSOR_ALGORITHM_CONFIG_MASK", &gps_conf.SENSOR_ALGORITHM_CONFIG_MASK, NULL, 'n'}, {"QUIPC_ENABLED", &gps_conf.QUIPC_ENABLED, NULL, 'n'}, {"LPP_PROFILE", &gps_conf.LPP_PROFILE, NULL, 'n'}, }; @@ -114,6 +119,10 @@ static void loc_default_parameters(void) gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH = 5; gps_conf.SENSOR_GYRO_BATCHES_PER_SEC = 2; gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH = 5; + gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC_HIGH = 4; + gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH_HIGH = 25; + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC_HIGH = 4; + gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH_HIGH = 25; gps_conf.SENSOR_CONTROL_MODE = 0; /* AUTO */ gps_conf.SENSOR_USAGE = 0; /* Enabled */ gps_conf.SENSOR_ALGORITHM_CONFIG_MASK = 0; /* INS Disabled = FALSE*/ @@ -374,6 +383,10 @@ static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data) gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC, gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH, gps_conf.SENSOR_GYRO_BATCHES_PER_SEC, + gps_conf.SENSOR_ACCEL_SAMPLES_PER_BATCH_HIGH, + gps_conf.SENSOR_ACCEL_BATCHES_PER_SEC_HIGH, + gps_conf.SENSOR_GYRO_SAMPLES_PER_BATCH_HIGH, + gps_conf.SENSOR_GYRO_BATCHES_PER_SEC_HIGH, gps_conf.SENSOR_ALGORITHM_CONFIG_MASK)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, sensor_perf_control_conf_msg, loc_eng_free_msg); @@ -1444,7 +1457,10 @@ static void loc_eng_deferred_action_thread(void* arg) { loc_eng_msg_sensor_perf_control_config *spccMsg = (loc_eng_msg_sensor_perf_control_config*)msg; loc_eng_data_p->client_handle->setSensorPerfControlConfig(spccMsg->controlMode, spccMsg->accelSamplesPerBatch, spccMsg->accelBatchesPerSec, - spccMsg->gyroSamplesPerBatch, spccMsg->gyroBatchesPerSec, spccMsg->algorithmConfig); + spccMsg->gyroSamplesPerBatch, spccMsg->gyroBatchesPerSec, + spccMsg->accelSamplesPerBatchHigh, spccMsg->accelBatchesPerSecHigh, + spccMsg->gyroSamplesPerBatchHigh, spccMsg->gyroBatchesPerSecHigh, + spccMsg->algorithmConfig); } break; @@ -1498,6 +1514,15 @@ static void loc_eng_deferred_action_thread(void* arg) // turn off the session flag. loc_eng_data_p->client_handle->setInSession(false); } + + // Free the allocated memory for rawData + GpsLocation* gp = (GpsLocation*)&(rpMsg->location); + if (gp != NULL && gp->rawData != NULL) + { + delete (char*)gp->rawData; + gp->rawData = NULL; + gp->rawDataSize = 0; + } } break; @@ -1852,6 +1877,19 @@ bool loc_eng_inject_raw_command(loc_eng_data_s_type &loc_eng_data, LOC_LOGD("loc_eng_send_extra_command: %s\n", command); ret_val = TRUE; + if((loc_eng_data.ulp_initialized == true) && (gps_conf.CAPABILITIES & ULP_CAPABILITY)) + { + ulp_msg_inject_raw_command *msg( + new ulp_msg_inject_raw_command(&loc_eng_data,command, length)); + msg_q_snd( (void*)((LocEngContext*)(loc_eng_data.context))->ulp_q + , msg, loc_eng_free_msg); + ret_val = 0; + }else + { + ret_val = -1; + } + + EXIT_LOG(%s, loc_logger_boolStr[ret_val!=0]); return ret_val; } diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h index e1cf95cc..a14f5bd1 100644 --- a/loc_api/libloc_api_50001/loc_eng.h +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -157,6 +157,10 @@ typedef struct loc_gps_cfg_s unsigned long SENSOR_ACCEL_SAMPLES_PER_BATCH; unsigned long SENSOR_GYRO_BATCHES_PER_SEC; unsigned long SENSOR_GYRO_SAMPLES_PER_BATCH; + unsigned long SENSOR_ACCEL_BATCHES_PER_SEC_HIGH; + unsigned long SENSOR_ACCEL_SAMPLES_PER_BATCH_HIGH; + unsigned long SENSOR_GYRO_BATCHES_PER_SEC_HIGH; + unsigned long SENSOR_GYRO_SAMPLES_PER_BATCH_HIGH; unsigned long SENSOR_CONTROL_MODE; unsigned long SENSOR_USAGE; unsigned long QUIPC_ENABLED; diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h index 4a1cae63..adc138fe 100644 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -223,10 +223,16 @@ struct loc_eng_msg_sensor_perf_control_config : public loc_eng_msg { const int accelBatchesPerSec; const int gyroSamplesPerBatch; const int gyroBatchesPerSec; + const int accelSamplesPerBatchHigh; + const int accelBatchesPerSecHigh; + const int gyroSamplesPerBatchHigh; + const int gyroBatchesPerSecHigh; const int algorithmConfig; inline loc_eng_msg_sensor_perf_control_config(void* instance, int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, int gyroSamplesPerBatch, int gyroBatchesPerSec, + int accelSamplesPerBatchHigh, int accelBatchesPerSecHigh, + int gyroSamplesPerBatchHigh, int gyroBatchesPerSecHigh, int algorithmConfig) : loc_eng_msg(instance, LOC_ENG_MSG_SET_SENSOR_PERF_CONTROL_CONFIG), controlMode(controlMode), @@ -234,15 +240,25 @@ struct loc_eng_msg_sensor_perf_control_config : public loc_eng_msg { accelBatchesPerSec(accelBatchesPerSec), gyroSamplesPerBatch(gyroSamplesPerBatch), gyroBatchesPerSec(gyroBatchesPerSec), + accelSamplesPerBatchHigh(accelSamplesPerBatchHigh), + accelBatchesPerSecHigh(accelBatchesPerSecHigh), + gyroSamplesPerBatchHigh(gyroSamplesPerBatchHigh), + gyroBatchesPerSecHigh(gyroBatchesPerSecHigh), algorithmConfig(algorithmConfig) { LOC_LOGV("Sensor Perf Control Config (performanceControlMode)(%u) " - "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u), algorithmConfig(%u)\n", + "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u), " + "accel_high(#smp,#batches) (%u,%u) gyro_high(#smp,#batches) (%u,%u), " + "algorithmConfig(%u)\n", controlMode, accelSamplesPerBatch, accelBatchesPerSec, gyroSamplesPerBatch, gyroBatchesPerSec, + accelSamplesPerBatchHigh, + accelBatchesPerSecHigh, + gyroSamplesPerBatchHigh, + gyroBatchesPerSecHigh, algorithmConfig ); } @@ -749,6 +765,26 @@ struct ulp_msg_update_criteria : public loc_eng_msg { } }; +struct ulp_msg_inject_raw_command : public loc_eng_msg { + const char* rawCommand; + const int rawCommandLength; + inline ulp_msg_inject_raw_command (void* instance, char* command, int length) : + loc_eng_msg(instance, ULP_MSG_INJECT_RAW_COMMAND), + rawCommand(new char[length]), + rawCommandLength(length) + { + memcpy((void*)rawCommand, (void*)command, length); + LOC_LOGV("inject raw command: command %s\n command length: %d\n ", + rawCommand, + rawCommandLength); + } + + inline ~ulp_msg_inject_raw_command() + { + delete[] rawCommand; + } +}; + struct ulp_msg_inject_phone_context_settings : public loc_eng_msg { const UlpPhoneContextSettings phoneSetting; inline ulp_msg_inject_phone_context_settings(void* instance, UlpPhoneContextSettings setting) : diff --git a/loc_api/libloc_api_50001/loc_eng_msg_id.h b/loc_api/libloc_api_50001/loc_eng_msg_id.h index ff5a6bd7..0c3f5755 100644 --- a/loc_api/libloc_api_50001/loc_eng_msg_id.h +++ b/loc_api/libloc_api_50001/loc_eng_msg_id.h @@ -117,7 +117,11 @@ enum loc_eng_msg_ids_t { /* Message is sent by HAL to LOC API to configure LTE Positioning Profile in modem */ - LOC_ENG_MSG_LPP_CONFIG + LOC_ENG_MSG_LPP_CONFIG, + + // Message is sent by Android framework (GpsLocationProvider) + // to inject the raw command + ULP_MSG_INJECT_RAW_COMMAND, }; #ifdef __cplusplus diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 92acfc75..f352af19 100644 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1335,6 +1335,8 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorProperties(bool gyroBiasVa enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, int gyroSamplesPerBatch, int gyroBatchesPerSec, + int accelSamplesPerBatchHigh, int accelBatchesPerSecHigh, + int gyroSamplesPerBatchHigh, int gyroBatchesPerSecHigh, int algorithmConfig) { locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; @@ -1345,6 +1347,7 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont LOC_LOGD("%s:%d]: Sensor Perf Control Config (performanceControlMode)(%u) " "accel(#smp,#batches) (%u,%u) gyro(#smp,#batches) (%u,%u) " + "accel_high(#smp,#batches) (%u,%u) gyro_high(#smp,#batches) (%u,%u) " "algorithmConfig(%u)\n", __FUNCTION__, __LINE__, @@ -1353,6 +1356,10 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont accelBatchesPerSec, gyroSamplesPerBatch, gyroBatchesPerSec, + accelSamplesPerBatchHigh, + accelBatchesPerSecHigh, + gyroSamplesPerBatchHigh, + gyroBatchesPerSecHigh, algorithmConfig ); @@ -1367,6 +1374,12 @@ enum loc_api_adapter_err LocApiV02Adapter :: setSensorPerfControlConfig(int cont sensor_perf_config_req.gyroSamplingSpec_valid = 1; sensor_perf_config_req.gyroSamplingSpec.batchesPerSecond = gyroBatchesPerSec; sensor_perf_config_req.gyroSamplingSpec.samplesPerBatch = gyroSamplesPerBatch; + sensor_perf_config_req.accelSamplingSpecHigh_valid = 1; + sensor_perf_config_req.accelSamplingSpecHigh.batchesPerSecond = accelBatchesPerSecHigh; + sensor_perf_config_req.accelSamplingSpecHigh.samplesPerBatch = accelSamplesPerBatchHigh; + sensor_perf_config_req.gyroSamplingSpecHigh_valid = 1; + sensor_perf_config_req.gyroSamplingSpecHigh.batchesPerSecond = gyroBatchesPerSecHigh; + sensor_perf_config_req.gyroSamplingSpecHigh.samplesPerBatch = gyroSamplesPerBatchHigh; sensor_perf_config_req.algorithmConfig_valid = 1; sensor_perf_config_req.algorithmConfig = algorithmConfig; diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.h b/loc_api/loc_api_v02/LocApiV02Adapter.h index 04f931ee..60c2a5ce 100644 --- a/loc_api/loc_api_v02/LocApiV02Adapter.h +++ b/loc_api/loc_api_v02/LocApiV02Adapter.h @@ -157,7 +157,9 @@ public: virtual enum loc_api_adapter_err setSensorPerfControlConfig(int controlMode, int accelSamplesPerBatch, int accelBatchesPerSec, - int gyroSamplesPerBatch, int gyroBatchesPerSec, int algorithmConfig); + int gyroSamplesPerBatch, int gyroBatchesPerSec, + int accelSamplesPerBatchHigh, int accelBatchesPerSecHigh, + int gyroSamplesPerBatchHigh, int gyroBatchesPerSecHigh, int algorithmConfig); virtual enum loc_api_adapter_err setExtPowerConfig(int isBatteryCharging); }; diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c index ebd1a376..e1bf6f55 100644 --- a/loc_api/loc_api_v02/location_service_v02.c +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -578,6 +578,25 @@ static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { QMI_IDL_FLAG_END_VALUE }; +static const uint8_t qmiLocMotionDataStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_mode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, probability_of_state), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, age), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, timeout), + + QMI_IDL_FLAG_END_VALUE +}; + /*Message Definitions*/ static const uint8_t qmiLocGenRespMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, @@ -1805,10 +1824,15 @@ static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), 0x13, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) }; static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { @@ -1848,10 +1872,15 @@ static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), 0x13, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) }; static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { @@ -1977,10 +2006,22 @@ static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), 19, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), 0x13, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), + 19, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), + 19, 0 }; static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { @@ -2022,10 +2063,22 @@ static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), 19, 0, - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), 0x13, QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), + 19, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), + 19, 0 }; static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { @@ -2440,6 +2493,43 @@ static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) }; +static const uint8_t qmiLocInjectMotionDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataReqMsgT_v02, motion_data), + 33, 0 +}; + +static const uint8_t qmiLocInjectMotionDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList), + QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) +}; + /* Type Table */ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, @@ -2474,7 +2564,8 @@ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, - {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02} + {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, + {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02} }; /* Message Table */ @@ -2602,7 +2693,11 @@ static const qmi_idl_message_table_entry loc_message_table_v02[] = { {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, - {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02} + {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02} }; /* Predefine the Type Table Object */ @@ -2662,13 +2757,13 @@ static const qmi_idl_service_message_table_entry loc_service_command_messages_v0 {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 25}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 32}, {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 28}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 42}, {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, @@ -2678,7 +2773,9 @@ static const qmi_idl_service_message_table_entry loc_service_command_messages_v0 {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7} + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, + {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7} }; static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { @@ -2736,7 +2833,9 @@ static const qmi_idl_service_message_table_entry loc_service_response_messages_v {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7} + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7} }; static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { @@ -2789,13 +2888,13 @@ static const qmi_idl_service_message_table_entry loc_service_indication_messages {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 32}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 39}, {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 35}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 49}, {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, @@ -2807,7 +2906,9 @@ static const qmi_idl_service_message_table_entry loc_service_indication_messages {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391} + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, + {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82} }; /*Service Object*/ @@ -2821,7 +2922,7 @@ struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, &loc_qmi_idl_type_table_object_v02, - 0x0B, + 0x0D, NULL }; diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h index c3d67702..d2da6915 100644 --- a/loc_api/loc_api_v02/location_service_v02.h +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -82,11 +82,11 @@ extern "C" { /** Major Version Number of the IDL used to generate this file */ #define LOC_V02_IDL_MAJOR_VERS 0x02 /** Revision Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MINOR_VERS 0x0B +#define LOC_V02_IDL_MINOR_VERS 0x0D /** Major Version Number of the qmi_idl_compiler used to generate this file */ #define LOC_V02_IDL_TOOL_VERS 0x05 /** Maximum Defined Message ID */ -#define LOC_V02_MAX_MESSAGE_ID 0x0067; +#define LOC_V02_MAX_MESSAGE_ID 0x0069; /** @} */ @@ -180,6 +180,10 @@ extern "C" { /** Maximum length of the SUPL certificate. */ #define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 + +/** Maximum length of the Network Initiated Geofence ID + list */ +#define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 /** @} */ @@ -476,6 +480,8 @@ typedef uint32_t qmiLocPosTechMaskT_v02; #define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ #define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ #define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION_V02 ((qmiLocPosTechMaskT_v02)0x00000020) /**< Coarse position injected into the location engine was used to + generate the fix. */ /** @addtogroup loc_qmi_enums @{ */ @@ -836,7 +842,8 @@ typedef struct { - 0x00000002 -- CELLID \n - 0x00000004 -- WIFI \n - 0x00000008 -- SENSORS \n - - 0x00000010 -- REFERENCE_LOCATION */ + - 0x00000010 -- REFERENCE_LOCATION \n + - 0x00000020 -- INJECTED_COARSE_POSITION */ /* Optional */ /* Dilution of Precision */ @@ -2671,7 +2678,7 @@ typedef struct { Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING - \item 0x00000001 -- GEOFENCE_BREACH_TYPE_LEAVING + \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING \vspace{-0.18in} \end{itemize1} */ @@ -4766,10 +4773,12 @@ typedef enum { eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ - eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. - Use cell ID. For 1x, this mode corresponds to - AFLT. */ - eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, + eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ + eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for GSM/UMTS network + Use WWAN measurements to calculate position. If this mode is + set then for 1x network AFLT will used and for LTE network + OTDOA will used. */ + eQMI_LOC_OPER_MODE_WWAN_V02 = 6, QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocOperationModeEnumT_v02; /** @@ -4796,6 +4805,7 @@ typedef struct { \item 0x00000003 -- OPER_MODE_MSA \item 0x00000004 -- OPER_MODE_STANDALONE \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN \vspace{-0.18in} \end{itemize1} */ }qmiLocSetOperationModeReqMsgT_v02; /* Message */ @@ -4874,6 +4884,7 @@ typedef struct { \item 0x00000003 -- OPER_MODE_MSA \item 0x00000004 -- OPER_MODE_STANDALONE \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN \vspace{-0.18in} \end{itemize1} */ }qmiLocGetOperationModeIndMsgT_v02; /* Message */ @@ -5550,6 +5561,9 @@ typedef enum { typedef uint32_t qmiLocLppConfigMaskT_v02; #define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ #define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ +typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in Control Plane */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in User Plane */ /** @addtogroup loc_qmi_messages @{ */ @@ -5603,6 +5617,20 @@ typedef struct { \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Configures the protocols that the location service can indicate it supports, + for Assisted Glonass. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP + \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP + \vspace{-0.18in} \end{itemize1} + */ }qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ /** @} @@ -5613,6 +5641,7 @@ typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; #define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ #define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ #define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000010ull) /**< Mask for the LPP configuration parameter. */ /** @addtogroup loc_qmi_messages @{ */ @@ -5651,6 +5680,7 @@ typedef struct { \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL \vspace{-0.18in} \end{itemize1} */ }qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ @@ -5676,6 +5706,7 @@ typedef struct { \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL \vspace{-0.18in} \end{itemize1} */ }qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ @@ -5753,6 +5784,19 @@ typedef struct { \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Assisted GLONASS Protocol Mask. + + Valid bitmasks: + \begin{itemize1} + \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP + \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP + \vspace{-0.18in} \end{itemize1} + */ }qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -6181,10 +6225,12 @@ typedef struct { uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data. The sensor data rate is specified in terms of the nominal - number of samples per batch and the number of batches per second. + acceleration data to be used by the low data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. + The default specification is 10Hz sampling rate and 2Hz batching rate. */ /* Optional */ @@ -6192,10 +6238,12 @@ typedef struct { uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data. The sensor data rate is specified in terms of the nominal number of - samples per batch and the number of batches per second. + gyro data to be used by the high data rate filter. The sensor data + rate is specified in terms of the nominal number of samples per batch + and the number of batches per second. However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. + The default specification is 10Hz sampling rate and 2Hz batching rate. */ /* Optional */ @@ -6209,6 +6257,32 @@ typedef struct { \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + The default specification is 100Hz sampling rate and 4Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + The default specification is 100Hz sampling rate and 4Hz batching rate. + */ }qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ /** @} @@ -6219,6 +6293,8 @@ typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ #define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000010) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000020) /**< Failed to set the gyroscope sampling specification. */ /** @addtogroup loc_qmi_messages @{ */ @@ -6256,6 +6332,8 @@ typedef struct { \item 0x00000002 -- ACCEL_SAMPLING_SPEC \item 0x00000004 -- GYRO_SAMPLING_SPEC \item 0x00000008 -- ALGORITHM_CONFIG + \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH + \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH \vspace{-0.18in} \end{itemize1} */ }qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ @@ -6317,10 +6395,12 @@ typedef struct { uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data. The sensor data rate is specified in terms of the nominal number of - samples per batch and the number of batches per second. + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. + The default specification is 10Hz sampling rate and 2Hz batching rate. */ /* Optional */ @@ -6328,10 +6408,12 @@ typedef struct { uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data. The sensor data rate is specified in terms of the nominal number of - samples per batch and the number of batches per second. + gyro data to be used by the high data rate filter. The sensor data + rate is specified in terms of the nominal number of samples per batch + and the number of batches per second. However, the final control of the actual requested rate resides with the Sensors Manager Module/GNSS location engine. + The default specification is 10Hz sampling rate and 2Hz batching rate. */ /* Optional */ @@ -6345,6 +6427,32 @@ typedef struct { \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + The default specification is 100Hz sampling rate and 4Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. + The default specification is 100Hz sampling rate and 4Hz batching rate. + */ }qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ /** @} @@ -7409,6 +7517,7 @@ typedef struct { \item 0x00000004 -- WIFI \item 0x00000008 -- SENSORS \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION \vspace{-0.18in} \end{itemize1} */ /* Optional */ @@ -7465,6 +7574,193 @@ typedef struct { @} */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known */ + eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is stationary + Device state is in motion */ + eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, + QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known */ + eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in pedestrian mode, nothing else is known about the movement */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian walking mode */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian running mode + Device movement is in vehicular mode, nothing else is known about the movement */ + eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, + QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocMotionStateEnumT_v02 motion_state; + /**< Current motion state of the user. States of user motion: \n + Options are: */ + + qmiLocMotionModeEnumT_v02 motion_mode; + /**< Modes of user motion.\n + Options are: */ + + float probability_of_state; + /**< Probability that the device is actually undergoing the motion state + specified by the combination of the values of motion_state, motion_mode, + and motion_sub_mode. \vspace{0.06in} + + This value is a floating point number in the range of 0 to 100, in + units of percent probability. Any value greater than 99.9999 is + applied as 99.9999. \vspace{0.06in} + + It is recommended that if a particular combination of motion_state and + motion_mode cannot be determined with more than 50 percent confidence, + that a more general statement of user motion be made. + For example, if the mode of In-Motion + Pedestrian-Running can only be + determined with 50 percent probability, and the simpler statement of In-Motion + can be determined with 90 percent probability, it is recommended that this field + be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} + + If the motion_state is not known, the value in this field is not used. + */ + + uint16_t age; + /**< Age of the motion data in milliseconds at the time of injection. + */ + + uint16_t timeout; + /**< If the age of the motion data input exceeds the timeout value, it + will no longer be used. The timeout value is in units of milliseconds. + Values in the range of 0 to 10000 are accepted. If 65535 is provided, + the motion data input is applied indefinitely until the next input is + received. \vspace{0.06in} + + If the determination of motion data is an instantaneous observation, + and no notice is guaranteed to be given via QMI on a change in the + state of motion data, it is recommended that this field be set to 0. \vspace{0.06in} + + If the determination of motion data is continuously monitored + external to QMI, and an update is always applied to QMI upon any + change in state, a value of 65535 is used for this field. + Note that in this case, if a certain mode is set and is not later + unset (e.g., by sending in the request message with a user motion + state of Unknown), the value is applied indefinitely. + */ +}qmiLocMotionDataStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Motion Data */ + qmiLocMotionDataStructT_v02 motion_data; +}qmiLocInjectMotionDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Inject motion data request status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Motion Data request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + */ +}qmiLocInjectMotionDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to retrieve the list of network + initiated geofence ID's. */ +typedef struct { + + /* Mandatory */ + /* Transaction Id */ + uint32_t transactionId; + /**< Identifies the transaction, the same transaction Id + will be returned in the Get NI Geofence ID List indication. + - Type -- Unsigned Integer. */ +}qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to retrieve the list of network + initiated geofence ID's. */ +typedef struct { + + /* Mandatory */ + /* Get NI Geofence ID List status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NI Geofence ID List request. + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction Id */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction Id which was specified in the Get NI + Geofence ID List request. + - Type -- Unsigned Integer. */ + + /* Optional */ + /* NI Geofence ID List */ + uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ + uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ + uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; + /**< List containing the NI Geofence Id's. + - Type: Array of unsigned 32 bit integers. \n + - Maximum NI Geofence ID List length : 16 */ +}qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ +/** + @} + */ + /*Service Message Definition*/ /** @addtogroup loc_qmi_msg_ids @{ @@ -7647,6 +7943,12 @@ typedef struct { #define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 #define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 #define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 +#define QMI_LOC_INJECT_MOTION_DATA_REQ_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_RESP_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_IND_V02 0x0068 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 /** @} */ From 72e3b852ded1c9221e9b98001172eb6deb44164f Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Wed, 15 Aug 2012 15:06:22 -0700 Subject: [PATCH 05/33] loc_api_v02: Initialize the QMI notifier before looking for service Looking for a service results in opening and closing the IPC Router socket. This in turn involves IPC Router to trigger loading & unloading the modem. Sometimes this causes the race condition between modem unload and modem coming out of reset. CRs-fixed: 384906 Change-Id: I61767d3eeab5867f64f94c5d4cdee4272de2dc44 --- loc_api/loc_api_v02/loc_api_v02_client.c | 54 ++++++++++-------------- 1 file changed, 22 insertions(+), 32 deletions(-) diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c index 26ecfd26..12782b93 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.c +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -1543,6 +1543,8 @@ static locClientStatusEnumType locClientQmiCtrlPointInit( uint32_t num_services = 0, num_entries = 0; qmi_client_error_type rc = QMI_NO_ERR; bool nosignal = false; + qmi_client_os_params os_params; + int timeout = 0; // Get the service object for the qmiLoc Service qmi_idl_service_object_type locClientServiceObject = @@ -1557,46 +1559,34 @@ static locClientStatusEnumType locClientQmiCtrlPointInit( break; } - // get the service addressing information - rc = qmi_client_get_service_list( locClientServiceObject, NULL, NULL, - &num_services); - LOC_LOGV("%s:%d]: qmi_client_get_service_list() first try rc %d, " - "num_services %d", __func__, __LINE__, rc, num_services); + // register for service notification + rc = qmi_client_notifier_init(locClientServiceObject, &os_params, ¬ifier); + notifierInitFlag = (NULL != notifier); if (rc != QMI_NO_ERR) { - // bummer, service list is not up. - // We need to try again after a timed wait - qmi_client_os_params os_params; - int timeout = 0; - - // register for service notification - rc = qmi_client_notifier_init(locClientServiceObject, &os_params, ¬ifier); - notifierInitFlag = (NULL != notifier); + LOC_LOGE("%s:%d]: qmi_client_notifier_init failed %d\n", + __func__, __LINE__, rc); + status = eLOC_CLIENT_FAILURE_INTERNAL; + break; + } + do { + QMI_CCI_OS_SIGNAL_CLEAR(&os_params); + // get the service addressing information + rc = qmi_client_get_service_list(locClientServiceObject, NULL, NULL, + &num_services); + /* If service is not up wait on a signal until the service is up + * or a timeout occurs. */ if (rc != QMI_NO_ERR) { - LOC_LOGE("%s:%d]: qmi_client_notifier_init failed %d\n", - __func__, __LINE__, rc); - status = eLOC_CLIENT_FAILURE_INTERNAL; - break; - } - - do { - QMI_CCI_OS_SIGNAL_CLEAR(&os_params); - /* If service is not up wait on a signal until the service is up - * or a timeout occurs. */ QMI_CCI_OS_SIGNAL_WAIT(&os_params, LOC_CLIENT_SERVICE_TIMEOUT_UNIT); nosignal = QMI_CCI_OS_SIGNAL_TIMED_OUT(&os_params); + } - // get the service addressing information - rc = qmi_client_get_service_list(locClientServiceObject, NULL, NULL, - &num_services); + timeout += LOC_CLIENT_SERVICE_TIMEOUT_UNIT; - timeout += LOC_CLIENT_SERVICE_TIMEOUT_UNIT; - - LOC_LOGV("%s:%d]: qmi_client_get_service_list() rc %d, nosignal %d, " - "total timeout %d", __func__, __LINE__, rc, nosignal, timeout); - } while (timeout < LOC_CLIENT_SERVICE_TIMEOUT_TOTAL && nosignal && rc != QMI_NO_ERR); - } + LOC_LOGV("%s:%d]: qmi_client_get_service_list() rc %d, nosignal %d, " + "total timeout %d", __func__, __LINE__, rc, nosignal, timeout); + } while (timeout < LOC_CLIENT_SERVICE_TIMEOUT_TOTAL && nosignal && rc != QMI_NO_ERR); if (0 == num_services || rc != QMI_NO_ERR) { if (!nosignal) { From b1595d72cb42fead7ece9c6f74244f1485d5a827 Mon Sep 17 00:00:00 2001 From: Nagender Telkar Date: Mon, 13 Aug 2012 20:00:28 -0700 Subject: [PATCH 06/33] build: Include path to TARGET_OUT_HEADERS in LOCAL_C_INCLUDES Change-Id: I5cd48e37ef747a021329f8d166320ee88ef2fd3e --- loc_api/loc_api_v02/Android.mk | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/loc_api/loc_api_v02/Android.mk b/loc_api/loc_api_v02/Android.mk index b6c7a66e..63b28663 100644 --- a/loc_api/loc_api_v02/Android.mk +++ b/loc_api/loc_api_v02/Android.mk @@ -30,10 +30,9 @@ LOCAL_CFLAGS += \ ## Includes LOCAL_C_INCLUDES := \ - $(TOP)/vendor/qcom/proprietary/qmi-framework/inc \ - $(TOP)/vendor/qcom/proprietary/qmi-framework/qcci/inc \ - $(TOP)/vendor/qcom/proprietary/qmi-framework/common/inc \ $(TARGET_OUT_HEADERS)/libloc_eng \ + $(TARGET_OUT_HEADERS)/qmi-framework/inc \ + $(TARGET_OUT_HEADERS)/qmi/inc \ $(TARGET_OUT_HEADERS)/gps.utils LOCAL_PRELINK_MODULE := false From 7ce61c42e25569f0250dd44832784557fff5db56 Mon Sep 17 00:00:00 2001 From: Neethu Joseph Date: Mon, 25 Jun 2012 10:36:48 -0700 Subject: [PATCH 07/33] loc_api: Send position technology mask to ulp Sends the technology mask of the position report to ulp and blocks the injected wifi fix from getting reported as final Change-Id: I3a9b390d3d6d9be1a913731d6e8d8ee1d3ced686 --- loc_api/libloc_api_50001/LocApiAdapter.cpp | 6 ++++-- loc_api/libloc_api_50001/LocApiAdapter.h | 3 ++- loc_api/libloc_api_50001/loc.h | 9 +++++++++ loc_api/libloc_api_50001/loc_eng.cpp | 10 +++++++++- loc_api/libloc_api_50001/loc_eng_msg.h | 17 ++++++++++++++--- loc_api/libloc_api_50001/loc_eng_msg_id.h | 6 ++++++ loc_api/loc_api_v02/LocApiV02Adapter.cpp | 8 +++++++- 7 files changed, 51 insertions(+), 8 deletions(-) mode change 100644 => 100755 loc_api/libloc_api_50001/LocApiAdapter.cpp mode change 100644 => 100755 loc_api/libloc_api_50001/LocApiAdapter.h mode change 100644 => 100755 loc_api/libloc_api_50001/loc.h mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng.cpp mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_msg.h mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_msg_id.h mode change 100644 => 100755 loc_api/loc_api_v02/LocApiV02Adapter.cpp diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp old mode 100644 new mode 100755 index b7ebc6f5..1bf7a8e0 --- a/loc_api/libloc_api_50001/LocApiAdapter.cpp +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -114,12 +114,14 @@ int LocApiAdapter::decodeAddress(char *addr_string, int string_size, void LocApiAdapter::reportPosition(GpsLocation &location, void* locationExt, - enum loc_sess_status status) + enum loc_sess_status status, + LocPosTechMask loc_technology_mask ) { loc_eng_msg_report_position *msg(new loc_eng_msg_report_position(locEngHandle.owner, location, locationExt, - status)); + status, + loc_technology_mask)); if (locEngHandle.sendUlpMsg) { locEngHandle.sendUlpMsg(locEngHandle.owner, msg); } else { diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h old mode 100644 new mode 100755 index 57d0eae0..59caaf62 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -122,7 +122,8 @@ public: void reportPosition(GpsLocation &location, void* locationExt, - enum loc_sess_status status); + enum loc_sess_status status, + LocPosTechMask loc_technology_mask = LOC_POS_TECH_MASK_DEFAULT); void reportSv(GpsSvStatus &svStatus, void* svExt); void reportStatus(GpsStatusValue status); void reportNmea(const char* nmea, int length); diff --git a/loc_api/libloc_api_50001/loc.h b/loc_api/libloc_api_50001/loc.h old mode 100644 new mode 100755 index 233b34c3..17f6ab70 --- a/loc_api/libloc_api_50001/loc.h +++ b/loc_api/libloc_api_50001/loc.h @@ -80,6 +80,15 @@ enum loc_sess_status { LOC_SESS_FAILURE }; +typedef uint32_t LocPosTechMask; +#define LOC_POS_TECH_MASK_DEFAULT ((LocPosTechMask)0x00000000) +#define LOC_POS_TECH_MASK_SATELLITE ((LocPosTechMask)0x00000001) +#define LOC_POS_TECH_MASK_CELLID ((LocPosTechMask)0x00000002) +#define LOC_POS_TECH_MASK_WIFI ((LocPosTechMask)0x00000004) +#define LOC_POS_TECH_MASK_SENSORS ((LocPosTechMask)0x00000008) +#define LOC_POS_TECH_MASK_REFERENCE_LOCATION ((LocPosTechMask)0x00000010) +#define LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION ((LocPosTechMask)0x00000020) + void loc_ulp_msg_sender(void* loc_eng_data_p, void* msg); #ifdef __cplusplus diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp old mode 100644 new mode 100755 index 821d9624..562a30c2 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -1484,13 +1484,21 @@ static void loc_eng_deferred_action_thread(void* arg) } // what's in the else if is... (line by line) // 1. this is a good fix; or + // 1.1 there is source info; or + // 1.1.1 this is from hybrid provider; + // 1.2 it is a Satellite fix; or + // 1.2.1 it is a sensor fix // 2. (must be intermediate fix... implicit) // 2.1 we accepte intermediate; and // 2.2 it is NOT the case that // 2.2.1 there is inaccuracy; and // 2.2.2 we care about inaccuracy; and // 2.2.3 the inaccuracy exceeds our tolerance - else if (LOC_SESS_SUCCESS == rpMsg->status || + else if ((LOC_SESS_SUCCESS == rpMsg->status && + ((LOCATION_HAS_SOURCE_INFO == rpMsg->location.flags && + ULP_LOCATION_IS_FROM_HYBRID == rpMsg->location.position_source) || + ((LOC_POS_TECH_MASK_SATELLITE & rpMsg->technology_mask) || + (LOC_POS_TECH_MASK_SENSORS & rpMsg->technology_mask)))) || (LOC_SESS_INTERMEDIATE == loc_eng_data_p->intermediateFix && !((rpMsg->location.flags & GPS_LOCATION_HAS_ACCURACY) && (gps_conf.ACCURACY_THRES != 0) && diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h old mode 100644 new mode 100755 index adc138fe..d846a1f3 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -319,15 +319,26 @@ struct loc_eng_msg_report_position : public loc_eng_msg { const GpsLocation location; const void* locationExt; const enum loc_sess_status status; + const LocPosTechMask technology_mask; inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, void* locExt, enum loc_sess_status st) : loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), - location(loc), locationExt(locExt), status(st) + location(loc), locationExt(locExt), status(st), technology_mask(LOC_POS_TECH_MASK_DEFAULT) { - LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d", + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d\n Technology mask: %u", location.flags, location.position_source, location.latitude, location.longitude, location.altitude, location.speed, location.bearing, location.accuracy, - location.timestamp, location.rawDataSize, location.rawData,status); + location.timestamp, location.rawDataSize, location.rawData,status,technology_mask); + } + inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, void* locExt, + enum loc_sess_status st, LocPosTechMask technology) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), + location(loc), locationExt(locExt), status(st), technology_mask(technology) + { + LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d\n Technology mask: %u", + location.flags, location.position_source, location.latitude, location.longitude, + location.altitude, location.speed, location.bearing, location.accuracy, + location.timestamp, location.rawDataSize, location.rawData,status,technology_mask); } }; diff --git a/loc_api/libloc_api_50001/loc_eng_msg_id.h b/loc_api/libloc_api_50001/loc_eng_msg_id.h old mode 100644 new mode 100755 index 0c3f5755..0761b89d --- a/loc_api/libloc_api_50001/loc_eng_msg_id.h +++ b/loc_api/libloc_api_50001/loc_eng_msg_id.h @@ -115,6 +115,12 @@ enum loc_eng_msg_ids_t { // Message is sent by QUIPC module in order to request some info from ULP ULP_MSG_REQUEST_COARSE_POSITION, + // Message is sent to ULP module to re-evaluate its subsystems + ULP_MSG_MONITOR, + + // Last ULP MSG + ULP_MSG_LAST = 0x700, + /* Message is sent by HAL to LOC API to configure LTE Positioning Profile in modem */ LOC_ENG_MSG_LPP_CONFIG, diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp old mode 100644 new mode 100755 index f352af19..68057bcd --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1550,6 +1550,7 @@ void LocApiV02Adapter :: reportPosition ( const qmiLocEventPositionReportIndMsgT_v02 *location_report_ptr) { GpsLocation location; + LocPosTechMask tech_Mask = LOC_POS_TECH_MASK_DEFAULT; LOC_LOGD("Reporting postion from V2 Adapter\n"); memset(&location, 0, sizeof (GpsLocation)); location.size = sizeof(location); @@ -1607,6 +1608,10 @@ void LocApiV02Adapter :: reportPosition ( location.flags |= GPS_LOCATION_HAS_ACCURACY; location.accuracy = location_report_ptr->horUncCircular; } + + // Technology Mask + tech_Mask |= location_report_ptr->technologyMask; + //Mark the location source as from GNSS location.flags |= LOCATION_HAS_SOURCE_INFO; location.position_source = ULP_LOCATION_IS_FROM_GNSS; @@ -1614,7 +1619,8 @@ void LocApiV02Adapter :: reportPosition ( locEngHandle.extPosInfo((void*)location_report_ptr), (location_report_ptr->sessionStatus == eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 ? - LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS)); + LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS), + tech_Mask); } } else From 332389d67fe3aadbf53e68d50f508eff1c458ef3 Mon Sep 17 00:00:00 2001 From: Neethu Joseph Date: Wed, 29 Aug 2012 12:16:57 -0700 Subject: [PATCH 08/33] loc_api: Fix QUIPS position being dropped at GPS HAL Change-Id: I10606597f39b29fd4b3a8acfacd9a8c17aa9713f --- loc_api/libloc_api_50001/loc_eng.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 562a30c2..f7161da8 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -1495,7 +1495,7 @@ static void loc_eng_deferred_action_thread(void* arg) // 2.2.2 we care about inaccuracy; and // 2.2.3 the inaccuracy exceeds our tolerance else if ((LOC_SESS_SUCCESS == rpMsg->status && - ((LOCATION_HAS_SOURCE_INFO == rpMsg->location.flags && + (((LOCATION_HAS_SOURCE_INFO & rpMsg->location.flags) && ULP_LOCATION_IS_FROM_HYBRID == rpMsg->location.position_source) || ((LOC_POS_TECH_MASK_SATELLITE & rpMsg->technology_mask) || (LOC_POS_TECH_MASK_SENSORS & rpMsg->technology_mask)))) || From b4f4652ce2fd32745382249a323b9f09db95bf7f Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Fri, 31 Aug 2012 15:48:18 -0700 Subject: [PATCH 09/33] gps: add support for msm8974 Change-Id: I4a4520bcfb118fea8dfc244efff4837003466d34 --- loc_api/Android.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/loc_api/Android.mk b/loc_api/Android.mk index 7e1e35f8..20ff0727 100644 --- a/loc_api/Android.mk +++ b/loc_api/Android.mk @@ -15,6 +15,7 @@ endif #TARGET_NO_RPC #add QMI libraries for QMI targets QMI_BOARD_PLATFORM_LIST := msm8960 +QMI_BOARD_PLATFORM_LIST += msm8974 ifeq ($(call is-board-platform-in-list,$(QMI_BOARD_PLATFORM_LIST)),true) GPS_DIR_LIST += $(LOCAL_PATH)/loc_api_v02/ From d3b220c611eef4c56f7a818338556f9c71846ace Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Fri, 7 Sep 2012 14:59:53 -0700 Subject: [PATCH 10/33] gps: fix SSR issue If service list check fails initially while the modem is not up yet, the rc is not updated after client gets signaled that the modem is now up. Change-Id: I5fe05ddad7764874eda45521e9394bfbee0eb85f CRs-fixed: 385158 --- loc_api/loc_api_v02/loc_api_v02_client.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c index 12782b93..7294d33e 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.c +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -1580,6 +1580,9 @@ static locClientStatusEnumType locClientQmiCtrlPointInit( if (rc != QMI_NO_ERR) { QMI_CCI_OS_SIGNAL_WAIT(&os_params, LOC_CLIENT_SERVICE_TIMEOUT_UNIT); nosignal = QMI_CCI_OS_SIGNAL_TIMED_OUT(&os_params); + if (!nosignal) + rc = qmi_client_get_service_list(locClientServiceObject, NULL, NULL, + &num_services); } timeout += LOC_CLIENT_SERVICE_TIMEOUT_UNIT; From 02d13cc646ea79aa97af45b4bff0565906ce27af Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Wed, 27 Jun 2012 16:28:45 -0700 Subject: [PATCH 11/33] gps: control session state evt from HAL, not modem Suppress the registering for QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 event from modem, that is normally responsible for generating GPS_STATUS_SESSION_BEGIN and GPS_STATUS_SESSION_END, and instead initiate these events from hal from when we get GPS_STATUS_ENGINE_ON and GPS_STATUS_ENGINE_OFF Change-Id: I9d220bef7ee4f989a3982d888ed46279861f612d CRs-fixed: 370904 --- .../src/LocApiRpcAdapter.cpp | 17 ++++++----------- loc_api/loc_api_v02/LocApiV02Adapter.cpp | 17 ++++++++++------- 2 files changed, 16 insertions(+), 18 deletions(-) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp index 843a8ae9..84d2bb88 100644 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -797,29 +797,24 @@ void LocApiRpcAdapter::reportSv(const rpc_loc_gnss_info_s_type *gnss_report_ptr) void LocApiRpcAdapter::reportStatus(const rpc_loc_status_event_s_type *status_report_ptr) { - GpsStatusValue status = GPS_STATUS_NONE; if (status_report_ptr->event == RPC_LOC_STATUS_EVENT_ENGINE_STATE) { if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.engine_state == RPC_LOC_ENGINE_STATE_ON) { - status = GPS_STATUS_ENGINE_ON; + LocApiAdapter::reportStatus(GPS_STATUS_ENGINE_ON); + LocApiAdapter::reportStatus(GPS_STATUS_SESSION_BEGIN); } else if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.engine_state == RPC_LOC_ENGINE_STATE_OFF) { - status = GPS_STATUS_ENGINE_OFF; + LocApiAdapter::reportStatus(GPS_STATUS_SESSION_END); + LocApiAdapter::reportStatus(GPS_STATUS_ENGINE_OFF); } - } else if (status_report_ptr->event == RPC_LOC_STATUS_EVENT_FIX_SESSION_STATE) { - if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.fix_session_state == RPC_LOC_FIX_SESSION_STATE_BEGIN) + else { - status = GPS_STATUS_SESSION_BEGIN; - } - else if (status_report_ptr->payload.rpc_loc_status_event_payload_u_type_u.fix_session_state == RPC_LOC_FIX_SESSION_STATE_END) - { - status = GPS_STATUS_SESSION_END; + LocApiAdapter::reportStatus(GPS_STATUS_NONE); } } - LocApiAdapter::reportStatus(status); } void LocApiRpcAdapter::reportNmea(const rpc_loc_nmea_report_s_type *nmea_report_ptr) diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 68057bcd..196e6878 100755 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1495,8 +1495,7 @@ locClientEventMaskType LocApiV02Adapter :: convertMask( if(mask & LOC_API_ADAPTER_BIT_STATUS_REPORT) { - eventMask |= (QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 | - QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02); + eventMask |= (QMI_LOC_EVENT_MASK_ENGINE_STATE_V02); } if(mask & LOC_API_ADAPTER_BIT_LOCATION_SERVER_REQUEST) @@ -1749,21 +1748,25 @@ void LocApiV02Adapter :: reportSv ( void LocApiV02Adapter :: reportEngineState ( const qmiLocEventEngineStateIndMsgT_v02 *engine_state_ptr) { - GpsStatusValue status; LOC_LOGV("%s:%d]: state = %d\n", __func__, __LINE__, engine_state_ptr->engineState); - status = GPS_STATUS_NONE; if (engine_state_ptr->engineState == eQMI_LOC_ENGINE_STATE_ON_V02) { - status = GPS_STATUS_ENGINE_ON; + LocApiAdapter::reportStatus(GPS_STATUS_ENGINE_ON); + LocApiAdapter::reportStatus(GPS_STATUS_SESSION_BEGIN); } else if (engine_state_ptr->engineState == eQMI_LOC_ENGINE_STATE_OFF_V02) { - status = GPS_STATUS_ENGINE_OFF; + LocApiAdapter::reportStatus(GPS_STATUS_SESSION_END); + LocApiAdapter::reportStatus(GPS_STATUS_ENGINE_OFF); } - LocApiAdapter::reportStatus(status); + else + { + LocApiAdapter::reportStatus(GPS_STATUS_NONE); + } + } /* convert fix session state report to loc eng format and send the converted From 06ce79b8fa87383a5740edf04691e3e9bb275f7f Mon Sep 17 00:00:00 2001 From: Vineela Tummalapalli Date: Tue, 11 Sep 2012 12:51:22 +0530 Subject: [PATCH 12/33] GPS: fix the issue that GNSS position report are dropped in PPC based target Change-Id: I94fb2bd12ac8751cbd2366a4cc5fde4b52d17f64 CRs-Fixed: 395398 --- .../libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp index 843a8ae9..bd384717 100644 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -624,6 +624,8 @@ LocApiRpcAdapter::deleteAidingData(GpsAidingData bits) void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *location_report_ptr) { + LocPosTechMask tech_Mask = LOC_POS_TECH_MASK_DEFAULT; + GpsLocation location = {0}; location.size = sizeof(location); @@ -678,6 +680,10 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca location.flags |= GPS_LOCATION_HAS_ACCURACY; location.accuracy = location_report_ptr->hor_unc_circular; } + + // Technology Mask + + tech_Mask |= location_report_ptr->technology_mask; //Mark the location source as from GNSS location.flags |= LOCATION_HAS_SOURCE_INFO; location.position_source = ULP_LOCATION_IS_FROM_GNSS; @@ -685,7 +691,8 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca LocApiAdapter::reportPosition(location, locEngHandle.extPosInfo((void*)location_report_ptr), (location_report_ptr->session_status == RPC_LOC_SESS_STATUS_IN_PROGESS ? - LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS)); + LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS), + tech_Mask); } } else From 4d0a38184823255fedec03d8844a097eaed21afe Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Fri, 14 Sep 2012 13:24:40 -0700 Subject: [PATCH 13/33] gps: launch GSS on bootup even if GPS is disabled Move the launching of GSS from loc_init to get_gps_interface, since loc_init is only called by AFW when GPS is enabled. CRs-fixed: 399637 Change-Id: I7cf8500f6a345f3bef71f717c595ea734da2bff2 --- loc_api/libloc_api_50001/loc.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp index c0378fdf..baba3d7c 100644 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -270,6 +270,17 @@ extern "C" const GpsInterface* get_gps_interface() if(gps_conf.CAPABILITIES & ULP_CAPABILITY) { loc_eng_ulp_inf = loc_eng_get_ulp_inf(); } + + if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) + { + gps_conf.CAPABILITIES &= ~(GPS_CAPABILITY_MSA | GPS_CAPABILITY_MSB); + gss_fd = open("/dev/gss", O_RDONLY); + if (gss_fd < 0) { + LOC_LOGE("GSS open failed: %s\n", strerror(errno)); + } + LOC_LOGD("GSS open success! CAPABILITIES %0x\n", gps_conf.CAPABILITIES); + } + return &sLocEngInterface; } @@ -327,17 +338,6 @@ static int loc_init(GpsCallbacks* callbacks) gps_loc_cb = callbacks->location_cb; gps_sv_cb = callbacks->sv_status_cb; - if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) - { - gps_conf.CAPABILITIES &= ~(GPS_CAPABILITY_MSA | GPS_CAPABILITY_MSB); - gss_fd = open("/dev/gss", O_RDONLY); - if (gss_fd < 0) { - LOC_LOGE("GSS open failed: %s\n", strerror(errno)); - return NULL; - } - LOC_LOGD("GSS open success! CAPABILITIES %0x\n", gps_conf.CAPABILITIES); - } - int retVal = -1; if (loc_eng_ulp_inf == NULL) retVal = loc_eng_init(loc_afw_data, &clientCallbacks, event, From a3409617b658f1e732b154802d0a88dcee83912e Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Tue, 7 Aug 2012 10:29:30 -0700 Subject: [PATCH 14/33] gps: AP NMEA generation Generate NMEA sentences on the AP Change-Id: Ifc9e9263868ab4dec450bef35c53c441c881a072 --- .../src/LocApiRpcAdapter.cpp | 32 +- loc_api/libloc_api_50001/Android.mk | 3 +- loc_api/libloc_api_50001/LocApiAdapter.cpp | 8 +- loc_api/libloc_api_50001/LocApiAdapter.h | 7 +- loc_api/libloc_api_50001/loc_eng.cpp | 26 +- loc_api/libloc_api_50001/loc_eng.h | 15 +- loc_api/libloc_api_50001/loc_eng_msg.h | 45 +- loc_api/libloc_api_50001/loc_eng_nmea.cpp | 703 ++++++++++++++++++ loc_api/libloc_api_50001/loc_eng_nmea.h | 42 ++ loc_api/loc_api_v02/LocApiV02Adapter.cpp | 32 +- 10 files changed, 896 insertions(+), 17 deletions(-) create mode 100644 loc_api/libloc_api_50001/loc_eng_nmea.cpp create mode 100644 loc_api/libloc_api_50001/loc_eng_nmea.h diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp index 843a8ae9..5754a4c9 100644 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -625,8 +625,10 @@ LocApiRpcAdapter::deleteAidingData(GpsAidingData bits) void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *location_report_ptr) { GpsLocation location = {0}; + GpsLocationExtended locationExtended = {0}; location.size = sizeof(location); + locationExtended.size = sizeof(locationExtended); if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_SESSION_STATUS) { // Process the position from final and intermediate reports @@ -681,8 +683,22 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca //Mark the location source as from GNSS location.flags |= LOCATION_HAS_SOURCE_INFO; location.position_source = ULP_LOCATION_IS_FROM_GNSS; + + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_ALTITUDE_WRT_MEAN_SEA_LEVEL) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_MAG_DEV; + locationExtended.magneticDeviation = location_report_ptr->altitude_wrt_mean_sea_level; + } + + if (location_report_ptr->valid_mask & RPC_LOC_POS_VALID_MAGNETIC_VARIATION ) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_MAG_DEV; + locationExtended.magneticDeviation = location_report_ptr->magnetic_deviation; + } + LOC_LOGV("reportPosition: fire callback\n"); LocApiAdapter::reportPosition(location, + locationExtended, locEngHandle.extPosInfo((void*)location_report_ptr), (location_report_ptr->session_status == RPC_LOC_SESS_STATUS_IN_PROGESS ? LOC_SESS_INTERMEDIATE : LOC_SESS_SUCCESS)); @@ -691,6 +707,7 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca else { LocApiAdapter::reportPosition(location, + locationExtended, NULL, LOC_SESS_FAILURE); LOC_LOGV("loc_eng_report_position: ignore position report when session status = %d\n", location_report_ptr->session_status); @@ -705,6 +722,8 @@ void LocApiRpcAdapter::reportPosition(const rpc_loc_parsed_position_s_type *loca void LocApiRpcAdapter::reportSv(const rpc_loc_gnss_info_s_type *gnss_report_ptr) { GpsSvStatus SvStatus = {0}; + GpsLocationExtended locationExtended = {0}; + locationExtended.size = sizeof(locationExtended); int num_svs_max = 0; const rpc_loc_sv_info_s_type *sv_info_ptr; @@ -788,9 +807,20 @@ void LocApiRpcAdapter::reportSv(const rpc_loc_gnss_info_s_type *gnss_report_ptr) } } + if ((gnss_report_ptr->valid_mask & RPC_LOC_GNSS_INFO_VALID_POS_DOP) && + (gnss_report_ptr->valid_mask & RPC_LOC_GNSS_INFO_VALID_HOR_DOP) && + (gnss_report_ptr->valid_mask & RPC_LOC_GNSS_INFO_VALID_VERT_DOP)) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_DOP; + locationExtended.pdop = gnss_report_ptr->position_dop; + locationExtended.hdop = gnss_report_ptr->horizontal_dop; + locationExtended.vdop = gnss_report_ptr->vertical_dop; + } + if (SvStatus.num_svs >= 0) { LocApiAdapter::reportSv(SvStatus, + locationExtended, locEngHandle.extSvInfo((void*)gnss_report_ptr)); } } diff --git a/loc_api/libloc_api_50001/Android.mk b/loc_api/libloc_api_50001/Android.mk index 4e5973d6..0bf889ef 100644 --- a/loc_api/libloc_api_50001/Android.mk +++ b/loc_api/libloc_api_50001/Android.mk @@ -65,7 +65,8 @@ LOCAL_SRC_FILES += \ loc_eng_agps.cpp \ loc_eng_xtra.cpp \ loc_eng_ni.cpp \ - loc_eng_log.cpp + loc_eng_log.cpp \ + loc_eng_nmea.cpp ifeq ($(FEATURE_GNSS_BIT_API), true) LOCAL_CFLAGS += -DFEATURE_GNSS_BIT_API diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp index 1bf7a8e0..6bd79bbe 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.cpp +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -113,12 +113,14 @@ int LocApiAdapter::decodeAddress(char *addr_string, int string_size, } void LocApiAdapter::reportPosition(GpsLocation &location, + GpsLocationExtended &locationExtended, void* locationExt, enum loc_sess_status status, LocPosTechMask loc_technology_mask ) { loc_eng_msg_report_position *msg(new loc_eng_msg_report_position(locEngHandle.owner, location, + locationExtended, locationExt, status, loc_technology_mask)); @@ -129,9 +131,9 @@ void LocApiAdapter::reportPosition(GpsLocation &location, } } -void LocApiAdapter::reportSv(GpsSvStatus &svStatus, void* svExt) +void LocApiAdapter::reportSv(GpsSvStatus &svStatus, GpsLocationExtended &locationExtended, void* svExt) { - loc_eng_msg_report_sv *msg(new loc_eng_msg_report_sv(locEngHandle.owner, svStatus, svExt)); + loc_eng_msg_report_sv *msg(new loc_eng_msg_report_sv(locEngHandle.owner, svStatus, locationExtended, svExt)); //We want to send SV info to ULP to help it in determining GNSS signal strength //ULP will forward the SV reports to HAL without any modifications diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h index 59caaf62..80a675d8 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -121,10 +121,13 @@ public: const char *data, int data_size); void reportPosition(GpsLocation &location, + GpsLocationExtended &locationExtended, void* locationExt, enum loc_sess_status status, LocPosTechMask loc_technology_mask = LOC_POS_TECH_MASK_DEFAULT); - void reportSv(GpsSvStatus &svStatus, void* svExt); + void reportSv(GpsSvStatus &svStatus, + GpsLocationExtended &locationExtended, + void* svExt); void reportStatus(GpsStatusValue status); void reportNmea(const char* nmea, int length); void reportAgpsStatus(AGpsStatus &agpsStatus); diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index f7161da8..5075311e 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2009-2012 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2009-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -57,6 +57,7 @@ #include #include #include +#include #include #include @@ -83,6 +84,7 @@ static loc_param_s_type loc_parameter_table[] = {"INTERMEDIATE_POS", &gps_conf.INTERMEDIATE_POS, NULL, 'n'}, {"ACCURACY_THRES", &gps_conf.ACCURACY_THRES, NULL, 'n'}, {"ENABLE_WIPER", &gps_conf.ENABLE_WIPER, NULL, 'n'}, + {"NMEA_PROVIDER", &gps_conf.NMEA_PROVIDER, NULL, 'n'}, {"SUPL_VER", &gps_conf.SUPL_VER, NULL, 'n'}, {"CAPABILITIES", &gps_conf.CAPABILITIES, NULL, 'n'}, {"GYRO_BIAS_RANDOM_WALK", &gps_conf.GYRO_BIAS_RANDOM_WALK, &gps_conf.GYRO_BIAS_RANDOM_WALK_VALID, 'f'}, @@ -111,6 +113,7 @@ static void loc_default_parameters(void) gps_conf.INTERMEDIATE_POS = 0; gps_conf.ACCURACY_THRES = 0; gps_conf.ENABLE_WIPER = 0; + gps_conf.NMEA_PROVIDER = 0; gps_conf.SUPL_VER = 0x10000; gps_conf.CAPABILITIES = 0x7; @@ -303,6 +306,16 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, // loc_eng_data.fix_session_status -- GPS_STATUS_NONE; // loc_eng_data.mute_session_state -- LOC_MUTE_SESS_NONE; + if ((event & LOC_API_ADAPTER_BIT_NMEA_1HZ_REPORT) && (gps_conf.NMEA_PROVIDER == NMEA_PROVIDER_AP)) + { + event = event ^ LOC_API_ADAPTER_BIT_NMEA_1HZ_REPORT; // unregister for modem NMEA report + loc_eng_data.generateNmea = true; + } + else + { + loc_eng_data.generateNmea = false; + } + LocEng locEngHandle(&loc_eng_data, event, loc_eng_data.acquire_wakelock_cb, loc_eng_data.release_wakelock_cb, loc_eng_msg_sender, loc_external_msg_sender, callbacks->location_ext_parser, callbacks->sv_ext_parser); @@ -1523,6 +1536,11 @@ static void loc_eng_deferred_action_thread(void* arg) loc_eng_data_p->client_handle->setInSession(false); } + if (loc_eng_data_p->generateNmea && rpMsg->location.position_source == ULP_LOCATION_IS_FROM_GNSS) + { + loc_eng_nmea_generate_pos(loc_eng_data_p, rpMsg->location, rpMsg->locationExtended); + } + // Free the allocated memory for rawData GpsLocation* gp = (GpsLocation*)&(rpMsg->location); if (gp != NULL && gp->rawData != NULL) @@ -1543,6 +1561,12 @@ static void loc_eng_deferred_action_thread(void* arg) loc_eng_data_p->sv_status_cb((GpsSvStatus*)&(rsMsg->svStatus), (void*)rsMsg->svExt); } + + if (loc_eng_data_p->generateNmea) + { + loc_eng_nmea_generate_sv(loc_eng_data_p, rsMsg->svStatus, rsMsg->locationExtended); + } + } break; diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h index a14f5bd1..1b9dcf58 100644 --- a/loc_api/libloc_api_50001/loc_eng.h +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2009-2012 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2009-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -68,6 +68,11 @@ typedef unsigned char boolean; #define FAILURE FALSE #define INVALID_ATL_CONNECTION_HANDLE -1 +enum loc_nmea_provider_e_type { + NMEA_PROVIDER_AP = 0, // Application Processor Provider of NMEA + NMEA_PROVIDER_MP // Modem Processor Provider of NMEA +}; + enum loc_mute_session_e_type { LOC_MUTE_SESS_NONE = 0, LOC_MUTE_SESS_WAIT, @@ -128,6 +133,13 @@ typedef struct // For muting session broadcast loc_mute_session_e_type mute_session_state; + // For nmea generation + boolean generateNmea; + uint32_t sv_used_mask; + float hdop; + float pdop; + float vdop; + // Address buffers, for addressing setting before init int supl_host_set; char supl_host_buf[101]; @@ -149,6 +161,7 @@ typedef struct loc_gps_cfg_s unsigned long INTERMEDIATE_POS; unsigned long ACCURACY_THRES; unsigned long ENABLE_WIPER; + uint8_t NMEA_PROVIDER; unsigned long SUPL_VER; unsigned long CAPABILITIES; uint8_t GYRO_BIAS_RANDOM_WALK_VALID; diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h index d846a1f3..9dffc280 100755 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2011,2012 Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -98,6 +98,35 @@ struct LocPosMode } }; +/** Flags to indicate which values are valid in a GpsLocationExtended. */ +typedef uint16_t GpsLocationExtendedFlags; +/** GpsLocationExtended has valid pdop, hdop, vdop. */ +#define GPS_LOCATION_EXTENDED_HAS_DOP 0x0001 +/** GpsLocationExtended has valid altitude mean sea level. */ +#define GPS_LOCATION_EXTENDED_HAS_ALTITUDE_MEAN_SEA_LEVEL 0x0002 +/** GpsLocation has valid magnetic deviation. */ +#define GPS_LOCATION_EXTENDED_HAS_MAG_DEV 0x0004 +/** GpsLocation has valid mode indicator. */ +#define GPS_LOCATION_EXTENDED_HAS_MODE_IND 0x0008 + +/** Represents gps location extended. */ +typedef struct { + /** set to sizeof(GpsLocationExtended) */ + size_t size; + /** Contains GpsLocationExtendedFlags bits. */ + uint16_t flags; + /** Contains the Altitude wrt mean sea level */ + float altitudeMeanSeaLevel; + /** Contains Position Dilusion of Precision. */ + float pdop; + /** Contains Horizontal Dilusion of Precision. */ + float hdop; + /** Contains Vertical Dilusion of Precision. */ + float vdop; + /** Contains Magnetic Deviation. */ + float magneticDeviation; +} GpsLocationExtended; + typedef enum { LOC_ENG_IF_REQUEST_TYPE_SUPL = 0, LOC_ENG_IF_REQUEST_TYPE_WIFI, @@ -317,23 +346,24 @@ struct loc_eng_msg_delete_aiding_data : public loc_eng_msg { struct loc_eng_msg_report_position : public loc_eng_msg { const GpsLocation location; + const GpsLocationExtended locationExtended; const void* locationExt; const enum loc_sess_status status; const LocPosTechMask technology_mask; - inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, void* locExt, + inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, GpsLocationExtended &locExtended, void* locExt, enum loc_sess_status st) : loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), - location(loc), locationExt(locExt), status(st), technology_mask(LOC_POS_TECH_MASK_DEFAULT) + location(loc), locationExtended(locExtended), locationExt(locExt), status(st), technology_mask(LOC_POS_TECH_MASK_DEFAULT) { LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d\n Technology mask: %u", location.flags, location.position_source, location.latitude, location.longitude, location.altitude, location.speed, location.bearing, location.accuracy, location.timestamp, location.rawDataSize, location.rawData,status,technology_mask); } - inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, void* locExt, + inline loc_eng_msg_report_position(void* instance, GpsLocation &loc, GpsLocationExtended &locExtended, void* locExt, enum loc_sess_status st, LocPosTechMask technology) : loc_eng_msg(instance, LOC_ENG_MSG_REPORT_POSITION), - location(loc), locationExt(locExt), status(st), technology_mask(technology) + location(loc), locationExtended(locExtended), locationExt(locExt), status(st), technology_mask(technology) { LOC_LOGV("flags: %d\n source: %d\n latitude: %f\n longitude: %f\n altitude: %f\n speed: %f\n bearing: %f\n accuracy: %f\n timestamp: %lld\n rawDataSize: %d\n rawData: %p\n Session status: %d\n Technology mask: %u", location.flags, location.position_source, location.latitude, location.longitude, @@ -344,9 +374,10 @@ struct loc_eng_msg_report_position : public loc_eng_msg { struct loc_eng_msg_report_sv : public loc_eng_msg { const GpsSvStatus svStatus; + const GpsLocationExtended locationExtended; const void* svExt; - inline loc_eng_msg_report_sv(void* instance, GpsSvStatus &sv, void* ext) : - loc_eng_msg(instance, LOC_ENG_MSG_REPORT_SV), svStatus(sv), svExt(ext) + inline loc_eng_msg_report_sv(void* instance, GpsSvStatus &sv, GpsLocationExtended &locExtended, void* ext) : + loc_eng_msg(instance, LOC_ENG_MSG_REPORT_SV), svStatus(sv), locationExtended(locExtended), svExt(ext) { LOC_LOGV("num sv: %d\n ephemeris mask: %dxn almanac mask: %x\n used in fix mask: %x\n sv: prn snr elevation azimuth", svStatus.num_svs, svStatus.ephemeris_mask, svStatus.almanac_mask, svStatus.used_in_fix_mask); diff --git a/loc_api/libloc_api_50001/loc_eng_nmea.cpp b/loc_api/libloc_api_50001/loc_eng_nmea.cpp new file mode 100644 index 00000000..a0a3f202 --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_nmea.cpp @@ -0,0 +1,703 @@ +/* Copyright (c) 2012, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#define LOG_NDDEBUG 0 +#define LOG_TAG "LocSvc_eng_nmea" + +#include +#include +#include +#include "log_util.h" + +/*=========================================================================== +FUNCTION loc_eng_nmea_send + +DESCRIPTION + send out NMEA sentence + +DEPENDENCIES + NONE + +RETURN VALUE + Total length of the nmea sentence + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_nmea_send(char *pNmea, int length, loc_eng_data_s_type *loc_eng_data_p) +{ + struct timeval tv; + gettimeofday(&tv, (struct timezone *) NULL); + int64_t now = tv.tv_sec * 1000LL + tv.tv_usec / 1000; + CALLBACK_LOG_CALLFLOW("nmea_cb", %p, pNmea); + loc_eng_data_p->nmea_cb(now, pNmea, length); + LOC_LOGD("NMEA <%s", pNmea); +} + +/*=========================================================================== +FUNCTION loc_eng_nmea_put_checksum + +DESCRIPTION + Generate NMEA sentences generated based on position report + +DEPENDENCIES + NONE + +RETURN VALUE + Total length of the nmea sentence + +SIDE EFFECTS + N/A + +===========================================================================*/ +int loc_eng_nmea_put_checksum(char *pNmea, int maxSize) +{ + uint8_t checksum = 0; + int length = 0; + + pNmea++; //skip the $ + while (*pNmea != '\0') + { + checksum ^= *pNmea++; + length++; + } + + int checksumLength = snprintf(pNmea, maxSize,"*%02X\r\n", checksum); + return (length + checksumLength); +} + +/*=========================================================================== +FUNCTION loc_eng_nmea_generate_pos + +DESCRIPTION + Generate NMEA sentences generated based on position report + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_nmea_generate_pos(loc_eng_data_s_type *loc_eng_data_p, + const GpsLocation &location, const GpsLocationExtended &locationExtended) +{ + ENTRY_LOG(); + + char sentence[NMEA_SENTENCE_MAX_LENGTH] = {0}; + char* pMarker = sentence; + int lengthRemaining = sizeof(sentence); + int length = 0; + + time_t utcTime(location.timestamp/1000); + tm * pTm = gmtime(&utcTime); + int utcYear = pTm->tm_year % 100; // 2 digit year + int utcMonth = pTm->tm_mon + 1; // tm_mon starts at zero + int utcDay = pTm->tm_mday; + int utcHours = pTm->tm_hour; + int utcMinutes = pTm->tm_min; + int utcSeconds = pTm->tm_sec; + + // ------------------ + // ------$GPGSA------ + // ------------------ + + uint32_t svUsedCount = 0; + uint32_t svUsedList[32] = {0}; + uint32_t mask = loc_eng_data_p->sv_used_mask; + for (uint8_t i = 1; mask > 0 && svUsedCount < 32; i++) + { + if (mask & 1) + svUsedList[svUsedCount++] = i; + mask = mask >> 1; + } + // clear the cache so they can't be used again + loc_eng_data_p->sv_used_mask = 0; + + char fixType; + if (svUsedCount == 0) + fixType = '1'; // no fix + else if (svUsedCount <= 3) + fixType = '2'; // 2D fix + else + fixType = '3'; // 3D fix + + length = snprintf(pMarker, lengthRemaining, "$GPGSA,A,%c,", fixType); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + for (uint8_t i = 0; i < 12; i++) // only the first 12 sv go in sentence + { + if (i < svUsedCount) + length = snprintf(pMarker, lengthRemaining, "%02d,", svUsedList[i]); + else + length = snprintf(pMarker, lengthRemaining, ","); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + } + + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_DOP) + { // dop is in locationExtended, (QMI) + length = snprintf(pMarker, lengthRemaining, "%.1f,%.1f,%.1f", + locationExtended.pdop, + locationExtended.hdop, + locationExtended.vdop); + } + else if (loc_eng_data_p->pdop > 0 && loc_eng_data_p->hdop > 0 && loc_eng_data_p->vdop > 0) + { // dop was cached from sv report (RPC) + length = snprintf(pMarker, lengthRemaining, "%.1f,%.1f,%.1f", + loc_eng_data_p->pdop, + loc_eng_data_p->hdop, + loc_eng_data_p->vdop); + } + else + { // no dop + length = snprintf(pMarker, lengthRemaining, ",,"); + } + + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + // ------------------ + // ------$GPVTG------ + // ------------------ + + pMarker = sentence; + lengthRemaining = sizeof(sentence); + + if (location.flags & GPS_LOCATION_HAS_BEARING) + { + float magTrack = location.bearing; + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_MAG_DEV) + { + float magTrack = location.bearing - locationExtended.magneticDeviation; + if (magTrack < 0.0) + magTrack += 360.0; + else if (magTrack > 360.0) + magTrack -= 360.0; + } + + length = snprintf(pMarker, lengthRemaining, "$GPVTG,%.1lf,T,%.1lf,M,", location.bearing, magTrack); + } + else + { + length = snprintf(pMarker, lengthRemaining, "$GPVTG,,T,,M,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (location.flags & GPS_LOCATION_HAS_SPEED) + { + float speedKnots = location.speed * (3600.0/1852.0); + float speedKmPerHour = location.speed * 3.6; + + length = snprintf(pMarker, lengthRemaining, "%.1lf,N,%.1lf,K,", speedKnots, speedKmPerHour); + } + else + { + length = snprintf(pMarker, lengthRemaining, ",N,,K,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (!(location.flags & GPS_LOCATION_HAS_LAT_LONG)) + length = snprintf(pMarker, lengthRemaining, "%c", 'N'); // N means no fix + else if (LOC_POSITION_MODE_STANDALONE == loc_eng_data_p->client_handle->getPositionMode().mode) + length = snprintf(pMarker, lengthRemaining, "%c", 'A'); // A means autonomous + else + length = snprintf(pMarker, lengthRemaining, "%c", 'D'); // D means differential + + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + // ------------------ + // ------$GPRMC------ + // ------------------ + + pMarker = sentence; + lengthRemaining = sizeof(sentence); + + length = snprintf(pMarker, lengthRemaining, "$GPRMC,%02d%02d%02d,A," , + utcHours, utcMinutes, utcSeconds); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (location.flags & GPS_LOCATION_HAS_LAT_LONG) + { + double latitude = location.latitude; + double longitude = location.longitude; + char latHemisphere; + char lonHemisphere; + double latMinutes; + double lonMinutes; + + if (latitude > 0) + { + latHemisphere = 'N'; + } + else + { + latHemisphere = 'S'; + latitude *= -1.0; + } + + if (longitude < 0) + { + lonHemisphere = 'W'; + longitude *= -1.0; + } + else + { + lonHemisphere = 'E'; + } + + latMinutes = fmod(latitude * 60.0 , 60.0); + lonMinutes = fmod(longitude * 60.0 , 60.0); + + length = snprintf(pMarker, lengthRemaining, "%02d%09.6lf,%c,%03d%09.6lf,%c,", + (uint8_t)floor(latitude), latMinutes, latHemisphere, + (uint8_t)floor(longitude),lonMinutes, lonHemisphere); + } + else + { + length = snprintf(pMarker, lengthRemaining,",,,,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (location.flags & GPS_LOCATION_HAS_SPEED) + { + float speedKnots = location.speed * (3600.0/1852.0); + length = snprintf(pMarker, lengthRemaining, "%.1lf,", speedKnots); + } + else + { + length = snprintf(pMarker, lengthRemaining, ","); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (location.flags & GPS_LOCATION_HAS_BEARING) + { + length = snprintf(pMarker, lengthRemaining, "%.1lf,", location.bearing); + } + else + { + length = snprintf(pMarker, lengthRemaining, ","); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + length = snprintf(pMarker, lengthRemaining, "%2.2d%2.2d%2.2d,", + utcDay, utcMonth, utcYear); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_MAG_DEV) + { + float magneticVariation = locationExtended.magneticDeviation; + char direction; + if (magneticVariation < 0.0) + { + direction = 'W'; + magneticVariation *= -1.0; + } + else + { + direction = 'E'; + } + + length = snprintf(pMarker, lengthRemaining, "%.1lf,%c,", + magneticVariation, direction); + } + else + { + length = snprintf(pMarker, lengthRemaining, ",,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (!(location.flags & GPS_LOCATION_HAS_LAT_LONG)) + length = snprintf(pMarker, lengthRemaining, "%c", 'N'); // N means no fix + else if (LOC_POSITION_MODE_STANDALONE == loc_eng_data_p->client_handle->getPositionMode().mode) + length = snprintf(pMarker, lengthRemaining, "%c", 'A'); // A means autonomous + else + length = snprintf(pMarker, lengthRemaining, "%c", 'D'); // D means differential + + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + // ------------------ + // ------$GPGGA------ + // ------------------ + + pMarker = sentence; + lengthRemaining = sizeof(sentence); + + length = snprintf(pMarker, lengthRemaining, "$GPGGA,%02d%02d%02d," , + utcHours, utcMinutes, utcSeconds); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (location.flags & GPS_LOCATION_HAS_LAT_LONG) + { + double latitude = location.latitude; + double longitude = location.longitude; + char latHemisphere; + char lonHemisphere; + double latMinutes; + double lonMinutes; + + if (latitude > 0) + { + latHemisphere = 'N'; + } + else + { + latHemisphere = 'S'; + latitude *= -1.0; + } + + if (longitude < 0) + { + lonHemisphere = 'W'; + longitude *= -1.0; + } + else + { + lonHemisphere = 'E'; + } + + latMinutes = fmod(latitude * 60.0 , 60.0); + lonMinutes = fmod(longitude * 60.0 , 60.0); + + length = snprintf(pMarker, lengthRemaining, "%02d%09.6lf,%c,%03d%09.6lf,%c,", + (uint8_t)floor(latitude), latMinutes, latHemisphere, + (uint8_t)floor(longitude),lonMinutes, lonHemisphere); + } + else + { + length = snprintf(pMarker, lengthRemaining,",,,,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + char gpsQuality; + if (!(location.flags & GPS_LOCATION_HAS_LAT_LONG)) + gpsQuality = '0'; // 0 means no fix + else if (LOC_POSITION_MODE_STANDALONE == loc_eng_data_p->client_handle->getPositionMode().mode) + gpsQuality = '1'; // 1 means GPS fix + else + gpsQuality = '2'; // 2 means DGPS fix + + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_DOP) + { // dop is in locationExtended, (QMI) + length = snprintf(pMarker, lengthRemaining, "%c,%02d,%.1f,", + gpsQuality, svUsedCount, locationExtended.hdop); + } + else if (loc_eng_data_p->pdop > 0 && loc_eng_data_p->hdop > 0 && loc_eng_data_p->vdop > 0) + { // dop was cached from sv report (RPC) + length = snprintf(pMarker, lengthRemaining, "%c,%02d,%.1f,", + gpsQuality, svUsedCount, loc_eng_data_p->hdop); + } + else + { // no hdop + length = snprintf(pMarker, lengthRemaining, "%c,%02d,,", + gpsQuality, svUsedCount); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_ALTITUDE_MEAN_SEA_LEVEL) + { + length = snprintf(pMarker, lengthRemaining, "%.1lf,M,", + locationExtended.altitudeMeanSeaLevel); + } + else + { + length = snprintf(pMarker, lengthRemaining,",,"); + } + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if ((location.flags & GPS_LOCATION_HAS_ALTITUDE) && + (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_ALTITUDE_MEAN_SEA_LEVEL)) + { + length = snprintf(pMarker, lengthRemaining, "%.1lf,M,,", + location.altitude - locationExtended.altitudeMeanSeaLevel); + } + else + { + length = snprintf(pMarker, lengthRemaining,",,,"); + } + + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + // clear the dop cache so they can't be used again + loc_eng_data_p->pdop = 0; + loc_eng_data_p->hdop = 0; + loc_eng_data_p->vdop = 0; + + EXIT_LOG(%d, 0); +} + + + +/*=========================================================================== +FUNCTION loc_eng_nmea_generate_sv + +DESCRIPTION + Generate NMEA sentences generated based on sv report + +DEPENDENCIES + NONE + +RETURN VALUE + 0 + +SIDE EFFECTS + N/A + +===========================================================================*/ +void loc_eng_nmea_generate_sv(loc_eng_data_s_type *loc_eng_data_p, + const GpsSvStatus &svStatus, const GpsLocationExtended &locationExtended) +{ + ENTRY_LOG(); + + char sentence[NMEA_SENTENCE_MAX_LENGTH] = {0}; + char* pMarker = sentence; + int lengthRemaining = sizeof(sentence); + int length = 0; + + // ------------------ + // ------$GPGSV------ + // ------------------ + + if (svStatus.num_svs <= 0) + { + // no svs in view, so just send a blank $GPGSV sentence + strlcpy(sentence, "$GPGSV,1,1,0,", sizeof(sentence)); + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + } + else + { + int svCount = svStatus.num_svs; + int sentenceCount = svCount / 4; + if (svStatus.num_svs % 4) + sentenceCount++; + int sentenceNumber = 1; + int svNumber = 1; + + while (sentenceNumber <= sentenceCount) + { + pMarker = sentence; + lengthRemaining = sizeof(sentence); + + length = snprintf(pMarker, lengthRemaining, "$GPGSV,%d,%d,%02d", + sentenceCount, sentenceNumber, svCount); + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + for (int i=0; (svNumber <= svCount) && (i < 4); i++, svNumber++) + { + length = snprintf(pMarker, lengthRemaining,",%02d,%02d,%03d,", + svStatus.sv_list[svNumber-1].prn, + (int)(0.5 + svStatus.sv_list[svNumber-1].elevation), //float to int + (int)(0.5 + svStatus.sv_list[svNumber-1].azimuth)); //float to int + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + + if (svStatus.sv_list[svNumber-1].snr > 0) + { + length = snprintf(pMarker, lengthRemaining,"%02d", + (int)(0.5 + svStatus.sv_list[svNumber-1].snr)); //float to int + + if (length < 0 || length >= lengthRemaining) + { + LOC_LOGE("NMEA Error in string formatting"); + return; + } + pMarker += length; + lengthRemaining -= length; + } + } + + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + sentenceNumber++; + + } + } + + if (svStatus.used_in_fix_mask == 0) + { // No sv used, so there will be no position report, so send + // blank NMEA sentences + strlcpy(sentence, "$GPGSA,A,1,,,,,,,,,,,,,,,", sizeof(sentence)); + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + strlcpy(sentence, "$GPVTG,,T,,M,,N,,K,N", sizeof(sentence)); + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + strlcpy(sentence, "$GPRMC,,V,,,,,,,,,,N", sizeof(sentence)); + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + + strlcpy(sentence, "$GPGGA,,,,,,0,,,,,,,,", sizeof(sentence)); + length = loc_eng_nmea_put_checksum(sentence, sizeof(sentence)); + loc_eng_nmea_send(sentence, length, loc_eng_data_p); + } + else + { // cache the used in fix mask, as it will be needed to send $GPGSA + // during the position report + loc_eng_data_p->sv_used_mask = svStatus.used_in_fix_mask; + + // For RPC, the DOP are sent during sv report, so cache them + // now to be sent during position report. + // For QMI, the DOP will be in position report. + if (locationExtended.flags & GPS_LOCATION_EXTENDED_HAS_DOP) + { + loc_eng_data_p->pdop = locationExtended.pdop; + loc_eng_data_p->hdop = locationExtended.hdop; + loc_eng_data_p->vdop = locationExtended.vdop; + } + else + { + loc_eng_data_p->pdop = 0; + loc_eng_data_p->hdop = 0; + loc_eng_data_p->vdop = 0; + } + + } + + EXIT_LOG(%d, 0); +} diff --git a/loc_api/libloc_api_50001/loc_eng_nmea.h b/loc_api/libloc_api_50001/loc_eng_nmea.h new file mode 100644 index 00000000..5da7d5dd --- /dev/null +++ b/loc_api/libloc_api_50001/loc_eng_nmea.h @@ -0,0 +1,42 @@ +/* Copyright (c) 2012, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#ifndef LOC_ENG_NMEA_H +#define LOC_ENG_NMEA_H + +#include + +#define NMEA_SENTENCE_MAX_LENGTH 200 + +void loc_eng_nmea_send(char *pNmea, int length, loc_eng_data_s_type *loc_eng_data_p); +int loc_eng_nmea_put_checksum(char *pNmea, int maxSize); +void loc_eng_nmea_generate_sv(loc_eng_data_s_type *loc_eng_data_p, const GpsSvStatus &svStatus, const GpsLocationExtended &locationExtended); +void loc_eng_nmea_generate_pos(loc_eng_data_s_type *loc_eng_data_p, const GpsLocation &location, const GpsLocationExtended &locationExtended); + +#endif // LOC_ENG_NMEA_H diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 68057bcd..9345aedf 100755 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -1554,6 +1554,9 @@ void LocApiV02Adapter :: reportPosition ( LOC_LOGD("Reporting postion from V2 Adapter\n"); memset(&location, 0, sizeof (GpsLocation)); location.size = sizeof(location); + GpsLocationExtended locationExtended; + memset(&locationExtended, 0, sizeof (GpsLocationExtended)); + locationExtended.size = sizeof(locationExtended); // Process the position from final and intermediate reports if( (location_report_ptr->sessionStatus == eQMI_LOC_SESS_STATUS_SUCCESS_V02) || @@ -1615,7 +1618,29 @@ void LocApiV02Adapter :: reportPosition ( //Mark the location source as from GNSS location.flags |= LOCATION_HAS_SOURCE_INFO; location.position_source = ULP_LOCATION_IS_FROM_GNSS; + + if (location_report_ptr->magneticDeviation_valid) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_MAG_DEV; + locationExtended.magneticDeviation = location_report_ptr->magneticDeviation; + } + + if (location_report_ptr->DOP_valid) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_DOP; + locationExtended.pdop = location_report_ptr->DOP.PDOP; + locationExtended.hdop = location_report_ptr->DOP.HDOP; + locationExtended.vdop = location_report_ptr->DOP.VDOP; + } + + if (location_report_ptr->altitudeWrtMeanSeaLevel_valid) + { + locationExtended.flags |= GPS_LOCATION_EXTENDED_HAS_ALTITUDE_MEAN_SEA_LEVEL; + locationExtended.altitudeMeanSeaLevel = location_report_ptr->altitudeWrtMeanSeaLevel; + } + LocApiAdapter::reportPosition( location, + locationExtended, locEngHandle.extPosInfo((void*)location_report_ptr), (location_report_ptr->sessionStatus == eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 ? @@ -1626,6 +1651,7 @@ void LocApiV02Adapter :: reportPosition ( else { LocApiAdapter::reportPosition(location, + locationExtended, NULL, LOC_SESS_FAILURE); @@ -1642,6 +1668,7 @@ void LocApiV02Adapter :: reportSv ( const qmiLocEventGnssSvInfoIndMsgT_v02 *gnss_report_ptr) { GpsSvStatus SvStatus; + GpsLocationExtended locationExtended; int num_svs_max, i; const qmiLocSvInfoStructT_v02 *sv_info_ptr; @@ -1650,6 +1677,8 @@ void LocApiV02Adapter :: reportSv ( num_svs_max = 0; memset (&SvStatus, 0, sizeof (GpsSvStatus)); + memset(&locationExtended, 0, sizeof (GpsLocationExtended)); + locationExtended.size = sizeof(locationExtended); if(gnss_report_ptr->svList_valid == 1) { num_svs_max = gnss_report_ptr->svList_len; @@ -1740,6 +1769,7 @@ void LocApiV02Adapter :: reportSv ( { LOC_LOGV ("%s:%d]: firing SV callback\n", __func__, __LINE__); LocApiAdapter::reportSv(SvStatus, + locationExtended, locEngHandle.extSvInfo((void*)gnss_report_ptr)); } } From af0b025a0af13fc24faaba869c0be4012061a1de Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Thu, 20 Sep 2012 16:52:46 -0700 Subject: [PATCH 15/33] QMI LOC and Loc API update: Inject motion data and Get NI Geofence List; subsystem restart over QMUXD; CR 368109 SGLTE CID / OOS / NI SUPL INIT Change-Id: I3bd77e87de61c2c2565bbb151d661c717367c0ed --- loc_api/loc_api_v02/loc_api_v02_client.c | 173 +- loc_api/loc_api_v02/loc_api_v02_client.h | 612 +++--- loc_api/loc_api_v02/location_service_v02.c | 194 +- loc_api/loc_api_v02/location_service_v02.h | 2020 ++++++++++---------- 4 files changed, 1597 insertions(+), 1402 deletions(-) diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c index 7294d33e..6e60b604 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.c +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -27,6 +27,12 @@ */ #include +#include +#include + +#include +#include + #include "qmi_client.h" #include "qmi_idl_lib.h" #include "qmi_cci_target_ext.h" @@ -38,10 +44,7 @@ #define LOG_TAG "LocSvc_api_v02" #endif //_ANDROID_ -#include -#include -#include -#include + #include "loc_api_v02_client.h" #include "loc_util_log.h" @@ -50,21 +53,16 @@ // timeout in ms before send_msg_sync should return #define LOC_CLIENT_ACK_TIMEOUT (5000) -// timeout in ms before a sync request should return -#define LOC_CLIENT_SYNC_REQ_TIMEOUT (5000) - #else // timeout in ms before send_msg_sync should return #define LOC_CLIENT_ACK_TIMEOUT (1000) -// timeout in ms before a sync request should return -#define LOC_CLIENT_SYNC_REQ_TIMEOUT (1000) - #endif //LOC_UTIL_TARGET_OFF_TARGET -//timeout in ms to wait for the service to come up +//timeout in ms that the service waits for qmi-fw notification #define LOC_CLIENT_SERVICE_TIMEOUT_UNIT (4000) +// total timeout for the service to come up #define LOC_CLIENT_SERVICE_TIMEOUT_TOTAL (40000) /* Table to relate eventId, size and mask value used to enable the event*/ @@ -374,7 +372,27 @@ static locClientRespIndTableStructT locClientRespIndTable[]= { //Get best available position { QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, - sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02)} + sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02)}, + + //Inject motion data + { QMI_LOC_INJECT_MOTION_DATA_IND_V02, + sizeof(qmiLocInjectMotionDataIndMsgT_v02)}, + + //Get NI Geofence list + { QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, + sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02)}, + + //Inject GSM Cell Info + { QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, + sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02)}, + + //Inject Network Initiated Message + { QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, + sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02)}, + + //WWAN Out of Service Notification + { QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, + sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02)} }; @@ -385,7 +403,9 @@ typedef enum { eventIndType =0, respIndType = 1 } locClientIndEnumT; /** @struct locClientInternalState */ -typedef struct +typedef struct locClientCbDataStructT locClientCallbackDataType; + +struct locClientCbDataStructT { // client cookie void *pClientCookie; @@ -400,7 +420,10 @@ typedef struct // the event mask the client has registered for locClientEventMaskType eventRegMask; -}locClientCallbackDataType; + //pointer to itself for checking consistency data + locClientCallbackDataType *pMe; +}; + /*=========================================================================== * @@ -466,10 +489,12 @@ static bool isClientRegisteredForEvent( { if(eventIndId == locClientEventIndTable[idx].eventId) { - LOC_LOGV("%s:%d]: eventId %d registered mask = %llu, " - "eventMask = %llu\n", __func__, __LINE__, - eventIndId, eventRegMask, - locClientEventIndTable[idx].eventMask); + LOC_LOGV("%s:%d]: eventId %d registered mask = 0x%04x%04x, " + "eventMask = 0x%04x%04x\n", __func__, __LINE__, + eventIndId,(uint32_t)(eventRegMask>>32), + (uint32_t)(eventRegMask & 0xFFFFFFFF), + (uint32_t)(locClientEventIndTable[idx].eventMask >> 32), + (uint32_t)(locClientEventIndTable[idx].eventMask & 0xFFFFFFFF)); return(( eventRegMask & locClientEventIndTable[idx].eventMask)? @@ -826,6 +851,22 @@ static bool locClientHandleIndication( break; } + // get predicted orbits source response indication + case QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02: + { + //locClientHandleGetPredictedOrbitsSourceInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + // get predicted orbits validity response indication + case QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02: + { + //locClientHandleGetPredictedOrbitsDataValidityInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + case QMI_LOC_INJECT_SENSOR_DATA_IND_V02 : { //locClientHandleInjectSensorDataInd(user_handle, msg_id, ind_buf, ind_buf_len); @@ -948,6 +989,12 @@ static bool locClientHandleIndication( break; } + case QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02: + { + status = true; + break; + } + // for indications that only have a "status" field case QMI_LOC_NI_USER_RESPONSE_IND_V02: case QMI_LOC_INJECT_UTC_TIME_IND_V02: @@ -971,6 +1018,10 @@ static bool locClientHandleIndication( case QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02: case QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02: case QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02: + case QMI_LOC_INJECT_MOTION_DATA_IND_V02: + case QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02: + case QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02: + case QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02: { status = true; break; @@ -1003,13 +1054,16 @@ static void locClientErrorCb { locClientCallbackDataType* pCallbackData = (locClientCallbackDataType *)err_cb_data; + locClientErrorCbType localErrorCallback = NULL; /* copy the errorCallback function pointer from the callback * data to local variable. This is to protect against the race * condition between open/close and error callback. */ - locClientErrorCbType localErrorCallback = - pCallbackData->errorCallback; + if(NULL != pCallbackData) + { + localErrorCallback = pCallbackData->errorCallback; + } LOC_LOGD("%s:%d]: Service Error %d received, pCallbackData = %p\n", __func__, __LINE__, error, err_cb_data); @@ -1021,7 +1075,8 @@ static void locClientErrorCb if( (NULL != pCallbackData) && (NULL != localErrorCallback) && - (NULL != pCallbackData->errorCallback) ) + (NULL != pCallbackData->errorCallback) && + (pCallbackData == pCallbackData->pMe) ) { //invoke the error callback for the corresponding client localErrorCallback( @@ -1063,7 +1118,7 @@ static void locClientIndCb pCallbackData); // check callback data - if(NULL == pCallbackData) + if(NULL == pCallbackData ||(pCallbackData != pCallbackData->pMe)) { LOC_LOGE("%s:%d]: invalid callback data", __func__, __LINE__); return; @@ -1479,6 +1534,30 @@ static bool validateRequest( *pOutLen = sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02); break; } + case QMI_LOC_INJECT_MOTION_DATA_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectMotionDataReqMsgT_v02); + break; + } + + case QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02: + { + *pOutLen = sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02); + break; + } + + case QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02: + { + *pOutLen = sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02); + break; + } + // ALL requests with no payload case QMI_LOC_GET_SERVICE_REVISION_REQ_V02: @@ -1497,6 +1576,7 @@ static bool validateRequest( case QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02: case QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02: case QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02: + case QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02: { noPayloadFlag = true; break; @@ -1726,21 +1806,18 @@ locClientStatusEnumType locClientOpen ( locClientStatusEnumType status = eLOC_CLIENT_SUCCESS; locClientCallbackDataType *pCallbackData = NULL; - LOC_LOGV("%s:%d] \n", __func__, __LINE__); + // check input parameters + if( (NULL == pLocClientCallbacks) || (NULL == pLocClientHandle) + || (NULL == pLocClientCallbacks->respIndCb) || + (pLocClientCallbacks->size != sizeof(locClientCallbacksType))) + { + LOC_LOGE("%s:%d]: Invalid parameters in locClientOpen\n", + __func__, __LINE__); + return eLOC_CLIENT_FAILURE_INVALID_PARAMETER; + } do { - // check input parameters - if( (NULL == pLocClientCallbacks) || (NULL == pLocClientHandle) - || (NULL == pLocClientCallbacks->respIndCb) || - (pLocClientCallbacks->size != sizeof(locClientCallbacksType))) - { - LOC_LOGE("%s:%d]: Invalid parameters in locClientOpen\n", - __func__, __LINE__); - status = eLOC_CLIENT_FAILURE_INVALID_PARAMETER; - break; - } - // Allocate memory for the callback data pCallbackData = ( locClientCallbackDataType*)calloc( @@ -1775,7 +1852,8 @@ locClientStatusEnumType locClientOpen ( __func__, __LINE__, status); break; } - + // set the self pointer + pCallbackData->pMe = pCallbackData; // set the handle to the callback data *pLocClientHandle = (locClientHandleType)pCallbackData; @@ -1810,10 +1888,6 @@ locClientStatusEnumType locClientOpen ( // set the client cookie pCallbackData->pClientCookie = (void *)pClientCookie; - LOC_LOGD("%s:%d]: returning handle = 0x%x, user_handle=0x%x, status = %d\n", - __func__, __LINE__, *pLocClientHandle, - pCallbackData->userHandle, status); - }while(0); if(eLOC_CLIENT_SUCCESS != status) @@ -1822,6 +1896,13 @@ locClientStatusEnumType locClientOpen ( LOC_LOGE("%s:%d]: Error! status = %d\n", __func__, __LINE__,status); } + else + { + LOC_LOGD("%s:%d]: returning handle = %p, user_handle=%p, status = %d\n", + __func__, __LINE__, *pLocClientHandle, + pCallbackData->userHandle, status); + } + return(status); } @@ -1838,6 +1919,8 @@ locClientStatusEnumType locClientOpen ( locClientStatusEnumType locClientClose( locClientHandleType* pLocClientHandle) { + // convert handle to callback data + locClientCallbackDataType *pCallbackData; qmi_client_error_type rc = QMI_NO_ERR; //No error if(NULL == pLocClientHandle) @@ -1849,15 +1932,12 @@ locClientStatusEnumType locClientClose( return(eLOC_CLIENT_FAILURE_INVALID_PARAMETER); } - // convert handle to callback data - locClientCallbackDataType *pCallbackData = - (locClientCallbackDataType *)(*pLocClientHandle); - - LOC_LOGV("%s:%d]:\n", __func__, __LINE__ ); + pCallbackData = (locClientCallbackDataType *)(*pLocClientHandle); // check the input handle for sanity if(NULL == pCallbackData || - NULL == pCallbackData->userHandle) + NULL == pCallbackData->userHandle || + pCallbackData != pCallbackData->pMe ) { // invalid handle LOC_LOGE("%s:%d]: invalid handle \n", @@ -1934,7 +2014,8 @@ locClientStatusEnumType locClientSendReq( // check the input handle for sanity if(NULL == pCallbackData || - NULL == pCallbackData->userHandle ) + NULL == pCallbackData->userHandle || + pCallbackData != pCallbackData->pMe ) { // did not find the handle in the client List LOC_LOGE("%s:%d]: invalid handle \n", diff --git a/loc_api/loc_api_v02/loc_api_v02_client.h b/loc_api/loc_api_v02/loc_api_v02_client.h index 0ce7a2e8..a49f1275 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.h +++ b/loc_api/loc_api_v02/loc_api_v02_client.h @@ -32,6 +32,7 @@ #ifndef LOC_API_V02_CLIENT_H #define LOC_API_V02_CLIENT_H + #ifdef __cplusplus extern "C" { #endif @@ -42,37 +43,34 @@ extern "C" { * DATA DECLARATION * *============================================================================*/ - -#include -#include "location_service_v02.h" //QMI LOC Service data types definitions #include +#include + +#include "location_service_v02.h" //QMI LOC Service data types definitions + #include /****************************************************************************** * Constants and configuration *****************************************************************************/ -/** @addtogroup constants_macros -@{ */ - -/** Specific value of #locClientHandleType, indicating an invalid handle. */ +/** @ingroup constants_macros + Specific value of #locClientHandleType, indicating an invalid handle. */ #define LOC_CLIENT_INVALID_HANDLE_VALUE (NULL) -/** @} */ /* end_addtogroup constants_macros */ /** @addtogroup data_types @{ */ /** Location client handle used to represent a specific client. Negative values - are invalid handles. */ + are invalid handles. +*/ typedef void* locClientHandleType; -/** Data type for events and event masks. - @newpage */ +/** Data type for events and event masks. */ typedef uint64_t locClientEventMaskType; /** Location client status values. - @vertspace */ typedef enum { @@ -116,29 +114,22 @@ typedef enum /**< Failed because the service has not been initialized. */ eLOC_CLIENT_FAILURE_NOT_ENOUGH_MEMORY = 13 - /**< Failed because not rnough memory to do the operation.*/ + /**< Failed because there is not enough memory to do the operation. */ }locClientStatusEnumType; -/** Loc Client error values +/** Location client error values */ - typedef enum { eLOC_CLIENT_ERROR_SERVICE_UNAVAILABLE = 1 - /**< Service is no longer available, the client should - close the existing connection and reopen the connection - upon getting this error. - */ + /**< Service is no longer available. Upon getting this error, the client + must close the existing connection and reopen the connection. */ + }locClientErrorEnumType; -/** @} */ /* end_addtogroup data_types */ - -/** @addtogroup send_request -@{ */ - -/** @brief Request messages the client can send to the location engine. +/** Request messages the client can send to the location engine. The following requests do not have any data associated, so they do not have a payload structure defined: @@ -159,6 +150,7 @@ typedef enum - GetExternalPowerConfig - GetSensorControlConfig - GetSensorPerformanceControlConfiguration + - WWANOutOfServiceNotification */ typedef union { @@ -310,9 +302,11 @@ typedef union QMI_LOC_DELETE_ASSIST_DATA_REQ_V02. */ const qmiLocSetXtraTSessionControlReqMsgT_v02* pSetXtraTSessionControlReq; - /**< Sets XTRA-T session control in the engine. If the request is accepted by - the service, the client receives the following indication containing a - response: QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02. + /**< Sets XTRA-T session control in the engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02. To send this request, set the reqId field in locClientSendReq() to QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02. */ @@ -407,7 +401,7 @@ typedef union response indication for this request. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02.*/ + QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02. */ const qmiLocSetProtocolConfigParametersReqMsgT_v02* pSetProtocolConfigParametersReq; @@ -429,10 +423,9 @@ typedef union QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. - @newpage */ + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. */ - const qmiLocSetSensorControlConfigReqMsgT_v02* + const qmiLocSetSensorControlConfigReqMsgT_v02* pSetSensorControlConfigReq; /**< Sets the sensor control configuration parameters in the engine. @@ -441,8 +434,7 @@ typedef union QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02. - @newpage */ + QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02. */ const qmiLocSetSensorPerformanceControlConfigReqMsgT_v02* pSetSensorPerformanceControlConfigReq; @@ -453,8 +445,7 @@ typedef union QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. - @newpage */ + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. */ const qmiLocGetSensorPropertiesReqMsgT_v02* pGetSensorPropertiesReq; /**< Retrieves the sensor properties from the engine. @@ -464,8 +455,7 @@ typedef union QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02. - @newpage */ + QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02. */ const qmiLocSetSensorPropertiesReqMsgT_v02* pSetSensorPropertiesReq; /**< Sets the sensor properties in the engine. @@ -475,8 +465,7 @@ typedef union QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02. - @newpage */ + QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02. */ const qmiLocInjectSuplCertificateReqMsgT_v02* pInjectSuplCertificateReq; /**< Injects a SUPL certificate into the engine. @@ -486,8 +475,7 @@ typedef union QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02. - @newpage */ + QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02. */ const qmiLocDeleteSuplCertificateReqMsgT_v02* pDeleteSuplCertificateReq; /**< Deletes a SUPL certificate from the engine. @@ -497,78 +485,69 @@ typedef union QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02. - @newpage */ + QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02. */ const qmiLocSetPositionEngineConfigParametersReqMsgT_v02* pSetPositionEngineConfigParametersReq; - /**< Sets Position Engine configuration. + /**< Sets position engine configuration. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND _V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. - @newpage */ + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. */ const qmiLocGetPositionEngineConfigParametersReqMsgT_v02* pGetPositionEngineConfigParametersReq; - /**< Gets Position Engine configuration. + /**< Gets position engine configuration. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. - @newpage */ + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02. */ const qmiLocAddCircularGeofenceReqMsgT_v02* pAddCircularGeofenceReq; - /**< Adds a Circular Geofence. + /**< Adds a circular geofence. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 - @newpage */ + QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 */ const qmiLocDeleteGeofenceReqMsgT_v02* pDeleteGeofenceReq; - /**< Deletes a Geofence. + /**< Deletes a geofence. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_DELETE_GEOFENCE_IND_V02. To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_DELETE_GEOFENCE_REQ_V02 - @newpage */ + QMI_LOC_DELETE_GEOFENCE_REQ_V02 */ const qmiLocQueryGeofenceReqMsgT_v02* pQueryGeofenceReq; - /**< Queries a Geofence. + /**< Queries a geofence. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_QUERY_GEOFENCE_IND_V02 To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_QUERY_GEOFENCE_REQ_V02 - - @newpage */ + QMI_LOC_QUERY_GEOFENCE_REQ_V02. */ const qmiLocEditGeofenceReqMsgT_v02* pEditGeofenceReq; - /**< Edits Geofence Parameters. + /**< Edits geofence parameters. If the request is accepted by the service, the client receives the following indication containing a response: QMI_LOC_EDIT_GEOFENCE_IND_V02 To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_EDIT_GEOFENCE_REQ_V02 - - @newpage */ + QMI_LOC_EDIT_GEOFENCE_REQ_V02. */ const qmiLocGetBestAvailablePositionReqMsgT_v02* pGetBestAvailablePositionReq; @@ -579,14 +558,52 @@ typedef union QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 To send this request, set the reqId field in locClientSendReq() to - QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 + QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02. @newpagetable */ - @newpage */ + const qmiLocInjectMotionDataReqMsgT_v02* pInjectMotionDataReq; + /**< Inject motion data in the location engine + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_MOTION_DATA_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_MOTION_DATA_REQ_V02 */ + + const qmiLocGetNiGeofenceIdListReqMsgT_v02* pGetNiGeofenceIdListReq; + /**< Get the list of Network Initiated Geofences from the location engine. + + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 */ + + const qmiLocInjectGSMCellInfoReqMsgT_v02 *pInjectGSMCellInfoReq; + /**< Inject GSM Cell Information into the location engine. + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 */ + + const qmiLocInjectNetworkInitiatedMessageReqMsgT_v02 + *pInjectNetworkInitiatedMessageReq; + /**< Inject Network Initiated Message into the location engine. + If the request is accepted by the service, the client receives the + following indication containing a response: + QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 */ + + const void *pWWANOutOfServiceNotificationReq; }locClientReqUnionType; -/** @brief Event indications that are sent by the service. +/** Event indications that are sent by the service. */ typedef union { @@ -612,21 +629,22 @@ typedef union QMI_LOC_EVENT_GNSS_INFO_IND_V02. */ const qmiLocEventNmeaIndMsgT_v02* pNmeaReportEvent; - /**< Contains an NMEA report sentence. The entire NMEA report consisting - of multiple sentences is sent at a 1Hz rate. - This event is generated after QMI_LOC_START_REQ_V02 is sent. + /**< Contains an NMEA report sentence. + + The entire NMEA report consisting of multiple sentences is sent at a + 1 Hz rate. This event is generated after QMI_LOC_START_REQ_V02 is sent. The eventIndId field in the event indication callback is set to QMI_LOC_EVENT_NMEA_IND_V02. */ const qmiLocEventNiNotifyVerifyReqIndMsgT_v02* pNiNotifyVerifyReqEvent; - /**< Notifies a location client when the network triggers a positioning request - to the mobile. + /**< Notifies a location client when the network triggers a positioning + request to the mobile. Upon getting this event, the location client displays the - network-initiated fix request in a dialog and prompts the user to accept - or deny the request. The client responds to this request with the message - QMI_LOC_NI_USER_RESPONSE_REQ_V02. + network-initiated fix request in a dialog and prompts the user to + accept or deny the request. The client responds to this request with + the message QMI_LOC_NI_USER_RESPONSE_REQ_V02. The eventIndId field in the event indication callback is set to QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02. */ @@ -708,54 +726,51 @@ typedef union QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 message. The eventIndId field in the event indication callback is set to - QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02. - @newpage */ + QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02. */ const qmiLocEventNiGeofenceNotificationIndMsgT_v02* pNiGeofenceNotificationEvent; /**< Sent by the engine to notify the client about changes to a - Network Initiated Geofence. + network-initiated geofence. The eventIndId field in the event indication callback is set to - QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02. - @newpage */ + QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02. */ const qmiLocEventGeofenceGenAlertIndMsgT_v02* pGeofenceGenAlertEvent; /**< Sent by the engine to notify the client about updates that may - affect a Geofence operation. + affect a geofence operation. The eventIndId field in the event indication callback is set to - QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02. - @newpage */ + QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02. */ const qmiLocEventGeofenceBreachIndMsgT_v02* pGeofenceBreachEvent; - /**< Sent by the engine to notify the client about a Geofence Breach - Event. + /**< Sent by the engine to notify the client about a geofence breach + event. The eventIndId field in the event indication callback is set to - QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02. - @newpage */ + QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02. @newpagetable */ }locClientEventIndUnionType; -/** @brief Response indications that are sent by the service. */ +/** Response indications that are sent by the service. +*/ typedef union { const qmiLocGetServiceRevisionIndMsgT_v02* pGetServiceRevisionInd; - /**< Response to the request, QMI_LOC_GET_SERVICE_REVISION_REQ_V02. + /**< Response to the QMI_LOC_GET_SERVICE_REVISION_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_SERVICE_REVISION_IND_V02. */ const qmiLocGetFixCriteriaIndMsgT_v02* pGetFixCriteriaInd; - /**< Response to the request, QMI_LOC_GET_FIX_CRITERIA_REQ_V02. + /**< Response to the QMI_LOC_GET_FIX_CRITERIA_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_FIX_CRITERIA_IND_V02. */ const qmiLocNiUserRespIndMsgT_v02* pNiUserRespInd; - /**< Response to the request, QMI_LOC_NI_USER_RESPONSE_REQ_V02. + /**< Response to the QMI_LOC_NI_USER_RESPONSE_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_NI_USER_RESPONSE_IND_V02. */ @@ -773,332 +788,351 @@ typedef union const qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02* pGetPredictedOrbitsDataSourceInd; - /**< Response to the request, - QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02. + /**< Response to the QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 + request. The respIndId field in the response indication callback is set to QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02. */ const qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02* pGetPredictedOrbitsDataValidityInd; - /**< Response to the request, - QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02. + /**< Response to the QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 + request. The respIndId field in the response indication callback is set to QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02. */ const qmiLocInjectUtcTimeIndMsgT_v02* pInjectUtcTimeInd; - /**< Response to the request, QMI_LOC_INJECT_UTC_TIME_REQ_V02. + /**< Response to the QMI_LOC_INJECT_UTC_TIME_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_INJECT_UTC_TIME_IND_V02. */ const qmiLocInjectPositionIndMsgT_v02* pInjectPositionInd; - /**< Response to the request, QMI_LOC_INJECT_POSITION_REQ_V02. + /**< Response to the QMI_LOC_INJECT_POSITION_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_INJECT_POSITION_IND_V02. */ const qmiLocSetEngineLockIndMsgT_v02* pSetEngineLockInd; - /**< Response to the request, QMI_LOC_SET_ENGINE_LOCK_REQ_V02. + /**< Response to the QMI_LOC_SET_ENGINE_LOCK_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_ENGINE_LOCK_IND_V02. */ const qmiLocGetEngineLockIndMsgT_v02* pGetEngineLockInd; - /**< Response to the request, QMI_LOC_GET_ENGINE_LOCK_REQ_V02. + /**< Response to the QMI_LOC_GET_ENGINE_LOCK_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_ENGINE_LOCK_IND_V02. */ const qmiLocSetSbasConfigIndMsgT_v02* pSetSbasConfigInd; - /**< Response to the request, QMI_LOC_SET_SBAS_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_SET_SBAS_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_SBAS_CONFIG_IND_V02. */ const qmiLocGetSbasConfigIndMsgT_v02* pGetSbasConfigInd; - /**< Response to the request, QMI_LOC_GET_SBAS_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_GET_SBAS_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_SBAS_CONFIG_IND_V02. */ const qmiLocSetNmeaTypesIndMsgT_v02* pSetNmeaTypesInd; - /**< Response to the request, QMI_LOC_SET_NMEA_TYPES_REQ_V02. + /**< Response to the QMI_LOC_SET_NMEA_TYPES_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_NMEA_TYPES_IND_V02. */ const qmiLocGetNmeaTypesIndMsgT_v02* pGetNmeaTypesInd; - /**< Response to the request, QMI_LOC_GET_NMEA_TYPES_REQ_V02. + /**< Response to the QMI_LOC_GET_NMEA_TYPES_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_NMEA_TYPES_IND_V02. */ const qmiLocSetLowPowerModeIndMsgT_v02* pSetLowPowerModeInd; - /**< Response to the request, QMI_LOC_SET_LOW_POWER_MODE_REQ_V02. + /**< Response to the QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_LOW_POWER_MODE_IND_V02. */ const qmiLocGetLowPowerModeIndMsgT_v02* pGetLowPowerModeInd; - /**< Response to the request, QMI_LOC_GET_LOW_POWER_MODE_REQ_V02. + /**< Response to the QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_LOW_POWER_MODE_IND_V02. */ const qmiLocSetServerIndMsgT_v02* pSetServerInd; - /**< Response to the request, QMI_LOC_SET_SERVER_REQ_V02. + /**< Response to the QMI_LOC_SET_SERVER_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_SERVER_IND_V02. */ const qmiLocGetServerIndMsgT_v02* pGetServerInd; - /**< Response to the request, QMI_LOC_GET_SERVER_REQ_V02. + /**< Response to the QMI_LOC_GET_SERVER_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_SERVER_IND_V02. */ const qmiLocDeleteAssistDataIndMsgT_v02* pDeleteAssistDataInd; - /**< Response to the request, QMI_LOC_DELETE_ASSIST_DATA_REQ_V02. + /**< Response to the QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_DELETE_ASSIST_DATA_IND_V02. */ const qmiLocSetXtraTSessionControlIndMsgT_v02* pSetXtraTSessionControlInd; - /**< Response to the request, QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02. + /**< Response to the QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02. */ const qmiLocGetXtraTSessionControlIndMsgT_v02* pGetXtraTSessionControlInd; - /**< Response to the request, QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02. + /**< Response to the QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02. */ const qmiLocInjectWifiPositionIndMsgT_v02* pInjectWifiPositionInd; - /**< Response to the request, QMI_LOC_INJECT_WIFI_POSITION_REQ_V02. + /**< Response to the QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_INJECT_WIFI_POSITION_IND_V02. */ const qmiLocNotifyWifiStatusIndMsgT_v02* pNotifyWifiStatusInd; - /**< Response to the request, QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02. + /**< Response to the QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02. */ const qmiLocGetRegisteredEventsIndMsgT_v02* pGetRegisteredEventsInd; - /**< Response to the request, QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02. + /**< Response to the QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_REGISTERED_EVENTS_IND_V02. */ const qmiLocSetOperationModeIndMsgT_v02* pSetOperationModeInd; - /**< Response to the request, QMI_LOC_SET_OPERATION_MODE_REQ_V02. + /**< Response to the QMI_LOC_SET_OPERATION_MODE_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_OPERATION_MODE_IND_V02. */ const qmiLocGetOperationModeIndMsgT_v02* pGetOperationModeInd; - /**< Response to the request, QMI_LOC_GET_OPERATION_MODE_REQ_V02. + /**< Response to the QMI_LOC_GET_OPERATION_MODE_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_OPERATION_MODE_IND_V02. */ const qmiLocSetSpiStatusIndMsgT_v02* pSetSpiStatusInd; - /**< Response to the request, QMI_LOC_SET_SPI_STATUS_REQ_V02. + /**< Response to the QMI_LOC_SET_SPI_STATUS_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_SPI_STATUS_IND_V02. */ const qmiLocInjectSensorDataIndMsgT_v02* pInjectSensorDataInd; - /**< Response to the request, QMI_LOC_INJECT_SENSOR_DATA_REQ_V02. + /**< Response to the QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_INJECT_SENSOR_DATA_IND_V02. */ const qmiLocInjectTimeSyncDataIndMsgT_v02* pInjectTimeSyncDataInd; - /**< Response to the request, QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02. + /**< Response to the QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02. */ const qmiLocSetCradleMountConfigIndMsgT_v02* pSetCradleMountConfigInd; - /**< Response to the request, QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02. + /**< Response to the QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02. */ const qmiLocGetCradleMountConfigIndMsgT_v02* pGetCradleMountConfigInd; - /**< Response to the request, QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02. */ const qmiLocSetExternalPowerConfigIndMsgT_v02* pSetExternalPowerConfigInd; - /**< Response to the request, QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02. */ const qmiLocGetExternalPowerConfigIndMsgT_v02* pGetExternalPowerConfigInd; - /**< Response to the request, QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02. */ const qmiLocInformLocationServerConnStatusIndMsgT_v02* pInformLocationServerConnStatusInd; - /**< Response to the request, - QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02. + /**< Response to the QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 + request. The respIndId field in the response indication callback is set to QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02.*/ const qmiLocSetProtocolConfigParametersIndMsgT_v02* pSetProtocolConfigParametersInd; - /**< Response to the request, - QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. + /**< Response to the QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. */ const qmiLocGetProtocolConfigParametersIndMsgT_v02* pGetProtocolConfigParametersInd; - /**< Response to the request, - QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02. + /**< Response to the QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 request. The respIndId field in the response indication callback is set to - QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. - @newpage */ + QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02. */ const qmiLocSetSensorControlConfigIndMsgT_v02* pSetSensorControlConfigInd; - /**< Response to the request, - QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02. - @newpage */ + */ const qmiLocGetSensorControlConfigIndMsgT_v02* pGetSensorControlConfigInd; - /**< Response to the request, - QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02. + /**< Response to the QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02. - @newpage */ + */ const qmiLocSetSensorPropertiesIndMsgT_v02* pSetSensorPropertiesInd; - /**< Response to the request, - QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02. + /**< Response to the QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02. - @newpage */ + */ const qmiLocGetSensorPropertiesIndMsgT_v02* pGetSensorPropertiesInd; - /**< Response to the request, - QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02. + /**< Response to the QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 request. The respIndId field in the response indication callback is set to QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02. - @newpage */ + */ const qmiLocSetSensorPerformanceControlConfigIndMsgT_v02* pSetSensorPerformanceControlConfigInd; - /**< Response to the request, - QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. + /**< Response to the + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 request. The respIndId field in the response indication callback is set to - QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. - @newpage */ + QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. */ const qmiLocGetSensorPerformanceControlConfigIndMsgT_v02* pGetSensorPerformanceControlConfigInd; - /**< Response to the request, - QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02. + /**< Response to the + QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 request. The respIndId field in the response indication callback is set to - QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. - @newpage */ + QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02. */ const qmiLocInjectSuplCertificateIndMsgT_v02* pInjectSuplCertificateInd; - /**< Response to the request, - QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 + /**< Response to the QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 request. + The respIndId field in the response indication callback is set to - QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02. - @newpage */ + QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02. */ const qmiLocDeleteSuplCertificateIndMsgT_v02* pDeleteSuplCertificateInd; - /**< Response to the request, - QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02. + /**< Response to the QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 request. + The respIndId field in the response indication callback is set to - QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02. - @newpage */ + QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02. */ const qmiLocSetPositionEngineConfigParametersIndMsgT_v02* pSetPositionEngineConfigParametersInd; - /**< Response to the request, - QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 + /**< Response to the QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 + request. + The respIndId field in the response indication callback is set to - QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. - @newpage */ + QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. */ const qmiLocGetPositionEngineConfigParametersIndMsgT_v02* pGetPositionEngineConfigParametersInd; - /**< Response to the request, - QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 - The respIndId field in the response indication callback is set to - QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. - @newpage */ + /**< Response to the QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 + request. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02. */ const qmiLocAddCircularGeofenceIndMsgT_v02* pAddCircularGeofenceInd; - /**< Response to the request, - QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 + /**< Response to the QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 request. + The respIndId field in the response indication callback is set to - QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 - @newpage */ + QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02. */ const qmiLocDeleteGeofenceIndMsgT_v02* pDeleteGeofenceInd; - /**< Response to the request, - QMI_LOC_DELETE_GEOFENCE_REQ_V02 + /**< Response to the QMI_LOC_DELETE_GEOFENCE_REQ_V02 request. + The respIndId field in the response indication callback is set to - QMI_LOC_DELETE_GEOFENCE_IND_V02 - @newpage */ + QMI_LOC_DELETE_GEOFENCE_IND_V02. */ const qmiLocQueryGeofenceIndMsgT_v02* pQueryGeofenceInd; - /**< Response to the request, - QMI_LOC_QUERY_GEOFENCE_REQ_V02 - The respIndId field in the response indication callback is set to - QMI_LOC_QUERY_GEOFENCE_IND_V02 - @newpage */ + /**< Response to the QMI_LOC_QUERY_GEOFENCE_REQ_V02 request. - const qmiLocEditGeofenceIndMsgT_v02* pEditGeofenceInd; - /**< Response to the request, - QMI_LOC_EDIT_GEOFENCE_REQ_V02 - The respIndId field in the response indication callback is set to - QMI_LOC_EDIT_GEOFENCE_IND_V02 - @newpage */ + The respIndId field in the response indication callback is set to + QMI_LOC_QUERY_GEOFENCE_IND_V02. */ - const qmiLocGetBestAvailablePositionIndMsgT_v02* + const qmiLocEditGeofenceIndMsgT_v02* pEditGeofenceInd; + /**< Response to the QMI_LOC_EDIT_GEOFENCE_REQ_V02 request. + + The respIndId field in the response indication callback is set to + QMI_LOC_EDIT_GEOFENCE_IND_V02. */ + + const qmiLocGetBestAvailablePositionIndMsgT_v02* pGetBestAvailablePositionInd; - /**< Response to the request, - QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 + /**< Response to the QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 request. + The respIndId field in the response indication callback is set to - QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 - @newpage */ + QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02. */ + + const qmiLocInjectMotionDataIndMsgT_v02* pInjectMotionDataInd; + /**< Response to the QMI_LOC_INJECT_MOTION_DATA_REQ_V02 request. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_MOTION_DATA_IND_V02. */ + + const qmiLocGetNiGeofenceIdListIndMsgT_v02* pGetNiGeofenceIdListInd; + /**< Response to the QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 request. + + The respIndId field in the response indication callback is set to + QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02. */ + + const qmiLocInjectGSMCellInfoIndMsgT_v02* pInjectGSMCellInfoInd; + /**< Response to the QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 request. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02. */ + + const qmiLocInjectNetworkInitiatedMessageIndMsgT_v02* + pInjectNetworkInitiatedMessageInd; + + /**< Response to the QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 + request. + + The respIndId field in the response indication callback is set to + QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02. */ + + const qmiLocWWANOutOfServiceNotificationIndMsgT_v02* + pWWANOutOfServiceNotificationInd; + + /**< Response to the QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 + request. + The respIndId field in the response indication callback is set to + QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02. */ }locClientRespIndUnionType; -/** @} */ /* end_addtogroup send_request */ +/** @} */ /* end_addtogroup data_types */ -/** @addtogroup data_types +/** @addtogroup callback_functions @{ */ - -/** Location event indication callback function type. The Location service can - generate two types of indications: +/** + Location event indication callback function type. The Location service can + generate two types of indications: - Asynchronous events indications, such as time injection request and satellite reports. The client specifies the asynchronous events it is interested in @@ -1109,7 +1143,10 @@ typedef union This callback handles the asynchronous event indications. - @vertspace + @datatypes + #locClientHandleType \n + #locClientEventIndUnionType + @param handle Location client for this event. Only the client who registered for the corresponding event receives this callback. @@ -1117,6 +1154,12 @@ typedef union @param eventIndPayload Event indication payload. @param pClientCookie Pointer to the cookie the client specified during registration. + + @return + None. + + @dependencies + None. @newpage */ typedef void (*locClientEventIndCbType)( locClientHandleType handle, @@ -1125,8 +1168,9 @@ typedef void (*locClientEventIndCbType)( void *pClientCookie ); -/** Location response indication callback function type. The Location service can - generate two types of indications: +/** + Location response indication callback function type. The Location service can + generate two types of indications: - Asynchronous events indications, such as time injection request and satellite reports. The client specifies the asynchronous events it is interested in @@ -1137,7 +1181,10 @@ typedef void (*locClientEventIndCbType)( This callback handles the response indications. - @vertspace + @datatypes + #locClientHandleType \n + #locClientRespIndUnionType + @param handle Location client who sent the request for which this response indication is generated. @param respIndId ID of the response. It is the same value as the ID @@ -1146,7 +1193,11 @@ typedef void (*locClientEventIndCbType)( @param pClientCookie Pointer to the cookie the client specified during registration. - @newpage + @return + None. + + @dependencies + None. @newpage */ typedef void (*locClientRespIndCbType)( locClientHandleType handle, @@ -1155,84 +1206,84 @@ typedef void (*locClientRespIndCbType)( void *pClientCookie ); -/** Location error callback function type. This function will be - called to inform the client that the service is no longer - available. When the client receives this callback it must - close the existing connection and reopen the client connection. +/** + Location error callback function type. This function is called to inform + the client that the service is no longer available. When the client + receives this callback, it must close the existing connection and reopen + the client connection. + @datatypes + #locClientHandleType \n + #locClientErrorEnumType - @vertspace @param handle Location client who sent the request for which this error indication is generated. @param errorId Error ID. - @param errorCbdata Payload associated with the error indication. + @param pClientCookie Payload associated with the error indication. - @newpage + @return + None. + + @dependencies + None. */ typedef void (*locClientErrorCbType)( locClientHandleType handle, locClientErrorEnumType errorId, void* pClientCookie ); +/** @} */ /* end_addtogroup callback_functions */ -/** Callback functions to be registered during locClientOpen +/** @ingroup data_types + Callback functions to be registered during locClientOpen(). */ - typedef struct { - uint32_t size; - /**< Size of the structure */ - locClientEventIndCbType eventIndCb; - /**< Event Indication callback */ - locClientRespIndCbType respIndCb; - /**< Response Indication callback */ - locClientErrorCbType errorCb; - /**< Error Indication callback */ + uint32_t size; /**< Size of the structure. */ + locClientEventIndCbType eventIndCb; /**< Event indication callback. */ + locClientRespIndCbType respIndCb; /**< Response indication callback. */ + locClientErrorCbType errorCb; /**< Error indication callback. + @newpagetable */ }locClientCallbacksType; -/** @} */ /* end_addtogroup data_types */ /*=========================================================================== * * FUNCTION DECLARATION * *==========================================================================*/ - -/** @addtogroup open_client +/** @addtogroup operation_functions @{ */ /*========================================================================== locClientOpen */ -/** - @latexonly\label{hdr:locClientOpenFunction}@endlatexonly Connects a location - client to the location engine. If the connection is successful, this function - returns a handle that the location client uses for future location operations. +/** @xreflabel{hdr:locClientOpenFunction} + Connects a location client to the location engine. If the connection is + successful, this function returns a handle that the location client uses for + future location operations. - @datatype - #locClientStatusEnumType\n - #locClientEventMaskType\n - #locClientCallbacksType *\n - #locClientHandleType *\n - #void * + @datatypes + #locClientStatusEnumType \n + #locClientEventMaskType \n + #locClientCallbacksType \n + #locClientHandleType - @vertspace @param[in] eventRegMask Mask of asynchronous events the client is interested in receiving. @param[in] pLocClientCallbacks Pointer to structure containing the callbacks. @param[out] pLocClientHandle Pointer to the handle to be used by the client for any subsequent requests. - @param[in] pLocClientCookie Pointer to a "cookie" to be returned to the + @param[in] pLocClientCookie Pointer to a cookie to be returned to the client along with the callbacks. @return One of the following error codes: - eLOC_CLIENT_SUCCESS -- If the connection is opened. - - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. + - Non-zero error code (see #locClientStatusEnumType) -- On failure. @dependencies - None. - @newpage + None. @newpage */ extern locClientStatusEnumType locClientOpen ( locClientEventMaskType eventRegMask, @@ -1241,22 +1292,17 @@ extern locClientStatusEnumType locClientOpen ( const void* pLocClientCookie ); -/** @} */ /* end_addtogroup open_client */ -/** @addtogroup close_client -@{ */ /*========================================================================== locClientClose */ -/** - @latexonly\label{hdr:locClientCloseFunction}@endlatexonly Disconnects a client - from the location engine and sets the handle to +/** @xreflabel{hdr:locClientCloseFunction} + Disconnects a client from the location engine and sets the handle to LOC_CLIENT_INVALID_HANDLE_VALUE. - @datatype - #locClientStatusEnumType\n + @datatypes + #locClientStatusEnumType \n #locClientHandleType - @vertspace @param[in] pLocClientHandle Pointer to the handle returned by the locClientOpen() function. @@ -1266,38 +1312,32 @@ extern locClientStatusEnumType locClientOpen ( - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. @dependencies - None. - @newpage + None. @newpage */ extern locClientStatusEnumType locClientClose ( locClientHandleType* pLocClientHandle ); -/** @} */ /* end_addtogroup close_client */ - -/** @addtogroup send_request -@{ */ /*============================================================================= locClientSendReq */ -/** - @latexonly\label{hdr:locClientSendReqFunction}@endlatexonly Sends a message to - the location engine. If this function is successful, the client expects an - indication (except start, stop, event registration, and sensor injection - messages) through the registered callback in the locClientOpen() function. +/** @xreflabel{hdr:locClientSendReqFunction} + Sends a message to the location engine. If this function is successful, the + client expects an indication (except start, stop, event registration, and + sensor injection messages) through the registered callback in the + locClientOpen() function. The indication contains the status of the request. If the status is a success, the indication also contains the payload associated with response. - @datatype - #locClientStatusEnumType\n - #locClientHandleType\n + @datatypes + #locClientStatusEnumType \n + #locClientHandleType \n #locClientReqUnionType - @vertspace @param[in] handle Handle returned by the locClientOpen() function. @param[in] reqId QMI_LOC service message ID of the request. - @param[in] pReqPayload Payload of the request. This can be NULL if the request - has no payload. + @param[in] reqPayload Payload of the request. This can be NULL if the + request has no payload. @return One of the following error codes: @@ -1305,11 +1345,7 @@ extern locClientStatusEnumType locClientClose ( - Non-zero error code (see \ref locClientStatusEnumType) -- On failure. @dependencies - None. - - @structure - locClientReqUnionType - @newpage + None. @newpage */ extern locClientStatusEnumType locClientSendReq( locClientHandleType handle, @@ -1317,72 +1353,46 @@ extern locClientStatusEnumType locClientSendReq( locClientReqUnionType reqPayload ); -/** @} */ /* end_addtogroup send_request */ -/** @addtogroup get_size_event -@{ */ /*============================================================================= locClientGetSizeByEventIndId */ -/** - Gets the size of the event indication structure from a specified ID. +/** Gets the size of the event indication structure from a specified ID. - @datatype - #locClientGetSizeByEventIndId - - @vertspace @param[in] eventIndId Event indicator ID. @param[out] pEventIndSize Pointer to the size of the structure. @return - true -- The event ID was found.\n - false -- Otherwise. + TRUE -- The event ID was found. \n + FALSE -- Otherwise. @dependencies - None. - - @structure - locClientEventIndUnionType - @newpage + None. @newpage */ extern bool locClientGetSizeByEventIndId( uint32_t eventIndId, size_t *pEventIndSize); -/** @} */ /* end_addtogroup get_size_event */ -/** @addtogroup get_size_response -@{ */ /*============================================================================= locClientGetSizeByRespIndId */ +/** Gets the size of the response indication structure from a specified ID. -/** - Gets the size of the response indication structure from a specified ID. - - @datatype - #locClientGetSizeByRespIndId - - @vertspace @param[in] respIndId Response indicator ID. @param[out] pRespIndSize Pointer to the size of the structure. @return - true -- The response ID was found.\n - false -- Otherwise. + TRUE -- The response ID was found. \n + FALSE -- Otherwise. @dependencies None. - - @structure - locClientRespIndUnionType - @newpage */ extern bool locClientGetSizeByRespIndId( uint32_t respIndId, size_t *pRespIndSize); /*=============================================================================*/ - -/** @} */ /* end_addtogroup get_size_response */ +/** @} */ /* end_addtogroup operation_functions */ #ifdef __cplusplus } diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c index e1bf6f55..f1e1b6db 100644 --- a/loc_api/loc_api_v02/location_service_v02.c +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -33,7 +33,14 @@ GENERAL DESCRIPTION This is the file which defines the loc service Data structures. -*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.5 + It was generated on: Thu Sep 20 2012 + From IDL File: location_service_v02.idl */ #include "stdint.h" #include "qmi_idl_lib_internal.h" @@ -320,6 +327,19 @@ static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { QMI_IDL_FLAG_END_VALUE }; +static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), + + QMI_IDL_FLAG_END_VALUE +}; + static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), @@ -336,7 +356,7 @@ static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), QMI_LOC_MAX_NTP_SERVERS_V02, QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), - 15, 0, + 16, 0, QMI_IDL_FLAG_END_VALUE }; @@ -355,7 +375,7 @@ static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), - 15, 0, + 16, 0, QMI_IDL_FLAG_END_VALUE }; @@ -375,7 +395,7 @@ static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), - 19, 0, + 20, 0, QMI_IDL_FLAG_END_VALUE }; @@ -537,7 +557,7 @@ static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), - 28, 0, + 29, 0, QMI_IDL_FLAG_END_VALUE }; @@ -565,19 +585,6 @@ static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { QMI_IDL_FLAG_END_VALUE }; -static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), - - QMI_IDL_FLAG_END_VALUE -}; - static const uint8_t qmiLocMotionDataStructT_data_v02[] = { QMI_IDL_GENERIC_4_BYTE, QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), @@ -597,6 +604,22 @@ static const uint8_t qmiLocMotionDataStructT_data_v02[] = { QMI_IDL_FLAG_END_VALUE }; +static const uint8_t qmiLocGSMCellIdStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MCC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MNC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, LAC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, CID), + + QMI_IDL_FLAG_END_VALUE +}; + /*Message Definitions*/ static const uint8_t qmiLocGenRespMsgT_data_v02[] = { QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, @@ -869,7 +892,7 @@ static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { 0x14, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), - 32, 0 + 15, 0 }; static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { @@ -877,20 +900,20 @@ static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), - 16, 0 + 17, 0 }; static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { 0x01, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), - 17, 0, + 18, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), - 18, 0 + 19, 0 }; static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { @@ -944,13 +967,13 @@ static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), - 20, 0, + 21, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), - 20, 0 + 21, 0 }; static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { @@ -1008,7 +1031,7 @@ static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), - 21, 0 + 22, 0 }; /* @@ -1115,7 +1138,7 @@ static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { 0x14, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), - 32, 0 + 15, 0 }; static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { @@ -1175,13 +1198,13 @@ static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), - 17, 0, + 18, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), - 18, 0 + 19, 0 }; /* @@ -1199,7 +1222,7 @@ static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), - 22, 0 + 23, 0 }; static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { @@ -1273,7 +1296,7 @@ static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { 0x1A, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), - 23, 0, + 24, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), 0x1B, @@ -1493,7 +1516,7 @@ static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), - 24, 0, + 25, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), 0x11, @@ -1551,13 +1574,13 @@ static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), - 25, 0, + 26, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), - 26, 0, + 27, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), 0x12, @@ -1565,7 +1588,7 @@ static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), - 27, 0, + 28, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), 0x13, @@ -1664,13 +1687,13 @@ static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), - 29, 0, + 30, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), 0x12, QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), - 29, 0 + 30, 0 }; static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { @@ -1799,7 +1822,7 @@ static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { 0x10, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), - 30, 0 + 31, 0 }; static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { @@ -1998,13 +2021,13 @@ static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), 0x12, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), 0x13, @@ -2015,13 +2038,13 @@ static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = 0x14, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), 0x15, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), - 19, 0 + 20, 0 }; static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { @@ -2055,13 +2078,13 @@ static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = 0x11, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), 0x12, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), 0x13, @@ -2072,13 +2095,13 @@ static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = 0x14, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), - 19, 0, + 20, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), 0x15, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), - 19, 0 + 20, 0 }; static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { @@ -2175,7 +2198,7 @@ static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { 0x02, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), - 31, 0, + 32, 0, 0x03, QMI_IDL_GENERIC_1_BYTE, @@ -2277,7 +2300,7 @@ static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { 0x14, QMI_IDL_AGGREGATE, QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), - 31, 0, + 32, 0, QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), 0x15, @@ -2530,6 +2553,53 @@ static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) }; +static const uint8_t qmiLocInjectGSMCellInfoReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, gsmCellId), + 34, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, roamingStatus) +}; + +static const uint8_t qmiLocInjectGSMCellInfoIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessageType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage), + ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage) - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage_len) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02, status) +}; + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * static const uint8_t qmiLocWWANOutOfServiceNotificationReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWWANOutOfServiceNotificationIndMsgT_v02, status) +}; + /* Type Table */ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, @@ -2547,6 +2617,7 @@ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, + {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, @@ -2564,8 +2635,8 @@ static const qmi_idl_type_table_entry loc_type_table_v02[] = { {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, - {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, - {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02} + {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02}, + {sizeof(qmiLocGSMCellIdStructT_v02), qmiLocGSMCellIdStructT_data_v02} }; /* Message Table */ @@ -2697,7 +2768,13 @@ static const qmi_idl_message_table_entry loc_message_table_v02[] = { {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, - {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02} + {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02), qmiLocInjectGSMCellInfoReqMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02), qmiLocInjectGSMCellInfoIndMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02), qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02), qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02), qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02} }; /* Predefine the Type Table Object */ @@ -2775,7 +2852,10 @@ static const qmi_idl_service_message_table_entry loc_service_command_messages_v0 {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7} + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02, TYPE16(0, 128), 23}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02, TYPE16(0, 130), 1036}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02, TYPE16(0, 132), 0} }; static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { @@ -2835,7 +2915,10 @@ static const qmi_idl_service_message_table_entry loc_service_response_messages_v {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7} + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02, TYPE16(0, 0), 7} }; static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { @@ -2908,7 +2991,10 @@ static const qmi_idl_service_message_table_entry loc_service_indication_messages {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82} + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82}, + {QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, TYPE16(0, 129), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, TYPE16(0, 131), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, TYPE16(0, 132), 0} }; /*Service Object*/ @@ -2922,7 +3008,7 @@ struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, &loc_qmi_idl_type_table_object_v02, - 0x0D, + 0x0F, NULL }; diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h index d2da6915..f5db0b99 100644 --- a/loc_api/loc_api_v02/location_service_v02.h +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -58,6 +58,13 @@ elements in the array will be accessed. */ +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.5 + It was generated on: Thu Sep 20 2012 + From IDL File: location_service_v02.idl */ /** @defgroup loc_qmi_consts Constant values defined in the IDL */ /** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ @@ -82,11 +89,11 @@ extern "C" { /** Major Version Number of the IDL used to generate this file */ #define LOC_V02_IDL_MAJOR_VERS 0x02 /** Revision Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MINOR_VERS 0x0D +#define LOC_V02_IDL_MINOR_VERS 0x0F /** Major Version Number of the qmi_idl_compiler used to generate this file */ #define LOC_V02_IDL_TOOL_VERS 0x05 /** Maximum Defined Message ID */ -#define LOC_V02_MAX_MESSAGE_ID 0x0069; +#define LOC_V02_MAX_MESSAGE_ID 0x006C; /** @} */ @@ -181,9 +188,12 @@ extern "C" { /** Maximum length of the SUPL certificate. */ #define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 -/** Maximum length of the Network Initiated Geofence ID +/** Maximum length of the network-initiated Geofence ID list */ #define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 + +/** Maximum length of the injected network initiated message. */ +#define QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02 1024 /** @} */ @@ -214,7 +224,7 @@ typedef struct { /* Mandatory */ /* Revision */ uint32_t revision; - /**< Revision that the control point is using. */ + /**< Revision that the control point is using. */ }qmiLocInformClientRevisionReqMsgT_v02; /* Message */ /** @} @@ -295,7 +305,7 @@ typedef struct { \end{itemize1} \vspace{0.05in} Multiple events can be registered by ORing the individual masks and sending them in this TLV. All unused bits in this mask must be set to 0. - */ + */ }qmiLocRegEventsReqMsgT_v02; /* Message */ /** @} @@ -306,9 +316,8 @@ typedef struct { */ typedef enum { QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. - Request a single position fix. */ - eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, + eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. */ + eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, /**< Request a single position fix. */ QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocFixRecurrenceEnumT_v02; /** @@ -321,9 +330,8 @@ typedef enum { typedef enum { QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ - eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. - High accuracy. */ - eQMI_LOC_ACCURACY_HIGH_V02 = 3, + eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. */ + eQMI_LOC_ACCURACY_HIGH_V02 = 3, /**< High accuracy. */ QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocAccuracyLevelEnumT_v02; /** @@ -335,9 +343,8 @@ typedef enum { */ typedef enum { QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. - Intermediate reports are turned off. */ - eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, + eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. */ + eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, /**< Intermediate reports are turned off. */ QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocIntermediateReportStateEnumT_v02; /** @@ -350,20 +357,20 @@ typedef enum { typedef struct { char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; - /**< Application provider. */ + /**< Application provider. */ char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; - /**< Application name. */ + /**< Application name. */ uint8_t applicationVersion_valid; - /**< Specifies whether the application version string contains a valid value: - \begin{itemize1} + /**< Specifies whether the application version string contains + a valid value: \begin{itemize1} \item 0x00 (FALSE) -- Application version string is invalid \item 0x01 (TRUE) -- Application version string is valid - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; - /**< Application version. */ + /**< Application version. */ }qmiLocApplicationIdStructT_v02; /* Type */ /** @} @@ -372,8 +379,7 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Request Message; The control point sends this message when it wants to - initiate a GPS session. */ +/** Request Message; Used by the control point to initiate a GPS session. */ typedef struct { /* Mandatory */ @@ -383,7 +389,7 @@ typedef struct { is reported back in the position reports. The control point must specify the same session ID in the QMI_LOC_STOP_REQ message. \n - Range: 0 to 255 - */ + */ /* Optional */ /* Recurrence Type */ @@ -395,7 +401,7 @@ typedef struct { Valid values: \n - 0x00000001 -- Request periodic fixes \n - 0x00000002 -- Request a single fix - */ + */ /* Optional */ /* Horizontal Accuracy */ @@ -404,14 +410,13 @@ typedef struct { /**< Specifies the horizontal accuracy level required by the control point. If not specified, accuracy defaults to LOW. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- LOW: Client requires low horizontal accuracy \item 0x00000002 -- MED: Client requires medium horizontal accuracy \item 0x00000003 -- HIGH: Client requires high horizontal accuracy \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Enable/Disable Intermediate Reports */ @@ -426,15 +431,14 @@ typedef struct { report is set to IN_PROGRESS in order for the control point to identify intermediate reports. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- ON: Client is interested in receiving intermediate reports \item 0x00000002 -- OFF: Client is not interested in receiving intermediate reports \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Minimum Interval Between Position Reports */ @@ -444,13 +448,13 @@ typedef struct { position reports. \n - Units: Milliseconds \n - Default: 1000 ms - */ + */ /* Optional */ /* ID of the Application that Sent this Request */ uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version. */ + /**< \n Application provider, name, and version.*/ }qmiLocStartReqMsgT_v02; /* Message */ /** @} @@ -459,8 +463,7 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Request Message; The control point sends this message when it wants to - stop a GPS session. */ +/** Request Message; Used by the control point to stop a GPS session. */ typedef struct { /* Mandatory */ @@ -468,7 +471,7 @@ typedef struct { uint8_t sessionId; /**< ID of the session that was specified in the Start request (QMI_LOC_START_REQ).\n - - Range: 0 to 255 */ + - Range: 0 to 255 */ }qmiLocStopReqMsgT_v02; /* Message */ /** @} @@ -495,9 +498,8 @@ typedef enum { eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ - eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. - Fix request failed because the engine is locked. */ - eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, + eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. */ + eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, /**< Fix request failed because the engine is locked. */ QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSessionStatusEnumT_v02; /** @@ -511,11 +513,11 @@ typedef struct { uint16_t gpsWeek; /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n - - Units: Weeks */ + - Units: Weeks */ uint32_t gpsTimeOfWeekMs; /**< Amount of time into the current GPS week. \n - - Units: Milliseconds */ + - Units: Milliseconds */ }qmiLocGPSTimeStructT_v02; /* Type */ /** @} @@ -531,19 +533,19 @@ typedef struct { \begin{itemize1} \item Range: 1 (highest accuracy) to 50 (lowest accuracy) \item PDOP = square root of (HDOP^2 + VDOP^2) - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ float HDOP; /**< Horizontal dilution of precision. \begin{itemize1} \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ float VDOP; /**< Vertical dilution of precision. \begin{itemize1} \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocDOPStructT_v02; /* Type */ /** @} @@ -566,11 +568,10 @@ typedef struct { /**< Specifies which sensors were used in calculating the position in the position report. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- SENSOR_USED_ACCEL \item 0x00000002 -- SENSOR_USED_GYRO - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; /**< Specifies which results were aided by sensors. @@ -579,7 +580,7 @@ typedef struct { - 0x00000001 -- AIDED_HEADING \n - 0x00000002 -- AIDED_SPEED \n - 0x00000004 -- AIDED_POSITION \n - - 0x00000008 -- AIDED_VELOCITY */ + - 0x00000008 -- AIDED_VELOCITY */ }qmiLocSensorUsageIndicatorStructT_v02; /* Type */ /** @} @@ -606,9 +607,8 @@ typedef enum { eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ - eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network - Source of the time is unknown */ - eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, + eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network */ + eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, /**< Source of the time is unknown */ QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocTimeSourceEnumT_v02; /** @@ -623,9 +623,8 @@ typedef enum { eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ - eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed - Location reliability is high; strong cross-check passed */ - eQMI_LOC_RELIABILITY_HIGH_V02 = 4, + eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed */ + eQMI_LOC_RELIABILITY_HIGH_V02 = 4, /**< Location reliability is high; strong cross-check passed */ QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocReliabilityEnumT_v02; /** @@ -635,8 +634,7 @@ typedef enum { /** @addtogroup loc_qmi_messages @{ */ -/** Indication Message; This message is used to send the position report to the - control point. */ +/** Indication Message; Sends the position report to the control point. */ typedef struct { /* Mandatory */ @@ -644,8 +642,7 @@ typedef struct { qmiLocSessionStatusEnumT_v02 sessionStatus; /**< Session status. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SESS_STATUS_SUCCESS \item 0x00000001 -- SESS_STATUS_IN_PROGRESS \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE @@ -655,14 +652,14 @@ typedef struct { \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED \vspace{-0.18in} \end{itemize1} - */ + */ /* Mandatory */ /* Session ID */ uint8_t sessionId; /**< ID of the session that was specified in the Start request QMI_LOC_START_REQ. \n - - Range: 0 to 255 */ + - Range: 0 to 255 */ /* Optional */ /* Latitude */ @@ -675,7 +672,7 @@ typedef struct { \item Range: -90.0 to 90.0 \begin{itemize1} \item Positive values indicate northern latitude \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Longitude */ @@ -688,28 +685,28 @@ typedef struct { \item Range: -180.0 to 180.0 \begin{itemize1} \item Positive values indicate eastern longitude \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Circular Horizontal Position Uncertainty */ uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ float horUncEllipseSemiMinor; /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ float horUncEllipseSemiMajor; /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Elliptical Horizontal Uncertainty Azimuth */ @@ -717,7 +714,7 @@ typedef struct { float horUncEllipseOrientAzimuth; /**< Elliptical horizontal uncertainty azimuth of orientation.\n - Units: Decimal degrees \n - - Range: 0 to 180 */ + - Range: 0 to 180 */ /* Optional */ /* Horizontal Confidence */ @@ -725,36 +722,35 @@ typedef struct { uint8_t horConfidence; /**< Horizontal uncertainty confidence.\n - Units: Percent \n - - Range: 0 to 99 */ + - Range: 0 to 99 */ /* Optional */ /* Horizontal Reliability */ uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ qmiLocReliabilityEnumT_v02 horReliability; /**< Specifies the reliability of the horizontal position. \n - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- RELIABILITY_NOT_SET \item 0x00000001 -- RELIABILITY_VERY_LOW \item 0x00000002 -- RELIABILITY_LOW \item 0x00000003 -- RELIABILITY_MEDIUM \item 0x00000004 -- RELIABILITY_HIGH \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Horizontal Speed */ uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ float speedHorizontal; /**< Horizontal speed.\n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Speed Uncertainty */ uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ float speedUnc; /**< 3-D Speed uncertainty.\n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Altitude With Respect to Ellipsoid */ @@ -762,21 +758,21 @@ typedef struct { float altitudeWrtEllipsoid; /**< Altitude with respect to the WGS84 ellipsoid.\n - Units: Meters \n - - Range: -500 to 15883 */ + - Range: -500 to 15883 */ /* Optional */ /* Altitude With Respect to Sea Level */ uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ float altitudeWrtMeanSeaLevel; /**< Altitude with respect to mean sea level.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Vertical Uncertainty */ uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ float vertUnc; /**< Vertical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Vertical Confidence */ @@ -784,28 +780,27 @@ typedef struct { uint8_t vertConfidence; /**< Vertical uncertainty confidence.\n - Units: Percent \n - - Range: 0 to 99 */ + - Range: 0 to 99 */ /* Optional */ /* Vertical Reliability */ uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ qmiLocReliabilityEnumT_v02 vertReliability; /**< Specifies the reliability of the vertical position. \n - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- RELIABILITY_NOT_SET \item 0x00000001 -- RELIABILITY_VERY_LOW \item 0x00000002 -- RELIABILITY_LOW \item 0x00000003 -- RELIABILITY_MEDIUM \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ /* Optional */ /* Vertical Speed */ uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ float speedVertical; /**< Vertical speed.\n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Heading */ @@ -813,7 +808,7 @@ typedef struct { float heading; /**< Heading.\n - Units: Degrees \n - - Range: 0 to 359.999 */ + - Range: 0 to 359.999 */ /* Optional */ /* Heading Uncertainty */ @@ -821,7 +816,7 @@ typedef struct { float headingUnc; /**< Heading uncertainty.\n - Units: Degrees \n - - Range: 0 to 359.999 */ + - Range: 0 to 359.999 */ /* Optional */ /* Magnetic Deviation */ @@ -829,7 +824,7 @@ typedef struct { float magneticDeviation; /**< Difference between the bearing to true north and the bearing shown on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ + north is east of true north. */ /* Optional */ /* Technology Used */ @@ -837,26 +832,27 @@ typedef struct { qmiLocPosTechMaskT_v02 technologyMask; /**< Technology used in computing this fix. - Valid bitmasks: \n - - 0x00000001 -- SATELLITE \n - - 0x00000002 -- CELLID \n - - 0x00000004 -- WIFI \n - - 0x00000008 -- SENSORS \n - - 0x00000010 -- REFERENCE_LOCATION \n - - 0x00000020 -- INJECTED_COARSE_POSITION */ + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Dilution of Precision */ uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ qmiLocDOPStructT_v02 DOP; - /**< \n Dilution of precision associated with this position. */ + /**< \n Dilution of precision associated with this position. */ /* Optional */ /* UTC Timestamp */ uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ uint64_t timestampUtc; /**< UTC timestamp. \n - - Units: Milliseconds since Jan. 1, 1970 */ + - Units: Milliseconds since Jan. 1, 1970 */ /* Optional */ /* Leap Seconds */ @@ -865,21 +861,21 @@ typedef struct { /**< Leap second information. If leapSeconds is not available, timestampUtc is calculated based on a hard-coded value for leap seconds. \n - - Units: Seconds */ + - Units: Seconds */ /* Optional */ /* GPS Time */ uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ qmiLocGPSTimeStructT_v02 gpsTime; /**< \n The number of weeks since Jan. 5, 1980, and - milliseconds into the current week. */ + milliseconds into the current week. */ /* Optional */ /* Time Uncertainty */ uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ float timeUnc; /**< Time uncertainty. \n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Optional */ /* Time Source */ @@ -887,32 +883,31 @@ typedef struct { qmiLocTimeSourceEnumT_v02 timeSrc; /**< Time source. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- TIME_SRC_INVALID \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING - \item 0x00000003 -- TIME_SRC_EXTERNAL_ INPUT + \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT \item 0x00000004 -- TIME_SRC_TOW_DECODE \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED \item 0x00000007 -- TIME_SRC_NAV_SOLUTION \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Sensor Data Usage */ uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; /**< \n Whether sensor data was used in computing the position in this - position report. */ + position report. */ /* Optional */ /* Fix Count for This Session */ uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ uint32_t fixId; /**< Fix count for the session. Starts with 0 and increments by one - for each successive position report for a particular session. */ + for each successive position report for a particular session. */ /* Optional */ /* SVs Used to Calculate the Fix */ @@ -927,7 +922,7 @@ typedef struct { \item For SBAS: 33 to 64 \item For GLONASS: 65 to 96 \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ }qmiLocEventPositionReportIndMsgT_v02; /* Message */ /** @} @@ -941,9 +936,8 @@ typedef enum { eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ - eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. - GLONASS satellite. */ - eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, + eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. */ + eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, /**< GLONASS satellite. */ QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSvSystemEnumT_v02; /** @@ -956,9 +950,8 @@ typedef enum { typedef enum { QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ - eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. - SV is being tracked. */ - eQMI_LOC_SV_STATUS_TRACK_V02 = 3, + eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. */ + eQMI_LOC_SV_STATUS_TRACK_V02 = 3, /**< SV is being tracked. */ QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSvStatusEnumT_v02; /** @@ -985,8 +978,7 @@ typedef struct { qmiLocSvInfoValidMaskT_v02 validMask; /**< Bitmask indicating which of the fields in this TLV are valid. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- VALID_SYSTEM \item 0x00000002 -- VALID_GNSS_SVID \item 0x00000004 -- VALID_HEALTH_STATUS @@ -995,19 +987,18 @@ typedef struct { \item 0x00000020 -- VALID_ELEVATION \item 0x00000040 -- VALID_AZIMUTH \item 0x00000080 -- VALID_SNR - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ qmiLocSvSystemEnumT_v02 system; /**< Indicates to which constellation this SV belongs. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ uint16_t gnssSvId; /**< GNSS SV ID. @@ -1018,13 +1009,13 @@ typedef struct { \item For SBAS: 120 to 151 \end{itemize1} \end{itemize1} - The GPS and GLONASS SVs can be disambiguated using the system field. */ + The GPS and GLONASS SVs can be disambiguated using the system field. */ uint8_t healthStatus; /**< Health status. \begin{itemize1} \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ qmiLocSvStatusEnumT_v02 svStatus; /**< SV processing status. \n @@ -1032,28 +1023,28 @@ typedef struct { - 0x00000001 -- SV_STATUS_IDLE \n - 0x00000002 -- SV_STATUS_SEARCH \n - 0x00000003 -- SV_STATUS_TRACK - */ + */ qmiLocSvInfoMaskT_v02 svInfoMask; /**< Whether almanac and ephemeris information is available. \n Valid bitmasks: \n - 0x01 -- SVINFO_HAS_EPHEMERIS \n - 0x02 -- SVINFO_HAS_ALMANAC - */ + */ float elevation; /**< SV elevation angle.\n - Units: Degrees \n - - Range: 0 to 90 */ + - Range: 0 to 90 */ float azimuth; /**< SV azimuth angle.\n - Units: Degrees \n - - Range: 0 to 360 */ + - Range: 0 to 360 */ float snr; /**< SV signal-to-noise ratio. \n - - Units: dB-Hz */ + - Units: dB-Hz */ }qmiLocSvInfoStructT_v02; /* Type */ /** @} @@ -1062,25 +1053,24 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Indication Message; Used to send a satellite report to the control point. */ +/** Indication Message; Sends a satellite report to the control point. */ typedef struct { /* Mandatory */ /* Altitude Source */ uint8_t altitudeAssumed; - /**< Whether altitude is assumed or calculated: - \begin{itemize1} + /**< Whether altitude is assumed or calculated: \begin{itemize1} \item 0x00 (FALSE) -- Valid altitude is calculated \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be enough satellites to determine precise altitude - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ /* Optional */ /* Satellite Info */ uint8_t svList_valid; /**< Must be set to true if svList is being passed */ uint32_t svList_len; /**< Must be set to # of elements in svList */ qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; - /**< \n SV information list. */ + /**< \n SV information list. */ }qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ /** @} @@ -1089,7 +1079,7 @@ typedef struct { /** @addtogroup loc_qmi_messages @{ */ -/** Indication Message; Used to send NMEA sentences to the control point. */ +/** Indication Message; Sends NMEA sentences to the control point */ typedef struct { /* Mandatory */ @@ -1099,7 +1089,7 @@ typedef struct { \begin{itemize1} \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 201 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ }qmiLocEventNmeaIndMsgT_v02; /* Message */ /** @} @@ -1113,9 +1103,8 @@ typedef enum { eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. - Notify and Verify, and require a response. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, + eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, /**< Notify and Verify, and require a response. */ QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiNotifyVerifyEnumT_v02; /** @@ -1129,9 +1118,8 @@ typedef enum { QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ - eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. - MS-based preferred, but MS-assisted allowed. */ - eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, + eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. */ + eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, /**< MS-based preferred, but MS-assisted allowed. */ QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiVxPosModeEnumT_v02; /** @@ -1151,9 +1139,8 @@ typedef enum { eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ - eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. - Encoding is GSM. */ - eQMI_LOC_NI_VX_GSM_V02 = 9, + eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. */ + eQMI_LOC_NI_VX_GSM_V02 = 9, /**< Encoding is GSM. */ QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; /** @@ -1168,37 +1155,35 @@ typedef struct { uint8_t posQosIncl; /**< Whether quality of service is included:\n - 0x01 (TRUE) -- QoS is included \n - - 0x00 (FALSE) -- QoS is not included */ + - 0x00 (FALSE) -- QoS is not included */ uint8_t posQos; /**< Position QoS timeout. \n - Units: Seconds \n - - Range: 0 to 255 */ + - Range: 0 to 255 */ uint32_t numFixes; - /**< Number of fixes allowed. */ + /**< Number of fixes allowed. */ uint32_t timeBetweenFixes; /**< Time between fixes.\n - - Units: Seconds */ + - Units: Seconds */ qmiLocNiVxPosModeEnumT_v02 posMode; /**< Position mode. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY \item 0x00000002 -- NI_VX_MS_BASED_ONLY \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; /**< VX encoding scheme. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- NI_VX_OCTET \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG \item 0x00000002 -- NI_VX_ASCII @@ -1210,18 +1195,18 @@ typedef struct { \item 0x00000008 -- NI_VX_LATIN \item 0x00000009 -- NI_VX_GSM \vspace{-0.18in} \end{itemize1} - */ + */ uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; /**< Requestor ID. \n - Type: Array of bytes \n - Maximum array length: 200 - */ + */ uint16_t userRespTimerInSeconds; /**< Time to wait for the user to respond. \n - - Units: Seconds */ + - Units: Seconds */ }qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ /** @} @@ -1240,9 +1225,8 @@ typedef enum { eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ - eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. - No position. */ - eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, + eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. */ + eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, /**< No position. */ QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiSuplPosMethodEnumT_v02; /** @@ -1271,9 +1255,8 @@ typedef enum { eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ - eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. - Encoding is GSM default. */ - eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, + eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. */ + eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, /**< Encoding is GSM default. */ QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiDataCodingSchemeEnumT_v02; /** @@ -1292,9 +1275,8 @@ typedef enum { eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ - eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity - SUPL unknown format. */ - eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, + eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity */ + eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, /**< SUPL unknown format. */ QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiSuplFormatEnumType_v02; /** @@ -1309,8 +1291,7 @@ typedef struct { qmiLocNiSuplFormatEnumType_v02 formatType; /**< Format of the formatted string. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- FORMAT_LOGICAL_NAME \item 0x00000001 -- FORMAT_EMAIL_ADDRESS \item 0x00000002 -- FORMAT_MSISDN @@ -1321,14 +1302,14 @@ typedef struct { \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN \vspace{-0.18in} \end{itemize1} - */ + */ uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; /**< Formatted string. \n - Type: Byte array \n - Maximum string length: 64 - */ + */ }qmiLocNiSuplFormattedStringStructT_v02; /* Type */ /** @} @@ -1351,24 +1332,24 @@ typedef struct { - 0x01 -- QOP_HORZ_ACC_VALID \n - 0x02 -- QOP_VER_ACC_VALID \n - 0x04 -- QOP_MAXAGE_VALID \n - - 0x08 -- QOP_DELAY_VALID */ + - 0x08 -- QOP_DELAY_VALID*/ uint8_t horizontalAccuracy; /**< Horizontal accuracy. \n - - Units: Meters */ + - Units: Meters */ uint8_t verticalAccuracy; /**< Vertical accuracy. \n - - Units: Meters */ + - Units: Meters */ uint16_t maxLocAge; /**< Maximum age of the location if the engine sends a previously computed position. \n - - Units: Seconds */ + - Units: Seconds */ uint8_t delay; /**< Delay the server is willing to tolerate for the fix. \n - - Units: Seconds */ + - Units: Seconds */ }qmiLocNiSuplQopStructT_v02; /* Type */ /** @} @@ -1384,10 +1365,10 @@ typedef uint8_t qmiLocServerAddrTypeMaskT_v02; typedef struct { uint32_t addr; - /**< IPV4 address. */ + /**< IPV4 address. */ uint16_t port; - /**< IPV4 port. */ + /**< IPV4 port. */ }qmiLocIpV4AddrStructType_v02; /* Type */ /** @} @@ -1401,10 +1382,10 @@ typedef struct { uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; /**< IPV6 address. \n - Type: Array of unsigned integers \n - - Maximum length of the array: 8 */ + - Maximum length of the array: 8 */ uint32_t port; - /**< IPV6 port. */ + /**< IPV6 port. */ }qmiLocIpV6AddrStructType_v02; /* Type */ /** @} @@ -1422,13 +1403,13 @@ typedef struct { - 0x01 -- IPV4 \n - 0x02 -- IPV6 \n - 0x04 -- URL - */ + */ qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< IPV4 address and port. */ + /**< IPV4 address and port. */ qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< IPV6 address and port. */ + /**< IPV6 address and port. */ char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; /**< URL. @@ -1436,7 +1417,7 @@ typedef struct { \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 256 \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocNiSuplServerInfoStructT_v02; /* Type */ /** @} @@ -1486,8 +1467,7 @@ typedef struct { qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; /**< Indicates which of the following fields are present in this value. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- SUPL_SERVER_INFO \item 0x00000002 -- SUPL_SESSION_ID \item 0x00000004 -- SUPL_HASH @@ -1498,27 +1478,26 @@ typedef struct { \item 0x00000080 -- SUPL_QOP \item 0x00000100 -- SUPL_USER_RESP_TIMER \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; - /**< SUPL server information. */ + /**< SUPL server information. */ uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; /**< SUPL session ID. \n - Type: Array of unsigned integers \n - - Maximum length of the array: 4 */ + - Maximum length of the array: 4 */ uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; /**< Hash for SUPL_INIT; used to validate that the message was not corrupted. \n - Type: Array of unsigned integers \n - - Length of the array: 8 */ + - Length of the array: 8 */ qmiLocNiSuplPosMethodEnumT_v02 posMethod; /**< GPS mode to be used for the fix. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- AGPS_SETASSISTED \item 0x00000002 -- AGPS_SETBASED \item 0x00000003 -- AGPS_SETASSISTED_PREF @@ -1530,14 +1509,13 @@ typedef struct { \item 0x00000009 -- OTDOA \item 0x0000000A -- NO_POSITION \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Data coding scheme applies to both the requestor ID and the client name. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x0000000C -- NI_SS_GERMAN \item 0x0000000D -- NI_SS_ENGLISH \item 0x0000000E -- NI_SS_ITALIAN @@ -1558,22 +1536,22 @@ typedef struct { \item 0x0000001D -- NI_SUPL_UCS2 \item 0x0000001E -- NI_SUPL_GSM_DEFAULT \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiSuplFormattedStringStructT_v02 requestorId; /**< Requestor ID. The encoding scheme for requestor_id is specified in - the dataCodingScheme field. */ + the dataCodingScheme field. */ qmiLocNiSuplFormattedStringStructT_v02 clientName; /**< Client name. The encoding scheme for client_name is specified in - the dataCodingScheme field. */ + the dataCodingScheme field. */ qmiLocNiSuplQopStructT_v02 suplQop; - /**< SUPL QoP. */ + /**< SUPL QoP. */ uint16_t userResponseTimer; /**< Time to wait for the user to respond. \n - - Units: Seconds */ + - Units: Seconds*/ }qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ /** @} @@ -1585,9 +1563,8 @@ typedef struct { typedef enum { QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ - eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. - Initial location. */ - eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. */ + eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, /**< Initial location. */ QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiLocationTypeEnumT_v02; /** @@ -1602,8 +1579,7 @@ typedef struct { qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Identifies the coding scheme of the coded string. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x0000000C -- NI_SS_GERMAN \item 0x0000000D -- NI_SS_ENGLISH \item 0x0000000E -- NI_SS_ITALIAN @@ -1625,13 +1601,13 @@ typedef struct { \item 0x0000001E -- NI_SUPL_GSM_DEFAULT \vspace{-0.18in} \end{itemize1} - */ + */ uint32_t codedString_len; /**< Must be set to # of elements in codedString */ uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; /**< Coded string. \n - Type: Array of bytes \n - - Maximum string length: 20 */ + - Maximum string length: 20 */ }qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ /** @} @@ -1682,8 +1658,7 @@ typedef struct { qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; /**< Fields that are valid in this value. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x0001 -- INVOKE_ID_MASK \item 0x0002 -- DATA_CODING_SCHEME_MASK \item 0x0004 -- NOTIFICATION_TEXT_MASK @@ -1694,17 +1669,16 @@ typedef struct { \item 0x0080 -- SERVICE_TYPE_MASK \item 0x0100 -- USER_RESP_TIMER_MASK \vspace{-0.18in} \end{itemize1} - */ + */ uint8_t invokeId; - /**< Supplementary Services invoke ID. */ + /**< Supplementary Services invoke ID. */ qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; /**< Type of data encoding scheme for the text. Applies to both the notification text and the client address. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x0000000C -- NI_SS_GERMAN \item 0x0000000D -- NI_SS_ENGLISH \item 0x0000000E -- NI_SS_ITALIAN @@ -1725,46 +1699,45 @@ typedef struct { \item 0x0000001D -- NI_SUPL_UCS2 \item 0x0000001E -- NI_SUPL_GSM_DEFAULT \vspace{-0.18in} \end{itemize1} - */ + */ uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; /**< Notification text; the encoding method is specified in dataCodingScheme. \n - Type: Array of bytes \n - - Maximum array length: 64 */ + - Maximum array length: 64 */ uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; /**< Client address; the encoding method is specified in dataCodingScheme. \n - - Maximum array length: 20 */ + - Maximum array length: 20 */ qmiLocNiLocationTypeEnumT_v02 locationType; /**< Location type. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- CURRENT_LOCATION \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION \item 0x00000004 -- INITIAL_LOCATION \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; /**< Requestor ID; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; /**< Codeword string; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ uint8_t lcsServiceTypeId; - /**< Service type ID. */ + /**< Service type ID. */ uint16_t userResponseTimer; /**< Time to wait for the user to respond. \n - - Units: Seconds */ + - Units: Seconds */ }qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ /** @} @@ -1788,16 +1761,15 @@ typedef enum { typedef struct { qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; - /**< Ongoing NI session request; this information is currently not filled. */ + /**< Ongoing NI session request; this information is currently not filled. */ qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- ONGOING_NI_INCOMING_MO \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocNiVxServiceInteractionStructT_v02; /* Type */ /** @} @@ -1832,10 +1804,9 @@ typedef enum { eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot triggered session. */ eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic - triggered session. - The SUPL INIT message indicates a request for an area event triggered session. */ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, /**< The SUPL INIT message indicates a request for an area event + triggered session. */ QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; /** @@ -1859,8 +1830,7 @@ typedef struct { part of the Location ID or Multiple Location IDs parameter in the SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x0001 -- SUPPORTED_NETWORK_WLAN \item 0x0002 -- SUPPORTED_NETWORK_GSM \item 0x0004 -- SUPPORTED_NETWORK_WCDMA @@ -1872,18 +1842,17 @@ typedef struct { \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; /**< Specifies the type of session trigger requested in the SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT \item 0x00000000 -- TRIGGER_TYPE_PERIODIC \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; /**< Specifies which GNSS technologies are allowed as positioning @@ -1896,7 +1865,7 @@ typedef struct { - 0x0008 -- GNSS_SBAS \n - 0x0010 -- GNSS_QZSS \n - 0x0020 -- GNSS_MODERN_GPS - */ + */ }qmiLocNiSuplVer2ExtStructT_v02; /* Type */ /** @} @@ -1913,39 +1882,38 @@ typedef struct { qmiLocNiNotifyVerifyEnumT_v02 notificationType; /**< Type of notification/verification performed. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- NO_NOTIFY_NO_VERIFY \item 0x00000002 -- NOTIFY_ONLY \item 0x00000003 -- ALLOW_NO_RESP \item 0x00000004 -- NOT_ALLOW_NO_RESP \item 0x00000005 -- PRIVACY_OVERRIDE \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Network Initiated Vx Request */ uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; - /**< \n Optional NI Vx request payload. */ + /**< \n Optional NI Vx request payload. */ /* Optional */ /* Network Initiated SUPL Request */ uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; - /**< \n Optional NI SUPL request payload. */ + /**< \n Optional NI SUPL request payload. */ /* Optional */ /* Network Initiated UMTS Control Plane Request */ uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; - /**< \n Optional NI UMTS-CP request payload. */ + /**< \n Optional NI UMTS-CP request payload. */ /* Optional */ /* Network Initiated Service Interaction Request */ uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; - /**< \n Optional NI service interaction payload. */ + /**< \n Optional NI service interaction payload. */ /* Optional */ /* Network Initiated SUPL Version 2 Extension */ @@ -1953,7 +1921,7 @@ typedef struct { qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; /**< \n Optional NI SUPL Version 2 Extension payload. When present, this payload is to be used in conjunction with the SUPL - indication payload. */ + indication payload. */ }qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ /** @} @@ -1969,7 +1937,7 @@ typedef struct { \begin{itemize1} \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocAssistanceServerUrlStructT_v02; /* Type */ /** @} @@ -1983,7 +1951,7 @@ typedef struct { uint32_t delayThreshold; /**< The time server is to be skipped if a one-way delay to the server exceeds this threshold. \n - - Units: Milliseconds */ + - Units: Milliseconds */ uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; @@ -1991,7 +1959,7 @@ typedef struct { information, the list is ordered, the client is to use the first server specified in the list as the primary URL to fetch NTP time, the second one as secondary, and so on. \n - - Maximum server list items: 3 */ + - Maximum server list items: 3 */ }qmiLocTimeServerListStructT_v02; /* Type */ /** @} @@ -2008,7 +1976,7 @@ typedef struct { uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ qmiLocTimeServerListStructT_v02 timeServerInfo; /**< \n Contains information about the time servers recommended by the - location service for NTP time. */ + location service for NTP time. */ }qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ /** @} @@ -2020,10 +1988,10 @@ typedef struct { typedef struct { uint32_t maxFileSizeInBytes; - /**< Maximum allowable predicted orbits file size (in bytes). */ + /**< Maximum allowable predicted orbits file size (in bytes). */ uint32_t maxPartSize; - /**< Maximum allowable predicted orbits file chunk size (in bytes). */ + /**< Maximum allowable predicted orbits file chunk size (in bytes). */ }qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ /** @} @@ -2040,7 +2008,7 @@ typedef struct { must use the first server specified in the list as the primary URL from which to download predicted orbits data, the second one as secondary, and so on. \n - - Maximum number of servers that can be specified: 3 */ + - Maximum number of servers that can be specified: 3 */ }qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ /** @} @@ -2055,14 +2023,14 @@ typedef struct { /* Mandatory */ /* Allowed Sizes */ qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ + /**< \n Maximum part and file size allowed to be injected in the engine. */ /* Optional */ /* Server List */ uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ qmiLocPredictedOrbitsServerListStructT_v02 serverList; /**< \n List of servers that can be used by the client to download - predicted orbits data. */ + predicted orbits data. */ }qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ /** @} @@ -2084,7 +2052,7 @@ typedef struct { \item Range: -90.0 to 90.0 \begin{itemize1} \item Positive values indicate northern latitude \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Mandatory */ /* Longitude */ @@ -2096,13 +2064,13 @@ typedef struct { \item Range: -180.0 to 180.0 \begin{itemize1} \item Positive values indicate eastern longitude \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Mandatory */ /* Circular Horizontal Uncertainty */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ + - Units: Meters */ /* Mandatory */ /* UTC Timestamp */ @@ -2110,7 +2078,7 @@ typedef struct { /**< UTC timestamp. \begin{itemize1} \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ /** @} @@ -2121,9 +2089,8 @@ typedef struct { */ typedef enum { QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. - Location engine is off. */ - eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, + eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. */ + eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, /**< Location engine is off. */ QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocEngineStateEnumT_v02; /** @@ -2144,7 +2111,7 @@ typedef struct { Valid values: \n - 0x00000001 -- ON \n - 0x00000002 -- OFF - */ + */ }qmiLocEventEngineStateIndMsgT_v02; /* Message */ /** @} @@ -2155,9 +2122,8 @@ typedef struct { */ typedef enum { QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. - Location fix session has ended. */ - eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, + eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. */ + eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, /**< Location fix session has ended. */ QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocFixSessionStateEnumT_v02; /** @@ -2178,7 +2144,7 @@ typedef struct { Valid values: \n - 0x00000001 -- STARTED \n - 0x00000002 -- FINISHED - */ + */ /* Optional */ /* Session ID */ @@ -2187,7 +2153,7 @@ typedef struct { /**< ID of the session that was specified in the Start request. This may not be specified for a fix session corresponding to a network-initiated request. \n - - Range: 0 to 255 */ + - Range: 0 to 255 */ }qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ /** @} @@ -2199,9 +2165,8 @@ typedef struct { typedef enum { QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ - eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. - Stop periodic fixes request. */ - eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, + eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. */ + eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, /**< Stop periodic fixes request. */ QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocWifiRequestEnumT_v02; /** @@ -2219,20 +2184,19 @@ typedef struct { qmiLocWifiRequestEnumT_v02 requestType; /**< Request type as specified in qmiWifiRequestEnumT. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES \item 0x00000001 -- START_PERIODIC_KEEP_WARM \item 0x00000002 -- STOP_PERIODIC_FIXES \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Time Between Fixes */ uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ uint16_t tbfInMs; /**< Time between fixes for a periodic request.\n - - Units: Milliseconds */ + - Units: Milliseconds */ }qmiLocEventWifiReqIndMsgT_v02; /* Message */ /** @} @@ -2249,16 +2213,16 @@ typedef struct { samplingFrequency = samplesPerBatch * batchesPerSecond \n - samplesPerBatch must be a non-zero positive value. - */ + samplesPerBatch must be a nonzero positive value. + */ uint16_t batchesPerSecond; /**< Number of sensor-data batches the GNSS location engine is to receive - per second. The rate is specified in integral number of batches per + per second. The rate is specified in an integral number of batches per second (Hz). \n - batchesPerSecond must be a non-zero positive value. - */ + batchesPerSecond must be a nonzero positive value. + */ }qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ /** @} @@ -2273,20 +2237,19 @@ typedef struct { /**< Whether the GNSS location engine is ready to accept data from this sensor. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor data \item 0x00 (FALSE) -- GNSS location engine is not ready to accept sensor data \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; /**< Rate at which the GNSS engine would like the sensor to be sampled. \n The rate is specified in integral number of samples per second (Hz)\n and batches per second. - */ + */ }qmiLocSensorReadyStatusStructT_v02; /* Type */ /** @} @@ -2305,7 +2268,7 @@ typedef struct { qmiLocSensorReadyStatusStructT_v02 accelReady; /**< \n Whether the GNSS location engine is ready to accept accelerometer sensor data. - */ + */ /* Optional */ /* Gyroscope Accept Ready */ @@ -2313,7 +2276,7 @@ typedef struct { qmiLocSensorReadyStatusStructT_v02 gyroReady; /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor data. - */ + */ }qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ /** @} @@ -2332,7 +2295,7 @@ typedef struct { /**< This TLV is sent to registered control points. It is sent by the location engine when it needs to synchronize location engine and control point (sensor processor) times. - This TLV must be echoed back in the Time Sync Inject request. */ + This TLV must be echoed back in the Time Sync Inject request. */ }qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ /** @} @@ -2352,7 +2315,7 @@ typedef struct { \begin{itemize1} \item 0x01 (TRUE) -- Client is to start sending an SPI status stream \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ }qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ /** @} @@ -2363,9 +2326,8 @@ typedef struct { */ typedef enum { QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. - Bring up the WWAN type used for AGNSS connections. */ - eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, + eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. */ + eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, /**< Bring up the WWAN type used for AGNSS connections. */ QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocWWANTypeEnumT_v02; /** @@ -2377,9 +2339,8 @@ typedef enum { */ typedef enum { QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. - Close a connection to the location server. */ - eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, + eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. */ + eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, /**< Close a connection to the location server. */ QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocServerRequestEnumT_v02; /** @@ -2396,7 +2357,7 @@ typedef struct { /* Mandatory */ /* Connection Handle */ uint32_t connHandle; - /**< Identifies a connection across Open and Close request events. */ + /**< Identifies a connection across Open and Close request events. */ /* Mandatory */ /* Request Type */ @@ -2406,18 +2367,18 @@ typedef struct { Valid values: \n - 0x00000001 -- OPEN \n - 0x00000002 -- CLOSE - */ + */ /* Mandatory */ /* WWAN Type */ qmiLocWWANTypeEnumT_v02 wwanType; /**< Identifies the WWAN type for this request. \n - Valid values: - \begin{itemize1} + + Valid values: \begin{itemize1} \item 0x00000000 -- WWAN_TYPE_INTERNET \item 0x00000001 -- WWAN_TYPE_AGNSS \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ /** @} @@ -2429,10 +2390,9 @@ typedef struct { typedef enum { QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ - eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. - An NI Geofence was edited. The control point can query the + eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. */ + eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, /**< An NI Geofence was edited. The control point can query the Geofence to find the its current state. */ - eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiGeofenceOperationEnumT_v02; /** @@ -2450,19 +2410,19 @@ typedef struct { /* Geofence ID */ uint32_t geofenceId; /**< ID of the Geofence for which this - notification was generated. */ + notification was generated. */ /* Mandatory */ /* Operation Type */ qmiLocNiGeofenceOperationEnumT_v02 operationType; - /**< Operation for which this notification was generated. \n - Valid values: - \begin{itemize1} + /**< Operation for which this notification was generated. + + Valid values: \begin{itemize1} \item 0x00000001 -- NI_GEOFENCE_ADDED \item 0x00000002 -- NI_GEOFENCE_DELETED \item 0x00000003 -- NI_GEOFENCE_EDITED \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ /** @} @@ -2478,9 +2438,8 @@ typedef enum { eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can be used to monitor Geofences. */ eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage - information is available. - The engine has an invalid time. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, + information is available. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, /**< The engine has an invalid time. */ QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceGenAlertEnumT_v02; /** @@ -2497,15 +2456,15 @@ typedef struct { /* Mandatory */ /* Geofence General Alert */ qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; - /**< Specifies the Geofence general alert type. \n - Valid values: - \begin{itemize1} + /**< Specifies the Geofence general alert type. + + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ /** @} @@ -2516,9 +2475,8 @@ typedef struct { */ typedef enum { QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. - Denotes that a client left the Geofence. */ - eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, + eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. */ + eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, /**< Denotes that a client left the Geofence. */ QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceBreachTypeEnumT_v02; /** @@ -2535,7 +2493,7 @@ typedef struct { /**< UTC timestamp. \begin{itemize1} \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Latitude */ double latitude; @@ -2546,7 +2504,7 @@ typedef struct { \item Range: -90.0 to 90.0 \begin{itemize1} \item Positive values indicate northern latitude \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Longitude */ double longitude; @@ -2557,23 +2515,23 @@ typedef struct { \item Range: -180.0 to 180.0 \begin{itemize1} \item Positive values indicate eastern longitude \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ float horUncEllipseSemiMinor; /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ float horUncEllipseSemiMajor; /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Elliptical Horizontal Uncertainty Azimuth */ float horUncEllipseOrientAzimuth; /**< Elliptical horizontal uncertainty azimuth of orientation.\n - Units: Decimal degrees \n - - Range: 0 to 180 */ + - Range: 0 to 180 */ /* Horizontal Speed validity bit */ uint8_t speedHorizontal_valid; @@ -2583,12 +2541,12 @@ typedef struct { \item 0x01 (TRUE) -- Horizontal speed is valid \item 0x00 (FALSE) -- Horizontal speed is invalid and is to be ignored - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Horizontal Speed */ float speedHorizontal; /**< Horizontal speed.\n - - Units: Meters/second */ + - Units: Meters/second */ /* Altitude validity bit */ uint8_t altitudeWrtEllipsoid_valid; @@ -2599,13 +2557,13 @@ typedef struct { \item 0x00 (FALSE) -- Altitude field is invalid and is to be ignored \vspace{-0.18in} \end{itemize1} - */ + */ /* Altitude With Respect to Ellipsoid */ float altitudeWrtEllipsoid; /**< Altitude with respect to the WGS84 ellipsoid.\n - Units: Meters \n - - Range: -500 to 15883 */ + - Range: -500 to 15883 */ /* Vertical Uncertainty validity bit */ uint8_t vertUnc_valid; @@ -2615,12 +2573,12 @@ typedef struct { \item 0x01 (TRUE) -- Vertical Uncertainty field is valid \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid and is to be ignored - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Vertical Uncertainty */ float vertUnc; /**< Vertical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Vertical Speed validity bit */ uint8_t speedVertical_valid; @@ -2630,12 +2588,12 @@ typedef struct { \item 0x01 (TRUE) -- Vertical Speed field is valid \item 0x00 (FALSE) -- Vertical Speed field is invalid and is to be ignored - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Vertical Speed */ float speedVertical; /**< Vertical speed.\n - - Units: Meters/second */ + - Units: Meters/second */ /* heading validity bit */ uint8_t heading_valid; @@ -2645,13 +2603,13 @@ typedef struct { \item 0x01 (TRUE) -- Heading field is valid \item 0x00 (FALSE) -- Heading field is invalid and is to be ignored - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Heading */ float heading; /**< Heading.\n - Units: Degrees \n - - Range: 0 to 359.999 */ + - Range: 0 to 359.999 */ }qmiLocGeofencePositionStructT_v02; /* Type */ /** @} @@ -2668,19 +2626,18 @@ typedef struct { /* Geofence ID */ uint32_t geofenceId; /**< ID of the Geofence for which this - notification was generated. */ + notification was generated. */ /* Mandatory */ /* Geofence Breach Type */ qmiLocGeofenceBreachTypeEnumT_v02 breachType; /**< The type of breach that generated this event. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Geofence Position */ @@ -2690,7 +2647,7 @@ typedef struct { This TLV is included if the client configures the Geofence to report position. The position is reported at the same confidence level that was specified in the - Add Circular Geofence request. */ + Add Circular Geofence request. */ }qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ /** @} @@ -2708,10 +2665,9 @@ typedef enum { eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ - eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested - Request failed because the engine could not allocate sufficent + eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested */ + eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, /**< Request failed because the engine could not allocate sufficent memory for the request. */ - eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocStatusEnumT_v02; /** @@ -2735,8 +2691,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Revision request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -2745,14 +2700,14 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Mandatory */ /* Interface Definition Minor Revision */ uint32_t revision; /**< Revision of the service. This is the minor revision of the interface that the service implements. Minor revision updates of the service are always - backward compatible. */ + backward compatible. */ /* Optional */ /* GNSS Measurement Engine Firmware Version String */ @@ -2766,7 +2721,7 @@ typedef struct { \textbf{Note:} This string is only provided on platforms that have a measurement engine that supports this version string. On all other - platforms, this optional TLV is not provided. */ + platforms, this optional TLV is not provided. */ /* Optional */ /* GNSS Hosted Software Version String */ @@ -2781,7 +2736,7 @@ typedef struct { \textbf{Note:} This string is only provided on hosted architectures (measurement and position engine running on different processors) that support this version string. On all other platforms, this optional TLV - is not provided. */ + is not provided. */ /* Optional */ /* GNSS Software Version String */ @@ -2791,7 +2746,7 @@ typedef struct { \begin{itemize1} \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ /** @} @@ -2814,8 +2769,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Fix Criteria request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -2824,7 +2778,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Horizontal Accuracy */ @@ -2832,13 +2786,12 @@ typedef struct { qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; /**< Horizontal accuracy level. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- LOW: Client requires low horizontal accuracy \item 0x00000002 -- MED: Client requires medium horizontal accuracy \item 0x00000003 -- HIGH: Client requires high horizontal accuracy \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Enable/Disable Intermediate Fixes */ @@ -2850,28 +2803,28 @@ typedef struct { generated at \n 1 Hz and are ON by default. If intermediate reports are turned ON, the client receives position reports even if the accuracy criteria is not met. The status in the position report is - set to IN_PROGRESS for intermediate reports. \n - Valid values: - \begin{itemize1} + set to IN_PROGRESS for intermediate reports. + + Valid values: \begin{itemize1} \item 0x00000001 -- ON: Client is interested in receiving intermediate reports \item 0x00000002 -- OFF: Client is not interested in receiving intermediate reports \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Minimum Interval Between Fixes */ uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ uint32_t minInterval; /**< Time that must elapse before alerting the client. \n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Optional */ /* ID of the Application that Sent the Position Request */ uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version. */ + /**< \n Application provider, name, and version.*/ }qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ /** @} @@ -2883,9 +2836,8 @@ typedef struct { typedef enum { QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. - User did not respond to notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, /**< User did not respond to notify verify request. */ QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocNiUserRespEnumT_v02; /** @@ -2904,58 +2856,56 @@ typedef struct { qmiLocNiUserRespEnumT_v02 userResp; /**< User accepted or denied. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT \item 0x00000002 -- NOTIFY_VERIFY_DENY \item 0x00000003 -- NOTIFY_VERIFY_NORESP \vspace{-0.18in} \end{itemize1} - */ + */ /* Mandatory */ /* Notification Type */ qmiLocNiNotifyVerifyEnumT_v02 notificationType; /**< Type of notification/verification performed. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- NO_NOTIFY_NO_VERIF \item 0x00000002 -- NOTIFY_ONLY \item 0x00000003 -- ALLOW_NO_RESP \item 0x00000004 -- NOT_ALLOW_NO_RESP \item 0x00000005 -- PRIVACY_OVERRIDE \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Network Initiated Vx Request */ uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; - /**< \n Optional NI VX request payload. */ + /**< \n Optional NI VX request payload. */ /* Optional */ /* Network Initiated SUPL Request */ uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; - /**< \n Optional NI SUPL request payload. */ + /**< \n Optional NI SUPL request payload. */ /* Optional */ /* Network Initiated UMTS Control Plane Request */ uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; - /**< \n Optional NI UMTS-CP request payload. */ + /**< \n Optional NI UMTS-CP request payload. */ /* Optional */ /* Network Initiated Service Interaction Request */ uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; - /**< \n Optional NI service interaction payload. */ + /**< \n Optional NI service interaction payload. */ /* Optional */ /* Network Initiated SUPL Version 2 Extension */ uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; - /**< \n Optional SUPL Version 2 Extension payload. */ + /**< \n Optional SUPL Version 2 Extension payload. */ }qmiLocNiUserRespReqMsgT_v02; /* Message */ /** @} @@ -2973,8 +2923,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the NI User Response request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -2983,7 +2932,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocNiUserRespIndMsgT_v02; /* Message */ /** @} @@ -3011,18 +2960,18 @@ typedef struct { /* Total Size */ uint32_t totalSize; /**< Total size of the predicted orbits data to be injected. \n - - Units: Bytes */ + - Units: Bytes */ /* Mandatory */ /* Total Parts */ uint16_t totalParts; /**< Total number of parts into which the predicted orbits data is - divided. */ + divided. */ /* Mandatory */ /* Part Number */ uint16_t partNum; - /**< Number of the current predicted orbits data part; starts at 1. */ + /**< Number of the current predicted orbits data part; starts at 1. */ /* Mandatory */ /* Data */ @@ -3031,7 +2980,7 @@ typedef struct { /**< Predicted orbits data. \n - Type: Array of bytes \n - Maximum length of the array: 1024 - */ + */ /* Optional */ /* Format Type */ @@ -3039,11 +2988,10 @@ typedef struct { qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; /**< Predicted orbits data format. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- PREDICTED_ORBITS_XTRA \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ /** @} @@ -3060,8 +3008,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Data Injection request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3070,14 +3017,14 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Part Number */ uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ uint16_t partNum; /**< Number of the predicted orbits data part for which this indication - is sent; starts at 1. */ + is sent; starts at 1. */ }qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ /** @} @@ -3100,8 +3047,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the query request for a predicted orbits data source. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3110,20 +3056,20 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Allowed Sizes */ uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ + /**< \n Maximum part and file size allowed to be injected in the engine. */ /* Optional */ /* Server List */ uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ qmiLocPredictedOrbitsServerListStructT_v02 serverList; /**< \n List of servers that can be used by the client to download - predicted orbits data. */ + predicted orbits data. */ }qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ /** @} @@ -3143,12 +3089,12 @@ typedef struct { uint64_t startTimeInUTC; /**< Predicted orbits data is valid starting from this time. \n - Units: Seconds (since Jan. 1, 1970) - */ + */ uint16_t durationHours; /**< Duration from the start time for which the data is valid.\n - Units: Hours - */ + */ }qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ /** @} @@ -3165,8 +3111,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the query request for predicted orbits data validity. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3175,7 +3120,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Validity Info */ @@ -3196,13 +3141,13 @@ typedef struct { /* UTC Time */ uint64_t timeUtc; /**< UTC time since Jan. 1, 1970.\n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Mandatory */ /* Time Uncertainty */ uint32_t timeUnc; /**< Time uncertainty.\n - - Units: Milliseconds */ + - Units: Milliseconds */ }qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ /** @} @@ -3219,8 +3164,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the UTC Time Injection request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3229,7 +3173,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ /** @} @@ -3248,9 +3192,8 @@ typedef enum { eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ - eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. - Other sources. */ - eQMI_LOC_ALT_SRC_OTHER_V02 = 9, + eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. */ + eQMI_LOC_ALT_SRC_OTHER_V02 = 9, /**< Other sources. */ QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocAltSrcEnumT_v02; /** @@ -3264,9 +3207,8 @@ typedef enum { QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ - eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. - Fully independent. */ - eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, + eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, /**< Fully independent. */ QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocAltSrcLinkageEnumT_v02; /** @@ -3280,11 +3222,10 @@ typedef enum { QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal - position coordinates only. - Altitude uncertainty applies to the position of the device + position coordinates only. */ + eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, /**< Altitude uncertainty applies to the position of the device regardless of horizontal position (within the horizontal uncertainty region, if provided). */ - eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocAltSrcUncertaintyCoverageEnumT_v02; /** @@ -3299,8 +3240,7 @@ typedef struct { qmiLocAltSrcEnumT_v02 source; /**< Specifies the source of the altitude. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- ALT_SRC_UNKNOWN \item 0x00000001 -- ALT_SRC_GPS \item 0x00000002 -- ALT_SRC_CELL_ID @@ -3312,26 +3252,24 @@ typedef struct { \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER \item 0x00000009 -- ALT_SRC_OTHER \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocAltSrcLinkageEnumT_v02 linkage; /**< Specifies the dependency between the horizontal and altitude position components. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; /**< Specifies the region of uncertainty. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid at the injected horizontal position coordinates @@ -3341,7 +3279,7 @@ typedef struct { horizontal position (within the horizontal uncertainty region, if provided). \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocAltitudeSrcInfoStructT_v02; /* Type */ /** @} @@ -3357,9 +3295,8 @@ typedef enum { eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ - eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. - Other sources. */ - eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, + eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. */ + eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, /**< Other sources. */ QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocPositionSrcEnumT_v02; /** @@ -3384,7 +3321,7 @@ typedef struct { \item Positive values indicate northern latitude \item Negative values indicate southern latitude \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ + */ /* Optional */ /* Longitude */ @@ -3398,14 +3335,14 @@ typedef struct { \item Positive values indicate eastern longitude \item Negative values indicate western longitude \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ + */ /* Optional */ /* Circular Horizontal Uncertainty */ uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Horizontal Confidence */ @@ -3419,7 +3356,7 @@ typedef struct { \item If 100 is received, reinterpret to 99 \end{itemize1} This field must be specified together with horizontal uncertainty. - If not specified, the default value will be 50. */ + If not specified, the default value will be 50. */ /* Optional */ /* Horizontal Reliability */ @@ -3427,15 +3364,14 @@ typedef struct { qmiLocReliabilityEnumT_v02 horReliability; /**< Specifies the reliability of the horizontal position. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Altitude With Respect to Ellipsoid */ @@ -3446,14 +3382,14 @@ typedef struct { \item Units: Meters \begin{itemize1} \item Positive = height \item Negative = depth - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1}*/ /* Optional */ /* Altitude With Respect to Sea Level */ uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ float altitudeWrtMeanSeaLevel; /**< Altitude with respect to mean sea level.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Vertical Uncertainty */ @@ -3461,7 +3397,7 @@ typedef struct { float vertUnc; /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid or altitudeWrtMeanSeaLevel is specified.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Vertical Confidence */ @@ -3475,7 +3411,7 @@ typedef struct { \item If 100 is received, reinterpret to 99 \end{itemize1} This field must be specified together with the vertical uncertainty. - If not specified, the default value will be 50. */ + If not specified, the default value will be 50. */ /* Optional */ /* Vertical Reliability */ @@ -3483,43 +3419,42 @@ typedef struct { qmiLocReliabilityEnumT_v02 vertReliability; /**< Specifies the reliability of the vertical position. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Altitude Source Info */ uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; - /**< \n Specifies information regarding the altitude source. */ + /**< \n Specifies information regarding the altitude source. */ /* Optional */ /* UTC Timestamp */ uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ uint64_t timestampUtc; /**< UTC timestamp. \n - - Units: Milliseconds (since Jan. 1, 1970) */ + - Units: Milliseconds (since Jan. 1, 1970) */ /* Optional */ /* Position Age */ uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ int32_t timestampAge; /**< Position age, which is an estimate of how long ago this fix was made. \n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Optional */ /* Position Source */ uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ qmiLocPositionSrcEnumT_v02 positionSrc; - /**< Source from which this position was obtained. \n - Valid values: - \begin{itemize1} + /**< Source from which this position was obtained. + + Valid values: \begin{itemize1} \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID @@ -3528,12 +3463,13 @@ typedef struct { \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER \end{itemize1} \vspace{0.05in} + If altitude is specified and the altitude source is not specified, the engine assumes that the altitude was obtained using the specified position source. \n If both altitude and altitude source are specified, the engine assumes that only latitude and longitude were obtained using the specified position source. - */ + */ }qmiLocInjectPositionReqMsgT_v02; /* Message */ /** @} @@ -3550,8 +3486,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the UTC Position Injection request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3560,7 +3495,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectPositionIndMsgT_v02; /* Message */ /** @} @@ -3573,9 +3508,8 @@ typedef enum { QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ - eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. - Lock all position sessions. */ - eQMI_LOC_LOCK_ALL_V02 = 4, + eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. */ + eQMI_LOC_LOCK_ALL_V02 = 4, /**< Lock all position sessions. */ QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocLockEnumT_v02; /** @@ -3599,7 +3533,7 @@ typedef struct { - 0x00000003 -- LOCK_MT \n - 0x00000004 -- LOCK_ALL - */ + */ }qmiLocSetEngineLockReqMsgT_v02; /* Message */ /** @} @@ -3616,8 +3550,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Engine Lock request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3626,7 +3559,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetEngineLockIndMsgT_v02; /* Message */ /** @} @@ -3649,8 +3582,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Engine Lock request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3659,7 +3591,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Lock Type */ @@ -3672,7 +3604,7 @@ typedef struct { - 0x00000002 -- LOCK_MI \n - 0x00000003 -- LOCK_MT \n - 0x00000004 -- LOCK_ALL - */ + */ }qmiLocGetEngineLockIndMsgT_v02; /* Message */ /** @} @@ -3691,7 +3623,7 @@ typedef struct { \begin{itemize1} \item 0x01 (TRUE) -- SBAS configuration is enabled \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ }qmiLocSetSbasConfigReqMsgT_v02; /* Message */ /** @} @@ -3708,8 +3640,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set SBAS Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3718,7 +3649,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSbasConfigIndMsgT_v02; /* Message */ /** @} @@ -3741,8 +3672,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get SBAS Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3751,7 +3681,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* SBAS Config */ @@ -3761,7 +3691,7 @@ typedef struct { \begin{itemize1} \item 0x01 (TRUE) -- SBAS configuration is enabled \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ }qmiLocGetSbasConfigIndMsgT_v02; /* Message */ /** @} @@ -3794,7 +3724,7 @@ typedef struct { - 0x00000010 -- NMEA_MASK_VTG \n - 0x00000020 -- NMEA_MASK_PQXFI \n - 0x00000040 -- NMEA_MASK_PSTIS - */ + */ }qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ /** @} @@ -3811,8 +3741,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of Set NMEA Types request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3821,7 +3750,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ /** @} @@ -3844,8 +3773,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get NMEA Types request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3854,7 +3782,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* NMEA Sentence Types */ @@ -3871,7 +3799,7 @@ typedef struct { - 0x00000010 -- NMEA_MASK_VTG \n - 0x00000020 -- NMEA_MASK_PQXFI \n - 0x00000040 -- NMEA_MASK_PSTIS - */ + */ }qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ /** @} @@ -3888,7 +3816,7 @@ typedef struct { uint8_t lowPowerMode; /**< Whether to enable Low Power mode:\n - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ + - 0x00 (FALSE) -- Disable LPM */ }qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ /** @} @@ -3905,8 +3833,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Low Power Mode request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3915,7 +3842,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ /** @} @@ -3938,8 +3865,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get LPM request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -3948,7 +3874,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Enable/Disable LPM */ @@ -3956,7 +3882,7 @@ typedef struct { uint8_t lowPowerMode; /**< Whether to enable Low Power mode:\n - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ + - 0x00 (FALSE) -- Disable LPM */ }qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ /** @} @@ -3969,9 +3895,8 @@ typedef enum { QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ - eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. - Server type is custom PDE. */ - eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, + eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. */ + eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, /**< Server type is custom PDE. */ QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocServerTypeEnumT_v02; /** @@ -3994,19 +3919,19 @@ typedef struct { - 0x00000002 -- CDMA_MPC \n - 0x00000003 -- UMTS_SLP \n - 0x00000004 -- CUSTOM_PDE - */ + */ /* Optional */ /* IPV4 Address */ uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ + /**< \n IPV4 address and port. */ /* Optional */ /* IPV6 Address */ uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ + /**< \n IPV6 address and port. */ /* Optional */ /* Uniform Resource Locator */ @@ -4017,7 +3942,7 @@ typedef struct { \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 256 \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetServerReqMsgT_v02; /* Message */ /** @} @@ -4034,8 +3959,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Server request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4044,7 +3968,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetServerIndMsgT_v02; /* Message */ /** @} @@ -4066,7 +3990,7 @@ typedef struct { - 0x00000002 -- CDMA_MPC \n - 0x00000003 -- UMTS_SLP \n - 0x00000004 -- CUSTOM_PDE - */ + */ /* Optional */ /* Server Address Type */ @@ -4080,7 +4004,7 @@ typedef struct { - 0x01 -- IPV4 \n - 0x02 -- IPV6 \n - 0x04 -- URL - */ + */ }qmiLocGetServerReqMsgT_v02; /* Message */ /** @} @@ -4097,8 +4021,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Server request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4107,7 +4030,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Mandatory */ /* Server Type */ @@ -4119,19 +4042,19 @@ typedef struct { - 0x00000002 -- CDMA_MPC \n - 0x00000003 -- UMTS_SLP \n - 0x00000004 -- CUSTOM_PDE - */ + */ /* Optional */ /* IPV4 Address */ uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ + /**< \n IPV4 address and port. */ /* Optional */ /* IPV6 Address */ uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ + /**< \n IPV6 address and port. */ /* Optional */ /* Uniform Resource Locator */ @@ -4142,7 +4065,7 @@ typedef struct { \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 256 \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetServerIndMsgT_v02; /* Message */ /** @} @@ -4206,20 +4129,19 @@ typedef struct { \item For GPS: 1 to 32 \item For SBAS: 33 to 64 \item For GLONASS: 65 to 96 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ qmiLocSvSystemEnumT_v02 system; /**< Indicates to which constellation this SV belongs. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS \vspace{-0.18in} \end{itemize1} - */ + */ qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; /**< Indicates if the ephemeris or almanac for a satellite @@ -4227,7 +4149,7 @@ typedef struct { Valid values: \n - 0x01 -- DELETE_EPHEMERIS \n - 0x02 -- DELETE_ALMANAC - */ + */ }qmiLocDeleteSvInfoStructT_v02; /* Type */ /** @} @@ -4245,15 +4167,14 @@ typedef struct { uint8_t deleteAllFlag; /**< Whether all assistance data is to be deleted. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- All assistance data is to be deleted; if this flag is set, all the other information contained in the optional fields for this message are ignored \item 0x00 (FALSE) -- The optional fields in the message are to be used to determine which data is to be deleted - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Delete SV Info */ @@ -4261,7 +4182,7 @@ typedef struct { uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; /**< \n List of satellites for which the assistance data is to be deleted. - */ + */ /* Optional */ /* Delete GNSS Data */ @@ -4269,8 +4190,7 @@ typedef struct { qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; /**< Mask for the GNSS data that is to be deleted. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- DELETE_GPS_SVDIR \item 0x00000002 -- DELETE_GPS_SVSTEER \item 0x00000004 -- DELETE_GPS_TIME @@ -4291,7 +4211,7 @@ typedef struct { \item 0x00020000 -- DELETE_SV_NO_EXIST \item 0x00040000 -- DELETE_FREQ_BIAS_EST \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Delete Cell Database */ @@ -4299,8 +4219,7 @@ typedef struct { qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; /**< Mask for the cell database assistance data that is to be deleted. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- DELETE_CELLDB_POS \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS \item 0x00000004 -- DELETE_CELLDB_OTA_POS @@ -4312,7 +4231,7 @@ typedef struct { \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Delete Clock Info */ @@ -4320,8 +4239,7 @@ typedef struct { qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; /**< Mask for the clock information assistance data that is to be deleted. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER @@ -4334,7 +4252,7 @@ typedef struct { \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ /** @} @@ -4352,8 +4270,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Delete Assist Data request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4362,7 +4279,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ /** @} @@ -4379,7 +4296,7 @@ typedef struct { uint8_t xtraTSessionControl; /**< Whether to enable XTRA-T:\n - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ + - 0x00 (FALSE) -- Disable XTRA-T */ }qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ /** @} @@ -4396,8 +4313,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set XTRA-T Session Control request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4406,7 +4322,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ /** @} @@ -4430,8 +4346,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get XTRA-T Session Control request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4440,7 +4355,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Enable/Disable XTRA-T */ @@ -4448,7 +4363,7 @@ typedef struct { uint8_t xtraTSessionControl; /**< Whether to enable XTRA-T:\n - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ + - 0x00 (FALSE) -- Disable XTRA-T */ }qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ /** @} @@ -4462,7 +4377,7 @@ typedef struct { uint32_t wifiPositionTime; /**< Common counter (typically, the number of milliseconds since bootup). This field is only to be provided if the modem and host processors are - synchronized. */ + synchronized. */ }qmiLocWifiFixTimeStructT_v02; /* Type */ /** @} @@ -4480,9 +4395,8 @@ typedef enum { code. */ eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. - This may be because the APs found are not in the database. - WiFi fix failed, but the cause could not be determined. */ - eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, + This may be because the APs found are not in the database. */ + eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, /**< WiFi fix failed, but the cause could not be determined. */ QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocWifiFixErrorCodeEnumT_v02; /** @@ -4497,19 +4411,19 @@ typedef struct { double lat; /**< WiFi position latitude. \n - Type: Floating point \n - - Units: Degrees */ + - Units: Degrees */ double lon; /**< WiFi position longitude. \n - Type: Floating point \n - - Units: Degrees */ + - Units: Degrees */ uint16_t hepe; /**< WiFi position HEPE.\n - - Units: Meters */ + - Units: Meters */ uint8_t numApsUsed; - /**< Number of Access Points (AP) used to generate a fix. */ + /**< Number of Access Points (AP) used to generate a fix. */ qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; /**< WiFi position error code; set to 0 if the fix succeeds. This position @@ -4517,8 +4431,7 @@ typedef struct { the error code provided by the WiFi positioning system can be provided here. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- ERROR_SUCCESS \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE \item 0x00000002 -- ERROR_NO_AP_FOUND @@ -4527,7 +4440,7 @@ typedef struct { \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED \item 0x00000006 -- ERROR_UNKNOWN \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocWifiFixPosStructT_v02; /* Type */ /** @} @@ -4547,14 +4460,14 @@ typedef struct { /**< Associated MAC address of the AP. \n - Type: Array of unsigned integers \n - Address length: 6 - */ + */ int32_t rssi; /**< Receive signal strength indicator.\n - - Units: dBm (offset with +100 dB) */ + - Units: dBm (offset with +100 dB) */ uint16_t channel; - /**< WiFi channel on which a beacon was received. */ + /**< WiFi channel on which a beacon was received. */ qmiLocWifiApQualifierMaskT_v02 apQualifier; /**< A bitmask of Boolean qualifiers for APs. @@ -4565,7 +4478,7 @@ typedef struct { - 0x02 -- HIDDEN_SSID \n - 0x04 -- PRIVATE \n - 0x08 -- INFRASTRUCTURE_MODE - */ + */ }qmiLocWifiApInfoStructT_v02; /* Type */ /** @} @@ -4581,20 +4494,20 @@ typedef struct { /* WiFi Fix Time */ uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ qmiLocWifiFixTimeStructT_v02 wifiFixTime; - /**< \n Time of WiFi position fix. */ + /**< \n Time of WiFi position fix. */ /* Optional */ /* WiFi Position */ uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ qmiLocWifiFixPosStructT_v02 wifiFixPosition; - /**< \n WiFi position fix. */ + /**< \n WiFi position fix. */ /* Optional */ /* WiFi Access Point Information */ uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; - /**< \n AP scan list. */ + /**< \n AP scan list. */ /* Optional */ /* Horizontal Reliability */ @@ -4602,15 +4515,14 @@ typedef struct { qmiLocReliabilityEnumT_v02 horizontalReliability; /**< Specifies the reliability of the horizontal position. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ /** @} @@ -4627,8 +4539,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject WiFi Position request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4637,7 +4548,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ /** @} @@ -4648,9 +4559,8 @@ typedef struct { */ typedef enum { QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. - WiFi is not available. */ - eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, + eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. */ + eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, /**< WiFi is not available. */ QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocWifiStatusEnumT_v02; /** @@ -4668,12 +4578,11 @@ typedef struct { qmiLocWifiStatusEnumT_v02 wifiStatus; /**< WiFi status information. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- WIFI_STATUS_AVAILABLE \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ /** @} @@ -4690,8 +4599,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Notify WiFi Status request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4700,7 +4608,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ /** @} @@ -4724,8 +4632,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Registered Events request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4734,7 +4641,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Event Registration Mask */ @@ -4742,8 +4649,7 @@ typedef struct { qmiLocEventRegMaskT_v02 eventRegMask; /**< Event registration mask. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- POSITION_REPORT \item 0x00000002 -- GNSS_SV_INFO \item 0x00000004 -- NMEA @@ -4759,7 +4665,7 @@ typedef struct { \item 0x00001000 -- SET_SPI_STREAMING_REPORT \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ /** @} @@ -4774,11 +4680,10 @@ typedef enum { eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ - eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for GSM/UMTS network - Use WWAN measurements to calculate position. If this mode is - set then for 1x network AFLT will used and for LTE network - OTDOA will used. */ - eQMI_LOC_OPER_MODE_WWAN_V02 = 6, + eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for a GSM/UMTS network. */ + eQMI_LOC_OPER_MODE_WWAN_V02 = 6, /**< Use WWAN measurements to calculate the position. If this mode is + set, AFLT will be used for 1x networks and OTDOA will be used + for LTE networks. */ QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocOperationModeEnumT_v02; /** @@ -4797,9 +4702,9 @@ typedef struct { /* Operation Mode */ qmiLocOperationModeEnumT_v02 operationMode; /**< Preferred operation mode. + \label{operationMode} - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- OPER_MODE_DEFAULT \item 0x00000002 -- OPER_MODE_MSB \item 0x00000003 -- OPER_MODE_MSA @@ -4807,7 +4712,7 @@ typedef struct { \item 0x00000005 -- OPER_MODE_CELL_ID \item 0x00000006 -- OPER_MODE_WWAN \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetOperationModeReqMsgT_v02; /* Message */ /** @} @@ -4826,8 +4731,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Operation Mode request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4836,7 +4740,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetOperationModeIndMsgT_v02; /* Message */ /** @} @@ -4859,8 +4763,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Operation Mode request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4869,7 +4772,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Operation Mode */ @@ -4877,8 +4780,7 @@ typedef struct { qmiLocOperationModeEnumT_v02 operationMode; /**< Current operation mode. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- OPER_MODE_DEFAULT \item 0x00000002 -- OPER_MODE_MSB \item 0x00000003 -- OPER_MODE_MSA @@ -4886,7 +4788,7 @@ typedef struct { \item 0x00000005 -- OPER_MODE_CELL_ID \item 0x00000006 -- OPER_MODE_WWAN \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetOperationModeIndMsgT_v02; /* Message */ /** @} @@ -4906,14 +4808,14 @@ typedef struct { \begin{itemize1} \item 0x00 (FALSE) -- Device is not stationary \item 0x01 (TRUE) -- Device is stationary - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ /* Optional */ /* Confidence */ uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ uint8_t confidenceStationary; /**< Confidence in the Stationary state expressed as a percentage.\n - - Range: 0 to 100 */ + - Range: 0 to 100 */ }qmiLocSetSpiStatusReqMsgT_v02; /* Message */ /** @} @@ -4931,8 +4833,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the SPI Status request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -4941,7 +4842,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSpiStatusIndMsgT_v02; /* Message */ /** @} @@ -4960,22 +4861,22 @@ typedef struct { uint16_t timeOffset; /**< Sample time offset. This time offset must be relative to the sensor time of the first sample.\n - - Units: Milliseconds */ + - Units: Milliseconds */ float xAxis; /**< Sensor x-axis sample. \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds) ) */ float yAxis; /**< Sensor y-axis sample. \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds) ) */ float zAxis; /**< Sensor z-axis sample. \n - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds^2) ) */ + - Units Gyroscope: ( (rads)/(seconds) ) */ }qmiLoc3AxisSensorSampleStructT_v02; /* Type */ /** @} @@ -4989,21 +4890,21 @@ typedef struct { uint32_t timeOfFirstSample; /**< Denotes a full 32-bit time tag of the first (oldest) sample in this message. \n - - Units: Milliseconds */ + - Units: Milliseconds */ qmiLocSensorDataFlagMaskT_v02 flags; /**< Flags to indicate any deviation from the default measurement assumptions. All unused bits in this field must be set to 0. - Valid bitmasks: \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x01 -- SIGN_REVERSAL \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; /**< Variable length array to specify sensor samples. \n - - Maximum length of the array: 50 */ + - Maximum length of the array: 50 */ }qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ /** @} @@ -5022,19 +4923,19 @@ typedef struct { uint32_t opaqueIdentifier; /**< An opaque identifier that is sent in by the client that will be echoed in the indication so the client can relate the indication to the - request. */ + request. */ /* Optional */ /* 3-Axis Accelerometer Data */ uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; - /**< \n Accelerometer sensor samples. */ + /**< \n Accelerometer sensor samples. */ /* Optional */ /* 3-Axis Gyroscope Data */ uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; - /**< \n Gyroscope sensor samples. */ + /**< \n Gyroscope sensor samples. */ }qmiLocInjectSensorDataReqMsgT_v02; /* Message */ /** @} @@ -5052,8 +4953,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject Sensor Data request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5062,28 +4962,28 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Opaque Identifier */ uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ uint32_t opaqueIdentifier; /**< Opaque identifier that was sent in by the client echoed - so the client can relate the indication to the request. */ + so the client can relate the indication to the request. */ /* Optional */ /* Accelerometer Samples Accepted */ uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ uint8_t threeAxisAccelSamplesAccepted; /**< Lets the client know how many 3-axis accelerometer samples - were accepted. */ + were accepted. */ /* Optional */ /* Gyroscope Samples Accepted */ uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ uint8_t threeAxisGyroSamplesAccepted; /**< Lets the client know how many 3-axis gyroscope samples were - accepted. */ + accepted. */ }qmiLocInjectSensorDataIndMsgT_v02; /* Message */ /** @} @@ -5099,7 +4999,7 @@ typedef struct { /* Reference Time Sync Counter */ uint32_t refCounter; /**< Must be set to the value that was sent to the control point when the - GNSS location engine requested time sync injection. */ + GNSS location engine requested time sync injection. */ /* Mandatory */ /* Sensor Receive Time */ @@ -5109,7 +5009,7 @@ typedef struct { Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Mandatory */ /* Sensor Transmit Time */ @@ -5119,7 +5019,7 @@ typedef struct { Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ + - Units: Milliseconds */ }qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ /** @} @@ -5136,8 +5036,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject Time Sync Data request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5146,7 +5045,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ /** @} @@ -5158,9 +5057,8 @@ typedef struct { typedef enum { QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ - eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle - Unknown cradle mount state */ - eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, + eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, /**< Unknown cradle mount state */ QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocCradleMountStateEnumT_v02; /** @@ -5185,8 +5083,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Cradle Mount Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5195,7 +5092,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Cradle Mount State */ @@ -5203,20 +5100,19 @@ typedef struct { qmiLocCradleMountStateEnumT_v02 cradleMountState; /**< Cradle Mount state set by the control point. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \item 0x00000001 -- CRADLE_STATE_MOUNTED \item 0x00000002 -- CRADLE_STATE_UNKNOWN \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Cradle Mount Confidence */ uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ uint8_t confidenceCradleMountState; /**< Confidence of the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ + - Range: 0 to 100 */ }qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ /** @} @@ -5234,19 +5130,18 @@ typedef struct { qmiLocCradleMountStateEnumT_v02 cradleMountState; /**< Cradle Mount state set by the control point. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED \item 0x00000001 -- CRADLE_STATE_MOUNTED \item 0x00000002 -- CRADLE_STATE_UNKNOWN - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Cradle Mount Confidence */ uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ uint8_t confidenceCradleMountState; /**< Confidence in the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ + - Range: 0 to 100 */ }qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ /** @} @@ -5264,8 +5159,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Cradle Mount Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5274,7 +5168,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ /** @} @@ -5286,9 +5180,8 @@ typedef struct { typedef enum { QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ - eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. - Unknown external power state. */ - eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, + eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, /**< Unknown external power state. */ QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocExternalPowerConfigEnumT_v02; /** @@ -5313,8 +5206,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get External Power Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5323,7 +5215,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* External Power State */ @@ -5331,13 +5223,12 @@ typedef struct { qmiLocExternalPowerConfigEnumT_v02 externalPowerState; /**< Power state; injected by the control point. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \item 0x00000001 -- EXTERNAL_POWER_CONNECTED \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ /** @} @@ -5355,13 +5246,12 @@ typedef struct { qmiLocExternalPowerConfigEnumT_v02 externalPowerState; /**< Power state; injected by the control point. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED \item 0x00000001 -- EXTERNAL_POWER_CONNECTED \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ /** @} @@ -5379,8 +5269,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set External Power Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5389,7 +5278,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ /** @} @@ -5402,9 +5291,8 @@ typedef enum { QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. - PPP PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, /**< PPP PDN type. */ QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocServerPDNEnumT_v02; /** @@ -5417,14 +5305,14 @@ typedef enum { typedef struct { qmiLocServerPDNEnumT_v02 pdnType; - /**< PDN type of the Access Point Name (APN) profile. + /**< PDN type of the APN profile. Valid values: \n - 0x00000001 -- PDN_TYPE_IPV4 \n - 0x00000002 -- PDN_TYPE_IPV6 \n - 0x00000003 -- PDN_TYPE_IPV4V6 \n - 0x00000004 -- PDN_TYPE_PPP - */ + */ char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; /**< APN name. @@ -5432,7 +5320,7 @@ typedef struct { \item Type: NULL-terminated string \item Maximum string length (including NULL terminator): 101 \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocApnProfilesStructT_v02; /* Type */ /** @} @@ -5443,9 +5331,8 @@ typedef struct { */ typedef enum { QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. - Location server request failed. */ - eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, + eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. */ + eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, /**< Location server request failed. */ QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocServerReqStatusEnumT_v02; /** @@ -5465,7 +5352,7 @@ typedef struct { /* Connection Handle */ uint32_t connHandle; /**< Connection handle that the service specified in the - Location Server Connection request event. */ + Location Server Connection request event. */ /* Mandatory */ /* Request Type */ @@ -5476,7 +5363,7 @@ typedef struct { Valid values: \n - 0x00000001 -- OPEN \n - 0x00000002 -- CLOSE - */ + */ /* Mandatory */ /* Connection Status */ @@ -5487,14 +5374,14 @@ typedef struct { - 0x00000001 -- STATUS_SUCCESS = 1 \n - 0x00000002 -- STATUS_FAILURE = 2 - */ + */ /* Optional */ /* APN Profile */ uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ qmiLocApnProfilesStructT_v02 apnProfile; - /**< \n APN profile information is present only when requestType - is OPEN and statusType is SUCCESS. */ + /**< \n Access Point Name (APN) profile information is present only when + requestType is OPEN and statusType is SUCCESS. */ }qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ /** @} @@ -5514,8 +5401,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inform Location Server Connection Status request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5524,7 +5410,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ /** @} @@ -5535,9 +5421,8 @@ typedef struct { */ typedef enum { QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. - V2 VX version. */ - eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, + eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. */ + eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, /**< V2 VX version. */ QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocVxVersionEnumT_v02; /** @@ -5549,9 +5434,8 @@ typedef enum { */ typedef enum { QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. - SUPL version 2.0. */ - eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, + eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. */ + eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, /**< SUPL version 2.0. */ QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSuplVersionEnumT_v02; /** @@ -5562,8 +5446,8 @@ typedef uint32_t qmiLocLppConfigMaskT_v02; #define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ #define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in Control Plane */ -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in User Plane */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in the control plane. */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in the user plane. */ /** @addtogroup loc_qmi_messages @{ */ @@ -5579,7 +5463,7 @@ typedef struct { \begin{itemize1} \item 0x01 (TRUE) -- SUPL security is enabled \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* VX Version */ @@ -5587,12 +5471,11 @@ typedef struct { qmiLocVxVersionEnumT_v02 vxVersion; /**< VX version. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- VX_VERSION_V1_ONLY \item 0x00000002 -- VX_VERSION_V2_ONLY \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* SUPL Version */ @@ -5603,7 +5486,7 @@ typedef struct { Valid values: \n - 0x00000001 -- SUPL_VERSION_1_0 \n - 0x00000002 -- SUPL_VERSION_2_0 - */ + */ /* Optional */ /* LPP Configuration */ @@ -5611,26 +5494,24 @@ typedef struct { qmiLocLppConfigMaskT_v02 lppConfig; /**< LTE Positioning Profile (LPP) configuration. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Assisted GLONASS Protocol Mask */ uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Configures the protocols that the location service can indicate it supports, - for Assisted Glonass. + /**< Configures the protocols that the location service supports + for assisted GLONASS. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ /** @} @@ -5654,8 +5535,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Configuration Parameters request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5664,25 +5544,23 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Failed Parameters */ uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; - /**< This field is sent only if the status is not a success. And if it is - not successful, this field will identify the parameters that were not - set successfully. + /**< Identifies parameters that were not set successfully. This field + is sent only if the status is not a success. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -5700,15 +5578,14 @@ typedef struct { qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; /**< Mask denoting the configuration parameters to be retrieved. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ /** @} @@ -5726,8 +5603,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Configuration Parameters request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5736,7 +5612,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* SUPL Security */ @@ -5746,7 +5622,7 @@ typedef struct { \begin{itemize1} \item 0x01 (TRUE) -- SUPL security is enabled \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ /* Optional */ /* VX Version */ @@ -5754,12 +5630,11 @@ typedef struct { qmiLocVxVersionEnumT_v02 vxVersion; /**< VX version. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- VX_VERSION_V1_ONLY \item 0x00000002 -- VX_VERSION_V2_ONLY \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* SUPL Version */ @@ -5770,7 +5645,7 @@ typedef struct { Valid values: \n - 0x00000001 -- SUPL_VERSION_1_0 \n - 0x00000002 -- SUPL_VERSION_2_0 - */ + */ /* Optional */ /* LPP Configuration */ @@ -5778,25 +5653,23 @@ typedef struct { qmiLocLppConfigMaskT_v02 lppConfig; /**< LTE Positioning Profile (LPP) configuration. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Assisted GLONASS Protocol Mask */ uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Assisted GLONASS Protocol Mask. + /**< Assisted GLONASS Protocol mask. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -5811,10 +5684,9 @@ typedef enum { received. If sensor data are injected, the positioning engine attempts to improve the heading and positioning performance using sensors. This is the default. - - Inertial sensors are not to be used to aid heading and position + */ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, /**< Inertial sensors are not to be used to aid heading and position improvement. */ - eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSensorsControlConfigSensorUseEnumT_v02; /** @@ -5834,18 +5706,17 @@ typedef struct { /**< Controls how sensors are used to aid heading and positioning performance. - Valid values: - \begin{itemize1} - \item 0x00000000 -- SENSORS USE ENABLED: \n + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: Sensors data is to be requested whenever a position request is received. If sensors data is injected, the GNSS location engine attempts to improve the heading and positioning performance using sensors. This is the default. - \item 0x00000001 -- SENSORS USE DISABLED: \n + \item 0x00000001 -- SENSORS_USE_DISABLED: Inertial sensors are not to be used to aid in heading and position improvement. \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ /** @} @@ -5862,8 +5733,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Sensor Control Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5872,7 +5742,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ /** @} @@ -5895,8 +5765,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Sensors Control Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -5905,7 +5774,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Sensors Usage */ @@ -5914,18 +5783,17 @@ typedef struct { /**< Controls how sensors are used to aid the heading and positioning performance. - Valid values: - \begin{itemize1} - \item 0x00000000 -- SENSORS USE ENABLED: \n + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: Sensors data is to be requested whenever a position request is received. If sensors data is injected, the GNSS location engine attempts to improve the heading and positioning performance using sensors. This is the default. - \item 0x00000001 -- SENSORS USE DISABLED: \n + \item 0x00000001 -- SENSORS_USE_DISABLED: Inertial sensors are not to be used to aid in the heading and position improvement. \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ /** @} @@ -5956,7 +5824,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians^2/seconds^4 - */ + */ /* Optional */ /* Velocity Random Walk Spectral Density */ @@ -5968,7 +5836,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Meters/seconds^2/Hertz^0.5 - */ + */ /* Optional */ /* Acceleration Random Walk Spectral Density */ @@ -5980,7 +5848,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Meters/seconds^3/Hertz^0.5 - */ + */ /* Optional */ /* Angle Random Walk Spectral Density */ @@ -5992,7 +5860,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians/seconds/Hertz^0.5 - */ + */ /* Optional */ /* Rate Random Walk Spectral Density */ @@ -6004,7 +5872,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians/seconds^2/Hertz^0.5 - */ + */ }qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ /** @} @@ -6024,8 +5892,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Sensor Properties request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6035,7 +5902,7 @@ typedef struct { \item 0x00000006 -- TIMEOUT \item 0x00000007 -- CONFIG_NOT_SUPPORTED \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Failed Set Sensor Properties */ @@ -6044,15 +5911,14 @@ typedef struct { /**< This field will be sent only if the status is not a success. Identifies the parameters that were not set successfully. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ /** @} @@ -6069,15 +5935,14 @@ typedef struct { qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; /**< Mask denoting the sensor properties parameters to be retrieved. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ /** @} @@ -6094,8 +5959,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Sensors Properties request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6105,7 +5969,7 @@ typedef struct { \item 0x00000006 -- TIMEOUT \item 0x00000007 -- CONFIG_NOT_SUPPORTED \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Gyro Bias Random Walk Variance */ @@ -6117,7 +5981,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians^2/seconds^4 - */ + */ /* Optional */ /* Velocity Random Walk Spectral Density */ @@ -6129,7 +5993,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Meters/seconds^2/Hertz^0.5 - */ + */ /* Optional */ /* Acceleration Random Walk Spectral Density */ @@ -6141,7 +6005,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Meters/seconds^3/Hertz^0.5 - */ + */ /* Optional */ /* Angle Random Walk Spectral Density */ @@ -6153,7 +6017,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians/seconds/Hertz^0.5 - */ + */ /* Optional */ /* Rate Random Walk Spectral Density */ @@ -6165,7 +6029,7 @@ typedef struct { sensors data sheet or a sensors conformance test. \n - Units: Radians/seconds^2/Hertz^0.5 - */ + */ }qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ /** @} @@ -6179,12 +6043,11 @@ typedef enum { eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. This mode can optimize power consumption and give a power-balanced positioning and heading enhancement using - inertial sensors - Sensors usage is to be forced ON. + inertial sensors */ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, /**< Sensors usage is to be forced ON. This mode can be requested by the control point when power consumption is not a restriction to the use of inertial sensors. */ - eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocSensorPerformanceControlModeEnumT_v02; /** @@ -6209,8 +6072,7 @@ typedef struct { This field is relevant only when sensors have been enabled using the sensors control configuration. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- AUTO: \n The GNSS location engine can decide when to request sensor data injection based on internal criteria. This is the default. @@ -6218,33 +6080,33 @@ typedef struct { The GNSS location engine must request use of sensors every time the GNSS location engine turns on. \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Accelerometer Sampling Specification */ uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the low data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request acceleration data to be used by the low data rate + filter. The sensor data rate is specified in terms of the nominal number + of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 10Hz sampling rate and 2Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ /* Optional */ /* Gyroscope Sampling Specification */ uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data - rate is specified in terms of the nominal number of samples per batch - and the number of batches per second. + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request gyro data to be used by the high data rate filter. + The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 10Hz sampling rate and 2Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ /* Optional */ /* Algorithm Configuration */ @@ -6252,11 +6114,10 @@ typedef struct { qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; /**< Sets which sensor algorithms are to be used when processing sensor data. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* High Data Rate Filter Accelerometer Sampling Specification */ @@ -6267,9 +6128,9 @@ typedef struct { data rate is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 100Hz sampling rate and 4Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ /* Optional */ /* High Data Rate Filter Gyroscope Sampling Specification */ @@ -6280,9 +6141,9 @@ typedef struct { is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 100Hz sampling rate and 4Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ }qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ /** @} @@ -6307,8 +6168,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Sensor Performance Control Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6317,17 +6177,17 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Failed Configuration */ uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; - /**< This field is sent only if the status is not a success. - When sent, this field identifies which configuration failed. + /**< Identifies parameters that were not configured successfully. This field + is sent only if the status is not a success. - Valid bitmasks: - \begin{itemize1} + + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- PERFORMANCE_MODE \item 0x00000002 -- ACCEL_SAMPLING_SPEC \item 0x00000004 -- GYRO_SAMPLING_SPEC @@ -6335,7 +6195,7 @@ typedef struct { \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ /** @} @@ -6359,8 +6219,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Sensor Performance Control Configuration request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6369,7 +6228,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Performance Control Mode */ @@ -6379,8 +6238,7 @@ typedef struct { This field is relevant only when sensors have been enabled using the sensor control configuration. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- AUTO: \n The GNSS location engine can decide when to request sensor data injection based on internal criteria. This is the default. @@ -6388,7 +6246,7 @@ typedef struct { The GNSS location engine must request use of the sensors every time the GNSS location engine turns on. \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Accelerometer Sampling Specification */ @@ -6399,9 +6257,9 @@ typedef struct { data rate is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 10Hz sampling rate and 2Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2Hz batching rate. + */ /* Optional */ /* Gyroscope Sampling Specification */ @@ -6412,9 +6270,9 @@ typedef struct { rate is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 10Hz sampling rate and 2Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ /* Optional */ /* Algorithm Configuration */ @@ -6422,11 +6280,10 @@ typedef struct { qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; /**< Informs which sensor algorithms are currently set. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* High Data Rate Filter Accelerometer Sampling Specification */ @@ -6437,9 +6294,9 @@ typedef struct { data rate is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 100Hz sampling rate and 4Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ /* Optional */ /* High Data Rate Filter Gyroscope Sampling Specification */ @@ -6450,9 +6307,9 @@ typedef struct { is specified in terms of the nominal number of samples per batch and the number of batches per second. However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. - The default specification is 100Hz sampling rate and 4Hz batching rate. - */ + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ }qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ /** @} @@ -6469,7 +6326,7 @@ typedef struct { uint8_t suplCertId; /**< Certificate ID of the SUPL certificate. \n - Units: Bytes \n - - Range: 0 to 9 */ + - Range: 0 to 9 */ /* Mandatory */ /* SUPL Certificate Data */ @@ -6477,7 +6334,7 @@ typedef struct { uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; /**< SUPL certificate contents. \n - Type: Array of bytes. \n - - Maximum certificate size: 2000 bytes */ + - Maximum certificate size: 2000 bytes */ }qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ /** @} @@ -6494,8 +6351,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Inject SUPL Certificate request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6504,7 +6360,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ /** @} @@ -6524,7 +6380,7 @@ typedef struct { - Units: Bytes \n - Range: 0 to 9 \n If suplCertId is not specified, - all SUPL certificates are deleted. */ + all SUPL certificates are deleted. */ }qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ /** @} @@ -6541,8 +6397,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Delete SUPL Certificate request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6551,7 +6406,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ /** @} @@ -6577,15 +6432,14 @@ typedef struct { uint8_t injectedPositionControl; /**< Controls how the injected position is used in the position engine. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- Use the injected position in a direct position calculation \item 0x00 (FALSE) -- Do not use the injected position in a direct position calculation \end{itemize1} The default value is TRUE. - */ + */ /* Optional */ /* Filter SV Usage */ @@ -6593,13 +6447,12 @@ typedef struct { uint8_t filterSvUsage; /**< Controls whether SV usage is filtered in a position fix. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- Filter the usage of SVs in the fix \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix \end{itemize1} The default value is FALSE. - */ + */ /* Optional */ /* Store Assist Data */ @@ -6608,13 +6461,12 @@ typedef struct { /**< Controls whether assistance data is to be stored in persistent memory. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- Store assistance data in persistent memory \item 0x00 (FALSE) -- Do not store assistance data in persistent memory \end{itemize1} The default value is TRUE. - */ + */ }qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ /** @} @@ -6632,8 +6484,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Set Configuration Parameters request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6642,7 +6493,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Failed Parameters */ @@ -6651,13 +6502,12 @@ typedef struct { /**< Identifies the parameters that were not set successfully. This field is sent only if the status is other than SUCCESS. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- INJECTED_POSITION_CONTROL \item 0x00000002 -- FILTER_SV_USAGE \item 0x00000004 -- STORE_ASSIST_DATA \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -6675,13 +6525,12 @@ typedef struct { qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; /**< Mask denoting the configuration parameters to be retrieved. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- INJECTED_POSITION_CONTROL \item 0x00000002 -- FILTER_SV_USAGE \item 0x00000004 -- STORE_ASSIST_DATA \vspace{-0.18in} \end{itemize1} - */ + */ }qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ /** @} @@ -6699,8 +6548,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Get Configuration Parameters request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6709,7 +6557,7 @@ typedef struct { \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Injected Position Control */ @@ -6718,15 +6566,14 @@ typedef struct { /**< Specifies whether the injected position is used for a direct calculation in the position engine. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- The injected position is used in a direct position calculation \item 0x00 (FALSE) -- The injected position is not used in a direct position calculation \end{itemize1} The default value is TRUE. - */ + */ /* Optional */ /* Filter SV Usage */ @@ -6734,13 +6581,12 @@ typedef struct { uint8_t filterSvUsage; /**< Specifies whether SV usage is filtered in a position fix. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- SV usage is filtered in the fix \item 0x00 (FALSE) -- SV usage is not filtered in the fix \end{itemize1} The default value is FALSE. - */ + */ /* Optional */ /* Store Assist Data */ @@ -6748,14 +6594,13 @@ typedef struct { uint8_t storeAssistData; /**< Specifies whether assistance data is stored in persistent memory. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- Assistance data is stored in persistent memory \item 0x00 (FALSE) -- Assistance data is not stored in persistent memory \end{itemize1} The default value is TRUE. - */ + */ }qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ /** @} @@ -6776,12 +6621,11 @@ typedef enum { the time it is reported is higher. This setting results in lower power usage. */ eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a - medium rate. This is the default setting. - The Geofence is monitored for a breach at a + medium rate. This is the default setting. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, /**< The Geofence is monitored for a breach at a high rate. The gap between actual breach and the time it is reported is low. This results in higher power usage. */ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceResponsivenessEnumT_v02; /** @@ -6798,11 +6642,10 @@ typedef enum { power usage. This setting can impact the "yield" because incorrect breach events may be sent. */ eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with - medium confidence. This is the default setting. - The Geofence engine indicates a breach with + medium confidence. This is the default setting. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, /**< The Geofence engine indicates a breach with high confidence. This setting results in higher power usage. */ - eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceConfidenceEnumT_v02; /** @@ -6815,13 +6658,13 @@ typedef enum { typedef struct { double latitude; - /**< Latitude of the center of the Geofence. */ + /**< Latitude of the center of the Geofence.*/ double longitude; - /**< Longitude of the center of the Geofence. */ + /**< Longitude of the center of the Geofence.*/ uint32_t radius; - /**< Radius of the circular Geofence in meters. */ + /**< Radius of the circular Geofence in meters. */ }qmiLocCircularGeofenceArgsStructT_v02; /* Type */ /** @} @@ -6832,9 +6675,8 @@ typedef struct { */ typedef enum { QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. - Position outside a Geofence. */ - eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, + eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. */ + eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, /**< Position outside a Geofence. */ QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofencePositionEnumT_v02; /** @@ -6852,7 +6694,7 @@ typedef struct { uint32_t transactionId; /**< Identifies the transaction. The transaction ID is returned in the Add Circular Geofence - indication. */ + indication. */ /* Mandatory */ /* Circular Geofence Arguments */ @@ -6863,11 +6705,10 @@ typedef struct { qmiLocGeofenceBreachMaskT_v02 breachMask; /**< Specifies the breach events in which the client is interested. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Mandatory */ /* Include Position in Breach Event */ @@ -6875,12 +6716,11 @@ typedef struct { /**< Specifies whether the Geofence engine is to include the position in a breach event. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 (TRUE) -- Position will be reported with the breach event \item 0x00 (FALSE) -- Position will not be reported with the breach event - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Responsiveness */ @@ -6891,12 +6731,11 @@ typedef struct { when it is reported. This parameter has power implications and is to be fine-tuned to optimize power savings. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Confidence */ @@ -6907,12 +6746,11 @@ typedef struct { This parameter has power implications and is to be fine-tuned to optimize power savings. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ /** @} @@ -6929,8 +6767,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Add Circular Geofence request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -6940,7 +6777,7 @@ typedef struct { \item 0x00000006 -- TIMEOUT \item 0x00000008 -- INSUFFICIENT_MEMORY \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Transaction ID */ @@ -6948,7 +6785,7 @@ typedef struct { uint32_t transactionId; /**< Transaction ID that was specified in the Add Circular Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ + if the status field is set to SUCCESS. */ /* Optional */ /* Geofence ID */ @@ -6956,7 +6793,7 @@ typedef struct { uint32_t geofenceId; /**< Geofence identifier allocated by the engine. The client must include this identifier in all transactions - pertaining to this Geofence. */ + pertaining to this Geofence. */ }qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ /** @} @@ -6971,14 +6808,14 @@ typedef struct { /* Mandatory */ /* Geofence ID */ uint32_t geofenceId; - /**< Identifier for the Geofence that is to be deleted. */ + /**< Identifier for the Geofence that is to be deleted. */ /* Mandatory */ /* Transaction ID */ uint32_t transactionId; /**< Identifies the transaction. The transaction ID is returned in the Delete Geofence - indication. */ + indication. */ }qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ /** @} @@ -6995,8 +6832,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Delete Geofence request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -7004,13 +6840,13 @@ typedef struct { \item 0x00000004 -- ENGINE_BUSY \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Geofence ID */ uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ uint32_t geofenceId; - /**< Identifier for the Geofence that was deleted. */ + /**< Identifier for the Geofence that was deleted. */ /* Optional */ /* Transaction ID */ @@ -7018,7 +6854,7 @@ typedef struct { uint32_t transactionId; /**< Transaction ID that was specified in the Delete Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ + if the status field is set to SUCCESS. */ }qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ /** @} @@ -7029,9 +6865,8 @@ typedef struct { */ typedef enum { QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. - The Geofence was initiated by the device. */ - eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, + eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. */ + eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, /**< The Geofence was initiated by the device. */ QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceOriginEnumT_v02; /** @@ -7043,9 +6878,8 @@ typedef enum { */ typedef enum { QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. - The Geofence monitoring is suspended. */ - eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, + eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. */ + eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, /**< The Geofence monitoring is suspended. */ QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocGeofenceStateEnumT_v02; /** @@ -7061,14 +6895,14 @@ typedef struct { /* Mandatory */ /* Geofence ID */ uint32_t geofenceId; - /**< Identifier for the Geofence that is to be queried. */ + /**< Identifier for the Geofence that is to be queried. */ /* Mandatory */ /* Transaction ID */ uint32_t transactionId; /**< Identifies the transaction. The transaction ID is returned with the Query Geofence - indication. */ + indication. */ }qmiLocQueryGeofenceReqMsgT_v02; /* Message */ /** @} @@ -7085,8 +6919,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Query Geofence request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -7094,13 +6927,13 @@ typedef struct { \item 0x00000004 -- ENGINE_BUSY \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Geofence ID */ uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ uint32_t geofenceId; - /**< Identifier for the Geofence that was queried. */ + /**< Identifier for the Geofence that was queried. */ /* Optional */ /* Transaction ID */ @@ -7108,7 +6941,7 @@ typedef struct { uint32_t transactionId; /**< Transaction ID that was specified in the Query Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ + if the status field is set to SUCCESS. */ /* Optional */ /* Geofence Origin */ @@ -7116,12 +6949,11 @@ typedef struct { qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; /**< Originator of the Geofence. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE \vspace{-0.18in} \end{itemize1} - */ + */ /* Optional */ /* Position with Respect to Geofence */ @@ -7130,11 +6962,10 @@ typedef struct { /**< Indicates if the client is currently inside or outside the Geofence. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_POSITION_INSIDE \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Circular Geofence Parameters */ @@ -7147,11 +6978,10 @@ typedef struct { qmiLocGeofenceStateEnumT_v02 geofenceState; /**< Specifies whether the Geofence is to be actively monitored. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_STATE_ACTIVE \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocQueryGeofenceIndMsgT_v02; /* Message */ /** @} @@ -7166,7 +6996,7 @@ typedef struct { /* Mandatory */ /* Geofence ID */ uint32_t geofenceId; - /**< Identifier for the Geofence to be edited. */ + /**< Identifier for the Geofence to be edited. */ /* Mandatory */ /* Transaction ID */ @@ -7174,7 +7004,7 @@ typedef struct { /**< Transaction ID that was specified in the Edit Geofence request. This parameter will always be present if the status field is set to SUCCESS. - */ + */ /* Optional */ /* Geofence State */ @@ -7182,11 +7012,10 @@ typedef struct { qmiLocGeofenceStateEnumT_v02 geofenceState; /**< Specifies whether the Geofence is to be actively monitored. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_STATE_ACTIVE \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Breach Event Mask */ @@ -7194,11 +7023,10 @@ typedef struct { qmiLocGeofenceBreachMaskT_v02 breachMask; /**< Specifies the breach events in which the client is interested. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocEditGeofenceReqMsgT_v02; /* Message */ /** @} @@ -7218,8 +7046,7 @@ typedef struct { qmiLocStatusEnumT_v02 status; /**< Status of the Edit Geofence request. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- SUCCESS \item 0x00000001 -- GENERAL_FAILURE \item 0x00000002 -- UNSUPPORTED @@ -7227,20 +7054,20 @@ typedef struct { \item 0x00000004 -- ENGINE_BUSY \item 0x00000005 -- PHONE_OFFLINE \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Geofence ID */ uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ uint32_t geofenceId; - /**< Identifier for the Geofence that was edited. */ + /**< Identifier for the Geofence that was edited. */ /* Optional */ /* Transaction ID */ uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ uint32_t transactionId; /**< Identifies the transaction. The transaction ID - is specified in the Edit Geofence request. */ + is specified in the Edit Geofence request. */ /* Optional */ /* Failed Parameters */ @@ -7250,11 +7077,10 @@ typedef struct { the mask corresponding to a field is set, it indicates that the Geofence parameter could not be edited. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ }qmiLocEditGeofenceIndMsgT_v02; /* Message */ /** @} @@ -7271,7 +7097,7 @@ typedef struct { /* Transaction ID */ uint32_t transactionId; /**< Identifies the transaction. The transaction ID - is returned in the Get Best Available Position indication. */ + is returned in the Get Best Available Position indication. */ }qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ /** @} @@ -7294,7 +7120,7 @@ typedef struct { - 0x00000001 -- GENERAL_FAILURE \n - 0x00000002 -- UNSUPPORTED \n - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ + - 0x00000006 -- TIMEOUT */ /* Optional */ /* Transaction ID */ @@ -7303,7 +7129,7 @@ typedef struct { /**< Transaction ID that was specified in the Get Best Available Position request. This parameter will always be present if the status field is set to - SUCCESS. */ + SUCCESS. */ /* Optional */ /* Latitude */ @@ -7316,7 +7142,7 @@ typedef struct { \item Range: -90.0 to 90.0 \begin{itemize1} \item Positive values indicate northern latitude \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Longitude */ @@ -7329,14 +7155,14 @@ typedef struct { \item Range: -180.0 to 180.0 \begin{itemize1} \item Positive values indicate eastern longitude \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ /* Optional */ /* Circular Horizontal Position Uncertainty */ uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ float horUncCircular; /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Altitude With Respect to Ellipsoid */ @@ -7344,14 +7170,14 @@ typedef struct { float altitudeWrtEllipsoid; /**< Altitude with respect to the WGS84 ellipsoid.\n - Units: Meters \n - - Range: -500 to 15883 */ + - Range: -500 to 15883 */ /* Optional */ /* Vertical Uncertainty */ uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ float vertUnc; /**< Vertical uncertainty.\n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* UTC Timestamp */ @@ -7360,28 +7186,28 @@ typedef struct { /**< UTC timestamp. \begin{itemize1} \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Time Uncertainty */ uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ float timeUnc; /**< Time uncertainty. \n - - Units: Milliseconds */ + - Units: Milliseconds */ /* Optional */ /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ float horUncEllipseSemiMinor; /**< Semi-minor axis of horizontal elliptical uncertainty. \n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Horizontal Elliptical Uncertainty Semi-Major Axis */ uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ float horUncEllipseSemiMajor; /**< Semi-major axis of horizontal elliptical uncertainty. \n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Horizontal Elliptical Uncertainty Azimuth */ @@ -7389,7 +7215,7 @@ typedef struct { float horUncEllipseOrientAzimuth; /**< Elliptical horizontal uncertainty azimuth of orientation. \n - Units: Decimal degrees \n - - Range: 0 to 180 */ + - Range: 0 to 180 */ /* Optional */ /* Horizontal Circular Confidence */ @@ -7397,7 +7223,7 @@ typedef struct { uint8_t horCircularConfidence; /**< Horizontal circular uncertainty confidence. \n - Units: Percent \n - - Range: 0 to 99 */ + - Range: 0 to 99 */ /* Optional */ /* Horizontal Elliptical Confidence */ @@ -7405,7 +7231,7 @@ typedef struct { uint8_t horEllipticalConfidence; /**< Horizontal elliptical uncertainty confidence. \n - Units: Percent \n - - Range: 0 to 99 */ + - Range: 0 to 99 */ /* Optional */ /* Horizontal Reliability */ @@ -7413,35 +7239,34 @@ typedef struct { qmiLocReliabilityEnumT_v02 horReliability; /**< Specifies the reliability of the horizontal position. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- RELIABILITY_NOT_SET \item 0x00000001 -- RELIABILITY_VERY_LOW \item 0x00000002 -- RELIABILITY_LOW \item 0x00000003 -- RELIABILITY_MEDIUM \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Horizontal Speed */ uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ float horSpeed; /**< Horizontal speed. \n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Horizontal Speed Uncertainty */ uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ float horSpeedUnc; /**< Horizontal speed uncertainty. \n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Altitude With Respect to Sea Level */ uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ float altitudeWrtMeanSeaLevel; /**< Altitude with respect to mean sea level. \n - - Units: Meters */ + - Units: Meters */ /* Optional */ /* Vertical Confidence */ @@ -7449,7 +7274,7 @@ typedef struct { uint8_t vertConfidence; /**< Vertical uncertainty confidence. \n - Units: Percent \n - - Range: 0 to 99 */ + - Range: 0 to 99 */ /* Optional */ /* Vertical Reliability */ @@ -7457,28 +7282,27 @@ typedef struct { qmiLocReliabilityEnumT_v02 vertReliability; /**< Specifies the reliability of the vertical position. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- RELIABILITY_NOT_SET \item 0x00000001 -- RELIABILITY_VERY_LOW \item 0x00000002 -- RELIABILITY_LOW \item 0x00000003 -- RELIABILITY_MEDIUM \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1}*/ /* Optional */ /* Vertical Speed */ uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ float vertSpeed; /**< Vertical speed. \n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Vertical Speed Uncertainty */ uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ float vertSpeedUnc; /**< Vertical speed uncertainty. \n - - Units: Meters/second */ + - Units: Meters/second */ /* Optional */ /* Heading */ @@ -7486,7 +7310,7 @@ typedef struct { float heading; /**< Heading. \n - Units: Degrees \n - - Range: 0 to 359.999 */ + - Range: 0 to 359.999 */ /* Optional */ /* Heading Uncertainty */ @@ -7494,7 +7318,7 @@ typedef struct { float headingUnc; /**< Heading uncertainty. \n - Type: Floating point \n - - Range: 0 to 359.999 */ + - Range: 0 to 359.999 */ /* Optional */ /* Magnetic Deviation */ @@ -7502,7 +7326,7 @@ typedef struct { float magneticDeviation; /**< Difference between the bearing to true north and the bearing shown on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ + north is east of true north. */ /* Optional */ /* Technology Used Mask */ @@ -7510,15 +7334,14 @@ typedef struct { qmiLocPosTechMaskT_v02 technologyMask; /**< Technology used in computing this fix. - Valid bitmasks: - \begin{itemize1} + Valid bitmasks: \begin{itemize1} \item 0x00000001 -- SATELLITE \item 0x00000002 -- CELLID \item 0x00000004 -- WIFI \item 0x00000008 -- SENSORS \item 0x00000010 -- REFERENCE_LOCATION \item 0x00000020 -- INJECTED_COARSE_POSITION - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Dilution of Precision */ @@ -7536,8 +7359,7 @@ typedef struct { qmiLocTimeSourceEnumT_v02 timeSrc; /**< Time source. - Valid values: - \begin{itemize1} + Valid values: \begin{itemize1} \item 0x00000000 -- TIME_SRC_INVALID \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING @@ -7547,7 +7369,7 @@ typedef struct { \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED \item 0x00000007 -- TIME_SRC_NAV_SOLUTION \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} */ /* Optional */ /* Sensor Data Usage */ @@ -7561,14 +7383,13 @@ typedef struct { uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; /**< Each entry in the list contains the SV ID of a satellite used for calculating this position report. The following - information is associated with each SV ID: - \begin{itemize1} + information is associated with each SV ID: \begin{itemize1} \item Range: \begin{itemize1} \item For GPS: 1 to 32 \item For SBAS: 33 to 64 \item For GLONASS: 65 to 96 \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ }qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ /** @} @@ -7579,10 +7400,9 @@ typedef struct { */ typedef enum { QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known */ - eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is stationary - Device state is in motion */ - eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, + eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known. */ + eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is Stationary. */ + eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, /**< Device state is In Motion. */ QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocMotionStateEnumT_v02; /** @@ -7594,13 +7414,12 @@ typedef enum { */ typedef enum { QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known */ - eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in pedestrian mode, nothing else is known about the movement */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian walking mode */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian running mode - Device movement is in vehicular mode, nothing else is known about the movement */ - eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, + eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known. */ + eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in Pedestrian mode; nothing else is known about the movement. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian Walking mode. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian Running mode. */ + eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, /**< Device movement is in Vehicular mode; nothing else is known about the movement. */ QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ }qmiLocMotionModeEnumT_v02; /** @@ -7613,17 +7432,42 @@ typedef enum { typedef struct { qmiLocMotionStateEnumT_v02 motion_state; - /**< Current motion state of the user. States of user motion: \n - Options are: */ + /**< Current motion state of the user. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_STATE_UNKNOWN (0) -- Device state is not known. + \item eQMI_LOC_MOTION_STATE_STATIONARY (1) -- Device state is Stationary. + \item eQMI_LOC_MOTION_STATE_IN_MOTION (2) -- Device state is In Motion. + \vspace{0.06in} \end{itemize1} + + Absolute rest and relative rest are both indicated by setting motion_state + to Stationary. The relative rest state can be distinguished from absolute + rest by reducing probability_of_state. + */ qmiLocMotionModeEnumT_v02 motion_mode; - /**< Modes of user motion.\n - Options are: */ + /**< Modes of user motion. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_MODE_ UNKNOWN (0) -- Device movement is not known. + \item eQMI_LOC_MOTION_MODE_ STATIONARY (1) -- Device is not moving. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_UNKNOWN (200) -- Device movement + is in Pedestrian mode; nothing else is known about the movement. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_WALKING (201) -- Device movement + is in Pedestrian Walking mode. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_RUNNING (202) -- Device movement + is in Pedestrian Running mode. + \item eQMI_LOC_MOTION_MODE_ VEHICLE_UNKNOWN (300) -- Device movement is + in Vehicular mode; nothing else is known about the movement. + \vspace{0.06in} \end{itemize1} + + The motion_mode value is independent of the motion_state value. + */ float probability_of_state; /**< Probability that the device is actually undergoing the motion state specified by the combination of the values of motion_state, motion_mode, - and motion_sub_mode. \vspace{0.06in} + and motion_sub_mode. \vspace{0.06in} This value is a floating point number in the range of 0 to 100, in units of percent probability. Any value greater than 99.9999 is @@ -7635,33 +7479,33 @@ typedef struct { For example, if the mode of In-Motion + Pedestrian-Running can only be determined with 50 percent probability, and the simpler statement of In-Motion can be determined with 90 percent probability, it is recommended that this field - be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} + be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} If the motion_state is not known, the value in this field is not used. - */ + */ uint16_t age; /**< Age of the motion data in milliseconds at the time of injection. - */ + */ uint16_t timeout; - /**< If the age of the motion data input exceeds the timeout value, it + /**< If the age of the motion data input exceeds the timeout value, the data will no longer be used. The timeout value is in units of milliseconds. Values in the range of 0 to 10000 are accepted. If 65535 is provided, - the motion data input is applied indefinitely until the next input is + the motion data input is applied until the next input is received. \vspace{0.06in} - If the determination of motion data is an instantaneous observation, - and no notice is guaranteed to be given via QMI on a change in the - state of motion data, it is recommended that this field be set to 0. \vspace{0.06in} + If the determination of motion data is an instantaneous observation + and no notice is guaranteed to be given via the QMI on a change in the + state of the motion data, it is recommended that this field be set to 0. \vspace{0.06in} If the determination of motion data is continuously monitored - external to QMI, and an update is always applied to QMI upon any + external to the QMI and an update is always applied to the QMI upon any change in state, a value of 65535 is used for this field. Note that in this case, if a certain mode is set and is not later unset (e.g., by sending in the request message with a user motion state of Unknown), the value is applied indefinitely. - */ + */ }qmiLocMotionDataStructT_v02; /* Type */ /** @} @@ -7676,6 +7520,7 @@ typedef struct { /* Mandatory */ /* Motion Data */ qmiLocMotionDataStructT_v02 motion_data; + /**< Current motion data of the client */ }qmiLocInjectMotionDataReqMsgT_v02; /* Message */ /** @} @@ -7688,17 +7533,19 @@ typedef struct { typedef struct { /* Mandatory */ - /* Inject motion data request status */ + /* Inject Motion Data Request Status */ qmiLocStatusEnumT_v02 status; /**< Status of the Inject Motion Data request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - */ + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_ PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ }qmiLocInjectMotionDataIndMsgT_v02; /* Message */ /** @} @@ -7708,15 +7555,14 @@ typedef struct { @{ */ /** Request Message; Used by the control point to retrieve the list of network - initiated geofence ID's. */ + initiated Geofence IDs. */ typedef struct { /* Mandatory */ - /* Transaction Id */ + /* Transaction ID */ uint32_t transactionId; - /**< Identifies the transaction, the same transaction Id - will be returned in the Get NI Geofence ID List indication. - - Type -- Unsigned Integer. */ + /**< Identifies the transaction. The same transaction ID + will be returned in the Get NI Geofence ID List indication. */ }qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ /** @} @@ -7726,7 +7572,7 @@ typedef struct { @{ */ /** Indication Message; Used by the control point to retrieve the list of network - initiated geofence ID's. */ + initiated Geofence IDs. */ typedef struct { /* Mandatory */ @@ -7738,29 +7584,192 @@ typedef struct { - 0x00000001 -- GENERAL_FAILURE \n - 0x00000002 -- UNSUPPORTED \n - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ + - 0x00000006 -- TIMEOUT */ /* Optional */ - /* Transaction Id */ + /* Transaction ID */ uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ uint32_t transactionId; - /**< Transaction Id which was specified in the Get NI - Geofence ID List request. - - Type -- Unsigned Integer. */ + /**< Transaction ID that was specified in the Get NI + Geofence ID List request. */ /* Optional */ /* NI Geofence ID List */ uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; - /**< List containing the NI Geofence Id's. - - Type: Array of unsigned 32 bit integers. \n - - Maximum NI Geofence ID List length : 16 */ + /**< List containing the NI Geofence IDs. + - Type: Array of unsigned 32-bit integers \n + - Maximum NI Geofence ID List length: 16 */ }qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ /** @} */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t MCC; + /**< GSM mobile country code. Refer to ITU-T E.212 specification */ + + uint32_t MNC; + /**< GSM mobile network code. Refer to ITU-T E.212 specification*/ + + uint32_t LAC; + /**< GSM location area code.Refer to ITU-T E.212 specification */ + + uint32_t CID; + /**< GSM cell identification.Refer to ITU-T E.212 specification */ +}qmiLocGSMCellIdStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* GSM Cell ID */ + qmiLocGSMCellIdStructT_v02 gsmCellId; + /**< Identifies the GSM Cell the device is currently camped on.*/ + + /* Mandatory */ + /* Roaming Status */ + uint8_t roamingStatus; + /**< Whether the device is roaming. + \begin{itemize1} + \item 0x01 (TRUE) -- The device is roaming. + \item 0x00 (FALSE) -- The device is not roaming. + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocInjectGSMCellInfoReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject GSM Cell Info Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject GSM Cell Info request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ +}qmiLocInjectGSMCellInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL_V02 = 0, /**< SUPL netwrok initiated message is being injected. */ + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Injected Network Initiated Message Type */ + qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02 injectedNIMessageType; + /**< Type of the network initiated message being injected + Valid Values: + - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL (0) -- SUPL netwrok initiated message is being injected. */ + + /* Mandatory */ + /* Injected Network Initiated Message */ + uint32_t injectedNIMessage_len; /**< Must be set to # of elements in injectedNIMessage */ + uint8_t injectedNIMessage[QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02]; + /**< Network initiated message body. + If the inject NI message type is TYPE_SUPL, the message contains + a SUPL INIT message as defined in OMA-TS-ULP-V2_0-20110527-C specification. */ +}qmiLocInjectNetworkInitiatedMessageReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Network Initiated Message Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Network Initiated Message request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + - 0x00000008 -- INSUFFICIENT_MEMORY \n */ +}qmiLocInjectNetworkInitiatedMessageIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * typedef struct { + * }qmiLocWWANOutOfServiceNotificationReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to notify the location engine that the device is + no longer camped. */ +typedef struct { + + /* Mandatory */ + /* Notify WWAN Out of Service Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WWAN out of service request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + */ +}qmiLocWWANOutOfServiceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + /*Service Message Definition*/ /** @addtogroup loc_qmi_msg_ids @{ @@ -7949,6 +7958,15 @@ typedef struct { #define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 #define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 #define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 +#define QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 0x006A +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 0x006B +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02 0x006C /** @} */ From a03322f3a73dd28d7486ffa516755d2c49773e8d Mon Sep 17 00:00:00 2001 From: Amol Mahesh Date: Mon, 24 Sep 2012 13:41:46 -0700 Subject: [PATCH 16/33] LOC_API: Add group permissions after creating the pipe. Add the group permissions to the pipe after creation so that it can be accessed by the group. Change-Id: Ib42639ee8a46a498c4e246bc448fe8267fd5fa7d --- loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c old mode 100644 new mode 100755 index 74769088..e479b7ae --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_glue_pipe.c @@ -64,13 +64,21 @@ int loc_eng_dmn_conn_glue_pipeget(const char * pipe_name, int mode) int result; LOC_LOGD("%s, mode = %d\n", pipe_name, mode); - result = mkfifo(pipe_name, 0666); + result = mkfifo(pipe_name, 0660); if ((result == -1) && (errno != EEXIST)) { LOC_LOGE("failed: %s\n", strerror(errno)); return result; } + // The mode in mkfifo is not honoured and does not provide the + // group permissions. Doing chmod to add group permissions. + result = chmod (pipe_name, 0660); + if (result != 0){ + LOC_LOGE ("%s failed to change mode for %s, error = %s\n", __func__, + pipe_name, strerror(errno)); + } + fd = open(pipe_name, mode); if (fd <= 0) { From 899ebaa3de7d2329f776dbfca19672b3a18a7013 Mon Sep 17 00:00:00 2001 From: Amol Mahesh Date: Mon, 24 Sep 2012 13:44:50 -0700 Subject: [PATCH 17/33] LOC_API: Modify LOC_API to support MSAPU client. Modify LOC_API to support MSAPU client which would also request for the access to wifi network. Change-Id: I74a5f83484953c52437855467b04c2a4c2ccfa27 --- loc_api/libloc_api_50001/loc_eng.cpp | 3 ++- loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp | 12 ++++++++++ loc_api/libloc_api_50001/loc_eng_dmn_conn.h | 2 ++ .../loc_eng_dmn_conn_handler.cpp | 24 +++++++++++++++++++ .../loc_eng_dmn_conn_handler.h | 1 + loc_api/libloc_api_50001/loc_eng_msg.h | 1 + 6 files changed, 42 insertions(+), 1 deletion(-) mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn.h mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 5075311e..65b211ec 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -1661,7 +1661,8 @@ static void loc_eng_deferred_action_thread(void* arg) { loc_eng_msg_request_wifi *wrqMsg = (loc_eng_msg_request_wifi *)msg; if (wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC || - wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM) { + wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM || + wrqMsg->senderId == LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU) { AgpsStateMachine* stateMachine = loc_eng_data_p->wifi_nif; WIFISubscriber subscriber(stateMachine, wrqMsg->ssid, wrqMsg->password, wrqMsg->senderId); stateMachine->subscribeRsrc((Subscriber*)&subscriber); diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp old mode 100644 new mode 100755 index 2bb2d810..f01402a1 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp @@ -48,11 +48,13 @@ static int loc_api_server_msgqid; static int loc_api_resp_msgqid; static int quipc_msgqid; static int msapm_msgqid; +static int msapu_msgqid; static const char * global_loc_api_q_path = GPSONE_LOC_API_Q_PATH; static const char * global_loc_api_resp_q_path = GPSONE_LOC_API_RESP_Q_PATH; static const char * global_quipc_ctrl_q_path = QUIPC_CTRL_Q_PATH; static const char * global_msapm_ctrl_q_path = MSAPM_CTRL_Q_PATH; +static const char * global_msapu_ctrl_q_path = MSAPU_CTRL_Q_PATH; static int loc_api_server_proc_init(void *context) { @@ -81,6 +83,7 @@ static int loc_api_server_proc_init(void *context) loc_api_resp_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_resp_q_path, O_RDWR); quipc_msgqid = loc_eng_dmn_conn_glue_msgget(global_quipc_ctrl_q_path, O_RDWR); msapm_msgqid = loc_eng_dmn_conn_glue_msgget(global_msapm_ctrl_q_path , O_RDWR); + msapu_msgqid = loc_eng_dmn_conn_glue_msgget(global_msapu_ctrl_q_path , O_RDWR); LOC_LOGD("%s:%d] loc_api_server_msgqid = %d\n", __func__, __LINE__, loc_api_server_msgqid); return 0; @@ -148,6 +151,7 @@ static int loc_api_server_proc_post(void *context) loc_eng_dmn_conn_glue_msgremove( global_loc_api_resp_q_path, loc_api_resp_msgqid); loc_eng_dmn_conn_glue_msgremove( global_quipc_ctrl_q_path, quipc_msgqid); loc_eng_dmn_conn_glue_msgremove( global_msapm_ctrl_q_path, msapm_msgqid); + loc_eng_dmn_conn_glue_msgremove( global_msapu_ctrl_q_path, msapu_msgqid); return 0; } @@ -221,6 +225,14 @@ int loc_eng_dmn_conn_loc_api_server_data_conn(int sender_id, int status) { } break; } + case LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU: { + LOC_LOGD("%s:%d] sender_id = LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU", __func__, __LINE__); + if (loc_eng_dmn_conn_glue_msgsnd(msapu_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { + LOC_LOGD("%s:%d] error! conn_glue_msgsnd failed\n", __func__, __LINE__); + return -1; + } + break; + } case LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON: { LOC_LOGD("%s:%d] sender_id = LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON", __func__, __LINE__); if (loc_eng_dmn_conn_glue_msgsnd(loc_api_resp_msgqid, & cmsgbuf, sizeof(struct ctrl_msgbuf)) < 0) { diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h old mode 100644 new mode 100755 index f6692487..cebbfc92 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn.h +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.h @@ -37,6 +37,7 @@ #define GPSONE_LOC_API_RESP_Q_PATH "/data/misc/gpsone_d/gpsone_loc_api_resp_q" #define QUIPC_CTRL_Q_PATH "/data/misc/gpsone_d/quipc_ctrl_q" #define MSAPM_CTRL_Q_PATH "/data/misc/gpsone_d/msapm_ctrl_q" +#define MSAPU_CTRL_Q_PATH "/data/misc/gpsone_d/msapu_ctrl_q" #else @@ -44,6 +45,7 @@ #define GPSONE_LOC_API_RESP_Q_PATH "/tmp/gpsone_loc_api_resp_q" #define QUIPC_CTRL_Q_PATH "/tmp/quipc_ctrl_q" #define MSAPM_CTRL_Q_PATH "/tmp/msapm_ctrl_q" +#define MSAPU_CTRL_Q_PATH "/tmp/msapu_ctrl_q" #endif diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp old mode 100644 new mode 100755 index 6077b721..16d9be75 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.cpp @@ -99,6 +99,18 @@ int loc_eng_dmn_conn_loc_api_server_if_request_handler(struct ctrl_msgbuf *pmsg, loc_eng_msg_sender(loc_api_handle, msg); break; } + case IF_REQUEST_SENDER_ID_MSAPU: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_MSAPU"); + loc_eng_msg_request_wifi *msg( + new loc_eng_msg_request_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } case IF_REQUEST_SENDER_ID_GPSONE_DAEMON: { LOC_LOGD("IF_REQUEST_SENDER_ID_GPSONE_DAEMON"); @@ -179,6 +191,18 @@ int loc_eng_dmn_conn_loc_api_server_if_release_handler(struct ctrl_msgbuf *pmsg, loc_eng_msg_sender(loc_api_handle, msg); break; } + case IF_REQUEST_SENDER_ID_MSAPU: + { + LOC_LOGD("IF_REQUEST_SENDER_ID_MSAPU"); + loc_eng_msg_release_wifi *msg( + new loc_eng_msg_release_wifi(loc_api_handle, + type, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU, + (char*)pmsg->cmsg.cmsg_if_request.ssid, + (char*)pmsg->cmsg.cmsg_if_request.password)); + loc_eng_msg_sender(loc_api_handle, msg); + break; + } case IF_REQUEST_SENDER_ID_GPSONE_DAEMON: { LOC_LOGD("IF_REQUEST_SENDER_ID_GPSONE_DAEMON"); diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h old mode 100644 new mode 100755 index 7aa22bfb..51efb592 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn_handler.h @@ -67,6 +67,7 @@ typedef enum { typedef enum { IF_REQUEST_SENDER_ID_QUIPC = 0, IF_REQUEST_SENDER_ID_MSAPM, + IF_REQUEST_SENDER_ID_MSAPU, IF_REQUEST_SENDER_ID_GPSONE_DAEMON, IF_REQUEST_SENDER_ID_MODEM } ctrl_if_req_sender_id_e_type; diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h index 9dffc280..9c5c03bd 100755 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -136,6 +136,7 @@ typedef enum { typedef enum { LOC_ENG_IF_REQUEST_SENDER_ID_QUIPC = 0, LOC_ENG_IF_REQUEST_SENDER_ID_MSAPM, + LOC_ENG_IF_REQUEST_SENDER_ID_MSAPU, LOC_ENG_IF_REQUEST_SENDER_ID_GPSONE_DAEMON, LOC_ENG_IF_REQUEST_SENDER_ID_MODEM, LOC_ENG_IF_REQUEST_SENDER_ID_UNKNOWN From 0a28a39125e42b0b5c62825dbb532a72783617c2 Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Thu, 27 Sep 2012 10:07:13 -0700 Subject: [PATCH 18/33] QMI LOC bug fix on SGLTE OOS IND Change-Id: I4408beede3d05d6cfb1a9a5ead3a44a31b1263cf --- loc_api/loc_api_v02/location_service_v02.c | 5994 +++---- loc_api/loc_api_v02/location_service_v02.h | 15940 +++++++++---------- 2 files changed, 10967 insertions(+), 10967 deletions(-) mode change 100644 => 100755 loc_api/loc_api_v02/location_service_v02.c mode change 100644 => 100755 loc_api/loc_api_v02/location_service_v02.h diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c old mode 100644 new mode 100755 index f1e1b6db..47a63eea --- a/loc_api/loc_api_v02/location_service_v02.c +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -26,3000 +26,3000 @@ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - - L O C A T I O N _ S E R V I C E _ V 0 2 . C - -GENERAL DESCRIPTION - This is the file which defines the loc service Data structures. - - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ - -/* This file was generated with Tool version 5.5 - It was generated on: Thu Sep 20 2012 - From IDL File: location_service_v02.idl */ - -#include "stdint.h" -#include "qmi_idl_lib_internal.h" -#include "location_service_v02.h" -#include "common_v01.h" - - -/*Type Definitions*/ -static const uint8_t qmiLocApplicationIdStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationProvider), - QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02, - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationName), - QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02, - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion_valid), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion), - QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsTimeOfWeekMs), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocDOPStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, PDOP), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, HDOP), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, VDOP), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorUsageIndicatorStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, usageMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, aidingIndicatorMask), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSvInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, validMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, system), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, gnssSvId), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, healthStatus), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svStatus), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svInfoMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, elevation), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, azimuth), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, snr), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQosIncl), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQos), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, numFixes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, timeBetweenFixes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posMode), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), - QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiVxNotifyVerifyStructT_v02, userRespTimerInSeconds), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), - QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplQopStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, validMask), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, horizontalAccuracy), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, verticalAccuracy), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, maxLocAge), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, delay), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, addr), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, port), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), - QMI_LOC_IPV6_ADDR_LENGTH_V02, - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, port), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, suplServerAddrTypeMask), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), - 8, 0, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), - 9, 0, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, valid_flags), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), - 10, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), - QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), - QMI_LOC_NI_SUPL_HASH_LENGTH_V02, - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, posMethod), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), - 6, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), - 6, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), - 7, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), - QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, valid_flags), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, invokeId), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), - QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), - QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, locationType), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), - 12, 0, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), - 12, 0, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, userResponseTimer), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), - 5, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), - QMI_LOC_MAX_NTP_SERVERS_V02, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), - 16, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxFileSizeInBytes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxPartSize), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), - QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), - 16, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorControlConfigSamplingSpecStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, samplesPerBatch), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, batchesPerSecond), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, injectEnable), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), - 20, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGeofencePositionStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, timestampUtc), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, latitude), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, longitude), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMinor), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMajor), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsDataValidityStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, startTimeInUTC), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, durationHours), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocAltitudeSrcInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, source), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, linkage), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, coverage), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocDeleteSvInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, gnssSvId), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, system), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, deleteSvInfoMask), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiFixTimeStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixTimeStructT_v02, wifiPositionTime), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lat), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lon), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, hepe), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, numApsUsed), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, fixErrorCode), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), - QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, rssi), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, channel), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, apQualifier), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLoc3AxisSensorSampleStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, timeOffset), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, xAxis), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, yAxis), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, zAxis), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, timeOfFirstSample), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), - QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), - 29, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), - QMI_LOC_MAX_APN_NAME_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, latitude), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, longitude), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, radius), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocMotionDataStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_mode), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, probability_of_state), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, age), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, timeout), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGSMCellIdStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MCC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MNC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, LAC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, CID), - - QMI_IDL_FLAG_END_VALUE -}; - -/*Message Definitions*/ -static const uint8_t qmiLocGenRespMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGenRespMsgT_v02, resp), - 0, 1 -}; - -static const uint8_t qmiLocInformClientRevisionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformClientRevisionReqMsgT_v02, revision) -}; - -static const uint8_t qmiLocRegEventsReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocRegEventsReqMsgT_v02, eventRegMask) -}; - -static const uint8_t qmiLocStartReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, sessionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId), - 0, 0 -}; - -static const uint8_t qmiLocStopReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocStopReqMsgT_v02, sessionId) -}; - -static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionStatus), - - 0x02, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence_valid)), - 0x16, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal_valid)), - 0x18, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x1A, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x1B, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc_valid)), - 0x1C, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence_valid)), - 0x1D, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability_valid)), - 0x1E, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical_valid)), - 0x1F, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading_valid)), - 0x20, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc_valid)), - 0x21, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation_valid)), - 0x22, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask_valid)), - 0x23, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP_valid)), - 0x24, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), - 2, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), - 0x25, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds_valid)), - 0x26, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime_valid)), - 0x27, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), - 1, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), - 0x28, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc_valid)), - 0x29, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, timeSrc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage_valid)), - 0x2A, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), - 3, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), - 0x2B, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_valid)), - 0x2C, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList), - QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_len) -}; - -static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, altitudeAssumed), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), - QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), - 4, 0 -}; - -static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), - QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 -}; - -static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, notificationType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd) - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), - 5, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), - 11, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), - 13, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), - 14, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd_valid)), - 0x14, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), - 15, 0 -}; - -static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo) - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), - 17, 0 -}; - -static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), - 18, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), - 19, 0 -}; - -static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, latitude), - - 0x02, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, longitude), - - 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x04, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, timestampUtc) -}; - -static const uint8_t qmiLocEventEngineStateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventEngineStateIndMsgT_v02, engineState) -}; - -static const uint8_t qmiLocEventFixSessionStateIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) -}; - -static const uint8_t qmiLocEventWifiReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, requestType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs_valid)), - 0x10, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) -}; - -static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), - 21, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), - 21, 0 -}; - -static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventTimeSyncReqIndMsgT_v02, refCounter) -}; - -static const uint8_t qmiLocEventSetSpiStreamingReportIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventSetSpiStreamingReportIndMsgT_v02, enable) -}; - -static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, connHandle), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, requestType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) -}; - -static const uint8_t qmiLocEventNiGeofenceNotificationIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, operationType) -}; - -static const uint8_t qmiLocEventGeofenceGenAlertIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceGenAlertIndMsgT_v02, geofenceAlert) -}; - -static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofenceId), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, breachType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition) - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), - 22, 0 -}; - -/* - * qmiLocGetServiceRevisionReqMsgT is empty - * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString), - QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString_valid)), - 0x11, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString), - QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_STRING, - QMI_IDL_OFFSET16ARRAY(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString), - QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 -}; - -/* - * qmiLocGetFixCriteriaReqMsgT is empty - * static const uint8_t qmiLocGetFixCriteriaReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId_valid)), - 0x13, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId), - 0, 0 -}; - -static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, userResp), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, notificationType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload) - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), - 5, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), - 11, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), - 13, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), - 14, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload_valid)), - 0x14, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), - 15, 0 -}; - -static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalSize), - - 0x02, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalParts), - - 0x03, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partNum), - - 0x04, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData), - ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) & 0xFF), ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData_len), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType_valid)), - 0x10, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) -}; - -static const uint8_t qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum_valid)), - 0x10, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) -}; - -/* - * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty - * static const uint8_t qmiLocGetPredictedOrbitsDataSourceReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), - 18, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), - 19, 0 -}; - -/* - * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty - * static const uint8_t qmiLocGetPredictedOrbitsDataValidityReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), - 23, 0 -}; - -static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUtc), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUnc) -}; - -static const uint8_t qmiLocInjectUtcTimeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence_valid)), - 0x13, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x16, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence_valid)), - 0x18, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo_valid)), - 0x1A, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), - 24, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), - 0x1B, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge_valid)), - 0x1C, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc_valid)), - 0x1D, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) -}; - -static const uint8_t qmiLocInjectPositionIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetEngineLockReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetEngineLockReqMsgT_v02, lockType) -}; - -static const uint8_t qmiLocSetEngineLockIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetEngineLockIndMsgT_v02, status) -}; - -/* - * qmiLocGetEngineLockReqMsgT is empty - * static const uint8_t qmiLocGetEngineLockReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetEngineLockIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) -}; - -static const uint8_t qmiLocSetSbasConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSbasConfigReqMsgT_v02, sbasConfig) -}; - -static const uint8_t qmiLocSetSbasConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSbasConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetSbasConfigReqMsgT is empty - * static const uint8_t qmiLocGetSbasConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSbasConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) -}; - -static const uint8_t qmiLocSetNmeaTypesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetNmeaTypesReqMsgT_v02, nmeaSentenceType) -}; - -static const uint8_t qmiLocSetNmeaTypesIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetNmeaTypesIndMsgT_v02, status) -}; - -/* - * qmiLocGetNmeaTypesReqMsgT is empty - * static const uint8_t qmiLocGetNmeaTypesReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetNmeaTypesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) -}; - -static const uint8_t qmiLocSetLowPowerModeReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetLowPowerModeReqMsgT_v02, lowPowerMode) -}; - -static const uint8_t qmiLocSetLowPowerModeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetLowPowerModeIndMsgT_v02, status) -}; - -/* - * qmiLocGetLowPowerModeReqMsgT is empty - * static const uint8_t qmiLocGetLowPowerModeReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetLowPowerModeIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) -}; - -static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), - 8, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), - 9, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 -}; - -static const uint8_t qmiLocSetServerIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetServerIndMsgT_v02, status) -}; - -static const uint8_t qmiLocGetServerReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) -}; - -static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, status), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), - 8, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), - 9, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 -}; - -static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteAllFlag), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), - QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), - 25, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) -}; - -static const uint8_t qmiLocDeleteAssistDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetXtraTSessionControlReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlReqMsgT_v02, xtraTSessionControl) -}; - -static const uint8_t qmiLocSetXtraTSessionControlIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlIndMsgT_v02, status) -}; - -/* - * qmiLocGetXtraTSessionControlReqMsgT is empty - * static const uint8_t qmiLocGetXtraTSessionControlReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetXtraTSessionControlIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) -}; - -static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), - 26, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), - 27, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), - QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), - 28, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) -}; - -static const uint8_t qmiLocInjectWifiPositionIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionIndMsgT_v02, status) -}; - -static const uint8_t qmiLocNotifyWifiStatusReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusReqMsgT_v02, wifiStatus) -}; - -static const uint8_t qmiLocNotifyWifiStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusIndMsgT_v02, status) -}; - -/* - * qmiLocGetRegisteredEventsReqMsgT is empty - * static const uint8_t qmiLocGetRegisteredEventsReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetRegisteredEventsIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) -}; - -static const uint8_t qmiLocSetOperationModeReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetOperationModeReqMsgT_v02, operationMode) -}; - -static const uint8_t qmiLocSetOperationModeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetOperationModeIndMsgT_v02, status) -}; - -/* - * qmiLocGetOperationModeReqMsgT is empty - * static const uint8_t qmiLocGetOperationModeReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetOperationModeIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) -}; - -static const uint8_t qmiLocSetSpiStatusReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, stationary), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) -}; - -static const uint8_t qmiLocSetSpiStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), - 30, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), - 30, 0 -}; - -static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) -}; - -static const uint8_t qmiLocInjectTimeSyncDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, refCounter), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcRxTime), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcTxTime) -}; - -static const uint8_t qmiLocInjectTimeSyncDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataIndMsgT_v02, status) -}; - -/* - * qmiLocGetCradleMountConfigReqMsgT is empty - * static const uint8_t qmiLocGetCradleMountConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetCradleMountConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) -}; - -static const uint8_t qmiLocSetCradleMountConfigReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, cradleMountState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) -}; - -static const uint8_t qmiLocSetCradleMountConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetExternalPowerConfigReqMsgT is empty - * static const uint8_t qmiLocGetExternalPowerConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetExternalPowerConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) -}; - -static const uint8_t qmiLocSetExternalPowerConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigReqMsgT_v02, externalPowerState) -}; - -static const uint8_t qmiLocSetExternalPowerConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, connHandle), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, requestType), - - 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, statusType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile) - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), - 31, 0 -}; - -static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) -}; - -static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) -}; - -static const uint8_t qmiLocGetProtocolConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersReqMsgT_v02, getProtocolConfigParamMask) -}; - -static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) -}; - -static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) -}; - -static const uint8_t qmiLocSetSensorControlConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetSensorControlConfigReqMsgT is empty - * static const uint8_t qmiLocGetSensorControlConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) -}; - -static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) -}; - -static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) -}; - -static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesReqMsgT_v02, getSensorPropertiesMask) -}; - -static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) -}; - -static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), - 0x12, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), - 20, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), - 0x15, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), - 20, 0 -}; - -static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) -}; - -/* - * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty - * static const uint8_t qmiLocGetSensorPerformanceControlConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), - 0x12, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), - 20, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), - 0x15, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), - 20, 0 -}; - -static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData), - ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData) - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData_len) -}; - -static const uint8_t qmiLocInjectSuplCertificateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateIndMsgT_v02, status) -}; - -static const uint8_t qmiLocDeleteSuplCertificateReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) -}; - -static const uint8_t qmiLocDeleteSuplCertificateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) -}; - -static const uint8_t qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) -}; - -static const uint8_t qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersReqMsgT_v02, getPositionEngineConfigParamMask) -}; - -static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) -}; - -static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, transactionId), - - 0x02, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), - 32, 0, - - 0x03, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, breachMask), - - 0x04, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, includePosition), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) -}; - -static const uint8_t qmiLocAddCircularGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) -}; - -static const uint8_t qmiLocDeleteGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocDeleteGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocQueryGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), - 32, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) -}; - -static const uint8_t qmiLocEditGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceId), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) -}; - -static const uint8_t qmiLocEditGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) -}; - -static const uint8_t qmiLocGetBestAvailablePositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude_valid)), - 0x12, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc_valid)), - 0x16, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor_valid)), - 0x18, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), - 0x1A, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence_valid)), - 0x1B, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence_valid)), - 0x1C, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability_valid)), - 0x1D, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed_valid)), - 0x1E, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc_valid)), - 0x1F, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x20, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence_valid)), - 0x21, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability_valid)), - 0x22, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed_valid)), - 0x23, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc_valid)), - 0x24, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading_valid)), - 0x25, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc_valid)), - 0x26, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation_valid)), - 0x27, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask_valid)), - 0x28, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP_valid)), - 0x29, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP), - 2, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime_valid)), - 0x2A, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime), - 1, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc_valid)), - 0x2B, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage_valid)), - 0x2C, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage), - 3, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_valid)), - 0x2D, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList), - QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) -}; - -static const uint8_t qmiLocInjectMotionDataReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectMotionDataReqMsgT_v02, motion_data), - 33, 0 -}; - -static const uint8_t qmiLocInjectMotionDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectMotionDataIndMsgT_v02, status) -}; - -static const uint8_t qmiLocGetNiGeofenceIdListReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_valid)), - 0x11, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList), - QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) -}; - -static const uint8_t qmiLocInjectGSMCellInfoReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, gsmCellId), - 34, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, roamingStatus) -}; - -static const uint8_t qmiLocInjectGSMCellInfoIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessageType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage), - ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage) - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage_len) -}; - -static const uint8_t qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02, status) -}; - -/* - * qmiLocWWANOutOfServiceNotificationReqMsgT is empty - * static const uint8_t qmiLocWWANOutOfServiceNotificationReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWWANOutOfServiceNotificationIndMsgT_v02, status) -}; - -/* Type Table */ -static const qmi_idl_type_table_entry loc_type_table_v02[] = { - {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, - {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, - {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, - {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, - {sizeof(qmiLocSvInfoStructT_v02), qmiLocSvInfoStructT_data_v02}, - {sizeof(qmiLocNiVxNotifyVerifyStructT_v02), qmiLocNiVxNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiSuplFormattedStringStructT_v02), qmiLocNiSuplFormattedStringStructT_data_v02}, - {sizeof(qmiLocNiSuplQopStructT_v02), qmiLocNiSuplQopStructT_data_v02}, - {sizeof(qmiLocIpV4AddrStructType_v02), qmiLocIpV4AddrStructType_data_v02}, - {sizeof(qmiLocIpV6AddrStructType_v02), qmiLocIpV6AddrStructType_data_v02}, - {sizeof(qmiLocNiSuplServerInfoStructT_v02), qmiLocNiSuplServerInfoStructT_data_v02}, - {sizeof(qmiLocNiSuplNotifyVerifyStructT_v02), qmiLocNiSuplNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, - {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, - {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, - {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, - {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, - {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, - {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, - {sizeof(qmiLocGeofencePositionStructT_v02), qmiLocGeofencePositionStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, - {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, - {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, - {sizeof(qmiLocWifiFixTimeStructT_v02), qmiLocWifiFixTimeStructT_data_v02}, - {sizeof(qmiLocWifiFixPosStructT_v02), qmiLocWifiFixPosStructT_data_v02}, - {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, - {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, - {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, - {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, - {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, - {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02}, - {sizeof(qmiLocGSMCellIdStructT_v02), qmiLocGSMCellIdStructT_data_v02} -}; - -/* Message Table */ -static const qmi_idl_message_table_entry loc_message_table_v02[] = { - {sizeof(qmiLocGenRespMsgT_v02), qmiLocGenRespMsgT_data_v02}, - {sizeof(qmiLocInformClientRevisionReqMsgT_v02), qmiLocInformClientRevisionReqMsgT_data_v02}, - {sizeof(qmiLocRegEventsReqMsgT_v02), qmiLocRegEventsReqMsgT_data_v02}, - {sizeof(qmiLocStartReqMsgT_v02), qmiLocStartReqMsgT_data_v02}, - {sizeof(qmiLocStopReqMsgT_v02), qmiLocStopReqMsgT_data_v02}, - {sizeof(qmiLocEventPositionReportIndMsgT_v02), qmiLocEventPositionReportIndMsgT_data_v02}, - {sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), qmiLocEventGnssSvInfoIndMsgT_data_v02}, - {sizeof(qmiLocEventNmeaIndMsgT_v02), qmiLocEventNmeaIndMsgT_data_v02}, - {sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), qmiLocEventInjectTimeReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), qmiLocEventInjectPositionReqIndMsgT_data_v02}, - {sizeof(qmiLocEventEngineStateIndMsgT_v02), qmiLocEventEngineStateIndMsgT_data_v02}, - {sizeof(qmiLocEventFixSessionStateIndMsgT_v02), qmiLocEventFixSessionStateIndMsgT_data_v02}, - {sizeof(qmiLocEventWifiReqIndMsgT_v02), qmiLocEventWifiReqIndMsgT_data_v02}, - {sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02}, - {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, - {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, - {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, - {sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), qmiLocEventNiGeofenceNotificationIndMsgT_data_v02}, - {sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), qmiLocEventGeofenceGenAlertIndMsgT_data_v02}, - {sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), qmiLocEventGeofenceBreachIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetFixCriteriaIndMsgT_v02), qmiLocGetFixCriteriaIndMsgT_data_v02}, - {sizeof(qmiLocNiUserRespReqMsgT_v02), qmiLocNiUserRespReqMsgT_data_v02}, - {sizeof(qmiLocNiUserRespIndMsgT_v02), qmiLocNiUserRespIndMsgT_data_v02}, - {sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02), qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02), qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02), qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02), qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02}, - {sizeof(qmiLocInjectUtcTimeReqMsgT_v02), qmiLocInjectUtcTimeReqMsgT_data_v02}, - {sizeof(qmiLocInjectUtcTimeIndMsgT_v02), qmiLocInjectUtcTimeIndMsgT_data_v02}, - {sizeof(qmiLocInjectPositionReqMsgT_v02), qmiLocInjectPositionReqMsgT_data_v02}, - {sizeof(qmiLocInjectPositionIndMsgT_v02), qmiLocInjectPositionIndMsgT_data_v02}, - {sizeof(qmiLocSetEngineLockReqMsgT_v02), qmiLocSetEngineLockReqMsgT_data_v02}, - {sizeof(qmiLocSetEngineLockIndMsgT_v02), qmiLocSetEngineLockIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetEngineLockIndMsgT_v02), qmiLocGetEngineLockIndMsgT_data_v02}, - {sizeof(qmiLocSetSbasConfigReqMsgT_v02), qmiLocSetSbasConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSbasConfigIndMsgT_v02), qmiLocSetSbasConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSbasConfigIndMsgT_v02), qmiLocGetSbasConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetNmeaTypesReqMsgT_v02), qmiLocSetNmeaTypesReqMsgT_data_v02}, - {sizeof(qmiLocSetNmeaTypesIndMsgT_v02), qmiLocSetNmeaTypesIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetNmeaTypesIndMsgT_v02), qmiLocGetNmeaTypesIndMsgT_data_v02}, - {sizeof(qmiLocSetLowPowerModeReqMsgT_v02), qmiLocSetLowPowerModeReqMsgT_data_v02}, - {sizeof(qmiLocSetLowPowerModeIndMsgT_v02), qmiLocSetLowPowerModeIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetLowPowerModeIndMsgT_v02), qmiLocGetLowPowerModeIndMsgT_data_v02}, - {sizeof(qmiLocSetServerReqMsgT_v02), qmiLocSetServerReqMsgT_data_v02}, - {sizeof(qmiLocSetServerIndMsgT_v02), qmiLocSetServerIndMsgT_data_v02}, - {sizeof(qmiLocGetServerReqMsgT_v02), qmiLocGetServerReqMsgT_data_v02}, - {sizeof(qmiLocGetServerIndMsgT_v02), qmiLocGetServerIndMsgT_data_v02}, - {sizeof(qmiLocDeleteAssistDataReqMsgT_v02), qmiLocDeleteAssistDataReqMsgT_data_v02}, - {sizeof(qmiLocDeleteAssistDataIndMsgT_v02), qmiLocDeleteAssistDataIndMsgT_data_v02}, - {sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02), qmiLocSetXtraTSessionControlReqMsgT_data_v02}, - {sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02), qmiLocSetXtraTSessionControlIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02), qmiLocGetXtraTSessionControlIndMsgT_data_v02}, - {sizeof(qmiLocInjectWifiPositionReqMsgT_v02), qmiLocInjectWifiPositionReqMsgT_data_v02}, - {sizeof(qmiLocInjectWifiPositionIndMsgT_v02), qmiLocInjectWifiPositionIndMsgT_data_v02}, - {sizeof(qmiLocNotifyWifiStatusReqMsgT_v02), qmiLocNotifyWifiStatusReqMsgT_data_v02}, - {sizeof(qmiLocNotifyWifiStatusIndMsgT_v02), qmiLocNotifyWifiStatusIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetRegisteredEventsIndMsgT_v02), qmiLocGetRegisteredEventsIndMsgT_data_v02}, - {sizeof(qmiLocSetOperationModeReqMsgT_v02), qmiLocSetOperationModeReqMsgT_data_v02}, - {sizeof(qmiLocSetOperationModeIndMsgT_v02), qmiLocSetOperationModeIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetOperationModeIndMsgT_v02), qmiLocGetOperationModeIndMsgT_data_v02}, - {sizeof(qmiLocSetSpiStatusReqMsgT_v02), qmiLocSetSpiStatusReqMsgT_data_v02}, - {sizeof(qmiLocSetSpiStatusIndMsgT_v02), qmiLocSetSpiStatusIndMsgT_data_v02}, - {sizeof(qmiLocInjectSensorDataReqMsgT_v02), qmiLocInjectSensorDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectSensorDataIndMsgT_v02), qmiLocInjectSensorDataIndMsgT_data_v02}, - {sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02), qmiLocInjectTimeSyncDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02), qmiLocInjectTimeSyncDataIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetCradleMountConfigIndMsgT_v02), qmiLocGetCradleMountConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetCradleMountConfigReqMsgT_v02), qmiLocSetCradleMountConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetCradleMountConfigIndMsgT_v02), qmiLocSetCradleMountConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02), qmiLocGetExternalPowerConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02), qmiLocSetExternalPowerConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02), qmiLocSetExternalPowerConfigIndMsgT_data_v02}, - {sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02), qmiLocInformLocationServerConnStatusReqMsgT_data_v02}, - {sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02), qmiLocInformLocationServerConnStatusIndMsgT_data_v02}, - {sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02), qmiLocSetProtocolConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02), qmiLocSetProtocolConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02), qmiLocGetProtocolConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02), qmiLocGetProtocolConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorControlConfigReqMsgT_v02), qmiLocSetSensorControlConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorControlConfigIndMsgT_v02), qmiLocSetSensorControlConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, - {sizeof(qmiLocGetSensorPropertiesReqMsgT_v02), qmiLocGetSensorPropertiesReqMsgT_data_v02}, - {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02), qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02}, - {sizeof(qmiLocInjectSuplCertificateReqMsgT_v02), qmiLocInjectSuplCertificateReqMsgT_data_v02}, - {sizeof(qmiLocInjectSuplCertificateIndMsgT_v02), qmiLocInjectSuplCertificateIndMsgT_data_v02}, - {sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02), qmiLocDeleteSuplCertificateReqMsgT_data_v02}, - {sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02), qmiLocDeleteSuplCertificateIndMsgT_data_v02}, - {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocAddCircularGeofenceReqMsgT_v02), qmiLocAddCircularGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocAddCircularGeofenceIndMsgT_v02), qmiLocAddCircularGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocDeleteGeofenceReqMsgT_v02), qmiLocDeleteGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocDeleteGeofenceIndMsgT_v02), qmiLocDeleteGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocQueryGeofenceReqMsgT_v02), qmiLocQueryGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocQueryGeofenceIndMsgT_v02), qmiLocQueryGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, - {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02}, - {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, - {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, - {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02}, - {sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02), qmiLocInjectGSMCellInfoReqMsgT_data_v02}, - {sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02), qmiLocInjectGSMCellInfoIndMsgT_data_v02}, - {sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02), qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02}, - {sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02), qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02), qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02} -}; - -/* Predefine the Type Table Object */ -static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02; - -/*Referenced Tables Array*/ -static const qmi_idl_type_table_object *loc_qmi_idl_type_table_object_referenced_tables_v02[] = -{&loc_qmi_idl_type_table_object_v02, &common_qmi_idl_type_table_object_v01}; - -/*Type Table Object*/ -static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { - sizeof(loc_type_table_v02)/sizeof(qmi_idl_type_table_entry ), - sizeof(loc_message_table_v02)/sizeof(qmi_idl_message_table_entry), - 1, - loc_type_table_v02, - loc_message_table_v02, - loc_qmi_idl_type_table_object_referenced_tables_v02 -}; - -/*Arrays of service_message_table_entries for commands, responses and indications*/ -static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { - {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, - {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, - {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 103}, - {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, - {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 22), 0}, - {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 24), 0}, - {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 26), 1086}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 28), 1053}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 30), 0}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 32), 0}, - {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 34), 18}, - {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 36), 112}, - {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 38), 7}, - {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 40), 0}, - {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 42), 4}, - {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 44), 0}, - {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 46), 7}, - {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 48), 0}, - {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 50), 4}, - {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 52), 0}, - {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 54), 297}, - {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 56), 11}, - {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 58), 929}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 60), 4}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 62), 0}, - {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 64), 694}, - {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 66), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 68), 0}, - {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 70), 7}, - {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 72), 0}, - {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 74), 8}, - {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 76), 1425}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 78), 21}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 82), 11}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 80), 0}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 32}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, - {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, - {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 42}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 110), 12}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 112), 7}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02, TYPE16(0, 114), 52}, - {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, - {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, - {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, - {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7}, - {QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02, TYPE16(0, 128), 23}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02, TYPE16(0, 130), 1036}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02, TYPE16(0, 132), 0} -}; - -static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { - {QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_REG_EVENTS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_START_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_STOP_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SERVICE_REVISION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_FIX_CRITERIA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_NI_USER_RESPONSE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_UTC_TIME_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SERVER_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SERVER_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_ASSIST_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_WIFI_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SPI_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_SENSOR_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02, TYPE16(0, 0), 7} -}; - -static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { - {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 388}, - {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, - {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, - {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1079}, - {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, - {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, - {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, - {QMI_LOC_EVENT_ENGINE_STATE_IND_V02, TYPE16(0, 12), 7}, - {QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, TYPE16(0, 13), 11}, - {QMI_LOC_EVENT_WIFI_REQ_IND_V02, TYPE16(0, 14), 12}, - {QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, TYPE16(0, 15), 16}, - {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, - {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, - {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, - {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 23), 532}, - {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 25), 99}, - {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 27), 7}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 29), 12}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 31), 790}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 33), 20}, - {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 35), 7}, - {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 37), 7}, - {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 39), 7}, - {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 41), 14}, - {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 43), 7}, - {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 45), 11}, - {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 47), 7}, - {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 49), 14}, - {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 51), 7}, - {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 53), 11}, - {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 55), 7}, - {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 57), 304}, - {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 59), 7}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 61), 7}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 63), 11}, - {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 65), 7}, - {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 67), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 69), 18}, - {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 71), 7}, - {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 73), 14}, - {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 75), 7}, - {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 77), 22}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 79), 7}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 83), 7}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 81), 18}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 87), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 39}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, - {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, - {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 49}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 113), 19}, - {QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, TYPE16(0, 19), 14}, - {QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, TYPE16(0, 20), 7}, - {QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, TYPE16(0, 21), 78}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, TYPE16(0, 115), 21}, - {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, - {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, - {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, - {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82}, - {QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, TYPE16(0, 129), 7}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, TYPE16(0, 131), 7}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, TYPE16(0, 132), 0} -}; - -/*Service Object*/ -struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { - 0x05, - 0x02, - 0x10, - 2248, - { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), - sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), - sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, - { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, - &loc_qmi_idl_type_table_object_v02, - 0x0F, - NULL -}; - -/* Service Object Accessor */ -qmi_idl_service_object_type loc_get_service_object_internal_v02 - ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ){ - if ( LOC_V02_IDL_MAJOR_VERS != idl_maj_version || LOC_V02_IDL_MINOR_VERS != idl_min_version - || LOC_V02_IDL_TOOL_VERS != library_version) - { - return NULL; - } - return (qmi_idl_service_object_type)&loc_qmi_idl_service_object_v02; -} - +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + + L O C A T I O N _ S E R V I C E _ V 0 2 . C + +GENERAL DESCRIPTION + This is the file which defines the loc service Data structures. + + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.5 + It was generated on: Thu Sep 27 2012 + From IDL File: location_service_v02.idl */ + +#include "stdint.h" +#include "qmi_idl_lib_internal.h" +#include "location_service_v02.h" +#include "common_v01.h" + + +/*Type Definitions*/ +static const uint8_t qmiLocApplicationIdStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationProvider), + QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02, + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationName), + QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02, + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion_valid), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion), + QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsTimeOfWeekMs), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDOPStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, PDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, HDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, VDOP), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorUsageIndicatorStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, usageMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, aidingIndicatorMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, validMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, healthStatus), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svStatus), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svInfoMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, elevation), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, azimuth), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, snr), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQosIncl), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQos), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, numFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, timeBetweenFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posMode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), + QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxNotifyVerifyStructT_v02, userRespTimerInSeconds), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplQopStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, validMask), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, horizontalAccuracy), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, verticalAccuracy), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, maxLocAge), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, delay), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, addr), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), + QMI_LOC_IPV6_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, suplServerAddrTypeMask), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), + 8, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), + 9, 0, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), + 10, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), + QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), + QMI_LOC_NI_SUPL_HASH_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, posMethod), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), + 6, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), + 6, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), + 7, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), + QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, invokeId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), + QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, locationType), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), + 12, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), + 12, 0, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), + 5, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), + QMI_LOC_MAX_NTP_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), + 16, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxFileSizeInBytes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxPartSize), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), + QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), + 16, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorControlConfigSamplingSpecStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, samplesPerBatch), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, batchesPerSecond), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, injectEnable), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), + 20, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGeofencePositionStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, timestampUtc), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMinor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMajor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsDataValidityStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, startTimeInUTC), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, durationHours), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAltitudeSrcInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, source), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, linkage), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, coverage), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDeleteSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, deleteSvInfoMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixTimeStructT_v02, wifiPositionTime), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lat), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lon), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, hepe), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, numApsUsed), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, fixErrorCode), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), + QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, rssi), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, channel), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, apQualifier), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, timeOffset), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, xAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, yAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, zAxis), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, timeOfFirstSample), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), + QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), + 29, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), + QMI_LOC_MAX_APN_NAME_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, radius), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocMotionDataStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_mode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, probability_of_state), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, age), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, timeout), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGSMCellIdStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MCC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MNC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, LAC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, CID), + + QMI_IDL_FLAG_END_VALUE +}; + +/*Message Definitions*/ +static const uint8_t qmiLocGenRespMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGenRespMsgT_v02, resp), + 0, 1 +}; + +static const uint8_t qmiLocInformClientRevisionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformClientRevisionReqMsgT_v02, revision) +}; + +static const uint8_t qmiLocRegEventsReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocRegEventsReqMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocStartReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId), + 0, 0 +}; + +static const uint8_t qmiLocStopReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStopReqMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionStatus), + + 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence_valid)), + 0x16, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x1B, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence_valid)), + 0x1D, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc_valid)), + 0x21, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP_valid)), + 0x24, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), + 2, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), + 0x25, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds_valid)), + 0x26, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime_valid)), + 0x27, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc_valid)), + 0x29, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), + 3, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_valid)), + 0x2C, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_len) +}; + +static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, altitudeAssumed), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), + QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), + 4, 0 +}; + +static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), + QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 +}; + +static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd) - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), + 5, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), + 11, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), + 13, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), + 14, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), + 15, 0 +}; + +static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo) - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), + 17, 0 +}; + +static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), + 19, 0 +}; + +static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, latitude), + + 0x02, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, longitude), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x04, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, timestampUtc) +}; + +static const uint8_t qmiLocEventEngineStateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventEngineStateIndMsgT_v02, engineState) +}; + +static const uint8_t qmiLocEventFixSessionStateIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventWifiReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) +}; + +static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), + 21, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), + 21, 0 +}; + +static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventTimeSyncReqIndMsgT_v02, refCounter) +}; + +static const uint8_t qmiLocEventSetSpiStreamingReportIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventSetSpiStreamingReportIndMsgT_v02, enable) +}; + +static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) +}; + +static const uint8_t qmiLocEventNiGeofenceNotificationIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, operationType) +}; + +static const uint8_t qmiLocEventGeofenceGenAlertIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceGenAlertIndMsgT_v02, geofenceAlert) +}; + +static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, breachType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition) - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), + 22, 0 +}; + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString), + QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString), + QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_STRING, + QMI_IDL_OFFSET16ARRAY(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString), + QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 +}; + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * static const uint8_t qmiLocGetFixCriteriaReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId_valid)), + 0x13, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId), + 0, 0 +}; + +static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, userResp), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload) - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), + 5, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), + 11, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), + 13, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), + 14, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), + 15, 0 +}; + +static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalSize), + + 0x02, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalParts), + + 0x03, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partNum), + + 0x04, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData), + ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) & 0xFF), ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData_len), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType_valid)), + 0x10, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) +}; + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataSourceReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), + 19, 0 +}; + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataValidityReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), + 23, 0 +}; + +static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUtc), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUnc) +}; + +static const uint8_t qmiLocInjectUtcTimeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence_valid)), + 0x13, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x16, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence_valid)), + 0x18, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo_valid)), + 0x1A, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), + 24, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), + 0x1B, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) +}; + +static const uint8_t qmiLocInjectPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetEngineLockReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockReqMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetEngineLockIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockIndMsgT_v02, status) +}; + +/* + * qmiLocGetEngineLockReqMsgT is empty + * static const uint8_t qmiLocGetEngineLockReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetEngineLockIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetSbasConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigReqMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetSbasConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * static const uint8_t qmiLocGetSbasConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSbasConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetNmeaTypesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesReqMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetNmeaTypesIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesIndMsgT_v02, status) +}; + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * static const uint8_t qmiLocGetNmeaTypesReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetNmeaTypesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetLowPowerModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeReqMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetLowPowerModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * static const uint8_t qmiLocGetLowPowerModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetLowPowerModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), + 9, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocSetServerIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) +}; + +static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, status), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), + 9, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteAllFlag), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), + QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), + 25, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) +}; + +static const uint8_t qmiLocDeleteAssistDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetXtraTSessionControlReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlReqMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocSetXtraTSessionControlIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlIndMsgT_v02, status) +}; + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * static const uint8_t qmiLocGetXtraTSessionControlReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetXtraTSessionControlIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), + 26, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), + 27, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), + QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), + 28, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) +}; + +static const uint8_t qmiLocInjectWifiPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocNotifyWifiStatusReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusReqMsgT_v02, wifiStatus) +}; + +static const uint8_t qmiLocNotifyWifiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusIndMsgT_v02, status) +}; + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * static const uint8_t qmiLocGetRegisteredEventsReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetRegisteredEventsIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocSetOperationModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeReqMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetOperationModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetOperationModeReqMsgT is empty + * static const uint8_t qmiLocGetOperationModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetOperationModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetSpiStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, stationary), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) +}; + +static const uint8_t qmiLocSetSpiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), + 30, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), + 30, 0 +}; + +static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) +}; + +static const uint8_t qmiLocInjectTimeSyncDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, refCounter), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcRxTime), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcTxTime) +}; + +static const uint8_t qmiLocInjectTimeSyncDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataIndMsgT_v02, status) +}; + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * static const uint8_t qmiLocGetCradleMountConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetCradleMountConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * static const uint8_t qmiLocGetExternalPowerConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetExternalPowerConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigReqMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, requestType), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, statusType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile) - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), + 31, 0 +}; + +static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersReqMsgT_v02, getProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) +}; + +static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorControlConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) +}; + +static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) +}; + +static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesReqMsgT_v02, getSensorPropertiesMask) +}; + +static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), + 20, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), + 20, 0 +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) +}; + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), + 20, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), + 20, 0 +}; + +static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData), + ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData) - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData_len) +}; + +static const uint8_t qmiLocInjectSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocDeleteSuplCertificateReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) +}; + +static const uint8_t qmiLocDeleteSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersReqMsgT_v02, getPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) +}; + +static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, transactionId), + + 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), + 32, 0, + + 0x03, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, breachMask), + + 0x04, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, includePosition), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) +}; + +static const uint8_t qmiLocAddCircularGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) +}; + +static const uint8_t qmiLocDeleteGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocDeleteGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), + 32, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) +}; + +static const uint8_t qmiLocEditGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) +}; + +static const uint8_t qmiLocEditGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) +}; + +static const uint8_t qmiLocGetBestAvailablePositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude_valid)), + 0x12, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc_valid)), + 0x16, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence_valid)), + 0x1B, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence_valid)), + 0x1C, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence_valid)), + 0x21, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc_valid)), + 0x24, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading_valid)), + 0x25, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc_valid)), + 0x26, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation_valid)), + 0x27, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP_valid)), + 0x29, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP), + 2, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage_valid)), + 0x2C, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage), + 3, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_valid)), + 0x2D, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) +}; + +static const uint8_t qmiLocInjectMotionDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataReqMsgT_v02, motion_data), + 33, 0 +}; + +static const uint8_t qmiLocInjectMotionDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList), + QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) +}; + +static const uint8_t qmiLocInjectGSMCellInfoReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, gsmCellId), + 34, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, roamingStatus) +}; + +static const uint8_t qmiLocInjectGSMCellInfoIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessageType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage), + ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage) - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage_len) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02, status) +}; + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * static const uint8_t qmiLocWWANOutOfServiceNotificationReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWWANOutOfServiceNotificationIndMsgT_v02, status) +}; + +/* Type Table */ +static const qmi_idl_type_table_entry loc_type_table_v02[] = { + {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, + {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, + {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, + {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, + {sizeof(qmiLocSvInfoStructT_v02), qmiLocSvInfoStructT_data_v02}, + {sizeof(qmiLocNiVxNotifyVerifyStructT_v02), qmiLocNiVxNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiSuplFormattedStringStructT_v02), qmiLocNiSuplFormattedStringStructT_data_v02}, + {sizeof(qmiLocNiSuplQopStructT_v02), qmiLocNiSuplQopStructT_data_v02}, + {sizeof(qmiLocIpV4AddrStructType_v02), qmiLocIpV4AddrStructType_data_v02}, + {sizeof(qmiLocIpV6AddrStructType_v02), qmiLocIpV6AddrStructType_data_v02}, + {sizeof(qmiLocNiSuplServerInfoStructT_v02), qmiLocNiSuplServerInfoStructT_data_v02}, + {sizeof(qmiLocNiSuplNotifyVerifyStructT_v02), qmiLocNiSuplNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, + {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, + {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, + {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, + {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, + {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, + {sizeof(qmiLocGeofencePositionStructT_v02), qmiLocGeofencePositionStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, + {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, + {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, + {sizeof(qmiLocWifiFixTimeStructT_v02), qmiLocWifiFixTimeStructT_data_v02}, + {sizeof(qmiLocWifiFixPosStructT_v02), qmiLocWifiFixPosStructT_data_v02}, + {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, + {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, + {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, + {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02}, + {sizeof(qmiLocGSMCellIdStructT_v02), qmiLocGSMCellIdStructT_data_v02} +}; + +/* Message Table */ +static const qmi_idl_message_table_entry loc_message_table_v02[] = { + {sizeof(qmiLocGenRespMsgT_v02), qmiLocGenRespMsgT_data_v02}, + {sizeof(qmiLocInformClientRevisionReqMsgT_v02), qmiLocInformClientRevisionReqMsgT_data_v02}, + {sizeof(qmiLocRegEventsReqMsgT_v02), qmiLocRegEventsReqMsgT_data_v02}, + {sizeof(qmiLocStartReqMsgT_v02), qmiLocStartReqMsgT_data_v02}, + {sizeof(qmiLocStopReqMsgT_v02), qmiLocStopReqMsgT_data_v02}, + {sizeof(qmiLocEventPositionReportIndMsgT_v02), qmiLocEventPositionReportIndMsgT_data_v02}, + {sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), qmiLocEventGnssSvInfoIndMsgT_data_v02}, + {sizeof(qmiLocEventNmeaIndMsgT_v02), qmiLocEventNmeaIndMsgT_data_v02}, + {sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), qmiLocEventInjectTimeReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), qmiLocEventInjectPositionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventEngineStateIndMsgT_v02), qmiLocEventEngineStateIndMsgT_data_v02}, + {sizeof(qmiLocEventFixSessionStateIndMsgT_v02), qmiLocEventFixSessionStateIndMsgT_data_v02}, + {sizeof(qmiLocEventWifiReqIndMsgT_v02), qmiLocEventWifiReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02}, + {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, + {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), qmiLocEventNiGeofenceNotificationIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), qmiLocEventGeofenceGenAlertIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), qmiLocEventGeofenceBreachIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetFixCriteriaIndMsgT_v02), qmiLocGetFixCriteriaIndMsgT_data_v02}, + {sizeof(qmiLocNiUserRespReqMsgT_v02), qmiLocNiUserRespReqMsgT_data_v02}, + {sizeof(qmiLocNiUserRespIndMsgT_v02), qmiLocNiUserRespIndMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02), qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02), qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02), qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02), qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeReqMsgT_v02), qmiLocInjectUtcTimeReqMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeIndMsgT_v02), qmiLocInjectUtcTimeIndMsgT_data_v02}, + {sizeof(qmiLocInjectPositionReqMsgT_v02), qmiLocInjectPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectPositionIndMsgT_v02), qmiLocInjectPositionIndMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockReqMsgT_v02), qmiLocSetEngineLockReqMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockIndMsgT_v02), qmiLocSetEngineLockIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetEngineLockIndMsgT_v02), qmiLocGetEngineLockIndMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigReqMsgT_v02), qmiLocSetSbasConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigIndMsgT_v02), qmiLocSetSbasConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSbasConfigIndMsgT_v02), qmiLocGetSbasConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesReqMsgT_v02), qmiLocSetNmeaTypesReqMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesIndMsgT_v02), qmiLocSetNmeaTypesIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetNmeaTypesIndMsgT_v02), qmiLocGetNmeaTypesIndMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeReqMsgT_v02), qmiLocSetLowPowerModeReqMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeIndMsgT_v02), qmiLocSetLowPowerModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetLowPowerModeIndMsgT_v02), qmiLocGetLowPowerModeIndMsgT_data_v02}, + {sizeof(qmiLocSetServerReqMsgT_v02), qmiLocSetServerReqMsgT_data_v02}, + {sizeof(qmiLocSetServerIndMsgT_v02), qmiLocSetServerIndMsgT_data_v02}, + {sizeof(qmiLocGetServerReqMsgT_v02), qmiLocGetServerReqMsgT_data_v02}, + {sizeof(qmiLocGetServerIndMsgT_v02), qmiLocGetServerIndMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataReqMsgT_v02), qmiLocDeleteAssistDataReqMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataIndMsgT_v02), qmiLocDeleteAssistDataIndMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02), qmiLocSetXtraTSessionControlReqMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02), qmiLocSetXtraTSessionControlIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02), qmiLocGetXtraTSessionControlIndMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionReqMsgT_v02), qmiLocInjectWifiPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionIndMsgT_v02), qmiLocInjectWifiPositionIndMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusReqMsgT_v02), qmiLocNotifyWifiStatusReqMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusIndMsgT_v02), qmiLocNotifyWifiStatusIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetRegisteredEventsIndMsgT_v02), qmiLocGetRegisteredEventsIndMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeReqMsgT_v02), qmiLocSetOperationModeReqMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeIndMsgT_v02), qmiLocSetOperationModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetOperationModeIndMsgT_v02), qmiLocGetOperationModeIndMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusReqMsgT_v02), qmiLocSetSpiStatusReqMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusIndMsgT_v02), qmiLocSetSpiStatusIndMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataReqMsgT_v02), qmiLocInjectSensorDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataIndMsgT_v02), qmiLocInjectSensorDataIndMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02), qmiLocInjectTimeSyncDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02), qmiLocInjectTimeSyncDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetCradleMountConfigIndMsgT_v02), qmiLocGetCradleMountConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigReqMsgT_v02), qmiLocSetCradleMountConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigIndMsgT_v02), qmiLocSetCradleMountConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02), qmiLocGetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02), qmiLocSetExternalPowerConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02), qmiLocSetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02), qmiLocInformLocationServerConnStatusReqMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02), qmiLocInformLocationServerConnStatusIndMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02), qmiLocSetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02), qmiLocSetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02), qmiLocGetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02), qmiLocGetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigReqMsgT_v02), qmiLocSetSensorControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigIndMsgT_v02), qmiLocSetSensorControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, + {sizeof(qmiLocGetSensorPropertiesReqMsgT_v02), qmiLocGetSensorPropertiesReqMsgT_data_v02}, + {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02), qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateReqMsgT_v02), qmiLocInjectSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateIndMsgT_v02), qmiLocInjectSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02), qmiLocDeleteSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02), qmiLocDeleteSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceReqMsgT_v02), qmiLocAddCircularGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceIndMsgT_v02), qmiLocAddCircularGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceReqMsgT_v02), qmiLocDeleteGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceIndMsgT_v02), qmiLocDeleteGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceReqMsgT_v02), qmiLocQueryGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceIndMsgT_v02), qmiLocQueryGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02), qmiLocInjectGSMCellInfoReqMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02), qmiLocInjectGSMCellInfoIndMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02), qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02), qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02), qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02} +}; + +/* Predefine the Type Table Object */ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02; + +/*Referenced Tables Array*/ +static const qmi_idl_type_table_object *loc_qmi_idl_type_table_object_referenced_tables_v02[] = +{&loc_qmi_idl_type_table_object_v02, &common_qmi_idl_type_table_object_v01}; + +/*Type Table Object*/ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { + sizeof(loc_type_table_v02)/sizeof(qmi_idl_type_table_entry ), + sizeof(loc_message_table_v02)/sizeof(qmi_idl_message_table_entry), + 1, + loc_type_table_v02, + loc_message_table_v02, + loc_qmi_idl_type_table_object_referenced_tables_v02 +}; + +/*Arrays of service_message_table_entries for commands, responses and indications*/ +static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, + {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, + {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 103}, + {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, + {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 22), 0}, + {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 24), 0}, + {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 26), 1086}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 28), 1053}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 30), 0}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 32), 0}, + {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 34), 18}, + {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 36), 112}, + {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 38), 7}, + {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 40), 0}, + {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 42), 4}, + {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 44), 0}, + {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 46), 7}, + {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 48), 0}, + {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 50), 4}, + {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 52), 0}, + {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 54), 297}, + {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 56), 11}, + {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 58), 929}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 60), 4}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 62), 0}, + {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 64), 694}, + {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 66), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 68), 0}, + {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 70), 7}, + {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 72), 0}, + {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 74), 8}, + {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 76), 1425}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 78), 21}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 82), 11}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 80), 0}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 32}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, + {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, + {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 42}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 110), 12}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 112), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02, TYPE16(0, 114), 52}, + {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, + {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, + {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, + {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02, TYPE16(0, 128), 23}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02, TYPE16(0, 130), 1036}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02, TYPE16(0, 132), 0} +}; + +static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_REG_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_START_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_STOP_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVICE_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_FIX_CRITERIA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NI_USER_RESPONSE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_UTC_TIME_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_ASSIST_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_WIFI_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SPI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02, TYPE16(0, 0), 7} +}; + +static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { + {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 388}, + {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, + {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, + {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1079}, + {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, + {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, + {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, + {QMI_LOC_EVENT_ENGINE_STATE_IND_V02, TYPE16(0, 12), 7}, + {QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, TYPE16(0, 13), 11}, + {QMI_LOC_EVENT_WIFI_REQ_IND_V02, TYPE16(0, 14), 12}, + {QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, TYPE16(0, 15), 16}, + {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, + {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, + {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, + {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 23), 532}, + {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 25), 99}, + {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 27), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 29), 12}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 31), 790}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 33), 20}, + {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 35), 7}, + {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 37), 7}, + {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 39), 7}, + {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 41), 14}, + {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 43), 7}, + {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 45), 11}, + {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 47), 7}, + {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 49), 14}, + {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 51), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 53), 11}, + {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 55), 7}, + {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 57), 304}, + {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 59), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 61), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 63), 11}, + {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 65), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 67), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 69), 18}, + {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 71), 7}, + {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 73), 14}, + {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 75), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 77), 22}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 79), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 83), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 81), 18}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 87), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 39}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, + {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, + {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 49}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 113), 19}, + {QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, TYPE16(0, 19), 14}, + {QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, TYPE16(0, 20), 7}, + {QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, TYPE16(0, 21), 78}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, TYPE16(0, 115), 21}, + {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, + {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, + {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, + {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82}, + {QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, TYPE16(0, 129), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, TYPE16(0, 131), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, TYPE16(0, 133), 7} +}; + +/*Service Object*/ +struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { + 0x05, + 0x02, + 0x10, + 2248, + { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, + { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, + &loc_qmi_idl_type_table_object_v02, + 0x10, + NULL +}; + +/* Service Object Accessor */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ){ + if ( LOC_V02_IDL_MAJOR_VERS != idl_maj_version || LOC_V02_IDL_MINOR_VERS != idl_min_version + || LOC_V02_IDL_TOOL_VERS != library_version) + { + return NULL; + } + return (qmi_idl_service_object_type)&loc_qmi_idl_service_object_v02; +} + diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h old mode 100644 new mode 100755 index f5db0b99..b31efd04 --- a/loc_api/loc_api_v02/location_service_v02.h +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -25,7973 +25,7973 @@ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef LOC_SERVICE_H -#define LOC_SERVICE_H -/** - @file location_service_v02.h - - @brief This is the public header file which defines the loc service Data structures. - - This header file defines the types and structures that were defined in - loc. It contains the constant values defined, enums, structures, - messages, and service message IDs (in that order) Structures that were - defined in the IDL as messages contain mandatory elements, optional - elements, a combination of mandatory and optional elements (mandatory - always come before optionals in the structure), or nothing (null message) - - An optional element in a message is preceded by a uint8_t value that must be - set to true if the element is going to be included. When decoding a received - message, the uint8_t values will be set to true or false by the decode - routine, and should be checked before accessing the values that they - correspond to. - - Variable sized arrays are defined as static sized arrays with an unsigned - integer (32 bit) preceding it that must be set to the number of elements - in the array that are valid. For Example: - - uint32_t test_opaque_len; - uint8_t test_opaque[16]; - - If only 4 elements are added to test_opaque[] then test_opaque_len must be - set to 4 before sending the message. When decoding, the _len value is set - by the decode routine and should be checked so that the correct number of - elements in the array will be accessed. - -*/ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ - -/* This file was generated with Tool version 5.5 - It was generated on: Thu Sep 20 2012 - From IDL File: location_service_v02.idl */ - -/** @defgroup loc_qmi_consts Constant values defined in the IDL */ -/** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ -/** @defgroup loc_qmi_enums Enumerated types used in QMI messages */ -/** @defgroup loc_qmi_messages Structures sent as QMI messages */ -/** @defgroup loc_qmi_aggregates Aggregate types used in QMI messages */ -/** @defgroup loc_qmi_accessor Accessor for QMI service object */ -/** @defgroup loc_qmi_version Constant values for versioning information */ - -#include -#include "qmi_idl_lib.h" -#include "common_v01.h" - - -#ifdef __cplusplus -extern "C" { -#endif - -/** @addtogroup loc_qmi_version - @{ - */ -/** Major Version Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MAJOR_VERS 0x02 -/** Revision Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MINOR_VERS 0x0F -/** Major Version Number of the qmi_idl_compiler used to generate this file */ -#define LOC_V02_IDL_TOOL_VERS 0x05 -/** Maximum Defined Message ID */ -#define LOC_V02_MAX_MESSAGE_ID 0x006C; -/** - @} - */ - - -/** @addtogroup loc_qmi_consts - @{ - */ - -/** Maximum string length for the Provider field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 24 - -/** Maximum string length for the Name field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 32 - -/** Maximum string length for the Version field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 8 - -/** Maximum length of the list containing the SVs that were used to generate - a position report. */ -#define QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02 80 - -/** Maximum number of satellites in the satellite report. */ -#define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 - -/** Maximum NMEA string length. */ -#define QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 200 - -/** Maximum length of the requestor ID string. */ -#define QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02 200 - -/** Session ID byte length. */ -#define QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02 4 - -/** Maximum client name length allowed. */ -#define QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02 64 - -/** Maximum URL length accepted by the location engine. */ -#define QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 255 - -/** IPV6 address length in bytes. */ -#define QMI_LOC_IPV6_ADDR_LENGTH_V02 8 - -/** SUPL hash length. */ -#define QMI_LOC_NI_SUPL_HASH_LENGTH_V02 8 - -/** Maximum client address length allowed. */ -#define QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02 20 - -/** Maximum codeword length allowed. */ -#define QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02 20 - -/** Maximum number of NTP Servers sent out with this event. */ -#define QMI_LOC_MAX_NTP_SERVERS_V02 3 - -/** Maximum number of predicted orbits servers supported in the location - engine. */ -#define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 - -/** Maximum GNSS Measurement Engine Firmware Version String length. */ -#define QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 127 - -/** Maximum GNSS Measurement Engine Hosted Software Version String length. */ -#define QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 127 - -/** Maximum GNSS Measurement Engine Full Version String length. */ -#define QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 255 - -/** Maximum part length that can be injected. The client should - also look at the maxPartSize field in the predicted orbits injection - request indication and pick the minimum of the two. */ -#define QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 1024 - -/** Maximum length of the delete SV information list */ -#define QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02 128 - -/** MAC address length in bytes. */ -#define QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02 6 - -/** Maximum number of APs that the sender can report. */ -#define QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02 50 - -/** Maximum number of samples that can be injected in a TLV. */ -#define QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02 50 - -/** Maximum APN string length allowed. */ -#define QMI_LOC_MAX_APN_NAME_LENGTH_V02 100 - -/** Maximum APN profiles supported. */ -#define QMI_LOC_MAX_APN_PROFILES_V02 6 - -/** Maximum length of the SUPL certificate. */ -#define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 - -/** Maximum length of the network-initiated Geofence ID - list */ -#define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 - -/** Maximum length of the injected network initiated message. */ -#define QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02 1024 -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Response Message; Generic response definition. This message is used to tell - clients whether their message was accepted for further - processing or rejected. */ -typedef struct { - - /* Mandatory */ - /* Result Code */ - qmi_response_type_v01 resp; -}qmiLocGenRespMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Informs the service of the minor revision of the interface - definition that the control point implements. */ -typedef struct { - - /* Mandatory */ - /* Revision */ - uint32_t revision; - /**< Revision that the control point is using. */ -}qmiLocInformClientRevisionReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocEventRegMaskT_v02; -#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001ull) /**< The control point must enable this mask to receive position report - event indications. */ -#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002ull) /**< The control point must enable this mask to receive satellite report - event indications. These reports are sent at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004ull) /**< The control point must enable this mask to receive NMEA reports for - position and satellites in view. The report is at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008ull) /**< The control point must enable this mask to receive NI notify verify request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010ull) /**< The control point must enable this mask to receive time injection request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020ull) /**< The control point must enable this mask to receive predicted orbits request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040ull) /**< The control point must enable this mask to receive position injection request - event indications. */ -#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080ull) /**< The control point must enable this mask to receive engine state report - event indications. */ -#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100ull) /**< The control point must enable this mask to receive fix session status report - event indications. */ -#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200ull) /**< The control point must enable this mask to receive WiFi position request - event indications. */ -#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400ull) /**< The control point must enable this mask to receive notifications from the - GPS engine indicating its readiness to accept data from the - sensors (accelerometer, gyroscope, etc.). */ -#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800ull) /**< The control point must enable this mask to receive time-sync requests - from the GPS engine. Time sync enables the GPS engine to synchronize - its clock with the sensor processor's clock. */ -#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000ull) /**< The control point must enable this mask to receive Stationary Position - Indicator (SPI) streaming report indications. */ -#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000ull) /**< The control point must enable this mask to receive location server - requests. These requests are generated when the service wishes to - establish a connection with a location server. */ -#define QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00004000ull) /**< The control point must enable this mask to receive notifications - related to network-initiated Geofences. These events notify the client - when a network-initiated Geofence is added, deleted, or edited. */ -#define QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02 ((qmiLocEventRegMaskT_v02)0x00008000ull) /**< The control point must enable this mask to receive Geofence alerts. - These alerts are generated to inform the client of the changes that may - affect Geofence, e.g., if GPS is turned off or if the network is - unavailable. */ -#define QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00010000ull) /**< The control point must enable this mask to receive notifications when - a Geofence is breached. These events are generated when the UE enters - or leaves the perimeter of a Geofence. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to register for events from the - location subsystem. */ -typedef struct { - - /* Mandatory */ - /* Event Registration Mask */ - qmiLocEventRegMaskT_v02 eventRegMask; - /**< Specifies the events that the control point is interested in receiving. - Refer to the definition of the following bitmasks: - \vspace{0.05in} \begin{itemize1} - \item 0x00000001 -- POSITION_REPORT - \item 0x00000002 -- GNSS_SV_INFO - \item 0x00000004 -- NMEA - \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ - \item 0x00000010 -- INJECT_TIME_REQ - \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ - \item 0x00000040 -- INJECT_POSITION_REQ - \item 0x00000080 -- ENGINE_STATE - \item 0x00000100 -- FIX_SESSION_STATE - \item 0x00000200 -- WIFI_REQ - \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS - \item 0x00000800 -- TIME_SYNC_REQ - \item 0x00001000 -- SET_SPI_STREAMING_REPORT - \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ - \item 0x00004000 -- NI_GEOFENCE_NOTIFICATION - \item 0x00008000 -- GEOFENCE_GEN_ALERT - \item 0x00010000 -- GEOFENCE_BREACH_NOTIFICATION - \end{itemize1} \vspace{0.05in} - Multiple events can be registered by ORing the individual masks and - sending them in this TLV. All unused bits in this mask must be set to 0. - */ -}qmiLocRegEventsReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. */ - eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, /**< Request a single position fix. */ - QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocFixRecurrenceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ - eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. */ - eQMI_LOC_ACCURACY_HIGH_V02 = 3, /**< High accuracy. */ - QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAccuracyLevelEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. */ - eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, /**< Intermediate reports are turned off. */ - QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocIntermediateReportStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; - /**< Application provider. */ - - char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; - /**< Application name. */ - - uint8_t applicationVersion_valid; - /**< Specifies whether the application version string contains - a valid value: \begin{itemize1} - \item 0x00 (FALSE) -- Application version string is invalid - \item 0x01 (TRUE) -- Application version string is valid - \vspace{-0.18in} \end{itemize1} */ - - char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; - /**< Application version. */ -}qmiLocApplicationIdStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to initiate a GPS session. */ -typedef struct { - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session as identified by the control point. The session ID - is reported back in the position reports. The control point must - specify the same session ID in the QMI_LOC_STOP_REQ message. \n - - Range: 0 to 255 - */ - - /* Optional */ - /* Recurrence Type */ - uint8_t fixRecurrence_valid; /**< Must be set to true if fixRecurrence is being passed */ - qmiLocFixRecurrenceEnumT_v02 fixRecurrence; - /**< Specifies the type of session in which the control point is interested. - If this TLV is not specified, recurrence defaults to SINGLE. - - Valid values: \n - - 0x00000001 -- Request periodic fixes \n - - 0x00000002 -- Request a single fix - */ - - /* Optional */ - /* Horizontal Accuracy */ - uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ - qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; - /**< Specifies the horizontal accuracy level required by the control point. - If not specified, accuracy defaults to LOW. - - Valid values: \begin{itemize1} - \item 0x00000001 -- LOW: Client requires low horizontal accuracy - \item 0x00000002 -- MED: Client requires medium horizontal accuracy - \item 0x00000003 -- HIGH: Client requires high horizontal accuracy - \vspace{-0.18in} - \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable Intermediate Reports */ - uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ - qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; - /**< Specifies if the control point is interested in receiving intermediate - reports. The control point must explicitly set this field to OFF if it - does not wish to receive intermediate position reports. Intermediate - position reports are generated at 1 Hz and are ON by default. If - intermediate reports are turned ON, the client receives position reports - even if the accuracy criteria are not met. The status in such a position - report is set to IN_PROGRESS in order for the control point to identify - intermediate reports. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ON: Client is interested in receiving intermediate - reports - \item 0x00000002 -- OFF: Client is not interested in receiving - intermediate reports - \vspace{-0.18in} - \end{itemize1} - */ - - /* Optional */ - /* Minimum Interval Between Position Reports */ - uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ - uint32_t minInterval; - /**< Minimum time interval, specified by the control point, that must elapse between - position reports. \n - - Units: Milliseconds \n - - Default: 1000 ms - */ - - /* Optional */ - /* ID of the Application that Sent this Request */ - uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ - qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version.*/ -}qmiLocStartReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to stop a GPS session. */ -typedef struct { - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request - (QMI_LOC_START_REQ).\n - - Range: 0 to 255 */ -}qmiLocStopReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocPosTechMaskT_v02; -#define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION_V02 ((qmiLocPosTechMaskT_v02)0x00000020) /**< Coarse position injected into the location engine was used to - generate the fix. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSESSIONSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SESS_STATUS_SUCCESS_V02 = 0, /**< Session was successful. */ - eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 = 1, /**< Session still in progress. Further position reports will be - generated until either the fix criteria specified by the client - are met or the client response timeout occurs. */ - eQMI_LOC_SESS_STATUS_GENERAL_FAILURE_V02 = 2, /**< Session failed. */ - eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ - eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ - eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ - eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. */ - eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, /**< Fix request failed because the engine is locked. */ - QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSessionStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t gpsWeek; - /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n - - Units: Weeks */ - - uint32_t gpsTimeOfWeekMs; - /**< Amount of time into the current GPS week. \n - - Units: Milliseconds */ -}qmiLocGPSTimeStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - float PDOP; - /**< Position dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \item PDOP = square root of (HDOP^2 + VDOP^2) - \vspace{-0.18in} \end{itemize1} */ - - float HDOP; - /**< Horizontal dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ - - float VDOP; - /**< Vertical dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ -}qmiLocDOPStructT_v02; /* Type */ -/** - @} - */ - -typedef uint32_t qmiLocSensorUsageMaskT_v02; -#define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ -#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyroscope was used. */ -typedef uint32_t qmiLocSensorAidedMaskT_v02; -#define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ -#define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ -#define QMI_LOC_SENSOR_AIDED_MASK_POSITION_V02 ((qmiLocSensorAidedMaskT_v02)0x00000004) /**< Bitmask to specify whether a sensor was used to calculate position. */ -#define QMI_LOC_SENSOR_AIDED_MASK_VELOCITY_V02 ((qmiLocSensorAidedMaskT_v02)0x00000008) /**< Bitmask to specify whether a sensor was used to calculate velocity. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSensorUsageMaskT_v02 usageMask; - /**< Specifies which sensors were used in calculating the position in the - position report. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SENSOR_USED_ACCEL - \item 0x00000002 -- SENSOR_USED_GYRO - \vspace{-0.18in} \end{itemize1} */ - - qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; - /**< Specifies which results were aided by sensors. - - Valid bitmasks: \n - - 0x00000001 -- AIDED_HEADING \n - - 0x00000002 -- AIDED_SPEED \n - - 0x00000004 -- AIDED_POSITION \n - - 0x00000008 -- AIDED_VELOCITY */ -}qmiLocSensorUsageIndicatorStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCTIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_TIME_SRC_INVALID_V02 = 0, /**< Invalid time. */ - eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER_V02 = 1, /**< Time is set by the 1x system. */ - eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING_V02 = 2, /**< Time is set by WCDMA/GSM time tagging (i.e., - associating network time with GPS time). */ - eQMI_LOC_TIME_SRC_EXTERNAL_INPUT_V02 = 3, /**< Time is set by an external injection. */ - eQMI_LOC_TIME_SRC_TOW_DECODE_V02 = 4, /**< Time is set after decoding over-the-air GPS navigation data - from one GPS satellite. */ - eQMI_LOC_TIME_SRC_TOW_CONFIRMED_V02 = 5, /**< Time is set after decoding over-the-air GPS navigation data - from multiple satellites. */ - eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED_V02 = 6, /**< Both time of the week and the GPS week number are known. */ - eQMI_LOC_TIME_SRC_NAV_SOLUTION_V02 = 7, /**< Time is set by the position engine after the fix is obtained. */ - eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME_V02 = 8, /**< Time is set by the position engine after performing SFT. - This is done when the clock time uncertainty is large. */ - eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ - eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ - eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ - eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network */ - eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, /**< Source of the time is unknown */ - QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocTimeSourceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCRELIABILITYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ - eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ - eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ - eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed */ - eQMI_LOC_RELIABILITY_HIGH_V02 = 4, /**< Location reliability is high; strong cross-check passed */ - QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocReliabilityEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the position report to the control point. */ -typedef struct { - - /* Mandatory */ - /* Session Status */ - qmiLocSessionStatusEnumT_v02 sessionStatus; - /**< Session status. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SESS_STATUS_SUCCESS - \item 0x00000001 -- SESS_STATUS_IN_PROGRESS - \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE - \item 0x00000003 -- SESS_STATUS_TIMEOUT - \item 0x00000004 -- SESS_STATUS_USER_END - \item 0x00000005 -- SESS_STATUS_BAD_PARAMETER - \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE - \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request - QMI_LOC_START_REQ. \n - - Range: 0 to 255 */ - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Circular Horizontal Position Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ - uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ - uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Elliptical Horizontal Uncertainty Azimuth */ - uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation.\n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Optional */ - /* Horizontal Confidence */ - uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ - uint8_t horConfidence; - /**< Horizontal uncertainty confidence.\n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. \n - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Horizontal Speed */ - uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ - float speedHorizontal; - /**< Horizontal speed.\n - - Units: Meters/second */ - - /* Optional */ - /* Speed Uncertainty */ - uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ - float speedUnc; - /**< 3-D Speed uncertainty.\n - - Units: Meters/second */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical uncertainty confidence.\n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. \n - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Vertical Speed */ - uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ - float speedVertical; - /**< Vertical speed.\n - - Units: Meters/second */ - - /* Optional */ - /* Heading */ - uint8_t heading_valid; /**< Must be set to true if heading is being passed */ - float heading; - /**< Heading.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Heading Uncertainty */ - uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ - float headingUnc; - /**< Heading uncertainty.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Magnetic Deviation */ - uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ - float magneticDeviation; - /**< Difference between the bearing to true north and the bearing shown - on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ - - /* Optional */ - /* Technology Used */ - uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ - qmiLocPosTechMaskT_v02 technologyMask; - /**< Technology used in computing this fix. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SATELLITE - \item 0x00000002 -- CELLID - \item 0x00000004 -- WIFI - \item 0x00000008 -- SENSORS - \item 0x00000010 -- REFERENCE_LOCATION - \item 0x00000020 -- INJECTED_COARSE_POSITION - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Dilution of Precision */ - uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ - qmiLocDOPStructT_v02 DOP; - /**< \n Dilution of precision associated with this position. */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. \n - - Units: Milliseconds since Jan. 1, 1970 */ - - /* Optional */ - /* Leap Seconds */ - uint8_t leapSeconds_valid; /**< Must be set to true if leapSeconds is being passed */ - uint8_t leapSeconds; - /**< Leap second information. If leapSeconds is not available, - timestampUtc is calculated based on a hard-coded value - for leap seconds. \n - - Units: Seconds */ - - /* Optional */ - /* GPS Time */ - uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ - qmiLocGPSTimeStructT_v02 gpsTime; - /**< \n The number of weeks since Jan. 5, 1980, and - milliseconds into the current week. */ - - /* Optional */ - /* Time Uncertainty */ - uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ - float timeUnc; - /**< Time uncertainty. \n - - Units: Milliseconds */ - - /* Optional */ - /* Time Source */ - uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ - qmiLocTimeSourceEnumT_v02 timeSrc; - /**< Time source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- TIME_SRC_INVALID - \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER - \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING - \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT - \item 0x00000004 -- TIME_SRC_TOW_DECODE - \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED - \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED - \item 0x00000007 -- TIME_SRC_NAV_SOLUTION - \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Sensor Data Usage */ - uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ - qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; - /**< \n Whether sensor data was used in computing the position in this - position report. */ - - /* Optional */ - /* Fix Count for This Session */ - uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ - uint32_t fixId; - /**< Fix count for the session. Starts with 0 and increments by one - for each successive position report for a particular session. */ - - /* Optional */ - /* SVs Used to Calculate the Fix */ - uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ - uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ - uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; - /**< Each entry in the list contains the SV ID of a satellite - used for calculating this position report. The following - information is associated with each SV ID: \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ -}qmiLocEventPositionReportIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSVSYSTEMENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ - eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ - eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ - eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. */ - eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, /**< GLONASS satellite. */ - QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSvSystemEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ - eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. */ - eQMI_LOC_SV_STATUS_TRACK_V02 = 3, /**< SV is being tracked. */ - QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSvStatusEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocSvInfoValidMaskT_v02; -#define QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000001) /**< System field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000002) /**< gnssSvId field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_HEALTH_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000004) /**< healthStatus field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000008) /**< processStatus field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000010) /**< svInfoMask field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000020) /**< Elevation field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000040) /**< Azimuth field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000080) /**< SNR field is valid in SV information. */ -typedef uint8_t qmiLocSvInfoMaskT_v02; -#define QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02 ((qmiLocSvInfoMaskT_v02)0x01) /**< Ephemeris is available for this SV. */ -#define QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02 ((qmiLocSvInfoMaskT_v02)0x02) /**< Almanac is available for this SV. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSvInfoValidMaskT_v02 validMask; - /**< Bitmask indicating which of the fields in this TLV are valid. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- VALID_SYSTEM - \item 0x00000002 -- VALID_GNSS_SVID - \item 0x00000004 -- VALID_HEALTH_STATUS - \item 0x00000008 -- VALID_PROCESS_STATUS - \item 0x00000010 -- VALID_SVINFO_MASK - \item 0x00000020 -- VALID_ELEVATION - \item 0x00000040 -- VALID_AZIMUTH - \item 0x00000080 -- VALID_SNR - \vspace{-0.18in} \end{itemize1} */ - - qmiLocSvSystemEnumT_v02 system; - /**< Indicates to which constellation this SV belongs. - - Valid values: \begin{itemize1} - \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS - \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO - \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS - \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS - \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - \vspace{-0.18in} \end{itemize1} */ - - uint16_t gnssSvId; - /**< GNSS SV ID. - \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For GLONASS: 1 to 32 - \item For SBAS: 120 to 151 - \end{itemize1} \end{itemize1} - - The GPS and GLONASS SVs can be disambiguated using the system field. */ - - uint8_t healthStatus; - /**< Health status. - \begin{itemize1} - \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy - \vspace{-0.18in} \end{itemize1}*/ - - qmiLocSvStatusEnumT_v02 svStatus; - /**< SV processing status. \n - Valid values:\n - - 0x00000001 -- SV_STATUS_IDLE \n - - 0x00000002 -- SV_STATUS_SEARCH \n - - 0x00000003 -- SV_STATUS_TRACK - */ - - qmiLocSvInfoMaskT_v02 svInfoMask; - /**< Whether almanac and ephemeris information is available. \n - Valid bitmasks: \n - - 0x01 -- SVINFO_HAS_EPHEMERIS \n - - 0x02 -- SVINFO_HAS_ALMANAC - */ - - float elevation; - /**< SV elevation angle.\n - - Units: Degrees \n - - Range: 0 to 90 */ - - float azimuth; - /**< SV azimuth angle.\n - - Units: Degrees \n - - Range: 0 to 360 */ - - float snr; - /**< SV signal-to-noise ratio. \n - - Units: dB-Hz */ -}qmiLocSvInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends a satellite report to the control point. */ -typedef struct { - - /* Mandatory */ - /* Altitude Source */ - uint8_t altitudeAssumed; - /**< Whether altitude is assumed or calculated: \begin{itemize1} - \item 0x00 (FALSE) -- Valid altitude is calculated - \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be - enough satellites to determine precise altitude - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Satellite Info */ - uint8_t svList_valid; /**< Must be set to true if svList is being passed */ - uint32_t svList_len; /**< Must be set to # of elements in svList */ - qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; - /**< \n SV information list. */ -}qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends NMEA sentences to the control point */ -typedef struct { - - /* Mandatory */ - /* NMEA String */ - char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; - /**< NMEA string. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 201 - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocEventNmeaIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNINOTIFYVERIFYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ - eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, /**< Notify and Verify, and require a response. */ - QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiNotifyVerifyEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ - eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ - eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. */ - eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, /**< MS-based preferred, but MS-assisted allowed. */ - QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiVxPosModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_VX_OCTET_V02 = 0, /**< Encoding is OCTET. */ - eQMI_LOC_NI_VX_EXN_PROTOCOL_MSG_V02 = 1, /**< Encoding is EXN PROTOCOL MSG. */ - eQMI_LOC_NI_VX_ASCII_V02 = 2, /**< Encoding is ASCII. */ - eQMI_LOC_NI_VX_IA5_V02 = 3, /**< Encoding is IA5. */ - eQMI_LOC_NI_VX_UNICODE_V02 = 4, /**< Encoding is UNICODE. */ - eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ - eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ - eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ - eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. */ - eQMI_LOC_NI_VX_GSM_V02 = 9, /**< Encoding is GSM. */ - QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t posQosIncl; - /**< Whether quality of service is included:\n - - 0x01 (TRUE) -- QoS is included \n - - 0x00 (FALSE) -- QoS is not included */ - - uint8_t posQos; - /**< Position QoS timeout. \n - - Units: Seconds \n - - Range: 0 to 255 */ - - uint32_t numFixes; - /**< Number of fixes allowed. */ - - uint32_t timeBetweenFixes; - /**< Time between fixes.\n - - Units: Seconds */ - - qmiLocNiVxPosModeEnumT_v02 posMode; - /**< Position mode. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY - \item 0x00000002 -- NI_VX_MS_BASED_ONLY - \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED - \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; - /**< VX encoding scheme. - - Valid values: \begin{itemize1} - \item 0x00000000 -- NI_VX_OCTET - \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG - \item 0x00000002 -- NI_VX_ASCII - \item 0x00000003 -- NI_VX_IA5 - \item 0x00000004 -- NI_VX_UNICODE - \item 0x00000005 -- NI_VX_SHIFT_JIS - \item 0x00000006 -- NI_VX_KOREAN - \item 0x00000007 -- NI_VX_LATIN_HEBREW - \item 0x00000008 -- NI_VX_LATIN - \item 0x00000009 -- NI_VX_GSM - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ - uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; - /**< Requestor ID. \n - - Type: Array of bytes \n - - Maximum array length: 200 - */ - - uint16_t userRespTimerInSeconds; - /**< Time to wait for the user to respond. \n - - Units: Seconds */ -}qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLPOSMETHODENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_V02 = 1, /**< Set assisted. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_V02 = 2, /**< Set based. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_PREF_V02 = 3, /**< Set assisted preferred. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_PREF_V02 = 4, /**< Set based preferred. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AUTONOMOUS_GPS_V02 = 5, /**< Standalone GPS. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ - eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ - eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ - eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. */ - eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, /**< No position. */ - QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplPosMethodEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIDATACODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SS_GERMAN_V02 = 12, /**< Language is German. */ - eQMI_LOC_NI_SS_ENGLISH_V02 = 13, /**< Language is English. */ - eQMI_LOC_NI_SS_ITALIAN_V02 = 14, /**< Language is Italian. */ - eQMI_LOC_NI_SS_FRENCH_V02 = 15, /**< Language is French. */ - eQMI_LOC_NI_SS_SPANISH_V02 = 16, /**< Language is Spanish. */ - eQMI_LOC_NI_SS_DUTCH_V02 = 17, /**< Language is Dutch. */ - eQMI_LOC_NI_SS_SWEDISH_V02 = 18, /**< Language is Swedish. */ - eQMI_LOC_NI_SS_DANISH_V02 = 19, /**< Language is Danish. */ - eQMI_LOC_NI_SS_PORTUGUESE_V02 = 20, /**< Language is Portuguese. */ - eQMI_LOC_NI_SS_FINNISH_V02 = 21, /**< Language is Finnish. */ - eQMI_LOC_NI_SS_NORWEGIAN_V02 = 22, /**< Language is Norwegian. */ - eQMI_LOC_NI_SS_GREEK_V02 = 23, /**< Language is Greek. */ - eQMI_LOC_NI_SS_TURKISH_V02 = 24, /**< Language is Turkish. */ - eQMI_LOC_NI_SS_HUNGARIAN_V02 = 25, /**< Language is Hungarian. */ - eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ - eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ - eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ - eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. */ - eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, /**< Encoding is GSM default. */ - QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiDataCodingSchemeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLFORMATENUMTYPE_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SUPL_FORMAT_LOGICAL_NAME_V02 = 0, /**< SUPL logical name format. */ - eQMI_LOC_NI_SUPL_FORMAT_EMAIL_ADDRESS_V02 = 1, /**< SUPL email address format. */ - eQMI_LOC_NI_SUPL_FORMAT_MSISDN_V02 = 2, /**< SUPL logical name format. */ - eQMI_LOC_NI_SUPL_FORMAT_URL_V02 = 3, /**< SUPL URL format. */ - eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ - eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ - eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ - eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity */ - eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, /**< SUPL unknown format. */ - QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplFormatEnumType_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplFormatEnumType_v02 formatType; - /**< Format of the formatted string. - - Valid values: \begin{itemize1} - \item 0x00000000 -- FORMAT_LOGICAL_NAME - \item 0x00000001 -- FORMAT_EMAIL_ADDRESS - \item 0x00000002 -- FORMAT_MSISDN - \item 0x00000003 -- FORMAT_URL - \item 0x00000004 -- FORMAT_SIP_URL - \item 0x00000005 -- FORMAT_MIN - \item 0x00000006 -- FORMAT_MDN - \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY - \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ - uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; - /**< Formatted string. \n - - Type: Byte array \n - - Maximum string length: 64 - */ -}qmiLocNiSuplFormattedStringStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocSuplQopValidMaskT_v02; -#define QMI_LOC_NI_SUPL_MASK_QOP_HORZ_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x01) /**< Horizontal accuracy is valid in the Quality of Position (QoP). */ -#define QMI_LOC_NI_SUPL_MASK_QOP_VER_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x02) /**< Vertical accuracy is valid in the QoP. */ -#define QMI_LOC_NI_SUPL_MASK_QOP_MAXAGE_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x04) /**< Vertical accuracy is valid in the QoP. */ -#define QMI_LOC_NI_SUPL_MASK_QOP_DELAY_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x08) /**< Vertical accuracy is valid in the QoP. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSuplQopValidMaskT_v02 validMask; - /**< Bit field indicating which fields are valid in this value. - - Valid bitmasks: \n - - 0x01 -- QOP_HORZ_ACC_VALID \n - - 0x02 -- QOP_VER_ACC_VALID \n - - 0x04 -- QOP_MAXAGE_VALID \n - - 0x08 -- QOP_DELAY_VALID*/ - - uint8_t horizontalAccuracy; - /**< Horizontal accuracy. \n - - Units: Meters */ - - uint8_t verticalAccuracy; - /**< Vertical accuracy. \n - - Units: Meters */ - - uint16_t maxLocAge; - /**< Maximum age of the location if the engine sends a previously - computed position. \n - - Units: Seconds */ - - uint8_t delay; - /**< Delay the server is willing to tolerate for the fix. \n - - Units: Seconds */ -}qmiLocNiSuplQopStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocServerAddrTypeMaskT_v02; -#define QMI_LOC_SERVER_ADDR_TYPE_IPV4_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x01) /**< IPV4 server address type. */ -#define QMI_LOC_SERVER_ADDR_TYPE_IPV6_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x02) /**< IPV6 server address type. */ -#define QMI_LOC_SERVER_ADDR_TYPE_URL_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x04) /**< URL server address type. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t addr; - /**< IPV4 address. */ - - uint16_t port; - /**< IPV4 port. */ -}qmiLocIpV4AddrStructType_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; - /**< IPV6 address. \n - - Type: Array of unsigned integers \n - - Maximum length of the array: 8 */ - - uint32_t port; - /**< IPV6 port. */ -}qmiLocIpV6AddrStructType_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocServerAddrTypeMaskT_v02 suplServerAddrTypeMask; - /**< Mask specifying the valid fields in this value. - - Valid bitmasks: \n - - 0x01 -- IPV4 \n - - 0x02 -- IPV6 \n - - 0x04 -- URL - */ - - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< IPV4 address and port. */ - - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< IPV6 address and port. */ - - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiSuplServerInfoStructT_v02; /* Type */ -/** - @} - */ - -typedef uint32_t qmiLocNiSuplNotifyVerifyValidMaskT_v02; -#define QMI_LOC_SUPL_SERVER_INFO_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000001) /**< Mask to denote that the server information - is present in an NI SUPL notify verify request event. This mask is set in - the valid_flags field of a notify verify structure. */ -#define QMI_LOC_SUPL_SESSION_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000002) /**< Mask to denote that the SUPL session ID - is present in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_HASH_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000004) /**< Mask to denote that the SUPL hash is present - in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_POS_METHOD_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000008) /**< Mask to denote that the position method is present - in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000010) /**< Mask to denote that the data coding scheme - is present in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000020) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_CLIENT_NAME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000040) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_QOP_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000080) /**< Mask to denote that the quality of position - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_USER_RESP_TIMER_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000100) /**< Mask to denote that the user response timer - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; - /**< Indicates which of the following fields are present in this value. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SUPL_SERVER_INFO - \item 0x00000002 -- SUPL_SESSION_ID - \item 0x00000004 -- SUPL_HASH - \item 0x00000008 -- SUPL_POS_METHOD - \item 0x00000010 -- SUPL_DATA_CODING_SCHEME - \item 0x00000020 -- SUPL_REQUESTOR_ID - \item 0x00000040 -- SUPL_CLIENT_NAME - \item 0x00000080 -- SUPL_QOP - \item 0x00000100 -- SUPL_USER_RESP_TIMER - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; - /**< SUPL server information. */ - - uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; - /**< SUPL session ID. \n - - Type: Array of unsigned integers \n - - Maximum length of the array: 4 */ - - uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; - /**< Hash for SUPL_INIT; used to validate that the message was not - corrupted. \n - - Type: Array of unsigned integers \n - - Length of the array: 8 */ - - qmiLocNiSuplPosMethodEnumT_v02 posMethod; - /**< GPS mode to be used for the fix. - - Valid values: \begin{itemize1} - \item 0x00000001 -- AGPS_SETASSISTED - \item 0x00000002 -- AGPS_SETBASED - \item 0x00000003 -- AGPS_SETASSISTED_PREF - \item 0x00000004 -- AGPS_SETBASED_PREF - \item 0x00000005 -- AUTONOMOUS_GPS - \item 0x00000006 -- AFLT - \item 0x00000007 -- ECID - \item 0x00000008 -- EOTD - \item 0x00000009 -- OTDOA - \item 0x0000000A -- NO_POSITION - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Data coding scheme applies to both the requestor ID and the client - name. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplFormattedStringStructT_v02 requestorId; - /**< Requestor ID. The encoding scheme for requestor_id is specified in - the dataCodingScheme field. */ - - qmiLocNiSuplFormattedStringStructT_v02 clientName; - /**< Client name. The encoding scheme for client_name is specified in - the dataCodingScheme field. */ - - qmiLocNiSuplQopStructT_v02 suplQop; - /**< SUPL QoP. */ - - uint16_t userResponseTimer; - /**< Time to wait for the user to respond. \n - - Units: Seconds*/ -}qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ - eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. */ - eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, /**< Initial location. */ - QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiLocationTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Identifies the coding scheme of the coded string. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - - */ - - uint32_t codedString_len; /**< Must be set to # of elements in codedString */ - uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; - /**< Coded string. \n - - Type: Array of bytes \n - - Maximum string length: 20 */ -}qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ -/** - @} - */ - -typedef uint16_t qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02; -#define QMI_LOC_UMTS_CP_INVOKE_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0001) /**< Mask to denote that the invoke ID - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0002) /**< Mask to denote that the data coding scheme - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_NOTIFICATION_TEXT_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0004) /**< Mask to denote that the notification text - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_CLIENT_ADDRESS_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0008) /**< Mask to denote that the client address - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_LOCATION_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0010) /**< Mask to denote that the location type - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_REQUESTOR_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0020) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_CODEWORD_STRING_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0040) /**< Mask to denote that the code word string - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_SERVICE_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0080) /**< Mask to denote that the service type - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_USER_RESP_TIMER_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0100) /**< Mask to denote that the user response timer - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; - /**< Fields that are valid in this value. - - Valid bitmasks: \begin{itemize1} - \item 0x0001 -- INVOKE_ID_MASK - \item 0x0002 -- DATA_CODING_SCHEME_MASK - \item 0x0004 -- NOTIFICATION_TEXT_MASK - \item 0x0008 -- CLIENT_ADDRESS_MASK - \item 0x0010 -- LOCATION_TYPE_MASK - \item 0x0020 -- REQUESTOR_ID_MASK - \item 0x0040 -- CODEWORD_STRING_MASK - \item 0x0080 -- SERVICE_TYPE_MASK - \item 0x0100 -- USER_RESP_TIMER_MASK - \vspace{-0.18in} \end{itemize1} - */ - - uint8_t invokeId; - /**< Supplementary Services invoke ID. */ - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Type of data encoding scheme for the text. - Applies to both the notification text and the client address. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ - uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; - /**< Notification text; the encoding method is specified in - dataCodingScheme. \n - - Type: Array of bytes \n - - Maximum array length: 64 */ - - uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ - uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; - /**< Client address; the encoding method is specified in - dataCodingScheme. \n - - Maximum array length: 20 */ - - qmiLocNiLocationTypeEnumT_v02 locationType; - /**< Location type. - - Valid values: \begin{itemize1} - \item 0x00000001 -- CURRENT_LOCATION - \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION - \item 0x00000004 -- INITIAL_LOCATION - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; - /**< Requestor ID; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ - - qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; - /**< Codeword string; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ - - uint8_t lcsServiceTypeId; - /**< Service type ID. */ - - uint16_t userResponseTimer; - /**< Time to wait for the user to respond. \n - - Units: Seconds */ -}qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISERVICEINTERACTIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO_V02 = 1, /**< Service interaction between ongoing NI and incoming MO sessions. */ - QMILOCNISERVICEINTERACTIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiServiceInteractionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; - /**< Ongoing NI session request; this information is currently not filled. */ - - qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; - /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ONGOING_NI_INCOMING_MO - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiVxServiceInteractionStructT_v02; /* Type */ -/** - @} - */ - -typedef uint16_t qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02; -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WLAN_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0001) /**< Denotes that WLAN measurements are allowed as part of location ID - and multiple location IDs in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_GSM_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0002) /**< Denotes that GSM measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WCDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0004) /**< Denotes that WCDMA measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_CDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0008) /**< Denotes that CDMA measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HRDP_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0010) /**< Denotes that HRDP measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_UMB_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0020) /**< Denotes that UMB measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_LTE_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0040) /**< Denotes that LTE measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WIMAX_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0080) /**< Denotes that WIMAX measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HISTORIC_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0100) /**< Denotes that historical information is allowed as part of - multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_NONSVRV_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0200) /**< Denotes that information about nonserving cells is allowed - as part of multiple location ID in the SUPL_POS_INIT message. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot - triggered session. */ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic - triggered session. */ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, /**< The SUPL INIT message indicates a request for an area event - triggered session. */ - QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; -/** - @} - */ - -typedef uint16_t qmiLocNiSuplVer2ExtGnssTypeMaskT_v02; -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0001) /**< GPS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GLONASS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0002) /**< GLONASS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GALILEO_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0004) /**< Galileo is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_SBAS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0008) /**< SBAS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_QZSS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0010) /**< QZSS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_MODERN_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0020) /**< Modern GPS is allowed to be used as the positioning technology. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02 supportedNetworksMask; - /**< Specifies which type of network measurements are allowed to be sent as - part of the Location ID or Multiple Location IDs parameter in the - SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - - Valid bitmasks: \begin{itemize1} - \item 0x0001 -- SUPPORTED_NETWORK_WLAN - \item 0x0002 -- SUPPORTED_NETWORK_GSM - \item 0x0004 -- SUPPORTED_NETWORK_WCDMA - \item 0x0008 -- SUPPORTED_NETWORK_CDMA - \item 0x0010 -- SUPPORTED_NETWORK_HRDP - \item 0x0020 -- SUPPORTED_NETWORK_UMB - \item 0x0040 -- SUPPORTED_NETWORK_LTE - \item 0x0080 -- SUPPORTED_NETWORK_WIMAX - \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC - \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; - /**< Specifies the type of session trigger requested in the - SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - - Valid values: \begin{itemize1} - \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT - \item 0x00000000 -- TRIGGER_TYPE_PERIODIC - \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT - \vspace{-0.18in} \end{itemize1} */ - - qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; - /**< Specifies which GNSS technologies are allowed as positioning - technologies. - - Valid bitmasks: \n - - 0x0001 -- GNSS_GPS \n - - 0x0002 -- GNSS_GLONASS \n - - 0x0004 -- GNSS_GALILEO \n - - 0x0008 -- GNSS_SBAS \n - - 0x0010 -- GNSS_QZSS \n - - 0x0020 -- GNSS_MODERN_GPS - */ -}qmiLocNiSuplVer2ExtStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Indicates an NI notify/verify request to the control point. */ -typedef struct { - - /* Mandatory */ - /* Notification Type */ - qmiLocNiNotifyVerifyEnumT_v02 notificationType; - /**< Type of notification/verification performed. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NO_NOTIFY_NO_VERIFY - \item 0x00000002 -- NOTIFY_ONLY - \item 0x00000003 -- ALLOW_NO_RESP - \item 0x00000004 -- NOT_ALLOW_NO_RESP - \item 0x00000005 -- PRIVACY_OVERRIDE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Network Initiated Vx Request */ - uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ - qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; - /**< \n Optional NI Vx request payload. */ - - /* Optional */ - /* Network Initiated SUPL Request */ - uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ - qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; - /**< \n Optional NI SUPL request payload. */ - - /* Optional */ - /* Network Initiated UMTS Control Plane Request */ - uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ - qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; - /**< \n Optional NI UMTS-CP request payload. */ - - /* Optional */ - /* Network Initiated Service Interaction Request */ - uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ - qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; - /**< \n Optional NI service interaction payload. */ - - /* Optional */ - /* Network Initiated SUPL Version 2 Extension */ - uint8_t NiSuplVer2ExtInd_valid; /**< Must be set to true if NiSuplVer2ExtInd is being passed */ - qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; - /**< \n Optional NI SUPL Version 2 Extension payload. When present, - this payload is to be used in conjunction with the SUPL - indication payload. */ -}qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< Assistance server URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocAssistanceServerUrlStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t delayThreshold; - /**< The time server is to be skipped if a one-way delay to the server - exceeds this threshold. \n - - Units: Milliseconds */ - - uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ - qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; - /**< List of Time Server URL's that are recommended by the service for time - information, the list is ordered, the client is to use the first - server specified in the list as the primary URL to fetch NTP time, - the second one as secondary, and so on. \n - - Maximum server list items: 3 */ -}qmiLocTimeServerListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject time information. */ -typedef struct { - - /* Optional */ - /* Time Server Info */ - uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ - qmiLocTimeServerListStructT_v02 timeServerInfo; - /**< \n Contains information about the time servers recommended by the - location service for NTP time. */ -}qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t maxFileSizeInBytes; - /**< Maximum allowable predicted orbits file size (in bytes). */ - - uint32_t maxPartSize; - /**< Maximum allowable predicted orbits file chunk size (in bytes). */ -}qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t serverList_len; /**< Must be set to # of elements in serverList */ - qmiLocAssistanceServerUrlStructT_v02 serverList[QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02]; - /**< List of predicted orbits URLs. The list is ordered, so the client - must use the first server specified in the list as the primary URL - from which to download predicted orbits data, the second one as - secondary, and so on. \n - - Maximum number of servers that can be specified: 3 */ -}qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Allowed Sizes */ - qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ - - /* Optional */ - /* Server List */ - uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ - qmiLocPredictedOrbitsServerListStructT_v02 serverList; - /**< \n List of servers that can be used by the client to download - predicted orbits data. */ -}qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject a position. */ -typedef struct { - - /* Mandatory */ - /* Latitude */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Mandatory */ - /* Longitude */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Mandatory */ - /* Circular Horizontal Uncertainty */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Mandatory */ - /* UTC Timestamp */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. */ - eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, /**< Location engine is off. */ - QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocEngineStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the engine state to the control point. */ -typedef struct { - - /* Mandatory */ - /* Engine State */ - qmiLocEngineStateEnumT_v02 engineState; - /**< Location engine state. - - Valid values: \n - - 0x00000001 -- ON \n - - 0x00000002 -- OFF - */ -}qmiLocEventEngineStateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. */ - eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, /**< Location fix session has ended. */ - QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocFixSessionStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the fix session state to the control point. */ -typedef struct { - - /* Mandatory */ - /* Session State */ - qmiLocFixSessionStateEnumT_v02 sessionState; - /**< LOC fix session state. - - Valid values: \n - - 0x00000001 -- STARTED \n - - 0x00000002 -- FINISHED - */ - - /* Optional */ - /* Session ID */ - uint8_t sessionId_valid; /**< Must be set to true if sessionId is being passed */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request. - This may not be specified for a fix session corresponding to - a network-initiated request. \n - - Range: 0 to 255 */ -}qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ - eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. */ - eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, /**< Stop periodic fixes request. */ - QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiRequestEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends a WiFi request to the control point. */ -typedef struct { - - /* Mandatory */ - /* Request Type */ - qmiLocWifiRequestEnumT_v02 requestType; - /**< Request type as specified in qmiWifiRequestEnumT. - - Valid values: \begin{itemize1} - \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES - \item 0x00000001 -- START_PERIODIC_KEEP_WARM - \item 0x00000002 -- STOP_PERIODIC_FIXES - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Time Between Fixes */ - uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ - uint16_t tbfInMs; - /**< Time between fixes for a periodic request.\n - - Units: Milliseconds */ -}qmiLocEventWifiReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t samplesPerBatch; - /**< Specifies the number of samples per batch the GNSS location engine is to - receive. The sensor sampling frequency can be computed as follows: \n - - samplingFrequency = samplesPerBatch * batchesPerSecond \n - - samplesPerBatch must be a nonzero positive value. - */ - - uint16_t batchesPerSecond; - /**< Number of sensor-data batches the GNSS location engine is to receive - per second. The rate is specified in an integral number of batches per - second (Hz). \n - - batchesPerSecond must be a nonzero positive value. - */ -}qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t injectEnable; - /**< Whether the GNSS location engine is ready to accept data from this - sensor. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor - data - \item 0x00 (FALSE) -- GNSS location engine is not ready to accept - sensor data - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; - /**< Rate at which the GNSS engine would like the sensor to be sampled. \n - The rate is specified in integral number of samples per second (Hz)\n - and batches per second. - */ -}qmiLocSensorReadyStatusStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point if the GNSS location engine is - ready to accept sensor data. */ -typedef struct { - - /* Optional */ - /* Accelerometer Accept Ready */ - uint8_t accelReady_valid; /**< Must be set to true if accelReady is being passed */ - qmiLocSensorReadyStatusStructT_v02 accelReady; - /**< \n Whether the GNSS location engine is ready to accept accelerometer - sensor data. - */ - - /* Optional */ - /* Gyroscope Accept Ready */ - uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ - qmiLocSensorReadyStatusStructT_v02 gyroReady; - /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor - data. - */ -}qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point to inject time synchronization - data. */ -typedef struct { - - /* Mandatory */ - /* Opaque Time Sync Reference Counter */ - uint32_t refCounter; - /**< This TLV is sent to registered control points. It is sent by - the location engine when it needs to synchronize location engine and - control point (sensor processor) times. - This TLV must be echoed back in the Time Sync Inject request. */ -}qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to enable Stationary Position - Indicator (SPI) streaming reports. */ -typedef struct { - - /* Mandatory */ - /* Enable/Disable SPI Requests */ - uint8_t enable; - /**< Whether the client is to start or stop sending an SPI status stream. - \begin{itemize1} - \item 0x01 (TRUE) -- Client is to start sending an SPI status stream - \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. */ - eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, /**< Bring up the WWAN type used for AGNSS connections. */ - QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWWANTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. */ - eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, /**< Close a connection to the location server. */ - QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerRequestEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the client to open or close a connection - to the assisted GPS location server. */ -typedef struct { - - /* Mandatory */ - /* Connection Handle */ - uint32_t connHandle; - /**< Identifies a connection across Open and Close request events. */ - - /* Mandatory */ - /* Request Type */ - qmiLocServerRequestEnumT_v02 requestType; - /**< Open or close a connection to the location server. - - Valid values: \n - - 0x00000001 -- OPEN \n - - 0x00000002 -- CLOSE - */ - - /* Mandatory */ - /* WWAN Type */ - qmiLocWWANTypeEnumT_v02 wwanType; - /**< Identifies the WWAN type for this request. \n - - Valid values: \begin{itemize1} - \item 0x00000000 -- WWAN_TYPE_INTERNET - \item 0x00000001 -- WWAN_TYPE_AGNSS - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ - eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. */ - eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, /**< An NI Geofence was edited. The control point can query the - Geofence to find the its current state. */ - QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiGeofenceOperationEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Informs the control point about - network-initiated Geofences. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< ID of the Geofence for which this - notification was generated. */ - - /* Mandatory */ - /* Operation Type */ - qmiLocNiGeofenceOperationEnumT_v02 operationType; - /**< Operation for which this notification was generated. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NI_GEOFENCE_ADDED - \item 0x00000002 -- NI_GEOFENCE_DELETED - \item 0x00000003 -- NI_GEOFENCE_EDITED - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEGENALERTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE_V02 = 1, /**< GNSS is unavailable and GNSS position fixes - cannot be used to monitor Geofences. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can - be used to monitor Geofences. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage - information is available. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, /**< The engine has an invalid time. */ - QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceGenAlertEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point of the - Geofence status. */ -typedef struct { - - /* Mandatory */ - /* Geofence General Alert */ - qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; - /**< Specifies the Geofence general alert type. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE - \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE - \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS - \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. */ - eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, /**< Denotes that a client left the Geofence. */ - QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceBreachTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - /* UTC Timestamp */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ - - /* Latitude */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Longitude */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Elliptical Horizontal Uncertainty Azimuth */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation.\n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Horizontal Speed validity bit */ - uint8_t speedHorizontal_valid; - /**< Indicates whether the Horizontal speed field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Horizontal speed is valid - \item 0x00 (FALSE) -- Horizontal speed is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Horizontal Speed */ - float speedHorizontal; - /**< Horizontal speed.\n - - Units: Meters/second */ - - /* Altitude validity bit */ - uint8_t altitudeWrtEllipsoid_valid; - /**< Indicates whether the altitude field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Altitude field is valid - \item 0x00 (FALSE) -- Altitude field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} - */ - - /* Altitude With Respect to Ellipsoid */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Vertical Uncertainty validity bit */ - uint8_t vertUnc_valid; - /**< Indicates whether the Vertical Uncertainty field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Vertical Uncertainty field is valid - \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Vertical Uncertainty */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Vertical Speed validity bit */ - uint8_t speedVertical_valid; - /**< Indicates whether the Vertical Speed field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Vertical Speed field is valid - \item 0x00 (FALSE) -- Vertical Speed field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Vertical Speed */ - float speedVertical; - /**< Vertical speed.\n - - Units: Meters/second */ - - /* heading validity bit */ - uint8_t heading_valid; - /**< Indicates whether the Heading field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Heading field is valid - \item 0x00 (FALSE) -- Heading field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Heading */ - float heading; - /**< Heading.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ -}qmiLocGeofencePositionStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point of - a Geofence breach event. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< ID of the Geofence for which this - notification was generated. */ - - /* Mandatory */ - /* Geofence Breach Type */ - qmiLocGeofenceBreachTypeEnumT_v02 breachType; - /**< The type of breach that generated this event. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING - \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Geofence Position */ - uint8_t geofencePosition_valid; /**< Must be set to true if geofencePosition is being passed */ - qmiLocGeofencePositionStructT_v02 geofencePosition; - /**< \n Position of the client when it breached the Geofence. - This TLV is included if the client configures the - Geofence to report position. The position is reported - at the same confidence level that was specified in the - Add Circular Geofence request. */ -}qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ - eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ - eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is not supported. */ - eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ - eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ - eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ - eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ - eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested */ - eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, /**< Request failed because the engine could not allocate sufficent - memory for the request. */ - QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocStatusEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetServiceRevisionReqMsgT is empty - * typedef struct { - * }qmiLocGetServiceRevisionReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Client can query the service revision using this message. */ -typedef struct { - - /* Mandatory */ - /* Get Revision Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Revision request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Interface Definition Minor Revision */ - uint32_t revision; - /**< Revision of the service. This is the minor revision of the interface that - the service implements. Minor revision updates of the service are always - backward compatible. */ - - /* Optional */ - /* GNSS Measurement Engine Firmware Version String */ - uint8_t gnssMeFWVerString_valid; /**< Must be set to true if gnssMeFWVerString is being passed */ - char gnssMeFWVerString[QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Version of the GNSS measurement engine software running under the LOC API. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 128 - \vspace{0.1in} \end{itemize1} - - \textbf{Note:} This string is only provided on platforms that have - a measurement engine that supports this version string. On all other - platforms, this optional TLV is not provided. */ - - /* Optional */ - /* GNSS Hosted Software Version String */ - uint8_t gnssHostSWVerString_valid; /**< Must be set to true if gnssHostSWVerString is being passed */ - char gnssHostSWVerString[QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Version of the GNSS hosted software running under the LOC API. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 128 - \vspace{0.1in}\end{itemize1} - - \textbf{Note:} This string is only provided on hosted architectures - (measurement and position engine running on different processors) that - support this version string. On all other platforms, this optional TLV - is not provided. */ - - /* Optional */ - /* GNSS Software Version String */ - uint8_t gnssSWVerString_valid; /**< Must be set to true if gnssSWVerString is being passed */ - char gnssSWVerString[QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Aggregate version of the GNSS software. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetFixCriteriaReqMsgT is empty - * typedef struct { - * }qmiLocGetFixCriteriaReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the fix criteria from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Fix Criteria Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Fix Criteria request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Horizontal Accuracy */ - uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ - qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; - /**< Horizontal accuracy level. - - Valid values: \begin{itemize1} - \item 0x00000001 -- LOW: Client requires low horizontal accuracy - \item 0x00000002 -- MED: Client requires medium horizontal accuracy - \item 0x00000003 -- HIGH: Client requires high horizontal accuracy - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable Intermediate Fixes */ - uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ - qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; - /**< Intermediate Report state (ON, OFF).\n - The client must explicitly set this field to OFF to stop receiving - intermediate position reports. Intermediate position reports are - generated at \n 1 Hz and are ON by default. If intermediate reports - are turned ON, the client receives position reports even if the - accuracy criteria is not met. The status in the position report is - set to IN_PROGRESS for intermediate reports. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ON: Client is interested in receiving intermediate - reports - \item 0x00000002 -- OFF: Client is not interested in receiving - intermediate reports - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Minimum Interval Between Fixes */ - uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ - uint32_t minInterval; - /**< Time that must elapse before alerting the client. \n - - Units: Milliseconds */ - - /* Optional */ - /* ID of the Application that Sent the Position Request */ - uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ - qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version.*/ -}qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, /**< User did not respond to notify verify request. */ - QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiUserRespEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ -typedef struct { - - /* Mandatory */ - /* User Response */ - qmiLocNiUserRespEnumT_v02 userResp; - /**< User accepted or denied. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT - \item 0x00000002 -- NOTIFY_VERIFY_DENY - \item 0x00000003 -- NOTIFY_VERIFY_NORESP - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Notification Type */ - qmiLocNiNotifyVerifyEnumT_v02 notificationType; - /**< Type of notification/verification performed. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NO_NOTIFY_NO_VERIF - \item 0x00000002 -- NOTIFY_ONLY - \item 0x00000003 -- ALLOW_NO_RESP - \item 0x00000004 -- NOT_ALLOW_NO_RESP - \item 0x00000005 -- PRIVACY_OVERRIDE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Network Initiated Vx Request */ - uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ - qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; - /**< \n Optional NI VX request payload. */ - - /* Optional */ - /* Network Initiated SUPL Request */ - uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ - qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; - /**< \n Optional NI SUPL request payload. */ - - /* Optional */ - /* Network Initiated UMTS Control Plane Request */ - uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ - qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; - /**< \n Optional NI UMTS-CP request payload. */ - - /* Optional */ - /* Network Initiated Service Interaction Request */ - uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ - qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; - /**< \n Optional NI service interaction payload. */ - - /* Optional */ - /* Network Initiated SUPL Version 2 Extension */ - uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ - qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; - /**< \n Optional SUPL Version 2 Extension payload. */ -}qmiLocNiUserRespReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ -typedef struct { - - /* Mandatory */ - /* NI User Response Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the NI User Response request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiUserRespIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCPREDICTEDORBITSDATAFORMATENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_PREDICTED_ORBITS_XTRA_V02 = 0, /**< Default is QCOM-XTRA format. */ - QMILOCPREDICTEDORBITSDATAFORMATENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocPredictedOrbitsDataFormatEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Total Size */ - uint32_t totalSize; - /**< Total size of the predicted orbits data to be injected. \n - - Units: Bytes */ - - /* Mandatory */ - /* Total Parts */ - uint16_t totalParts; - /**< Total number of parts into which the predicted orbits data is - divided. */ - - /* Mandatory */ - /* Part Number */ - uint16_t partNum; - /**< Number of the current predicted orbits data part; starts at 1. */ - - /* Mandatory */ - /* Data */ - uint32_t partData_len; /**< Must be set to # of elements in partData */ - char partData[QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02]; - /**< Predicted orbits data. \n - - Type: Array of bytes \n - - Maximum length of the array: 1024 - */ - - /* Optional */ - /* Format Type */ - uint8_t formatType_valid; /**< Must be set to true if formatType is being passed */ - qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; - /**< Predicted orbits data format. - - Valid values: \begin{itemize1} - \item 0x00000000 -- PREDICTED_ORBITS_XTRA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Data Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Data Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Part Number */ - uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ - uint16_t partNum; - /**< Number of the predicted orbits data part for which this indication - is sent; starts at 1. */ -}qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty - * typedef struct { - * }qmiLocGetPredictedOrbitsDataSourceReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the predicted orbits data source. */ -typedef struct { - - /* Mandatory */ - /* Predicted Orbits Data Source Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the query request for a predicted orbits data source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Allowed Sizes */ - uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ - qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ - - /* Optional */ - /* Server List */ - uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ - qmiLocPredictedOrbitsServerListStructT_v02 serverList; - /**< \n List of servers that can be used by the client to download - predicted orbits data. */ -}qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty - * typedef struct { - * }qmiLocGetPredictedOrbitsDataValidityReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint64_t startTimeInUTC; - /**< Predicted orbits data is valid starting from this time. \n - - Units: Seconds (since Jan. 1, 1970) - */ - - uint16_t durationHours; - /**< Duration from the start time for which the data is valid.\n - - Units: Hours - */ -}qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the predicted orbits data validity. */ -typedef struct { - - /* Mandatory */ - /* Predicted Orbits Data Validity Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the query request for predicted orbits data validity. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Validity Info */ - uint8_t validityInfo_valid; /**< Must be set to true if validityInfo is being passed */ - qmiLocPredictedOrbitsDataValidityStructT_v02 validityInfo; -}qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects UTC time in the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Time */ - uint64_t timeUtc; - /**< UTC time since Jan. 1, 1970.\n - - Units: Milliseconds */ - - /* Mandatory */ - /* Time Uncertainty */ - uint32_t timeUnc; - /**< Time uncertainty.\n - - Units: Milliseconds */ -}qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects UTC time in the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Time Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the UTC Time Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_SRC_UNKNOWN_V02 = 0, /**< Source is unknown. */ - eQMI_LOC_ALT_SRC_GPS_V02 = 1, /**< GPS is the source. */ - eQMI_LOC_ALT_SRC_CELL_ID_V02 = 2, /**< Cell ID provided the source. */ - eQMI_LOC_ALT_SRC_ENHANCED_CELL_ID_V02 = 3, /**< Source is enhanced cell ID. */ - eQMI_LOC_ALT_SRC_WIFI_V02 = 4, /**< WiFi is the source. */ - eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ - eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ - eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ - eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. */ - eQMI_LOC_ALT_SRC_OTHER_V02 = 9, /**< Other sources. */ - QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ - eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ - eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. */ - eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, /**< Fully independent. */ - QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcLinkageEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ - eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal - position coordinates only. */ - eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, /**< Altitude uncertainty applies to the position of the device - regardless of horizontal position (within the horizontal - uncertainty region, if provided). */ - QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcUncertaintyCoverageEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocAltSrcEnumT_v02 source; - /**< Specifies the source of the altitude. - - Valid values: \begin{itemize1} - \item 0x00000000 -- ALT_SRC_UNKNOWN - \item 0x00000001 -- ALT_SRC_GPS - \item 0x00000002 -- ALT_SRC_CELL_ID - \item 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID - \item 0x00000004 -- ALT_SRC_WIFI - \item 0x00000005 -- ALT_SRC_TERRESTRIAL - \item 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID - \item 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE - \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER - \item 0x00000009 -- ALT_SRC_OTHER - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocAltSrcLinkageEnumT_v02 linkage; - /**< Specifies the dependency between the horizontal and - altitude position components. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED - \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT - \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG - \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; - /**< Specifies the region of uncertainty. - - Valid values: \begin{itemize1} - \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED - \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid - at the injected horizontal position coordinates - only. - \item 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to - the position of the device regardless of - horizontal position (within the horizontal - uncertainty region, if provided). - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocAltitudeSrcInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position source is GNSS. */ - eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position source is Cell ID. */ - eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ - eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ - eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ - eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. */ - eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, /**< Other sources. */ - QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocPositionSrcEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects a position to the location engine. */ -typedef struct { - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ - - /* Optional */ - /* Circular Horizontal Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Confidence */ - uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ - uint8_t horConfidence; - /**< Horizontal confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). - \begin{itemize1} - \item Units: Percent (0 to 99) - \item 0 -- invalid value - \item 100 to 256 -- not used - \item If 100 is received, reinterpret to 99 - \end{itemize1} - This field must be specified together with horizontal uncertainty. - If not specified, the default value will be 50. */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid. - \begin{itemize1} - \item Units: Meters \begin{itemize1} - \item Positive = height - \item Negative = depth - \vspace{-0.18in} \end{itemize1} \end{itemize1}*/ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid - or altitudeWrtMeanSeaLevel is specified.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). - \begin{itemize1} - \item Units: Percent (0-99) - \item 0 -- invalid value - \item 100 to 256 -- not used - \item If 100 is received, reinterpret to 99 - \end{itemize1} - This field must be specified together with the vertical uncertainty. - If not specified, the default value will be 50. */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Altitude Source Info */ - uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ - qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; - /**< \n Specifies information regarding the altitude source. */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. \n - - Units: Milliseconds (since Jan. 1, 1970) */ - - /* Optional */ - /* Position Age */ - uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ - int32_t timestampAge; - /**< Position age, which is an estimate of how long ago this fix was made. \n - - Units: Milliseconds */ - - /* Optional */ - /* Position Source */ - uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ - qmiLocPositionSrcEnumT_v02 positionSrc; - /**< Source from which this position was obtained. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS - \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID - \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID - \item 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI - \item 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL - \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID - \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER - \end{itemize1} \vspace{0.05in} - - If altitude is specified and the altitude source is not specified, the engine - assumes that the altitude was obtained using the specified position source. \n - If both altitude and altitude source are specified, the engine assumes - that only latitude and longitude were obtained using the specified position - source. - */ -}qmiLocInjectPositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects a position to the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Position Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the UTC Position Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectPositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ - eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ - eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. */ - eQMI_LOC_LOCK_ALL_V02 = 4, /**< Lock all position sessions. */ - QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocLockEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Lock Type */ - qmiLocLockEnumT_v02 lockType; - /**< Type of lock. - - Valid values: \n - - 0x00000001 -- LOCK_NONE \n - - 0x00000002 -- LOCK_MI \n - - 0x00000003 -- LOCK_MT \n - - 0x00000004 -- LOCK_ALL - - */ -}qmiLocSetEngineLockReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Set Engine Lock Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Engine Lock request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetEngineLockIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetEngineLockReqMsgT is empty - * typedef struct { - * }qmiLocGetEngineLockReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Get Engine Lock Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Engine Lock request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Lock Type */ - uint8_t lockType_valid; /**< Must be set to true if lockType is being passed */ - qmiLocLockEnumT_v02 lockType; - /**< Type of lock. - - Valid values: \n - - 0x00000001 -- LOCK_NONE \n - - 0x00000002 -- LOCK_MI \n - - 0x00000003 -- LOCK_MT \n - - 0x00000004 -- LOCK_ALL - */ -}qmiLocGetEngineLockIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the SBAS configuration. */ -typedef struct { - - /* Mandatory */ - /* SBAS Config */ - uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SBAS configuration is enabled - \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocSetSbasConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the SBAS configuration. */ -typedef struct { - - /* Mandatory */ - /* Set SBAS Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set SBAS Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSbasConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSbasConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSbasConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the SBAS configuration from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get SBAS Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get SBAS Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SBAS Config */ - uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ - uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SBAS configuration is enabled - \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocGetSbasConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocNmeaSentenceMaskT_v02; -#define QMI_LOC_NMEA_MASK_GGA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000001) /**< Enable GGA type. */ -#define QMI_LOC_NMEA_MASK_RMC_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000002) /**< Enable RMC type. */ -#define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ -#define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ -#define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ -#define QMI_LOC_NMEA_MASK_PQXFI_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000020) /**< Enable PQXFI type. */ -#define QMI_LOC_NMEA_MASK_PSTIS_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000040) /**< Enable PSTIS type. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the NMEA types. */ -typedef struct { - - /* Mandatory */ - /* NMEA Sentence Types */ - qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; - /**< Bitmasks of NMEA types to enable. - - Valid bitmasks: \n - - 0x00000001 -- NMEA_MASK_GGA \n - - 0x00000002 -- NMEA_MASK_RMC \n - - 0x00000004 -- NMEA_MASK_GSV \n - - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG \n - - 0x00000020 -- NMEA_MASK_PQXFI \n - - 0x00000040 -- NMEA_MASK_PSTIS - */ -}qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the NMEA types. */ -typedef struct { - - /* Mandatory */ - /* Set NMEA Types Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of Set NMEA Types request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetNmeaTypesReqMsgT is empty - * typedef struct { - * }qmiLocGetNmeaTypesReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the NMEA types from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get NMEA Types Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get NMEA Types request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* NMEA Sentence Types */ - uint8_t nmeaSentenceType_valid; /**< Must be set to true if nmeaSentenceType is being passed */ - qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; - /**< NMEA types to enable. - - Valid bitmasks: \n - - 0x0000ffff -- NMEA_MASK_ALL \n - - 0x00000001 -- NMEA_MASK_GGA \n - - 0x00000002 -- NMEA_MASK_RMC \n - - 0x00000004 -- NMEA_MASK_GSV \n - - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG \n - - 0x00000020 -- NMEA_MASK_PQXFI \n - - 0x00000040 -- NMEA_MASK_PSTIS - */ -}qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Enables/disables Low Power Mode (LPM) configuration. */ -typedef struct { - - /* Mandatory */ - /* Enable Low Power Mode */ - uint8_t lowPowerMode; - /**< Whether to enable Low Power mode:\n - - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ -}qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Enables/disables Low Power Mode (LPM) configuration. */ -typedef struct { - - /* Mandatory */ - /* Set LPM Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Low Power Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetLowPowerModeReqMsgT is empty - * typedef struct { - * }qmiLocGetLowPowerModeReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the LPM status from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get LPM Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get LPM request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable LPM */ - uint8_t lowPowerMode_valid; /**< Must be set to true if lowPowerMode is being passed */ - uint8_t lowPowerMode; - /**< Whether to enable Low Power mode:\n - - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ -}qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ - eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ - eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. */ - eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, /**< Server type is custom PDE. */ - QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Specifies the A-GPS server type and address. */ -typedef struct { - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* IPV4 Address */ - uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ - - /* Optional */ - /* IPV6 Address */ - uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ - - /* Optional */ - /* Uniform Resource Locator */ - uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL address. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetServerReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Specifies the A-GPS server type and address. */ -typedef struct { - - /* Mandatory */ - /* Set Server Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Server request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetServerIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Gets the location server from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server, as defined in qmiLocServerTypeEnumT. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* Server Address Type */ - uint8_t serverAddrTypeMask_valid; /**< Must be set to true if serverAddrTypeMask is being passed */ - qmiLocServerAddrTypeMaskT_v02 serverAddrTypeMask; - /**< Type of address the client wants. If unspecified, the - indication will contain all the types of addresses - it has for the specified server type. - - Valid bitmasks: \n - - 0x01 -- IPV4 \n - - 0x02 -- IPV6 \n - - 0x04 -- URL - */ -}qmiLocGetServerReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the location server from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Server Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Server request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server, as defined in qmiLocServerTypeEnumT. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* IPV4 Address */ - uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ - - /* Optional */ - /* IPV6 Address */ - uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ - - /* Optional */ - /* Uniform Resource Locator */ - uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetServerIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; -#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001ull) /**< Mask to delete GPS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002ull) /**< Mask to delete GPS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004ull) /**< Mask to delete GPS time. */ -#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008ull) /**< Mask to delete almanac correlation. */ -#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010ull) /**< Mask to delete GLONASS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020ull) /**< Mask to delete GLONASS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040ull) /**< Mask to delete GLONASS time. */ -#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080ull) /**< Mask to delete GLONASS almanac correlation */ -#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100ull) /**< Mask to delete SBAS SVDIR */ -#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200ull) /**< Mask to delete SBAS SVSTEER */ -#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400ull) /**< Mask to delete position estimate */ -#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800ull) /**< Mask to delete time estimate */ -#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000ull) /**< Mask to delete IONO */ -#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000ull) /**< Mask to delete UTC estimate */ -#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000ull) /**< Mask to delete SV health record */ -#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000ull) /**< Mask to delete SADATA */ -#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000ull) /**< Mask to delete RTI */ -#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000ull) /**< Mask to delete SV_NO_EXIST */ -#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000ull) /**< Mask to delete frequency bias estimate */ -typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; -#define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ -#define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ -#define QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000004) /**< Mask to delete cell database OTA position */ -#define QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000008) /**< Mask to delete cell database external reference position */ -#define QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000010) /**< Mask to delete cell database time tag */ -#define QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000020) /**< Mask to delete cell database cell ID */ -#define QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000040) /**< Mask to delete cell database cached cell ID */ -#define QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000080) /**< Mask to delete cell database last service cell */ -#define QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000100) /**< Mask to delete cell database current service cell */ -#define QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000200) /**< Mask to delete cell database neighbor information */ -typedef uint32_t qmiLocDeleteClockInfoMaskT_v02; -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000001) /**< Mask to delete time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_FREQ_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000002) /**< Mask to delete frequency estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_WEEK_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000004) /**< Mask to delete week number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_RTC_TIME_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000008) /**< Mask to delete RTC time from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_TRANSFER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000010) /**< Mask to delete time transfer from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GPSTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000020) /**< Mask to delete GPS time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLOTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000040) /**< Mask to delete GLONASS time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLODAY_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000080) /**< Mask to delete GLONASS day number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO4YEAR_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000100) /**< Mask to delete GLONASS four year number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000200) /**< Mask to delete GLONASS RF GRP delay from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_DISABLE_TT_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000400) /**< Mask to delete disable TT from clock information */ -typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; -#define QMI_LOC_MASK_DELETE_EPHEMERIS_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x01) /**< Delete ephemeris for the satellite */ -#define QMI_LOC_MASK_DELETE_ALMANAC_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x02) /**< Delete almanac for the satellite */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t gnssSvId; - /**< SV ID of the satellite whose data is to be deleted. - \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - qmiLocSvSystemEnumT_v02 system; - /**< Indicates to which constellation this SV belongs. - - Valid values: \begin{itemize1} - \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS - \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO - \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS - \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS - \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; - /**< Indicates if the ephemeris or almanac for a satellite - is to be deleted. \n - Valid values: \n - - 0x01 -- DELETE_EPHEMERIS \n - - 0x02 -- DELETE_ALMANAC - */ -}qmiLocDeleteSvInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; This command is used to delete the location engine - assistance data */ -typedef struct { - - /* Mandatory */ - /* Delete All */ - uint8_t deleteAllFlag; - /**< Whether all assistance data is to be deleted. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- All assistance data is to be deleted; if - this flag is set, all the other information - contained in the optional fields for this - message are ignored - \item 0x00 (FALSE) -- The optional fields in the message are to be - used to determine which data is to be deleted - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Delete SV Info */ - uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ - uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ - qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; - /**< \n List of satellites for which the assistance data is to be deleted. - */ - - /* Optional */ - /* Delete GNSS Data */ - uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ - qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; - /**< Mask for the GNSS data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_GPS_SVDIR - \item 0x00000002 -- DELETE_GPS_SVSTEER - \item 0x00000004 -- DELETE_GPS_TIME - \item 0x00000008 -- DELETE_GPS_ALM_CORR - \item 0x00000010 -- DELETE_GLO_SVDIR - \item 0x00000020 -- DELETE_GLO_SVSTEER - \item 0x00000040 -- DELETE_GLO_TIME - \item 0x00000080 -- DELETE_GLO_ALM_CORR - \item 0x00000100 -- DELETE_SBAS_SVDIR - \item 0x00000200 -- DELETE_SBAS_SVSTEER - \item 0x00000400 -- DELETE_POSITION - \item 0x00000800 -- DELETE_TIME - \item 0x00001000 -- DELETE_IONO - \item 0x00002000 -- DELETE_UTC - \item 0x00004000 -- DELETE_HEALTH - \item 0x00008000 -- DELETE_SADATA - \item 0x00010000 -- DELETE_RTI - \item 0x00020000 -- DELETE_SV_NO_EXIST - \item 0x00040000 -- DELETE_FREQ_BIAS_EST - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Delete Cell Database */ - uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ - qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; - /**< Mask for the cell database assistance data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_CELLDB_POS - \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS - \item 0x00000004 -- DELETE_CELLDB_OTA_POS - \item 0x00000008 -- DELETE_CELLDB_EXT_REF_POS - \item 0x00000010 -- DELETE_CELLDB_TIMETAG - \item 0x00000020 -- DELETE_CELLDB_CELLID - \item 0x00000040 -- DELETE_CELLDB_CACHED_CELLID - \item 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL - \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL - \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Delete Clock Info */ - uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ - qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; - /**< Mask for the clock information assistance data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST - \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST - \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER - \item 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME - \item 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER - \item 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST - \item 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST - \item 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER - \item 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER - \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY - \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; This command is used to delete the location engine - assistance data */ -typedef struct { - - /* Mandatory */ - /* Delete Assist Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete Assist Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Enables/disables XTRA-T session control. */ -typedef struct { - - /* Mandatory */ - /* Enable XTRA-T */ - uint8_t xtraTSessionControl; - /**< Whether to enable XTRA-T:\n - - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ -}qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Enables/disables XTRA-T session control. */ -typedef struct { - - /* Mandatory */ - /* Set XTRA-T Session Control Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set XTRA-T Session Control request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetXtraTSessionControlReqMsgT is empty - * typedef struct { - * }qmiLocGetXtraTSessionControlReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the XTRA-T session control value from the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Get XTRA-T Session Control Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get XTRA-T Session Control request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable XTRA-T */ - uint8_t xtraTSessionControl_valid; /**< Must be set to true if xtraTSessionControl is being passed */ - uint8_t xtraTSessionControl; - /**< Whether to enable XTRA-T:\n - - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ -}qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t wifiPositionTime; - /**< Common counter (typically, the number of milliseconds since bootup). - This field is only to be provided if the modem and host processors are - synchronized. */ -}qmiLocWifiFixTimeStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFIFIXERRORCODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_FIX_ERROR_SUCCESS_V02 = 0, /**< WiFi fix is successful. */ - eQMI_LOC_WIFI_FIX_ERROR_WIFI_NOT_AVAILABLE_V02 = 1, /**< WiFi fix failed because WiFi is not available on the device. */ - eQMI_LOC_WIFI_FIX_ERROR_NO_AP_FOUND_V02 = 2, /**< WiFi fix failed because no access points were found. */ - eQMI_LOC_WIFI_FIX_ERROR_UNAUTHORIZED_V02 = 3, /**< WiFi fix failed because the server denied access due to bad authorization - code. */ - eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ - eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. - This may be because the APs found are not in the database. */ - eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, /**< WiFi fix failed, but the cause could not be determined. */ - QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiFixErrorCodeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - double lat; - /**< WiFi position latitude. \n - - Type: Floating point \n - - Units: Degrees */ - - double lon; - /**< WiFi position longitude. \n - - Type: Floating point \n - - Units: Degrees */ - - uint16_t hepe; - /**< WiFi position HEPE.\n - - Units: Meters */ - - uint8_t numApsUsed; - /**< Number of Access Points (AP) used to generate a fix. */ - - qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; - /**< WiFi position error code; set to 0 if the fix succeeds. This position - is only used by a module if the value is 0. If there was a failure, - the error code provided by the WiFi positioning system can be provided - here. - - Valid values: \begin{itemize1} - \item 0x00000000 -- ERROR_SUCCESS - \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE - \item 0x00000002 -- ERROR_NO_AP_FOUND - \item 0x00000003 -- ERROR_UNAUTHORIZED - \item 0x00000004 -- ERROR_SERVER_UNAVAILABLE - \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED - \item 0x00000006 -- ERROR_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocWifiFixPosStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocWifiApQualifierMaskT_v02; -#define QMI_LOC_WIFI_AP_QUALIFIER_BEING_USED_V02 ((qmiLocWifiApQualifierMaskT_v02)0x01) /**< Access point is being used by the WPS. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_HIDDEN_SSID_V02 ((qmiLocWifiApQualifierMaskT_v02)0x02) /**< AP does not broadcast SSID. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_PRIVATE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x04) /**< AP has encryption turned on. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_INFRASTRUCTURE_MODE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x08) /**< AP is in infrastructure mode and not in ad-hoc/unknown mode. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t macAddr[QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02]; - /**< Associated MAC address of the AP. \n - - Type: Array of unsigned integers \n - - Address length: 6 - */ - - int32_t rssi; - /**< Receive signal strength indicator.\n - - Units: dBm (offset with +100 dB) */ - - uint16_t channel; - /**< WiFi channel on which a beacon was received. */ - - qmiLocWifiApQualifierMaskT_v02 apQualifier; - /**< A bitmask of Boolean qualifiers for APs. - All unused bits in this mask must be set to 0. - - Valid values: \n - - 0x01 -- BEING_USED \n - - 0x02 -- HIDDEN_SSID \n - - 0x04 -- PRIVATE \n - - 0x08 -- INFRASTRUCTURE_MODE - */ -}qmiLocWifiApInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects the WiFi position. */ -typedef struct { - - /* Optional */ - /* WiFi Fix Time */ - uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ - qmiLocWifiFixTimeStructT_v02 wifiFixTime; - /**< \n Time of WiFi position fix. */ - - /* Optional */ - /* WiFi Position */ - uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ - qmiLocWifiFixPosStructT_v02 wifiFixPosition; - /**< \n WiFi position fix. */ - - /* Optional */ - /* WiFi Access Point Information */ - uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ - uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ - qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; - /**< \n AP scan list. */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horizontalReliability_valid; /**< Must be set to true if horizontalReliability is being passed */ - qmiLocReliabilityEnumT_v02 horizontalReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects the WiFi position. */ -typedef struct { - - /* Mandatory */ - /* Inject WiFi Position Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject WiFi Position request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. */ - eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, /**< WiFi is not available. */ - QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Notifies the location engine of the WiFi status. */ -typedef struct { - - /* Mandatory */ - /* Availablility of WiFi */ - qmiLocWifiStatusEnumT_v02 wifiStatus; - /**< WiFi status information. - - Valid values: \begin{itemize1} - \item 0x00000001 -- WIFI_STATUS_AVAILABLE - \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the location engine of the WiFi status. */ -typedef struct { - - /* Mandatory */ - /* Status of Notify WiFi Status Request */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Notify WiFi Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetRegisteredEventsReqMsgT is empty - * typedef struct { - * }qmiLocGetRegisteredEventsReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the mask of the events for which a client has - registered. */ -typedef struct { - - /* Mandatory */ - /* Get Registered Events Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Registered Events request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Event Registration Mask */ - uint8_t eventRegMask_valid; /**< Must be set to true if eventRegMask is being passed */ - qmiLocEventRegMaskT_v02 eventRegMask; - /**< Event registration mask. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- POSITION_REPORT - \item 0x00000002 -- GNSS_SV_INFO - \item 0x00000004 -- NMEA - \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ - \item 0x00000010 -- INJECT_TIME_REQ - \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ - \item 0x00000040 -- INJECT_POSITION_REQ - \item 0x00000080 -- ENGINE_STATE - \item 0x00000100 -- FIX_SESSION_STATE - \item 0x00000200 -- WIFI_REQ - \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS - \item 0x00000800 -- TIME_SYNC_REQ - \item 0x00001000 -- SET_SPI_STREAMING_REPORT - \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCOPERATIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ - eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ - eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ - eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ - eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for a GSM/UMTS network. */ - eQMI_LOC_OPER_MODE_WWAN_V02 = 6, /**< Use WWAN measurements to calculate the position. If this mode is - set, AFLT will be used for 1x networks and OTDOA will be used - for LTE networks. */ - QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocOperationModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Tells the engine to use the specified operation mode while - making the position fixes. This command is not to be used - by multiple clients concurrently. */ -typedef struct { - - /* Mandatory */ - /* Operation Mode */ - qmiLocOperationModeEnumT_v02 operationMode; - /**< Preferred operation mode. - \label{operationMode} - - Valid values: \begin{itemize1} - \item 0x00000001 -- OPER_MODE_DEFAULT - \item 0x00000002 -- OPER_MODE_MSB - \item 0x00000003 -- OPER_MODE_MSA - \item 0x00000004 -- OPER_MODE_STANDALONE - \item 0x00000005 -- OPER_MODE_CELL_ID - \item 0x00000006 -- OPER_MODE_WWAN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetOperationModeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Tells the engine to use the specified operation mode while - making the position fixes. This command is not to be used - by multiple clients concurrently. */ -typedef struct { - - /* Mandatory */ - /* Set Operation Mode Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Operation Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetOperationModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetOperationModeReqMsgT is empty - * typedef struct { - * }qmiLocGetOperationModeReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the current operation mode from the engine. */ -typedef struct { - - /* Mandatory */ - /* Get Operation Mode Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Operation Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Operation Mode */ - uint8_t operationMode_valid; /**< Must be set to true if operationMode is being passed */ - qmiLocOperationModeEnumT_v02 operationMode; - /**< Current operation mode. - - Valid values: \begin{itemize1} - \item 0x00000001 -- OPER_MODE_DEFAULT - \item 0x00000002 -- OPER_MODE_MSB - \item 0x00000003 -- OPER_MODE_MSA - \item 0x00000004 -- OPER_MODE_STANDALONE - \item 0x00000005 -- OPER_MODE_CELL_ID - \item 0x00000006 -- OPER_MODE_WWAN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetOperationModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the SPI status, which - indicates whether the device is stationary. */ -typedef struct { - - /* Mandatory */ - /* Stationary Status */ - uint8_t stationary; - /**< Whether the device is stationary: - \begin{itemize1} - \item 0x00 (FALSE) -- Device is not stationary - \item 0x01 (TRUE) -- Device is stationary - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Confidence */ - uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ - uint8_t confidenceStationary; - /**< Confidence in the Stationary state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocSetSpiStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the SPI status, which - indicates whether the device is stationary. */ -typedef struct { - - /* Mandatory */ - /* Status of SPI Status Request */ - qmiLocStatusEnumT_v02 status; - /**< Status of the SPI Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSpiStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint8_t qmiLocSensorDataFlagMaskT_v02; -#define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting - the sensor data. */ -#define QMI_LOC_SENSOR_DATA_FLAG_SENSOR_TIME_IS_MODEM_TIME_V02 ((qmiLocSensorDataFlagMaskT_v02)0x02) /**< Bitmask to specify that the sensor time stamp is the same as the modem - time stamp. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t timeOffset; - /**< Sample time offset. This time offset must be - relative to the sensor time of the first sample.\n - - Units: Milliseconds */ - - float xAxis; - /**< Sensor x-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ - - float yAxis; - /**< Sensor y-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ - - float zAxis; - /**< Sensor z-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ -}qmiLoc3AxisSensorSampleStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t timeOfFirstSample; - /**< Denotes a full 32-bit time tag of the first (oldest) sample in this - message. \n - - Units: Milliseconds */ - - qmiLocSensorDataFlagMaskT_v02 flags; - /**< Flags to indicate any deviation from the default measurement - assumptions. All unused bits in this field must be set to 0. - - Valid bitmasks: \begin{itemize1} - \item 0x01 -- SIGN_REVERSAL - \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME - \vspace{-0.18in} \end{itemize1} */ - - uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ - qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; - /**< Variable length array to specify sensor samples. \n - - Maximum length of the array: 50 */ -}qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inject sensor data into the - GNSS location engine. */ -typedef struct { - - /* Optional */ - /* Opaque Identifier */ - uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ - uint32_t opaqueIdentifier; - /**< An opaque identifier that is sent in by the client that will be echoed - in the indication so the client can relate the indication to the - request. */ - - /* Optional */ - /* 3-Axis Accelerometer Data */ - uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ - qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; - /**< \n Accelerometer sensor samples. */ - - /* Optional */ - /* 3-Axis Gyroscope Data */ - uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ - qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; - /**< \n Gyroscope sensor samples. */ -}qmiLocInjectSensorDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inject sensor data into the - GNSS location engine. */ -typedef struct { - - /* Mandatory */ - /* Inject Sensor Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Sensor Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Opaque Identifier */ - uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ - uint32_t opaqueIdentifier; - /**< Opaque identifier that was sent in by the client echoed - so the client can relate the indication to the request. */ - - /* Optional */ - /* Accelerometer Samples Accepted */ - uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ - uint8_t threeAxisAccelSamplesAccepted; - /**< Lets the client know how many 3-axis accelerometer samples - were accepted. */ - - /* Optional */ - /* Gyroscope Samples Accepted */ - uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ - uint8_t threeAxisGyroSamplesAccepted; - /**< Lets the client know how many 3-axis gyroscope samples were - accepted. */ -}qmiLocInjectSensorDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inject time sync data. */ -typedef struct { - - /* Mandatory */ - /* Reference Time Sync Counter */ - uint32_t refCounter; - /**< Must be set to the value that was sent to the control point when the - GNSS location engine requested time sync injection. */ - - /* Mandatory */ - /* Sensor Receive Time */ - uint32_t sensorProcRxTime; - /**< Value of the sensor time when the control point received the - Time Sync Inject request from the GNSS location engine. - - Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 - millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ - - /* Mandatory */ - /* Sensor Transmit Time */ - uint32_t sensorProcTxTime; - /**< Value of the sensor time when the control point injects this message - for use by the GNSS location engine. - - Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 - millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ -}qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inject time sync data. */ -typedef struct { - - /* Mandatory */ - /* Inject Time Sync Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Time Sync Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ - eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle */ - eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, /**< Unknown cradle mount state */ - QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocCradleMountStateEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetCradleMountConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetCradleMountConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Cradle Mount Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Cradle Mount Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Cradle Mount State */ - uint8_t cradleMountState_valid; /**< Must be set to true if cradleMountState is being passed */ - qmiLocCradleMountStateEnumT_v02 cradleMountState; - /**< Cradle Mount state set by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED - \item 0x00000001 -- CRADLE_STATE_MOUNTED - \item 0x00000002 -- CRADLE_STATE_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Cradle Mount Confidence */ - uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ - uint8_t confidenceCradleMountState; - /**< Confidence of the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Cradle Mount State */ - qmiLocCradleMountStateEnumT_v02 cradleMountState; - /**< Cradle Mount state set by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED - \item 0x00000001 -- CRADLE_STATE_MOUNTED - \item 0x00000002 -- CRADLE_STATE_UNKNOWN - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Cradle Mount Confidence */ - uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ - uint8_t confidenceCradleMountState; - /**< Confidence in the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Cradle Mount Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Cradle Mount Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ - eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. */ - eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, /**< Unknown external power state. */ - QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocExternalPowerConfigEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetExternalPowerConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetExternalPowerConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Ext Power Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get External Power Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* External Power State */ - uint8_t externalPowerState_valid; /**< Must be set to true if externalPowerState is being passed */ - qmiLocExternalPowerConfigEnumT_v02 externalPowerState; - /**< Power state; injected by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED - \item 0x00000001 -- EXTERNAL_POWER_CONNECTED - \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* External Power State */ - qmiLocExternalPowerConfigEnumT_v02 externalPowerState; - /**< Power state; injected by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED - \item 0x00000001 -- EXTERNAL_POWER_CONNECTED - \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Ext Power Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set External Power Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, /**< PPP PDN type. */ - QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerPDNEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocServerPDNEnumT_v02 pdnType; - /**< PDN type of the APN profile. - - Valid values: \n - - 0x00000001 -- PDN_TYPE_IPV4 \n - - 0x00000002 -- PDN_TYPE_IPV6 \n - - 0x00000003 -- PDN_TYPE_IPV4V6 \n - - 0x00000004 -- PDN_TYPE_PPP - */ - - char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; - /**< APN name. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 101 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocApnProfilesStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. */ - eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, /**< Location server request failed. */ - QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerReqStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inform the service about the - status of the location server connection request that the - service may have sent via the - QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ -typedef struct { - - /* Mandatory */ - /* Connection Handle */ - uint32_t connHandle; - /**< Connection handle that the service specified in the - Location Server Connection request event. */ - - /* Mandatory */ - /* Request Type */ - qmiLocServerRequestEnumT_v02 requestType; - /**< Type of connection request service that was specified in the - Location Server Connection Request event. - - Valid values: \n - - 0x00000001 -- OPEN \n - - 0x00000002 -- CLOSE - */ - - /* Mandatory */ - /* Connection Status */ - qmiLocServerReqStatusEnumT_v02 statusType; - /**< Status of the Connection request. - - Valid values: \n - - 0x00000001 -- STATUS_SUCCESS = 1 \n - - 0x00000002 -- STATUS_FAILURE = 2 - - */ - - /* Optional */ - /* APN Profile */ - uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ - qmiLocApnProfilesStructT_v02 apnProfile; - /**< \n Access Point Name (APN) profile information is present only when - requestType is OPEN and statusType is SUCCESS. */ -}qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inform the service about the - status of the location server connection request that the - service may have sent via the - QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ -typedef struct { - - /* Mandatory */ - /* Status of Inform Loc Server Conn Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inform Location Server Connection Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. */ - eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, /**< V2 VX version. */ - QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocVxVersionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. */ - eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, /**< SUPL version 2.0. */ - QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSuplVersionEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocLppConfigMaskT_v02; -#define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ -#define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ -typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in the control plane. */ -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in the user plane. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to configure parameters stored - in the nonvolatile memory. */ -typedef struct { - - /* Optional */ - /* SUPL Security */ - uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ - uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SUPL security is enabled - \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* VX Version */ - uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ - qmiLocVxVersionEnumT_v02 vxVersion; - /**< VX version. - - Valid values: \begin{itemize1} - \item 0x00000001 -- VX_VERSION_V1_ONLY - \item 0x00000002 -- VX_VERSION_V2_ONLY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Version */ - uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ - qmiLocSuplVersionEnumT_v02 suplVersion; - /**< SUPL version. - - Valid values: \n - - 0x00000001 -- SUPL_VERSION_1_0 \n - - 0x00000002 -- SUPL_VERSION_2_0 - */ - - /* Optional */ - /* LPP Configuration */ - uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ - qmiLocLppConfigMaskT_v02 lppConfig; - /**< LTE Positioning Profile (LPP) configuration. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE - \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Assisted GLONASS Protocol Mask */ - uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ - qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Configures the protocols that the location service supports - for assisted GLONASS. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP - \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000001ull) /**< Mask for the SUPL security configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000010ull) /**< Mask for the LPP configuration parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to configure parameters stored - in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Set Config Params Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ - qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; - /**< Identifies parameters that were not set successfully. This field - is sent only if the status is not a success. - - Valid bitmasks: \begin{itemize1} - \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY - \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION - \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION - \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG - \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the configuration - parameters stored in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Config Parameters */ - qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; - /**< Mask denoting the configuration parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY - \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION - \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION - \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG - \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the configuration - parameters stored in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Get Config Params Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Security */ - uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ - uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SUPL security is enabled - \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* VX Version */ - uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ - qmiLocVxVersionEnumT_v02 vxVersion; - /**< VX version. - - Valid values: \begin{itemize1} - \item 0x00000001 -- VX_VERSION_V1_ONLY - \item 0x00000002 -- VX_VERSION_V2_ONLY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Version */ - uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ - qmiLocSuplVersionEnumT_v02 suplVersion; - /**< SUPL version. - - Valid values: \n - - 0x00000001 -- SUPL_VERSION_1_0 \n - - 0x00000002 -- SUPL_VERSION_2_0 - */ - - /* Optional */ - /* LPP Configuration */ - uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ - qmiLocLppConfigMaskT_v02 lppConfig; - /**< LTE Positioning Profile (LPP) configuration. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE - \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Assisted GLONASS Protocol Mask */ - uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ - qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Assisted GLONASS Protocol mask. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP - \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02 = 0, /**< Sensors data should be requested whenever a position request is - received. If sensor data are injected, the positioning engine - attempts to improve the heading and positioning performance using sensors. - This is the default. - */ - eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, /**< Inertial sensors are not to be used to aid heading and position - improvement. */ - QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSensorsControlConfigSensorUseEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the sensor control configuration. */ -typedef struct { - - /* Optional */ - /* Sensors Usage */ - uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ - qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; - /**< Controls how sensors are used to aid heading and positioning - performance. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SENSORS_USE_ENABLED: - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. - \item 0x00000001 -- SENSORS_USE_DISABLED: - Inertial sensors are not to be used to aid in heading and - position improvement. - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the sensor control configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSensorControlConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSensorControlConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor control configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensors Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Sensors Usage */ - uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ - qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; - /**< Controls how sensors are used to aid the heading and positioning - performance. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SENSORS_USE_ENABLED: - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. - \item 0x00000001 -- SENSORS_USE_DISABLED: - Inertial sensors are not to be used to aid in the heading and - position improvement. - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocSensorPropertiesMaskT_v02; -#define QMI_LOC_SENSOR_PROPERTIES_MASK_GYRO_BIAS_VARIANCE_RANDOM_WALK_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000001) /**< Denotes the gyro bias variance random walk parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000002) /**< Denotes the velocity random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000004) /**< Denotes the acceleration random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000008) /**< Denotes the angle random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_RATE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000010) /**< Denotes the rate random walk spectral density parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the properties specific to the type of sensor used. - The control point must set sensor properties before they can be - used to aid in heading and positioning performance improvement. - */ -typedef struct { - - /* Optional */ - /* Gyro Bias Random Walk Variance */ - uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ - float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk variance parameter as a positive - floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. - The gyro bias variance random walk parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians^2/seconds^4 - - */ - - /* Optional */ - /* Velocity Random Walk Spectral Density */ - uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ - float velocityRandomWalkSpectralDensity; - /**< Specifies the velocity random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The velocity random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^2/Hertz^0.5 - - */ - - /* Optional */ - /* Acceleration Random Walk Spectral Density */ - uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ - float accelerationRandomWalkSpectralDensity; - /**< Specifies the acceleration random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The acceleration random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^3/Hertz^0.5 - - */ - - /* Optional */ - /* Angle Random Walk Spectral Density */ - uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ - float angleRandomWalkSpectralDensity; - /**< Specifies the angle random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The angle random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds/Hertz^0.5 - - */ - - /* Optional */ - /* Rate Random Walk Spectral Density */ - uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ - float rateRandomWalkSpectralDensity; - /**< Specifies the rate random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The rate random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds^2/Hertz^0.5 - - */ -}qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the properties specific to the type of sensor used. - The control point must set sensor properties before they can be - used to aid in heading and positioning performance improvement. - */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Properties Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Properties request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000007 -- CONFIG_NOT_SUPPORTED - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Set Sensor Properties */ - uint8_t failedSensorPropertiesMask_valid; /**< Must be set to true if failedSensorPropertiesMask is being passed */ - qmiLocSensorPropertiesMaskT_v02 failedSensorPropertiesMask; - /**< This field will be sent only if the status is not a success. - Identifies the parameters that were not set successfully. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK - \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Retrieves the current sensor properties. */ -typedef struct { - - /* Mandatory */ - /* Sensor Properties Config Parameters */ - qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; - /**< Mask denoting the sensor properties parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK - \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor properties. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Properties Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensors Properties request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000007 -- CONFIG_NOT_SUPPORTED - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Gyro Bias Random Walk Variance */ - uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ - float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk variance parameter as a positive - floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. - The gyro bias variance random walk parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians^2/seconds^4 - - */ - - /* Optional */ - /* Velocity Random Walk Spectral Density */ - uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ - float velocityRandomWalkSpectralDensity; - /**< Specifies the velocity random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The velocity random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^2/Hertz^0.5 - - */ - - /* Optional */ - /* Acceleration Random Walk Spectral Density */ - uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ - float accelerationRandomWalkSpectralDensity; - /**< Specifies the acceleration random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The acceleration random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^3/Hertz^0.5 - - */ - - /* Optional */ - /* Angle Random Walk Spectral Density */ - uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ - float angleRandomWalkSpectralDensity; - /**< Specifies the angle random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The angle random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds/Hertz^0.5 - - */ - - /* Optional */ - /* Rate Random Walk Spectral Density */ - uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ - float rateRandomWalkSpectralDensity; - /**< Specifies the rate random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The rate random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds^2/Hertz^0.5 - - */ -}qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. - This mode can optimize power consumption and give a - power-balanced positioning and heading enhancement using - inertial sensors */ - eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, /**< Sensors usage is to be forced ON. - This mode can be requested by the control point when - power consumption is not a restriction to the use of - inertial sensors. */ - QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSensorPerformanceControlModeEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocSensorAlgorithmMaskT_v02; -#define QMI_LOC_SENSOR_ALGORITHM_MASK_DISABLE_INS_POSITIONING_FILTER_V02 ((qmiLocSensorAlgorithmMaskT_v02)0x00000001) /**< Inertial sensors are not to be used in Accelerometer-integrated fashion with - GNSS. They can still be used for aiding in heading improvements. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Provides fine-grained control of sensor based positioning - performance */ -typedef struct { - - /* Optional */ - /* Sensor Performance Control Mode */ - uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ - qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; - /**< Controls when sensors data is requested during GNSS fix processing. - This field is relevant only when sensors have been enabled using the - sensors control configuration. - - Valid values: \begin{itemize1} - \item 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data - injection based on internal criteria. This is the default. - \item 0x00000001 -- FORCED: \n - The GNSS location engine must request use of sensors every time - the GNSS location engine turns on. - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Accelerometer Sampling Specification */ - uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; - /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location - engine is to request acceleration data to be used by the low data rate - filter. The sensor data rate is specified in terms of the nominal number - of samples per batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; - /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location - engine is to request gyro data to be used by the high data rate filter. - The sensor data rate is specified in terms of the nominal number of - samples per batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Algorithm Configuration */ - uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ - qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; - /**< Sets which sensor algorithms are to be used when processing sensor data. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* High Data Rate Filter Accelerometer Sampling Specification */ - uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ - - /* Optional */ - /* High Data Rate Filter Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data rate - is specified in terms of the nominal number of samples per batch and the - number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ -}qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000010) /**< Failed to set the accelerometer sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000020) /**< Failed to set the gyroscope sampling specification. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Provides fine-grained control of sensor based positioning - performance */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Perf Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Performance Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Configuration */ - uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ - qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; - /**< Identifies parameters that were not configured successfully. This field - is sent only if the status is not a success. - - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- PERFORMANCE_MODE - \item 0x00000002 -- ACCEL_SAMPLING_SPEC - \item 0x00000004 -- GYRO_SAMPLING_SPEC - \item 0x00000008 -- ALGORITHM_CONFIG - \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH - \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSensorPerformanceControlConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor performance control - configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Perf Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensor Performance Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Performance Control Mode */ - uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ - qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; - /**< Controls when sensor data is requested during GNSS fix processing. - This field is relevant only when sensors have been enabled using the - sensor control configuration. - - Valid values: \begin{itemize1} - \item 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data - injection based on internal criteria. This is the default. - \item 0x0000001 -- FORCED: \n - The GNSS location engine must request use of the sensors every time - the GNSS location engine turns on. - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Accelerometer Sampling Specification */ - uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2Hz batching rate. - */ - - /* Optional */ - /* Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data - rate is specified in terms of the nominal number of samples per batch - and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Algorithm Configuration */ - uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ - qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; - /**< Informs which sensor algorithms are currently set. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* High Data Rate Filter Accelerometer Sampling Specification */ - uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ - - /* Optional */ - /* High Data Rate Filter Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data rate - is specified in terms of the nominal number of samples per batch and the - number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ -}qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects a SUPL certificate to be used in AGNSS sessions. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate ID */ - uint8_t suplCertId; - /**< Certificate ID of the SUPL certificate. \n - - Units: Bytes \n - - Range: 0 to 9 */ - - /* Mandatory */ - /* SUPL Certificate Data */ - uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ - uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; - /**< SUPL certificate contents. \n - - Type: Array of bytes. \n - - Maximum certificate size: 2000 bytes */ -}qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects a SUPL certificate to be used in AGNSS sessions. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject SUPL Certificate request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Deletes a SUPL certificate. */ -typedef struct { - - /* Optional */ - /* SUPL Certificate ID */ - uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ - uint8_t suplCertId; - /**< Certificate ID of the SUPL certificate to be deleted. \n - - Units: Bytes \n - - Range: 0 to 9 \n - If suplCertId is not specified, - all SUPL certificates are deleted. */ -}qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Deletes a SUPL certificate. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate Deletion Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete SUPL Certificate request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< Denotes whether the position engine uses the - injected position in a direct position calculation. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< Denotes whether the position engine filters the - SV usage in the fix. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< Denotes whether the position engine stores assistance data - in persistent memory. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to configure position engine - functionality. */ -typedef struct { - - /* Optional */ - /* Injected Position Control */ - uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ - uint8_t injectedPositionControl; - /**< Controls how the injected position is used in the position engine. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Use the injected position in a direct position - calculation - \item 0x00 (FALSE) -- Do not use the injected position in a direct - position calculation - \end{itemize1} - The default value is TRUE. - */ - - /* Optional */ - /* Filter SV Usage */ - uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ - uint8_t filterSvUsage; - /**< Controls whether SV usage is filtered in a position fix. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Filter the usage of SVs in the fix - \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix - \end{itemize1} - The default value is FALSE. - */ - - /* Optional */ - /* Store Assist Data */ - uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ - uint8_t storeAssistData; - /**< Controls whether assistance data is to be stored in - persistent memory. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Store assistance data in persistent memory - \item 0x00 (FALSE) -- Do not store assistance data in persistent memory - \end{itemize1} - The default value is TRUE. - */ -}qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to configure position engine - functionality. */ -typedef struct { - - /* Mandatory */ - /* Set Position Engine Configuration Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ - qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; - /**< Identifies the parameters that were not set successfully. - This field is sent only if the status is other than SUCCESS. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- INJECTED_POSITION_CONTROL - \item 0x00000002 -- FILTER_SV_USAGE - \item 0x00000004 -- STORE_ASSIST_DATA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the position engine - configuration parameters. */ -typedef struct { - - /* Mandatory */ - /* Config Parameters */ - qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; - /**< Mask denoting the configuration parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- INJECTED_POSITION_CONTROL - \item 0x00000002 -- FILTER_SV_USAGE - \item 0x00000004 -- STORE_ASSIST_DATA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the position engine - configuration parameters. */ -typedef struct { - - /* Mandatory */ - /* Get Position Engine Configuration Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Injected Position Control */ - uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ - uint8_t injectedPositionControl; - /**< Specifies whether the injected position is used for a direct calculation - in the position engine. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- The injected position is used in a direct - position calculation - \item 0x00 (FALSE) -- The injected position is not used in a direct - position calculation - \end{itemize1} - The default value is TRUE. - */ - - /* Optional */ - /* Filter SV Usage */ - uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ - uint8_t filterSvUsage; - /**< Specifies whether SV usage is filtered in a position fix. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- SV usage is filtered in the fix - \item 0x00 (FALSE) -- SV usage is not filtered in the fix - \end{itemize1} - The default value is FALSE. - */ - - /* Optional */ - /* Store Assist Data */ - uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ - uint8_t storeAssistData; - /**< Specifies whether assistance data is stored in persistent memory. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Assistance data is stored in persistent memory - \item 0x00 (FALSE) -- Assistance data is not stored in persistent - memory - \end{itemize1} - The default value is TRUE. - */ -}qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint8_t qmiLocGeofenceBreachMaskT_v02; -#define QMI_LOC_GEOFENCE_BREACH_ENTERING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x01) /**< If this mask is set, a breach event is reported - when the Geofence is entered. */ -#define QMI_LOC_GEOFENCE_BREACH_LEAVING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x02) /**< If this mask is set, a breach event is reported - when the Geofence is exited. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCERESPONSIVENESSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_LOW_V02 = 0x01, /**< The Geofence is monitored for a breach at a - lower rate. The gap between actual breach and - the time it is reported is higher. This - setting results in lower power usage. */ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a - medium rate. This is the default setting. */ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, /**< The Geofence is monitored for a breach at a - high rate. The gap between actual breach and - the time it is reported is low. This results - in higher power usage. */ - QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceResponsivenessEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCECONFIDENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_CONFIDENCE_LOW_V02 = 0x01, /**< The Geofence engine indicates a breach with - low confidence. This setting results in lower - power usage. This setting can impact the "yield" because - incorrect breach events may be sent. */ - eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with - medium confidence. This is the default setting. */ - eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, /**< The Geofence engine indicates a breach with - high confidence. This setting results in higher - power usage. */ - QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceConfidenceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - double latitude; - /**< Latitude of the center of the Geofence.*/ - - double longitude; - /**< Longitude of the center of the Geofence.*/ - - uint32_t radius; - /**< Radius of the circular Geofence in meters. */ -}qmiLocCircularGeofenceArgsStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. */ - eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, /**< Position outside a Geofence. */ - QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofencePositionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to add a circular Geofence. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Add Circular Geofence - indication. */ - - /* Mandatory */ - /* Circular Geofence Arguments */ - qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; - - /* Mandatory */ - /* Breach Event Mask */ - qmiLocGeofenceBreachMaskT_v02 breachMask; - /**< Specifies the breach events in which the client is interested. - - Valid values: \begin{itemize1} - \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK - \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ - - /* Mandatory */ - /* Include Position in Breach Event */ - uint8_t includePosition; - /**< Specifies whether the Geofence engine is to include the position - in a breach event. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Position will be reported with the breach event - \item 0x00 (FALSE) -- Position will not be reported with the breach - event - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Responsiveness */ - uint8_t responsiveness_valid; /**< Must be set to true if responsiveness is being passed */ - qmiLocGeofenceResponsivenessEnumT_v02 responsiveness; - /**< Specifies the rate of detection for a Geofence breach. - This may impact the time lag between the actual breach event and - when it is reported. This parameter has power implications - and is to be fine-tuned to optimize power savings. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW - \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED - \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Confidence */ - uint8_t confidence_valid; /**< Must be set to true if confidence is being passed */ - qmiLocGeofenceConfidenceEnumT_v02 confidence; - /**< Given a breach event, the confidence determines the probability - that the breach happened at the Geofence boundary. - This parameter has power implications and - is to be fine-tuned to optimize power savings. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW - \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED - \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH - \vspace{-0.18in} \end{itemize1} */ -}qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to add a circular Geofence. */ -typedef struct { - - /* Mandatory */ - /* Add Circular Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Add Circular Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000008 -- INSUFFICIENT_MEMORY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Add Circular - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Geofence identifier allocated by the engine. - The client must include this identifier in all transactions - pertaining to this Geofence. */ -}qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to delete a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence that is to be deleted. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Delete Geofence - indication. */ -}qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to delete a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Delete Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was deleted. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Delete - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ -}qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. */ - eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, /**< The Geofence was initiated by the device. */ - QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceOriginEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. */ - eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, /**< The Geofence monitoring is suspended. */ - QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to query a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence that is to be queried. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned with the Query Geofence - indication. */ -}qmiLocQueryGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to query a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Query Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Query Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was queried. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Query - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ - - /* Optional */ - /* Geofence Origin */ - uint8_t geofenceOrigin_valid; /**< Must be set to true if geofenceOrigin is being passed */ - qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; - /**< Originator of the Geofence. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK - \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Position with Respect to Geofence */ - uint8_t posWrtGeofence_valid; /**< Must be set to true if posWrtGeofence is being passed */ - qmiLocGeofencePositionEnumT_v02 posWrtGeofence; - /**< Indicates if the client is currently inside or outside - the Geofence. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_POSITION_INSIDE - \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Circular Geofence Parameters */ - uint8_t circularGeofenceArgs_valid; /**< Must be set to true if circularGeofenceArgs is being passed */ - qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; - - /* Optional */ - /* Geofence State */ - uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ - qmiLocGeofenceStateEnumT_v02 geofenceState; - /**< Specifies whether the Geofence is to be actively monitored. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_STATE_ACTIVE - \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ -}qmiLocQueryGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to edit a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence to be edited. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Edit Geofence - request. This parameter will always be present if the - status field is set to SUCCESS. - */ - - /* Optional */ - /* Geofence State */ - uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ - qmiLocGeofenceStateEnumT_v02 geofenceState; - /**< Specifies whether the Geofence is to be actively monitored. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_STATE_ACTIVE - \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Breach Event Mask */ - uint8_t breachMask_valid; /**< Must be set to true if breachMask is being passed */ - qmiLocGeofenceBreachMaskT_v02 breachMask; - /**< Specifies the breach events in which the client is interested. - - Valid values: \begin{itemize1} - \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK - \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEditGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocGeofenceConfigParamMaskT_v02; -#define QMI_LOC_GEOFENCE_PARAM_MASK_GEOFENCE_STATE_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000001) /**< Mask for the Geofence state parameter. */ -#define QMI_LOC_GEOFENCE_PARAM_MASK_BREACH_MASK_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000002) /**< Mask for Geofence breach mask parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to edit a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Edit Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Edit Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was edited. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is specified in the Edit Geofence request. */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedParams_valid; /**< Must be set to true if failedParams is being passed */ - qmiLocGeofenceConfigParamMaskT_v02 failedParams; - /**< Specified only when the status is not set to SUCCESS. If - the mask corresponding to a field is set, it indicates that - the Geofence parameter could not be edited. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE - \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEditGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the best available - position estimate from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Get Best Available Position indication. */ -}qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the best available - position estimate from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Best Available Position Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Best Available Position request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Get Best - Available Position request. This parameter will - always be present if the status field is set to - SUCCESS. */ - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Circular Horizontal Position Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Time Uncertainty */ - uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ - float timeUnc; - /**< Time uncertainty. \n - - Units: Milliseconds */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ - uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty. \n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Semi-Major Axis */ - uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty. \n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Azimuth */ - uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation. \n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Optional */ - /* Horizontal Circular Confidence */ - uint8_t horCircularConfidence_valid; /**< Must be set to true if horCircularConfidence is being passed */ - uint8_t horCircularConfidence; - /**< Horizontal circular uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Elliptical Confidence */ - uint8_t horEllipticalConfidence_valid; /**< Must be set to true if horEllipticalConfidence is being passed */ - uint8_t horEllipticalConfidence; - /**< Horizontal elliptical uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Horizontal Speed */ - uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ - float horSpeed; - /**< Horizontal speed. \n - - Units: Meters/second */ - - /* Optional */ - /* Horizontal Speed Uncertainty */ - uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ - float horSpeedUnc; - /**< Horizontal speed uncertainty. \n - - Units: Meters/second */ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level. \n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Vertical Speed */ - uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ - float vertSpeed; - /**< Vertical speed. \n - - Units: Meters/second */ - - /* Optional */ - /* Vertical Speed Uncertainty */ - uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ - float vertSpeedUnc; - /**< Vertical speed uncertainty. \n - - Units: Meters/second */ - - /* Optional */ - /* Heading */ - uint8_t heading_valid; /**< Must be set to true if heading is being passed */ - float heading; - /**< Heading. \n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Heading Uncertainty */ - uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ - float headingUnc; - /**< Heading uncertainty. \n - - Type: Floating point \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Magnetic Deviation */ - uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ - float magneticDeviation; - /**< Difference between the bearing to true north and the bearing shown - on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ - - /* Optional */ - /* Technology Used Mask */ - uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ - qmiLocPosTechMaskT_v02 technologyMask; - /**< Technology used in computing this fix. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SATELLITE - \item 0x00000002 -- CELLID - \item 0x00000004 -- WIFI - \item 0x00000008 -- SENSORS - \item 0x00000010 -- REFERENCE_LOCATION - \item 0x00000020 -- INJECTED_COARSE_POSITION - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Dilution of Precision */ - uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ - qmiLocDOPStructT_v02 DOP; - - /* Optional */ - /* GPS Time */ - uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ - qmiLocGPSTimeStructT_v02 gpsTime; - - /* Optional */ - /* Time Source */ - uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ - qmiLocTimeSourceEnumT_v02 timeSrc; - /**< Time source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- TIME_SRC_INVALID - \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER - \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING - \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT - \item 0x00000004 -- TIME_SRC_TOW_DECODE - \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED - \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED - \item 0x00000007 -- TIME_SRC_NAV_SOLUTION - \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Sensor Data Usage */ - uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ - qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; - - /* Optional */ - /* SVs Used to Calculate the Fix */ - uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ - uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ - uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; - /**< Each entry in the list contains the SV ID of a satellite - used for calculating this position report. The following - information is associated with each SV ID: \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ -}qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known. */ - eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is Stationary. */ - eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, /**< Device state is In Motion. */ - QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocMotionStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known. */ - eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in Pedestrian mode; nothing else is known about the movement. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian Walking mode. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian Running mode. */ - eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, /**< Device movement is in Vehicular mode; nothing else is known about the movement. */ - QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocMotionModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocMotionStateEnumT_v02 motion_state; - /**< Current motion state of the user. \n - - Valid values: \begin{itemize1} - \item eQMI_LOC_MOTION_STATE_UNKNOWN (0) -- Device state is not known. - \item eQMI_LOC_MOTION_STATE_STATIONARY (1) -- Device state is Stationary. - \item eQMI_LOC_MOTION_STATE_IN_MOTION (2) -- Device state is In Motion. - \vspace{0.06in} \end{itemize1} - - Absolute rest and relative rest are both indicated by setting motion_state - to Stationary. The relative rest state can be distinguished from absolute - rest by reducing probability_of_state. - */ - - qmiLocMotionModeEnumT_v02 motion_mode; - /**< Modes of user motion. \n - - Valid values: \begin{itemize1} - \item eQMI_LOC_MOTION_MODE_ UNKNOWN (0) -- Device movement is not known. - \item eQMI_LOC_MOTION_MODE_ STATIONARY (1) -- Device is not moving. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_UNKNOWN (200) -- Device movement - is in Pedestrian mode; nothing else is known about the movement. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_WALKING (201) -- Device movement - is in Pedestrian Walking mode. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_RUNNING (202) -- Device movement - is in Pedestrian Running mode. - \item eQMI_LOC_MOTION_MODE_ VEHICLE_UNKNOWN (300) -- Device movement is - in Vehicular mode; nothing else is known about the movement. - \vspace{0.06in} \end{itemize1} - - The motion_mode value is independent of the motion_state value. - */ - - float probability_of_state; - /**< Probability that the device is actually undergoing the motion state - specified by the combination of the values of motion_state, motion_mode, - and motion_sub_mode. \vspace{0.06in} - - This value is a floating point number in the range of 0 to 100, in - units of percent probability. Any value greater than 99.9999 is - applied as 99.9999. \vspace{0.06in} - - It is recommended that if a particular combination of motion_state and - motion_mode cannot be determined with more than 50 percent confidence, - that a more general statement of user motion be made. - For example, if the mode of In-Motion + Pedestrian-Running can only be - determined with 50 percent probability, and the simpler statement of In-Motion - can be determined with 90 percent probability, it is recommended that this field - be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} - - If the motion_state is not known, the value in this field is not used. - */ - - uint16_t age; - /**< Age of the motion data in milliseconds at the time of injection. - */ - - uint16_t timeout; - /**< If the age of the motion data input exceeds the timeout value, the data - will no longer be used. The timeout value is in units of milliseconds. - Values in the range of 0 to 10000 are accepted. If 65535 is provided, - the motion data input is applied until the next input is - received. \vspace{0.06in} - - If the determination of motion data is an instantaneous observation - and no notice is guaranteed to be given via the QMI on a change in the - state of the motion data, it is recommended that this field be set to 0. \vspace{0.06in} - - If the determination of motion data is continuously monitored - external to the QMI and an update is always applied to the QMI upon any - change in state, a value of 65535 is used for this field. - Note that in this case, if a certain mode is set and is not later - unset (e.g., by sending in the request message with a user motion - state of Unknown), the value is applied indefinitely. - */ -}qmiLocMotionDataStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects motion data for MSM GPS service use. */ -typedef struct { - - /* Mandatory */ - /* Motion Data */ - qmiLocMotionDataStructT_v02 motion_data; - /**< Current motion data of the client */ -}qmiLocInjectMotionDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects motion data for MSM GPS service use. */ -typedef struct { - - /* Mandatory */ - /* Inject Motion Data Request Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Motion Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_ PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectMotionDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to retrieve the list of network - initiated Geofence IDs. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The same transaction ID - will be returned in the Get NI Geofence ID List indication. */ -}qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to retrieve the list of network - initiated Geofence IDs. */ -typedef struct { - - /* Mandatory */ - /* Get NI Geofence ID List status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get NI Geofence ID List request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Get NI - Geofence ID List request. */ - - /* Optional */ - /* NI Geofence ID List */ - uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ - uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ - uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; - /**< List containing the NI Geofence IDs. - - Type: Array of unsigned 32-bit integers \n - - Maximum NI Geofence ID List length: 16 */ -}qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t MCC; - /**< GSM mobile country code. Refer to ITU-T E.212 specification */ - - uint32_t MNC; - /**< GSM mobile network code. Refer to ITU-T E.212 specification*/ - - uint32_t LAC; - /**< GSM location area code.Refer to ITU-T E.212 specification */ - - uint32_t CID; - /**< GSM cell identification.Refer to ITU-T E.212 specification */ -}qmiLocGSMCellIdStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used to inject GSM Cell information into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* GSM Cell ID */ - qmiLocGSMCellIdStructT_v02 gsmCellId; - /**< Identifies the GSM Cell the device is currently camped on.*/ - - /* Mandatory */ - /* Roaming Status */ - uint8_t roamingStatus; - /**< Whether the device is roaming. - \begin{itemize1} - \item 0x01 (TRUE) -- The device is roaming. - \item 0x00 (FALSE) -- The device is not roaming. - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocInjectGSMCellInfoReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to inject GSM Cell information into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Inject GSM Cell Info Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject GSM Cell Info request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ -}qmiLocInjectGSMCellInfoIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL_V02 = 0, /**< SUPL netwrok initiated message is being injected. */ - QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used to inject a network initiated message into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Injected Network Initiated Message Type */ - qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02 injectedNIMessageType; - /**< Type of the network initiated message being injected - Valid Values: - - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL (0) -- SUPL netwrok initiated message is being injected. */ - - /* Mandatory */ - /* Injected Network Initiated Message */ - uint32_t injectedNIMessage_len; /**< Must be set to # of elements in injectedNIMessage */ - uint8_t injectedNIMessage[QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02]; - /**< Network initiated message body. - If the inject NI message type is TYPE_SUPL, the message contains - a SUPL INIT message as defined in OMA-TS-ULP-V2_0-20110527-C specification. */ -}qmiLocInjectNetworkInitiatedMessageReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to inject a network initiated message into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Inject Network Initiated Message Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Network Initiated Message request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT \n - - 0x00000008 -- INSUFFICIENT_MEMORY \n */ -}qmiLocInjectNetworkInitiatedMessageIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocWWANOutOfServiceNotificationReqMsgT is empty - * typedef struct { - * }qmiLocWWANOutOfServiceNotificationReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to notify the location engine that the device is - no longer camped. */ -typedef struct { - - /* Mandatory */ - /* Notify WWAN Out of Service Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Notify WWAN out of service request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT \n - */ -}qmiLocWWANOutOfServiceNotificationIndMsgT_v02; /* Message */ -/** - @} - */ - -/*Service Message Definition*/ -/** @addtogroup loc_qmi_msg_ids - @{ - */ -#define QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02 0x0020 -#define QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02 0x0020 -#define QMI_LOC_REG_EVENTS_REQ_V02 0x0021 -#define QMI_LOC_REG_EVENTS_RESP_V02 0x0021 -#define QMI_LOC_START_REQ_V02 0x0022 -#define QMI_LOC_START_RESP_V02 0x0022 -#define QMI_LOC_STOP_REQ_V02 0x0023 -#define QMI_LOC_STOP_RESP_V02 0x0023 -#define QMI_LOC_EVENT_POSITION_REPORT_IND_V02 0x0024 -#define QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02 0x0025 -#define QMI_LOC_EVENT_NMEA_IND_V02 0x0026 -#define QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02 0x0027 -#define QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02 0x0028 -#define QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02 0x0029 -#define QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02 0x002A -#define QMI_LOC_EVENT_ENGINE_STATE_IND_V02 0x002B -#define QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02 0x002C -#define QMI_LOC_EVENT_WIFI_REQ_IND_V02 0x002D -#define QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02 0x002E -#define QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02 0x002F -#define QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02 0x0030 -#define QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 0x0031 -#define QMI_LOC_GET_SERVICE_REVISION_REQ_V02 0x0032 -#define QMI_LOC_GET_SERVICE_REVISION_RESP_V02 0x0032 -#define QMI_LOC_GET_SERVICE_REVISION_IND_V02 0x0032 -#define QMI_LOC_GET_FIX_CRITERIA_REQ_V02 0x0033 -#define QMI_LOC_GET_FIX_CRITERIA_RESP_V02 0x0033 -#define QMI_LOC_GET_FIX_CRITERIA_IND_V02 0x0033 -#define QMI_LOC_NI_USER_RESPONSE_REQ_V02 0x0034 -#define QMI_LOC_NI_USER_RESPONSE_RESP_V02 0x0034 -#define QMI_LOC_NI_USER_RESPONSE_IND_V02 0x0034 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02 0x0035 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02 0x0035 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02 0x0035 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 0x0037 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02 0x0037 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02 0x0037 -#define QMI_LOC_INJECT_UTC_TIME_REQ_V02 0x0038 -#define QMI_LOC_INJECT_UTC_TIME_RESP_V02 0x0038 -#define QMI_LOC_INJECT_UTC_TIME_IND_V02 0x0038 -#define QMI_LOC_INJECT_POSITION_REQ_V02 0x0039 -#define QMI_LOC_INJECT_POSITION_RESP_V02 0x0039 -#define QMI_LOC_INJECT_POSITION_IND_V02 0x0039 -#define QMI_LOC_SET_ENGINE_LOCK_REQ_V02 0x003A -#define QMI_LOC_SET_ENGINE_LOCK_RESP_V02 0x003A -#define QMI_LOC_SET_ENGINE_LOCK_IND_V02 0x003A -#define QMI_LOC_GET_ENGINE_LOCK_REQ_V02 0x003B -#define QMI_LOC_GET_ENGINE_LOCK_RESP_V02 0x003B -#define QMI_LOC_GET_ENGINE_LOCK_IND_V02 0x003B -#define QMI_LOC_SET_SBAS_CONFIG_REQ_V02 0x003C -#define QMI_LOC_SET_SBAS_CONFIG_RESP_V02 0x003C -#define QMI_LOC_SET_SBAS_CONFIG_IND_V02 0x003C -#define QMI_LOC_GET_SBAS_CONFIG_REQ_V02 0x003D -#define QMI_LOC_GET_SBAS_CONFIG_RESP_V02 0x003D -#define QMI_LOC_GET_SBAS_CONFIG_IND_V02 0x003D -#define QMI_LOC_SET_NMEA_TYPES_REQ_V02 0x003E -#define QMI_LOC_SET_NMEA_TYPES_RESP_V02 0x003E -#define QMI_LOC_SET_NMEA_TYPES_IND_V02 0x003E -#define QMI_LOC_GET_NMEA_TYPES_REQ_V02 0x003F -#define QMI_LOC_GET_NMEA_TYPES_RESP_V02 0x003F -#define QMI_LOC_GET_NMEA_TYPES_IND_V02 0x003F -#define QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 0x0040 -#define QMI_LOC_SET_LOW_POWER_MODE_RESP_V02 0x0040 -#define QMI_LOC_SET_LOW_POWER_MODE_IND_V02 0x0040 -#define QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 0x0041 -#define QMI_LOC_GET_LOW_POWER_MODE_RESP_V02 0x0041 -#define QMI_LOC_GET_LOW_POWER_MODE_IND_V02 0x0041 -#define QMI_LOC_SET_SERVER_REQ_V02 0x0042 -#define QMI_LOC_SET_SERVER_RESP_V02 0x0042 -#define QMI_LOC_SET_SERVER_IND_V02 0x0042 -#define QMI_LOC_GET_SERVER_REQ_V02 0x0043 -#define QMI_LOC_GET_SERVER_RESP_V02 0x0043 -#define QMI_LOC_GET_SERVER_IND_V02 0x0043 -#define QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 0x0044 -#define QMI_LOC_DELETE_ASSIST_DATA_RESP_V02 0x0044 -#define QMI_LOC_DELETE_ASSIST_DATA_IND_V02 0x0044 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0045 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0045 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02 0x0045 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0046 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0046 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02 0x0046 -#define QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 0x0047 -#define QMI_LOC_INJECT_WIFI_POSITION_RESP_V02 0x0047 -#define QMI_LOC_INJECT_WIFI_POSITION_IND_V02 0x0047 -#define QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 0x0048 -#define QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02 0x0048 -#define QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02 0x0048 -#define QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 0x0049 -#define QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02 0x0049 -#define QMI_LOC_GET_REGISTERED_EVENTS_IND_V02 0x0049 -#define QMI_LOC_SET_OPERATION_MODE_REQ_V02 0x004A -#define QMI_LOC_SET_OPERATION_MODE_RESP_V02 0x004A -#define QMI_LOC_SET_OPERATION_MODE_IND_V02 0x004A -#define QMI_LOC_GET_OPERATION_MODE_REQ_V02 0x004B -#define QMI_LOC_GET_OPERATION_MODE_RESP_V02 0x004B -#define QMI_LOC_GET_OPERATION_MODE_IND_V02 0x004B -#define QMI_LOC_SET_SPI_STATUS_REQ_V02 0x004C -#define QMI_LOC_SET_SPI_STATUS_RESP_V02 0x004C -#define QMI_LOC_SET_SPI_STATUS_IND_V02 0x004C -#define QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 0x004D -#define QMI_LOC_INJECT_SENSOR_DATA_RESP_V02 0x004D -#define QMI_LOC_INJECT_SENSOR_DATA_IND_V02 0x004D -#define QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 0x004E -#define QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02 0x004E -#define QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02 0x004E -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02 0x004F -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02 0x004F -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 0x004F -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 0x0050 -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02 0x0050 -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02 0x0050 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0051 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0051 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02 0x0051 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0052 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0052 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02 0x0052 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 0x0053 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02 0x0053 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 0x0053 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0054 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0054 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0054 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0055 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0055 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0055 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0056 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0056 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02 0x0056 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0057 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0057 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02 0x0057 -#define QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 0x0058 -#define QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02 0x0058 -#define QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02 0x0058 -#define QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 0x0059 -#define QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02 0x0059 -#define QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02 0x0059 -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005A -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005A -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005A -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005B -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005B -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005B -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 0x005C -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02 0x005C -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02 0x005C -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 0x005D -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02 0x005D -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02 0x005D -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005E -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005E -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005E -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F -#define QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02 0x0060 -#define QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02 0x0061 -#define QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02 0x0062 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 0x0063 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02 0x0063 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 0x0063 -#define QMI_LOC_DELETE_GEOFENCE_REQ_V02 0x0064 -#define QMI_LOC_DELETE_GEOFENCE_RESP_V02 0x0064 -#define QMI_LOC_DELETE_GEOFENCE_IND_V02 0x0064 -#define QMI_LOC_QUERY_GEOFENCE_REQ_V02 0x0065 -#define QMI_LOC_QUERY_GEOFENCE_RESP_V02 0x0065 -#define QMI_LOC_QUERY_GEOFENCE_IND_V02 0x0065 -#define QMI_LOC_EDIT_GEOFENCE_REQ_V02 0x0066 -#define QMI_LOC_EDIT_GEOFENCE_RESP_V02 0x0066 -#define QMI_LOC_EDIT_GEOFENCE_IND_V02 0x0066 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 -#define QMI_LOC_INJECT_MOTION_DATA_REQ_V02 0x0068 -#define QMI_LOC_INJECT_MOTION_DATA_RESP_V02 0x0068 -#define QMI_LOC_INJECT_MOTION_DATA_IND_V02 0x0068 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 -#define QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 0x006A -#define QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02 0x006A -#define QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 0x006A -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 0x006B -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02 0x006B -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 0x006B -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 0x006C -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02 0x006C -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02 0x006C -/** - @} - */ - -/* Service Object Accessor */ -/** @addtogroup wms_qmi_accessor - @{ - */ -/** This function is used internally by the autogenerated code. Clients should use the - macro loc_get_service_object_v02( ) that takes in no arguments. */ -qmi_idl_service_object_type loc_get_service_object_internal_v02 - ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ); - -/** This macro should be used to get the service object */ -#define loc_get_service_object_v02( ) \ - loc_get_service_object_internal_v02( \ - LOC_V02_IDL_MAJOR_VERS, LOC_V02_IDL_MINOR_VERS, \ - LOC_V02_IDL_TOOL_VERS ) -/** - @} - */ - - -#ifdef __cplusplus -} -#endif -#endif - +#ifndef LOC_SERVICE_H +#define LOC_SERVICE_H +/** + @file location_service_v02.h + + @brief This is the public header file which defines the loc service Data structures. + + This header file defines the types and structures that were defined in + loc. It contains the constant values defined, enums, structures, + messages, and service message IDs (in that order) Structures that were + defined in the IDL as messages contain mandatory elements, optional + elements, a combination of mandatory and optional elements (mandatory + always come before optionals in the structure), or nothing (null message) + + An optional element in a message is preceded by a uint8_t value that must be + set to true if the element is going to be included. When decoding a received + message, the uint8_t values will be set to true or false by the decode + routine, and should be checked before accessing the values that they + correspond to. + + Variable sized arrays are defined as static sized arrays with an unsigned + integer (32 bit) preceding it that must be set to the number of elements + in the array that are valid. For Example: + + uint32_t test_opaque_len; + uint8_t test_opaque[16]; + + If only 4 elements are added to test_opaque[] then test_opaque_len must be + set to 4 before sending the message. When decoding, the _len value is set + by the decode routine and should be checked so that the correct number of + elements in the array will be accessed. + +*/ +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.5 + It was generated on: Thu Sep 27 2012 + From IDL File: location_service_v02.idl */ + +/** @defgroup loc_qmi_consts Constant values defined in the IDL */ +/** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ +/** @defgroup loc_qmi_enums Enumerated types used in QMI messages */ +/** @defgroup loc_qmi_messages Structures sent as QMI messages */ +/** @defgroup loc_qmi_aggregates Aggregate types used in QMI messages */ +/** @defgroup loc_qmi_accessor Accessor for QMI service object */ +/** @defgroup loc_qmi_version Constant values for versioning information */ + +#include +#include "qmi_idl_lib.h" +#include "common_v01.h" + + +#ifdef __cplusplus +extern "C" { +#endif + +/** @addtogroup loc_qmi_version + @{ + */ +/** Major Version Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MAJOR_VERS 0x02 +/** Revision Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MINOR_VERS 0x10 +/** Major Version Number of the qmi_idl_compiler used to generate this file */ +#define LOC_V02_IDL_TOOL_VERS 0x05 +/** Maximum Defined Message ID */ +#define LOC_V02_MAX_MESSAGE_ID 0x006C; +/** + @} + */ + + +/** @addtogroup loc_qmi_consts + @{ + */ + +/** Maximum string length for the Provider field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 24 + +/** Maximum string length for the Name field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 32 + +/** Maximum string length for the Version field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 8 + +/** Maximum length of the list containing the SVs that were used to generate + a position report. */ +#define QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02 80 + +/** Maximum number of satellites in the satellite report. */ +#define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 + +/** Maximum NMEA string length. */ +#define QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 200 + +/** Maximum length of the requestor ID string. */ +#define QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02 200 + +/** Session ID byte length. */ +#define QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02 4 + +/** Maximum client name length allowed. */ +#define QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02 64 + +/** Maximum URL length accepted by the location engine. */ +#define QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 255 + +/** IPV6 address length in bytes. */ +#define QMI_LOC_IPV6_ADDR_LENGTH_V02 8 + +/** SUPL hash length. */ +#define QMI_LOC_NI_SUPL_HASH_LENGTH_V02 8 + +/** Maximum client address length allowed. */ +#define QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02 20 + +/** Maximum codeword length allowed. */ +#define QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02 20 + +/** Maximum number of NTP Servers sent out with this event. */ +#define QMI_LOC_MAX_NTP_SERVERS_V02 3 + +/** Maximum number of predicted orbits servers supported in the location + engine. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 + +/** Maximum GNSS Measurement Engine Firmware Version String length. */ +#define QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Hosted Software Version String length. */ +#define QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Full Version String length. */ +#define QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 255 + +/** Maximum part length that can be injected. The client should + also look at the maxPartSize field in the predicted orbits injection + request indication and pick the minimum of the two. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 1024 + +/** Maximum length of the delete SV information list */ +#define QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02 128 + +/** MAC address length in bytes. */ +#define QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02 6 + +/** Maximum number of APs that the sender can report. */ +#define QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02 50 + +/** Maximum number of samples that can be injected in a TLV. */ +#define QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02 50 + +/** Maximum APN string length allowed. */ +#define QMI_LOC_MAX_APN_NAME_LENGTH_V02 100 + +/** Maximum APN profiles supported. */ +#define QMI_LOC_MAX_APN_PROFILES_V02 6 + +/** Maximum length of the SUPL certificate. */ +#define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 + +/** Maximum length of the network-initiated Geofence ID + list */ +#define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 + +/** Maximum length of the injected network initiated message. */ +#define QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02 1024 +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Response Message; Generic response definition. This message is used to tell + clients whether their message was accepted for further + processing or rejected. */ +typedef struct { + + /* Mandatory */ + /* Result Code */ + qmi_response_type_v01 resp; +}qmiLocGenRespMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Informs the service of the minor revision of the interface + definition that the control point implements. */ +typedef struct { + + /* Mandatory */ + /* Revision */ + uint32_t revision; + /**< Revision that the control point is using. */ +}qmiLocInformClientRevisionReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocEventRegMaskT_v02; +#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001ull) /**< The control point must enable this mask to receive position report + event indications. */ +#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002ull) /**< The control point must enable this mask to receive satellite report + event indications. These reports are sent at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004ull) /**< The control point must enable this mask to receive NMEA reports for + position and satellites in view. The report is at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008ull) /**< The control point must enable this mask to receive NI notify verify request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010ull) /**< The control point must enable this mask to receive time injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020ull) /**< The control point must enable this mask to receive predicted orbits request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040ull) /**< The control point must enable this mask to receive position injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080ull) /**< The control point must enable this mask to receive engine state report + event indications. */ +#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100ull) /**< The control point must enable this mask to receive fix session status report + event indications. */ +#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200ull) /**< The control point must enable this mask to receive WiFi position request + event indications. */ +#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400ull) /**< The control point must enable this mask to receive notifications from the + GPS engine indicating its readiness to accept data from the + sensors (accelerometer, gyroscope, etc.). */ +#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800ull) /**< The control point must enable this mask to receive time-sync requests + from the GPS engine. Time sync enables the GPS engine to synchronize + its clock with the sensor processor's clock. */ +#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000ull) /**< The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. */ +#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000ull) /**< The control point must enable this mask to receive location server + requests. These requests are generated when the service wishes to + establish a connection with a location server. */ +#define QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00004000ull) /**< The control point must enable this mask to receive notifications + related to network-initiated Geofences. These events notify the client + when a network-initiated Geofence is added, deleted, or edited. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02 ((qmiLocEventRegMaskT_v02)0x00008000ull) /**< The control point must enable this mask to receive Geofence alerts. + These alerts are generated to inform the client of the changes that may + affect Geofence, e.g., if GPS is turned off or if the network is + unavailable. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00010000ull) /**< The control point must enable this mask to receive notifications when + a Geofence is breached. These events are generated when the UE enters + or leaves the perimeter of a Geofence. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to register for events from the + location subsystem. */ +typedef struct { + + /* Mandatory */ + /* Event Registration Mask */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Specifies the events that the control point is interested in receiving. + Refer to the definition of the following bitmasks: + \vspace{0.05in} \begin{itemize1} + \item 0x00000001 -- POSITION_REPORT + \item 0x00000002 -- GNSS_SV_INFO + \item 0x00000004 -- NMEA + \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ + \item 0x00000010 -- INJECT_TIME_REQ + \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ + \item 0x00000040 -- INJECT_POSITION_REQ + \item 0x00000080 -- ENGINE_STATE + \item 0x00000100 -- FIX_SESSION_STATE + \item 0x00000200 -- WIFI_REQ + \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS + \item 0x00000800 -- TIME_SYNC_REQ + \item 0x00001000 -- SET_SPI_STREAMING_REPORT + \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ + \item 0x00004000 -- NI_GEOFENCE_NOTIFICATION + \item 0x00008000 -- GEOFENCE_GEN_ALERT + \item 0x00010000 -- GEOFENCE_BREACH_NOTIFICATION + \end{itemize1} \vspace{0.05in} + Multiple events can be registered by ORing the individual masks and + sending them in this TLV. All unused bits in this mask must be set to 0. + */ +}qmiLocRegEventsReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. */ + eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, /**< Request a single position fix. */ + QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixRecurrenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ + eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. */ + eQMI_LOC_ACCURACY_HIGH_V02 = 3, /**< High accuracy. */ + QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAccuracyLevelEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. */ + eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, /**< Intermediate reports are turned off. */ + QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocIntermediateReportStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; + /**< Application provider. */ + + char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; + /**< Application name. */ + + uint8_t applicationVersion_valid; + /**< Specifies whether the application version string contains + a valid value: \begin{itemize1} + \item 0x00 (FALSE) -- Application version string is invalid + \item 0x01 (TRUE) -- Application version string is valid + \vspace{-0.18in} \end{itemize1} */ + + char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; + /**< Application version. */ +}qmiLocApplicationIdStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to initiate a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session as identified by the control point. The session ID + is reported back in the position reports. The control point must + specify the same session ID in the QMI_LOC_STOP_REQ message. \n + - Range: 0 to 255 + */ + + /* Optional */ + /* Recurrence Type */ + uint8_t fixRecurrence_valid; /**< Must be set to true if fixRecurrence is being passed */ + qmiLocFixRecurrenceEnumT_v02 fixRecurrence; + /**< Specifies the type of session in which the control point is interested. + If this TLV is not specified, recurrence defaults to SINGLE. + + Valid values: \n + - 0x00000001 -- Request periodic fixes \n + - 0x00000002 -- Request a single fix + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Specifies the horizontal accuracy level required by the control point. + If not specified, accuracy defaults to LOW. + + Valid values: \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} + \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable Intermediate Reports */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Specifies if the control point is interested in receiving intermediate + reports. The control point must explicitly set this field to OFF if it + does not wish to receive intermediate position reports. Intermediate + position reports are generated at 1 Hz and are ON by default. If + intermediate reports are turned ON, the client receives position reports + even if the accuracy criteria are not met. The status in such a position + report is set to IN_PROGRESS in order for the control point to identify + intermediate reports. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} + \end{itemize1} + */ + + /* Optional */ + /* Minimum Interval Between Position Reports */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Minimum time interval, specified by the control point, that must elapse between + position reports. \n + - Units: Milliseconds \n + - Default: 1000 ms + */ + + /* Optional */ + /* ID of the Application that Sent this Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version.*/ +}qmiLocStartReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to stop a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + (QMI_LOC_START_REQ).\n + - Range: 0 to 255 */ +}qmiLocStopReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPosTechMaskT_v02; +#define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION_V02 ((qmiLocPosTechMaskT_v02)0x00000020) /**< Coarse position injected into the location engine was used to + generate the fix. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSESSIONSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SESS_STATUS_SUCCESS_V02 = 0, /**< Session was successful. */ + eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 = 1, /**< Session still in progress. Further position reports will be + generated until either the fix criteria specified by the client + are met or the client response timeout occurs. */ + eQMI_LOC_SESS_STATUS_GENERAL_FAILURE_V02 = 2, /**< Session failed. */ + eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ + eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ + eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ + eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. */ + eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, /**< Fix request failed because the engine is locked. */ + QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSessionStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gpsWeek; + /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n + - Units: Weeks */ + + uint32_t gpsTimeOfWeekMs; + /**< Amount of time into the current GPS week. \n + - Units: Milliseconds */ +}qmiLocGPSTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + float PDOP; + /**< Position dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \item PDOP = square root of (HDOP^2 + VDOP^2) + \vspace{-0.18in} \end{itemize1} */ + + float HDOP; + /**< Horizontal dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ + + float VDOP; + /**< Vertical dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ +}qmiLocDOPStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocSensorUsageMaskT_v02; +#define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ +#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyroscope was used. */ +typedef uint32_t qmiLocSensorAidedMaskT_v02; +#define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ +#define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ +#define QMI_LOC_SENSOR_AIDED_MASK_POSITION_V02 ((qmiLocSensorAidedMaskT_v02)0x00000004) /**< Bitmask to specify whether a sensor was used to calculate position. */ +#define QMI_LOC_SENSOR_AIDED_MASK_VELOCITY_V02 ((qmiLocSensorAidedMaskT_v02)0x00000008) /**< Bitmask to specify whether a sensor was used to calculate velocity. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSensorUsageMaskT_v02 usageMask; + /**< Specifies which sensors were used in calculating the position in the + position report. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SENSOR_USED_ACCEL + \item 0x00000002 -- SENSOR_USED_GYRO + \vspace{-0.18in} \end{itemize1} */ + + qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; + /**< Specifies which results were aided by sensors. + + Valid bitmasks: \n + - 0x00000001 -- AIDED_HEADING \n + - 0x00000002 -- AIDED_SPEED \n + - 0x00000004 -- AIDED_POSITION \n + - 0x00000008 -- AIDED_VELOCITY */ +}qmiLocSensorUsageIndicatorStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCTIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_TIME_SRC_INVALID_V02 = 0, /**< Invalid time. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER_V02 = 1, /**< Time is set by the 1x system. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING_V02 = 2, /**< Time is set by WCDMA/GSM time tagging (i.e., + associating network time with GPS time). */ + eQMI_LOC_TIME_SRC_EXTERNAL_INPUT_V02 = 3, /**< Time is set by an external injection. */ + eQMI_LOC_TIME_SRC_TOW_DECODE_V02 = 4, /**< Time is set after decoding over-the-air GPS navigation data + from one GPS satellite. */ + eQMI_LOC_TIME_SRC_TOW_CONFIRMED_V02 = 5, /**< Time is set after decoding over-the-air GPS navigation data + from multiple satellites. */ + eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED_V02 = 6, /**< Both time of the week and the GPS week number are known. */ + eQMI_LOC_TIME_SRC_NAV_SOLUTION_V02 = 7, /**< Time is set by the position engine after the fix is obtained. */ + eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME_V02 = 8, /**< Time is set by the position engine after performing SFT. + This is done when the clock time uncertainty is large. */ + eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ + eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ + eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ + eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network */ + eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, /**< Source of the time is unknown */ + QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocTimeSourceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCRELIABILITYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ + eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ + eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ + eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed */ + eQMI_LOC_RELIABILITY_HIGH_V02 = 4, /**< Location reliability is high; strong cross-check passed */ + QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocReliabilityEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the position report to the control point. */ +typedef struct { + + /* Mandatory */ + /* Session Status */ + qmiLocSessionStatusEnumT_v02 sessionStatus; + /**< Session status. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SESS_STATUS_SUCCESS + \item 0x00000001 -- SESS_STATUS_IN_PROGRESS + \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE + \item 0x00000003 -- SESS_STATUS_TIMEOUT + \item 0x00000004 -- SESS_STATUS_USER_END + \item 0x00000005 -- SESS_STATUS_BAD_PARAMETER + \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE + \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + QMI_LOC_START_REQ. \n + - Range: 0 to 255 */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Elliptical Horizontal Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal uncertainty confidence.\n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. \n + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Units: Meters/second */ + + /* Optional */ + /* Speed Uncertainty */ + uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ + float speedUnc; + /**< 3-D Speed uncertainty.\n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence.\n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. \n + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Vertical Speed */ + uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ + float speedVertical; + /**< Vertical speed.\n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. */ + + /* Optional */ + /* Technology Used */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + /**< \n Dilution of precision associated with this position. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Units: Milliseconds since Jan. 1, 1970 */ + + /* Optional */ + /* Leap Seconds */ + uint8_t leapSeconds_valid; /**< Must be set to true if leapSeconds is being passed */ + uint8_t leapSeconds; + /**< Leap second information. If leapSeconds is not available, + timestampUtc is calculated based on a hard-coded value + for leap seconds. \n + - Units: Seconds */ + + /* Optional */ + /* GPS Time */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + /**< \n The number of weeks since Jan. 5, 1980, and + milliseconds into the current week. */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Units: Milliseconds */ + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. + + Valid values: \begin{itemize1} + \item 0x00000000 -- TIME_SRC_INVALID + \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER + \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING + \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT + \item 0x00000004 -- TIME_SRC_TOW_DECODE + \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED + \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED + \item 0x00000007 -- TIME_SRC_NAV_SOLUTION + \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + /**< \n Whether sensor data was used in computing the position in this + position report. */ + + /* Optional */ + /* Fix Count for This Session */ + uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ + uint32_t fixId; + /**< Fix count for the session. Starts with 0 and increments by one + for each successive position report for a particular session. */ + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ +}qmiLocEventPositionReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSYSTEMENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ + eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ + eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ + eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. */ + eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, /**< GLONASS satellite. */ + QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvSystemEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ + eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. */ + eQMI_LOC_SV_STATUS_TRACK_V02 = 3, /**< SV is being tracked. */ + QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvStatusEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocSvInfoValidMaskT_v02; +#define QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000001) /**< System field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000002) /**< gnssSvId field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_HEALTH_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000004) /**< healthStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000008) /**< processStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000010) /**< svInfoMask field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000020) /**< Elevation field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000040) /**< Azimuth field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000080) /**< SNR field is valid in SV information. */ +typedef uint8_t qmiLocSvInfoMaskT_v02; +#define QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02 ((qmiLocSvInfoMaskT_v02)0x01) /**< Ephemeris is available for this SV. */ +#define QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02 ((qmiLocSvInfoMaskT_v02)0x02) /**< Almanac is available for this SV. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSvInfoValidMaskT_v02 validMask; + /**< Bitmask indicating which of the fields in this TLV are valid. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- VALID_SYSTEM + \item 0x00000002 -- VALID_GNSS_SVID + \item 0x00000004 -- VALID_HEALTH_STATUS + \item 0x00000008 -- VALID_PROCESS_STATUS + \item 0x00000010 -- VALID_SVINFO_MASK + \item 0x00000020 -- VALID_ELEVATION + \item 0x00000040 -- VALID_AZIMUTH + \item 0x00000080 -- VALID_SNR + \vspace{-0.18in} \end{itemize1} */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + + Valid values: \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} */ + + uint16_t gnssSvId; + /**< GNSS SV ID. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For GLONASS: 1 to 32 + \item For SBAS: 120 to 151 + \end{itemize1} \end{itemize1} + + The GPS and GLONASS SVs can be disambiguated using the system field. */ + + uint8_t healthStatus; + /**< Health status. + \begin{itemize1} + \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy + \vspace{-0.18in} \end{itemize1}*/ + + qmiLocSvStatusEnumT_v02 svStatus; + /**< SV processing status. \n + Valid values:\n + - 0x00000001 -- SV_STATUS_IDLE \n + - 0x00000002 -- SV_STATUS_SEARCH \n + - 0x00000003 -- SV_STATUS_TRACK + */ + + qmiLocSvInfoMaskT_v02 svInfoMask; + /**< Whether almanac and ephemeris information is available. \n + Valid bitmasks: \n + - 0x01 -- SVINFO_HAS_EPHEMERIS \n + - 0x02 -- SVINFO_HAS_ALMANAC + */ + + float elevation; + /**< SV elevation angle.\n + - Units: Degrees \n + - Range: 0 to 90 */ + + float azimuth; + /**< SV azimuth angle.\n + - Units: Degrees \n + - Range: 0 to 360 */ + + float snr; + /**< SV signal-to-noise ratio. \n + - Units: dB-Hz */ +}qmiLocSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends a satellite report to the control point. */ +typedef struct { + + /* Mandatory */ + /* Altitude Source */ + uint8_t altitudeAssumed; + /**< Whether altitude is assumed or calculated: \begin{itemize1} + \item 0x00 (FALSE) -- Valid altitude is calculated + \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be + enough satellites to determine precise altitude + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Satellite Info */ + uint8_t svList_valid; /**< Must be set to true if svList is being passed */ + uint32_t svList_len; /**< Must be set to # of elements in svList */ + qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; + /**< \n SV information list. */ +}qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends NMEA sentences to the control point */ +typedef struct { + + /* Mandatory */ + /* NMEA String */ + char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; + /**< NMEA string. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 201 + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocEventNmeaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNINOTIFYVERIFYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, /**< Notify and Verify, and require a response. */ + QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiNotifyVerifyEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ + eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ + eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. */ + eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, /**< MS-based preferred, but MS-assisted allowed. */ + QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxPosModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_OCTET_V02 = 0, /**< Encoding is OCTET. */ + eQMI_LOC_NI_VX_EXN_PROTOCOL_MSG_V02 = 1, /**< Encoding is EXN PROTOCOL MSG. */ + eQMI_LOC_NI_VX_ASCII_V02 = 2, /**< Encoding is ASCII. */ + eQMI_LOC_NI_VX_IA5_V02 = 3, /**< Encoding is IA5. */ + eQMI_LOC_NI_VX_UNICODE_V02 = 4, /**< Encoding is UNICODE. */ + eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ + eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ + eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ + eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. */ + eQMI_LOC_NI_VX_GSM_V02 = 9, /**< Encoding is GSM. */ + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t posQosIncl; + /**< Whether quality of service is included:\n + - 0x01 (TRUE) -- QoS is included \n + - 0x00 (FALSE) -- QoS is not included */ + + uint8_t posQos; + /**< Position QoS timeout. \n + - Units: Seconds \n + - Range: 0 to 255 */ + + uint32_t numFixes; + /**< Number of fixes allowed. */ + + uint32_t timeBetweenFixes; + /**< Time between fixes.\n + - Units: Seconds */ + + qmiLocNiVxPosModeEnumT_v02 posMode; + /**< Position mode. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY + \item 0x00000002 -- NI_VX_MS_BASED_ONLY + \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED + \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; + /**< VX encoding scheme. + + Valid values: \begin{itemize1} + \item 0x00000000 -- NI_VX_OCTET + \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG + \item 0x00000002 -- NI_VX_ASCII + \item 0x00000003 -- NI_VX_IA5 + \item 0x00000004 -- NI_VX_UNICODE + \item 0x00000005 -- NI_VX_SHIFT_JIS + \item 0x00000006 -- NI_VX_KOREAN + \item 0x00000007 -- NI_VX_LATIN_HEBREW + \item 0x00000008 -- NI_VX_LATIN + \item 0x00000009 -- NI_VX_GSM + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ + uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; + /**< Requestor ID. \n + - Type: Array of bytes \n + - Maximum array length: 200 + */ + + uint16_t userRespTimerInSeconds; + /**< Time to wait for the user to respond. \n + - Units: Seconds */ +}qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLPOSMETHODENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_V02 = 1, /**< Set assisted. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_V02 = 2, /**< Set based. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_PREF_V02 = 3, /**< Set assisted preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_PREF_V02 = 4, /**< Set based preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AUTONOMOUS_GPS_V02 = 5, /**< Standalone GPS. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ + eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ + eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ + eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. */ + eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, /**< No position. */ + QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplPosMethodEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIDATACODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SS_GERMAN_V02 = 12, /**< Language is German. */ + eQMI_LOC_NI_SS_ENGLISH_V02 = 13, /**< Language is English. */ + eQMI_LOC_NI_SS_ITALIAN_V02 = 14, /**< Language is Italian. */ + eQMI_LOC_NI_SS_FRENCH_V02 = 15, /**< Language is French. */ + eQMI_LOC_NI_SS_SPANISH_V02 = 16, /**< Language is Spanish. */ + eQMI_LOC_NI_SS_DUTCH_V02 = 17, /**< Language is Dutch. */ + eQMI_LOC_NI_SS_SWEDISH_V02 = 18, /**< Language is Swedish. */ + eQMI_LOC_NI_SS_DANISH_V02 = 19, /**< Language is Danish. */ + eQMI_LOC_NI_SS_PORTUGUESE_V02 = 20, /**< Language is Portuguese. */ + eQMI_LOC_NI_SS_FINNISH_V02 = 21, /**< Language is Finnish. */ + eQMI_LOC_NI_SS_NORWEGIAN_V02 = 22, /**< Language is Norwegian. */ + eQMI_LOC_NI_SS_GREEK_V02 = 23, /**< Language is Greek. */ + eQMI_LOC_NI_SS_TURKISH_V02 = 24, /**< Language is Turkish. */ + eQMI_LOC_NI_SS_HUNGARIAN_V02 = 25, /**< Language is Hungarian. */ + eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ + eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ + eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ + eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. */ + eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, /**< Encoding is GSM default. */ + QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiDataCodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLFORMATENUMTYPE_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_FORMAT_LOGICAL_NAME_V02 = 0, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_EMAIL_ADDRESS_V02 = 1, /**< SUPL email address format. */ + eQMI_LOC_NI_SUPL_FORMAT_MSISDN_V02 = 2, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_URL_V02 = 3, /**< SUPL URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ + eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ + eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity */ + eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, /**< SUPL unknown format. */ + QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplFormatEnumType_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplFormatEnumType_v02 formatType; + /**< Format of the formatted string. + + Valid values: \begin{itemize1} + \item 0x00000000 -- FORMAT_LOGICAL_NAME + \item 0x00000001 -- FORMAT_EMAIL_ADDRESS + \item 0x00000002 -- FORMAT_MSISDN + \item 0x00000003 -- FORMAT_URL + \item 0x00000004 -- FORMAT_SIP_URL + \item 0x00000005 -- FORMAT_MIN + \item 0x00000006 -- FORMAT_MDN + \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY + \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ + uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Formatted string. \n + - Type: Byte array \n + - Maximum string length: 64 + */ +}qmiLocNiSuplFormattedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocSuplQopValidMaskT_v02; +#define QMI_LOC_NI_SUPL_MASK_QOP_HORZ_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x01) /**< Horizontal accuracy is valid in the Quality of Position (QoP). */ +#define QMI_LOC_NI_SUPL_MASK_QOP_VER_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x02) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_MAXAGE_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x04) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_DELAY_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x08) /**< Vertical accuracy is valid in the QoP. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSuplQopValidMaskT_v02 validMask; + /**< Bit field indicating which fields are valid in this value. + + Valid bitmasks: \n + - 0x01 -- QOP_HORZ_ACC_VALID \n + - 0x02 -- QOP_VER_ACC_VALID \n + - 0x04 -- QOP_MAXAGE_VALID \n + - 0x08 -- QOP_DELAY_VALID*/ + + uint8_t horizontalAccuracy; + /**< Horizontal accuracy. \n + - Units: Meters */ + + uint8_t verticalAccuracy; + /**< Vertical accuracy. \n + - Units: Meters */ + + uint16_t maxLocAge; + /**< Maximum age of the location if the engine sends a previously + computed position. \n + - Units: Seconds */ + + uint8_t delay; + /**< Delay the server is willing to tolerate for the fix. \n + - Units: Seconds */ +}qmiLocNiSuplQopStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocServerAddrTypeMaskT_v02; +#define QMI_LOC_SERVER_ADDR_TYPE_IPV4_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x01) /**< IPV4 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_IPV6_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x02) /**< IPV6 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_URL_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x04) /**< URL server address type. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t addr; + /**< IPV4 address. */ + + uint16_t port; + /**< IPV4 port. */ +}qmiLocIpV4AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; + /**< IPV6 address. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 8 */ + + uint32_t port; + /**< IPV6 port. */ +}qmiLocIpV6AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerAddrTypeMaskT_v02 suplServerAddrTypeMask; + /**< Mask specifying the valid fields in this value. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ + + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< IPV4 address and port. */ + + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< IPV6 address and port. */ + + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiSuplServerInfoStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocNiSuplNotifyVerifyValidMaskT_v02; +#define QMI_LOC_SUPL_SERVER_INFO_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000001) /**< Mask to denote that the server information + is present in an NI SUPL notify verify request event. This mask is set in + the valid_flags field of a notify verify structure. */ +#define QMI_LOC_SUPL_SESSION_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000002) /**< Mask to denote that the SUPL session ID + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_HASH_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000004) /**< Mask to denote that the SUPL hash is present + in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_POS_METHOD_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000008) /**< Mask to denote that the position method is present + in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000010) /**< Mask to denote that the data coding scheme + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_CLIENT_NAME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000040) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_QOP_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000080) /**< Mask to denote that the quality of position + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_USER_RESP_TIMER_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; + /**< Indicates which of the following fields are present in this value. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SUPL_SERVER_INFO + \item 0x00000002 -- SUPL_SESSION_ID + \item 0x00000004 -- SUPL_HASH + \item 0x00000008 -- SUPL_POS_METHOD + \item 0x00000010 -- SUPL_DATA_CODING_SCHEME + \item 0x00000020 -- SUPL_REQUESTOR_ID + \item 0x00000040 -- SUPL_CLIENT_NAME + \item 0x00000080 -- SUPL_QOP + \item 0x00000100 -- SUPL_USER_RESP_TIMER + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; + /**< SUPL server information. */ + + uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; + /**< SUPL session ID. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 4 */ + + uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; + /**< Hash for SUPL_INIT; used to validate that the message was not + corrupted. \n + - Type: Array of unsigned integers \n + - Length of the array: 8 */ + + qmiLocNiSuplPosMethodEnumT_v02 posMethod; + /**< GPS mode to be used for the fix. + + Valid values: \begin{itemize1} + \item 0x00000001 -- AGPS_SETASSISTED + \item 0x00000002 -- AGPS_SETBASED + \item 0x00000003 -- AGPS_SETASSISTED_PREF + \item 0x00000004 -- AGPS_SETBASED_PREF + \item 0x00000005 -- AUTONOMOUS_GPS + \item 0x00000006 -- AFLT + \item 0x00000007 -- ECID + \item 0x00000008 -- EOTD + \item 0x00000009 -- OTDOA + \item 0x0000000A -- NO_POSITION + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Data coding scheme applies to both the requestor ID and the client + name. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplFormattedStringStructT_v02 requestorId; + /**< Requestor ID. The encoding scheme for requestor_id is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplFormattedStringStructT_v02 clientName; + /**< Client name. The encoding scheme for client_name is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplQopStructT_v02 suplQop; + /**< SUPL QoP. */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Units: Seconds*/ +}qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. */ + eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, /**< Initial location. */ + QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiLocationTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Identifies the coding scheme of the coded string. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + + */ + + uint32_t codedString_len; /**< Must be set to # of elements in codedString */ + uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; + /**< Coded string. \n + - Type: Array of bytes \n + - Maximum string length: 20 */ +}qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint16_t qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02; +#define QMI_LOC_UMTS_CP_INVOKE_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0001) /**< Mask to denote that the invoke ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0002) /**< Mask to denote that the data coding scheme + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_NOTIFICATION_TEXT_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0004) /**< Mask to denote that the notification text + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CLIENT_ADDRESS_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0008) /**< Mask to denote that the client address + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_LOCATION_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0010) /**< Mask to denote that the location type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_REQUESTOR_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CODEWORD_STRING_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0040) /**< Mask to denote that the code word string + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_SERVICE_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0080) /**< Mask to denote that the service type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_USER_RESP_TIMER_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; + /**< Fields that are valid in this value. + + Valid bitmasks: \begin{itemize1} + \item 0x0001 -- INVOKE_ID_MASK + \item 0x0002 -- DATA_CODING_SCHEME_MASK + \item 0x0004 -- NOTIFICATION_TEXT_MASK + \item 0x0008 -- CLIENT_ADDRESS_MASK + \item 0x0010 -- LOCATION_TYPE_MASK + \item 0x0020 -- REQUESTOR_ID_MASK + \item 0x0040 -- CODEWORD_STRING_MASK + \item 0x0080 -- SERVICE_TYPE_MASK + \item 0x0100 -- USER_RESP_TIMER_MASK + \vspace{-0.18in} \end{itemize1} + */ + + uint8_t invokeId; + /**< Supplementary Services invoke ID. */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Type of data encoding scheme for the text. + Applies to both the notification text and the client address. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ + uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Notification text; the encoding method is specified in + dataCodingScheme. \n + - Type: Array of bytes \n + - Maximum array length: 64 */ + + uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ + uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; + /**< Client address; the encoding method is specified in + dataCodingScheme. \n + - Maximum array length: 20 */ + + qmiLocNiLocationTypeEnumT_v02 locationType; + /**< Location type. + + Valid values: \begin{itemize1} + \item 0x00000001 -- CURRENT_LOCATION + \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION + \item 0x00000004 -- INITIAL_LOCATION + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; + /**< Requestor ID; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; + /**< Codeword string; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + uint8_t lcsServiceTypeId; + /**< Service type ID. */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Units: Seconds */ +}qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISERVICEINTERACTIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO_V02 = 1, /**< Service interaction between ongoing NI and incoming MO sessions. */ + QMILOCNISERVICEINTERACTIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiServiceInteractionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; + /**< Ongoing NI session request; this information is currently not filled. */ + + qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; + /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ONGOING_NI_INCOMING_MO + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiVxServiceInteractionStructT_v02; /* Type */ +/** + @} + */ + +typedef uint16_t qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WLAN_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0001) /**< Denotes that WLAN measurements are allowed as part of location ID + and multiple location IDs in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_GSM_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0002) /**< Denotes that GSM measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WCDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0004) /**< Denotes that WCDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_CDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0008) /**< Denotes that CDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HRDP_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0010) /**< Denotes that HRDP measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_UMB_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0020) /**< Denotes that UMB measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_LTE_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0040) /**< Denotes that LTE measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WIMAX_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0080) /**< Denotes that WIMAX measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HISTORIC_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0100) /**< Denotes that historical information is allowed as part of + multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_NONSVRV_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0200) /**< Denotes that information about nonserving cells is allowed + as part of multiple location ID in the SUPL_POS_INIT message. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, /**< The SUPL INIT message indicates a request for an area event + triggered session. */ + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; +/** + @} + */ + +typedef uint16_t qmiLocNiSuplVer2ExtGnssTypeMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0001) /**< GPS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GLONASS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0002) /**< GLONASS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GALILEO_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0004) /**< Galileo is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_SBAS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0008) /**< SBAS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_QZSS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0010) /**< QZSS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_MODERN_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0020) /**< Modern GPS is allowed to be used as the positioning technology. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02 supportedNetworksMask; + /**< Specifies which type of network measurements are allowed to be sent as + part of the Location ID or Multiple Location IDs parameter in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid bitmasks: \begin{itemize1} + \item 0x0001 -- SUPPORTED_NETWORK_WLAN + \item 0x0002 -- SUPPORTED_NETWORK_GSM + \item 0x0004 -- SUPPORTED_NETWORK_WCDMA + \item 0x0008 -- SUPPORTED_NETWORK_CDMA + \item 0x0010 -- SUPPORTED_NETWORK_HRDP + \item 0x0020 -- SUPPORTED_NETWORK_UMB + \item 0x0040 -- SUPPORTED_NETWORK_LTE + \item 0x0080 -- SUPPORTED_NETWORK_WIMAX + \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC + \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; + /**< Specifies the type of session trigger requested in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid values: \begin{itemize1} + \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT + \item 0x00000000 -- TRIGGER_TYPE_PERIODIC + \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT + \vspace{-0.18in} \end{itemize1} */ + + qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; + /**< Specifies which GNSS technologies are allowed as positioning + technologies. + + Valid bitmasks: \n + - 0x0001 -- GNSS_GPS \n + - 0x0002 -- GNSS_GLONASS \n + - 0x0004 -- GNSS_GALILEO \n + - 0x0008 -- GNSS_SBAS \n + - 0x0010 -- GNSS_QZSS \n + - 0x0020 -- GNSS_MODERN_GPS + */ +}qmiLocNiSuplVer2ExtStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Indicates an NI notify/verify request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIFY + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; + /**< \n Optional NI Vx request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; + /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtInd_valid; /**< Must be set to true if NiSuplVer2ExtInd is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; + /**< \n Optional NI SUPL Version 2 Extension payload. When present, + this payload is to be used in conjunction with the SUPL + indication payload. */ +}qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< Assistance server URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocAssistanceServerUrlStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t delayThreshold; + /**< The time server is to be skipped if a one-way delay to the server + exceeds this threshold. \n + - Units: Milliseconds */ + + uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ + qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; + /**< List of Time Server URL's that are recommended by the service for time + information, the list is ordered, the client is to use the first + server specified in the list as the primary URL to fetch NTP time, + the second one as secondary, and so on. \n + - Maximum server list items: 3 */ +}qmiLocTimeServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject time information. */ +typedef struct { + + /* Optional */ + /* Time Server Info */ + uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ + qmiLocTimeServerListStructT_v02 timeServerInfo; + /**< \n Contains information about the time servers recommended by the + location service for NTP time. */ +}qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t maxFileSizeInBytes; + /**< Maximum allowable predicted orbits file size (in bytes). */ + + uint32_t maxPartSize; + /**< Maximum allowable predicted orbits file chunk size (in bytes). */ +}qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t serverList_len; /**< Must be set to # of elements in serverList */ + qmiLocAssistanceServerUrlStructT_v02 serverList[QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02]; + /**< List of predicted orbits URLs. The list is ordered, so the client + must use the first server specified in the list as the primary URL + from which to download predicted orbits data, the second one as + secondary, and so on. \n + - Maximum number of servers that can be specified: 3 */ +}qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Allowed Sizes */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject a position. */ +typedef struct { + + /* Mandatory */ + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Mandatory */ + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Mandatory */ + /* Circular Horizontal Uncertainty */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Mandatory */ + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. */ + eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, /**< Location engine is off. */ + QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocEngineStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the engine state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Engine State */ + qmiLocEngineStateEnumT_v02 engineState; + /**< Location engine state. + + Valid values: \n + - 0x00000001 -- ON \n + - 0x00000002 -- OFF + */ +}qmiLocEventEngineStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. */ + eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, /**< Location fix session has ended. */ + QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixSessionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the fix session state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Session State */ + qmiLocFixSessionStateEnumT_v02 sessionState; + /**< LOC fix session state. + + Valid values: \n + - 0x00000001 -- STARTED \n + - 0x00000002 -- FINISHED + */ + + /* Optional */ + /* Session ID */ + uint8_t sessionId_valid; /**< Must be set to true if sessionId is being passed */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request. + This may not be specified for a fix session corresponding to + a network-initiated request. \n + - Range: 0 to 255 */ +}qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ + eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. */ + eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, /**< Stop periodic fixes request. */ + QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends a WiFi request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Request Type */ + qmiLocWifiRequestEnumT_v02 requestType; + /**< Request type as specified in qmiWifiRequestEnumT. + + Valid values: \begin{itemize1} + \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES + \item 0x00000001 -- START_PERIODIC_KEEP_WARM + \item 0x00000002 -- STOP_PERIODIC_FIXES + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Time Between Fixes */ + uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ + uint16_t tbfInMs; + /**< Time between fixes for a periodic request.\n + - Units: Milliseconds */ +}qmiLocEventWifiReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t samplesPerBatch; + /**< Specifies the number of samples per batch the GNSS location engine is to + receive. The sensor sampling frequency can be computed as follows: \n + + samplingFrequency = samplesPerBatch * batchesPerSecond \n + + samplesPerBatch must be a nonzero positive value. + */ + + uint16_t batchesPerSecond; + /**< Number of sensor-data batches the GNSS location engine is to receive + per second. The rate is specified in an integral number of batches per + second (Hz). \n + + batchesPerSecond must be a nonzero positive value. + */ +}qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t injectEnable; + /**< Whether the GNSS location engine is ready to accept data from this + sensor. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor + data + \item 0x00 (FALSE) -- GNSS location engine is not ready to accept + sensor data + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; + /**< Rate at which the GNSS engine would like the sensor to be sampled. \n + The rate is specified in integral number of samples per second (Hz)\n + and batches per second. + */ +}qmiLocSensorReadyStatusStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point if the GNSS location engine is + ready to accept sensor data. */ +typedef struct { + + /* Optional */ + /* Accelerometer Accept Ready */ + uint8_t accelReady_valid; /**< Must be set to true if accelReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 accelReady; + /**< \n Whether the GNSS location engine is ready to accept accelerometer + sensor data. + */ + + /* Optional */ + /* Gyroscope Accept Ready */ + uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 gyroReady; + /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor + data. + */ +}qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point to inject time synchronization + data. */ +typedef struct { + + /* Mandatory */ + /* Opaque Time Sync Reference Counter */ + uint32_t refCounter; + /**< This TLV is sent to registered control points. It is sent by + the location engine when it needs to synchronize location engine and + control point (sensor processor) times. + This TLV must be echoed back in the Time Sync Inject request. */ +}qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to enable Stationary Position + Indicator (SPI) streaming reports. */ +typedef struct { + + /* Mandatory */ + /* Enable/Disable SPI Requests */ + uint8_t enable; + /**< Whether the client is to start or stop sending an SPI status stream. + \begin{itemize1} + \item 0x01 (TRUE) -- Client is to start sending an SPI status stream + \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. */ + eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, /**< Bring up the WWAN type used for AGNSS connections. */ + QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWWANTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. */ + eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, /**< Close a connection to the location server. */ + QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the client to open or close a connection + to the assisted GPS location server. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Identifies a connection across Open and Close request events. */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Open or close a connection to the location server. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* WWAN Type */ + qmiLocWWANTypeEnumT_v02 wwanType; + /**< Identifies the WWAN type for this request. \n + + Valid values: \begin{itemize1} + \item 0x00000000 -- WWAN_TYPE_INTERNET + \item 0x00000001 -- WWAN_TYPE_AGNSS + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ + eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. */ + eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, /**< An NI Geofence was edited. The control point can query the + Geofence to find the its current state. */ + QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiGeofenceOperationEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Informs the control point about + network-initiated Geofences. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Operation Type */ + qmiLocNiGeofenceOperationEnumT_v02 operationType; + /**< Operation for which this notification was generated. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NI_GEOFENCE_ADDED + \item 0x00000002 -- NI_GEOFENCE_DELETED + \item 0x00000003 -- NI_GEOFENCE_EDITED + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEGENALERTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE_V02 = 1, /**< GNSS is unavailable and GNSS position fixes + cannot be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can + be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage + information is available. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, /**< The engine has an invalid time. */ + QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceGenAlertEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of the + Geofence status. */ +typedef struct { + + /* Mandatory */ + /* Geofence General Alert */ + qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; + /**< Specifies the Geofence general alert type. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE + \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE + \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS + \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. */ + eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, /**< Denotes that a client left the Geofence. */ + QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceBreachTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Elliptical Horizontal Uncertainty Azimuth */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Horizontal Speed validity bit */ + uint8_t speedHorizontal_valid; + /**< Indicates whether the Horizontal speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Horizontal speed is valid + \item 0x00 (FALSE) -- Horizontal speed is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Horizontal Speed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Units: Meters/second */ + + /* Altitude validity bit */ + uint8_t altitudeWrtEllipsoid_valid; + /**< Indicates whether the altitude field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Altitude field is valid + \item 0x00 (FALSE) -- Altitude field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} + */ + + /* Altitude With Respect to Ellipsoid */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Vertical Uncertainty validity bit */ + uint8_t vertUnc_valid; + /**< Indicates whether the Vertical Uncertainty field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Uncertainty field is valid + \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Uncertainty */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Vertical Speed validity bit */ + uint8_t speedVertical_valid; + /**< Indicates whether the Vertical Speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Speed field is valid + \item 0x00 (FALSE) -- Vertical Speed field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Speed */ + float speedVertical; + /**< Vertical speed.\n + - Units: Meters/second */ + + /* heading validity bit */ + uint8_t heading_valid; + /**< Indicates whether the Heading field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Heading field is valid + \item 0x00 (FALSE) -- Heading field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Heading */ + float heading; + /**< Heading.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ +}qmiLocGeofencePositionStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of + a Geofence breach event. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Geofence Breach Type */ + qmiLocGeofenceBreachTypeEnumT_v02 breachType; + /**< The type of breach that generated this event. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING + \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Geofence Position */ + uint8_t geofencePosition_valid; /**< Must be set to true if geofencePosition is being passed */ + qmiLocGeofencePositionStructT_v02 geofencePosition; + /**< \n Position of the client when it breached the Geofence. + This TLV is included if the client configures the + Geofence to report position. The position is reported + at the same confidence level that was specified in the + Add Circular Geofence request. */ +}qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ + eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ + eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is not supported. */ + eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ + eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ + eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ + eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ + eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested */ + eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, /**< Request failed because the engine could not allocate sufficent + memory for the request. */ + QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocStatusEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * typedef struct { + * }qmiLocGetServiceRevisionReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Client can query the service revision using this message. */ +typedef struct { + + /* Mandatory */ + /* Get Revision Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Revision request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Interface Definition Minor Revision */ + uint32_t revision; + /**< Revision of the service. This is the minor revision of the interface that + the service implements. Minor revision updates of the service are always + backward compatible. */ + + /* Optional */ + /* GNSS Measurement Engine Firmware Version String */ + uint8_t gnssMeFWVerString_valid; /**< Must be set to true if gnssMeFWVerString is being passed */ + char gnssMeFWVerString[QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS measurement engine software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in} \end{itemize1} + + \textbf{Note:} This string is only provided on platforms that have + a measurement engine that supports this version string. On all other + platforms, this optional TLV is not provided. */ + + /* Optional */ + /* GNSS Hosted Software Version String */ + uint8_t gnssHostSWVerString_valid; /**< Must be set to true if gnssHostSWVerString is being passed */ + char gnssHostSWVerString[QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS hosted software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in}\end{itemize1} + + \textbf{Note:} This string is only provided on hosted architectures + (measurement and position engine running on different processors) that + support this version string. On all other platforms, this optional TLV + is not provided. */ + + /* Optional */ + /* GNSS Software Version String */ + uint8_t gnssSWVerString_valid; /**< Must be set to true if gnssSWVerString is being passed */ + char gnssSWVerString[QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Aggregate version of the GNSS software. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * typedef struct { + * }qmiLocGetFixCriteriaReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the fix criteria from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Fix Criteria Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Fix Criteria request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Horizontal accuracy level. + + Valid values: \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable Intermediate Fixes */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Intermediate Report state (ON, OFF).\n + The client must explicitly set this field to OFF to stop receiving + intermediate position reports. Intermediate position reports are + generated at \n 1 Hz and are ON by default. If intermediate reports + are turned ON, the client receives position reports even if the + accuracy criteria is not met. The status in the position report is + set to IN_PROGRESS for intermediate reports. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Minimum Interval Between Fixes */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Time that must elapse before alerting the client. \n + - Units: Milliseconds */ + + /* Optional */ + /* ID of the Application that Sent the Position Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version.*/ +}qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, /**< User did not respond to notify verify request. */ + QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiUserRespEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* User Response */ + qmiLocNiUserRespEnumT_v02 userResp; + /**< User accepted or denied. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT + \item 0x00000002 -- NOTIFY_VERIFY_DENY + \item 0x00000003 -- NOTIFY_VERIFY_NORESP + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIF + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; + /**< \n Optional NI VX request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; + /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; + /**< \n Optional SUPL Version 2 Extension payload. */ +}qmiLocNiUserRespReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* NI User Response Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the NI User Response request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiUserRespIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_PREDICTED_ORBITS_XTRA_V02 = 0, /**< Default is QCOM-XTRA format. */ + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPredictedOrbitsDataFormatEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Total Size */ + uint32_t totalSize; + /**< Total size of the predicted orbits data to be injected. \n + - Units: Bytes */ + + /* Mandatory */ + /* Total Parts */ + uint16_t totalParts; + /**< Total number of parts into which the predicted orbits data is + divided. */ + + /* Mandatory */ + /* Part Number */ + uint16_t partNum; + /**< Number of the current predicted orbits data part; starts at 1. */ + + /* Mandatory */ + /* Data */ + uint32_t partData_len; /**< Must be set to # of elements in partData */ + char partData[QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02]; + /**< Predicted orbits data. \n + - Type: Array of bytes \n + - Maximum length of the array: 1024 + */ + + /* Optional */ + /* Format Type */ + uint8_t formatType_valid; /**< Must be set to true if formatType is being passed */ + qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; + /**< Predicted orbits data format. + + Valid values: \begin{itemize1} + \item 0x00000000 -- PREDICTED_ORBITS_XTRA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Data Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Data Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Part Number */ + uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ + uint16_t partNum; + /**< Number of the predicted orbits data part for which this indication + is sent; starts at 1. */ +}qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataSourceReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data source. */ +typedef struct { + + /* Mandatory */ + /* Predicted Orbits Data Source Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for a predicted orbits data source. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Allowed Sizes */ + uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataValidityReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint64_t startTimeInUTC; + /**< Predicted orbits data is valid starting from this time. \n + - Units: Seconds (since Jan. 1, 1970) + */ + + uint16_t durationHours; + /**< Duration from the start time for which the data is valid.\n + - Units: Hours + */ +}qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data validity. */ +typedef struct { + + /* Mandatory */ + /* Predicted Orbits Data Validity Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for predicted orbits data validity. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Validity Info */ + uint8_t validityInfo_valid; /**< Must be set to true if validityInfo is being passed */ + qmiLocPredictedOrbitsDataValidityStructT_v02 validityInfo; +}qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time */ + uint64_t timeUtc; + /**< UTC time since Jan. 1, 1970.\n + - Units: Milliseconds */ + + /* Mandatory */ + /* Time Uncertainty */ + uint32_t timeUnc; + /**< Time uncertainty.\n + - Units: Milliseconds */ +}qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Time Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_UNKNOWN_V02 = 0, /**< Source is unknown. */ + eQMI_LOC_ALT_SRC_GPS_V02 = 1, /**< GPS is the source. */ + eQMI_LOC_ALT_SRC_CELL_ID_V02 = 2, /**< Cell ID provided the source. */ + eQMI_LOC_ALT_SRC_ENHANCED_CELL_ID_V02 = 3, /**< Source is enhanced cell ID. */ + eQMI_LOC_ALT_SRC_WIFI_V02 = 4, /**< WiFi is the source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ + eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ + eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. */ + eQMI_LOC_ALT_SRC_OTHER_V02 = 9, /**< Other sources. */ + QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ + eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, /**< Fully independent. */ + QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcLinkageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal + position coordinates only. */ + eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, /**< Altitude uncertainty applies to the position of the device + regardless of horizontal position (within the horizontal + uncertainty region, if provided). */ + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcUncertaintyCoverageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocAltSrcEnumT_v02 source; + /**< Specifies the source of the altitude. + + Valid values: \begin{itemize1} + \item 0x00000000 -- ALT_SRC_UNKNOWN + \item 0x00000001 -- ALT_SRC_GPS + \item 0x00000002 -- ALT_SRC_CELL_ID + \item 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID + \item 0x00000004 -- ALT_SRC_WIFI + \item 0x00000005 -- ALT_SRC_TERRESTRIAL + \item 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID + \item 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE + \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER + \item 0x00000009 -- ALT_SRC_OTHER + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocAltSrcLinkageEnumT_v02 linkage; + /**< Specifies the dependency between the horizontal and + altitude position components. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED + \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT + \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG + \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; + /**< Specifies the region of uncertainty. + + Valid values: \begin{itemize1} + \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED + \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid + at the injected horizontal position coordinates + only. + \item 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to + the position of the device regardless of + horizontal position (within the horizontal + uncertainty region, if provided). + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocAltitudeSrcInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position source is GNSS. */ + eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position source is Cell ID. */ + eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ + eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ + eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ + eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. */ + eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, /**< Other sources. */ + QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPositionSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects a position to the location engine. */ +typedef struct { + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} + */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} + */ + + /* Optional */ + /* Circular Horizontal Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0 to 99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} + This field must be specified together with horizontal uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid. + \begin{itemize1} + \item Units: Meters \begin{itemize1} + \item Positive = height + \item Negative = depth + \vspace{-0.18in} \end{itemize1} \end{itemize1}*/ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid + or altitudeWrtMeanSeaLevel is specified.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0-99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} + This field must be specified together with the vertical uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Altitude Source Info */ + uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ + qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; + /**< \n Specifies information regarding the altitude source. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Units: Milliseconds (since Jan. 1, 1970) */ + + /* Optional */ + /* Position Age */ + uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ + int32_t timestampAge; + /**< Position age, which is an estimate of how long ago this fix was made. \n + - Units: Milliseconds */ + + /* Optional */ + /* Position Source */ + uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ + qmiLocPositionSrcEnumT_v02 positionSrc; + /**< Source from which this position was obtained. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS + \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID + \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID + \item 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI + \item 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL + \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID + \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER + \end{itemize1} \vspace{0.05in} + + If altitude is specified and the altitude source is not specified, the engine + assumes that the altitude was obtained using the specified position source. \n + If both altitude and altitude source are specified, the engine assumes + that only latitude and longitude were obtained using the specified position + source. + */ +}qmiLocInjectPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects a position to the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Position Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Position Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ + eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ + eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. */ + eQMI_LOC_LOCK_ALL_V02 = 4, /**< Lock all position sessions. */ + QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocLockEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Lock Type */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + + */ +}qmiLocSetEngineLockReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Set Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Engine Lock request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetEngineLockReqMsgT is empty + * typedef struct { + * }qmiLocGetEngineLockReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Get Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Engine Lock request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Lock Type */ + uint8_t lockType_valid; /**< Must be set to true if lockType is being passed */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + */ +}qmiLocGetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* SBAS Config */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocSetSbasConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* Set SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set SBAS Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSbasConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the SBAS configuration from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get SBAS Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SBAS Config */ + uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocGetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocNmeaSentenceMaskT_v02; +#define QMI_LOC_NMEA_MASK_GGA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000001) /**< Enable GGA type. */ +#define QMI_LOC_NMEA_MASK_RMC_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000002) /**< Enable RMC type. */ +#define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ +#define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ +#define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ +#define QMI_LOC_NMEA_MASK_PQXFI_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000020) /**< Enable PQXFI type. */ +#define QMI_LOC_NMEA_MASK_PSTIS_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000040) /**< Enable PSTIS type. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* NMEA Sentence Types */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< Bitmasks of NMEA types to enable. + + Valid bitmasks: \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS + */ +}qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* Set NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of Set NMEA Types request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * typedef struct { + * }qmiLocGetNmeaTypesReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the NMEA types from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NMEA Types request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* NMEA Sentence Types */ + uint8_t nmeaSentenceType_valid; /**< Must be set to true if nmeaSentenceType is being passed */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< NMEA types to enable. + + Valid bitmasks: \n + - 0x0000ffff -- NMEA_MASK_ALL \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS + */ +}qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Enable Low Power Mode */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Set LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Low Power Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * typedef struct { + * }qmiLocGetLowPowerModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the LPM status from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get LPM request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable LPM */ + uint8_t lowPowerMode_valid; /**< Must be set to true if lowPowerMode is being passed */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ + eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ + eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. */ + eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, /**< Server type is custom PDE. */ + QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL address. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Set Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Server request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* Server Address Type */ + uint8_t serverAddrTypeMask_valid; /**< Must be set to true if serverAddrTypeMask is being passed */ + qmiLocServerAddrTypeMaskT_v02 serverAddrTypeMask; + /**< Type of address the client wants. If unspecified, the + indication will contain all the types of addresses + it has for the specified server type. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ +}qmiLocGetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Server request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001ull) /**< Mask to delete GPS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002ull) /**< Mask to delete GPS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004ull) /**< Mask to delete GPS time. */ +#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008ull) /**< Mask to delete almanac correlation. */ +#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010ull) /**< Mask to delete GLONASS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020ull) /**< Mask to delete GLONASS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040ull) /**< Mask to delete GLONASS time. */ +#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080ull) /**< Mask to delete GLONASS almanac correlation */ +#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100ull) /**< Mask to delete SBAS SVDIR */ +#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200ull) /**< Mask to delete SBAS SVSTEER */ +#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400ull) /**< Mask to delete position estimate */ +#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800ull) /**< Mask to delete time estimate */ +#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000ull) /**< Mask to delete IONO */ +#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000ull) /**< Mask to delete UTC estimate */ +#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000ull) /**< Mask to delete SV health record */ +#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000ull) /**< Mask to delete SADATA */ +#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000ull) /**< Mask to delete RTI */ +#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000ull) /**< Mask to delete SV_NO_EXIST */ +#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000ull) /**< Mask to delete frequency bias estimate */ +typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ +#define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ +#define QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000004) /**< Mask to delete cell database OTA position */ +#define QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000008) /**< Mask to delete cell database external reference position */ +#define QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000010) /**< Mask to delete cell database time tag */ +#define QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000020) /**< Mask to delete cell database cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000040) /**< Mask to delete cell database cached cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000080) /**< Mask to delete cell database last service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000100) /**< Mask to delete cell database current service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000200) /**< Mask to delete cell database neighbor information */ +typedef uint32_t qmiLocDeleteClockInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000001) /**< Mask to delete time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_FREQ_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000002) /**< Mask to delete frequency estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_WEEK_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000004) /**< Mask to delete week number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_RTC_TIME_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000008) /**< Mask to delete RTC time from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_TRANSFER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000010) /**< Mask to delete time transfer from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GPSTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000020) /**< Mask to delete GPS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLOTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000040) /**< Mask to delete GLONASS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLODAY_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000080) /**< Mask to delete GLONASS day number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO4YEAR_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000100) /**< Mask to delete GLONASS four year number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000200) /**< Mask to delete GLONASS RF GRP delay from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_DISABLE_TT_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000400) /**< Mask to delete disable TT from clock information */ +typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_EPHEMERIS_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x01) /**< Delete ephemeris for the satellite */ +#define QMI_LOC_MASK_DELETE_ALMANAC_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x02) /**< Delete almanac for the satellite */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gnssSvId; + /**< SV ID of the satellite whose data is to be deleted. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + + Valid values: \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; + /**< Indicates if the ephemeris or almanac for a satellite + is to be deleted. \n + Valid values: \n + - 0x01 -- DELETE_EPHEMERIS \n + - 0x02 -- DELETE_ALMANAC + */ +}qmiLocDeleteSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete All */ + uint8_t deleteAllFlag; + /**< Whether all assistance data is to be deleted. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- All assistance data is to be deleted; if + this flag is set, all the other information + contained in the optional fields for this + message are ignored + \item 0x00 (FALSE) -- The optional fields in the message are to be + used to determine which data is to be deleted + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Delete SV Info */ + uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ + uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ + qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; + /**< \n List of satellites for which the assistance data is to be deleted. + */ + + /* Optional */ + /* Delete GNSS Data */ + uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ + qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; + /**< Mask for the GNSS data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_GPS_SVDIR + \item 0x00000002 -- DELETE_GPS_SVSTEER + \item 0x00000004 -- DELETE_GPS_TIME + \item 0x00000008 -- DELETE_GPS_ALM_CORR + \item 0x00000010 -- DELETE_GLO_SVDIR + \item 0x00000020 -- DELETE_GLO_SVSTEER + \item 0x00000040 -- DELETE_GLO_TIME + \item 0x00000080 -- DELETE_GLO_ALM_CORR + \item 0x00000100 -- DELETE_SBAS_SVDIR + \item 0x00000200 -- DELETE_SBAS_SVSTEER + \item 0x00000400 -- DELETE_POSITION + \item 0x00000800 -- DELETE_TIME + \item 0x00001000 -- DELETE_IONO + \item 0x00002000 -- DELETE_UTC + \item 0x00004000 -- DELETE_HEALTH + \item 0x00008000 -- DELETE_SADATA + \item 0x00010000 -- DELETE_RTI + \item 0x00020000 -- DELETE_SV_NO_EXIST + \item 0x00040000 -- DELETE_FREQ_BIAS_EST + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Delete Cell Database */ + uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ + qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; + /**< Mask for the cell database assistance data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_CELLDB_POS + \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS + \item 0x00000004 -- DELETE_CELLDB_OTA_POS + \item 0x00000008 -- DELETE_CELLDB_EXT_REF_POS + \item 0x00000010 -- DELETE_CELLDB_TIMETAG + \item 0x00000020 -- DELETE_CELLDB_CELLID + \item 0x00000040 -- DELETE_CELLDB_CACHED_CELLID + \item 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL + \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL + \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Delete Clock Info */ + uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ + qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; + /**< Mask for the clock information assistance data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST + \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST + \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER + \item 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME + \item 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER + \item 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST + \item 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST + \item 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER + \item 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER + \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY + \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete Assist Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Assist Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Enable XTRA-T */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Set XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set XTRA-T Session Control request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * typedef struct { + * }qmiLocGetXtraTSessionControlReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the XTRA-T session control value from the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Get XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get XTRA-T Session Control request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable XTRA-T */ + uint8_t xtraTSessionControl_valid; /**< Must be set to true if xtraTSessionControl is being passed */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t wifiPositionTime; + /**< Common counter (typically, the number of milliseconds since bootup). + This field is only to be provided if the modem and host processors are + synchronized. */ +}qmiLocWifiFixTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIFIXERRORCODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_FIX_ERROR_SUCCESS_V02 = 0, /**< WiFi fix is successful. */ + eQMI_LOC_WIFI_FIX_ERROR_WIFI_NOT_AVAILABLE_V02 = 1, /**< WiFi fix failed because WiFi is not available on the device. */ + eQMI_LOC_WIFI_FIX_ERROR_NO_AP_FOUND_V02 = 2, /**< WiFi fix failed because no access points were found. */ + eQMI_LOC_WIFI_FIX_ERROR_UNAUTHORIZED_V02 = 3, /**< WiFi fix failed because the server denied access due to bad authorization + code. */ + eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ + eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. + This may be because the APs found are not in the database. */ + eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, /**< WiFi fix failed, but the cause could not be determined. */ + QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiFixErrorCodeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double lat; + /**< WiFi position latitude. \n + - Type: Floating point \n + - Units: Degrees */ + + double lon; + /**< WiFi position longitude. \n + - Type: Floating point \n + - Units: Degrees */ + + uint16_t hepe; + /**< WiFi position HEPE.\n + - Units: Meters */ + + uint8_t numApsUsed; + /**< Number of Access Points (AP) used to generate a fix. */ + + qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; + /**< WiFi position error code; set to 0 if the fix succeeds. This position + is only used by a module if the value is 0. If there was a failure, + the error code provided by the WiFi positioning system can be provided + here. + + Valid values: \begin{itemize1} + \item 0x00000000 -- ERROR_SUCCESS + \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE + \item 0x00000002 -- ERROR_NO_AP_FOUND + \item 0x00000003 -- ERROR_UNAUTHORIZED + \item 0x00000004 -- ERROR_SERVER_UNAVAILABLE + \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED + \item 0x00000006 -- ERROR_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocWifiFixPosStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocWifiApQualifierMaskT_v02; +#define QMI_LOC_WIFI_AP_QUALIFIER_BEING_USED_V02 ((qmiLocWifiApQualifierMaskT_v02)0x01) /**< Access point is being used by the WPS. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_HIDDEN_SSID_V02 ((qmiLocWifiApQualifierMaskT_v02)0x02) /**< AP does not broadcast SSID. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_PRIVATE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x04) /**< AP has encryption turned on. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_INFRASTRUCTURE_MODE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x08) /**< AP is in infrastructure mode and not in ad-hoc/unknown mode. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t macAddr[QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02]; + /**< Associated MAC address of the AP. \n + - Type: Array of unsigned integers \n + - Address length: 6 + */ + + int32_t rssi; + /**< Receive signal strength indicator.\n + - Units: dBm (offset with +100 dB) */ + + uint16_t channel; + /**< WiFi channel on which a beacon was received. */ + + qmiLocWifiApQualifierMaskT_v02 apQualifier; + /**< A bitmask of Boolean qualifiers for APs. + All unused bits in this mask must be set to 0. + + Valid values: \n + - 0x01 -- BEING_USED \n + - 0x02 -- HIDDEN_SSID \n + - 0x04 -- PRIVATE \n + - 0x08 -- INFRASTRUCTURE_MODE + */ +}qmiLocWifiApInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects the WiFi position. */ +typedef struct { + + /* Optional */ + /* WiFi Fix Time */ + uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ + qmiLocWifiFixTimeStructT_v02 wifiFixTime; + /**< \n Time of WiFi position fix. */ + + /* Optional */ + /* WiFi Position */ + uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ + qmiLocWifiFixPosStructT_v02 wifiFixPosition; + /**< \n WiFi position fix. */ + + /* Optional */ + /* WiFi Access Point Information */ + uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ + uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ + qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; + /**< \n AP scan list. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horizontalReliability_valid; /**< Must be set to true if horizontalReliability is being passed */ + qmiLocReliabilityEnumT_v02 horizontalReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects the WiFi position. */ +typedef struct { + + /* Mandatory */ + /* Inject WiFi Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject WiFi Position request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. */ + eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, /**< WiFi is not available. */ + QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Availablility of WiFi */ + qmiLocWifiStatusEnumT_v02 wifiStatus; + /**< WiFi status information. + + Valid values: \begin{itemize1} + \item 0x00000001 -- WIFI_STATUS_AVAILABLE + \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Status of Notify WiFi Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WiFi Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * typedef struct { + * }qmiLocGetRegisteredEventsReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the mask of the events for which a client has + registered. */ +typedef struct { + + /* Mandatory */ + /* Get Registered Events Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Registered Events request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Event Registration Mask */ + uint8_t eventRegMask_valid; /**< Must be set to true if eventRegMask is being passed */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Event registration mask. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- POSITION_REPORT + \item 0x00000002 -- GNSS_SV_INFO + \item 0x00000004 -- NMEA + \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ + \item 0x00000010 -- INJECT_TIME_REQ + \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ + \item 0x00000040 -- INJECT_POSITION_REQ + \item 0x00000080 -- ENGINE_STATE + \item 0x00000100 -- FIX_SESSION_STATE + \item 0x00000200 -- WIFI_REQ + \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS + \item 0x00000800 -- TIME_SYNC_REQ + \item 0x00001000 -- SET_SPI_STREAMING_REPORT + \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCOPERATIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ + eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ + eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ + eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ + eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for a GSM/UMTS network. */ + eQMI_LOC_OPER_MODE_WWAN_V02 = 6, /**< Use WWAN measurements to calculate the position. If this mode is + set, AFLT will be used for 1x networks and OTDOA will be used + for LTE networks. */ + QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocOperationModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Operation Mode */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Preferred operation mode. + \label{operationMode} + + Valid values: \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetOperationModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Set Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Operation Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetOperationModeReqMsgT is empty + * typedef struct { + * }qmiLocGetOperationModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the current operation mode from the engine. */ +typedef struct { + + /* Mandatory */ + /* Get Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Operation Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Operation Mode */ + uint8_t operationMode_valid; /**< Must be set to true if operationMode is being passed */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Current operation mode. + + Valid values: \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Stationary Status */ + uint8_t stationary; + /**< Whether the device is stationary: + \begin{itemize1} + \item 0x00 (FALSE) -- Device is not stationary + \item 0x01 (TRUE) -- Device is stationary + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Confidence */ + uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ + uint8_t confidenceStationary; + /**< Confidence in the Stationary state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocSetSpiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Status of SPI Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the SPI Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSpiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint8_t qmiLocSensorDataFlagMaskT_v02; +#define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting + the sensor data. */ +#define QMI_LOC_SENSOR_DATA_FLAG_SENSOR_TIME_IS_MODEM_TIME_V02 ((qmiLocSensorDataFlagMaskT_v02)0x02) /**< Bitmask to specify that the sensor time stamp is the same as the modem + time stamp. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t timeOffset; + /**< Sample time offset. This time offset must be + relative to the sensor time of the first sample.\n + - Units: Milliseconds */ + + float xAxis; + /**< Sensor x-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ + + float yAxis; + /**< Sensor y-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ + + float zAxis; + /**< Sensor z-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ +}qmiLoc3AxisSensorSampleStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t timeOfFirstSample; + /**< Denotes a full 32-bit time tag of the first (oldest) sample in this + message. \n + - Units: Milliseconds */ + + qmiLocSensorDataFlagMaskT_v02 flags; + /**< Flags to indicate any deviation from the default measurement + assumptions. All unused bits in this field must be set to 0. + + Valid bitmasks: \begin{itemize1} + \item 0x01 -- SIGN_REVERSAL + \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME + \vspace{-0.18in} \end{itemize1} */ + + uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ + qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; + /**< Variable length array to specify sensor samples. \n + - Maximum length of the array: 50 */ +}qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< An opaque identifier that is sent in by the client that will be echoed + in the indication so the client can relate the indication to the + request. */ + + /* Optional */ + /* 3-Axis Accelerometer Data */ + uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; + /**< \n Accelerometer sensor samples. */ + + /* Optional */ + /* 3-Axis Gyroscope Data */ + uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; + /**< \n Gyroscope sensor samples. */ +}qmiLocInjectSensorDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Sensor Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Sensor Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< Opaque identifier that was sent in by the client echoed + so the client can relate the indication to the request. */ + + /* Optional */ + /* Accelerometer Samples Accepted */ + uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ + uint8_t threeAxisAccelSamplesAccepted; + /**< Lets the client know how many 3-axis accelerometer samples + were accepted. */ + + /* Optional */ + /* Gyroscope Samples Accepted */ + uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ + uint8_t threeAxisGyroSamplesAccepted; + /**< Lets the client know how many 3-axis gyroscope samples were + accepted. */ +}qmiLocInjectSensorDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Reference Time Sync Counter */ + uint32_t refCounter; + /**< Must be set to the value that was sent to the control point when the + GNSS location engine requested time sync injection. */ + + /* Mandatory */ + /* Sensor Receive Time */ + uint32_t sensorProcRxTime; + /**< Value of the sensor time when the control point received the + Time Sync Inject request from the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Units: Milliseconds */ + + /* Mandatory */ + /* Sensor Transmit Time */ + uint32_t sensorProcTxTime; + /**< Value of the sensor time when the control point injects this message + for use by the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Units: Milliseconds */ +}qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Inject Time Sync Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Time Sync Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, /**< Unknown cradle mount state */ + QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocCradleMountStateEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetCradleMountConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Cradle Mount Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Cradle Mount State */ + uint8_t cradleMountState_valid; /**< Must be set to true if cradleMountState is being passed */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence of the Cradle Mount state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Cradle Mount State */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence in the Cradle Mount state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Cradle Mount Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, /**< Unknown external power state. */ + QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocExternalPowerConfigEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetExternalPowerConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get External Power Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* External Power State */ + uint8_t externalPowerState_valid; /**< Must be set to true if externalPowerState is being passed */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* External Power State */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set External Power Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, /**< PPP PDN type. */ + QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerPDNEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerPDNEnumT_v02 pdnType; + /**< PDN type of the APN profile. + + Valid values: \n + - 0x00000001 -- PDN_TYPE_IPV4 \n + - 0x00000002 -- PDN_TYPE_IPV6 \n + - 0x00000003 -- PDN_TYPE_IPV4V6 \n + - 0x00000004 -- PDN_TYPE_PPP + */ + + char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; + /**< APN name. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 101 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocApnProfilesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. */ + eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, /**< Location server request failed. */ + QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerReqStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Connection handle that the service specified in the + Location Server Connection request event. */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Type of connection request service that was specified in the + Location Server Connection Request event. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* Connection Status */ + qmiLocServerReqStatusEnumT_v02 statusType; + /**< Status of the Connection request. + + Valid values: \n + - 0x00000001 -- STATUS_SUCCESS = 1 \n + - 0x00000002 -- STATUS_FAILURE = 2 + + */ + + /* Optional */ + /* APN Profile */ + uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ + qmiLocApnProfilesStructT_v02 apnProfile; + /**< \n Access Point Name (APN) profile information is present only when + requestType is OPEN and statusType is SUCCESS. */ +}qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Status of Inform Loc Server Conn Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inform Location Server Connection Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. */ + eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, /**< V2 VX version. */ + QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocVxVersionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. */ + eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, /**< SUPL version 2.0. */ + QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSuplVersionEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocLppConfigMaskT_v02; +#define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ +#define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ +typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in the control plane. */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in the user plane. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Configures the protocols that the location service supports + for assisted GLONASS. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP + \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000001ull) /**< Mask for the SUPL security configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000010ull) /**< Mask for the LPP configuration parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Set Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ + qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; + /**< Identifies parameters that were not set successfully. This field + is sent only if the status is not a success. + + Valid bitmasks: \begin{itemize1} + \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY + \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION + \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + + Valid bitmasks: \begin{itemize1} + \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY + \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION + \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION + \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG + \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Get Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Assisted GLONASS Protocol mask. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP + \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02 = 0, /**< Sensors data should be requested whenever a position request is + received. If sensor data are injected, the positioning engine + attempts to improve the heading and positioning performance using sensors. + This is the default. + */ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, /**< Inertial sensors are not to be used to aid heading and position + improvement. */ + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorsControlConfigSensorUseEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the sensor control configuration. */ +typedef struct { + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid heading and positioning + performance. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS_USE_DISABLED: + Inertial sensors are not to be used to aid in heading and + position improvement. + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid the heading and positioning + performance. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS_USE_DISABLED: + Inertial sensors are not to be used to aid in the heading and + position improvement. + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocSensorPropertiesMaskT_v02; +#define QMI_LOC_SENSOR_PROPERTIES_MASK_GYRO_BIAS_VARIANCE_RANDOM_WALK_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000001) /**< Denotes the gyro bias variance random walk parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000002) /**< Denotes the velocity random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000004) /**< Denotes the acceleration random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000008) /**< Denotes the angle random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_RATE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000010) /**< Denotes the rate random walk spectral density parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Optional */ + /* Gyro Bias Random Walk Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 + + */ +}qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Properties request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Set Sensor Properties */ + uint8_t failedSensorPropertiesMask_valid; /**< Must be set to true if failedSensorPropertiesMask is being passed */ + qmiLocSensorPropertiesMaskT_v02 failedSensorPropertiesMask; + /**< This field will be sent only if the status is not a success. + Identifies the parameters that were not set successfully. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Sensor Properties Config Parameters */ + qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; + /**< Mask denoting the sensor properties parameters to be retrieved. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Properties request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Gyro Bias Random Walk Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 + + */ +}qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. + This mode can optimize power consumption and give a + power-balanced positioning and heading enhancement using + inertial sensors */ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, /**< Sensors usage is to be forced ON. + This mode can be requested by the control point when + power consumption is not a restriction to the use of + inertial sensors. */ + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorPerformanceControlModeEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocSensorAlgorithmMaskT_v02; +#define QMI_LOC_SENSOR_ALGORITHM_MASK_DISABLE_INS_POSITIONING_FILTER_V02 ((qmiLocSensorAlgorithmMaskT_v02)0x00000001) /**< Inertial sensors are not to be used in Accelerometer-integrated fashion with + GNSS. They can still be used for aiding in heading improvements. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Optional */ + /* Sensor Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensors data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensors control configuration. + + Valid values: \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x00000001 -- FORCED: \n + The GNSS location engine must request use of sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request acceleration data to be used by the low data rate + filter. The sensor data rate is specified in terms of the nominal number + of samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request gyro data to be used by the high data rate filter. + The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Sets which sensor algorithms are to be used when processing sensor data. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ +}qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000010) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000020) /**< Failed to set the gyroscope sampling specification. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Performance Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Configuration */ + uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ + qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; + /**< Identifies parameters that were not configured successfully. This field + is sent only if the status is not a success. + + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- PERFORMANCE_MODE + \item 0x00000002 -- ACCEL_SAMPLING_SPEC + \item 0x00000004 -- GYRO_SAMPLING_SPEC + \item 0x00000008 -- ALGORITHM_CONFIG + \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH + \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorPerformanceControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor performance control + configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensor Performance Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensor data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensor control configuration. + + Valid values: \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x0000001 -- FORCED: \n + The GNSS location engine must request use of the sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2Hz batching rate. + */ + + /* Optional */ + /* Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data + rate is specified in terms of the nominal number of samples per batch + and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Informs which sensor algorithms are currently set. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ +}qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate ID */ + uint8_t suplCertId; + /**< Certificate ID of the SUPL certificate. \n + - Units: Bytes \n + - Range: 0 to 9 */ + + /* Mandatory */ + /* SUPL Certificate Data */ + uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ + uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; + /**< SUPL certificate contents. \n + - Type: Array of bytes. \n + - Maximum certificate size: 2000 bytes */ +}qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject SUPL Certificate request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Deletes a SUPL certificate. */ +typedef struct { + + /* Optional */ + /* SUPL Certificate ID */ + uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ + uint8_t suplCertId; + /**< Certificate ID of the SUPL certificate to be deleted. \n + - Units: Bytes \n + - Range: 0 to 9 \n + If suplCertId is not specified, + all SUPL certificates are deleted. */ +}qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Deletes a SUPL certificate. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate Deletion Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete SUPL Certificate request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< Denotes whether the position engine uses the + injected position in a direct position calculation. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< Denotes whether the position engine filters the + SV usage in the fix. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< Denotes whether the position engine stores assistance data + in persistent memory. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Controls how the injected position is used in the position engine. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Use the injected position in a direct position + calculation + \item 0x00 (FALSE) -- Do not use the injected position in a direct + position calculation + \end{itemize1} + The default value is TRUE. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Controls whether SV usage is filtered in a position fix. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Filter the usage of SVs in the fix + \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix + \end{itemize1} + The default value is FALSE. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Controls whether assistance data is to be stored in + persistent memory. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Store assistance data in persistent memory + \item 0x00 (FALSE) -- Do not store assistance data in persistent memory + \end{itemize1} + The default value is TRUE. + */ +}qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Mandatory */ + /* Set Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ + qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; + /**< Identifies the parameters that were not set successfully. + This field is sent only if the status is other than SUCCESS. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Get Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Specifies whether the injected position is used for a direct calculation + in the position engine. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- The injected position is used in a direct + position calculation + \item 0x00 (FALSE) -- The injected position is not used in a direct + position calculation + \end{itemize1} + The default value is TRUE. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Specifies whether SV usage is filtered in a position fix. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- SV usage is filtered in the fix + \item 0x00 (FALSE) -- SV usage is not filtered in the fix + \end{itemize1} + The default value is FALSE. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Specifies whether assistance data is stored in persistent memory. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Assistance data is stored in persistent memory + \item 0x00 (FALSE) -- Assistance data is not stored in persistent + memory + \end{itemize1} + The default value is TRUE. + */ +}qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint8_t qmiLocGeofenceBreachMaskT_v02; +#define QMI_LOC_GEOFENCE_BREACH_ENTERING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x01) /**< If this mask is set, a breach event is reported + when the Geofence is entered. */ +#define QMI_LOC_GEOFENCE_BREACH_LEAVING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x02) /**< If this mask is set, a breach event is reported + when the Geofence is exited. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCERESPONSIVENESSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_LOW_V02 = 0x01, /**< The Geofence is monitored for a breach at a + lower rate. The gap between actual breach and + the time it is reported is higher. This + setting results in lower power usage. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a + medium rate. This is the default setting. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, /**< The Geofence is monitored for a breach at a + high rate. The gap between actual breach and + the time it is reported is low. This results + in higher power usage. */ + QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceResponsivenessEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCECONFIDENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_CONFIDENCE_LOW_V02 = 0x01, /**< The Geofence engine indicates a breach with + low confidence. This setting results in lower + power usage. This setting can impact the "yield" because + incorrect breach events may be sent. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with + medium confidence. This is the default setting. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, /**< The Geofence engine indicates a breach with + high confidence. This setting results in higher + power usage. */ + QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceConfidenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double latitude; + /**< Latitude of the center of the Geofence.*/ + + double longitude; + /**< Longitude of the center of the Geofence.*/ + + uint32_t radius; + /**< Radius of the circular Geofence in meters. */ +}qmiLocCircularGeofenceArgsStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. */ + eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, /**< Position outside a Geofence. */ + QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofencePositionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Add Circular Geofence + indication. */ + + /* Mandatory */ + /* Circular Geofence Arguments */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Mandatory */ + /* Breach Event Mask */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ + + /* Mandatory */ + /* Include Position in Breach Event */ + uint8_t includePosition; + /**< Specifies whether the Geofence engine is to include the position + in a breach event. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Position will be reported with the breach event + \item 0x00 (FALSE) -- Position will not be reported with the breach + event + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Responsiveness */ + uint8_t responsiveness_valid; /**< Must be set to true if responsiveness is being passed */ + qmiLocGeofenceResponsivenessEnumT_v02 responsiveness; + /**< Specifies the rate of detection for a Geofence breach. + This may impact the time lag between the actual breach event and + when it is reported. This parameter has power implications + and is to be fine-tuned to optimize power savings. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW + \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED + \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Confidence */ + uint8_t confidence_valid; /**< Must be set to true if confidence is being passed */ + qmiLocGeofenceConfidenceEnumT_v02 confidence; + /**< Given a breach event, the confidence determines the probability + that the breach happened at the Geofence boundary. + This parameter has power implications and + is to be fine-tuned to optimize power savings. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW + \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED + \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH + \vspace{-0.18in} \end{itemize1} */ +}qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Add Circular Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Add Circular Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000008 -- INSUFFICIENT_MEMORY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Add Circular + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Geofence identifier allocated by the engine. + The client must include this identifier in all transactions + pertaining to this Geofence. */ +}qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be deleted. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Delete Geofence + indication. */ +}qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Delete Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was deleted. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Delete + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ +}qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. */ + eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, /**< The Geofence was initiated by the device. */ + QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceOriginEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. */ + eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, /**< The Geofence monitoring is suspended. */ + QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be queried. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned with the Query Geofence + indication. */ +}qmiLocQueryGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Query Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Query Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was queried. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Query + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence Origin */ + uint8_t geofenceOrigin_valid; /**< Must be set to true if geofenceOrigin is being passed */ + qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; + /**< Originator of the Geofence. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK + \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Position with Respect to Geofence */ + uint8_t posWrtGeofence_valid; /**< Must be set to true if posWrtGeofence is being passed */ + qmiLocGeofencePositionEnumT_v02 posWrtGeofence; + /**< Indicates if the client is currently inside or outside + the Geofence. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_POSITION_INSIDE + \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Circular Geofence Parameters */ + uint8_t circularGeofenceArgs_valid; /**< Must be set to true if circularGeofenceArgs is being passed */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ +}qmiLocQueryGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence to be edited. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Edit Geofence + request. This parameter will always be present if the + status field is set to SUCCESS. + */ + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Breach Event Mask */ + uint8_t breachMask_valid; /**< Must be set to true if breachMask is being passed */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocGeofenceConfigParamMaskT_v02; +#define QMI_LOC_GEOFENCE_PARAM_MASK_GEOFENCE_STATE_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000001) /**< Mask for the Geofence state parameter. */ +#define QMI_LOC_GEOFENCE_PARAM_MASK_BREACH_MASK_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000002) /**< Mask for Geofence breach mask parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Edit Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Edit Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was edited. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is specified in the Edit Geofence request. */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedParams_valid; /**< Must be set to true if failedParams is being passed */ + qmiLocGeofenceConfigParamMaskT_v02 failedParams; + /**< Specified only when the status is not set to SUCCESS. If + the mask corresponding to a field is set, it indicates that + the Geofence parameter could not be edited. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE + \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Get Best Available Position indication. */ +}qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Best Available Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Best Available Position request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Get Best + Available Position request. This parameter will + always be present if the status field is set to + SUCCESS. */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Units: Milliseconds */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Major Axis */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation. \n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Circular Confidence */ + uint8_t horCircularConfidence_valid; /**< Must be set to true if horCircularConfidence is being passed */ + uint8_t horCircularConfidence; + /**< Horizontal circular uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Elliptical Confidence */ + uint8_t horEllipticalConfidence_valid; /**< Must be set to true if horEllipticalConfidence is being passed */ + uint8_t horEllipticalConfidence; + /**< Horizontal elliptical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ + float horSpeed; + /**< Horizontal speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Horizontal Speed Uncertainty */ + uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ + float horSpeedUnc; + /**< Horizontal speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level. \n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Vertical Speed */ + uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ + float vertSpeed; + /**< Vertical speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Vertical Speed Uncertainty */ + uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ + float vertSpeedUnc; + /**< Vertical speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading. \n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty. \n + - Type: Floating point \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. */ + + /* Optional */ + /* Technology Used Mask */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + + /* Optional */ + /* GPS Time */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. + + Valid values: \begin{itemize1} + \item 0x00000000 -- TIME_SRC_INVALID + \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER + \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING + \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT + \item 0x00000004 -- TIME_SRC_TOW_DECODE + \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED + \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED + \item 0x00000007 -- TIME_SRC_NAV_SOLUTION + \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ +}qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known. */ + eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is Stationary. */ + eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, /**< Device state is In Motion. */ + QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known. */ + eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in Pedestrian mode; nothing else is known about the movement. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian Walking mode. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian Running mode. */ + eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, /**< Device movement is in Vehicular mode; nothing else is known about the movement. */ + QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocMotionStateEnumT_v02 motion_state; + /**< Current motion state of the user. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_STATE_UNKNOWN (0) -- Device state is not known. + \item eQMI_LOC_MOTION_STATE_STATIONARY (1) -- Device state is Stationary. + \item eQMI_LOC_MOTION_STATE_IN_MOTION (2) -- Device state is In Motion. + \vspace{0.06in} \end{itemize1} + + Absolute rest and relative rest are both indicated by setting motion_state + to Stationary. The relative rest state can be distinguished from absolute + rest by reducing probability_of_state. + */ + + qmiLocMotionModeEnumT_v02 motion_mode; + /**< Modes of user motion. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_MODE_ UNKNOWN (0) -- Device movement is not known. + \item eQMI_LOC_MOTION_MODE_ STATIONARY (1) -- Device is not moving. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_UNKNOWN (200) -- Device movement + is in Pedestrian mode; nothing else is known about the movement. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_WALKING (201) -- Device movement + is in Pedestrian Walking mode. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_RUNNING (202) -- Device movement + is in Pedestrian Running mode. + \item eQMI_LOC_MOTION_MODE_ VEHICLE_UNKNOWN (300) -- Device movement is + in Vehicular mode; nothing else is known about the movement. + \vspace{0.06in} \end{itemize1} + + The motion_mode value is independent of the motion_state value. + */ + + float probability_of_state; + /**< Probability that the device is actually undergoing the motion state + specified by the combination of the values of motion_state, motion_mode, + and motion_sub_mode. \vspace{0.06in} + + This value is a floating point number in the range of 0 to 100, in + units of percent probability. Any value greater than 99.9999 is + applied as 99.9999. \vspace{0.06in} + + It is recommended that if a particular combination of motion_state and + motion_mode cannot be determined with more than 50 percent confidence, + that a more general statement of user motion be made. + For example, if the mode of In-Motion + Pedestrian-Running can only be + determined with 50 percent probability, and the simpler statement of In-Motion + can be determined with 90 percent probability, it is recommended that this field + be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} + + If the motion_state is not known, the value in this field is not used. + */ + + uint16_t age; + /**< Age of the motion data in milliseconds at the time of injection. + */ + + uint16_t timeout; + /**< If the age of the motion data input exceeds the timeout value, the data + will no longer be used. The timeout value is in units of milliseconds. + Values in the range of 0 to 10000 are accepted. If 65535 is provided, + the motion data input is applied until the next input is + received. \vspace{0.06in} + + If the determination of motion data is an instantaneous observation + and no notice is guaranteed to be given via the QMI on a change in the + state of the motion data, it is recommended that this field be set to 0. \vspace{0.06in} + + If the determination of motion data is continuously monitored + external to the QMI and an update is always applied to the QMI upon any + change in state, a value of 65535 is used for this field. + Note that in this case, if a certain mode is set and is not later + unset (e.g., by sending in the request message with a user motion + state of Unknown), the value is applied indefinitely. + */ +}qmiLocMotionDataStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Motion Data */ + qmiLocMotionDataStructT_v02 motion_data; + /**< Current motion data of the client */ +}qmiLocInjectMotionDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Inject Motion Data Request Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Motion Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_ PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectMotionDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to retrieve the list of network + initiated Geofence IDs. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The same transaction ID + will be returned in the Get NI Geofence ID List indication. */ +}qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to retrieve the list of network + initiated Geofence IDs. */ +typedef struct { + + /* Mandatory */ + /* Get NI Geofence ID List status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NI Geofence ID List request. + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Get NI + Geofence ID List request. */ + + /* Optional */ + /* NI Geofence ID List */ + uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ + uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ + uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; + /**< List containing the NI Geofence IDs. + - Type: Array of unsigned 32-bit integers \n + - Maximum NI Geofence ID List length: 16 */ +}qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t MCC; + /**< GSM mobile country code. Refer to ITU-T E.212 specification */ + + uint32_t MNC; + /**< GSM mobile network code. Refer to ITU-T E.212 specification*/ + + uint32_t LAC; + /**< GSM location area code.Refer to ITU-T E.212 specification */ + + uint32_t CID; + /**< GSM cell identification.Refer to ITU-T E.212 specification */ +}qmiLocGSMCellIdStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* GSM Cell ID */ + qmiLocGSMCellIdStructT_v02 gsmCellId; + /**< Identifies the GSM Cell the device is currently camped on.*/ + + /* Mandatory */ + /* Roaming Status */ + uint8_t roamingStatus; + /**< Whether the device is roaming. + \begin{itemize1} + \item 0x01 (TRUE) -- The device is roaming. + \item 0x00 (FALSE) -- The device is not roaming. + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocInjectGSMCellInfoReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject GSM Cell Info Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject GSM Cell Info request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ +}qmiLocInjectGSMCellInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL_V02 = 0, /**< SUPL netwrok initiated message is being injected. */ + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Injected Network Initiated Message Type */ + qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02 injectedNIMessageType; + /**< Type of the network initiated message being injected + Valid Values: + - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL (0) -- SUPL netwrok initiated message is being injected. */ + + /* Mandatory */ + /* Injected Network Initiated Message */ + uint32_t injectedNIMessage_len; /**< Must be set to # of elements in injectedNIMessage */ + uint8_t injectedNIMessage[QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02]; + /**< Network initiated message body. + If the inject NI message type is TYPE_SUPL, the message contains + a SUPL INIT message as defined in OMA-TS-ULP-V2_0-20110527-C specification. */ +}qmiLocInjectNetworkInitiatedMessageReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Network Initiated Message Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Network Initiated Message request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + - 0x00000008 -- INSUFFICIENT_MEMORY \n */ +}qmiLocInjectNetworkInitiatedMessageIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * typedef struct { + * }qmiLocWWANOutOfServiceNotificationReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to notify the location engine that the device is + no longer camped. */ +typedef struct { + + /* Mandatory */ + /* Notify WWAN Out of Service Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WWAN out of service request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + */ +}qmiLocWWANOutOfServiceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + +/*Service Message Definition*/ +/** @addtogroup loc_qmi_msg_ids + @{ + */ +#define QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02 0x0020 +#define QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02 0x0020 +#define QMI_LOC_REG_EVENTS_REQ_V02 0x0021 +#define QMI_LOC_REG_EVENTS_RESP_V02 0x0021 +#define QMI_LOC_START_REQ_V02 0x0022 +#define QMI_LOC_START_RESP_V02 0x0022 +#define QMI_LOC_STOP_REQ_V02 0x0023 +#define QMI_LOC_STOP_RESP_V02 0x0023 +#define QMI_LOC_EVENT_POSITION_REPORT_IND_V02 0x0024 +#define QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02 0x0025 +#define QMI_LOC_EVENT_NMEA_IND_V02 0x0026 +#define QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02 0x0027 +#define QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02 0x0028 +#define QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02 0x0029 +#define QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02 0x002A +#define QMI_LOC_EVENT_ENGINE_STATE_IND_V02 0x002B +#define QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02 0x002C +#define QMI_LOC_EVENT_WIFI_REQ_IND_V02 0x002D +#define QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02 0x002E +#define QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02 0x002F +#define QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02 0x0030 +#define QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 0x0031 +#define QMI_LOC_GET_SERVICE_REVISION_REQ_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_RESP_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_IND_V02 0x0032 +#define QMI_LOC_GET_FIX_CRITERIA_REQ_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_RESP_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_IND_V02 0x0033 +#define QMI_LOC_NI_USER_RESPONSE_REQ_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_RESP_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_IND_V02 0x0034 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02 0x0035 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02 0x0037 +#define QMI_LOC_INJECT_UTC_TIME_REQ_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_RESP_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_IND_V02 0x0038 +#define QMI_LOC_INJECT_POSITION_REQ_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_RESP_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_IND_V02 0x0039 +#define QMI_LOC_SET_ENGINE_LOCK_REQ_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_RESP_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_IND_V02 0x003A +#define QMI_LOC_GET_ENGINE_LOCK_REQ_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_RESP_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_IND_V02 0x003B +#define QMI_LOC_SET_SBAS_CONFIG_REQ_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_RESP_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_IND_V02 0x003C +#define QMI_LOC_GET_SBAS_CONFIG_REQ_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_RESP_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_IND_V02 0x003D +#define QMI_LOC_SET_NMEA_TYPES_REQ_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_RESP_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_IND_V02 0x003E +#define QMI_LOC_GET_NMEA_TYPES_REQ_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_RESP_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_IND_V02 0x003F +#define QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_RESP_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_IND_V02 0x0040 +#define QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_RESP_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_IND_V02 0x0041 +#define QMI_LOC_SET_SERVER_REQ_V02 0x0042 +#define QMI_LOC_SET_SERVER_RESP_V02 0x0042 +#define QMI_LOC_SET_SERVER_IND_V02 0x0042 +#define QMI_LOC_GET_SERVER_REQ_V02 0x0043 +#define QMI_LOC_GET_SERVER_RESP_V02 0x0043 +#define QMI_LOC_GET_SERVER_IND_V02 0x0043 +#define QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_RESP_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_IND_V02 0x0044 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02 0x0045 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02 0x0046 +#define QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_RESP_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_IND_V02 0x0047 +#define QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02 0x0048 +#define QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_IND_V02 0x0049 +#define QMI_LOC_SET_OPERATION_MODE_REQ_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_RESP_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_IND_V02 0x004A +#define QMI_LOC_GET_OPERATION_MODE_REQ_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_RESP_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_IND_V02 0x004B +#define QMI_LOC_SET_SPI_STATUS_REQ_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_RESP_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_IND_V02 0x004C +#define QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_RESP_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_IND_V02 0x004D +#define QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02 0x004E +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 0x004F +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02 0x0050 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02 0x0051 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02 0x0052 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 0x0053 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0054 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0055 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02 0x0056 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02 0x0057 +#define QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02 0x0058 +#define QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02 0x0059 +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005A +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005B +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02 0x005C +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02 0x005D +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005E +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F +#define QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02 0x0060 +#define QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02 0x0061 +#define QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02 0x0062 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 0x0063 +#define QMI_LOC_DELETE_GEOFENCE_REQ_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_RESP_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_IND_V02 0x0064 +#define QMI_LOC_QUERY_GEOFENCE_REQ_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_RESP_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_IND_V02 0x0065 +#define QMI_LOC_EDIT_GEOFENCE_REQ_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_RESP_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_IND_V02 0x0066 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 +#define QMI_LOC_INJECT_MOTION_DATA_REQ_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_RESP_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_IND_V02 0x0068 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 +#define QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 0x006A +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 0x006B +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02 0x006C +/** + @} + */ + +/* Service Object Accessor */ +/** @addtogroup wms_qmi_accessor + @{ + */ +/** This function is used internally by the autogenerated code. Clients should use the + macro loc_get_service_object_v02( ) that takes in no arguments. */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ); + +/** This macro should be used to get the service object */ +#define loc_get_service_object_v02( ) \ + loc_get_service_object_internal_v02( \ + LOC_V02_IDL_MAJOR_VERS, LOC_V02_IDL_MINOR_VERS, \ + LOC_V02_IDL_TOOL_VERS ) +/** + @} + */ + + +#ifdef __cplusplus +} +#endif +#endif + From dc7abf9a3d621b7a744e0eaeb6d9819ffff869a5 Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Wed, 26 Sep 2012 09:20:41 -0700 Subject: [PATCH 19/33] gps: report session begin/end on gps start/stop Since modem does not consistently send SESSON_END/ENGINE_OFF event, always report SESSION_END on stop gps and SESSION_BEGIN on start gps so that the icon is turned on/off correctly. CRs-fixed: 401664 Change-Id: Ib3954529056a653d7057aedb489be1ccee9eaf1d --- loc_api/libloc_api_50001/loc_eng.cpp | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 5075311e..947e0814 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -536,6 +536,7 @@ static int loc_eng_start_handler(loc_eng_data_s_type &loc_eng_data) ret_val == LOC_API_ADAPTER_ERR_ENGINE_DOWN) { loc_eng_data.client_handle->setInSession(TRUE); + loc_inform_gps_status(loc_eng_data, GPS_STATUS_SESSION_BEGIN); } } @@ -589,8 +590,7 @@ static int loc_eng_stop_handler(loc_eng_data_s_type &loc_eng_data) if (loc_eng_data.client_handle->isInSession()) { ret_val = loc_eng_data.client_handle->stopFix(); - if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS && - loc_eng_data.fix_session_status != GPS_STATUS_SESSION_BEGIN) + if (ret_val == LOC_API_ADAPTER_ERR_SUCCESS) { loc_inform_gps_status(loc_eng_data, GPS_STATUS_SESSION_END); } @@ -787,14 +787,6 @@ static void loc_inform_gps_status(loc_eng_data_s_type &loc_eng_data, GpsStatusVa { CALLBACK_LOG_CALLFLOW("status_cb", %s, loc_get_gps_status_name(gs.status)); loc_eng_data.status_cb(&gs); - - // Restore session begin if needed - if (status == GPS_STATUS_ENGINE_ON && last_status == GPS_STATUS_SESSION_BEGIN) - { - GpsStatus gs_sess_begin = { sizeof(gs_sess_begin),GPS_STATUS_SESSION_BEGIN }; - CALLBACK_LOG_CALLFLOW("status_cb", %s, loc_get_gps_status_name(gs_sess_begin.status)); - loc_eng_data.status_cb(&gs_sess_begin); - } } last_status = status; From 67754118cec93d8032fda2e66901e157373ae407 Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Thu, 27 Sep 2012 22:28:12 -0700 Subject: [PATCH 20/33] ATL call crash fix AgpsStatus added with a couple string fields for wifi which are not NULL ended when they are not used. This get passed to AFW JNI, and allow UTF8 string with the open ended buffer with junks in it. It might cause exception depending on the content of the garbadge. CRs-Fixed: 405473 Change-Id: If762748a4c63fe1be59491b5d08dbadd479176b3 --- loc_api/libloc_api_50001/loc_eng_agps.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/loc_api/libloc_api_50001/loc_eng_agps.h b/loc_api/libloc_api_50001/loc_eng_agps.h index a0873d04..933779bc 100644 --- a/loc_api/libloc_api_50001/loc_eng_agps.h +++ b/loc_api/libloc_api_50001/loc_eng_agps.h @@ -204,7 +204,8 @@ struct Subscriber { inline virtual ~Subscriber() {} virtual void setIPAddresses(int &v4, char* v6) = 0; - inline virtual void setWifiInfo(char* ssid, char* password) {} + inline virtual void setWifiInfo(char* ssid, char* password) + { ssid[0] = 0; password[0] = 0; } inline virtual bool equals(const Subscriber *s) const { return ID == s->ID; } From 5b98ce35cda35d965332e27fbd40a0b46669b7f1 Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Fri, 28 Sep 2012 15:31:11 -0700 Subject: [PATCH 21/33] gps: add support for apq8064 v2 The id for apq8064 v2 is 153 vs apq8064 v1 id of 109, so the id can be either in order to conclude that the device is apq8064 so that GSS can be launched. Change-Id: I8126854f18ba30a1fe46992993185266e9d1db18 CRs-fixed: 405494 --- loc_api/libloc_api_50001/loc.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp index baba3d7c..cca44807 100644 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -216,7 +216,7 @@ static int get_target_name(void) target_name = TARGET_NAME_APQ8064_FUSION3; } else { read_a_line( id, line, LINE_LEN); - if(!strncmp(line, "109", strlen("109"))) { + if(!strncmp(line, "109", strlen("109")) || !strncmp(line, "153", strlen("153"))) { target_name = TARGET_NAME_APQ8064_STANDALONE; } } From 502865cbdf91517eb1a8fc1471ead21640a292fc Mon Sep 17 00:00:00 2001 From: Satheesh Jayakumar Date: Mon, 1 Oct 2012 11:57:20 -0700 Subject: [PATCH 22/33] BIT:Fixes a bug in the pipe ownership for BIT AGPS interface Changes to assign the correct permissions for 'gps" group for Rx path from HAL to BIT daemon Change-Id: I6c5dc4ff0a1379a95888f4d98e88f0174a7a2a79 CRs-Fixed: 400339, 387672 --- loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp | 22 ++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp index f01402a1..112d30f3 100755 --- a/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp +++ b/loc_api/libloc_api_50001/loc_eng_dmn_conn.cpp @@ -72,7 +72,8 @@ static int loc_api_server_proc_init(void *context) result = chown (global_loc_api_q_path, -1, gps_group->gr_gid); if (result != 0) { - LOC_LOGE("chown for pipe failed, gid = %d, result = %d, error = %s\n", gps_group->gr_gid, result, strerror(errno)); + LOC_LOGE("chown for pipe failed, pipe %s, gid = %d, result = %d, error = %s\n", + global_loc_api_q_path, gps_group->gr_gid, result, strerror(errno)); } } else @@ -81,6 +82,25 @@ static int loc_api_server_proc_init(void *context) } loc_api_resp_msgqid = loc_eng_dmn_conn_glue_msgget(global_loc_api_resp_q_path, O_RDWR); + + //change mode/group for the global_loc_api_resp_q_path pipe + result = chmod (global_loc_api_resp_q_path, 0660); + if (result != 0) + { + LOC_LOGE("failed to change mode for %s, error = %s\n", global_loc_api_resp_q_path, strerror(errno)); + } + + if (gps_group != NULL) + { + result = chown (global_loc_api_resp_q_path, -1, gps_group->gr_gid); + if (result != 0) + { + LOC_LOGE("chown for pipe failed, pipe %s, gid = %d, result = %d, error = %s\n", + global_loc_api_resp_q_path, + gps_group->gr_gid, result, strerror(errno)); + } + } + quipc_msgqid = loc_eng_dmn_conn_glue_msgget(global_quipc_ctrl_q_path, O_RDWR); msapm_msgqid = loc_eng_dmn_conn_glue_msgget(global_msapm_ctrl_q_path , O_RDWR); msapu_msgqid = loc_eng_dmn_conn_glue_msgget(global_msapu_ctrl_q_path , O_RDWR); From a389eae611ec3e7cfde8d45939cc7d9aca2eaf42 Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Tue, 11 Sep 2012 15:14:48 -0700 Subject: [PATCH 23/33] dynamically build and load adapter libs this is to support bringup efforts. This change will decouple the dependencies between GPS HAL and proprietary QMI headers, so that we can build HAL without any proprietary repos. Change-Id: I7b836d09f4ac6b1a1bdb38f8d6a2bfb90bb5bf01 --- loc_api/Android.mk | 2 ++ loc_api/libloc_api_50001/Android.mk | 14 ++----------- loc_api/libloc_api_50001/LocApiAdapter.cpp | 23 ++++++++++++++++++++++ loc_api/libloc_api_50001/LocApiAdapter.h | 5 ++++- loc_api/libloc_api_50001/loc_eng.cpp | 2 +- 5 files changed, 32 insertions(+), 14 deletions(-) diff --git a/loc_api/Android.mk b/loc_api/Android.mk index 20ff0727..82aa08bb 100644 --- a/loc_api/Android.mk +++ b/loc_api/Android.mk @@ -13,9 +13,11 @@ GPS_DIR_LIST += $(LOCAL_PATH)/libloc_api/ endif #TARGET_NO_RPC +ifeq (exists, $(shell test -d $(TOP)/vendor/qcom/proprietary/qmi-framework && echo exists)) #add QMI libraries for QMI targets QMI_BOARD_PLATFORM_LIST := msm8960 QMI_BOARD_PLATFORM_LIST += msm8974 +endif ifeq ($(call is-board-platform-in-list,$(QMI_BOARD_PLATFORM_LIST)),true) GPS_DIR_LIST += $(LOCAL_PATH)/loc_api_v02/ diff --git a/loc_api/libloc_api_50001/Android.mk b/loc_api/libloc_api_50001/Android.mk index 0bf889ef..d492120b 100644 --- a/loc_api/libloc_api_50001/Android.mk +++ b/loc_api/libloc_api_50001/Android.mk @@ -19,7 +19,8 @@ LOCAL_MODULE_TAGS := optional LOCAL_SHARED_LIBRARIES := \ libutils \ libcutils \ - libgps.utils + libgps.utils \ + libdl LOCAL_SRC_FILES += \ loc_eng_log.cpp \ @@ -79,17 +80,6 @@ LOCAL_SRC_FILES += \ loc_eng_dmn_conn_glue_msg.c \ loc_eng_dmn_conn_glue_pipe.c -# if QMI is supported then link to loc_api_v02 -ifeq ($(call is-board-platform-in-list,$(QMI_BOARD_PLATFORM_LIST)),true) -LOCAL_SHARED_LIBRARIES += libloc_api_v02 -else -## Check if RPC is not unsupported -ifneq ($(TARGET_NO_RPC),true) -LOCAL_SHARED_LIBRARIES += libloc_api-rpc-qc -endif #TARGET_NO_RPC - -endif #is-board-platform-in-list - LOCAL_CFLAGS += \ -fno-short-enums \ -D_ANDROID_ diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp index 6bd79bbe..950c6438 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.cpp +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -29,6 +29,7 @@ #define LOG_NDDEBUG 0 #define LOG_TAG "LocSvc_adapter" +#include #include #include "loc_eng_msg.h" #include "loc_log.h" @@ -67,6 +68,28 @@ LocApiAdapter::~LocApiAdapter() LOC_LOGV("LocApiAdapter deleted"); } +LocApiAdapter* LocApiAdapter::getLocApiAdapter(LocEng &locEng) +{ + void* handle; + LocApiAdapter* adapter = NULL; + + handle = dlopen ("libloc_api_v02.so", RTLD_NOW); + + if (!handle) { + handle = dlopen ("libloc_api-rpc-qc.so", RTLD_NOW); + } + + if (!handle) { + adapter = new LocApiAdapter(locEng); + } else { + getLocApiAdapter_t* getHandle = (getLocApiAdapter_t*)dlsym(handle, "getLocApiAdapter"); + + adapter = (*getHandle)(locEng); + } + + return adapter; +} + int LocApiAdapter::hexcode(char *hexstring, int string_size, const char *data, int data_size) { diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h index 80a675d8..ec53805e 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -115,6 +115,8 @@ public: //LocApiAdapter(int q, reportCb_t[LOC_API_ADAPTER_EVENT_MAX] callbackTable); virtual ~LocApiAdapter(); + static LocApiAdapter* getLocApiAdapter(LocEng &locEng); + static int hexcode(char *hexstring, int string_size, const char *data, int data_size); static int decodeAddress(char *addr_string, int string_size, @@ -221,7 +223,8 @@ public: inline virtual void setInSession(bool inSession) { navigating = inSession; } }; -LocApiAdapter* getLocApiAdapter(LocEng &locEng); +extern "C" LocApiAdapter* getLocApiAdapter(LocEng &locEng); +typedef LocApiAdapter* (getLocApiAdapter_t)(LocEng&); #endif //LOC_API_RPC_ADAPTER_H diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index aa9298d5..89a77292 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -319,7 +319,7 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, LocEng locEngHandle(&loc_eng_data, event, loc_eng_data.acquire_wakelock_cb, loc_eng_data.release_wakelock_cb, loc_eng_msg_sender, loc_external_msg_sender, callbacks->location_ext_parser, callbacks->sv_ext_parser); - loc_eng_data.client_handle = getLocApiAdapter(locEngHandle); + loc_eng_data.client_handle = LocApiAdapter::getLocApiAdapter(locEngHandle); int ret_val =-1; if (NULL == loc_eng_data.client_handle) { From 0eaa3bab7e314dbdb4688d21cab282c84e5f572f Mon Sep 17 00:00:00 2001 From: Satheesh Jayakumar Date: Tue, 9 Oct 2012 20:50:06 -0700 Subject: [PATCH 24/33] BIT:Fixes a bug in HAL for AGPS operation for SGLTE Enhances HAL to launch the Daemon connection server for SGLTE targets too. CRs-Fixed: 409237 Change-Id: I70116eb1f96b8b4dbe39f57dfceb1ab02ef65e4d --- loc_api/libloc_api_50001/loc_eng.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 89a77292..da10c714 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -870,10 +870,14 @@ void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbac char baseband[PROPERTY_VALUE_MAX]; property_get("ro.baseband", baseband, "msm"); if ((strcmp(baseband,"svlte2a") == 0) || + (strcmp(baseband,"sglte") == 0) || (strcmp(baseband,"msm") == 0)) { loc_eng_dmn_conn_loc_api_server_launch(callbacks->create_thread_cb, NULL, NULL, &loc_eng_data); + } else { + LOC_LOGD("%s:%d] loc_eng_dmn_conn_loc_api_server was not initialized.baseband = %s\n", + __func__, __LINE__, baseband); } } #endif /* FEATURE_GNSS_BIT_API */ From 2051ffae1f509a1b31e5a6bcf170cecf500376de Mon Sep 17 00:00:00 2001 From: Tushar Janefalkar Date: Mon, 8 Oct 2012 15:41:32 -0700 Subject: [PATCH 25/33] Service modem's request for NTP time Previously, modem's request for NTP time was not supported. This change enables that request to be serviced through the HAL and current NTP time is injected into the modem CRs-Fixed: 406357 Change-Id: I471f98cf57a276902d7991da48cf7244fe798318 --- loc_api/libloc_api_50001/LocApiAdapter.cpp | 6 +++--- loc_api/libloc_api_50001/loc.cpp | 4 ++-- loc_api/libloc_api_50001/loc.h | 1 + loc_api/libloc_api_50001/loc_eng.cpp | 11 +++++++++-- loc_api/libloc_api_50001/loc_eng.h | 1 + 5 files changed, 16 insertions(+), 7 deletions(-) diff --git a/loc_api/libloc_api_50001/LocApiAdapter.cpp b/loc_api/libloc_api_50001/LocApiAdapter.cpp index 950c6438..4bd2ec76 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.cpp +++ b/loc_api/libloc_api_50001/LocApiAdapter.cpp @@ -201,9 +201,9 @@ void LocApiAdapter::requestXtraData() void LocApiAdapter::requestTime() { - LOC_LOGD("loc_event_cb: XTRA time download request... not supported"); - // loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_REQUEST_TIME)); - // locEngHandle.sendMsge(locEngHandle.owner, msg); + LOC_LOGD("loc_event_cb: XTRA time download request"); + loc_eng_msg *msg(new loc_eng_msg(locEngHandle.owner, LOC_ENG_MSG_REQUEST_TIME)); + locEngHandle.sendMsge(locEngHandle.owner, msg); } void LocApiAdapter::requestLocation() diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp index cca44807..f78d8070 100644 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -334,7 +334,8 @@ static int loc_init(GpsCallbacks* callbacks) callbacks->release_wakelock_cb, /* release_wakelock_cb */ callbacks->create_thread_cb, /* create_thread_cb */ NULL, /* location_ext_parser */ - NULL /* sv_ext_parser */}; + NULL, /* sv_ext_parser */ + callbacks->request_utc_time_cb /* request_utc_time_cb */}; gps_loc_cb = callbacks->location_cb; gps_sv_cb = callbacks->sv_status_cb; @@ -499,7 +500,6 @@ static int loc_inject_time(GpsUtcTime time, int64_t timeReference, int uncertain { ENTRY_LOG(); int ret_val = loc_eng_inject_time(loc_afw_data, time, timeReference, uncertainty); - EXIT_LOG(%d, ret_val); return ret_val; } diff --git a/loc_api/libloc_api_50001/loc.h b/loc_api/libloc_api_50001/loc.h index 17f6ab70..b823e476 100755 --- a/loc_api/libloc_api_50001/loc.h +++ b/loc_api/libloc_api_50001/loc.h @@ -72,6 +72,7 @@ typedef struct { gps_create_thread create_thread_cb; loc_ext_parser location_ext_parser; loc_ext_parser sv_ext_parser; + gps_request_utc_time request_utc_time_cb; } LocCallbacks; enum loc_sess_status { diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 89a77292..a1fc6d57 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -298,7 +298,7 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, loc_eng_data.nmea_cb = callbacks->nmea_cb; loc_eng_data.acquire_wakelock_cb = callbacks->acquire_wakelock_cb; loc_eng_data.release_wakelock_cb = callbacks->release_wakelock_cb; - + loc_eng_data.request_utc_time_cb = callbacks->request_utc_time_cb; loc_eng_data.intermediateFix = gps_conf.INTERMEDIATE_POS; // initial states taken care of by the memset above @@ -683,7 +683,6 @@ int loc_eng_inject_time(loc_eng_data_s_type &loc_eng_data, GpsUtcTime time, uncertainty)); msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, msg, loc_eng_free_msg); - EXIT_LOG(%d, 0); return 0; } @@ -1682,6 +1681,14 @@ static void loc_eng_deferred_action_thread(void* arg) break; case LOC_ENG_MSG_REQUEST_TIME: + if (loc_eng_data_p->request_utc_time_cb != NULL) + { + loc_eng_data_p->request_utc_time_cb(); + } + else + { + LOC_LOGE("%s] ERROR: Callback function for request_time is NULL", __func__); + } break; case LOC_ENG_MSG_REQUEST_POSITION: diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h index 1b9dcf58..646d1716 100644 --- a/loc_api/libloc_api_50001/loc_eng.h +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -106,6 +106,7 @@ typedef struct gps_ni_notify_callback ni_notify_cb; gps_acquire_wakelock acquire_wakelock_cb; gps_release_wakelock release_wakelock_cb; + gps_request_utc_time request_utc_time_cb; ulp_network_location_request ulp_network_callback; ulp_request_phone_context ulp_phone_context_req_cb; boolean intermediateFix; From d6c87927692d41305be7fd5f94c967911180c7d1 Mon Sep 17 00:00:00 2001 From: Tushar Janefalkar Date: Tue, 9 Oct 2012 15:03:19 -0700 Subject: [PATCH 26/33] Remove interpretation of LPP config parameter Instead of having a switch case that sets bits in the lppconfig mask, the mask is assigned whatever value was read from gps.conf. The advantage of this being that if in the future additional bits are added in lppconfig, there need not be a code change; only comments in gps.conf have to be updated to inform the correct value for those additional bits CRs-Fixed: 406969 Change-Id: I979151b44cd85e98b59b4586fdd49e20a7d7c82b --- loc_api/loc_api_v02/LocApiV02Adapter.cpp | 25 +----------------------- 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 63eeb6c4..4c7b7124 100755 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1185,31 +1185,8 @@ enum loc_api_adapter_err LocApiV02Adapter :: setLPPConfig(uint32_t profile) memset(&lpp_config_ind, 0, sizeof(lpp_config_ind)); lpp_config_req.lppConfig_valid = 1; - // Default RRLP or User or Control plane configuration - switch(profile) - { - /* RRLP */ - case 0: - lpp_config_req.lppConfig = profile; - break; - /* User plane */ - case 1: - lpp_config_req.lppConfig = QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02; - break; - - case 2: - lpp_config_req.lppConfig = QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02; - break; - - default: - LOC_LOGE("%s:%d]: Invalid LPP Profile Config Setting Provided in gps.conf = %d!", - __FUNCTION__, - __LINE__, - profile); - return LOC_API_ADAPTER_ERR_INVALID_PARAMETER; - break; - } + lpp_config_req.lppConfig = profile; req_union.pSetProtocolConfigParametersReq = &lpp_config_req; From 0529b2b9bb54a1b7cd23741e5ef8101ee3d8bf52 Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Wed, 17 Oct 2012 14:49:56 -0700 Subject: [PATCH 27/33] XTWiFi: disable coarse position injection when XTWiFi NLP is in use Disable coarse position injection from GPS HAL when XTWiFi Network Location Provider is in use. This is needed to avoid self learning loop inside modem. Change-Id: I0526317221d3490c41d0d8d901fbfa4d93e9a0b0 CRs-Fixed: 409409 --- loc_api/libloc_api_50001/loc.cpp | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) mode change 100644 => 100755 loc_api/libloc_api_50001/loc.cpp diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp old mode 100644 new mode 100755 index f78d8070..8ac78625 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -41,6 +41,8 @@ #include #include +#include + //Globals defns static const ulpInterface * loc_eng_ulp_inf = NULL; static const ulpInterface * loc_eng_get_ulp_inf(void); @@ -523,9 +525,32 @@ SIDE EFFECTS ===========================================================================*/ static int loc_inject_location(double latitude, double longitude, float accuracy) { + static bool initialized = false; + static bool enable_cpi = true; ENTRY_LOG(); - int ret_val = loc_eng_inject_location(loc_afw_data, latitude, longitude, accuracy); + if(!initialized) + { + char value[PROPERTY_VALUE_MAX]; + memset(value, 0, sizeof(value)); + (void)property_get("persist.gps.qc_nlp_in_use", value, "0"); + if(0 == strcmp(value, "1")) + { + enable_cpi = false; + LOC_LOGI("GPS HAL coarse position injection disabled"); + } + else + { + LOC_LOGI("GPS HAL coarse position injection enabled"); + } + initialized = true; + } + + int ret_val = 0; + if(enable_cpi) + { + ret_val = loc_eng_inject_location(loc_afw_data, latitude, longitude, accuracy); + } EXIT_LOG(%d, ret_val); return ret_val; } From 5f45c04c890fbf9657e3a442f7094c25c59ee99f Mon Sep 17 00:00:00 2001 From: Nitin Singh Date: Thu, 1 Nov 2012 14:34:36 -0700 Subject: [PATCH 28/33] Loc api v02 support for QMI_LOC rev 2.17 changes to suuport pedometer and motion data control API Change-Id: I56c87adaa1f717c76bf1ff6eb2d195c92acbd38d --- loc_api/loc_api_v02/loc_api_v02_client.c | 46 +- loc_api/loc_api_v02/loc_api_v02_client.h | 28 + loc_api/loc_api_v02/loc_api_v02_log.c | 20 + loc_api/loc_api_v02/location_service_v02.c | 6178 +++---- loc_api/loc_api_v02/location_service_v02.h | 16478 ++++++++++--------- 5 files changed, 11780 insertions(+), 10970 deletions(-) diff --git a/loc_api/loc_api_v02/loc_api_v02_client.c b/loc_api/loc_api_v02/loc_api_v02_client.c index 6e60b604..592e3f59 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.c +++ b/loc_api/loc_api_v02/loc_api_v02_client.c @@ -159,7 +159,17 @@ static locClientEventIndTableStructT locClientEventIndTable[]= { //Geofence Breach event { QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), - QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02} + QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02}, + + //Pedometer Control event + { QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02, + sizeof(qmiLocEventPedometerControlIndMsgT_v02), + QMI_LOC_EVENT_MASK_PEDOMETER_CONTROL_V02 }, + + //Motion Data Control event + { QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02, + sizeof(qmiLocEventMotionDataControlIndMsgT_v02), + QMI_LOC_EVENT_MASK_MOTION_DATA_CONTROL_V02 } }; /* table to relate the respInd Id with its size */ @@ -384,7 +394,7 @@ static locClientRespIndTableStructT locClientRespIndTable[]= { //Inject GSM Cell Info { QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, - sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02)}, + sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02)}, //Inject Network Initiated Message { QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, @@ -392,7 +402,11 @@ static locClientRespIndTableStructT locClientRespIndTable[]= { //WWAN Out of Service Notification { QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, - sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02)} + sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02)}, + + //Pedomete Report + { QMI_LOC_PEDOMETER_REPORT_IND_V02, + sizeof(qmiLocPedometerReportIndMsgT_v02)} }; @@ -824,6 +838,20 @@ static bool locClientHandleIndication( break; } + case QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02 : + { + //locClientHandlePedometerControlInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + + case QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02: + { + //locClientHandleMotionDataControlInd(user_handle, msg_id, ind_buf, ind_buf_len); + status = true; + break; + } + //------------------------------------------------------------------------- // handle the response indications @@ -995,6 +1023,12 @@ static bool locClientHandleIndication( break; } + case QMI_LOC_PEDOMETER_REPORT_IND_V02: + { + status = true; + break; + } + // for indications that only have a "status" field case QMI_LOC_NI_USER_RESPONSE_IND_V02: case QMI_LOC_INJECT_UTC_TIME_IND_V02: @@ -1534,6 +1568,7 @@ static bool validateRequest( *pOutLen = sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02); break; } + case QMI_LOC_INJECT_MOTION_DATA_REQ_V02: { *pOutLen = sizeof(qmiLocInjectMotionDataReqMsgT_v02); @@ -1558,6 +1593,11 @@ static bool validateRequest( break; } + case QMI_LOC_PEDOMETER_REPORT_REQ_V02: + { + *pOutLen = sizeof(qmiLocPedometerReportReqMsgT_v02); + break; + } // ALL requests with no payload case QMI_LOC_GET_SERVICE_REVISION_REQ_V02: diff --git a/loc_api/loc_api_v02/loc_api_v02_client.h b/loc_api/loc_api_v02/loc_api_v02_client.h index a49f1275..97298782 100644 --- a/loc_api/loc_api_v02/loc_api_v02_client.h +++ b/loc_api/loc_api_v02/loc_api_v02_client.h @@ -600,6 +600,16 @@ typedef union QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 */ const void *pWWANOutOfServiceNotificationReq; + + const qmiLocPedometerReportReqMsgT_v02 *pPedometerReportReq; + /**< Send pedometer data to the location engine. If the request is + accepted by the service, the client receives the following + indication containing a response: + QMI_LOC_PEDOMETER_REPORT_IND_V02 + + To send this request, set the reqId field in locClientSendReq() to + QMI_LOC_PEDOMETER_REPORT_REQ_V02 */ + }locClientReqUnionType; @@ -750,6 +760,18 @@ typedef union The eventIndId field in the event indication callback is set to QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02. @newpagetable */ + const qmiLocEventPedometerControlIndMsgT_v02* pPedometerControlEvent; + /**< Sent by the engine to recommend how pedometer data is sent to the + location engine. + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02. @newpagetable */ + + const qmiLocEventMotionDataControlIndMsgT_v02* pMotionDataControlEvent; + /**< Sent by the engine to recommend how motion data is sent to the + location engine. + The eventIndId field in the event indication callback is set to + QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02. @newpagetable */ + }locClientEventIndUnionType; @@ -1124,6 +1146,12 @@ typedef union The respIndId field in the response indication callback is set to QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02. */ + const qmiLocPedometerReportIndMsgT_v02* pPedometerReportInd; + + /**< Response to the QMI_LOC_PEDOMETER_REPORT_REQ_V02 request. + The respIndId field in the response indication callback is set to + QMI_LOC_PEDOMETER_REPORT_IND_V02. */ + }locClientRespIndUnionType; /** @} */ /* end_addtogroup data_types */ diff --git a/loc_api/loc_api_v02/loc_api_v02_log.c b/loc_api/loc_api_v02/loc_api_v02_log.c index 6f60ee58..7a4f4a66 100644 --- a/loc_api/loc_api_v02/loc_api_v02_log.c +++ b/loc_api/loc_api_v02/loc_api_v02_log.c @@ -209,6 +209,26 @@ static loc_name_val_s_type loc_v02_event_name[] = NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02), NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02), NAME_VAL(QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02), + NAME_VAL(QMI_LOC_INJECT_MOTION_DATA_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_MOTION_DATA_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_MOTION_DATA_IND_V02), + NAME_VAL(QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02), + NAME_VAL(QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02), + NAME_VAL(QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02), + NAME_VAL(QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02), + NAME_VAL(QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02), + NAME_VAL(QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02), + NAME_VAL(QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02), + NAME_VAL(QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02), + NAME_VAL(QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02), + NAME_VAL(QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02), + NAME_VAL(QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02), + NAME_VAL(QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02), + NAME_VAL(QMI_LOC_PEDOMETER_REPORT_REQ_V02), + NAME_VAL(QMI_LOC_PEDOMETER_REPORT_RESP_V02), + NAME_VAL(QMI_LOC_PEDOMETER_REPORT_IND_V02) }; static int loc_v02_event_num = sizeof(loc_v02_event_name) / sizeof(loc_name_val_s_type); diff --git a/loc_api/loc_api_v02/location_service_v02.c b/loc_api/loc_api_v02/location_service_v02.c index 47a63eea..ae465714 100755 --- a/loc_api/loc_api_v02/location_service_v02.c +++ b/loc_api/loc_api_v02/location_service_v02.c @@ -26,3000 +26,3184 @@ * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - - L O C A T I O N _ S E R V I C E _ V 0 2 . C - -GENERAL DESCRIPTION - This is the file which defines the loc service Data structures. - - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ - -/* This file was generated with Tool version 5.5 - It was generated on: Thu Sep 27 2012 - From IDL File: location_service_v02.idl */ - -#include "stdint.h" -#include "qmi_idl_lib_internal.h" -#include "location_service_v02.h" -#include "common_v01.h" - - -/*Type Definitions*/ -static const uint8_t qmiLocApplicationIdStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationProvider), - QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02, - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationName), - QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02, - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion_valid), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion), - QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsTimeOfWeekMs), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocDOPStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, PDOP), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, HDOP), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, VDOP), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorUsageIndicatorStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, usageMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, aidingIndicatorMask), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSvInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, validMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, system), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, gnssSvId), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, healthStatus), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svStatus), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svInfoMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, elevation), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, azimuth), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, snr), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQosIncl), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQos), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, numFixes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, timeBetweenFixes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posMode), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), - QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiVxNotifyVerifyStructT_v02, userRespTimerInSeconds), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), - QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplQopStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, validMask), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, horizontalAccuracy), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, verticalAccuracy), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, maxLocAge), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, delay), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, addr), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, port), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), - QMI_LOC_IPV6_ADDR_LENGTH_V02, - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, port), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, suplServerAddrTypeMask), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), - 8, 0, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), - 9, 0, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, valid_flags), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), - 10, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), - QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), - QMI_LOC_NI_SUPL_HASH_LENGTH_V02, - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, posMethod), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), - 6, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), - 6, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), - 7, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), - QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, valid_flags), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, invokeId), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), - QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), - QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, locationType), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), - 12, 0, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), - 12, 0, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, userResponseTimer), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), - 5, 0, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), - QMI_LOC_MAX_NTP_SERVERS_V02, - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), - 16, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxFileSizeInBytes), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxPartSize), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), - QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), - 16, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorControlConfigSamplingSpecStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, samplesPerBatch), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, batchesPerSecond), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, injectEnable), - - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), - 20, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGeofencePositionStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, timestampUtc), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, latitude), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, longitude), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMinor), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMajor), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading_valid), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocPredictedOrbitsDataValidityStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, startTimeInUTC), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, durationHours), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocAltitudeSrcInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, source), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, linkage), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, coverage), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocDeleteSvInfoStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, gnssSvId), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, system), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, deleteSvInfoMask), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiFixTimeStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixTimeStructT_v02, wifiPositionTime), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lat), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lon), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, hepe), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, numApsUsed), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, fixErrorCode), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { - QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), - QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, rssi), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, channel), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, apQualifier), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLoc3AxisSensorSampleStructT_data_v02[] = { - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, timeOffset), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, xAxis), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, yAxis), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, zAxis), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, timeOfFirstSample), - - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), - QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), - 29, 0, - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), - - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), - QMI_LOC_MAX_APN_NAME_LENGTH_V02, - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, latitude), - - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, longitude), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, radius), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocMotionDataStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_mode), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, probability_of_state), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, age), - - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, timeout), - - QMI_IDL_FLAG_END_VALUE -}; - -static const uint8_t qmiLocGSMCellIdStructT_data_v02[] = { - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MCC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MNC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, LAC), - - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, CID), - - QMI_IDL_FLAG_END_VALUE -}; - -/*Message Definitions*/ -static const uint8_t qmiLocGenRespMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGenRespMsgT_v02, resp), - 0, 1 -}; - -static const uint8_t qmiLocInformClientRevisionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformClientRevisionReqMsgT_v02, revision) -}; - -static const uint8_t qmiLocRegEventsReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocRegEventsReqMsgT_v02, eventRegMask) -}; - -static const uint8_t qmiLocStartReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, sessionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId), - 0, 0 -}; - -static const uint8_t qmiLocStopReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocStopReqMsgT_v02, sessionId) -}; - -static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionStatus), - - 0x02, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence_valid)), - 0x16, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal_valid)), - 0x18, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x1A, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x1B, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc_valid)), - 0x1C, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence_valid)), - 0x1D, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability_valid)), - 0x1E, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical_valid)), - 0x1F, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading_valid)), - 0x20, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc_valid)), - 0x21, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation_valid)), - 0x22, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask_valid)), - 0x23, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP_valid)), - 0x24, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), - 2, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), - 0x25, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds_valid)), - 0x26, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime_valid)), - 0x27, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), - 1, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), - 0x28, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc_valid)), - 0x29, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, timeSrc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage_valid)), - 0x2A, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), - 3, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), - 0x2B, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_valid)), - 0x2C, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList), - QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_len) -}; - -static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, altitudeAssumed), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), - QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), - 4, 0 -}; - -static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), - QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 -}; - -static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, notificationType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd) - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), - 5, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), - 11, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), - 13, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), - 14, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd_valid)), - 0x14, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), - 15, 0 -}; - -static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo) - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), - 17, 0 -}; - -static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), - 18, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), - 19, 0 -}; - -static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, latitude), - - 0x02, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, longitude), - - 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x04, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, timestampUtc) -}; - -static const uint8_t qmiLocEventEngineStateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventEngineStateIndMsgT_v02, engineState) -}; - -static const uint8_t qmiLocEventFixSessionStateIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) -}; - -static const uint8_t qmiLocEventWifiReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, requestType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs_valid)), - 0x10, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) -}; - -static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), - 21, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), - 21, 0 -}; - -static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventTimeSyncReqIndMsgT_v02, refCounter) -}; - -static const uint8_t qmiLocEventSetSpiStreamingReportIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEventSetSpiStreamingReportIndMsgT_v02, enable) -}; - -static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, connHandle), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, requestType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) -}; - -static const uint8_t qmiLocEventNiGeofenceNotificationIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, operationType) -}; - -static const uint8_t qmiLocEventGeofenceGenAlertIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceGenAlertIndMsgT_v02, geofenceAlert) -}; - -static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofenceId), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, breachType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition) - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), - 22, 0 -}; - -/* - * qmiLocGetServiceRevisionReqMsgT is empty - * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString), - QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString_valid)), - 0x11, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString), - QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_STRING, - QMI_IDL_OFFSET16ARRAY(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString), - QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 -}; - -/* - * qmiLocGetFixCriteriaReqMsgT is empty - * static const uint8_t qmiLocGetFixCriteriaReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId_valid)), - 0x13, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId), - 0, 0 -}; - -static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, userResp), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, notificationType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload) - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), - 5, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), - 11, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), - 13, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), - 14, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload_valid)), - 0x14, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), - 15, 0 -}; - -static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNiUserRespIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalSize), - - 0x02, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalParts), - - 0x03, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partNum), - - 0x04, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData), - ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) & 0xFF), ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData_len), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType_valid)), - 0x10, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) -}; - -static const uint8_t qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum_valid)), - 0x10, - QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) -}; - -/* - * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty - * static const uint8_t qmiLocGetPredictedOrbitsDataSourceReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), - 18, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), - 19, 0 -}; - -/* - * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty - * static const uint8_t qmiLocGetPredictedOrbitsDataValidityReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), - 23, 0 -}; - -static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUtc), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUnc) -}; - -static const uint8_t qmiLocInjectUtcTimeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectUtcTimeIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence_valid)), - 0x13, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x16, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence_valid)), - 0x18, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo_valid)), - 0x1A, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), - 24, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), - 0x1B, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge_valid)), - 0x1C, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc_valid)), - 0x1D, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) -}; - -static const uint8_t qmiLocInjectPositionIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectPositionIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetEngineLockReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetEngineLockReqMsgT_v02, lockType) -}; - -static const uint8_t qmiLocSetEngineLockIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetEngineLockIndMsgT_v02, status) -}; - -/* - * qmiLocGetEngineLockReqMsgT is empty - * static const uint8_t qmiLocGetEngineLockReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetEngineLockIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) -}; - -static const uint8_t qmiLocSetSbasConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSbasConfigReqMsgT_v02, sbasConfig) -}; - -static const uint8_t qmiLocSetSbasConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSbasConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetSbasConfigReqMsgT is empty - * static const uint8_t qmiLocGetSbasConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSbasConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) -}; - -static const uint8_t qmiLocSetNmeaTypesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetNmeaTypesReqMsgT_v02, nmeaSentenceType) -}; - -static const uint8_t qmiLocSetNmeaTypesIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetNmeaTypesIndMsgT_v02, status) -}; - -/* - * qmiLocGetNmeaTypesReqMsgT is empty - * static const uint8_t qmiLocGetNmeaTypesReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetNmeaTypesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) -}; - -static const uint8_t qmiLocSetLowPowerModeReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetLowPowerModeReqMsgT_v02, lowPowerMode) -}; - -static const uint8_t qmiLocSetLowPowerModeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetLowPowerModeIndMsgT_v02, status) -}; - -/* - * qmiLocGetLowPowerModeReqMsgT is empty - * static const uint8_t qmiLocGetLowPowerModeReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetLowPowerModeIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) -}; - -static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), - 8, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), - 9, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 -}; - -static const uint8_t qmiLocSetServerIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetServerIndMsgT_v02, status) -}; - -static const uint8_t qmiLocGetServerReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) -}; - -static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, status), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, serverType), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), - 8, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), - 9, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), - QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 -}; - -static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteAllFlag), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), - 0x10, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), - QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), - 25, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), - 0x11, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) -}; - -static const uint8_t qmiLocDeleteAssistDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetXtraTSessionControlReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlReqMsgT_v02, xtraTSessionControl) -}; - -static const uint8_t qmiLocSetXtraTSessionControlIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlIndMsgT_v02, status) -}; - -/* - * qmiLocGetXtraTSessionControlReqMsgT is empty - * static const uint8_t qmiLocGetXtraTSessionControlReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetXtraTSessionControlIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) -}; - -static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), - 26, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), - 27, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), - 0x12, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), - QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), - 28, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), - 0x13, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) -}; - -static const uint8_t qmiLocInjectWifiPositionIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionIndMsgT_v02, status) -}; - -static const uint8_t qmiLocNotifyWifiStatusReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusReqMsgT_v02, wifiStatus) -}; - -static const uint8_t qmiLocNotifyWifiStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusIndMsgT_v02, status) -}; - -/* - * qmiLocGetRegisteredEventsReqMsgT is empty - * static const uint8_t qmiLocGetRegisteredEventsReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetRegisteredEventsIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) -}; - -static const uint8_t qmiLocSetOperationModeReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetOperationModeReqMsgT_v02, operationMode) -}; - -static const uint8_t qmiLocSetOperationModeIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetOperationModeIndMsgT_v02, status) -}; - -/* - * qmiLocGetOperationModeReqMsgT is empty - * static const uint8_t qmiLocGetOperationModeReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetOperationModeIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) -}; - -static const uint8_t qmiLocSetSpiStatusReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, stationary), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) -}; - -static const uint8_t qmiLocSetSpiStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSpiStatusIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), - 30, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), - 0x12, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), - 30, 0 -}; - -static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) -}; - -static const uint8_t qmiLocInjectTimeSyncDataReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, refCounter), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcRxTime), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcTxTime) -}; - -static const uint8_t qmiLocInjectTimeSyncDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataIndMsgT_v02, status) -}; - -/* - * qmiLocGetCradleMountConfigReqMsgT is empty - * static const uint8_t qmiLocGetCradleMountConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetCradleMountConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) -}; - -static const uint8_t qmiLocSetCradleMountConfigReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, cradleMountState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) -}; - -static const uint8_t qmiLocSetCradleMountConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetExternalPowerConfigReqMsgT is empty - * static const uint8_t qmiLocGetExternalPowerConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetExternalPowerConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) -}; - -static const uint8_t qmiLocSetExternalPowerConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigReqMsgT_v02, externalPowerState) -}; - -static const uint8_t qmiLocSetExternalPowerConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, connHandle), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, requestType), - - 0x03, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, statusType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile) - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile_valid)), - 0x10, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), - 31, 0 -}; - -static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) -}; - -static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask_valid)), - 0x10, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) -}; - -static const uint8_t qmiLocGetProtocolConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersReqMsgT_v02, getProtocolConfigParamMask) -}; - -static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) -}; - -static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) -}; - -static const uint8_t qmiLocSetSensorControlConfigIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigIndMsgT_v02, status) -}; - -/* - * qmiLocGetSensorControlConfigReqMsgT is empty - * static const uint8_t qmiLocGetSensorControlConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) -}; - -static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) -}; - -static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) -}; - -static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesReqMsgT_v02, getSensorPropertiesMask) -}; - -static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) -}; - -static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), - 0x12, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), - 20, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), - 0x15, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), - 20, 0 -}; - -static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) -}; - -/* - * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty - * static const uint8_t qmiLocGetSensorPerformanceControlConfigReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec_valid)), - 0x11, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), - 0x12, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), - 20, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), - 20, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), - 0x15, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), - 20, 0 -}; - -static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData), - ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData) - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData_len) -}; - -static const uint8_t qmiLocInjectSuplCertificateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateIndMsgT_v02, status) -}; - -static const uint8_t qmiLocDeleteSuplCertificateReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) -}; - -static const uint8_t qmiLocDeleteSuplCertificateIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateIndMsgT_v02, status) -}; - -static const uint8_t qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) -}; - -static const uint8_t qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) -}; - -static const uint8_t qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersReqMsgT_v02, getPositionEngineConfigParamMask) -}; - -static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl_valid)), - 0x10, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData_valid)), - 0x12, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) -}; - -static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, transactionId), - - 0x02, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), - 32, 0, - - 0x03, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, breachMask), - - 0x04, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, includePosition), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) -}; - -static const uint8_t qmiLocAddCircularGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) -}; - -static const uint8_t qmiLocDeleteGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocDeleteGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocQueryGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs_valid)), - 0x14, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), - 32, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) -}; - -static const uint8_t qmiLocEditGeofenceReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceId), - - 0x02, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask_valid)), - 0x11, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) -}; - -static const uint8_t qmiLocEditGeofenceIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId_valid)), - 0x11, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams_valid)), - 0x12, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) -}; - -static const uint8_t qmiLocGetBestAvailablePositionReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude_valid)), - 0x11, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude_valid)), - 0x12, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular_valid)), - 0x13, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid_valid)), - 0x14, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc_valid)), - 0x15, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc_valid)), - 0x16, - QMI_IDL_GENERIC_8_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc_valid)), - 0x17, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor_valid)), - 0x18, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor_valid)), - 0x19, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), - 0x1A, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence_valid)), - 0x1B, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence_valid)), - 0x1C, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability_valid)), - 0x1D, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed_valid)), - 0x1E, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc_valid)), - 0x1F, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), - 0x20, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence_valid)), - 0x21, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability_valid)), - 0x22, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed_valid)), - 0x23, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc_valid)), - 0x24, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading_valid)), - 0x25, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc_valid)), - 0x26, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation_valid)), - 0x27, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask_valid)), - 0x28, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP_valid)), - 0x29, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP), - 2, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime_valid)), - 0x2A, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime), - 1, 0, - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc_valid)), - 0x2B, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage_valid)), - 0x2C, - QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage), - 3, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_valid)), - 0x2D, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, - QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList), - QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) -}; - -static const uint8_t qmiLocInjectMotionDataReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectMotionDataReqMsgT_v02, motion_data), - 33, 0 -}; - -static const uint8_t qmiLocInjectMotionDataIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectMotionDataIndMsgT_v02, status) -}; - -static const uint8_t qmiLocGetNiGeofenceIdListReqMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListReqMsgT_v02, transactionId) -}; - -static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, status), - - QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId_valid)), - 0x10, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId), - - QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_valid)), - 0x11, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList), - QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02, - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) -}; - -static const uint8_t qmiLocInjectGSMCellInfoReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_AGGREGATE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, gsmCellId), - 34, 0, - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, roamingStatus) -}; - -static const uint8_t qmiLocInjectGSMCellInfoIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoIndMsgT_v02, status) -}; - -static const uint8_t qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02[] = { - 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessageType), - - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, - QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage), - ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) >> 8), - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage) - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage_len) -}; - -static const uint8_t qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02, status) -}; - -/* - * qmiLocWWANOutOfServiceNotificationReqMsgT is empty - * static const uint8_t qmiLocWWANOutOfServiceNotificationReqMsgT_data_v02[] = { - * }; - */ - -static const uint8_t qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02[] = { - QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, - QMI_IDL_GENERIC_4_BYTE, - QMI_IDL_OFFSET8(qmiLocWWANOutOfServiceNotificationIndMsgT_v02, status) -}; - -/* Type Table */ -static const qmi_idl_type_table_entry loc_type_table_v02[] = { - {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, - {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, - {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, - {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, - {sizeof(qmiLocSvInfoStructT_v02), qmiLocSvInfoStructT_data_v02}, - {sizeof(qmiLocNiVxNotifyVerifyStructT_v02), qmiLocNiVxNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiSuplFormattedStringStructT_v02), qmiLocNiSuplFormattedStringStructT_data_v02}, - {sizeof(qmiLocNiSuplQopStructT_v02), qmiLocNiSuplQopStructT_data_v02}, - {sizeof(qmiLocIpV4AddrStructType_v02), qmiLocIpV4AddrStructType_data_v02}, - {sizeof(qmiLocIpV6AddrStructType_v02), qmiLocIpV6AddrStructType_data_v02}, - {sizeof(qmiLocNiSuplServerInfoStructT_v02), qmiLocNiSuplServerInfoStructT_data_v02}, - {sizeof(qmiLocNiSuplNotifyVerifyStructT_v02), qmiLocNiSuplNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, - {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, - {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, - {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, - {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, - {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, - {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, - {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, - {sizeof(qmiLocGeofencePositionStructT_v02), qmiLocGeofencePositionStructT_data_v02}, - {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, - {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, - {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, - {sizeof(qmiLocWifiFixTimeStructT_v02), qmiLocWifiFixTimeStructT_data_v02}, - {sizeof(qmiLocWifiFixPosStructT_v02), qmiLocWifiFixPosStructT_data_v02}, - {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, - {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, - {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, - {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, - {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, - {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02}, - {sizeof(qmiLocGSMCellIdStructT_v02), qmiLocGSMCellIdStructT_data_v02} -}; - -/* Message Table */ -static const qmi_idl_message_table_entry loc_message_table_v02[] = { - {sizeof(qmiLocGenRespMsgT_v02), qmiLocGenRespMsgT_data_v02}, - {sizeof(qmiLocInformClientRevisionReqMsgT_v02), qmiLocInformClientRevisionReqMsgT_data_v02}, - {sizeof(qmiLocRegEventsReqMsgT_v02), qmiLocRegEventsReqMsgT_data_v02}, - {sizeof(qmiLocStartReqMsgT_v02), qmiLocStartReqMsgT_data_v02}, - {sizeof(qmiLocStopReqMsgT_v02), qmiLocStopReqMsgT_data_v02}, - {sizeof(qmiLocEventPositionReportIndMsgT_v02), qmiLocEventPositionReportIndMsgT_data_v02}, - {sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), qmiLocEventGnssSvInfoIndMsgT_data_v02}, - {sizeof(qmiLocEventNmeaIndMsgT_v02), qmiLocEventNmeaIndMsgT_data_v02}, - {sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), qmiLocEventInjectTimeReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02}, - {sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), qmiLocEventInjectPositionReqIndMsgT_data_v02}, - {sizeof(qmiLocEventEngineStateIndMsgT_v02), qmiLocEventEngineStateIndMsgT_data_v02}, - {sizeof(qmiLocEventFixSessionStateIndMsgT_v02), qmiLocEventFixSessionStateIndMsgT_data_v02}, - {sizeof(qmiLocEventWifiReqIndMsgT_v02), qmiLocEventWifiReqIndMsgT_data_v02}, - {sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02}, - {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, - {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, - {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, - {sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), qmiLocEventNiGeofenceNotificationIndMsgT_data_v02}, - {sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), qmiLocEventGeofenceGenAlertIndMsgT_data_v02}, - {sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), qmiLocEventGeofenceBreachIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetFixCriteriaIndMsgT_v02), qmiLocGetFixCriteriaIndMsgT_data_v02}, - {sizeof(qmiLocNiUserRespReqMsgT_v02), qmiLocNiUserRespReqMsgT_data_v02}, - {sizeof(qmiLocNiUserRespIndMsgT_v02), qmiLocNiUserRespIndMsgT_data_v02}, - {sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02), qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02), qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02), qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02), qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02}, - {sizeof(qmiLocInjectUtcTimeReqMsgT_v02), qmiLocInjectUtcTimeReqMsgT_data_v02}, - {sizeof(qmiLocInjectUtcTimeIndMsgT_v02), qmiLocInjectUtcTimeIndMsgT_data_v02}, - {sizeof(qmiLocInjectPositionReqMsgT_v02), qmiLocInjectPositionReqMsgT_data_v02}, - {sizeof(qmiLocInjectPositionIndMsgT_v02), qmiLocInjectPositionIndMsgT_data_v02}, - {sizeof(qmiLocSetEngineLockReqMsgT_v02), qmiLocSetEngineLockReqMsgT_data_v02}, - {sizeof(qmiLocSetEngineLockIndMsgT_v02), qmiLocSetEngineLockIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetEngineLockIndMsgT_v02), qmiLocGetEngineLockIndMsgT_data_v02}, - {sizeof(qmiLocSetSbasConfigReqMsgT_v02), qmiLocSetSbasConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSbasConfigIndMsgT_v02), qmiLocSetSbasConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSbasConfigIndMsgT_v02), qmiLocGetSbasConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetNmeaTypesReqMsgT_v02), qmiLocSetNmeaTypesReqMsgT_data_v02}, - {sizeof(qmiLocSetNmeaTypesIndMsgT_v02), qmiLocSetNmeaTypesIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetNmeaTypesIndMsgT_v02), qmiLocGetNmeaTypesIndMsgT_data_v02}, - {sizeof(qmiLocSetLowPowerModeReqMsgT_v02), qmiLocSetLowPowerModeReqMsgT_data_v02}, - {sizeof(qmiLocSetLowPowerModeIndMsgT_v02), qmiLocSetLowPowerModeIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetLowPowerModeIndMsgT_v02), qmiLocGetLowPowerModeIndMsgT_data_v02}, - {sizeof(qmiLocSetServerReqMsgT_v02), qmiLocSetServerReqMsgT_data_v02}, - {sizeof(qmiLocSetServerIndMsgT_v02), qmiLocSetServerIndMsgT_data_v02}, - {sizeof(qmiLocGetServerReqMsgT_v02), qmiLocGetServerReqMsgT_data_v02}, - {sizeof(qmiLocGetServerIndMsgT_v02), qmiLocGetServerIndMsgT_data_v02}, - {sizeof(qmiLocDeleteAssistDataReqMsgT_v02), qmiLocDeleteAssistDataReqMsgT_data_v02}, - {sizeof(qmiLocDeleteAssistDataIndMsgT_v02), qmiLocDeleteAssistDataIndMsgT_data_v02}, - {sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02), qmiLocSetXtraTSessionControlReqMsgT_data_v02}, - {sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02), qmiLocSetXtraTSessionControlIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02), qmiLocGetXtraTSessionControlIndMsgT_data_v02}, - {sizeof(qmiLocInjectWifiPositionReqMsgT_v02), qmiLocInjectWifiPositionReqMsgT_data_v02}, - {sizeof(qmiLocInjectWifiPositionIndMsgT_v02), qmiLocInjectWifiPositionIndMsgT_data_v02}, - {sizeof(qmiLocNotifyWifiStatusReqMsgT_v02), qmiLocNotifyWifiStatusReqMsgT_data_v02}, - {sizeof(qmiLocNotifyWifiStatusIndMsgT_v02), qmiLocNotifyWifiStatusIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetRegisteredEventsIndMsgT_v02), qmiLocGetRegisteredEventsIndMsgT_data_v02}, - {sizeof(qmiLocSetOperationModeReqMsgT_v02), qmiLocSetOperationModeReqMsgT_data_v02}, - {sizeof(qmiLocSetOperationModeIndMsgT_v02), qmiLocSetOperationModeIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetOperationModeIndMsgT_v02), qmiLocGetOperationModeIndMsgT_data_v02}, - {sizeof(qmiLocSetSpiStatusReqMsgT_v02), qmiLocSetSpiStatusReqMsgT_data_v02}, - {sizeof(qmiLocSetSpiStatusIndMsgT_v02), qmiLocSetSpiStatusIndMsgT_data_v02}, - {sizeof(qmiLocInjectSensorDataReqMsgT_v02), qmiLocInjectSensorDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectSensorDataIndMsgT_v02), qmiLocInjectSensorDataIndMsgT_data_v02}, - {sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02), qmiLocInjectTimeSyncDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02), qmiLocInjectTimeSyncDataIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetCradleMountConfigIndMsgT_v02), qmiLocGetCradleMountConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetCradleMountConfigReqMsgT_v02), qmiLocSetCradleMountConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetCradleMountConfigIndMsgT_v02), qmiLocSetCradleMountConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02), qmiLocGetExternalPowerConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02), qmiLocSetExternalPowerConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02), qmiLocSetExternalPowerConfigIndMsgT_data_v02}, - {sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02), qmiLocInformLocationServerConnStatusReqMsgT_data_v02}, - {sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02), qmiLocInformLocationServerConnStatusIndMsgT_data_v02}, - {sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02), qmiLocSetProtocolConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02), qmiLocSetProtocolConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02), qmiLocGetProtocolConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02), qmiLocGetProtocolConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorControlConfigReqMsgT_v02), qmiLocSetSensorControlConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorControlConfigIndMsgT_v02), qmiLocSetSensorControlConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, - {sizeof(qmiLocGetSensorPropertiesReqMsgT_v02), qmiLocGetSensorPropertiesReqMsgT_data_v02}, - {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, - {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, - {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02), qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02}, - {sizeof(qmiLocInjectSuplCertificateReqMsgT_v02), qmiLocInjectSuplCertificateReqMsgT_data_v02}, - {sizeof(qmiLocInjectSuplCertificateIndMsgT_v02), qmiLocInjectSuplCertificateIndMsgT_data_v02}, - {sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02), qmiLocDeleteSuplCertificateReqMsgT_data_v02}, - {sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02), qmiLocDeleteSuplCertificateIndMsgT_data_v02}, - {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, - {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02}, - {sizeof(qmiLocAddCircularGeofenceReqMsgT_v02), qmiLocAddCircularGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocAddCircularGeofenceIndMsgT_v02), qmiLocAddCircularGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocDeleteGeofenceReqMsgT_v02), qmiLocDeleteGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocDeleteGeofenceIndMsgT_v02), qmiLocDeleteGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocQueryGeofenceReqMsgT_v02), qmiLocQueryGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocQueryGeofenceIndMsgT_v02), qmiLocQueryGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, - {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, - {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, - {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02}, - {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, - {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, - {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, - {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02}, - {sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02), qmiLocInjectGSMCellInfoReqMsgT_data_v02}, - {sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02), qmiLocInjectGSMCellInfoIndMsgT_data_v02}, - {sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02), qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02}, - {sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02), qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02}, - {0, 0}, - {sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02), qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02} -}; - -/* Predefine the Type Table Object */ -static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02; - -/*Referenced Tables Array*/ -static const qmi_idl_type_table_object *loc_qmi_idl_type_table_object_referenced_tables_v02[] = -{&loc_qmi_idl_type_table_object_v02, &common_qmi_idl_type_table_object_v01}; - -/*Type Table Object*/ -static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { - sizeof(loc_type_table_v02)/sizeof(qmi_idl_type_table_entry ), - sizeof(loc_message_table_v02)/sizeof(qmi_idl_message_table_entry), - 1, - loc_type_table_v02, - loc_message_table_v02, - loc_qmi_idl_type_table_object_referenced_tables_v02 -}; - -/*Arrays of service_message_table_entries for commands, responses and indications*/ -static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { - {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, - {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, - {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 103}, - {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, - {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 22), 0}, - {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 24), 0}, - {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 26), 1086}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 28), 1053}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 30), 0}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 32), 0}, - {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 34), 18}, - {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 36), 112}, - {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 38), 7}, - {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 40), 0}, - {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 42), 4}, - {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 44), 0}, - {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 46), 7}, - {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 48), 0}, - {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 50), 4}, - {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 52), 0}, - {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 54), 297}, - {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 56), 11}, - {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 58), 929}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 60), 4}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 62), 0}, - {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 64), 694}, - {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 66), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 68), 0}, - {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 70), 7}, - {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 72), 0}, - {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 74), 8}, - {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 76), 1425}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 78), 21}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 82), 11}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 80), 0}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 32}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, - {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, - {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 42}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 110), 12}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 112), 7}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02, TYPE16(0, 114), 52}, - {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, - {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, - {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, - {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7}, - {QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02, TYPE16(0, 128), 23}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02, TYPE16(0, 130), 1036}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02, TYPE16(0, 132), 0} -}; - -static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { - {QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_REG_EVENTS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_START_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_STOP_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SERVICE_REVISION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_FIX_CRITERIA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_NI_USER_RESPONSE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_UTC_TIME_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SERVER_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SERVER_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_ASSIST_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_WIFI_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SPI_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_SENSOR_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02, TYPE16(0, 0), 7}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02, TYPE16(0, 0), 7} -}; - -static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { - {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 388}, - {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, - {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, - {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1079}, - {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, - {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, - {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, - {QMI_LOC_EVENT_ENGINE_STATE_IND_V02, TYPE16(0, 12), 7}, - {QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, TYPE16(0, 13), 11}, - {QMI_LOC_EVENT_WIFI_REQ_IND_V02, TYPE16(0, 14), 12}, - {QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, TYPE16(0, 15), 16}, - {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, - {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, - {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, - {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 23), 532}, - {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 25), 99}, - {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 27), 7}, - {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 29), 12}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 31), 790}, - {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 33), 20}, - {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 35), 7}, - {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 37), 7}, - {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 39), 7}, - {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 41), 14}, - {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 43), 7}, - {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 45), 11}, - {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 47), 7}, - {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 49), 14}, - {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 51), 7}, - {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 53), 11}, - {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 55), 7}, - {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 57), 304}, - {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 59), 7}, - {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 61), 7}, - {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 63), 11}, - {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 65), 7}, - {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 67), 7}, - {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 69), 18}, - {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 71), 7}, - {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 73), 14}, - {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 75), 7}, - {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 77), 22}, - {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 79), 7}, - {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 83), 7}, - {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 81), 18}, - {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 87), 7}, - {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, - {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, - {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, - {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 39}, - {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, - {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, - {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, - {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, - {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, - {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 49}, - {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, - {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, - {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, - {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 113), 19}, - {QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, TYPE16(0, 19), 14}, - {QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, TYPE16(0, 20), 7}, - {QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, TYPE16(0, 21), 78}, - {QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, TYPE16(0, 115), 21}, - {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, - {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, - {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, - {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, - {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, - {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82}, - {QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, TYPE16(0, 129), 7}, - {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, TYPE16(0, 131), 7}, - {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, TYPE16(0, 133), 7} -}; - -/*Service Object*/ -struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { - 0x05, - 0x02, - 0x10, - 2248, - { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), - sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), - sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, - { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, - &loc_qmi_idl_type_table_object_v02, - 0x10, - NULL -}; - -/* Service Object Accessor */ -qmi_idl_service_object_type loc_get_service_object_internal_v02 - ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ){ - if ( LOC_V02_IDL_MAJOR_VERS != idl_maj_version || LOC_V02_IDL_MINOR_VERS != idl_min_version - || LOC_V02_IDL_TOOL_VERS != library_version) - { - return NULL; - } - return (qmi_idl_service_object_type)&loc_qmi_idl_service_object_v02; -} - +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.6 + It was generated on: Fri Oct 26 2012 + From IDL File: location_service_v02.idl */ + +#include "stdint.h" +#include "qmi_idl_lib_internal.h" +#include "location_service_v02.h" +#include "common_v01.h" + + +/*Type Definitions*/ +static const uint8_t qmiLocApplicationIdStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationProvider), + QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02, + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationName), + QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02, + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion_valid), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApplicationIdStructT_v02, applicationVersion), + QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGPSTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsWeek), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGPSTimeStructT_v02, gpsTimeOfWeekMs), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDOPStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, PDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, HDOP), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDOPStructT_v02, VDOP), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorUsageIndicatorStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, usageMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorUsageIndicatorStructT_v02, aidingIndicatorMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, validMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, healthStatus), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svStatus), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, svInfoMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, elevation), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, azimuth), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSvInfoStructT_v02, snr), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQosIncl), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posQos), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, numFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, timeBetweenFixes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, posMode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, encodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId), + QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId) - QMI_IDL_OFFSET8(qmiLocNiVxNotifyVerifyStructT_v02, requestorId_len), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxNotifyVerifyStructT_v02, userRespTimerInSeconds), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplFormattedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formatType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString) - QMI_IDL_OFFSET8(qmiLocNiSuplFormattedStringStructT_v02, formattedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplQopStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, validMask), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, horizontalAccuracy), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, verticalAccuracy), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, maxLocAge), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplQopStructT_v02, delay), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV4AddrStructType_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, addr), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV4AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocIpV6AddrStructType_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, addr), + QMI_LOC_IPV6_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocIpV6AddrStructType_v02, port), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplServerInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, suplServerAddrTypeMask), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv4Addr), + 8, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, ipv6Addr), + 9, 0, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocNiSuplServerInfoStructT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiSuplNotifyVerifyStructT_v02, suplServerInfo), + 10, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplSessionId), + QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplHash), + QMI_LOC_NI_SUPL_HASH_LENGTH_V02, + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, posMethod), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, requestorId), + 6, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, clientName), + 6, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, suplQop), + 7, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiSuplNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpCodedStringStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString), + QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpCodedStringStructT_v02, codedString_len), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiUmtsCpNotifyVerifyStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, valid_flags), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, invokeId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, dataCodingScheme), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText), + QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, notificationText_len), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress), + QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress) - QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, clientAddress_len), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, locationType), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, requestorId), + 12, 0, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, codewordString), + 12, 0, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, lcsServiceTypeId), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUmtsCpNotifyVerifyStructT_v02, userResponseTimer), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiVxServiceInteractionStructT_data_v02[] = { + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiVxServiceInteractionStructT_v02, niVxReq), + 5, 0, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiVxServiceInteractionStructT_v02, serviceInteractionType), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocNiSuplVer2ExtStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, supportedNetworksMask), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, triggerType), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocNiSuplVer2ExtStructT_v02, gnssType), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAssistanceServerUrlStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocAssistanceServerUrlStructT_v02, serverUrl), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocTimeServerListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, delayThreshold), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList), + QMI_LOC_MAX_NTP_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList) - QMI_IDL_OFFSET8(qmiLocTimeServerListStructT_v02, timeServerList_len), + 16, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsAllowedSizesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxFileSizeInBytes), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsAllowedSizesStructT_v02, maxPartSize), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsServerListStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList), + QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocPredictedOrbitsServerListStructT_v02, serverList_len), + 16, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorControlConfigSamplingSpecStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, samplesPerBatch), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorControlConfigSamplingSpecStructT_v02, batchesPerSecond), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorReadyStatusStructT_data_v02[] = { + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, injectEnable), + + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSensorReadyStatusStructT_v02, dataFrequency), + 20, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGeofencePositionStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, timestampUtc), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMinor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseSemiMajor), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedHorizontal), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, altitudeWrtEllipsoid), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, vertUnc), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, speedVertical), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading_valid), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGeofencePositionStructT_v02, heading), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocPredictedOrbitsDataValidityStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, startTimeInUTC), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocPredictedOrbitsDataValidityStructT_v02, durationHours), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocAltitudeSrcInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, source), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, linkage), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAltitudeSrcInfoStructT_v02, coverage), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocDeleteSvInfoStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, gnssSvId), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, system), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSvInfoStructT_v02, deleteSvInfoMask), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixTimeStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixTimeStructT_v02, wifiPositionTime), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiFixPosStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lat), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, lon), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, hepe), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, numApsUsed), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiFixPosStructT_v02, fixErrorCode), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocWifiApInfoStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY |QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, macAddr), + QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02, + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, rssi), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, channel), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocWifiApInfoStructT_v02, apQualifier), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, timeOffset), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, xAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, yAxis), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleStructT_v02, zAxis), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLoc3AxisSensorSampleListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, timeOfFirstSample), + + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, flags), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData), + QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, + QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData) - QMI_IDL_OFFSET8(qmiLoc3AxisSensorSampleListStructT_v02, sensorData_len), + 29, 0, + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocApnProfilesStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, pdnType), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocApnProfilesStructT_v02, apnName), + QMI_LOC_MAX_APN_NAME_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocCircularGeofenceArgsStructT_data_v02[] = { + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, latitude), + + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, longitude), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocCircularGeofenceArgsStructT_v02, radius), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocMotionDataStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_state), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, motion_mode), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, probability_of_state), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, age), + + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocMotionDataStructT_v02, timeout), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocGSMCellIdStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MCC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, MNC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, LAC), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGSMCellIdStructT_v02, CID), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocEmergencyNotificationStructT_data_v02[] = { + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN |QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocEmergencyNotificationStructT_v02, eslpUrl), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02, + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorTemperatureSampleStructT_data_v02[] = { + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleStructT_v02, timeOffset), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleStructT_v02, temperature), + + QMI_IDL_FLAG_END_VALUE +}; + +static const uint8_t qmiLocSensorTemperatureSampleListStructT_data_v02[] = { + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleListStructT_v02, timeSource), + + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleListStructT_v02, timeOfFirstSample), + + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleListStructT_v02, temperatureData), + QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02, + QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleListStructT_v02, temperatureData) - QMI_IDL_OFFSET8(qmiLocSensorTemperatureSampleListStructT_v02, temperatureData_len), + 36, 0, + QMI_IDL_FLAG_END_VALUE +}; + +/*Message Definitions*/ +static const uint8_t qmiLocGenRespMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGenRespMsgT_v02, resp), + 0, 1 +}; + +static const uint8_t qmiLocInformClientRevisionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformClientRevisionReqMsgT_v02, revision) +}; + +static const uint8_t qmiLocRegEventsReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocRegEventsReqMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocStartReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, fixRecurrence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocStartReqMsgT_v02, applicationId), + 0, 0 +}; + +static const uint8_t qmiLocStopReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocStopReqMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventPositionReportIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionStatus), + + 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, sessionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence_valid)), + 0x16, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedHorizontal), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x1B, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence_valid)), + 0x1D, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, speedVertical), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc_valid)), + 0x21, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP_valid)), + 0x24, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, DOP), + 2, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc_valid)), + 0x25, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds_valid)), + 0x26, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, leapSeconds), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime_valid)), + 0x27, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, gpsTime), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPositionReportIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, timeSrc_valid)), + 0x29, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, sensorDataUsage), + 3, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, fixId_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, fixId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_valid)), + 0x2C, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventPositionReportIndMsgT_v02, gnssSvUsedList_len) +}; + +static const uint8_t qmiLocEventGnssSvInfoIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, altitudeAssumed), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList), + QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02, + QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList) - QMI_IDL_OFFSET8(qmiLocEventGnssSvInfoIndMsgT_v02, svList_len), + 4, 0 +}; + +static const uint8_t qmiLocEventNmeaIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocEventNmeaIndMsgT_v02, nmea), + QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 +}; + +static const uint8_t qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd) - QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxInd), + 5, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplInd), + 11, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiUmtsCpInd), + 13, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiVxServiceInteractionInd), + 14, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, NiSuplVer2ExtInd), + 15, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, suplEmergencyNotification) - QMI_IDL_OFFSET16RELATIVE(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, suplEmergencyNotification_valid)), + 0x15, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocEventNiNotifyVerifyReqIndMsgT_v02, suplEmergencyNotification), + 35, 0 +}; + +static const uint8_t qmiLocEventInjectTimeReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo) - QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectTimeReqIndMsgT_v02, timeServerInfo), + 17, 0 +}; + +static const uint8_t qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, allowedSizes), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02, serverList), + 19, 0 +}; + +static const uint8_t qmiLocEventInjectPositionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, latitude), + + 0x02, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, longitude), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x04, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocEventInjectPositionReqIndMsgT_v02, timestampUtc) +}; + +static const uint8_t qmiLocEventEngineStateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventEngineStateIndMsgT_v02, engineState) +}; + +static const uint8_t qmiLocEventFixSessionStateIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) - QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventFixSessionStateIndMsgT_v02, sessionId) +}; + +static const uint8_t qmiLocEventWifiReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) - QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocEventWifiReqIndMsgT_v02, tbfInMs) +}; + +static const uint8_t qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelReady), + 21, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroReady), + 21, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelTemperatureReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelTemperatureReady_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, accelTemperatureReady), + 21, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroTemperatureReady) - QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroTemperatureReady_valid)), + 0x13, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02, gyroTemperatureReady), + 21, 0 +}; + +static const uint8_t qmiLocEventTimeSyncReqIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventTimeSyncReqIndMsgT_v02, refCounter) +}; + +static const uint8_t qmiLocEventSetSpiStreamingReportIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventSetSpiStreamingReportIndMsgT_v02, enable) +}; + +static const uint8_t qmiLocEventLocationServerConnectionReqIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, requestType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventLocationServerConnectionReqIndMsgT_v02, wwanType) +}; + +static const uint8_t qmiLocEventNiGeofenceNotificationIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventNiGeofenceNotificationIndMsgT_v02, operationType) +}; + +static const uint8_t qmiLocEventGeofenceGenAlertIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceGenAlertIndMsgT_v02, geofenceAlert) +}; + +static const uint8_t qmiLocEventGeofenceBreachIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, breachType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition) - QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocEventGeofenceBreachIndMsgT_v02, geofencePosition), + 22, 0 +}; + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * static const uint8_t qmiLocGetServiceRevisionReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetServiceRevisionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, status), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, revision), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssMeFWVerString), + QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString) - QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServiceRevisionIndMsgT_v02, gnssHostSWVerString), + QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_STRING, + QMI_IDL_OFFSET16ARRAY(qmiLocGetServiceRevisionIndMsgT_v02, gnssSWVerString), + QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 +}; + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * static const uint8_t qmiLocGetFixCriteriaReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetFixCriteriaIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, horizontalAccuracyLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, intermediateReportState), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, minInterval), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId) - QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId_valid)), + 0x13, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetFixCriteriaIndMsgT_v02, applicationId), + 0, 0 +}; + +static const uint8_t qmiLocNiUserRespReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, userResp), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, notificationType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload) - QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocNiUserRespReqMsgT_v02, NiVxPayload), + 5, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplPayload), + 11, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiUmtsCpPayload), + 13, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiVxServiceInteractionPayload), + 14, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, NiSuplVer2ExtPayload), + 15, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, suplEmergencyNotification) - QMI_IDL_OFFSET16RELATIVE(qmiLocNiUserRespReqMsgT_v02, suplEmergencyNotification_valid)), + 0x15, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocNiUserRespReqMsgT_v02, suplEmergencyNotification), + 35, 0 +}; + +static const uint8_t qmiLocNiUserRespIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNiUserRespIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalSize), + + 0x02, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, totalParts), + + 0x03, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partNum), + + 0x04, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData), + ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) & 0xFF), ((QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, partData_len), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType_valid)), + 0x10, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectPredictedOrbitsDataReqMsgT_v02, formatType) +}; + +static const uint8_t qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) - QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum_valid)), + 0x10, + QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPredictedOrbitsDataIndMsgT_v02, partNum) +}; + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataSourceReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, allowedSizes), + 18, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02, serverList), + 19, 0 +}; + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * static const uint8_t qmiLocGetPredictedOrbitsDataValidityReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo) - QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02, validityInfo), + 23, 0 +}; + +static const uint8_t qmiLocInjectUtcTimeReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUtc), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeReqMsgT_v02, timeUnc) +}; + +static const uint8_t qmiLocInjectUtcTimeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectUtcTimeIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence_valid)), + 0x13, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x16, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence_valid)), + 0x18, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo_valid)), + 0x1A, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, altSourceInfo), + 24, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc_valid)), + 0x1B, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge_valid)), + 0x1C, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, timestampAge), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) - QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionReqMsgT_v02, positionSrc) +}; + +static const uint8_t qmiLocInjectPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetEngineLockReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockReqMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetEngineLockIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetEngineLockIndMsgT_v02, status) +}; + +/* + * qmiLocGetEngineLockReqMsgT is empty + * static const uint8_t qmiLocGetEngineLockReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetEngineLockIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) - QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetEngineLockIndMsgT_v02, lockType) +}; + +static const uint8_t qmiLocSetSbasConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigReqMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetSbasConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSbasConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * static const uint8_t qmiLocGetSbasConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSbasConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) - QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSbasConfigIndMsgT_v02, sbasConfig) +}; + +static const uint8_t qmiLocSetNmeaTypesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesReqMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetNmeaTypesIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetNmeaTypesIndMsgT_v02, status) +}; + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * static const uint8_t qmiLocGetNmeaTypesReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetNmeaTypesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) - QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNmeaTypesIndMsgT_v02, nmeaSentenceType) +}; + +static const uint8_t qmiLocSetLowPowerModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeReqMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetLowPowerModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetLowPowerModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * static const uint8_t qmiLocGetLowPowerModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetLowPowerModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) - QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetLowPowerModeIndMsgT_v02, lowPowerMode) +}; + +static const uint8_t qmiLocSetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv4Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, ipv6Addr), + 9, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocSetServerReqMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocSetServerIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetServerIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetServerReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) - QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerReqMsgT_v02, serverAddrTypeMask) +}; + +static const uint8_t qmiLocGetServerIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, status), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, serverType), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv4Addr), + 8, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, ipv6Addr), + 9, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr) - QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_STRING, + QMI_IDL_OFFSET8(qmiLocGetServerIndMsgT_v02, urlAddr), + QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 +}; + +static const uint8_t qmiLocDeleteAssistDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteAllFlag), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_valid)), + 0x10, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList), + QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList) - QMI_IDL_OFFSET8(qmiLocDeleteAssistDataReqMsgT_v02, deleteSvInfoList_len), + 25, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask_valid)), + 0x11, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteGnssDataMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteCellDbDataMask), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) - QMI_IDL_OFFSET16RELATIVE(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocDeleteAssistDataReqMsgT_v02, deleteClockInfoMask) +}; + +static const uint8_t qmiLocDeleteAssistDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteAssistDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetXtraTSessionControlReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlReqMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocSetXtraTSessionControlIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetXtraTSessionControlIndMsgT_v02, status) +}; + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * static const uint8_t qmiLocGetXtraTSessionControlReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetXtraTSessionControlIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) - QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetXtraTSessionControlIndMsgT_v02, xtraTSessionControl) +}; + +static const uint8_t qmiLocInjectWifiPositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixTime), + 26, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, wifiFixPosition), + 27, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_valid)), + 0x12, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo), + QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo) - QMI_IDL_OFFSET8(qmiLocInjectWifiPositionReqMsgT_v02, apInfo_len), + 28, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectWifiPositionReqMsgT_v02, horizontalReliability) +}; + +static const uint8_t qmiLocInjectWifiPositionIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectWifiPositionIndMsgT_v02, status) +}; + +static const uint8_t qmiLocNotifyWifiStatusReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusReqMsgT_v02, wifiStatus) +}; + +static const uint8_t qmiLocNotifyWifiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocNotifyWifiStatusIndMsgT_v02, status) +}; + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * static const uint8_t qmiLocGetRegisteredEventsReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetRegisteredEventsIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) - QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetRegisteredEventsIndMsgT_v02, eventRegMask) +}; + +static const uint8_t qmiLocSetOperationModeReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeReqMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetOperationModeIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetOperationModeIndMsgT_v02, status) +}; + +/* + * qmiLocGetOperationModeReqMsgT is empty + * static const uint8_t qmiLocGetOperationModeReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetOperationModeIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) - QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetOperationModeIndMsgT_v02, operationMode) +}; + +static const uint8_t qmiLocSetSpiStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, stationary), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) - QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusReqMsgT_v02, confidenceStationary) +}; + +static const uint8_t qmiLocSetSpiStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSpiStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectSensorDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelData), + 30, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData_valid)), + 0x12, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroData), + 30, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelDataTimeSource) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelDataTimeSource_valid)), + 0x13, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisAccelDataTimeSource), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroDataTimeSource) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroDataTimeSource_valid)), + 0x14, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, threeAxisGyroDataTimeSource), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, accelTemperatureData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, accelTemperatureData_valid)), + 0x15, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, accelTemperatureData), + 37, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, gyroTemperatureData) - QMI_IDL_OFFSET16RELATIVE(qmiLocInjectSensorDataReqMsgT_v02, gyroTemperatureData_valid)), + 0x16, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocInjectSensorDataReqMsgT_v02, gyroTemperatureData), + 37, 0 +}; + +static const uint8_t qmiLocInjectSensorDataIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, opaqueIdentifier), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisAccelSamplesAccepted), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, threeAxisGyroSamplesAccepted), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, accelTemperatureSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, accelTemperatureSamplesAccepted_valid)), + 0x13, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, accelTemperatureSamplesAccepted), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, gyroTemperatureSamplesAccepted) - QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, gyroTemperatureSamplesAccepted_valid)), + 0x14, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSensorDataIndMsgT_v02, gyroTemperatureSamplesAccepted) +}; + +static const uint8_t qmiLocInjectTimeSyncDataReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, refCounter), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcRxTime), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataReqMsgT_v02, sensorProcTxTime) +}; + +static const uint8_t qmiLocInjectTimeSyncDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectTimeSyncDataIndMsgT_v02, status) +}; + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * static const uint8_t qmiLocGetCradleMountConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetCradleMountConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetCradleMountConfigIndMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, cradleMountState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) - QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigReqMsgT_v02, confidenceCradleMountState) +}; + +static const uint8_t qmiLocSetCradleMountConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetCradleMountConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * static const uint8_t qmiLocGetExternalPowerConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetExternalPowerConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) - QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetExternalPowerConfigIndMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigReqMsgT_v02, externalPowerState) +}; + +static const uint8_t qmiLocSetExternalPowerConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetExternalPowerConfigIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInformLocationServerConnStatusReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, connHandle), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, requestType), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, statusType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile) - QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile_valid)), + 0x10, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusReqMsgT_v02, apnProfile), + 31, 0 +}; + +static const uint8_t qmiLocInformLocationServerConnStatusIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInformLocationServerConnStatusIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, assistedGlonassProtocolMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplHashAlgo) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplHashAlgo_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplHashAlgo), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplTlsVersion) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplTlsVersion_valid)), + 0x16, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, suplTlsVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, emergencyProtocol) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, emergencyProtocol_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersReqMsgT_v02, emergencyProtocol) +}; + +static const uint8_t qmiLocSetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocSetProtocolConfigParametersIndMsgT_v02, failedProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersReqMsgT_v02, getProtocolConfigParamMask) +}; + +static const uint8_t qmiLocGetProtocolConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplSecurity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, vxVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplVersion), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, lppConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, assistedGlonassProtocolMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplHashAlgo) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplHashAlgo_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplHashAlgo), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplTlsVersion) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplTlsVersion_valid)), + 0x16, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, suplTlsVersion), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, emergencyProtocol) - QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, emergencyProtocol_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetProtocolConfigParametersIndMsgT_v02, emergencyProtocol) +}; + +static const uint8_t qmiLocSetSensorControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigReqMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorControlConfigIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorControlConfigIndMsgT_v02, status) +}; + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) - QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorControlConfigIndMsgT_v02, sensorsUsage) +}; + +static const uint8_t qmiLocSetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesReqMsgT_v02, rateRandomWalkSpectralDensity) +}; + +static const uint8_t qmiLocSetSensorPropertiesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) - QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPropertiesIndMsgT_v02, failedSensorPropertiesMask) +}; + +static const uint8_t qmiLocGetSensorPropertiesReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesReqMsgT_v02, getSensorPropertiesMask) +}; + +static const uint8_t qmiLocGetSensorPropertiesIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, gyroBiasVarianceRandomWalk), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, velocityRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, accelerationRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, angleRandomWalkSpectralDensity), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) - QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPropertiesIndMsgT_v02, rateRandomWalkSpectralDensity) +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, accelSamplingSpecHigh), + 20, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02, gyroSamplingSpecHigh), + 20, 0 +}; + +static const uint8_t qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) - QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02, failedConfiguration) +}; + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * static const uint8_t qmiLocGetSensorPerformanceControlConfigReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, performanceControlMode), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec_valid)), + 0x11, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec_valid)), + 0x12, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpec), + 20, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, algorithmConfig), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, accelSamplingSpecHigh), + 20, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh) - QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh_valid)), + 0x15, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02, gyroSamplingSpecHigh), + 20, 0 +}; + +static const uint8_t qmiLocInjectSuplCertificateReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData), + ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_SUPL_CERT_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData) - QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateReqMsgT_v02, suplCertData_len) +}; + +static const uint8_t qmiLocInjectSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocDeleteSuplCertificateReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) - QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateReqMsgT_v02, suplCertId) +}; + +static const uint8_t qmiLocDeleteSuplCertificateIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteSuplCertificateIndMsgT_v02, status) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersReqMsgT_v02, storeAssistData) +}; + +static const uint8_t qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) - QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocSetPositionEngineConfigParametersIndMsgT_v02, failedPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersReqMsgT_v02, getPositionEngineConfigParamMask) +}; + +static const uint8_t qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, injectedPositionControl), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, filterSvUsage), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) - QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData_valid)), + 0x12, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetPositionEngineConfigParametersIndMsgT_v02, storeAssistData) +}; + +static const uint8_t qmiLocAddCircularGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, transactionId), + + 0x02, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, circularGeofenceArgs), + 32, 0, + + 0x03, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, breachMask), + + 0x04, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, includePosition), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, responsiveness), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceReqMsgT_v02, confidence) +}; + +static const uint8_t qmiLocAddCircularGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocAddCircularGeofenceIndMsgT_v02, geofenceId) +}; + +static const uint8_t qmiLocDeleteGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocDeleteGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocDeleteGeofenceIndMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocQueryGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceOrigin), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, posWrtGeofence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs_valid)), + 0x14, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, circularGeofenceArgs), + 32, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocQueryGeofenceIndMsgT_v02, geofenceState) +}; + +static const uint8_t qmiLocEditGeofenceReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceId), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, geofenceState), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) - QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask_valid)), + 0x11, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceReqMsgT_v02, breachMask) +}; + +static const uint8_t qmiLocEditGeofenceIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, geofenceId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) - QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEditGeofenceIndMsgT_v02, failedParams) +}; + +static const uint8_t qmiLocGetBestAvailablePositionReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetBestAvailablePositionIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude_valid)), + 0x11, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, latitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude_valid)), + 0x12, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, longitude), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular_valid)), + 0x13, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncCircular), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid_valid)), + 0x14, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtEllipsoid), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc_valid)), + 0x15, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc_valid)), + 0x16, + QMI_IDL_GENERIC_8_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timestampUtc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc_valid)), + 0x17, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, timeUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor_valid)), + 0x18, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMinor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor_valid)), + 0x19, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseSemiMajor), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth_valid)), + 0x1A, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horUncEllipseOrientAzimuth), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence_valid)), + 0x1B, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horCircularConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence_valid)), + 0x1C, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horEllipticalConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability_valid)), + 0x1D, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed_valid)), + 0x1E, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc_valid)), + 0x1F, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, horSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel_valid)), + 0x20, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, altitudeWrtMeanSeaLevel), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence_valid)), + 0x21, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability_valid)), + 0x22, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertReliability), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed_valid)), + 0x23, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeed), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc_valid)), + 0x24, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, vertSpeedUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading_valid)), + 0x25, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, heading), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc_valid)), + 0x26, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, headingUnc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation_valid)), + 0x27, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, magneticDeviation), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask_valid)), + 0x28, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, technologyMask), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP) - QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP_valid)), + 0x29, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocGetBestAvailablePositionIndMsgT_v02, DOP), + 2, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime_valid)), + 0x2A, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gpsTime), + 1, 0, + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc_valid)), + 0x2B, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, timeSrc), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage_valid)), + 0x2C, + QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, sensorDataUsage), + 3, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_valid)), + 0x2D, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_OFFSET_IS_16 | QMI_IDL_GENERIC_2_BYTE, + QMI_IDL_OFFSET16ARRAY(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList), + QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02, + QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList) - QMI_IDL_OFFSET16RELATIVE(qmiLocGetBestAvailablePositionIndMsgT_v02, gnssSvUsedList_len) +}; + +static const uint8_t qmiLocInjectMotionDataReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataReqMsgT_v02, motion_data), + 33, 0 +}; + +static const uint8_t qmiLocInjectMotionDataIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectMotionDataIndMsgT_v02, status) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListReqMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListReqMsgT_v02, transactionId) +}; + +static const uint8_t qmiLocGetNiGeofenceIdListIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, status), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId_valid)), + 0x10, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, transactionId), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_valid)), + 0x11, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList), + QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02, + QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList) - QMI_IDL_OFFSET8(qmiLocGetNiGeofenceIdListIndMsgT_v02, niGeofenceIdList_len) +}; + +static const uint8_t qmiLocInjectGSMCellInfoReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_AGGREGATE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, gsmCellId), + 34, 0, + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoReqMsgT_v02, roamingStatus) +}; + +static const uint8_t qmiLocInjectGSMCellInfoIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectGSMCellInfoIndMsgT_v02, status) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessageType), + + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x02, + QMI_IDL_FLAGS_IS_ARRAY | QMI_IDL_FLAGS_IS_VARIABLE_LEN | QMI_IDL_FLAGS_SZ_IS_16 | QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage), + ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) & 0xFF), ((QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02) >> 8), + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage) - QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02, injectedNIMessage_len) +}; + +static const uint8_t qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02, status) +}; + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * static const uint8_t qmiLocWWANOutOfServiceNotificationReqMsgT_data_v02[] = { + * }; + */ + +static const uint8_t qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocWWANOutOfServiceNotificationIndMsgT_v02, status) +}; + +static const uint8_t qmiLocEventPedometerControlIndMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, requestPedometerData), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, resetStepCount) - QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, resetStepCount_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, resetStepCount), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, stepCountThreshold) - QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, stepCountThreshold_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocEventPedometerControlIndMsgT_v02, stepCountThreshold) +}; + +static const uint8_t qmiLocEventMotionDataControlIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocEventMotionDataControlIndMsgT_v02, requestMotionData) +}; + +static const uint8_t qmiLocPedometerReportReqMsgT_data_v02[] = { + 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, timeSource), + + 0x02, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, timestamp), + + 0x03, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, timeInterval), + + 0x04, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepCount), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepConfidence) - QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepConfidence_valid)), + 0x10, + QMI_IDL_GENERIC_1_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepConfidence), + + QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepCountUncertainty) - QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepCountUncertainty_valid)), + 0x11, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepCountUncertainty), + + QMI_IDL_TLV_FLAGS_LAST_TLV | QMI_IDL_TLV_FLAGS_OPTIONAL | (QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepRate) - QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepRate_valid)), + 0x12, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportReqMsgT_v02, stepRate) +}; + +static const uint8_t qmiLocPedometerReportIndMsgT_data_v02[] = { + QMI_IDL_TLV_FLAGS_LAST_TLV | 0x01, + QMI_IDL_GENERIC_4_BYTE, + QMI_IDL_OFFSET8(qmiLocPedometerReportIndMsgT_v02, status) +}; + +/* Type Table */ +static const qmi_idl_type_table_entry loc_type_table_v02[] = { + {sizeof(qmiLocApplicationIdStructT_v02), qmiLocApplicationIdStructT_data_v02}, + {sizeof(qmiLocGPSTimeStructT_v02), qmiLocGPSTimeStructT_data_v02}, + {sizeof(qmiLocDOPStructT_v02), qmiLocDOPStructT_data_v02}, + {sizeof(qmiLocSensorUsageIndicatorStructT_v02), qmiLocSensorUsageIndicatorStructT_data_v02}, + {sizeof(qmiLocSvInfoStructT_v02), qmiLocSvInfoStructT_data_v02}, + {sizeof(qmiLocNiVxNotifyVerifyStructT_v02), qmiLocNiVxNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiSuplFormattedStringStructT_v02), qmiLocNiSuplFormattedStringStructT_data_v02}, + {sizeof(qmiLocNiSuplQopStructT_v02), qmiLocNiSuplQopStructT_data_v02}, + {sizeof(qmiLocIpV4AddrStructType_v02), qmiLocIpV4AddrStructType_data_v02}, + {sizeof(qmiLocIpV6AddrStructType_v02), qmiLocIpV6AddrStructType_data_v02}, + {sizeof(qmiLocNiSuplServerInfoStructT_v02), qmiLocNiSuplServerInfoStructT_data_v02}, + {sizeof(qmiLocNiSuplNotifyVerifyStructT_v02), qmiLocNiSuplNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpCodedStringStructT_v02), qmiLocNiUmtsCpCodedStringStructT_data_v02}, + {sizeof(qmiLocNiUmtsCpNotifyVerifyStructT_v02), qmiLocNiUmtsCpNotifyVerifyStructT_data_v02}, + {sizeof(qmiLocNiVxServiceInteractionStructT_v02), qmiLocNiVxServiceInteractionStructT_data_v02}, + {sizeof(qmiLocNiSuplVer2ExtStructT_v02), qmiLocNiSuplVer2ExtStructT_data_v02}, + {sizeof(qmiLocAssistanceServerUrlStructT_v02), qmiLocAssistanceServerUrlStructT_data_v02}, + {sizeof(qmiLocTimeServerListStructT_v02), qmiLocTimeServerListStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsAllowedSizesStructT_v02), qmiLocPredictedOrbitsAllowedSizesStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsServerListStructT_v02), qmiLocPredictedOrbitsServerListStructT_data_v02}, + {sizeof(qmiLocSensorControlConfigSamplingSpecStructT_v02), qmiLocSensorControlConfigSamplingSpecStructT_data_v02}, + {sizeof(qmiLocSensorReadyStatusStructT_v02), qmiLocSensorReadyStatusStructT_data_v02}, + {sizeof(qmiLocGeofencePositionStructT_v02), qmiLocGeofencePositionStructT_data_v02}, + {sizeof(qmiLocPredictedOrbitsDataValidityStructT_v02), qmiLocPredictedOrbitsDataValidityStructT_data_v02}, + {sizeof(qmiLocAltitudeSrcInfoStructT_v02), qmiLocAltitudeSrcInfoStructT_data_v02}, + {sizeof(qmiLocDeleteSvInfoStructT_v02), qmiLocDeleteSvInfoStructT_data_v02}, + {sizeof(qmiLocWifiFixTimeStructT_v02), qmiLocWifiFixTimeStructT_data_v02}, + {sizeof(qmiLocWifiFixPosStructT_v02), qmiLocWifiFixPosStructT_data_v02}, + {sizeof(qmiLocWifiApInfoStructT_v02), qmiLocWifiApInfoStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleStructT_v02), qmiLoc3AxisSensorSampleStructT_data_v02}, + {sizeof(qmiLoc3AxisSensorSampleListStructT_v02), qmiLoc3AxisSensorSampleListStructT_data_v02}, + {sizeof(qmiLocApnProfilesStructT_v02), qmiLocApnProfilesStructT_data_v02}, + {sizeof(qmiLocCircularGeofenceArgsStructT_v02), qmiLocCircularGeofenceArgsStructT_data_v02}, + {sizeof(qmiLocMotionDataStructT_v02), qmiLocMotionDataStructT_data_v02}, + {sizeof(qmiLocGSMCellIdStructT_v02), qmiLocGSMCellIdStructT_data_v02}, + {sizeof(qmiLocEmergencyNotificationStructT_v02), qmiLocEmergencyNotificationStructT_data_v02}, + {sizeof(qmiLocSensorTemperatureSampleStructT_v02), qmiLocSensorTemperatureSampleStructT_data_v02}, + {sizeof(qmiLocSensorTemperatureSampleListStructT_v02), qmiLocSensorTemperatureSampleListStructT_data_v02} +}; + +/* Message Table */ +static const qmi_idl_message_table_entry loc_message_table_v02[] = { + {sizeof(qmiLocGenRespMsgT_v02), qmiLocGenRespMsgT_data_v02}, + {sizeof(qmiLocInformClientRevisionReqMsgT_v02), qmiLocInformClientRevisionReqMsgT_data_v02}, + {sizeof(qmiLocRegEventsReqMsgT_v02), qmiLocRegEventsReqMsgT_data_v02}, + {sizeof(qmiLocStartReqMsgT_v02), qmiLocStartReqMsgT_data_v02}, + {sizeof(qmiLocStopReqMsgT_v02), qmiLocStopReqMsgT_data_v02}, + {sizeof(qmiLocEventPositionReportIndMsgT_v02), qmiLocEventPositionReportIndMsgT_data_v02}, + {sizeof(qmiLocEventGnssSvInfoIndMsgT_v02), qmiLocEventGnssSvInfoIndMsgT_data_v02}, + {sizeof(qmiLocEventNmeaIndMsgT_v02), qmiLocEventNmeaIndMsgT_data_v02}, + {sizeof(qmiLocEventNiNotifyVerifyReqIndMsgT_v02), qmiLocEventNiNotifyVerifyReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectTimeReqIndMsgT_v02), qmiLocEventInjectTimeReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02), qmiLocEventInjectPredictedOrbitsReqIndMsgT_data_v02}, + {sizeof(qmiLocEventInjectPositionReqIndMsgT_v02), qmiLocEventInjectPositionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventEngineStateIndMsgT_v02), qmiLocEventEngineStateIndMsgT_data_v02}, + {sizeof(qmiLocEventFixSessionStateIndMsgT_v02), qmiLocEventFixSessionStateIndMsgT_data_v02}, + {sizeof(qmiLocEventWifiReqIndMsgT_v02), qmiLocEventWifiReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSensorStreamingReadyStatusIndMsgT_v02), qmiLocEventSensorStreamingReadyStatusIndMsgT_data_v02}, + {sizeof(qmiLocEventTimeSyncReqIndMsgT_v02), qmiLocEventTimeSyncReqIndMsgT_data_v02}, + {sizeof(qmiLocEventSetSpiStreamingReportIndMsgT_v02), qmiLocEventSetSpiStreamingReportIndMsgT_data_v02}, + {sizeof(qmiLocEventLocationServerConnectionReqIndMsgT_v02), qmiLocEventLocationServerConnectionReqIndMsgT_data_v02}, + {sizeof(qmiLocEventNiGeofenceNotificationIndMsgT_v02), qmiLocEventNiGeofenceNotificationIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceGenAlertIndMsgT_v02), qmiLocEventGeofenceGenAlertIndMsgT_data_v02}, + {sizeof(qmiLocEventGeofenceBreachIndMsgT_v02), qmiLocEventGeofenceBreachIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetServiceRevisionIndMsgT_v02), qmiLocGetServiceRevisionIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetFixCriteriaIndMsgT_v02), qmiLocGetFixCriteriaIndMsgT_data_v02}, + {sizeof(qmiLocNiUserRespReqMsgT_v02), qmiLocNiUserRespReqMsgT_data_v02}, + {sizeof(qmiLocNiUserRespIndMsgT_v02), qmiLocNiUserRespIndMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataReqMsgT_v02), qmiLocInjectPredictedOrbitsDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectPredictedOrbitsDataIndMsgT_v02), qmiLocInjectPredictedOrbitsDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02), qmiLocGetPredictedOrbitsDataSourceIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02), qmiLocGetPredictedOrbitsDataValidityIndMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeReqMsgT_v02), qmiLocInjectUtcTimeReqMsgT_data_v02}, + {sizeof(qmiLocInjectUtcTimeIndMsgT_v02), qmiLocInjectUtcTimeIndMsgT_data_v02}, + {sizeof(qmiLocInjectPositionReqMsgT_v02), qmiLocInjectPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectPositionIndMsgT_v02), qmiLocInjectPositionIndMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockReqMsgT_v02), qmiLocSetEngineLockReqMsgT_data_v02}, + {sizeof(qmiLocSetEngineLockIndMsgT_v02), qmiLocSetEngineLockIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetEngineLockIndMsgT_v02), qmiLocGetEngineLockIndMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigReqMsgT_v02), qmiLocSetSbasConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSbasConfigIndMsgT_v02), qmiLocSetSbasConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSbasConfigIndMsgT_v02), qmiLocGetSbasConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesReqMsgT_v02), qmiLocSetNmeaTypesReqMsgT_data_v02}, + {sizeof(qmiLocSetNmeaTypesIndMsgT_v02), qmiLocSetNmeaTypesIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetNmeaTypesIndMsgT_v02), qmiLocGetNmeaTypesIndMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeReqMsgT_v02), qmiLocSetLowPowerModeReqMsgT_data_v02}, + {sizeof(qmiLocSetLowPowerModeIndMsgT_v02), qmiLocSetLowPowerModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetLowPowerModeIndMsgT_v02), qmiLocGetLowPowerModeIndMsgT_data_v02}, + {sizeof(qmiLocSetServerReqMsgT_v02), qmiLocSetServerReqMsgT_data_v02}, + {sizeof(qmiLocSetServerIndMsgT_v02), qmiLocSetServerIndMsgT_data_v02}, + {sizeof(qmiLocGetServerReqMsgT_v02), qmiLocGetServerReqMsgT_data_v02}, + {sizeof(qmiLocGetServerIndMsgT_v02), qmiLocGetServerIndMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataReqMsgT_v02), qmiLocDeleteAssistDataReqMsgT_data_v02}, + {sizeof(qmiLocDeleteAssistDataIndMsgT_v02), qmiLocDeleteAssistDataIndMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlReqMsgT_v02), qmiLocSetXtraTSessionControlReqMsgT_data_v02}, + {sizeof(qmiLocSetXtraTSessionControlIndMsgT_v02), qmiLocSetXtraTSessionControlIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetXtraTSessionControlIndMsgT_v02), qmiLocGetXtraTSessionControlIndMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionReqMsgT_v02), qmiLocInjectWifiPositionReqMsgT_data_v02}, + {sizeof(qmiLocInjectWifiPositionIndMsgT_v02), qmiLocInjectWifiPositionIndMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusReqMsgT_v02), qmiLocNotifyWifiStatusReqMsgT_data_v02}, + {sizeof(qmiLocNotifyWifiStatusIndMsgT_v02), qmiLocNotifyWifiStatusIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetRegisteredEventsIndMsgT_v02), qmiLocGetRegisteredEventsIndMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeReqMsgT_v02), qmiLocSetOperationModeReqMsgT_data_v02}, + {sizeof(qmiLocSetOperationModeIndMsgT_v02), qmiLocSetOperationModeIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetOperationModeIndMsgT_v02), qmiLocGetOperationModeIndMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusReqMsgT_v02), qmiLocSetSpiStatusReqMsgT_data_v02}, + {sizeof(qmiLocSetSpiStatusIndMsgT_v02), qmiLocSetSpiStatusIndMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataReqMsgT_v02), qmiLocInjectSensorDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectSensorDataIndMsgT_v02), qmiLocInjectSensorDataIndMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataReqMsgT_v02), qmiLocInjectTimeSyncDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectTimeSyncDataIndMsgT_v02), qmiLocInjectTimeSyncDataIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetCradleMountConfigIndMsgT_v02), qmiLocGetCradleMountConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigReqMsgT_v02), qmiLocSetCradleMountConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetCradleMountConfigIndMsgT_v02), qmiLocSetCradleMountConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetExternalPowerConfigIndMsgT_v02), qmiLocGetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigReqMsgT_v02), qmiLocSetExternalPowerConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetExternalPowerConfigIndMsgT_v02), qmiLocSetExternalPowerConfigIndMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusReqMsgT_v02), qmiLocInformLocationServerConnStatusReqMsgT_data_v02}, + {sizeof(qmiLocInformLocationServerConnStatusIndMsgT_v02), qmiLocInformLocationServerConnStatusIndMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersReqMsgT_v02), qmiLocSetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetProtocolConfigParametersIndMsgT_v02), qmiLocSetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersReqMsgT_v02), qmiLocGetProtocolConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetProtocolConfigParametersIndMsgT_v02), qmiLocGetProtocolConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigReqMsgT_v02), qmiLocSetSensorControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorControlConfigIndMsgT_v02), qmiLocSetSensorControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorControlConfigIndMsgT_v02), qmiLocGetSensorControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesReqMsgT_v02), qmiLocSetSensorPropertiesReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPropertiesIndMsgT_v02), qmiLocSetSensorPropertiesIndMsgT_data_v02}, + {sizeof(qmiLocGetSensorPropertiesReqMsgT_v02), qmiLocGetSensorPropertiesReqMsgT_data_v02}, + {sizeof(qmiLocGetSensorPropertiesIndMsgT_v02), qmiLocGetSensorPropertiesIndMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigReqMsgT_v02), qmiLocSetSensorPerformanceControlConfigReqMsgT_data_v02}, + {sizeof(qmiLocSetSensorPerformanceControlConfigIndMsgT_v02), qmiLocSetSensorPerformanceControlConfigIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocGetSensorPerformanceControlConfigIndMsgT_v02), qmiLocGetSensorPerformanceControlConfigIndMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateReqMsgT_v02), qmiLocInjectSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocInjectSuplCertificateIndMsgT_v02), qmiLocInjectSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateReqMsgT_v02), qmiLocDeleteSuplCertificateReqMsgT_data_v02}, + {sizeof(qmiLocDeleteSuplCertificateIndMsgT_v02), qmiLocDeleteSuplCertificateIndMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersReqMsgT_v02), qmiLocSetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocSetPositionEngineConfigParametersIndMsgT_v02), qmiLocSetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersReqMsgT_v02), qmiLocGetPositionEngineConfigParametersReqMsgT_data_v02}, + {sizeof(qmiLocGetPositionEngineConfigParametersIndMsgT_v02), qmiLocGetPositionEngineConfigParametersIndMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceReqMsgT_v02), qmiLocAddCircularGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocAddCircularGeofenceIndMsgT_v02), qmiLocAddCircularGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceReqMsgT_v02), qmiLocDeleteGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocDeleteGeofenceIndMsgT_v02), qmiLocDeleteGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceReqMsgT_v02), qmiLocQueryGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocQueryGeofenceIndMsgT_v02), qmiLocQueryGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceReqMsgT_v02), qmiLocEditGeofenceReqMsgT_data_v02}, + {sizeof(qmiLocEditGeofenceIndMsgT_v02), qmiLocEditGeofenceIndMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionReqMsgT_v02), qmiLocGetBestAvailablePositionReqMsgT_data_v02}, + {sizeof(qmiLocGetBestAvailablePositionIndMsgT_v02), qmiLocGetBestAvailablePositionIndMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataReqMsgT_v02), qmiLocInjectMotionDataReqMsgT_data_v02}, + {sizeof(qmiLocInjectMotionDataIndMsgT_v02), qmiLocInjectMotionDataIndMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListReqMsgT_v02), qmiLocGetNiGeofenceIdListReqMsgT_data_v02}, + {sizeof(qmiLocGetNiGeofenceIdListIndMsgT_v02), qmiLocGetNiGeofenceIdListIndMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoReqMsgT_v02), qmiLocInjectGSMCellInfoReqMsgT_data_v02}, + {sizeof(qmiLocInjectGSMCellInfoIndMsgT_v02), qmiLocInjectGSMCellInfoIndMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageReqMsgT_v02), qmiLocInjectNetworkInitiatedMessageReqMsgT_data_v02}, + {sizeof(qmiLocInjectNetworkInitiatedMessageIndMsgT_v02), qmiLocInjectNetworkInitiatedMessageIndMsgT_data_v02}, + {0, 0}, + {sizeof(qmiLocWWANOutOfServiceNotificationIndMsgT_v02), qmiLocWWANOutOfServiceNotificationIndMsgT_data_v02}, + {sizeof(qmiLocEventPedometerControlIndMsgT_v02), qmiLocEventPedometerControlIndMsgT_data_v02}, + {sizeof(qmiLocEventMotionDataControlIndMsgT_v02), qmiLocEventMotionDataControlIndMsgT_data_v02}, + {sizeof(qmiLocPedometerReportReqMsgT_v02), qmiLocPedometerReportReqMsgT_data_v02}, + {sizeof(qmiLocPedometerReportIndMsgT_v02), qmiLocPedometerReportIndMsgT_data_v02} +}; + +/* Predefine the Type Table Object */ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02; + +/*Referenced Tables Array*/ +static const qmi_idl_type_table_object *loc_qmi_idl_type_table_object_referenced_tables_v02[] = +{&loc_qmi_idl_type_table_object_v02, &common_qmi_idl_type_table_object_v01}; + +/*Type Table Object*/ +static const qmi_idl_type_table_object loc_qmi_idl_type_table_object_v02 = { + sizeof(loc_type_table_v02)/sizeof(qmi_idl_type_table_entry ), + sizeof(loc_message_table_v02)/sizeof(qmi_idl_message_table_entry), + 1, + loc_type_table_v02, + loc_message_table_v02, + loc_qmi_idl_type_table_object_referenced_tables_v02 +}; + +/*Arrays of service_message_table_entries for commands, responses and indications*/ +static const qmi_idl_service_message_table_entry loc_service_command_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02, TYPE16(0, 1), 7}, + {QMI_LOC_REG_EVENTS_REQ_V02, TYPE16(0, 2), 11}, + {QMI_LOC_START_REQ_V02, TYPE16(0, 3), 103}, + {QMI_LOC_STOP_REQ_V02, TYPE16(0, 4), 4}, + {QMI_LOC_GET_SERVICE_REVISION_REQ_V02, TYPE16(0, 22), 0}, + {QMI_LOC_GET_FIX_CRITERIA_REQ_V02, TYPE16(0, 24), 0}, + {QMI_LOC_NI_USER_RESPONSE_REQ_V02, TYPE16(0, 26), 1345}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02, TYPE16(0, 28), 1053}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02, TYPE16(0, 30), 0}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02, TYPE16(0, 32), 0}, + {QMI_LOC_INJECT_UTC_TIME_REQ_V02, TYPE16(0, 34), 18}, + {QMI_LOC_INJECT_POSITION_REQ_V02, TYPE16(0, 36), 112}, + {QMI_LOC_SET_ENGINE_LOCK_REQ_V02, TYPE16(0, 38), 7}, + {QMI_LOC_GET_ENGINE_LOCK_REQ_V02, TYPE16(0, 40), 0}, + {QMI_LOC_SET_SBAS_CONFIG_REQ_V02, TYPE16(0, 42), 4}, + {QMI_LOC_GET_SBAS_CONFIG_REQ_V02, TYPE16(0, 44), 0}, + {QMI_LOC_SET_NMEA_TYPES_REQ_V02, TYPE16(0, 46), 7}, + {QMI_LOC_GET_NMEA_TYPES_REQ_V02, TYPE16(0, 48), 0}, + {QMI_LOC_SET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 50), 4}, + {QMI_LOC_GET_LOW_POWER_MODE_REQ_V02, TYPE16(0, 52), 0}, + {QMI_LOC_SET_SERVER_REQ_V02, TYPE16(0, 54), 297}, + {QMI_LOC_GET_SERVER_REQ_V02, TYPE16(0, 56), 11}, + {QMI_LOC_DELETE_ASSIST_DATA_REQ_V02, TYPE16(0, 58), 929}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 60), 4}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02, TYPE16(0, 62), 0}, + {QMI_LOC_INJECT_WIFI_POSITION_REQ_V02, TYPE16(0, 64), 694}, + {QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02, TYPE16(0, 66), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02, TYPE16(0, 68), 0}, + {QMI_LOC_SET_OPERATION_MODE_REQ_V02, TYPE16(0, 70), 7}, + {QMI_LOC_GET_OPERATION_MODE_REQ_V02, TYPE16(0, 72), 0}, + {QMI_LOC_SET_SPI_STATUS_REQ_V02, TYPE16(0, 74), 8}, + {QMI_LOC_INJECT_SENSOR_DATA_REQ_V02, TYPE16(0, 76), 2063}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02, TYPE16(0, 78), 21}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 82), 11}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02, TYPE16(0, 80), 0}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 86), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02, TYPE16(0, 84), 0}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02, TYPE16(0, 88), 129}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 90), 53}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 92), 11}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 94), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02, TYPE16(0, 96), 0}, + {QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 98), 35}, + {QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02, TYPE16(0, 100), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 102), 42}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02, TYPE16(0, 104), 0}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 106), 2009}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02, TYPE16(0, 108), 4}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 110), 12}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02, TYPE16(0, 112), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02, TYPE16(0, 114), 52}, + {QMI_LOC_DELETE_GEOFENCE_REQ_V02, TYPE16(0, 116), 14}, + {QMI_LOC_QUERY_GEOFENCE_REQ_V02, TYPE16(0, 118), 14}, + {QMI_LOC_EDIT_GEOFENCE_REQ_V02, TYPE16(0, 120), 25}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02, TYPE16(0, 122), 7}, + {QMI_LOC_INJECT_MOTION_DATA_REQ_V02, TYPE16(0, 124), 19}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02, TYPE16(0, 126), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02, TYPE16(0, 128), 23}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02, TYPE16(0, 130), 1036}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02, TYPE16(0, 132), 0}, + {QMI_LOC_PEDOMETER_REPORT_REQ_V02, TYPE16(0, 136), 46} +}; + +static const qmi_idl_service_message_table_entry loc_service_response_messages_v02[] = { + {QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_REG_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_START_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_STOP_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVICE_REVISION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_FIX_CRITERIA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NI_USER_RESPONSE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_UTC_TIME_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_ENGINE_LOCK_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SBAS_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NMEA_TYPES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SERVER_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_ASSIST_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_WIFI_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_OPERATION_MODE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SPI_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_DELETE_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_QUERY_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_EDIT_GEOFENCE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_MOTION_DATA_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02, TYPE16(0, 0), 7}, + {QMI_LOC_PEDOMETER_REPORT_RESP_V02, TYPE16(0, 0), 7} +}; + +static const qmi_idl_service_message_table_entry loc_service_indication_messages_v02[] = { + {QMI_LOC_EVENT_POSITION_REPORT_IND_V02, TYPE16(0, 5), 388}, + {QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02, TYPE16(0, 6), 2248}, + {QMI_LOC_EVENT_NMEA_IND_V02, TYPE16(0, 7), 203}, + {QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02, TYPE16(0, 8), 1338}, + {QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02, TYPE16(0, 9), 776}, + {QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02, TYPE16(0, 10), 783}, + {QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02, TYPE16(0, 11), 40}, + {QMI_LOC_EVENT_ENGINE_STATE_IND_V02, TYPE16(0, 12), 7}, + {QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02, TYPE16(0, 13), 11}, + {QMI_LOC_EVENT_WIFI_REQ_IND_V02, TYPE16(0, 14), 12}, + {QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02, TYPE16(0, 15), 32}, + {QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02, TYPE16(0, 16), 7}, + {QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02, TYPE16(0, 17), 4}, + {QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02, TYPE16(0, 18), 21}, + {QMI_LOC_GET_SERVICE_REVISION_IND_V02, TYPE16(0, 23), 532}, + {QMI_LOC_GET_FIX_CRITERIA_IND_V02, TYPE16(0, 25), 99}, + {QMI_LOC_NI_USER_RESPONSE_IND_V02, TYPE16(0, 27), 7}, + {QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02, TYPE16(0, 29), 12}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02, TYPE16(0, 31), 790}, + {QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02, TYPE16(0, 33), 20}, + {QMI_LOC_INJECT_UTC_TIME_IND_V02, TYPE16(0, 35), 7}, + {QMI_LOC_INJECT_POSITION_IND_V02, TYPE16(0, 37), 7}, + {QMI_LOC_SET_ENGINE_LOCK_IND_V02, TYPE16(0, 39), 7}, + {QMI_LOC_GET_ENGINE_LOCK_IND_V02, TYPE16(0, 41), 14}, + {QMI_LOC_SET_SBAS_CONFIG_IND_V02, TYPE16(0, 43), 7}, + {QMI_LOC_GET_SBAS_CONFIG_IND_V02, TYPE16(0, 45), 11}, + {QMI_LOC_SET_NMEA_TYPES_IND_V02, TYPE16(0, 47), 7}, + {QMI_LOC_GET_NMEA_TYPES_IND_V02, TYPE16(0, 49), 14}, + {QMI_LOC_SET_LOW_POWER_MODE_IND_V02, TYPE16(0, 51), 7}, + {QMI_LOC_GET_LOW_POWER_MODE_IND_V02, TYPE16(0, 53), 11}, + {QMI_LOC_SET_SERVER_IND_V02, TYPE16(0, 55), 7}, + {QMI_LOC_GET_SERVER_IND_V02, TYPE16(0, 57), 304}, + {QMI_LOC_DELETE_ASSIST_DATA_IND_V02, TYPE16(0, 59), 7}, + {QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 61), 7}, + {QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02, TYPE16(0, 63), 11}, + {QMI_LOC_INJECT_WIFI_POSITION_IND_V02, TYPE16(0, 65), 7}, + {QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02, TYPE16(0, 67), 7}, + {QMI_LOC_GET_REGISTERED_EVENTS_IND_V02, TYPE16(0, 69), 18}, + {QMI_LOC_SET_OPERATION_MODE_IND_V02, TYPE16(0, 71), 7}, + {QMI_LOC_GET_OPERATION_MODE_IND_V02, TYPE16(0, 73), 14}, + {QMI_LOC_SET_SPI_STATUS_IND_V02, TYPE16(0, 75), 7}, + {QMI_LOC_INJECT_SENSOR_DATA_IND_V02, TYPE16(0, 77), 30}, + {QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02, TYPE16(0, 79), 7}, + {QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 83), 7}, + {QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02, TYPE16(0, 81), 18}, + {QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 87), 7}, + {QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02, TYPE16(0, 85), 14}, + {QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02, TYPE16(0, 89), 7}, + {QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 91), 18}, + {QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 93), 60}, + {QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 95), 7}, + {QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02, TYPE16(0, 97), 14}, + {QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 99), 14}, + {QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02, TYPE16(0, 101), 42}, + {QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 103), 14}, + {QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02, TYPE16(0, 105), 49}, + {QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 107), 7}, + {QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02, TYPE16(0, 109), 7}, + {QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 111), 14}, + {QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02, TYPE16(0, 113), 19}, + {QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02, TYPE16(0, 19), 14}, + {QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02, TYPE16(0, 20), 7}, + {QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02, TYPE16(0, 21), 78}, + {QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02, TYPE16(0, 115), 21}, + {QMI_LOC_DELETE_GEOFENCE_IND_V02, TYPE16(0, 117), 21}, + {QMI_LOC_QUERY_GEOFENCE_IND_V02, TYPE16(0, 119), 65}, + {QMI_LOC_EDIT_GEOFENCE_IND_V02, TYPE16(0, 121), 28}, + {QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02, TYPE16(0, 123), 391}, + {QMI_LOC_INJECT_MOTION_DATA_IND_V02, TYPE16(0, 125), 7}, + {QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02, TYPE16(0, 127), 82}, + {QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02, TYPE16(0, 129), 7}, + {QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02, TYPE16(0, 131), 7}, + {QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02, TYPE16(0, 133), 7}, + {QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02, TYPE16(0, 134), 15}, + {QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02, TYPE16(0, 135), 4}, + {QMI_LOC_PEDOMETER_REPORT_IND_V02, TYPE16(0, 137), 7} +}; + +/*Service Object*/ +struct qmi_idl_service_object loc_qmi_idl_service_object_v02 = { + 0x05, + 0x02, + 0x10, + 2248, + { sizeof(loc_service_command_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_response_messages_v02)/sizeof(qmi_idl_service_message_table_entry), + sizeof(loc_service_indication_messages_v02)/sizeof(qmi_idl_service_message_table_entry) }, + { loc_service_command_messages_v02, loc_service_response_messages_v02, loc_service_indication_messages_v02}, + &loc_qmi_idl_type_table_object_v02, + 0x11, + NULL +}; + +/* Service Object Accessor */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ){ + if ( LOC_V02_IDL_MAJOR_VERS != idl_maj_version || LOC_V02_IDL_MINOR_VERS != idl_min_version + || LOC_V02_IDL_TOOL_VERS != library_version) + { + return NULL; + } + return (qmi_idl_service_object_type)&loc_qmi_idl_service_object_v02; +} + diff --git a/loc_api/loc_api_v02/location_service_v02.h b/loc_api/loc_api_v02/location_service_v02.h index b31efd04..c44d6fa5 100755 --- a/loc_api/loc_api_v02/location_service_v02.h +++ b/loc_api/loc_api_v02/location_service_v02.h @@ -25,7973 +25,8511 @@ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef LOC_SERVICE_H -#define LOC_SERVICE_H -/** - @file location_service_v02.h - - @brief This is the public header file which defines the loc service Data structures. - - This header file defines the types and structures that were defined in - loc. It contains the constant values defined, enums, structures, - messages, and service message IDs (in that order) Structures that were - defined in the IDL as messages contain mandatory elements, optional - elements, a combination of mandatory and optional elements (mandatory - always come before optionals in the structure), or nothing (null message) - - An optional element in a message is preceded by a uint8_t value that must be - set to true if the element is going to be included. When decoding a received - message, the uint8_t values will be set to true or false by the decode - routine, and should be checked before accessing the values that they - correspond to. - - Variable sized arrays are defined as static sized arrays with an unsigned - integer (32 bit) preceding it that must be set to the number of elements - in the array that are valid. For Example: - - uint32_t test_opaque_len; - uint8_t test_opaque[16]; - - If only 4 elements are added to test_opaque[] then test_opaque_len must be - set to 4 before sending the message. When decoding, the _len value is set - by the decode routine and should be checked so that the correct number of - elements in the array will be accessed. - -*/ -/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* - *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY - *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ - -/* This file was generated with Tool version 5.5 - It was generated on: Thu Sep 27 2012 - From IDL File: location_service_v02.idl */ - -/** @defgroup loc_qmi_consts Constant values defined in the IDL */ -/** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ -/** @defgroup loc_qmi_enums Enumerated types used in QMI messages */ -/** @defgroup loc_qmi_messages Structures sent as QMI messages */ -/** @defgroup loc_qmi_aggregates Aggregate types used in QMI messages */ -/** @defgroup loc_qmi_accessor Accessor for QMI service object */ -/** @defgroup loc_qmi_version Constant values for versioning information */ - -#include -#include "qmi_idl_lib.h" -#include "common_v01.h" - - -#ifdef __cplusplus -extern "C" { -#endif - -/** @addtogroup loc_qmi_version - @{ - */ -/** Major Version Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MAJOR_VERS 0x02 -/** Revision Number of the IDL used to generate this file */ -#define LOC_V02_IDL_MINOR_VERS 0x10 -/** Major Version Number of the qmi_idl_compiler used to generate this file */ -#define LOC_V02_IDL_TOOL_VERS 0x05 -/** Maximum Defined Message ID */ -#define LOC_V02_MAX_MESSAGE_ID 0x006C; -/** - @} - */ - - -/** @addtogroup loc_qmi_consts - @{ - */ - -/** Maximum string length for the Provider field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 24 - -/** Maximum string length for the Name field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 32 - -/** Maximum string length for the Version field in the application ID. */ -#define QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 8 - -/** Maximum length of the list containing the SVs that were used to generate - a position report. */ -#define QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02 80 - -/** Maximum number of satellites in the satellite report. */ -#define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 - -/** Maximum NMEA string length. */ -#define QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 200 - -/** Maximum length of the requestor ID string. */ -#define QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02 200 - -/** Session ID byte length. */ -#define QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02 4 - -/** Maximum client name length allowed. */ -#define QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02 64 - -/** Maximum URL length accepted by the location engine. */ -#define QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 255 - -/** IPV6 address length in bytes. */ -#define QMI_LOC_IPV6_ADDR_LENGTH_V02 8 - -/** SUPL hash length. */ -#define QMI_LOC_NI_SUPL_HASH_LENGTH_V02 8 - -/** Maximum client address length allowed. */ -#define QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02 20 - -/** Maximum codeword length allowed. */ -#define QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02 20 - -/** Maximum number of NTP Servers sent out with this event. */ -#define QMI_LOC_MAX_NTP_SERVERS_V02 3 - -/** Maximum number of predicted orbits servers supported in the location - engine. */ -#define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 - -/** Maximum GNSS Measurement Engine Firmware Version String length. */ -#define QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 127 - -/** Maximum GNSS Measurement Engine Hosted Software Version String length. */ -#define QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 127 - -/** Maximum GNSS Measurement Engine Full Version String length. */ -#define QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 255 - -/** Maximum part length that can be injected. The client should - also look at the maxPartSize field in the predicted orbits injection - request indication and pick the minimum of the two. */ -#define QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 1024 - -/** Maximum length of the delete SV information list */ -#define QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02 128 - -/** MAC address length in bytes. */ -#define QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02 6 - -/** Maximum number of APs that the sender can report. */ -#define QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02 50 - -/** Maximum number of samples that can be injected in a TLV. */ -#define QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02 50 - -/** Maximum APN string length allowed. */ -#define QMI_LOC_MAX_APN_NAME_LENGTH_V02 100 - -/** Maximum APN profiles supported. */ -#define QMI_LOC_MAX_APN_PROFILES_V02 6 - -/** Maximum length of the SUPL certificate. */ -#define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 - -/** Maximum length of the network-initiated Geofence ID - list */ -#define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 - -/** Maximum length of the injected network initiated message. */ -#define QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02 1024 -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Response Message; Generic response definition. This message is used to tell - clients whether their message was accepted for further - processing or rejected. */ -typedef struct { - - /* Mandatory */ - /* Result Code */ - qmi_response_type_v01 resp; -}qmiLocGenRespMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Informs the service of the minor revision of the interface - definition that the control point implements. */ -typedef struct { - - /* Mandatory */ - /* Revision */ - uint32_t revision; - /**< Revision that the control point is using. */ -}qmiLocInformClientRevisionReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocEventRegMaskT_v02; -#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001ull) /**< The control point must enable this mask to receive position report - event indications. */ -#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002ull) /**< The control point must enable this mask to receive satellite report - event indications. These reports are sent at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004ull) /**< The control point must enable this mask to receive NMEA reports for - position and satellites in view. The report is at a 1 Hz rate. */ -#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008ull) /**< The control point must enable this mask to receive NI notify verify request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010ull) /**< The control point must enable this mask to receive time injection request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020ull) /**< The control point must enable this mask to receive predicted orbits request - event indications. */ -#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040ull) /**< The control point must enable this mask to receive position injection request - event indications. */ -#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080ull) /**< The control point must enable this mask to receive engine state report - event indications. */ -#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100ull) /**< The control point must enable this mask to receive fix session status report - event indications. */ -#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200ull) /**< The control point must enable this mask to receive WiFi position request - event indications. */ -#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400ull) /**< The control point must enable this mask to receive notifications from the - GPS engine indicating its readiness to accept data from the - sensors (accelerometer, gyroscope, etc.). */ -#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800ull) /**< The control point must enable this mask to receive time-sync requests - from the GPS engine. Time sync enables the GPS engine to synchronize - its clock with the sensor processor's clock. */ -#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000ull) /**< The control point must enable this mask to receive Stationary Position - Indicator (SPI) streaming report indications. */ -#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000ull) /**< The control point must enable this mask to receive location server - requests. These requests are generated when the service wishes to - establish a connection with a location server. */ -#define QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00004000ull) /**< The control point must enable this mask to receive notifications - related to network-initiated Geofences. These events notify the client - when a network-initiated Geofence is added, deleted, or edited. */ -#define QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02 ((qmiLocEventRegMaskT_v02)0x00008000ull) /**< The control point must enable this mask to receive Geofence alerts. - These alerts are generated to inform the client of the changes that may - affect Geofence, e.g., if GPS is turned off or if the network is - unavailable. */ -#define QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00010000ull) /**< The control point must enable this mask to receive notifications when - a Geofence is breached. These events are generated when the UE enters - or leaves the perimeter of a Geofence. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to register for events from the - location subsystem. */ -typedef struct { - - /* Mandatory */ - /* Event Registration Mask */ - qmiLocEventRegMaskT_v02 eventRegMask; - /**< Specifies the events that the control point is interested in receiving. - Refer to the definition of the following bitmasks: - \vspace{0.05in} \begin{itemize1} - \item 0x00000001 -- POSITION_REPORT - \item 0x00000002 -- GNSS_SV_INFO - \item 0x00000004 -- NMEA - \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ - \item 0x00000010 -- INJECT_TIME_REQ - \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ - \item 0x00000040 -- INJECT_POSITION_REQ - \item 0x00000080 -- ENGINE_STATE - \item 0x00000100 -- FIX_SESSION_STATE - \item 0x00000200 -- WIFI_REQ - \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS - \item 0x00000800 -- TIME_SYNC_REQ - \item 0x00001000 -- SET_SPI_STREAMING_REPORT - \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ - \item 0x00004000 -- NI_GEOFENCE_NOTIFICATION - \item 0x00008000 -- GEOFENCE_GEN_ALERT - \item 0x00010000 -- GEOFENCE_BREACH_NOTIFICATION - \end{itemize1} \vspace{0.05in} - Multiple events can be registered by ORing the individual masks and - sending them in this TLV. All unused bits in this mask must be set to 0. - */ -}qmiLocRegEventsReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. */ - eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, /**< Request a single position fix. */ - QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocFixRecurrenceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ - eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. */ - eQMI_LOC_ACCURACY_HIGH_V02 = 3, /**< High accuracy. */ - QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAccuracyLevelEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. */ - eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, /**< Intermediate reports are turned off. */ - QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocIntermediateReportStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; - /**< Application provider. */ - - char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; - /**< Application name. */ - - uint8_t applicationVersion_valid; - /**< Specifies whether the application version string contains - a valid value: \begin{itemize1} - \item 0x00 (FALSE) -- Application version string is invalid - \item 0x01 (TRUE) -- Application version string is valid - \vspace{-0.18in} \end{itemize1} */ - - char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; - /**< Application version. */ -}qmiLocApplicationIdStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to initiate a GPS session. */ -typedef struct { - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session as identified by the control point. The session ID - is reported back in the position reports. The control point must - specify the same session ID in the QMI_LOC_STOP_REQ message. \n - - Range: 0 to 255 - */ - - /* Optional */ - /* Recurrence Type */ - uint8_t fixRecurrence_valid; /**< Must be set to true if fixRecurrence is being passed */ - qmiLocFixRecurrenceEnumT_v02 fixRecurrence; - /**< Specifies the type of session in which the control point is interested. - If this TLV is not specified, recurrence defaults to SINGLE. - - Valid values: \n - - 0x00000001 -- Request periodic fixes \n - - 0x00000002 -- Request a single fix - */ - - /* Optional */ - /* Horizontal Accuracy */ - uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ - qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; - /**< Specifies the horizontal accuracy level required by the control point. - If not specified, accuracy defaults to LOW. - - Valid values: \begin{itemize1} - \item 0x00000001 -- LOW: Client requires low horizontal accuracy - \item 0x00000002 -- MED: Client requires medium horizontal accuracy - \item 0x00000003 -- HIGH: Client requires high horizontal accuracy - \vspace{-0.18in} - \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable Intermediate Reports */ - uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ - qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; - /**< Specifies if the control point is interested in receiving intermediate - reports. The control point must explicitly set this field to OFF if it - does not wish to receive intermediate position reports. Intermediate - position reports are generated at 1 Hz and are ON by default. If - intermediate reports are turned ON, the client receives position reports - even if the accuracy criteria are not met. The status in such a position - report is set to IN_PROGRESS in order for the control point to identify - intermediate reports. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ON: Client is interested in receiving intermediate - reports - \item 0x00000002 -- OFF: Client is not interested in receiving - intermediate reports - \vspace{-0.18in} - \end{itemize1} - */ - - /* Optional */ - /* Minimum Interval Between Position Reports */ - uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ - uint32_t minInterval; - /**< Minimum time interval, specified by the control point, that must elapse between - position reports. \n - - Units: Milliseconds \n - - Default: 1000 ms - */ - - /* Optional */ - /* ID of the Application that Sent this Request */ - uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ - qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version.*/ -}qmiLocStartReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to stop a GPS session. */ -typedef struct { - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request - (QMI_LOC_START_REQ).\n - - Range: 0 to 255 */ -}qmiLocStopReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocPosTechMaskT_v02; -#define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ -#define QMI_LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION_V02 ((qmiLocPosTechMaskT_v02)0x00000020) /**< Coarse position injected into the location engine was used to - generate the fix. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSESSIONSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SESS_STATUS_SUCCESS_V02 = 0, /**< Session was successful. */ - eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 = 1, /**< Session still in progress. Further position reports will be - generated until either the fix criteria specified by the client - are met or the client response timeout occurs. */ - eQMI_LOC_SESS_STATUS_GENERAL_FAILURE_V02 = 2, /**< Session failed. */ - eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ - eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ - eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ - eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. */ - eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, /**< Fix request failed because the engine is locked. */ - QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSessionStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t gpsWeek; - /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n - - Units: Weeks */ - - uint32_t gpsTimeOfWeekMs; - /**< Amount of time into the current GPS week. \n - - Units: Milliseconds */ -}qmiLocGPSTimeStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - float PDOP; - /**< Position dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \item PDOP = square root of (HDOP^2 + VDOP^2) - \vspace{-0.18in} \end{itemize1} */ - - float HDOP; - /**< Horizontal dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ - - float VDOP; - /**< Vertical dilution of precision. - \begin{itemize1} - \item Range: 1 (highest accuracy) to 50 (lowest accuracy) - \vspace{-0.18in} \end{itemize1} */ -}qmiLocDOPStructT_v02; /* Type */ -/** - @} - */ - -typedef uint32_t qmiLocSensorUsageMaskT_v02; -#define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ -#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyroscope was used. */ -typedef uint32_t qmiLocSensorAidedMaskT_v02; -#define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ -#define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ -#define QMI_LOC_SENSOR_AIDED_MASK_POSITION_V02 ((qmiLocSensorAidedMaskT_v02)0x00000004) /**< Bitmask to specify whether a sensor was used to calculate position. */ -#define QMI_LOC_SENSOR_AIDED_MASK_VELOCITY_V02 ((qmiLocSensorAidedMaskT_v02)0x00000008) /**< Bitmask to specify whether a sensor was used to calculate velocity. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSensorUsageMaskT_v02 usageMask; - /**< Specifies which sensors were used in calculating the position in the - position report. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SENSOR_USED_ACCEL - \item 0x00000002 -- SENSOR_USED_GYRO - \vspace{-0.18in} \end{itemize1} */ - - qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; - /**< Specifies which results were aided by sensors. - - Valid bitmasks: \n - - 0x00000001 -- AIDED_HEADING \n - - 0x00000002 -- AIDED_SPEED \n - - 0x00000004 -- AIDED_POSITION \n - - 0x00000008 -- AIDED_VELOCITY */ -}qmiLocSensorUsageIndicatorStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCTIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_TIME_SRC_INVALID_V02 = 0, /**< Invalid time. */ - eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER_V02 = 1, /**< Time is set by the 1x system. */ - eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING_V02 = 2, /**< Time is set by WCDMA/GSM time tagging (i.e., - associating network time with GPS time). */ - eQMI_LOC_TIME_SRC_EXTERNAL_INPUT_V02 = 3, /**< Time is set by an external injection. */ - eQMI_LOC_TIME_SRC_TOW_DECODE_V02 = 4, /**< Time is set after decoding over-the-air GPS navigation data - from one GPS satellite. */ - eQMI_LOC_TIME_SRC_TOW_CONFIRMED_V02 = 5, /**< Time is set after decoding over-the-air GPS navigation data - from multiple satellites. */ - eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED_V02 = 6, /**< Both time of the week and the GPS week number are known. */ - eQMI_LOC_TIME_SRC_NAV_SOLUTION_V02 = 7, /**< Time is set by the position engine after the fix is obtained. */ - eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME_V02 = 8, /**< Time is set by the position engine after performing SFT. - This is done when the clock time uncertainty is large. */ - eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ - eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ - eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ - eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network */ - eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, /**< Source of the time is unknown */ - QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocTimeSourceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCRELIABILITYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ - eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ - eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ - eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed */ - eQMI_LOC_RELIABILITY_HIGH_V02 = 4, /**< Location reliability is high; strong cross-check passed */ - QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocReliabilityEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the position report to the control point. */ -typedef struct { - - /* Mandatory */ - /* Session Status */ - qmiLocSessionStatusEnumT_v02 sessionStatus; - /**< Session status. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SESS_STATUS_SUCCESS - \item 0x00000001 -- SESS_STATUS_IN_PROGRESS - \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE - \item 0x00000003 -- SESS_STATUS_TIMEOUT - \item 0x00000004 -- SESS_STATUS_USER_END - \item 0x00000005 -- SESS_STATUS_BAD_PARAMETER - \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE - \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Session ID */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request - QMI_LOC_START_REQ. \n - - Range: 0 to 255 */ - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Circular Horizontal Position Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ - uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ - uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Elliptical Horizontal Uncertainty Azimuth */ - uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation.\n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Optional */ - /* Horizontal Confidence */ - uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ - uint8_t horConfidence; - /**< Horizontal uncertainty confidence.\n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. \n - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Horizontal Speed */ - uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ - float speedHorizontal; - /**< Horizontal speed.\n - - Units: Meters/second */ - - /* Optional */ - /* Speed Uncertainty */ - uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ - float speedUnc; - /**< 3-D Speed uncertainty.\n - - Units: Meters/second */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical uncertainty confidence.\n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. \n - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Vertical Speed */ - uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ - float speedVertical; - /**< Vertical speed.\n - - Units: Meters/second */ - - /* Optional */ - /* Heading */ - uint8_t heading_valid; /**< Must be set to true if heading is being passed */ - float heading; - /**< Heading.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Heading Uncertainty */ - uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ - float headingUnc; - /**< Heading uncertainty.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Magnetic Deviation */ - uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ - float magneticDeviation; - /**< Difference between the bearing to true north and the bearing shown - on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ - - /* Optional */ - /* Technology Used */ - uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ - qmiLocPosTechMaskT_v02 technologyMask; - /**< Technology used in computing this fix. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SATELLITE - \item 0x00000002 -- CELLID - \item 0x00000004 -- WIFI - \item 0x00000008 -- SENSORS - \item 0x00000010 -- REFERENCE_LOCATION - \item 0x00000020 -- INJECTED_COARSE_POSITION - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Dilution of Precision */ - uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ - qmiLocDOPStructT_v02 DOP; - /**< \n Dilution of precision associated with this position. */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. \n - - Units: Milliseconds since Jan. 1, 1970 */ - - /* Optional */ - /* Leap Seconds */ - uint8_t leapSeconds_valid; /**< Must be set to true if leapSeconds is being passed */ - uint8_t leapSeconds; - /**< Leap second information. If leapSeconds is not available, - timestampUtc is calculated based on a hard-coded value - for leap seconds. \n - - Units: Seconds */ - - /* Optional */ - /* GPS Time */ - uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ - qmiLocGPSTimeStructT_v02 gpsTime; - /**< \n The number of weeks since Jan. 5, 1980, and - milliseconds into the current week. */ - - /* Optional */ - /* Time Uncertainty */ - uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ - float timeUnc; - /**< Time uncertainty. \n - - Units: Milliseconds */ - - /* Optional */ - /* Time Source */ - uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ - qmiLocTimeSourceEnumT_v02 timeSrc; - /**< Time source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- TIME_SRC_INVALID - \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER - \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING - \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT - \item 0x00000004 -- TIME_SRC_TOW_DECODE - \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED - \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED - \item 0x00000007 -- TIME_SRC_NAV_SOLUTION - \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Sensor Data Usage */ - uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ - qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; - /**< \n Whether sensor data was used in computing the position in this - position report. */ - - /* Optional */ - /* Fix Count for This Session */ - uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ - uint32_t fixId; - /**< Fix count for the session. Starts with 0 and increments by one - for each successive position report for a particular session. */ - - /* Optional */ - /* SVs Used to Calculate the Fix */ - uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ - uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ - uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; - /**< Each entry in the list contains the SV ID of a satellite - used for calculating this position report. The following - information is associated with each SV ID: \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ -}qmiLocEventPositionReportIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSVSYSTEMENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ - eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ - eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ - eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. */ - eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, /**< GLONASS satellite. */ - QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSvSystemEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ - eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. */ - eQMI_LOC_SV_STATUS_TRACK_V02 = 3, /**< SV is being tracked. */ - QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSvStatusEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocSvInfoValidMaskT_v02; -#define QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000001) /**< System field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000002) /**< gnssSvId field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_HEALTH_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000004) /**< healthStatus field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000008) /**< processStatus field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000010) /**< svInfoMask field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000020) /**< Elevation field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000040) /**< Azimuth field is valid in SV information. */ -#define QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000080) /**< SNR field is valid in SV information. */ -typedef uint8_t qmiLocSvInfoMaskT_v02; -#define QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02 ((qmiLocSvInfoMaskT_v02)0x01) /**< Ephemeris is available for this SV. */ -#define QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02 ((qmiLocSvInfoMaskT_v02)0x02) /**< Almanac is available for this SV. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSvInfoValidMaskT_v02 validMask; - /**< Bitmask indicating which of the fields in this TLV are valid. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- VALID_SYSTEM - \item 0x00000002 -- VALID_GNSS_SVID - \item 0x00000004 -- VALID_HEALTH_STATUS - \item 0x00000008 -- VALID_PROCESS_STATUS - \item 0x00000010 -- VALID_SVINFO_MASK - \item 0x00000020 -- VALID_ELEVATION - \item 0x00000040 -- VALID_AZIMUTH - \item 0x00000080 -- VALID_SNR - \vspace{-0.18in} \end{itemize1} */ - - qmiLocSvSystemEnumT_v02 system; - /**< Indicates to which constellation this SV belongs. - - Valid values: \begin{itemize1} - \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS - \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO - \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS - \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS - \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - \vspace{-0.18in} \end{itemize1} */ - - uint16_t gnssSvId; - /**< GNSS SV ID. - \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For GLONASS: 1 to 32 - \item For SBAS: 120 to 151 - \end{itemize1} \end{itemize1} - - The GPS and GLONASS SVs can be disambiguated using the system field. */ - - uint8_t healthStatus; - /**< Health status. - \begin{itemize1} - \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy - \vspace{-0.18in} \end{itemize1}*/ - - qmiLocSvStatusEnumT_v02 svStatus; - /**< SV processing status. \n - Valid values:\n - - 0x00000001 -- SV_STATUS_IDLE \n - - 0x00000002 -- SV_STATUS_SEARCH \n - - 0x00000003 -- SV_STATUS_TRACK - */ - - qmiLocSvInfoMaskT_v02 svInfoMask; - /**< Whether almanac and ephemeris information is available. \n - Valid bitmasks: \n - - 0x01 -- SVINFO_HAS_EPHEMERIS \n - - 0x02 -- SVINFO_HAS_ALMANAC - */ - - float elevation; - /**< SV elevation angle.\n - - Units: Degrees \n - - Range: 0 to 90 */ - - float azimuth; - /**< SV azimuth angle.\n - - Units: Degrees \n - - Range: 0 to 360 */ - - float snr; - /**< SV signal-to-noise ratio. \n - - Units: dB-Hz */ -}qmiLocSvInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends a satellite report to the control point. */ -typedef struct { - - /* Mandatory */ - /* Altitude Source */ - uint8_t altitudeAssumed; - /**< Whether altitude is assumed or calculated: \begin{itemize1} - \item 0x00 (FALSE) -- Valid altitude is calculated - \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be - enough satellites to determine precise altitude - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Satellite Info */ - uint8_t svList_valid; /**< Must be set to true if svList is being passed */ - uint32_t svList_len; /**< Must be set to # of elements in svList */ - qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; - /**< \n SV information list. */ -}qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends NMEA sentences to the control point */ -typedef struct { - - /* Mandatory */ - /* NMEA String */ - char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; - /**< NMEA string. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 201 - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocEventNmeaIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNINOTIFYVERIFYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ - eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. */ - eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, /**< Notify and Verify, and require a response. */ - QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiNotifyVerifyEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ - eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ - eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. */ - eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, /**< MS-based preferred, but MS-assisted allowed. */ - QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiVxPosModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_VX_OCTET_V02 = 0, /**< Encoding is OCTET. */ - eQMI_LOC_NI_VX_EXN_PROTOCOL_MSG_V02 = 1, /**< Encoding is EXN PROTOCOL MSG. */ - eQMI_LOC_NI_VX_ASCII_V02 = 2, /**< Encoding is ASCII. */ - eQMI_LOC_NI_VX_IA5_V02 = 3, /**< Encoding is IA5. */ - eQMI_LOC_NI_VX_UNICODE_V02 = 4, /**< Encoding is UNICODE. */ - eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ - eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ - eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ - eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. */ - eQMI_LOC_NI_VX_GSM_V02 = 9, /**< Encoding is GSM. */ - QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t posQosIncl; - /**< Whether quality of service is included:\n - - 0x01 (TRUE) -- QoS is included \n - - 0x00 (FALSE) -- QoS is not included */ - - uint8_t posQos; - /**< Position QoS timeout. \n - - Units: Seconds \n - - Range: 0 to 255 */ - - uint32_t numFixes; - /**< Number of fixes allowed. */ - - uint32_t timeBetweenFixes; - /**< Time between fixes.\n - - Units: Seconds */ - - qmiLocNiVxPosModeEnumT_v02 posMode; - /**< Position mode. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY - \item 0x00000002 -- NI_VX_MS_BASED_ONLY - \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED - \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; - /**< VX encoding scheme. - - Valid values: \begin{itemize1} - \item 0x00000000 -- NI_VX_OCTET - \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG - \item 0x00000002 -- NI_VX_ASCII - \item 0x00000003 -- NI_VX_IA5 - \item 0x00000004 -- NI_VX_UNICODE - \item 0x00000005 -- NI_VX_SHIFT_JIS - \item 0x00000006 -- NI_VX_KOREAN - \item 0x00000007 -- NI_VX_LATIN_HEBREW - \item 0x00000008 -- NI_VX_LATIN - \item 0x00000009 -- NI_VX_GSM - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ - uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; - /**< Requestor ID. \n - - Type: Array of bytes \n - - Maximum array length: 200 - */ - - uint16_t userRespTimerInSeconds; - /**< Time to wait for the user to respond. \n - - Units: Seconds */ -}qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLPOSMETHODENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_V02 = 1, /**< Set assisted. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_V02 = 2, /**< Set based. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_PREF_V02 = 3, /**< Set assisted preferred. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_PREF_V02 = 4, /**< Set based preferred. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AUTONOMOUS_GPS_V02 = 5, /**< Standalone GPS. */ - eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ - eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ - eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ - eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. */ - eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, /**< No position. */ - QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplPosMethodEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIDATACODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SS_GERMAN_V02 = 12, /**< Language is German. */ - eQMI_LOC_NI_SS_ENGLISH_V02 = 13, /**< Language is English. */ - eQMI_LOC_NI_SS_ITALIAN_V02 = 14, /**< Language is Italian. */ - eQMI_LOC_NI_SS_FRENCH_V02 = 15, /**< Language is French. */ - eQMI_LOC_NI_SS_SPANISH_V02 = 16, /**< Language is Spanish. */ - eQMI_LOC_NI_SS_DUTCH_V02 = 17, /**< Language is Dutch. */ - eQMI_LOC_NI_SS_SWEDISH_V02 = 18, /**< Language is Swedish. */ - eQMI_LOC_NI_SS_DANISH_V02 = 19, /**< Language is Danish. */ - eQMI_LOC_NI_SS_PORTUGUESE_V02 = 20, /**< Language is Portuguese. */ - eQMI_LOC_NI_SS_FINNISH_V02 = 21, /**< Language is Finnish. */ - eQMI_LOC_NI_SS_NORWEGIAN_V02 = 22, /**< Language is Norwegian. */ - eQMI_LOC_NI_SS_GREEK_V02 = 23, /**< Language is Greek. */ - eQMI_LOC_NI_SS_TURKISH_V02 = 24, /**< Language is Turkish. */ - eQMI_LOC_NI_SS_HUNGARIAN_V02 = 25, /**< Language is Hungarian. */ - eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ - eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ - eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ - eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. */ - eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, /**< Encoding is GSM default. */ - QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiDataCodingSchemeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLFORMATENUMTYPE_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SUPL_FORMAT_LOGICAL_NAME_V02 = 0, /**< SUPL logical name format. */ - eQMI_LOC_NI_SUPL_FORMAT_EMAIL_ADDRESS_V02 = 1, /**< SUPL email address format. */ - eQMI_LOC_NI_SUPL_FORMAT_MSISDN_V02 = 2, /**< SUPL logical name format. */ - eQMI_LOC_NI_SUPL_FORMAT_URL_V02 = 3, /**< SUPL URL format. */ - eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ - eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ - eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ - eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity */ - eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, /**< SUPL unknown format. */ - QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplFormatEnumType_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplFormatEnumType_v02 formatType; - /**< Format of the formatted string. - - Valid values: \begin{itemize1} - \item 0x00000000 -- FORMAT_LOGICAL_NAME - \item 0x00000001 -- FORMAT_EMAIL_ADDRESS - \item 0x00000002 -- FORMAT_MSISDN - \item 0x00000003 -- FORMAT_URL - \item 0x00000004 -- FORMAT_SIP_URL - \item 0x00000005 -- FORMAT_MIN - \item 0x00000006 -- FORMAT_MDN - \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY - \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ - uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; - /**< Formatted string. \n - - Type: Byte array \n - - Maximum string length: 64 - */ -}qmiLocNiSuplFormattedStringStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocSuplQopValidMaskT_v02; -#define QMI_LOC_NI_SUPL_MASK_QOP_HORZ_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x01) /**< Horizontal accuracy is valid in the Quality of Position (QoP). */ -#define QMI_LOC_NI_SUPL_MASK_QOP_VER_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x02) /**< Vertical accuracy is valid in the QoP. */ -#define QMI_LOC_NI_SUPL_MASK_QOP_MAXAGE_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x04) /**< Vertical accuracy is valid in the QoP. */ -#define QMI_LOC_NI_SUPL_MASK_QOP_DELAY_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x08) /**< Vertical accuracy is valid in the QoP. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocSuplQopValidMaskT_v02 validMask; - /**< Bit field indicating which fields are valid in this value. - - Valid bitmasks: \n - - 0x01 -- QOP_HORZ_ACC_VALID \n - - 0x02 -- QOP_VER_ACC_VALID \n - - 0x04 -- QOP_MAXAGE_VALID \n - - 0x08 -- QOP_DELAY_VALID*/ - - uint8_t horizontalAccuracy; - /**< Horizontal accuracy. \n - - Units: Meters */ - - uint8_t verticalAccuracy; - /**< Vertical accuracy. \n - - Units: Meters */ - - uint16_t maxLocAge; - /**< Maximum age of the location if the engine sends a previously - computed position. \n - - Units: Seconds */ - - uint8_t delay; - /**< Delay the server is willing to tolerate for the fix. \n - - Units: Seconds */ -}qmiLocNiSuplQopStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocServerAddrTypeMaskT_v02; -#define QMI_LOC_SERVER_ADDR_TYPE_IPV4_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x01) /**< IPV4 server address type. */ -#define QMI_LOC_SERVER_ADDR_TYPE_IPV6_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x02) /**< IPV6 server address type. */ -#define QMI_LOC_SERVER_ADDR_TYPE_URL_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x04) /**< URL server address type. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t addr; - /**< IPV4 address. */ - - uint16_t port; - /**< IPV4 port. */ -}qmiLocIpV4AddrStructType_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; - /**< IPV6 address. \n - - Type: Array of unsigned integers \n - - Maximum length of the array: 8 */ - - uint32_t port; - /**< IPV6 port. */ -}qmiLocIpV6AddrStructType_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocServerAddrTypeMaskT_v02 suplServerAddrTypeMask; - /**< Mask specifying the valid fields in this value. - - Valid bitmasks: \n - - 0x01 -- IPV4 \n - - 0x02 -- IPV6 \n - - 0x04 -- URL - */ - - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< IPV4 address and port. */ - - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< IPV6 address and port. */ - - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiSuplServerInfoStructT_v02; /* Type */ -/** - @} - */ - -typedef uint32_t qmiLocNiSuplNotifyVerifyValidMaskT_v02; -#define QMI_LOC_SUPL_SERVER_INFO_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000001) /**< Mask to denote that the server information - is present in an NI SUPL notify verify request event. This mask is set in - the valid_flags field of a notify verify structure. */ -#define QMI_LOC_SUPL_SESSION_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000002) /**< Mask to denote that the SUPL session ID - is present in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_HASH_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000004) /**< Mask to denote that the SUPL hash is present - in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_POS_METHOD_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000008) /**< Mask to denote that the position method is present - in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000010) /**< Mask to denote that the data coding scheme - is present in an NI SUPL notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000020) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_CLIENT_NAME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000040) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_QOP_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000080) /**< Mask to denote that the quality of position - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -#define QMI_LOC_SUPL_USER_RESP_TIMER_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000100) /**< Mask to denote that the user response timer - is present in an NI notify verify request event. - This mask is set in the valid_flags field of a - notify verify structure. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; - /**< Indicates which of the following fields are present in this value. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SUPL_SERVER_INFO - \item 0x00000002 -- SUPL_SESSION_ID - \item 0x00000004 -- SUPL_HASH - \item 0x00000008 -- SUPL_POS_METHOD - \item 0x00000010 -- SUPL_DATA_CODING_SCHEME - \item 0x00000020 -- SUPL_REQUESTOR_ID - \item 0x00000040 -- SUPL_CLIENT_NAME - \item 0x00000080 -- SUPL_QOP - \item 0x00000100 -- SUPL_USER_RESP_TIMER - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; - /**< SUPL server information. */ - - uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; - /**< SUPL session ID. \n - - Type: Array of unsigned integers \n - - Maximum length of the array: 4 */ - - uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; - /**< Hash for SUPL_INIT; used to validate that the message was not - corrupted. \n - - Type: Array of unsigned integers \n - - Length of the array: 8 */ - - qmiLocNiSuplPosMethodEnumT_v02 posMethod; - /**< GPS mode to be used for the fix. - - Valid values: \begin{itemize1} - \item 0x00000001 -- AGPS_SETASSISTED - \item 0x00000002 -- AGPS_SETBASED - \item 0x00000003 -- AGPS_SETASSISTED_PREF - \item 0x00000004 -- AGPS_SETBASED_PREF - \item 0x00000005 -- AUTONOMOUS_GPS - \item 0x00000006 -- AFLT - \item 0x00000007 -- ECID - \item 0x00000008 -- EOTD - \item 0x00000009 -- OTDOA - \item 0x0000000A -- NO_POSITION - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Data coding scheme applies to both the requestor ID and the client - name. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplFormattedStringStructT_v02 requestorId; - /**< Requestor ID. The encoding scheme for requestor_id is specified in - the dataCodingScheme field. */ - - qmiLocNiSuplFormattedStringStructT_v02 clientName; - /**< Client name. The encoding scheme for client_name is specified in - the dataCodingScheme field. */ - - qmiLocNiSuplQopStructT_v02 suplQop; - /**< SUPL QoP. */ - - uint16_t userResponseTimer; - /**< Time to wait for the user to respond. \n - - Units: Seconds*/ -}qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ - eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. */ - eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, /**< Initial location. */ - QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiLocationTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Identifies the coding scheme of the coded string. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - - */ - - uint32_t codedString_len; /**< Must be set to # of elements in codedString */ - uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; - /**< Coded string. \n - - Type: Array of bytes \n - - Maximum string length: 20 */ -}qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ -/** - @} - */ - -typedef uint16_t qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02; -#define QMI_LOC_UMTS_CP_INVOKE_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0001) /**< Mask to denote that the invoke ID - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0002) /**< Mask to denote that the data coding scheme - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_NOTIFICATION_TEXT_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0004) /**< Mask to denote that the notification text - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_CLIENT_ADDRESS_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0008) /**< Mask to denote that the client address - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_LOCATION_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0010) /**< Mask to denote that the location type - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_REQUESTOR_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0020) /**< Mask to denote that the requestor ID - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_CODEWORD_STRING_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0040) /**< Mask to denote that the code word string - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_SERVICE_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0080) /**< Mask to denote that the service type - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -#define QMI_LOC_UMTS_CP_USER_RESP_TIMER_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0100) /**< Mask to denote that the user response timer - is present in an NI notify verify request event. - This mask is set in the valid flags field of a - notify verify structure. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; - /**< Fields that are valid in this value. - - Valid bitmasks: \begin{itemize1} - \item 0x0001 -- INVOKE_ID_MASK - \item 0x0002 -- DATA_CODING_SCHEME_MASK - \item 0x0004 -- NOTIFICATION_TEXT_MASK - \item 0x0008 -- CLIENT_ADDRESS_MASK - \item 0x0010 -- LOCATION_TYPE_MASK - \item 0x0020 -- REQUESTOR_ID_MASK - \item 0x0040 -- CODEWORD_STRING_MASK - \item 0x0080 -- SERVICE_TYPE_MASK - \item 0x0100 -- USER_RESP_TIMER_MASK - \vspace{-0.18in} \end{itemize1} - */ - - uint8_t invokeId; - /**< Supplementary Services invoke ID. */ - - qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; - /**< Type of data encoding scheme for the text. - Applies to both the notification text and the client address. - - Valid values: \begin{itemize1} - \item 0x0000000C -- NI_SS_GERMAN - \item 0x0000000D -- NI_SS_ENGLISH - \item 0x0000000E -- NI_SS_ITALIAN - \item 0x0000000F -- NI_SS_FRENCH - \item 0x00000010 -- NI_SS_SPANISH - \item 0x00000011 -- NI_SS_DUTCH - \item 0x00000012 -- NI_SS_SWEDISH - \item 0x00000013 -- NI_SS_DANISH - \item 0x00000014 -- NI_SS_PORTUGUESE - \item 0x00000015 -- NI_SS_FINNISH - \item 0x00000016 -- NI_SS_NORWEGIAN - \item 0x00000017 -- NI_SS_GREEK - \item 0x00000018 -- NI_SS_TURKISH - \item 0x00000019 -- NI_SS_HUNGARIAN - \item 0x0000001A -- NI_SS_POLISH - \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC - \item 0x0000001C -- NI_SUPL_UTF8 - \item 0x0000001D -- NI_SUPL_UCS2 - \item 0x0000001E -- NI_SUPL_GSM_DEFAULT - \vspace{-0.18in} \end{itemize1} - */ - - uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ - uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; - /**< Notification text; the encoding method is specified in - dataCodingScheme. \n - - Type: Array of bytes \n - - Maximum array length: 64 */ - - uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ - uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; - /**< Client address; the encoding method is specified in - dataCodingScheme. \n - - Maximum array length: 20 */ - - qmiLocNiLocationTypeEnumT_v02 locationType; - /**< Location type. - - Valid values: \begin{itemize1} - \item 0x00000001 -- CURRENT_LOCATION - \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION - \item 0x00000004 -- INITIAL_LOCATION - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; - /**< Requestor ID; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ - - qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; - /**< Codeword string; the encoding method is specified in the - qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ - - uint8_t lcsServiceTypeId; - /**< Service type ID. */ - - uint16_t userResponseTimer; - /**< Time to wait for the user to respond. \n - - Units: Seconds */ -}qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISERVICEINTERACTIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO_V02 = 1, /**< Service interaction between ongoing NI and incoming MO sessions. */ - QMILOCNISERVICEINTERACTIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiServiceInteractionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; - /**< Ongoing NI session request; this information is currently not filled. */ - - qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; - /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ONGOING_NI_INCOMING_MO - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiVxServiceInteractionStructT_v02; /* Type */ -/** - @} - */ - -typedef uint16_t qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02; -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WLAN_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0001) /**< Denotes that WLAN measurements are allowed as part of location ID - and multiple location IDs in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_GSM_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0002) /**< Denotes that GSM measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WCDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0004) /**< Denotes that WCDMA measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_CDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0008) /**< Denotes that CDMA measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HRDP_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0010) /**< Denotes that HRDP measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_UMB_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0020) /**< Denotes that UMB measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_LTE_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0040) /**< Denotes that LTE measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WIMAX_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0080) /**< Denotes that WIMAX measurements are allowed as part of location ID - and multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HISTORIC_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0100) /**< Denotes that historical information is allowed as part of - multiple location ID in the SUPL_POS_INIT message. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_NONSVRV_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0200) /**< Denotes that information about nonserving cells is allowed - as part of multiple location ID in the SUPL_POS_INIT message. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot - triggered session. */ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic - triggered session. */ - eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, /**< The SUPL INIT message indicates a request for an area event - triggered session. */ - QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; -/** - @} - */ - -typedef uint16_t qmiLocNiSuplVer2ExtGnssTypeMaskT_v02; -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0001) /**< GPS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GLONASS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0002) /**< GLONASS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GALILEO_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0004) /**< Galileo is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_SBAS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0008) /**< SBAS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_QZSS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0010) /**< QZSS is allowed to be used as the positioning technology. */ -#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_MODERN_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0020) /**< Modern GPS is allowed to be used as the positioning technology. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02 supportedNetworksMask; - /**< Specifies which type of network measurements are allowed to be sent as - part of the Location ID or Multiple Location IDs parameter in the - SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - - Valid bitmasks: \begin{itemize1} - \item 0x0001 -- SUPPORTED_NETWORK_WLAN - \item 0x0002 -- SUPPORTED_NETWORK_GSM - \item 0x0004 -- SUPPORTED_NETWORK_WCDMA - \item 0x0008 -- SUPPORTED_NETWORK_CDMA - \item 0x0010 -- SUPPORTED_NETWORK_HRDP - \item 0x0020 -- SUPPORTED_NETWORK_UMB - \item 0x0040 -- SUPPORTED_NETWORK_LTE - \item 0x0080 -- SUPPORTED_NETWORK_WIMAX - \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC - \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; - /**< Specifies the type of session trigger requested in the - SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). - - Valid values: \begin{itemize1} - \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT - \item 0x00000000 -- TRIGGER_TYPE_PERIODIC - \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT - \vspace{-0.18in} \end{itemize1} */ - - qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; - /**< Specifies which GNSS technologies are allowed as positioning - technologies. - - Valid bitmasks: \n - - 0x0001 -- GNSS_GPS \n - - 0x0002 -- GNSS_GLONASS \n - - 0x0004 -- GNSS_GALILEO \n - - 0x0008 -- GNSS_SBAS \n - - 0x0010 -- GNSS_QZSS \n - - 0x0020 -- GNSS_MODERN_GPS - */ -}qmiLocNiSuplVer2ExtStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Indicates an NI notify/verify request to the control point. */ -typedef struct { - - /* Mandatory */ - /* Notification Type */ - qmiLocNiNotifyVerifyEnumT_v02 notificationType; - /**< Type of notification/verification performed. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NO_NOTIFY_NO_VERIFY - \item 0x00000002 -- NOTIFY_ONLY - \item 0x00000003 -- ALLOW_NO_RESP - \item 0x00000004 -- NOT_ALLOW_NO_RESP - \item 0x00000005 -- PRIVACY_OVERRIDE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Network Initiated Vx Request */ - uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ - qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; - /**< \n Optional NI Vx request payload. */ - - /* Optional */ - /* Network Initiated SUPL Request */ - uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ - qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; - /**< \n Optional NI SUPL request payload. */ - - /* Optional */ - /* Network Initiated UMTS Control Plane Request */ - uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ - qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; - /**< \n Optional NI UMTS-CP request payload. */ - - /* Optional */ - /* Network Initiated Service Interaction Request */ - uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ - qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; - /**< \n Optional NI service interaction payload. */ - - /* Optional */ - /* Network Initiated SUPL Version 2 Extension */ - uint8_t NiSuplVer2ExtInd_valid; /**< Must be set to true if NiSuplVer2ExtInd is being passed */ - qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; - /**< \n Optional NI SUPL Version 2 Extension payload. When present, - this payload is to be used in conjunction with the SUPL - indication payload. */ -}qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< Assistance server URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocAssistanceServerUrlStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t delayThreshold; - /**< The time server is to be skipped if a one-way delay to the server - exceeds this threshold. \n - - Units: Milliseconds */ - - uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ - qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; - /**< List of Time Server URL's that are recommended by the service for time - information, the list is ordered, the client is to use the first - server specified in the list as the primary URL to fetch NTP time, - the second one as secondary, and so on. \n - - Maximum server list items: 3 */ -}qmiLocTimeServerListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject time information. */ -typedef struct { - - /* Optional */ - /* Time Server Info */ - uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ - qmiLocTimeServerListStructT_v02 timeServerInfo; - /**< \n Contains information about the time servers recommended by the - location service for NTP time. */ -}qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t maxFileSizeInBytes; - /**< Maximum allowable predicted orbits file size (in bytes). */ - - uint32_t maxPartSize; - /**< Maximum allowable predicted orbits file chunk size (in bytes). */ -}qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t serverList_len; /**< Must be set to # of elements in serverList */ - qmiLocAssistanceServerUrlStructT_v02 serverList[QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02]; - /**< List of predicted orbits URLs. The list is ordered, so the client - must use the first server specified in the list as the primary URL - from which to download predicted orbits data, the second one as - secondary, and so on. \n - - Maximum number of servers that can be specified: 3 */ -}qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Allowed Sizes */ - qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ - - /* Optional */ - /* Server List */ - uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ - qmiLocPredictedOrbitsServerListStructT_v02 serverList; - /**< \n List of servers that can be used by the client to download - predicted orbits data. */ -}qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to inject a position. */ -typedef struct { - - /* Mandatory */ - /* Latitude */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Mandatory */ - /* Longitude */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Mandatory */ - /* Circular Horizontal Uncertainty */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Mandatory */ - /* UTC Timestamp */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. */ - eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, /**< Location engine is off. */ - QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocEngineStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the engine state to the control point. */ -typedef struct { - - /* Mandatory */ - /* Engine State */ - qmiLocEngineStateEnumT_v02 engineState; - /**< Location engine state. - - Valid values: \n - - 0x00000001 -- ON \n - - 0x00000002 -- OFF - */ -}qmiLocEventEngineStateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. */ - eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, /**< Location fix session has ended. */ - QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocFixSessionStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the fix session state to the control point. */ -typedef struct { - - /* Mandatory */ - /* Session State */ - qmiLocFixSessionStateEnumT_v02 sessionState; - /**< LOC fix session state. - - Valid values: \n - - 0x00000001 -- STARTED \n - - 0x00000002 -- FINISHED - */ - - /* Optional */ - /* Session ID */ - uint8_t sessionId_valid; /**< Must be set to true if sessionId is being passed */ - uint8_t sessionId; - /**< ID of the session that was specified in the Start request. - This may not be specified for a fix session corresponding to - a network-initiated request. \n - - Range: 0 to 255 */ -}qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ - eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. */ - eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, /**< Stop periodic fixes request. */ - QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiRequestEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends a WiFi request to the control point. */ -typedef struct { - - /* Mandatory */ - /* Request Type */ - qmiLocWifiRequestEnumT_v02 requestType; - /**< Request type as specified in qmiWifiRequestEnumT. - - Valid values: \begin{itemize1} - \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES - \item 0x00000001 -- START_PERIODIC_KEEP_WARM - \item 0x00000002 -- STOP_PERIODIC_FIXES - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Time Between Fixes */ - uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ - uint16_t tbfInMs; - /**< Time between fixes for a periodic request.\n - - Units: Milliseconds */ -}qmiLocEventWifiReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t samplesPerBatch; - /**< Specifies the number of samples per batch the GNSS location engine is to - receive. The sensor sampling frequency can be computed as follows: \n - - samplingFrequency = samplesPerBatch * batchesPerSecond \n - - samplesPerBatch must be a nonzero positive value. - */ - - uint16_t batchesPerSecond; - /**< Number of sensor-data batches the GNSS location engine is to receive - per second. The rate is specified in an integral number of batches per - second (Hz). \n - - batchesPerSecond must be a nonzero positive value. - */ -}qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t injectEnable; - /**< Whether the GNSS location engine is ready to accept data from this - sensor. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor - data - \item 0x00 (FALSE) -- GNSS location engine is not ready to accept - sensor data - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; - /**< Rate at which the GNSS engine would like the sensor to be sampled. \n - The rate is specified in integral number of samples per second (Hz)\n - and batches per second. - */ -}qmiLocSensorReadyStatusStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point if the GNSS location engine is - ready to accept sensor data. */ -typedef struct { - - /* Optional */ - /* Accelerometer Accept Ready */ - uint8_t accelReady_valid; /**< Must be set to true if accelReady is being passed */ - qmiLocSensorReadyStatusStructT_v02 accelReady; - /**< \n Whether the GNSS location engine is ready to accept accelerometer - sensor data. - */ - - /* Optional */ - /* Gyroscope Accept Ready */ - uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ - qmiLocSensorReadyStatusStructT_v02 gyroReady; - /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor - data. - */ -}qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point to inject time synchronization - data. */ -typedef struct { - - /* Mandatory */ - /* Opaque Time Sync Reference Counter */ - uint32_t refCounter; - /**< This TLV is sent to registered control points. It is sent by - the location engine when it needs to synchronize location engine and - control point (sensor processor) times. - This TLV must be echoed back in the Time Sync Inject request. */ -}qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the control point to enable Stationary Position - Indicator (SPI) streaming reports. */ -typedef struct { - - /* Mandatory */ - /* Enable/Disable SPI Requests */ - uint8_t enable; - /**< Whether the client is to start or stop sending an SPI status stream. - \begin{itemize1} - \item 0x01 (TRUE) -- Client is to start sending an SPI status stream - \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. */ - eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, /**< Bring up the WWAN type used for AGNSS connections. */ - QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWWANTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. */ - eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, /**< Close a connection to the location server. */ - QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerRequestEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Requests the client to open or close a connection - to the assisted GPS location server. */ -typedef struct { - - /* Mandatory */ - /* Connection Handle */ - uint32_t connHandle; - /**< Identifies a connection across Open and Close request events. */ - - /* Mandatory */ - /* Request Type */ - qmiLocServerRequestEnumT_v02 requestType; - /**< Open or close a connection to the location server. - - Valid values: \n - - 0x00000001 -- OPEN \n - - 0x00000002 -- CLOSE - */ - - /* Mandatory */ - /* WWAN Type */ - qmiLocWWANTypeEnumT_v02 wwanType; - /**< Identifies the WWAN type for this request. \n - - Valid values: \begin{itemize1} - \item 0x00000000 -- WWAN_TYPE_INTERNET - \item 0x00000001 -- WWAN_TYPE_AGNSS - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ - eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. */ - eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, /**< An NI Geofence was edited. The control point can query the - Geofence to find the its current state. */ - QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiGeofenceOperationEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Informs the control point about - network-initiated Geofences. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< ID of the Geofence for which this - notification was generated. */ - - /* Mandatory */ - /* Operation Type */ - qmiLocNiGeofenceOperationEnumT_v02 operationType; - /**< Operation for which this notification was generated. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NI_GEOFENCE_ADDED - \item 0x00000002 -- NI_GEOFENCE_DELETED - \item 0x00000003 -- NI_GEOFENCE_EDITED - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEGENALERTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE_V02 = 1, /**< GNSS is unavailable and GNSS position fixes - cannot be used to monitor Geofences. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can - be used to monitor Geofences. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage - information is available. */ - eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, /**< The engine has an invalid time. */ - QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceGenAlertEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point of the - Geofence status. */ -typedef struct { - - /* Mandatory */ - /* Geofence General Alert */ - qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; - /**< Specifies the Geofence general alert type. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE - \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE - \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS - \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. */ - eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, /**< Denotes that a client left the Geofence. */ - QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceBreachTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - /* UTC Timestamp */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ - - /* Latitude */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Longitude */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty.\n - - Units: Meters */ - - /* Elliptical Horizontal Uncertainty Azimuth */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation.\n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Horizontal Speed validity bit */ - uint8_t speedHorizontal_valid; - /**< Indicates whether the Horizontal speed field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Horizontal speed is valid - \item 0x00 (FALSE) -- Horizontal speed is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Horizontal Speed */ - float speedHorizontal; - /**< Horizontal speed.\n - - Units: Meters/second */ - - /* Altitude validity bit */ - uint8_t altitudeWrtEllipsoid_valid; - /**< Indicates whether the altitude field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Altitude field is valid - \item 0x00 (FALSE) -- Altitude field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} - */ - - /* Altitude With Respect to Ellipsoid */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Vertical Uncertainty validity bit */ - uint8_t vertUnc_valid; - /**< Indicates whether the Vertical Uncertainty field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Vertical Uncertainty field is valid - \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Vertical Uncertainty */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Vertical Speed validity bit */ - uint8_t speedVertical_valid; - /**< Indicates whether the Vertical Speed field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Vertical Speed field is valid - \item 0x00 (FALSE) -- Vertical Speed field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Vertical Speed */ - float speedVertical; - /**< Vertical speed.\n - - Units: Meters/second */ - - /* heading validity bit */ - uint8_t heading_valid; - /**< Indicates whether the Heading field contains valid - information. - \begin{itemize1} - \item 0x01 (TRUE) -- Heading field is valid - \item 0x00 (FALSE) -- Heading field is invalid - and is to be ignored - \vspace{-0.18in} \end{itemize1} */ - - /* Heading */ - float heading; - /**< Heading.\n - - Units: Degrees \n - - Range: 0 to 359.999 */ -}qmiLocGeofencePositionStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the control point of - a Geofence breach event. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< ID of the Geofence for which this - notification was generated. */ - - /* Mandatory */ - /* Geofence Breach Type */ - qmiLocGeofenceBreachTypeEnumT_v02 breachType; - /**< The type of breach that generated this event. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING - \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Geofence Position */ - uint8_t geofencePosition_valid; /**< Must be set to true if geofencePosition is being passed */ - qmiLocGeofencePositionStructT_v02 geofencePosition; - /**< \n Position of the client when it breached the Geofence. - This TLV is included if the client configures the - Geofence to report position. The position is reported - at the same confidence level that was specified in the - Add Circular Geofence request. */ -}qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ - eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ - eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is not supported. */ - eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ - eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ - eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ - eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ - eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested */ - eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, /**< Request failed because the engine could not allocate sufficent - memory for the request. */ - QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocStatusEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetServiceRevisionReqMsgT is empty - * typedef struct { - * }qmiLocGetServiceRevisionReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Client can query the service revision using this message. */ -typedef struct { - - /* Mandatory */ - /* Get Revision Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Revision request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Interface Definition Minor Revision */ - uint32_t revision; - /**< Revision of the service. This is the minor revision of the interface that - the service implements. Minor revision updates of the service are always - backward compatible. */ - - /* Optional */ - /* GNSS Measurement Engine Firmware Version String */ - uint8_t gnssMeFWVerString_valid; /**< Must be set to true if gnssMeFWVerString is being passed */ - char gnssMeFWVerString[QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Version of the GNSS measurement engine software running under the LOC API. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 128 - \vspace{0.1in} \end{itemize1} - - \textbf{Note:} This string is only provided on platforms that have - a measurement engine that supports this version string. On all other - platforms, this optional TLV is not provided. */ - - /* Optional */ - /* GNSS Hosted Software Version String */ - uint8_t gnssHostSWVerString_valid; /**< Must be set to true if gnssHostSWVerString is being passed */ - char gnssHostSWVerString[QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Version of the GNSS hosted software running under the LOC API. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 128 - \vspace{0.1in}\end{itemize1} - - \textbf{Note:} This string is only provided on hosted architectures - (measurement and position engine running on different processors) that - support this version string. On all other platforms, this optional TLV - is not provided. */ - - /* Optional */ - /* GNSS Software Version String */ - uint8_t gnssSWVerString_valid; /**< Must be set to true if gnssSWVerString is being passed */ - char gnssSWVerString[QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; - /**< Aggregate version of the GNSS software. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} */ -}qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetFixCriteriaReqMsgT is empty - * typedef struct { - * }qmiLocGetFixCriteriaReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the fix criteria from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Fix Criteria Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Fix Criteria request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Horizontal Accuracy */ - uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ - qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; - /**< Horizontal accuracy level. - - Valid values: \begin{itemize1} - \item 0x00000001 -- LOW: Client requires low horizontal accuracy - \item 0x00000002 -- MED: Client requires medium horizontal accuracy - \item 0x00000003 -- HIGH: Client requires high horizontal accuracy - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable Intermediate Fixes */ - uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ - qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; - /**< Intermediate Report state (ON, OFF).\n - The client must explicitly set this field to OFF to stop receiving - intermediate position reports. Intermediate position reports are - generated at \n 1 Hz and are ON by default. If intermediate reports - are turned ON, the client receives position reports even if the - accuracy criteria is not met. The status in the position report is - set to IN_PROGRESS for intermediate reports. - - Valid values: \begin{itemize1} - \item 0x00000001 -- ON: Client is interested in receiving intermediate - reports - \item 0x00000002 -- OFF: Client is not interested in receiving - intermediate reports - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Minimum Interval Between Fixes */ - uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ - uint32_t minInterval; - /**< Time that must elapse before alerting the client. \n - - Units: Milliseconds */ - - /* Optional */ - /* ID of the Application that Sent the Position Request */ - uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ - qmiLocApplicationIdStructT_v02 applicationId; - /**< \n Application provider, name, and version.*/ -}qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. */ - eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, /**< User did not respond to notify verify request. */ - QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocNiUserRespEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ -typedef struct { - - /* Mandatory */ - /* User Response */ - qmiLocNiUserRespEnumT_v02 userResp; - /**< User accepted or denied. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT - \item 0x00000002 -- NOTIFY_VERIFY_DENY - \item 0x00000003 -- NOTIFY_VERIFY_NORESP - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Notification Type */ - qmiLocNiNotifyVerifyEnumT_v02 notificationType; - /**< Type of notification/verification performed. - - Valid values: \begin{itemize1} - \item 0x00000001 -- NO_NOTIFY_NO_VERIF - \item 0x00000002 -- NOTIFY_ONLY - \item 0x00000003 -- ALLOW_NO_RESP - \item 0x00000004 -- NOT_ALLOW_NO_RESP - \item 0x00000005 -- PRIVACY_OVERRIDE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Network Initiated Vx Request */ - uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ - qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; - /**< \n Optional NI VX request payload. */ - - /* Optional */ - /* Network Initiated SUPL Request */ - uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ - qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; - /**< \n Optional NI SUPL request payload. */ - - /* Optional */ - /* Network Initiated UMTS Control Plane Request */ - uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ - qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; - /**< \n Optional NI UMTS-CP request payload. */ - - /* Optional */ - /* Network Initiated Service Interaction Request */ - uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ - qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; - /**< \n Optional NI service interaction payload. */ - - /* Optional */ - /* Network Initiated SUPL Version 2 Extension */ - uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ - qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; - /**< \n Optional SUPL Version 2 Extension payload. */ -}qmiLocNiUserRespReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sends the NI user response back to the engine; success or - failure is reported in a separate indication. */ -typedef struct { - - /* Mandatory */ - /* NI User Response Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the NI User Response request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNiUserRespIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCPREDICTEDORBITSDATAFORMATENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_PREDICTED_ORBITS_XTRA_V02 = 0, /**< Default is QCOM-XTRA format. */ - QMILOCPREDICTEDORBITSDATAFORMATENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocPredictedOrbitsDataFormatEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Total Size */ - uint32_t totalSize; - /**< Total size of the predicted orbits data to be injected. \n - - Units: Bytes */ - - /* Mandatory */ - /* Total Parts */ - uint16_t totalParts; - /**< Total number of parts into which the predicted orbits data is - divided. */ - - /* Mandatory */ - /* Part Number */ - uint16_t partNum; - /**< Number of the current predicted orbits data part; starts at 1. */ - - /* Mandatory */ - /* Data */ - uint32_t partData_len; /**< Must be set to # of elements in partData */ - char partData[QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02]; - /**< Predicted orbits data. \n - - Type: Array of bytes \n - - Maximum length of the array: 1024 - */ - - /* Optional */ - /* Format Type */ - uint8_t formatType_valid; /**< Must be set to true if formatType is being passed */ - qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; - /**< Predicted orbits data format. - - Valid values: \begin{itemize1} - \item 0x00000000 -- PREDICTED_ORBITS_XTRA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects predicted orbits data. */ -typedef struct { - - /* Mandatory */ - /* Data Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Data Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Part Number */ - uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ - uint16_t partNum; - /**< Number of the predicted orbits data part for which this indication - is sent; starts at 1. */ -}qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty - * typedef struct { - * }qmiLocGetPredictedOrbitsDataSourceReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the predicted orbits data source. */ -typedef struct { - - /* Mandatory */ - /* Predicted Orbits Data Source Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the query request for a predicted orbits data source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Allowed Sizes */ - uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ - qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; - /**< \n Maximum part and file size allowed to be injected in the engine. */ - - /* Optional */ - /* Server List */ - uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ - qmiLocPredictedOrbitsServerListStructT_v02 serverList; - /**< \n List of servers that can be used by the client to download - predicted orbits data. */ -}qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty - * typedef struct { - * }qmiLocGetPredictedOrbitsDataValidityReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint64_t startTimeInUTC; - /**< Predicted orbits data is valid starting from this time. \n - - Units: Seconds (since Jan. 1, 1970) - */ - - uint16_t durationHours; - /**< Duration from the start time for which the data is valid.\n - - Units: Hours - */ -}qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the predicted orbits data validity. */ -typedef struct { - - /* Mandatory */ - /* Predicted Orbits Data Validity Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the query request for predicted orbits data validity. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Validity Info */ - uint8_t validityInfo_valid; /**< Must be set to true if validityInfo is being passed */ - qmiLocPredictedOrbitsDataValidityStructT_v02 validityInfo; -}qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects UTC time in the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Time */ - uint64_t timeUtc; - /**< UTC time since Jan. 1, 1970.\n - - Units: Milliseconds */ - - /* Mandatory */ - /* Time Uncertainty */ - uint32_t timeUnc; - /**< Time uncertainty.\n - - Units: Milliseconds */ -}qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects UTC time in the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Time Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the UTC Time Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_SRC_UNKNOWN_V02 = 0, /**< Source is unknown. */ - eQMI_LOC_ALT_SRC_GPS_V02 = 1, /**< GPS is the source. */ - eQMI_LOC_ALT_SRC_CELL_ID_V02 = 2, /**< Cell ID provided the source. */ - eQMI_LOC_ALT_SRC_ENHANCED_CELL_ID_V02 = 3, /**< Source is enhanced cell ID. */ - eQMI_LOC_ALT_SRC_WIFI_V02 = 4, /**< WiFi is the source. */ - eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ - eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ - eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ - eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. */ - eQMI_LOC_ALT_SRC_OTHER_V02 = 9, /**< Other sources. */ - QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ - eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ - eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. */ - eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, /**< Fully independent. */ - QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcLinkageEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ - eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal - position coordinates only. */ - eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, /**< Altitude uncertainty applies to the position of the device - regardless of horizontal position (within the horizontal - uncertainty region, if provided). */ - QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocAltSrcUncertaintyCoverageEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocAltSrcEnumT_v02 source; - /**< Specifies the source of the altitude. - - Valid values: \begin{itemize1} - \item 0x00000000 -- ALT_SRC_UNKNOWN - \item 0x00000001 -- ALT_SRC_GPS - \item 0x00000002 -- ALT_SRC_CELL_ID - \item 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID - \item 0x00000004 -- ALT_SRC_WIFI - \item 0x00000005 -- ALT_SRC_TERRESTRIAL - \item 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID - \item 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE - \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER - \item 0x00000009 -- ALT_SRC_OTHER - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocAltSrcLinkageEnumT_v02 linkage; - /**< Specifies the dependency between the horizontal and - altitude position components. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED - \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT - \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG - \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; - /**< Specifies the region of uncertainty. - - Valid values: \begin{itemize1} - \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED - \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid - at the injected horizontal position coordinates - only. - \item 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to - the position of the device regardless of - horizontal position (within the horizontal - uncertainty region, if provided). - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocAltitudeSrcInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position source is GNSS. */ - eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position source is Cell ID. */ - eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ - eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ - eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ - eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. */ - eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, /**< Other sources. */ - QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocPositionSrcEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects a position to the location engine. */ -typedef struct { - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} - */ - - /* Optional */ - /* Circular Horizontal Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Horizontal Confidence */ - uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ - uint8_t horConfidence; - /**< Horizontal confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). - \begin{itemize1} - \item Units: Percent (0 to 99) - \item 0 -- invalid value - \item 100 to 256 -- not used - \item If 100 is received, reinterpret to 99 - \end{itemize1} - This field must be specified together with horizontal uncertainty. - If not specified, the default value will be 50. */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid. - \begin{itemize1} - \item Units: Meters \begin{itemize1} - \item Positive = height - \item Negative = depth - \vspace{-0.18in} \end{itemize1} \end{itemize1}*/ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid - or altitudeWrtMeanSeaLevel is specified.\n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). - \begin{itemize1} - \item Units: Percent (0-99) - \item 0 -- invalid value - \item 100 to 256 -- not used - \item If 100 is received, reinterpret to 99 - \end{itemize1} - This field must be specified together with the vertical uncertainty. - If not specified, the default value will be 50. */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Altitude Source Info */ - uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ - qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; - /**< \n Specifies information regarding the altitude source. */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. \n - - Units: Milliseconds (since Jan. 1, 1970) */ - - /* Optional */ - /* Position Age */ - uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ - int32_t timestampAge; - /**< Position age, which is an estimate of how long ago this fix was made. \n - - Units: Milliseconds */ - - /* Optional */ - /* Position Source */ - uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ - qmiLocPositionSrcEnumT_v02 positionSrc; - /**< Source from which this position was obtained. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS - \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID - \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID - \item 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI - \item 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL - \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID - \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER - \end{itemize1} \vspace{0.05in} - - If altitude is specified and the altitude source is not specified, the engine - assumes that the altitude was obtained using the specified position source. \n - If both altitude and altitude source are specified, the engine assumes - that only latitude and longitude were obtained using the specified position - source. - */ -}qmiLocInjectPositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects a position to the location engine. */ -typedef struct { - - /* Mandatory */ - /* UTC Position Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the UTC Position Injection request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectPositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ - eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ - eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. */ - eQMI_LOC_LOCK_ALL_V02 = 4, /**< Lock all position sessions. */ - QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocLockEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Lock Type */ - qmiLocLockEnumT_v02 lockType; - /**< Type of lock. - - Valid values: \n - - 0x00000001 -- LOCK_NONE \n - - 0x00000002 -- LOCK_MI \n - - 0x00000003 -- LOCK_MT \n - - 0x00000004 -- LOCK_ALL - - */ -}qmiLocSetEngineLockReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Set Engine Lock Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Engine Lock request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetEngineLockIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetEngineLockReqMsgT is empty - * typedef struct { - * }qmiLocGetEngineLockReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the location engine lock. */ -typedef struct { - - /* Mandatory */ - /* Get Engine Lock Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Engine Lock request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Lock Type */ - uint8_t lockType_valid; /**< Must be set to true if lockType is being passed */ - qmiLocLockEnumT_v02 lockType; - /**< Type of lock. - - Valid values: \n - - 0x00000001 -- LOCK_NONE \n - - 0x00000002 -- LOCK_MI \n - - 0x00000003 -- LOCK_MT \n - - 0x00000004 -- LOCK_ALL - */ -}qmiLocGetEngineLockIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the SBAS configuration. */ -typedef struct { - - /* Mandatory */ - /* SBAS Config */ - uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SBAS configuration is enabled - \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocSetSbasConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the SBAS configuration. */ -typedef struct { - - /* Mandatory */ - /* Set SBAS Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set SBAS Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSbasConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSbasConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSbasConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the SBAS configuration from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get SBAS Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get SBAS Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SBAS Config */ - uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ - uint8_t sbasConfig; - /**< Whether SBAS configuration is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SBAS configuration is enabled - \item 0x00 (FALSE) -- SBAS configuration is disabled - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocGetSbasConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocNmeaSentenceMaskT_v02; -#define QMI_LOC_NMEA_MASK_GGA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000001) /**< Enable GGA type. */ -#define QMI_LOC_NMEA_MASK_RMC_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000002) /**< Enable RMC type. */ -#define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ -#define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ -#define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ -#define QMI_LOC_NMEA_MASK_PQXFI_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000020) /**< Enable PQXFI type. */ -#define QMI_LOC_NMEA_MASK_PSTIS_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000040) /**< Enable PSTIS type. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the NMEA types. */ -typedef struct { - - /* Mandatory */ - /* NMEA Sentence Types */ - qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; - /**< Bitmasks of NMEA types to enable. - - Valid bitmasks: \n - - 0x00000001 -- NMEA_MASK_GGA \n - - 0x00000002 -- NMEA_MASK_RMC \n - - 0x00000004 -- NMEA_MASK_GSV \n - - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG \n - - 0x00000020 -- NMEA_MASK_PQXFI \n - - 0x00000040 -- NMEA_MASK_PSTIS - */ -}qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the NMEA types. */ -typedef struct { - - /* Mandatory */ - /* Set NMEA Types Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of Set NMEA Types request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetNmeaTypesReqMsgT is empty - * typedef struct { - * }qmiLocGetNmeaTypesReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the NMEA types from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get NMEA Types Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get NMEA Types request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* NMEA Sentence Types */ - uint8_t nmeaSentenceType_valid; /**< Must be set to true if nmeaSentenceType is being passed */ - qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; - /**< NMEA types to enable. - - Valid bitmasks: \n - - 0x0000ffff -- NMEA_MASK_ALL \n - - 0x00000001 -- NMEA_MASK_GGA \n - - 0x00000002 -- NMEA_MASK_RMC \n - - 0x00000004 -- NMEA_MASK_GSV \n - - 0x00000008 -- NMEA_MASK_GSA \n - - 0x00000010 -- NMEA_MASK_VTG \n - - 0x00000020 -- NMEA_MASK_PQXFI \n - - 0x00000040 -- NMEA_MASK_PSTIS - */ -}qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Enables/disables Low Power Mode (LPM) configuration. */ -typedef struct { - - /* Mandatory */ - /* Enable Low Power Mode */ - uint8_t lowPowerMode; - /**< Whether to enable Low Power mode:\n - - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ -}qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Enables/disables Low Power Mode (LPM) configuration. */ -typedef struct { - - /* Mandatory */ - /* Set LPM Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Low Power Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetLowPowerModeReqMsgT is empty - * typedef struct { - * }qmiLocGetLowPowerModeReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the LPM status from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get LPM Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get LPM request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable LPM */ - uint8_t lowPowerMode_valid; /**< Must be set to true if lowPowerMode is being passed */ - uint8_t lowPowerMode; - /**< Whether to enable Low Power mode:\n - - 0x01 (TRUE) -- Enable LPM \n - - 0x00 (FALSE) -- Disable LPM */ -}qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ - eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ - eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. */ - eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, /**< Server type is custom PDE. */ - QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Specifies the A-GPS server type and address. */ -typedef struct { - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* IPV4 Address */ - uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ - - /* Optional */ - /* IPV6 Address */ - uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ - - /* Optional */ - /* Uniform Resource Locator */ - uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL address. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetServerReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Specifies the A-GPS server type and address. */ -typedef struct { - - /* Mandatory */ - /* Set Server Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Server request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetServerIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Gets the location server from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server, as defined in qmiLocServerTypeEnumT. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* Server Address Type */ - uint8_t serverAddrTypeMask_valid; /**< Must be set to true if serverAddrTypeMask is being passed */ - qmiLocServerAddrTypeMaskT_v02 serverAddrTypeMask; - /**< Type of address the client wants. If unspecified, the - indication will contain all the types of addresses - it has for the specified server type. - - Valid bitmasks: \n - - 0x01 -- IPV4 \n - - 0x02 -- IPV6 \n - - 0x04 -- URL - */ -}qmiLocGetServerReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the location server from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Server Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Server request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Mandatory */ - /* Server Type */ - qmiLocServerTypeEnumT_v02 serverType; - /**< Type of server, as defined in qmiLocServerTypeEnumT. - - Valid values: \n - - 0x00000001 -- CDMA_PDE \n - - 0x00000002 -- CDMA_MPC \n - - 0x00000003 -- UMTS_SLP \n - - 0x00000004 -- CUSTOM_PDE - */ - - /* Optional */ - /* IPV4 Address */ - uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ - qmiLocIpV4AddrStructType_v02 ipv4Addr; - /**< \n IPV4 address and port. */ - - /* Optional */ - /* IPV6 Address */ - uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ - qmiLocIpV6AddrStructType_v02 ipv6Addr; - /**< \n IPV6 address and port. */ - - /* Optional */ - /* Uniform Resource Locator */ - uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ - char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; - /**< URL. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 256 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetServerIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; -#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001ull) /**< Mask to delete GPS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002ull) /**< Mask to delete GPS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004ull) /**< Mask to delete GPS time. */ -#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008ull) /**< Mask to delete almanac correlation. */ -#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010ull) /**< Mask to delete GLONASS SVDIR. */ -#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020ull) /**< Mask to delete GLONASS SVSTEER. */ -#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040ull) /**< Mask to delete GLONASS time. */ -#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080ull) /**< Mask to delete GLONASS almanac correlation */ -#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100ull) /**< Mask to delete SBAS SVDIR */ -#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200ull) /**< Mask to delete SBAS SVSTEER */ -#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400ull) /**< Mask to delete position estimate */ -#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800ull) /**< Mask to delete time estimate */ -#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000ull) /**< Mask to delete IONO */ -#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000ull) /**< Mask to delete UTC estimate */ -#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000ull) /**< Mask to delete SV health record */ -#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000ull) /**< Mask to delete SADATA */ -#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000ull) /**< Mask to delete RTI */ -#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000ull) /**< Mask to delete SV_NO_EXIST */ -#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000ull) /**< Mask to delete frequency bias estimate */ -typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; -#define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ -#define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ -#define QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000004) /**< Mask to delete cell database OTA position */ -#define QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000008) /**< Mask to delete cell database external reference position */ -#define QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000010) /**< Mask to delete cell database time tag */ -#define QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000020) /**< Mask to delete cell database cell ID */ -#define QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000040) /**< Mask to delete cell database cached cell ID */ -#define QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000080) /**< Mask to delete cell database last service cell */ -#define QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000100) /**< Mask to delete cell database current service cell */ -#define QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000200) /**< Mask to delete cell database neighbor information */ -typedef uint32_t qmiLocDeleteClockInfoMaskT_v02; -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000001) /**< Mask to delete time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_FREQ_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000002) /**< Mask to delete frequency estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_WEEK_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000004) /**< Mask to delete week number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_RTC_TIME_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000008) /**< Mask to delete RTC time from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_TRANSFER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000010) /**< Mask to delete time transfer from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GPSTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000020) /**< Mask to delete GPS time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLOTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000040) /**< Mask to delete GLONASS time estimate from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLODAY_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000080) /**< Mask to delete GLONASS day number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO4YEAR_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000100) /**< Mask to delete GLONASS four year number from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000200) /**< Mask to delete GLONASS RF GRP delay from clock information */ -#define QMI_LOC_MASK_DELETE_CLOCK_INFO_DISABLE_TT_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000400) /**< Mask to delete disable TT from clock information */ -typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; -#define QMI_LOC_MASK_DELETE_EPHEMERIS_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x01) /**< Delete ephemeris for the satellite */ -#define QMI_LOC_MASK_DELETE_ALMANAC_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x02) /**< Delete almanac for the satellite */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t gnssSvId; - /**< SV ID of the satellite whose data is to be deleted. - \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - qmiLocSvSystemEnumT_v02 system; - /**< Indicates to which constellation this SV belongs. - - Valid values: \begin{itemize1} - \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS - \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO - \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS - \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS - \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS - \vspace{-0.18in} \end{itemize1} - */ - - qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; - /**< Indicates if the ephemeris or almanac for a satellite - is to be deleted. \n - Valid values: \n - - 0x01 -- DELETE_EPHEMERIS \n - - 0x02 -- DELETE_ALMANAC - */ -}qmiLocDeleteSvInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; This command is used to delete the location engine - assistance data */ -typedef struct { - - /* Mandatory */ - /* Delete All */ - uint8_t deleteAllFlag; - /**< Whether all assistance data is to be deleted. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- All assistance data is to be deleted; if - this flag is set, all the other information - contained in the optional fields for this - message are ignored - \item 0x00 (FALSE) -- The optional fields in the message are to be - used to determine which data is to be deleted - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Delete SV Info */ - uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ - uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ - qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; - /**< \n List of satellites for which the assistance data is to be deleted. - */ - - /* Optional */ - /* Delete GNSS Data */ - uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ - qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; - /**< Mask for the GNSS data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_GPS_SVDIR - \item 0x00000002 -- DELETE_GPS_SVSTEER - \item 0x00000004 -- DELETE_GPS_TIME - \item 0x00000008 -- DELETE_GPS_ALM_CORR - \item 0x00000010 -- DELETE_GLO_SVDIR - \item 0x00000020 -- DELETE_GLO_SVSTEER - \item 0x00000040 -- DELETE_GLO_TIME - \item 0x00000080 -- DELETE_GLO_ALM_CORR - \item 0x00000100 -- DELETE_SBAS_SVDIR - \item 0x00000200 -- DELETE_SBAS_SVSTEER - \item 0x00000400 -- DELETE_POSITION - \item 0x00000800 -- DELETE_TIME - \item 0x00001000 -- DELETE_IONO - \item 0x00002000 -- DELETE_UTC - \item 0x00004000 -- DELETE_HEALTH - \item 0x00008000 -- DELETE_SADATA - \item 0x00010000 -- DELETE_RTI - \item 0x00020000 -- DELETE_SV_NO_EXIST - \item 0x00040000 -- DELETE_FREQ_BIAS_EST - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Delete Cell Database */ - uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ - qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; - /**< Mask for the cell database assistance data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_CELLDB_POS - \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS - \item 0x00000004 -- DELETE_CELLDB_OTA_POS - \item 0x00000008 -- DELETE_CELLDB_EXT_REF_POS - \item 0x00000010 -- DELETE_CELLDB_TIMETAG - \item 0x00000020 -- DELETE_CELLDB_CELLID - \item 0x00000040 -- DELETE_CELLDB_CACHED_CELLID - \item 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL - \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL - \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Delete Clock Info */ - uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ - qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; - /**< Mask for the clock information assistance data that is to be deleted. - - Valid values: \begin{itemize1} - \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST - \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST - \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER - \item 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME - \item 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER - \item 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST - \item 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST - \item 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER - \item 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER - \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY - \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; This command is used to delete the location engine - assistance data */ -typedef struct { - - /* Mandatory */ - /* Delete Assist Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete Assist Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Enables/disables XTRA-T session control. */ -typedef struct { - - /* Mandatory */ - /* Enable XTRA-T */ - uint8_t xtraTSessionControl; - /**< Whether to enable XTRA-T:\n - - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ -}qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Enables/disables XTRA-T session control. */ -typedef struct { - - /* Mandatory */ - /* Set XTRA-T Session Control Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set XTRA-T Session Control request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetXtraTSessionControlReqMsgT is empty - * typedef struct { - * }qmiLocGetXtraTSessionControlReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the XTRA-T session control value from the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Get XTRA-T Session Control Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get XTRA-T Session Control request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Enable/Disable XTRA-T */ - uint8_t xtraTSessionControl_valid; /**< Must be set to true if xtraTSessionControl is being passed */ - uint8_t xtraTSessionControl; - /**< Whether to enable XTRA-T:\n - - 0x01 (TRUE) -- Enable XTRA-T \n - - 0x00 (FALSE) -- Disable XTRA-T */ -}qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t wifiPositionTime; - /**< Common counter (typically, the number of milliseconds since bootup). - This field is only to be provided if the modem and host processors are - synchronized. */ -}qmiLocWifiFixTimeStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFIFIXERRORCODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_FIX_ERROR_SUCCESS_V02 = 0, /**< WiFi fix is successful. */ - eQMI_LOC_WIFI_FIX_ERROR_WIFI_NOT_AVAILABLE_V02 = 1, /**< WiFi fix failed because WiFi is not available on the device. */ - eQMI_LOC_WIFI_FIX_ERROR_NO_AP_FOUND_V02 = 2, /**< WiFi fix failed because no access points were found. */ - eQMI_LOC_WIFI_FIX_ERROR_UNAUTHORIZED_V02 = 3, /**< WiFi fix failed because the server denied access due to bad authorization - code. */ - eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ - eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. - This may be because the APs found are not in the database. */ - eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, /**< WiFi fix failed, but the cause could not be determined. */ - QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiFixErrorCodeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - double lat; - /**< WiFi position latitude. \n - - Type: Floating point \n - - Units: Degrees */ - - double lon; - /**< WiFi position longitude. \n - - Type: Floating point \n - - Units: Degrees */ - - uint16_t hepe; - /**< WiFi position HEPE.\n - - Units: Meters */ - - uint8_t numApsUsed; - /**< Number of Access Points (AP) used to generate a fix. */ - - qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; - /**< WiFi position error code; set to 0 if the fix succeeds. This position - is only used by a module if the value is 0. If there was a failure, - the error code provided by the WiFi positioning system can be provided - here. - - Valid values: \begin{itemize1} - \item 0x00000000 -- ERROR_SUCCESS - \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE - \item 0x00000002 -- ERROR_NO_AP_FOUND - \item 0x00000003 -- ERROR_UNAUTHORIZED - \item 0x00000004 -- ERROR_SERVER_UNAVAILABLE - \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED - \item 0x00000006 -- ERROR_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocWifiFixPosStructT_v02; /* Type */ -/** - @} - */ - -typedef uint8_t qmiLocWifiApQualifierMaskT_v02; -#define QMI_LOC_WIFI_AP_QUALIFIER_BEING_USED_V02 ((qmiLocWifiApQualifierMaskT_v02)0x01) /**< Access point is being used by the WPS. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_HIDDEN_SSID_V02 ((qmiLocWifiApQualifierMaskT_v02)0x02) /**< AP does not broadcast SSID. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_PRIVATE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x04) /**< AP has encryption turned on. */ -#define QMI_LOC_WIFI_AP_QUALIFIER_INFRASTRUCTURE_MODE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x08) /**< AP is in infrastructure mode and not in ad-hoc/unknown mode. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint8_t macAddr[QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02]; - /**< Associated MAC address of the AP. \n - - Type: Array of unsigned integers \n - - Address length: 6 - */ - - int32_t rssi; - /**< Receive signal strength indicator.\n - - Units: dBm (offset with +100 dB) */ - - uint16_t channel; - /**< WiFi channel on which a beacon was received. */ - - qmiLocWifiApQualifierMaskT_v02 apQualifier; - /**< A bitmask of Boolean qualifiers for APs. - All unused bits in this mask must be set to 0. - - Valid values: \n - - 0x01 -- BEING_USED \n - - 0x02 -- HIDDEN_SSID \n - - 0x04 -- PRIVATE \n - - 0x08 -- INFRASTRUCTURE_MODE - */ -}qmiLocWifiApInfoStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects the WiFi position. */ -typedef struct { - - /* Optional */ - /* WiFi Fix Time */ - uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ - qmiLocWifiFixTimeStructT_v02 wifiFixTime; - /**< \n Time of WiFi position fix. */ - - /* Optional */ - /* WiFi Position */ - uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ - qmiLocWifiFixPosStructT_v02 wifiFixPosition; - /**< \n WiFi position fix. */ - - /* Optional */ - /* WiFi Access Point Information */ - uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ - uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ - qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; - /**< \n AP scan list. */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horizontalReliability_valid; /**< Must be set to true if horizontalReliability is being passed */ - qmiLocReliabilityEnumT_v02 horizontalReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET - \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW - \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW - \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM - \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects the WiFi position. */ -typedef struct { - - /* Mandatory */ - /* Inject WiFi Position Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject WiFi Position request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. */ - eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, /**< WiFi is not available. */ - QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocWifiStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Notifies the location engine of the WiFi status. */ -typedef struct { - - /* Mandatory */ - /* Availablility of WiFi */ - qmiLocWifiStatusEnumT_v02 wifiStatus; - /**< WiFi status information. - - Valid values: \begin{itemize1} - \item 0x00000001 -- WIFI_STATUS_AVAILABLE - \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Notifies the location engine of the WiFi status. */ -typedef struct { - - /* Mandatory */ - /* Status of Notify WiFi Status Request */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Notify WiFi Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetRegisteredEventsReqMsgT is empty - * typedef struct { - * }qmiLocGetRegisteredEventsReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the mask of the events for which a client has - registered. */ -typedef struct { - - /* Mandatory */ - /* Get Registered Events Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Registered Events request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Event Registration Mask */ - uint8_t eventRegMask_valid; /**< Must be set to true if eventRegMask is being passed */ - qmiLocEventRegMaskT_v02 eventRegMask; - /**< Event registration mask. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- POSITION_REPORT - \item 0x00000002 -- GNSS_SV_INFO - \item 0x00000004 -- NMEA - \item 0x00000008 -- NI_NOTIFY_VERIFY_REQ - \item 0x00000010 -- INJECT_TIME_REQ - \item 0x00000020 -- INJECT_PREDICTED_ORBITS_REQ - \item 0x00000040 -- INJECT_POSITION_REQ - \item 0x00000080 -- ENGINE_STATE - \item 0x00000100 -- FIX_SESSION_STATE - \item 0x00000200 -- WIFI_REQ - \item 0x00000400 -- SENSOR_STREAMING_READY_STATUS - \item 0x00000800 -- TIME_SYNC_REQ - \item 0x00001000 -- SET_SPI_STREAMING_REPORT - \item 0x00002000 -- LOCATION_SERVER_CONNECTION_REQ - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCOPERATIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ - eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ - eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ - eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ - eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for a GSM/UMTS network. */ - eQMI_LOC_OPER_MODE_WWAN_V02 = 6, /**< Use WWAN measurements to calculate the position. If this mode is - set, AFLT will be used for 1x networks and OTDOA will be used - for LTE networks. */ - QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocOperationModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Tells the engine to use the specified operation mode while - making the position fixes. This command is not to be used - by multiple clients concurrently. */ -typedef struct { - - /* Mandatory */ - /* Operation Mode */ - qmiLocOperationModeEnumT_v02 operationMode; - /**< Preferred operation mode. - \label{operationMode} - - Valid values: \begin{itemize1} - \item 0x00000001 -- OPER_MODE_DEFAULT - \item 0x00000002 -- OPER_MODE_MSB - \item 0x00000003 -- OPER_MODE_MSA - \item 0x00000004 -- OPER_MODE_STANDALONE - \item 0x00000005 -- OPER_MODE_CELL_ID - \item 0x00000006 -- OPER_MODE_WWAN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetOperationModeReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Tells the engine to use the specified operation mode while - making the position fixes. This command is not to be used - by multiple clients concurrently. */ -typedef struct { - - /* Mandatory */ - /* Set Operation Mode Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Operation Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetOperationModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetOperationModeReqMsgT is empty - * typedef struct { - * }qmiLocGetOperationModeReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Gets the current operation mode from the engine. */ -typedef struct { - - /* Mandatory */ - /* Get Operation Mode Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Operation Mode request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Operation Mode */ - uint8_t operationMode_valid; /**< Must be set to true if operationMode is being passed */ - qmiLocOperationModeEnumT_v02 operationMode; - /**< Current operation mode. - - Valid values: \begin{itemize1} - \item 0x00000001 -- OPER_MODE_DEFAULT - \item 0x00000002 -- OPER_MODE_MSB - \item 0x00000003 -- OPER_MODE_MSA - \item 0x00000004 -- OPER_MODE_STANDALONE - \item 0x00000005 -- OPER_MODE_CELL_ID - \item 0x00000006 -- OPER_MODE_WWAN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetOperationModeIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the SPI status, which - indicates whether the device is stationary. */ -typedef struct { - - /* Mandatory */ - /* Stationary Status */ - uint8_t stationary; - /**< Whether the device is stationary: - \begin{itemize1} - \item 0x00 (FALSE) -- Device is not stationary - \item 0x01 (TRUE) -- Device is stationary - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Confidence */ - uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ - uint8_t confidenceStationary; - /**< Confidence in the Stationary state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocSetSpiStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the SPI status, which - indicates whether the device is stationary. */ -typedef struct { - - /* Mandatory */ - /* Status of SPI Status Request */ - qmiLocStatusEnumT_v02 status; - /**< Status of the SPI Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSpiStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint8_t qmiLocSensorDataFlagMaskT_v02; -#define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting - the sensor data. */ -#define QMI_LOC_SENSOR_DATA_FLAG_SENSOR_TIME_IS_MODEM_TIME_V02 ((qmiLocSensorDataFlagMaskT_v02)0x02) /**< Bitmask to specify that the sensor time stamp is the same as the modem - time stamp. */ -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint16_t timeOffset; - /**< Sample time offset. This time offset must be - relative to the sensor time of the first sample.\n - - Units: Milliseconds */ - - float xAxis; - /**< Sensor x-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ - - float yAxis; - /**< Sensor y-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ - - float zAxis; - /**< Sensor z-axis sample. \n - - Units Accelerometer: ( (meters)/(seconds^2) ) \n - - Units Gyroscope: ( (rads)/(seconds) ) */ -}qmiLoc3AxisSensorSampleStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t timeOfFirstSample; - /**< Denotes a full 32-bit time tag of the first (oldest) sample in this - message. \n - - Units: Milliseconds */ - - qmiLocSensorDataFlagMaskT_v02 flags; - /**< Flags to indicate any deviation from the default measurement - assumptions. All unused bits in this field must be set to 0. - - Valid bitmasks: \begin{itemize1} - \item 0x01 -- SIGN_REVERSAL - \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME - \vspace{-0.18in} \end{itemize1} */ - - uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ - qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; - /**< Variable length array to specify sensor samples. \n - - Maximum length of the array: 50 */ -}qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inject sensor data into the - GNSS location engine. */ -typedef struct { - - /* Optional */ - /* Opaque Identifier */ - uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ - uint32_t opaqueIdentifier; - /**< An opaque identifier that is sent in by the client that will be echoed - in the indication so the client can relate the indication to the - request. */ - - /* Optional */ - /* 3-Axis Accelerometer Data */ - uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ - qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; - /**< \n Accelerometer sensor samples. */ - - /* Optional */ - /* 3-Axis Gyroscope Data */ - uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ - qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; - /**< \n Gyroscope sensor samples. */ -}qmiLocInjectSensorDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inject sensor data into the - GNSS location engine. */ -typedef struct { - - /* Mandatory */ - /* Inject Sensor Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Sensor Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Opaque Identifier */ - uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ - uint32_t opaqueIdentifier; - /**< Opaque identifier that was sent in by the client echoed - so the client can relate the indication to the request. */ - - /* Optional */ - /* Accelerometer Samples Accepted */ - uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ - uint8_t threeAxisAccelSamplesAccepted; - /**< Lets the client know how many 3-axis accelerometer samples - were accepted. */ - - /* Optional */ - /* Gyroscope Samples Accepted */ - uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ - uint8_t threeAxisGyroSamplesAccepted; - /**< Lets the client know how many 3-axis gyroscope samples were - accepted. */ -}qmiLocInjectSensorDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inject time sync data. */ -typedef struct { - - /* Mandatory */ - /* Reference Time Sync Counter */ - uint32_t refCounter; - /**< Must be set to the value that was sent to the control point when the - GNSS location engine requested time sync injection. */ - - /* Mandatory */ - /* Sensor Receive Time */ - uint32_t sensorProcRxTime; - /**< Value of the sensor time when the control point received the - Time Sync Inject request from the GNSS location engine. - - Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 - millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ - - /* Mandatory */ - /* Sensor Transmit Time */ - uint32_t sensorProcTxTime; - /**< Value of the sensor time when the control point injects this message - for use by the GNSS location engine. - - Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 - millisecond, never stopping until the process is rebooted.\n - - Units: Milliseconds */ -}qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inject time sync data. */ -typedef struct { - - /* Mandatory */ - /* Inject Time Sync Data Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Time Sync Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ - eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle */ - eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, /**< Unknown cradle mount state */ - QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocCradleMountStateEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetCradleMountConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetCradleMountConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Cradle Mount Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Cradle Mount Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Cradle Mount State */ - uint8_t cradleMountState_valid; /**< Must be set to true if cradleMountState is being passed */ - qmiLocCradleMountStateEnumT_v02 cradleMountState; - /**< Cradle Mount state set by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED - \item 0x00000001 -- CRADLE_STATE_MOUNTED - \item 0x00000002 -- CRADLE_STATE_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Cradle Mount Confidence */ - uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ - uint8_t confidenceCradleMountState; - /**< Confidence of the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Cradle Mount State */ - qmiLocCradleMountStateEnumT_v02 cradleMountState; - /**< Cradle Mount state set by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED - \item 0x00000001 -- CRADLE_STATE_MOUNTED - \item 0x00000002 -- CRADLE_STATE_UNKNOWN - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Cradle Mount Confidence */ - uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ - uint8_t confidenceCradleMountState; - /**< Confidence in the Cradle Mount state expressed as a percentage.\n - - Range: 0 to 100 */ -}qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the current - cradle mount configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Cradle Mount Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Cradle Mount Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ - eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. */ - eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, /**< Unknown external power state. */ - QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocExternalPowerConfigEnumT_v02; -/** - @} - */ - -/* - * qmiLocGetExternalPowerConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetExternalPowerConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Ext Power Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get External Power Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* External Power State */ - uint8_t externalPowerState_valid; /**< Must be set to true if externalPowerState is being passed */ - qmiLocExternalPowerConfigEnumT_v02 externalPowerState; - /**< Power state; injected by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED - \item 0x00000001 -- EXTERNAL_POWER_CONNECTED - \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to set the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* External Power State */ - qmiLocExternalPowerConfigEnumT_v02 externalPowerState; - /**< Power state; injected by the control point. - - Valid values: \begin{itemize1} - \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED - \item 0x00000001 -- EXTERNAL_POWER_CONNECTED - \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to set the current - external power configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Ext Power Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set External Power Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. */ - eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, /**< PPP PDN type. */ - QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerPDNEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocServerPDNEnumT_v02 pdnType; - /**< PDN type of the APN profile. - - Valid values: \n - - 0x00000001 -- PDN_TYPE_IPV4 \n - - 0x00000002 -- PDN_TYPE_IPV6 \n - - 0x00000003 -- PDN_TYPE_IPV4V6 \n - - 0x00000004 -- PDN_TYPE_PPP - */ - - char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; - /**< APN name. - \begin{itemize1} - \item Type: NULL-terminated string - \item Maximum string length (including NULL terminator): 101 - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocApnProfilesStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. */ - eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, /**< Location server request failed. */ - QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocServerReqStatusEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to inform the service about the - status of the location server connection request that the - service may have sent via the - QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ -typedef struct { - - /* Mandatory */ - /* Connection Handle */ - uint32_t connHandle; - /**< Connection handle that the service specified in the - Location Server Connection request event. */ - - /* Mandatory */ - /* Request Type */ - qmiLocServerRequestEnumT_v02 requestType; - /**< Type of connection request service that was specified in the - Location Server Connection Request event. - - Valid values: \n - - 0x00000001 -- OPEN \n - - 0x00000002 -- CLOSE - */ - - /* Mandatory */ - /* Connection Status */ - qmiLocServerReqStatusEnumT_v02 statusType; - /**< Status of the Connection request. - - Valid values: \n - - 0x00000001 -- STATUS_SUCCESS = 1 \n - - 0x00000002 -- STATUS_FAILURE = 2 - - */ - - /* Optional */ - /* APN Profile */ - uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ - qmiLocApnProfilesStructT_v02 apnProfile; - /**< \n Access Point Name (APN) profile information is present only when - requestType is OPEN and statusType is SUCCESS. */ -}qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to inform the service about the - status of the location server connection request that the - service may have sent via the - QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ -typedef struct { - - /* Mandatory */ - /* Status of Inform Loc Server Conn Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inform Location Server Connection Status request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. */ - eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, /**< V2 VX version. */ - QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocVxVersionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. */ - eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, /**< SUPL version 2.0. */ - QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSuplVersionEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocLppConfigMaskT_v02; -#define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ -#define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ -typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in the control plane. */ -#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in the user plane. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to configure parameters stored - in the nonvolatile memory. */ -typedef struct { - - /* Optional */ - /* SUPL Security */ - uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ - uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SUPL security is enabled - \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* VX Version */ - uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ - qmiLocVxVersionEnumT_v02 vxVersion; - /**< VX version. - - Valid values: \begin{itemize1} - \item 0x00000001 -- VX_VERSION_V1_ONLY - \item 0x00000002 -- VX_VERSION_V2_ONLY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Version */ - uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ - qmiLocSuplVersionEnumT_v02 suplVersion; - /**< SUPL version. - - Valid values: \n - - 0x00000001 -- SUPL_VERSION_1_0 \n - - 0x00000002 -- SUPL_VERSION_2_0 - */ - - /* Optional */ - /* LPP Configuration */ - uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ - qmiLocLppConfigMaskT_v02 lppConfig; - /**< LTE Positioning Profile (LPP) configuration. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE - \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Assisted GLONASS Protocol Mask */ - uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ - qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Configures the protocols that the location service supports - for assisted GLONASS. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP - \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000001ull) /**< Mask for the SUPL security configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ -#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000010ull) /**< Mask for the LPP configuration parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to configure parameters stored - in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Set Config Params Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ - qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; - /**< Identifies parameters that were not set successfully. This field - is sent only if the status is not a success. - - Valid bitmasks: \begin{itemize1} - \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY - \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION - \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION - \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG - \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the configuration - parameters stored in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Config Parameters */ - qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; - /**< Mask denoting the configuration parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x0000000000000001 -- CONFIG_PARAM_MASK_SUPL_SECURITY - \item 0x0000000000000002 -- CONFIG_PARAM_MASK_VX_VERSION - \item 0x0000000000000004 -- CONFIG_PARAM_MASK_SUPL_VERSION - \item 0x0000000000000008 -- CONFIG_PARAM_MASK_LPP_CONFIG - \item 0x0000000000000010 -- CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the configuration - parameters stored in the nonvolatile memory. */ -typedef struct { - - /* Mandatory */ - /* Get Config Params Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Security */ - uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ - uint8_t suplSecurity; - /**< Indicates whether SUPL security is enabled. - \begin{itemize1} - \item 0x01 (TRUE) -- SUPL security is enabled - \item 0x00 (FALSE) -- SUPL security is disabled - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* VX Version */ - uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ - qmiLocVxVersionEnumT_v02 vxVersion; - /**< VX version. - - Valid values: \begin{itemize1} - \item 0x00000001 -- VX_VERSION_V1_ONLY - \item 0x00000002 -- VX_VERSION_V2_ONLY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* SUPL Version */ - uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ - qmiLocSuplVersionEnumT_v02 suplVersion; - /**< SUPL version. - - Valid values: \n - - 0x00000001 -- SUPL_VERSION_1_0 \n - - 0x00000002 -- SUPL_VERSION_2_0 - */ - - /* Optional */ - /* LPP Configuration */ - uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ - qmiLocLppConfigMaskT_v02 lppConfig; - /**< LTE Positioning Profile (LPP) configuration. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE - \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Assisted GLONASS Protocol Mask */ - uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ - qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; - /**< Assisted GLONASS Protocol mask. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP - \item 0x00000002 -- ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02 = 0, /**< Sensors data should be requested whenever a position request is - received. If sensor data are injected, the positioning engine - attempts to improve the heading and positioning performance using sensors. - This is the default. - */ - eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, /**< Inertial sensors are not to be used to aid heading and position - improvement. */ - QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSensorsControlConfigSensorUseEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the sensor control configuration. */ -typedef struct { - - /* Optional */ - /* Sensors Usage */ - uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ - qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; - /**< Controls how sensors are used to aid heading and positioning - performance. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SENSORS_USE_ENABLED: - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. - \item 0x00000001 -- SENSORS_USE_DISABLED: - Inertial sensors are not to be used to aid in heading and - position improvement. - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the sensor control configuration. */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSensorControlConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSensorControlConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor control configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensors Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Sensors Usage */ - uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ - qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; - /**< Controls how sensors are used to aid the heading and positioning - performance. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SENSORS_USE_ENABLED: - Sensors data is to be requested whenever a position request is - received. If sensors data is injected, the GNSS location engine - attempts to improve the heading and positioning performance using - sensors. This is the default. - \item 0x00000001 -- SENSORS_USE_DISABLED: - Inertial sensors are not to be used to aid in the heading and - position improvement. - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocSensorPropertiesMaskT_v02; -#define QMI_LOC_SENSOR_PROPERTIES_MASK_GYRO_BIAS_VARIANCE_RANDOM_WALK_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000001) /**< Denotes the gyro bias variance random walk parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000002) /**< Denotes the velocity random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000004) /**< Denotes the acceleration random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000008) /**< Denotes the angle random walk spectral density parameter. */ -#define QMI_LOC_SENSOR_PROPERTIES_MASK_RATE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000010) /**< Denotes the rate random walk spectral density parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Sets the properties specific to the type of sensor used. - The control point must set sensor properties before they can be - used to aid in heading and positioning performance improvement. - */ -typedef struct { - - /* Optional */ - /* Gyro Bias Random Walk Variance */ - uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ - float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk variance parameter as a positive - floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. - The gyro bias variance random walk parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians^2/seconds^4 - - */ - - /* Optional */ - /* Velocity Random Walk Spectral Density */ - uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ - float velocityRandomWalkSpectralDensity; - /**< Specifies the velocity random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The velocity random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^2/Hertz^0.5 - - */ - - /* Optional */ - /* Acceleration Random Walk Spectral Density */ - uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ - float accelerationRandomWalkSpectralDensity; - /**< Specifies the acceleration random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The acceleration random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^3/Hertz^0.5 - - */ - - /* Optional */ - /* Angle Random Walk Spectral Density */ - uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ - float angleRandomWalkSpectralDensity; - /**< Specifies the angle random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The angle random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds/Hertz^0.5 - - */ - - /* Optional */ - /* Rate Random Walk Spectral Density */ - uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ - float rateRandomWalkSpectralDensity; - /**< Specifies the rate random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The rate random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds^2/Hertz^0.5 - - */ -}qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Sets the properties specific to the type of sensor used. - The control point must set sensor properties before they can be - used to aid in heading and positioning performance improvement. - */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Properties Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Properties request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000007 -- CONFIG_NOT_SUPPORTED - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Set Sensor Properties */ - uint8_t failedSensorPropertiesMask_valid; /**< Must be set to true if failedSensorPropertiesMask is being passed */ - qmiLocSensorPropertiesMaskT_v02 failedSensorPropertiesMask; - /**< This field will be sent only if the status is not a success. - Identifies the parameters that were not set successfully. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK - \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Retrieves the current sensor properties. */ -typedef struct { - - /* Mandatory */ - /* Sensor Properties Config Parameters */ - qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; - /**< Mask denoting the sensor properties parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK - \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY - \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor properties. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Properties Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensors Properties request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000007 -- CONFIG_NOT_SUPPORTED - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Gyro Bias Random Walk Variance */ - uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ - float gyroBiasVarianceRandomWalk; - /**< Specifies the gyro bias random walk variance parameter as a positive - floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. - The gyro bias variance random walk parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians^2/seconds^4 - - */ - - /* Optional */ - /* Velocity Random Walk Spectral Density */ - uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ - float velocityRandomWalkSpectralDensity; - /**< Specifies the velocity random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The velocity random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^2/Hertz^0.5 - - */ - - /* Optional */ - /* Acceleration Random Walk Spectral Density */ - uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ - float accelerationRandomWalkSpectralDensity; - /**< Specifies the acceleration random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The acceleration random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Meters/seconds^3/Hertz^0.5 - - */ - - /* Optional */ - /* Angle Random Walk Spectral Density */ - uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ - float angleRandomWalkSpectralDensity; - /**< Specifies the angle random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The angle random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds/Hertz^0.5 - - */ - - /* Optional */ - /* Rate Random Walk Spectral Density */ - uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ - float rateRandomWalkSpectralDensity; - /**< Specifies the rate random walk spectral density parameter as a positive - floating-point value. This value does not have any internal defaults. - The rate random walk spectral density parameter is derived from either the - sensors data sheet or a sensors conformance test. \n - - Units: Radians/seconds^2/Hertz^0.5 - - */ -}qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. - This mode can optimize power consumption and give a - power-balanced positioning and heading enhancement using - inertial sensors */ - eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, /**< Sensors usage is to be forced ON. - This mode can be requested by the control point when - power consumption is not a restriction to the use of - inertial sensors. */ - QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocSensorPerformanceControlModeEnumT_v02; -/** - @} - */ - -typedef uint32_t qmiLocSensorAlgorithmMaskT_v02; -#define QMI_LOC_SENSOR_ALGORITHM_MASK_DISABLE_INS_POSITIONING_FILTER_V02 ((qmiLocSensorAlgorithmMaskT_v02)0x00000001) /**< Inertial sensors are not to be used in Accelerometer-integrated fashion with - GNSS. They can still be used for aiding in heading improvements. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Provides fine-grained control of sensor based positioning - performance */ -typedef struct { - - /* Optional */ - /* Sensor Performance Control Mode */ - uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ - qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; - /**< Controls when sensors data is requested during GNSS fix processing. - This field is relevant only when sensors have been enabled using the - sensors control configuration. - - Valid values: \begin{itemize1} - \item 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data - injection based on internal criteria. This is the default. - \item 0x00000001 -- FORCED: \n - The GNSS location engine must request use of sensors every time - the GNSS location engine turns on. - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Accelerometer Sampling Specification */ - uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; - /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location - engine is to request acceleration data to be used by the low data rate - filter. The sensor data rate is specified in terms of the nominal number - of samples per batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; - /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location - engine is to request gyro data to be used by the high data rate filter. - The sensor data rate is specified in terms of the nominal number of - samples per batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Algorithm Configuration */ - uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ - qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; - /**< Sets which sensor algorithms are to be used when processing sensor data. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* High Data Rate Filter Accelerometer Sampling Specification */ - uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ - - /* Optional */ - /* High Data Rate Filter Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data rate - is specified in terms of the nominal number of samples per batch and the - number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ -}qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000010) /**< Failed to set the accelerometer sampling specification. */ -#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000020) /**< Failed to set the gyroscope sampling specification. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Provides fine-grained control of sensor based positioning - performance */ -typedef struct { - - /* Mandatory */ - /* Set Sensor Perf Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Sensor Performance Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Configuration */ - uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ - qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; - /**< Identifies parameters that were not configured successfully. This field - is sent only if the status is not a success. - - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- PERFORMANCE_MODE - \item 0x00000002 -- ACCEL_SAMPLING_SPEC - \item 0x00000004 -- GYRO_SAMPLING_SPEC - \item 0x00000008 -- ALGORITHM_CONFIG - \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH - \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty - * typedef struct { - * }qmiLocGetSensorPerformanceControlConfigReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Retrieves the current sensor performance control - configuration. */ -typedef struct { - - /* Mandatory */ - /* Get Sensor Perf Control Config Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Sensor Performance Control Configuration request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Performance Control Mode */ - uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ - qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; - /**< Controls when sensor data is requested during GNSS fix processing. - This field is relevant only when sensors have been enabled using the - sensor control configuration. - - Valid values: \begin{itemize1} - \item 0x00000000 -- AUTO: \n - The GNSS location engine can decide when to request sensor data - injection based on internal criteria. This is the default. - \item 0x0000001 -- FORCED: \n - The GNSS location engine must request use of the sensors every time - the GNSS location engine turns on. - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Accelerometer Sampling Specification */ - uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2Hz batching rate. - */ - - /* Optional */ - /* Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data - rate is specified in terms of the nominal number of samples per batch - and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 10 Hz sampling rate and 2 Hz batching rate. - */ - - /* Optional */ - /* Algorithm Configuration */ - uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ - qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; - /**< Informs which sensor algorithms are currently set. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* High Data Rate Filter Accelerometer Sampling Specification */ - uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - acceleration data to be used by the high data rate filter. The sensor - data rate is specified in terms of the nominal number of samples per - batch and the number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ - - /* Optional */ - /* High Data Rate Filter Gyroscope Sampling Specification */ - uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ - qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; - /**< \n Sets the nominal rate at which the GNSS location engine is to request - gyro data to be used by the high data rate filter. The sensor data rate - is specified in terms of the nominal number of samples per batch and the - number of batches per second. - However, the final control of the actual requested rate resides with - the Sensors Manager Module/GNSS location engine. \n - Default: 100 Hz sampling rate and 4 Hz batching rate. - */ -}qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects a SUPL certificate to be used in AGNSS sessions. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate ID */ - uint8_t suplCertId; - /**< Certificate ID of the SUPL certificate. \n - - Units: Bytes \n - - Range: 0 to 9 */ - - /* Mandatory */ - /* SUPL Certificate Data */ - uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ - uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; - /**< SUPL certificate contents. \n - - Type: Array of bytes. \n - - Maximum certificate size: 2000 bytes */ -}qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects a SUPL certificate to be used in AGNSS sessions. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate Injection Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject SUPL Certificate request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Deletes a SUPL certificate. */ -typedef struct { - - /* Optional */ - /* SUPL Certificate ID */ - uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ - uint8_t suplCertId; - /**< Certificate ID of the SUPL certificate to be deleted. \n - - Units: Bytes \n - - Range: 0 to 9 \n - If suplCertId is not specified, - all SUPL certificates are deleted. */ -}qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Deletes a SUPL certificate. */ -typedef struct { - - /* Mandatory */ - /* SUPL Certificate Deletion Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete SUPL Certificate request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< Denotes whether the position engine uses the - injected position in a direct position calculation. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< Denotes whether the position engine filters the - SV usage in the fix. */ -#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< Denotes whether the position engine stores assistance data - in persistent memory. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to configure position engine - functionality. */ -typedef struct { - - /* Optional */ - /* Injected Position Control */ - uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ - uint8_t injectedPositionControl; - /**< Controls how the injected position is used in the position engine. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Use the injected position in a direct position - calculation - \item 0x00 (FALSE) -- Do not use the injected position in a direct - position calculation - \end{itemize1} - The default value is TRUE. - */ - - /* Optional */ - /* Filter SV Usage */ - uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ - uint8_t filterSvUsage; - /**< Controls whether SV usage is filtered in a position fix. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Filter the usage of SVs in the fix - \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix - \end{itemize1} - The default value is FALSE. - */ - - /* Optional */ - /* Store Assist Data */ - uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ - uint8_t storeAssistData; - /**< Controls whether assistance data is to be stored in - persistent memory. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Store assistance data in persistent memory - \item 0x00 (FALSE) -- Do not store assistance data in persistent memory - \end{itemize1} - The default value is TRUE. - */ -}qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to configure position engine - functionality. */ -typedef struct { - - /* Mandatory */ - /* Set Position Engine Configuration Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Set Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ - qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; - /**< Identifies the parameters that were not set successfully. - This field is sent only if the status is other than SUCCESS. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- INJECTED_POSITION_CONTROL - \item 0x00000002 -- FILTER_SV_USAGE - \item 0x00000004 -- STORE_ASSIST_DATA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the position engine - configuration parameters. */ -typedef struct { - - /* Mandatory */ - /* Config Parameters */ - qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; - /**< Mask denoting the configuration parameters to be retrieved. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- INJECTED_POSITION_CONTROL - \item 0x00000002 -- FILTER_SV_USAGE - \item 0x00000004 -- STORE_ASSIST_DATA - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the position engine - configuration parameters. */ -typedef struct { - - /* Mandatory */ - /* Get Position Engine Configuration Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Configuration Parameters request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Injected Position Control */ - uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ - uint8_t injectedPositionControl; - /**< Specifies whether the injected position is used for a direct calculation - in the position engine. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- The injected position is used in a direct - position calculation - \item 0x00 (FALSE) -- The injected position is not used in a direct - position calculation - \end{itemize1} - The default value is TRUE. - */ - - /* Optional */ - /* Filter SV Usage */ - uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ - uint8_t filterSvUsage; - /**< Specifies whether SV usage is filtered in a position fix. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- SV usage is filtered in the fix - \item 0x00 (FALSE) -- SV usage is not filtered in the fix - \end{itemize1} - The default value is FALSE. - */ - - /* Optional */ - /* Store Assist Data */ - uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ - uint8_t storeAssistData; - /**< Specifies whether assistance data is stored in persistent memory. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Assistance data is stored in persistent memory - \item 0x00 (FALSE) -- Assistance data is not stored in persistent - memory - \end{itemize1} - The default value is TRUE. - */ -}qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint8_t qmiLocGeofenceBreachMaskT_v02; -#define QMI_LOC_GEOFENCE_BREACH_ENTERING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x01) /**< If this mask is set, a breach event is reported - when the Geofence is entered. */ -#define QMI_LOC_GEOFENCE_BREACH_LEAVING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x02) /**< If this mask is set, a breach event is reported - when the Geofence is exited. */ -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCERESPONSIVENESSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_LOW_V02 = 0x01, /**< The Geofence is monitored for a breach at a - lower rate. The gap between actual breach and - the time it is reported is higher. This - setting results in lower power usage. */ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a - medium rate. This is the default setting. */ - eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, /**< The Geofence is monitored for a breach at a - high rate. The gap between actual breach and - the time it is reported is low. This results - in higher power usage. */ - QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceResponsivenessEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCECONFIDENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_CONFIDENCE_LOW_V02 = 0x01, /**< The Geofence engine indicates a breach with - low confidence. This setting results in lower - power usage. This setting can impact the "yield" because - incorrect breach events may be sent. */ - eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with - medium confidence. This is the default setting. */ - eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, /**< The Geofence engine indicates a breach with - high confidence. This setting results in higher - power usage. */ - QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceConfidenceEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - double latitude; - /**< Latitude of the center of the Geofence.*/ - - double longitude; - /**< Longitude of the center of the Geofence.*/ - - uint32_t radius; - /**< Radius of the circular Geofence in meters. */ -}qmiLocCircularGeofenceArgsStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. */ - eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, /**< Position outside a Geofence. */ - QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofencePositionEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to add a circular Geofence. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Add Circular Geofence - indication. */ - - /* Mandatory */ - /* Circular Geofence Arguments */ - qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; - - /* Mandatory */ - /* Breach Event Mask */ - qmiLocGeofenceBreachMaskT_v02 breachMask; - /**< Specifies the breach events in which the client is interested. - - Valid values: \begin{itemize1} - \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK - \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ - - /* Mandatory */ - /* Include Position in Breach Event */ - uint8_t includePosition; - /**< Specifies whether the Geofence engine is to include the position - in a breach event. - - Valid values: \begin{itemize1} - \item 0x01 (TRUE) -- Position will be reported with the breach event - \item 0x00 (FALSE) -- Position will not be reported with the breach - event - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Responsiveness */ - uint8_t responsiveness_valid; /**< Must be set to true if responsiveness is being passed */ - qmiLocGeofenceResponsivenessEnumT_v02 responsiveness; - /**< Specifies the rate of detection for a Geofence breach. - This may impact the time lag between the actual breach event and - when it is reported. This parameter has power implications - and is to be fine-tuned to optimize power savings. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW - \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED - \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Confidence */ - uint8_t confidence_valid; /**< Must be set to true if confidence is being passed */ - qmiLocGeofenceConfidenceEnumT_v02 confidence; - /**< Given a breach event, the confidence determines the probability - that the breach happened at the Geofence boundary. - This parameter has power implications and - is to be fine-tuned to optimize power savings. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW - \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED - \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH - \vspace{-0.18in} \end{itemize1} */ -}qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to add a circular Geofence. */ -typedef struct { - - /* Mandatory */ - /* Add Circular Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Add Circular Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \item 0x00000008 -- INSUFFICIENT_MEMORY - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Add Circular - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Geofence identifier allocated by the engine. - The client must include this identifier in all transactions - pertaining to this Geofence. */ -}qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to delete a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence that is to be deleted. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Delete Geofence - indication. */ -}qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to delete a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Delete Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Delete Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was deleted. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Delete - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ -}qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. */ - eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, /**< The Geofence was initiated by the device. */ - QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceOriginEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. */ - eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, /**< The Geofence monitoring is suspended. */ - QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocGeofenceStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to query a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence that is to be queried. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned with the Query Geofence - indication. */ -}qmiLocQueryGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to query a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Query Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Query Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was queried. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Query - Geofence request. This parameter will always be present - if the status field is set to SUCCESS. */ - - /* Optional */ - /* Geofence Origin */ - uint8_t geofenceOrigin_valid; /**< Must be set to true if geofenceOrigin is being passed */ - qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; - /**< Originator of the Geofence. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK - \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE - \vspace{-0.18in} \end{itemize1} - */ - - /* Optional */ - /* Position with Respect to Geofence */ - uint8_t posWrtGeofence_valid; /**< Must be set to true if posWrtGeofence is being passed */ - qmiLocGeofencePositionEnumT_v02 posWrtGeofence; - /**< Indicates if the client is currently inside or outside - the Geofence. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_POSITION_INSIDE - \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Circular Geofence Parameters */ - uint8_t circularGeofenceArgs_valid; /**< Must be set to true if circularGeofenceArgs is being passed */ - qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; - - /* Optional */ - /* Geofence State */ - uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ - qmiLocGeofenceStateEnumT_v02 geofenceState; - /**< Specifies whether the Geofence is to be actively monitored. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_STATE_ACTIVE - \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ -}qmiLocQueryGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to edit a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Geofence ID */ - uint32_t geofenceId; - /**< Identifier for the Geofence to be edited. */ - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Edit Geofence - request. This parameter will always be present if the - status field is set to SUCCESS. - */ - - /* Optional */ - /* Geofence State */ - uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ - qmiLocGeofenceStateEnumT_v02 geofenceState; - /**< Specifies whether the Geofence is to be actively monitored. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_STATE_ACTIVE - \item 0x00000002 -- GEOFENCE_STATE_SUSPEND - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Breach Event Mask */ - uint8_t breachMask_valid; /**< Must be set to true if breachMask is being passed */ - qmiLocGeofenceBreachMaskT_v02 breachMask; - /**< Specifies the breach events in which the client is interested. - - Valid values: \begin{itemize1} - \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK - \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEditGeofenceReqMsgT_v02; /* Message */ -/** - @} - */ - -typedef uint32_t qmiLocGeofenceConfigParamMaskT_v02; -#define QMI_LOC_GEOFENCE_PARAM_MASK_GEOFENCE_STATE_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000001) /**< Mask for the Geofence state parameter. */ -#define QMI_LOC_GEOFENCE_PARAM_MASK_BREACH_MASK_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000002) /**< Mask for Geofence breach mask parameter. */ -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to edit a Geofence. */ -typedef struct { - - /* Mandatory */ - /* Edit Geofence Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Edit Geofence request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000005 -- PHONE_OFFLINE - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Geofence ID */ - uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ - uint32_t geofenceId; - /**< Identifier for the Geofence that was edited. */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is specified in the Edit Geofence request. */ - - /* Optional */ - /* Failed Parameters */ - uint8_t failedParams_valid; /**< Must be set to true if failedParams is being passed */ - qmiLocGeofenceConfigParamMaskT_v02 failedParams; - /**< Specified only when the status is not set to SUCCESS. If - the mask corresponding to a field is set, it indicates that - the Geofence parameter could not be edited. - - Valid values: \begin{itemize1} - \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE - \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK - \vspace{-0.18in} \end{itemize1} */ -}qmiLocEditGeofenceIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to get the best available - position estimate from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The transaction ID - is returned in the Get Best Available Position indication. */ -}qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to get the best available - position estimate from the location engine. */ -typedef struct { - - /* Mandatory */ - /* Get Best Available Position Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get Best Available Position request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Get Best - Available Position request. This parameter will - always be present if the status field is set to - SUCCESS. */ - - /* Optional */ - /* Latitude */ - uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ - double latitude; - /**< Latitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -90.0 to 90.0 \begin{itemize1} - \item Positive values indicate northern latitude - \item Negative values indicate southern latitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Longitude */ - uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ - double longitude; - /**< Longitude (specified in WGS84 datum). - \begin{itemize1} - \item Type: Floating point - \item Units: Degrees - \item Range: -180.0 to 180.0 \begin{itemize1} - \item Positive values indicate eastern longitude - \item Negative values indicate western longitude - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ - - /* Optional */ - /* Circular Horizontal Position Uncertainty */ - uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ - float horUncCircular; - /**< Horizontal position uncertainty (circular).\n - - Units: Meters */ - - /* Optional */ - /* Altitude With Respect to Ellipsoid */ - uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ - float altitudeWrtEllipsoid; - /**< Altitude with respect to the WGS84 ellipsoid.\n - - Units: Meters \n - - Range: -500 to 15883 */ - - /* Optional */ - /* Vertical Uncertainty */ - uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ - float vertUnc; - /**< Vertical uncertainty.\n - - Units: Meters */ - - /* Optional */ - /* UTC Timestamp */ - uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ - uint64_t timestampUtc; - /**< UTC timestamp. - \begin{itemize1} - \item Units: Milliseconds since Jan. 1, 1970 - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Time Uncertainty */ - uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ - float timeUnc; - /**< Time uncertainty. \n - - Units: Milliseconds */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ - uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ - float horUncEllipseSemiMinor; - /**< Semi-minor axis of horizontal elliptical uncertainty. \n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Semi-Major Axis */ - uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ - float horUncEllipseSemiMajor; - /**< Semi-major axis of horizontal elliptical uncertainty. \n - - Units: Meters */ - - /* Optional */ - /* Horizontal Elliptical Uncertainty Azimuth */ - uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ - float horUncEllipseOrientAzimuth; - /**< Elliptical horizontal uncertainty azimuth of orientation. \n - - Units: Decimal degrees \n - - Range: 0 to 180 */ - - /* Optional */ - /* Horizontal Circular Confidence */ - uint8_t horCircularConfidence_valid; /**< Must be set to true if horCircularConfidence is being passed */ - uint8_t horCircularConfidence; - /**< Horizontal circular uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Elliptical Confidence */ - uint8_t horEllipticalConfidence_valid; /**< Must be set to true if horEllipticalConfidence is being passed */ - uint8_t horEllipticalConfidence; - /**< Horizontal elliptical uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Horizontal Reliability */ - uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ - qmiLocReliabilityEnumT_v02 horReliability; - /**< Specifies the reliability of the horizontal position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Horizontal Speed */ - uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ - float horSpeed; - /**< Horizontal speed. \n - - Units: Meters/second */ - - /* Optional */ - /* Horizontal Speed Uncertainty */ - uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ - float horSpeedUnc; - /**< Horizontal speed uncertainty. \n - - Units: Meters/second */ - - /* Optional */ - /* Altitude With Respect to Sea Level */ - uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ - float altitudeWrtMeanSeaLevel; - /**< Altitude with respect to mean sea level. \n - - Units: Meters */ - - /* Optional */ - /* Vertical Confidence */ - uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ - uint8_t vertConfidence; - /**< Vertical uncertainty confidence. \n - - Units: Percent \n - - Range: 0 to 99 */ - - /* Optional */ - /* Vertical Reliability */ - uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ - qmiLocReliabilityEnumT_v02 vertReliability; - /**< Specifies the reliability of the vertical position. - - Valid values: \begin{itemize1} - \item 0x00000000 -- RELIABILITY_NOT_SET - \item 0x00000001 -- RELIABILITY_VERY_LOW - \item 0x00000002 -- RELIABILITY_LOW - \item 0x00000003 -- RELIABILITY_MEDIUM - \item 0x00000004 -- RELIABILITY_HIGH - \vspace{-0.18in} \end{itemize1}*/ - - /* Optional */ - /* Vertical Speed */ - uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ - float vertSpeed; - /**< Vertical speed. \n - - Units: Meters/second */ - - /* Optional */ - /* Vertical Speed Uncertainty */ - uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ - float vertSpeedUnc; - /**< Vertical speed uncertainty. \n - - Units: Meters/second */ - - /* Optional */ - /* Heading */ - uint8_t heading_valid; /**< Must be set to true if heading is being passed */ - float heading; - /**< Heading. \n - - Units: Degrees \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Heading Uncertainty */ - uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ - float headingUnc; - /**< Heading uncertainty. \n - - Type: Floating point \n - - Range: 0 to 359.999 */ - - /* Optional */ - /* Magnetic Deviation */ - uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ - float magneticDeviation; - /**< Difference between the bearing to true north and the bearing shown - on a magnetic compass. The deviation is positive when the magnetic - north is east of true north. */ - - /* Optional */ - /* Technology Used Mask */ - uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ - qmiLocPosTechMaskT_v02 technologyMask; - /**< Technology used in computing this fix. - - Valid bitmasks: \begin{itemize1} - \item 0x00000001 -- SATELLITE - \item 0x00000002 -- CELLID - \item 0x00000004 -- WIFI - \item 0x00000008 -- SENSORS - \item 0x00000010 -- REFERENCE_LOCATION - \item 0x00000020 -- INJECTED_COARSE_POSITION - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Dilution of Precision */ - uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ - qmiLocDOPStructT_v02 DOP; - - /* Optional */ - /* GPS Time */ - uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ - qmiLocGPSTimeStructT_v02 gpsTime; - - /* Optional */ - /* Time Source */ - uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ - qmiLocTimeSourceEnumT_v02 timeSrc; - /**< Time source. - - Valid values: \begin{itemize1} - \item 0x00000000 -- TIME_SRC_INVALID - \item 0x00000001 -- TIME_SRC_NETWORK_TIME_TRANSFER - \item 0x00000002 -- TIME_SRC_NETWORK_TIME_TAGGING - \item 0x00000003 -- TIME_SRC_EXTERNAL_INPUT - \item 0x00000004 -- TIME_SRC_TOW_DECODE - \item 0x00000005 -- TIME_SRC_TOW_CONFIRMED - \item 0x00000006 -- TIME_SRC_TOW_AND_WEEK_CONFIRMED - \item 0x00000007 -- TIME_SRC_NAV_SOLUTION - \item 0x00000008 -- TIME_SRC_SOLVE_FOR_TIME - \vspace{-0.18in} \end{itemize1} */ - - /* Optional */ - /* Sensor Data Usage */ - uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ - qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; - - /* Optional */ - /* SVs Used to Calculate the Fix */ - uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ - uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ - uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; - /**< Each entry in the list contains the SV ID of a satellite - used for calculating this position report. The following - information is associated with each SV ID: \begin{itemize1} - \item Range: \begin{itemize1} - \item For GPS: 1 to 32 - \item For SBAS: 33 to 64 - \item For GLONASS: 65 to 96 - \item For QZSS: 193 to 197 - \vspace{-0.18in} \end{itemize1} \end{itemize1} */ -}qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known. */ - eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is Stationary. */ - eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, /**< Device state is In Motion. */ - QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocMotionStateEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known. */ - eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in Pedestrian mode; nothing else is known about the movement. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian Walking mode. */ - eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian Running mode. */ - eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, /**< Device movement is in Vehicular mode; nothing else is known about the movement. */ - QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocMotionModeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - qmiLocMotionStateEnumT_v02 motion_state; - /**< Current motion state of the user. \n - - Valid values: \begin{itemize1} - \item eQMI_LOC_MOTION_STATE_UNKNOWN (0) -- Device state is not known. - \item eQMI_LOC_MOTION_STATE_STATIONARY (1) -- Device state is Stationary. - \item eQMI_LOC_MOTION_STATE_IN_MOTION (2) -- Device state is In Motion. - \vspace{0.06in} \end{itemize1} - - Absolute rest and relative rest are both indicated by setting motion_state - to Stationary. The relative rest state can be distinguished from absolute - rest by reducing probability_of_state. - */ - - qmiLocMotionModeEnumT_v02 motion_mode; - /**< Modes of user motion. \n - - Valid values: \begin{itemize1} - \item eQMI_LOC_MOTION_MODE_ UNKNOWN (0) -- Device movement is not known. - \item eQMI_LOC_MOTION_MODE_ STATIONARY (1) -- Device is not moving. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_UNKNOWN (200) -- Device movement - is in Pedestrian mode; nothing else is known about the movement. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_WALKING (201) -- Device movement - is in Pedestrian Walking mode. - \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_RUNNING (202) -- Device movement - is in Pedestrian Running mode. - \item eQMI_LOC_MOTION_MODE_ VEHICLE_UNKNOWN (300) -- Device movement is - in Vehicular mode; nothing else is known about the movement. - \vspace{0.06in} \end{itemize1} - - The motion_mode value is independent of the motion_state value. - */ - - float probability_of_state; - /**< Probability that the device is actually undergoing the motion state - specified by the combination of the values of motion_state, motion_mode, - and motion_sub_mode. \vspace{0.06in} - - This value is a floating point number in the range of 0 to 100, in - units of percent probability. Any value greater than 99.9999 is - applied as 99.9999. \vspace{0.06in} - - It is recommended that if a particular combination of motion_state and - motion_mode cannot be determined with more than 50 percent confidence, - that a more general statement of user motion be made. - For example, if the mode of In-Motion + Pedestrian-Running can only be - determined with 50 percent probability, and the simpler statement of In-Motion - can be determined with 90 percent probability, it is recommended that this field - be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} - - If the motion_state is not known, the value in this field is not used. - */ - - uint16_t age; - /**< Age of the motion data in milliseconds at the time of injection. - */ - - uint16_t timeout; - /**< If the age of the motion data input exceeds the timeout value, the data - will no longer be used. The timeout value is in units of milliseconds. - Values in the range of 0 to 10000 are accepted. If 65535 is provided, - the motion data input is applied until the next input is - received. \vspace{0.06in} - - If the determination of motion data is an instantaneous observation - and no notice is guaranteed to be given via the QMI on a change in the - state of the motion data, it is recommended that this field be set to 0. \vspace{0.06in} - - If the determination of motion data is continuously monitored - external to the QMI and an update is always applied to the QMI upon any - change in state, a value of 65535 is used for this field. - Note that in this case, if a certain mode is set and is not later - unset (e.g., by sending in the request message with a user motion - state of Unknown), the value is applied indefinitely. - */ -}qmiLocMotionDataStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Injects motion data for MSM GPS service use. */ -typedef struct { - - /* Mandatory */ - /* Motion Data */ - qmiLocMotionDataStructT_v02 motion_data; - /**< Current motion data of the client */ -}qmiLocInjectMotionDataReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Injects motion data for MSM GPS service use. */ -typedef struct { - - /* Mandatory */ - /* Inject Motion Data Request Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Motion Data request. - - Valid values: \begin{itemize1} - \item 0x00000000 -- SUCCESS - \item 0x00000001 -- GENERAL_FAILURE - \item 0x00000002 -- UNSUPPORTED - \item 0x00000003 -- INVALID_ PARAMETER - \item 0x00000004 -- ENGINE_BUSY - \item 0x00000006 -- TIMEOUT - \vspace{-0.18in} \end{itemize1} - */ -}qmiLocInjectMotionDataIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used by the control point to retrieve the list of network - initiated Geofence IDs. */ -typedef struct { - - /* Mandatory */ - /* Transaction ID */ - uint32_t transactionId; - /**< Identifies the transaction. The same transaction ID - will be returned in the Get NI Geofence ID List indication. */ -}qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used by the control point to retrieve the list of network - initiated Geofence IDs. */ -typedef struct { - - /* Mandatory */ - /* Get NI Geofence ID List status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Get NI Geofence ID List request. - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ - - /* Optional */ - /* Transaction ID */ - uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ - uint32_t transactionId; - /**< Transaction ID that was specified in the Get NI - Geofence ID List request. */ - - /* Optional */ - /* NI Geofence ID List */ - uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ - uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ - uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; - /**< List containing the NI Geofence IDs. - - Type: Array of unsigned 32-bit integers \n - - Maximum NI Geofence ID List length: 16 */ -}qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_aggregates - @{ - */ -typedef struct { - - uint32_t MCC; - /**< GSM mobile country code. Refer to ITU-T E.212 specification */ - - uint32_t MNC; - /**< GSM mobile network code. Refer to ITU-T E.212 specification*/ - - uint32_t LAC; - /**< GSM location area code.Refer to ITU-T E.212 specification */ - - uint32_t CID; - /**< GSM cell identification.Refer to ITU-T E.212 specification */ -}qmiLocGSMCellIdStructT_v02; /* Type */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used to inject GSM Cell information into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* GSM Cell ID */ - qmiLocGSMCellIdStructT_v02 gsmCellId; - /**< Identifies the GSM Cell the device is currently camped on.*/ - - /* Mandatory */ - /* Roaming Status */ - uint8_t roamingStatus; - /**< Whether the device is roaming. - \begin{itemize1} - \item 0x01 (TRUE) -- The device is roaming. - \item 0x00 (FALSE) -- The device is not roaming. - \vspace{-0.18in} \end{itemize1}*/ -}qmiLocInjectGSMCellInfoReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to inject GSM Cell information into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Inject GSM Cell Info Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject GSM Cell Info request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT */ -}qmiLocInjectGSMCellInfoIndMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_enums - @{ - */ -typedef enum { - QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL_V02 = 0, /**< SUPL netwrok initiated message is being injected. */ - QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ -}qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02; -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Request Message; Used to inject a network initiated message into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Injected Network Initiated Message Type */ - qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02 injectedNIMessageType; - /**< Type of the network initiated message being injected - Valid Values: - - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL (0) -- SUPL netwrok initiated message is being injected. */ - - /* Mandatory */ - /* Injected Network Initiated Message */ - uint32_t injectedNIMessage_len; /**< Must be set to # of elements in injectedNIMessage */ - uint8_t injectedNIMessage[QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02]; - /**< Network initiated message body. - If the inject NI message type is TYPE_SUPL, the message contains - a SUPL INIT message as defined in OMA-TS-ULP-V2_0-20110527-C specification. */ -}qmiLocInjectNetworkInitiatedMessageReqMsgT_v02; /* Message */ -/** - @} - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to inject a network initiated message into the location - engine. */ -typedef struct { - - /* Mandatory */ - /* Inject Network Initiated Message Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Inject Network Initiated Message request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT \n - - 0x00000008 -- INSUFFICIENT_MEMORY \n */ -}qmiLocInjectNetworkInitiatedMessageIndMsgT_v02; /* Message */ -/** - @} - */ - -/* - * qmiLocWWANOutOfServiceNotificationReqMsgT is empty - * typedef struct { - * }qmiLocWWANOutOfServiceNotificationReqMsgT_v02; - */ - -/** @addtogroup loc_qmi_messages - @{ - */ -/** Indication Message; Used to notify the location engine that the device is - no longer camped. */ -typedef struct { - - /* Mandatory */ - /* Notify WWAN Out of Service Status */ - qmiLocStatusEnumT_v02 status; - /**< Status of the Notify WWAN out of service request. - - Valid values: \n - - 0x00000000 -- SUCCESS \n - - 0x00000001 -- GENERAL_FAILURE \n - - 0x00000002 -- UNSUPPORTED \n - - 0x00000003 -- INVALID_PARAMETER \n - - 0x00000004 -- ENGINE_BUSY \n - - 0x00000006 -- TIMEOUT \n - */ -}qmiLocWWANOutOfServiceNotificationIndMsgT_v02; /* Message */ -/** - @} - */ - -/*Service Message Definition*/ -/** @addtogroup loc_qmi_msg_ids - @{ - */ -#define QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02 0x0020 -#define QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02 0x0020 -#define QMI_LOC_REG_EVENTS_REQ_V02 0x0021 -#define QMI_LOC_REG_EVENTS_RESP_V02 0x0021 -#define QMI_LOC_START_REQ_V02 0x0022 -#define QMI_LOC_START_RESP_V02 0x0022 -#define QMI_LOC_STOP_REQ_V02 0x0023 -#define QMI_LOC_STOP_RESP_V02 0x0023 -#define QMI_LOC_EVENT_POSITION_REPORT_IND_V02 0x0024 -#define QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02 0x0025 -#define QMI_LOC_EVENT_NMEA_IND_V02 0x0026 -#define QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02 0x0027 -#define QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02 0x0028 -#define QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02 0x0029 -#define QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02 0x002A -#define QMI_LOC_EVENT_ENGINE_STATE_IND_V02 0x002B -#define QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02 0x002C -#define QMI_LOC_EVENT_WIFI_REQ_IND_V02 0x002D -#define QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02 0x002E -#define QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02 0x002F -#define QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02 0x0030 -#define QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 0x0031 -#define QMI_LOC_GET_SERVICE_REVISION_REQ_V02 0x0032 -#define QMI_LOC_GET_SERVICE_REVISION_RESP_V02 0x0032 -#define QMI_LOC_GET_SERVICE_REVISION_IND_V02 0x0032 -#define QMI_LOC_GET_FIX_CRITERIA_REQ_V02 0x0033 -#define QMI_LOC_GET_FIX_CRITERIA_RESP_V02 0x0033 -#define QMI_LOC_GET_FIX_CRITERIA_IND_V02 0x0033 -#define QMI_LOC_NI_USER_RESPONSE_REQ_V02 0x0034 -#define QMI_LOC_NI_USER_RESPONSE_RESP_V02 0x0034 -#define QMI_LOC_NI_USER_RESPONSE_IND_V02 0x0034 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02 0x0035 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02 0x0035 -#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02 0x0035 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02 0x0036 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 0x0037 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02 0x0037 -#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02 0x0037 -#define QMI_LOC_INJECT_UTC_TIME_REQ_V02 0x0038 -#define QMI_LOC_INJECT_UTC_TIME_RESP_V02 0x0038 -#define QMI_LOC_INJECT_UTC_TIME_IND_V02 0x0038 -#define QMI_LOC_INJECT_POSITION_REQ_V02 0x0039 -#define QMI_LOC_INJECT_POSITION_RESP_V02 0x0039 -#define QMI_LOC_INJECT_POSITION_IND_V02 0x0039 -#define QMI_LOC_SET_ENGINE_LOCK_REQ_V02 0x003A -#define QMI_LOC_SET_ENGINE_LOCK_RESP_V02 0x003A -#define QMI_LOC_SET_ENGINE_LOCK_IND_V02 0x003A -#define QMI_LOC_GET_ENGINE_LOCK_REQ_V02 0x003B -#define QMI_LOC_GET_ENGINE_LOCK_RESP_V02 0x003B -#define QMI_LOC_GET_ENGINE_LOCK_IND_V02 0x003B -#define QMI_LOC_SET_SBAS_CONFIG_REQ_V02 0x003C -#define QMI_LOC_SET_SBAS_CONFIG_RESP_V02 0x003C -#define QMI_LOC_SET_SBAS_CONFIG_IND_V02 0x003C -#define QMI_LOC_GET_SBAS_CONFIG_REQ_V02 0x003D -#define QMI_LOC_GET_SBAS_CONFIG_RESP_V02 0x003D -#define QMI_LOC_GET_SBAS_CONFIG_IND_V02 0x003D -#define QMI_LOC_SET_NMEA_TYPES_REQ_V02 0x003E -#define QMI_LOC_SET_NMEA_TYPES_RESP_V02 0x003E -#define QMI_LOC_SET_NMEA_TYPES_IND_V02 0x003E -#define QMI_LOC_GET_NMEA_TYPES_REQ_V02 0x003F -#define QMI_LOC_GET_NMEA_TYPES_RESP_V02 0x003F -#define QMI_LOC_GET_NMEA_TYPES_IND_V02 0x003F -#define QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 0x0040 -#define QMI_LOC_SET_LOW_POWER_MODE_RESP_V02 0x0040 -#define QMI_LOC_SET_LOW_POWER_MODE_IND_V02 0x0040 -#define QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 0x0041 -#define QMI_LOC_GET_LOW_POWER_MODE_RESP_V02 0x0041 -#define QMI_LOC_GET_LOW_POWER_MODE_IND_V02 0x0041 -#define QMI_LOC_SET_SERVER_REQ_V02 0x0042 -#define QMI_LOC_SET_SERVER_RESP_V02 0x0042 -#define QMI_LOC_SET_SERVER_IND_V02 0x0042 -#define QMI_LOC_GET_SERVER_REQ_V02 0x0043 -#define QMI_LOC_GET_SERVER_RESP_V02 0x0043 -#define QMI_LOC_GET_SERVER_IND_V02 0x0043 -#define QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 0x0044 -#define QMI_LOC_DELETE_ASSIST_DATA_RESP_V02 0x0044 -#define QMI_LOC_DELETE_ASSIST_DATA_IND_V02 0x0044 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0045 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0045 -#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02 0x0045 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0046 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0046 -#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02 0x0046 -#define QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 0x0047 -#define QMI_LOC_INJECT_WIFI_POSITION_RESP_V02 0x0047 -#define QMI_LOC_INJECT_WIFI_POSITION_IND_V02 0x0047 -#define QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 0x0048 -#define QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02 0x0048 -#define QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02 0x0048 -#define QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 0x0049 -#define QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02 0x0049 -#define QMI_LOC_GET_REGISTERED_EVENTS_IND_V02 0x0049 -#define QMI_LOC_SET_OPERATION_MODE_REQ_V02 0x004A -#define QMI_LOC_SET_OPERATION_MODE_RESP_V02 0x004A -#define QMI_LOC_SET_OPERATION_MODE_IND_V02 0x004A -#define QMI_LOC_GET_OPERATION_MODE_REQ_V02 0x004B -#define QMI_LOC_GET_OPERATION_MODE_RESP_V02 0x004B -#define QMI_LOC_GET_OPERATION_MODE_IND_V02 0x004B -#define QMI_LOC_SET_SPI_STATUS_REQ_V02 0x004C -#define QMI_LOC_SET_SPI_STATUS_RESP_V02 0x004C -#define QMI_LOC_SET_SPI_STATUS_IND_V02 0x004C -#define QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 0x004D -#define QMI_LOC_INJECT_SENSOR_DATA_RESP_V02 0x004D -#define QMI_LOC_INJECT_SENSOR_DATA_IND_V02 0x004D -#define QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 0x004E -#define QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02 0x004E -#define QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02 0x004E -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02 0x004F -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02 0x004F -#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 0x004F -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 0x0050 -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02 0x0050 -#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02 0x0050 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0051 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0051 -#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02 0x0051 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0052 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0052 -#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02 0x0052 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 0x0053 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02 0x0053 -#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 0x0053 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0054 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0054 -#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0054 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0055 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0055 -#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0055 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0056 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0056 -#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02 0x0056 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0057 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0057 -#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02 0x0057 -#define QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 0x0058 -#define QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02 0x0058 -#define QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02 0x0058 -#define QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 0x0059 -#define QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02 0x0059 -#define QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02 0x0059 -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005A -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005A -#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005A -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005B -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005B -#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005B -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 0x005C -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02 0x005C -#define QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02 0x005C -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 0x005D -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02 0x005D -#define QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02 0x005D -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005E -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005E -#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005E -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F -#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F -#define QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02 0x0060 -#define QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02 0x0061 -#define QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02 0x0062 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 0x0063 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02 0x0063 -#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 0x0063 -#define QMI_LOC_DELETE_GEOFENCE_REQ_V02 0x0064 -#define QMI_LOC_DELETE_GEOFENCE_RESP_V02 0x0064 -#define QMI_LOC_DELETE_GEOFENCE_IND_V02 0x0064 -#define QMI_LOC_QUERY_GEOFENCE_REQ_V02 0x0065 -#define QMI_LOC_QUERY_GEOFENCE_RESP_V02 0x0065 -#define QMI_LOC_QUERY_GEOFENCE_IND_V02 0x0065 -#define QMI_LOC_EDIT_GEOFENCE_REQ_V02 0x0066 -#define QMI_LOC_EDIT_GEOFENCE_RESP_V02 0x0066 -#define QMI_LOC_EDIT_GEOFENCE_IND_V02 0x0066 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 -#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 -#define QMI_LOC_INJECT_MOTION_DATA_REQ_V02 0x0068 -#define QMI_LOC_INJECT_MOTION_DATA_RESP_V02 0x0068 -#define QMI_LOC_INJECT_MOTION_DATA_IND_V02 0x0068 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 -#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 -#define QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 0x006A -#define QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02 0x006A -#define QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 0x006A -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 0x006B -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02 0x006B -#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 0x006B -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 0x006C -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02 0x006C -#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02 0x006C -/** - @} - */ - -/* Service Object Accessor */ -/** @addtogroup wms_qmi_accessor - @{ - */ -/** This function is used internally by the autogenerated code. Clients should use the - macro loc_get_service_object_v02( ) that takes in no arguments. */ -qmi_idl_service_object_type loc_get_service_object_internal_v02 - ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ); - -/** This macro should be used to get the service object */ -#define loc_get_service_object_v02( ) \ - loc_get_service_object_internal_v02( \ - LOC_V02_IDL_MAJOR_VERS, LOC_V02_IDL_MINOR_VERS, \ - LOC_V02_IDL_TOOL_VERS ) -/** - @} - */ - - -#ifdef __cplusplus -} -#endif -#endif - + +#ifndef LOC_SERVICE_H +#define LOC_SERVICE_H +/** + @file location_service_v02.h + + @brief This is the public header file which defines the loc service Data structures. + + This header file defines the types and structures that were defined in + loc. It contains the constant values defined, enums, structures, + messages, and service message IDs (in that order) Structures that were + defined in the IDL as messages contain mandatory elements, optional + elements, a combination of mandatory and optional elements (mandatory + always come before optionals in the structure), or nothing (null message) + + An optional element in a message is preceded by a uint8_t value that must be + set to true if the element is going to be included. When decoding a received + message, the uint8_t values will be set to true or false by the decode + routine, and should be checked before accessing the values that they + correspond to. + + Variable sized arrays are defined as static sized arrays with an unsigned + integer (32 bit) preceding it that must be set to the number of elements + in the array that are valid. For Example: + + uint32_t test_opaque_len; + uint8_t test_opaque[16]; + + If only 4 elements are added to test_opaque[] then test_opaque_len must be + set to 4 before sending the message. When decoding, the _len value is set + by the decode routine and should be checked so that the correct number of + elements in the array will be accessed. + +*/ + +/*====*====*====*====*====*====*====*====*====*====*====*====*====*====*====* + *THIS IS AN AUTO GENERATED FILE. DO NOT ALTER IN ANY WAY + *====*====*====*====*====*====*====*====*====*====*====*====*====*====*====*/ + +/* This file was generated with Tool version 5.6 + It was generated on: Fri Oct 26 2012 + From IDL File: location_service_v02.idl */ + +/** @defgroup loc_qmi_consts Constant values defined in the IDL */ +/** @defgroup loc_qmi_msg_ids Constant values for QMI message IDs */ +/** @defgroup loc_qmi_enums Enumerated types used in QMI messages */ +/** @defgroup loc_qmi_messages Structures sent as QMI messages */ +/** @defgroup loc_qmi_aggregates Aggregate types used in QMI messages */ +/** @defgroup loc_qmi_accessor Accessor for QMI service object */ +/** @defgroup loc_qmi_version Constant values for versioning information */ + +#include +#include "qmi_idl_lib.h" +#include "common_v01.h" + + +#ifdef __cplusplus +extern "C" { +#endif + +/** @addtogroup loc_qmi_version + @{ + */ +/** Major Version Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MAJOR_VERS 0x02 +/** Revision Number of the IDL used to generate this file */ +#define LOC_V02_IDL_MINOR_VERS 0x11 +/** Major Version Number of the qmi_idl_compiler used to generate this file */ +#define LOC_V02_IDL_TOOL_VERS 0x05 +/** Maximum Defined Message ID */ +#define LOC_V02_MAX_MESSAGE_ID 0x006F; +/** + @} + */ + + +/** @addtogroup loc_qmi_consts + @{ + */ + +/** Maximum string length for the Provider field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 24 + +/** Maximum string length for the Name field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 32 + +/** Maximum string length for the Version field in the application ID. */ +#define QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 8 + +/** Maximum length of the list containing the SVs that were used to generate + a position report. */ +#define QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02 80 + +/** Maximum number of satellites in the satellite report. */ +#define QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02 80 + +/** Maximum NMEA string length. */ +#define QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 200 + +/** Maximum length of the requestor ID string. */ +#define QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02 200 + +/** Session ID byte length. */ +#define QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02 4 + +/** Maximum client name length allowed. */ +#define QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02 64 + +/** Maximum URL length accepted by the location engine. */ +#define QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 255 + +/** IPV6 address length in bytes. */ +#define QMI_LOC_IPV6_ADDR_LENGTH_V02 8 + +/** SUPL hash length. */ +#define QMI_LOC_NI_SUPL_HASH_LENGTH_V02 8 + +/** Maximum client address length allowed. */ +#define QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02 20 + +/** Maximum codeword length allowed. */ +#define QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02 20 + +/** Maximum number of NTP Servers sent out with this event. */ +#define QMI_LOC_MAX_NTP_SERVERS_V02 3 + +/** Maximum number of predicted orbits servers supported in the location + engine. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02 3 + +/** Maximum GNSS Measurement Engine Firmware Version String length. */ +#define QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Hosted Software Version String length. */ +#define QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 127 + +/** Maximum GNSS Measurement Engine Full Version String length. */ +#define QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 255 + +/** Maximum part length that can be injected. The client should + also look at the maxPartSize field in the predicted orbits injection + request indication and pick the minimum of the two. */ +#define QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02 1024 + +/** Maximum length of the delete SV information list */ +#define QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02 128 + +/** MAC address length in bytes. */ +#define QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02 6 + +/** Maximum number of APs that the sender can report. */ +#define QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02 50 + +/** Maximum number of samples that can be injected in a TLV. */ +#define QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02 50 + +/** Maximum APN string length allowed. */ +#define QMI_LOC_MAX_APN_NAME_LENGTH_V02 100 + +/** Maximum APN profiles supported. */ +#define QMI_LOC_MAX_APN_PROFILES_V02 6 + +/** Maximum length of the SUPL certificate. */ +#define QMI_LOC_MAX_SUPL_CERT_LENGTH_V02 2000 + +/** Maximum length of the network-initiated Geofence ID + list */ +#define QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02 16 + +/** Maximum length of the injected network initiated message. */ +#define QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02 1024 +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Response Message; Generic response definition. This message is used to tell + clients whether their message was accepted for further + processing or rejected. */ +typedef struct { + + /* Mandatory */ + /* Result Code */ + qmi_response_type_v01 resp; +}qmiLocGenRespMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Informs the service of the minor revision of the interface + definition that the control point implements. */ +typedef struct { + + /* Mandatory */ + /* Revision */ + uint32_t revision; + /**< Revision that the control point is using. */ +}qmiLocInformClientRevisionReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocEventRegMaskT_v02; +#define QMI_LOC_EVENT_MASK_POSITION_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00000001ull) /**< The control point must enable this mask to receive position report + event indications. */ +#define QMI_LOC_EVENT_MASK_GNSS_SV_INFO_V02 ((qmiLocEventRegMaskT_v02)0x00000002ull) /**< The control point must enable this mask to receive satellite report + event indications. These reports are sent at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NMEA_V02 ((qmiLocEventRegMaskT_v02)0x00000004ull) /**< The control point must enable this mask to receive NMEA reports for + position and satellites in view. The report is at a 1 Hz rate. */ +#define QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000008ull) /**< The control point must enable this mask to receive NI notify verify request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_TIME_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000010ull) /**< The control point must enable this mask to receive time injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000020ull) /**< The control point must enable this mask to receive predicted orbits request + event indications. */ +#define QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000040ull) /**< The control point must enable this mask to receive position injection request + event indications. */ +#define QMI_LOC_EVENT_MASK_ENGINE_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000080ull) /**< The control point must enable this mask to receive engine state report + event indications. */ +#define QMI_LOC_EVENT_MASK_FIX_SESSION_STATE_V02 ((qmiLocEventRegMaskT_v02)0x00000100ull) /**< The control point must enable this mask to receive fix session status report + event indications. */ +#define QMI_LOC_EVENT_MASK_WIFI_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000200ull) /**< The control point must enable this mask to receive WiFi position request + event indications. */ +#define QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS_V02 ((qmiLocEventRegMaskT_v02)0x00000400ull) /**< The control point must enable this mask to receive notifications from the + GPS engine indicating its readiness to accept data from the + sensors (accelerometer, gyroscope, etc.). */ +#define QMI_LOC_EVENT_MASK_TIME_SYNC_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00000800ull) /**< The control point must enable this mask to receive time-sync requests + from the GPS engine. Time sync enables the GPS engine to synchronize + its clock with the sensor processor's clock. */ +#define QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT_V02 ((qmiLocEventRegMaskT_v02)0x00001000ull) /**< The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. */ +#define QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ_V02 ((qmiLocEventRegMaskT_v02)0x00002000ull) /**< The control point must enable this mask to receive location server + requests. These requests are generated when the service wishes to + establish a connection with a location server. */ +#define QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00004000ull) /**< The control point must enable this mask to receive notifications + related to network-initiated Geofences. These events notify the client + when a network-initiated Geofence is added, deleted, or edited. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT_V02 ((qmiLocEventRegMaskT_v02)0x00008000ull) /**< The control point must enable this mask to receive Geofence alerts. + These alerts are generated to inform the client of the changes that may + affect Geofence, e.g., if GPS is turned off or if the network is + unavailable. */ +#define QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION_V02 ((qmiLocEventRegMaskT_v02)0x00010000ull) /**< The control point must enable this mask to receive notifications when + a Geofence is breached. These events are generated when the UE enters + or leaves the perimeter of a Geofence. */ +#define QMI_LOC_EVENT_MASK_PEDOMETER_CONTROL_V02 ((qmiLocEventRegMaskT_v02)0x00020000ull) /**< The control point must enable this mask to register for Pedometer + control requests from the location engine. Location engine sends + this event out to control the injection of pedometer reports. */ +#define QMI_LOC_EVENT_MASK_MOTION_DATA_CONTROL_V02 ((qmiLocEventRegMaskT_v02)0x00040000ull) /**< The control point must enable this mask to register for motion data + control requests from the location engine. Location engine sends + this event out to control the injection of motion data. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to register for events from the + location subsystem. */ +typedef struct { + + /* Mandatory */ + /* Event Registration Mask */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Specifies the events that the control point is interested in receiving. + Refer to the definition of the following bitmasks: + - QMI_LOC_EVENT_MASK_POSITION_REPORT (0x00000001) -- The control point must enable this mask to receive position report + event indications. + - QMI_LOC_EVENT_MASK_GNSS_SV_INFO (0x00000002) -- The control point must enable this mask to receive satellite report + event indications. These reports are sent at a 1 Hz rate. + - QMI_LOC_EVENT_MASK_NMEA (0x00000004) -- The control point must enable this mask to receive NMEA reports for + position and satellites in view. The report is at a 1 Hz rate. + - QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ (0x00000008) -- The control point must enable this mask to receive NI notify verify request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_TIME_REQ (0x00000010) -- The control point must enable this mask to receive time injection request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ (0x00000020) -- The control point must enable this mask to receive predicted orbits request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ (0x00000040) -- The control point must enable this mask to receive position injection request + event indications. + - QMI_LOC_EVENT_MASK_ENGINE_STATE (0x00000080) -- The control point must enable this mask to receive engine state report + event indications. + - QMI_LOC_EVENT_MASK_FIX_SESSION_STATE (0x00000100) -- The control point must enable this mask to receive fix session status report + event indications. + - QMI_LOC_EVENT_MASK_WIFI_REQ (0x00000200) -- The control point must enable this mask to receive WiFi position request + event indications. + - QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS (0x00000400) -- The control point must enable this mask to receive notifications from the + GPS engine indicating its readiness to accept data from the + sensors (accelerometer, gyroscope, etc.). + - QMI_LOC_EVENT_MASK_TIME_SYNC_REQ (0x00000800) -- The control point must enable this mask to receive time-sync requests + from the GPS engine. Time sync enables the GPS engine to synchronize + its clock with the sensor processor's clock. + - QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT (0x00001000) -- The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. + - QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ (0x00002000) -- The control point must enable this mask to receive location server + requests. These requests are generated when the service wishes to + establish a connection with a location server. + - QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION (0x00004000) -- The control point must enable this mask to receive notifications + related to network-initiated Geofences. These events notify the client + when a network-initiated Geofence is added, deleted, or edited. + - QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT (0x00008000) -- The control point must enable this mask to receive Geofence alerts. + These alerts are generated to inform the client of the changes that may + affect Geofence, e.g., if GPS is turned off or if the network is + unavailable. + - QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION (0x00010000) -- The control point must enable this mask to receive notifications when + a Geofence is breached. These events are generated when the UE enters + or leaves the perimeter of a Geofence. + - QMI_LOC_EVENT_MASK_PEDOMETER_CONTROL (0x00020000) -- The control point must enable this mask to register for Pedometer + control requests from the location engine. Location engine sends + this event out to control the injection of pedometer reports. + - QMI_LOC_EVENT_MASK_MOTION_DATA_CONTROL (0x00040000) -- The control point must enable this mask to register for motion data + control requests from the location engine. Location engine sends + this event out to control the injection of motion data. + + Multiple events can be registered by ORing the individual masks and + sending them in this TLV. All unused bits in this mask must be set to 0. + */ +}qmiLocRegEventsReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXRECURRENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RECURRENCE_PERIODIC_V02 = 1, /**< Request periodic position fixes. */ + eQMI_LOC_RECURRENCE_SINGLE_V02 = 2, /**< Request a single position fix. */ + QMILOCFIXRECURRENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixRecurrenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCACCURACYLEVELENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ACCURACY_LOW_V02 = 1, /**< Low accuracy. */ + eQMI_LOC_ACCURACY_MED_V02 = 2, /**< Medium accuracy. */ + eQMI_LOC_ACCURACY_HIGH_V02 = 3, /**< High accuracy. */ + QMILOCACCURACYLEVELENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAccuracyLevelEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINTERMEDIATEREPORTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INTERMEDIATE_REPORTS_ON_V02 = 1, /**< Intermediate reports are turned on. */ + eQMI_LOC_INTERMEDIATE_REPORTS_OFF_V02 = 2, /**< Intermediate reports are turned off. */ + QMILOCINTERMEDIATEREPORTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocIntermediateReportStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char applicationProvider[QMI_LOC_MAX_APP_ID_PROVIDER_LENGTH_V02 + 1]; + /**< Application provider. */ + + char applicationName[QMI_LOC_MAX_APP_ID_NAME_LENGTH_V02 + 1]; + /**< Application name. */ + + uint8_t applicationVersion_valid; + /**< Specifies whether the application version string contains + a valid value: \begin{itemize1} + \item 0x00 (FALSE) -- Application version string is invalid + \item 0x01 (TRUE) -- Application version string is valid + \vspace{-0.18in} \end{itemize1} */ + + char applicationVersion[QMI_LOC_MAX_APP_ID_VERSION_LENGTH_V02 + 1]; + /**< Application version. */ +}qmiLocApplicationIdStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to initiate a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session as identified by the control point. The session ID + is reported back in the position reports. The control point must + specify the same session ID in the QMI_LOC_STOP_REQ message. \n + - Range: 0 to 255 + */ + + /* Optional */ + /* Recurrence Type */ + uint8_t fixRecurrence_valid; /**< Must be set to true if fixRecurrence is being passed */ + qmiLocFixRecurrenceEnumT_v02 fixRecurrence; + /**< Specifies the type of session in which the control point is interested. + If this TLV is not specified, recurrence defaults to SINGLE. + + Valid values: \n + - 0x00000001 -- Request periodic fixes \n + - 0x00000002 -- Request a single fix + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Specifies the horizontal accuracy level required by the control point. + If not specified, accuracy defaults to LOW. + + Valid values: \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} + \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable Intermediate Reports */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Specifies if the control point is interested in receiving intermediate + reports. The control point must explicitly set this field to OFF if it + does not wish to receive intermediate position reports. Intermediate + position reports are generated at 1 Hz and are ON by default. If + intermediate reports are turned ON, the client receives position reports + even if the accuracy criteria are not met. The status in such a position + report is set to IN_PROGRESS in order for the control point to identify + intermediate reports. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} + \end{itemize1} + */ + + /* Optional */ + /* Minimum Interval Between Position Reports */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Minimum time interval, specified by the control point, that must elapse between + position reports. \n + - Units: Milliseconds \n + - Default: 1000 ms + */ + + /* Optional */ + /* ID of the Application that Sent this Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version.*/ +}qmiLocStartReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to stop a GPS session. */ +typedef struct { + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + (QMI_LOC_START_REQ).\n + - Range: 0 to 255 */ +}qmiLocStopReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPosTechMaskT_v02; +#define QMI_LOC_POS_TECH_MASK_SATELLITE_V02 ((qmiLocPosTechMaskT_v02)0x00000001) /**< Satellites were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_CELLID_V02 ((qmiLocPosTechMaskT_v02)0x00000002) /**< Cell towers were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_WIFI_V02 ((qmiLocPosTechMaskT_v02)0x00000004) /**< WiFi access points were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_SENSORS_V02 ((qmiLocPosTechMaskT_v02)0x00000008) /**< Sensors were used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_REFERENCE_LOCATION_V02 ((qmiLocPosTechMaskT_v02)0x00000010) /**< Reference Location was used to generate the fix. */ +#define QMI_LOC_POS_TECH_MASK_INJECTED_COARSE_POSITION_V02 ((qmiLocPosTechMaskT_v02)0x00000020) /**< Coarse position injected into the location engine was used to + generate the fix. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSESSIONSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SESS_STATUS_SUCCESS_V02 = 0, /**< Session was successful. */ + eQMI_LOC_SESS_STATUS_IN_PROGRESS_V02 = 1, /**< Session still in progress. Further position reports will be + generated until either the fix criteria specified by the client + are met or the client response timeout occurs. */ + eQMI_LOC_SESS_STATUS_GENERAL_FAILURE_V02 = 2, /**< Session failed. */ + eQMI_LOC_SESS_STATUS_TIMEOUT_V02 = 3, /**< Fix request failed because the session timed out. */ + eQMI_LOC_SESS_STATUS_USER_END_V02 = 4, /**< Fix request failed because the session was ended by the user. */ + eQMI_LOC_SESS_STATUS_BAD_PARAMETER_V02 = 5, /**< Fix request failed due to bad parameters in the request. */ + eQMI_LOC_SESS_STATUS_PHONE_OFFLINE_V02 = 6, /**< Fix request failed because the phone is offline. */ + eQMI_LOC_SESS_STATUS_ENGINE_LOCKED_V02 = 7, /**< Fix request failed because the engine is locked. */ + QMILOCSESSIONSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSessionStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gpsWeek; + /**< Current GPS week as calculated from midnight, Jan. 6, 1980. \n + - Units: Weeks */ + + uint32_t gpsTimeOfWeekMs; + /**< Amount of time into the current GPS week. \n + - Units: Milliseconds */ +}qmiLocGPSTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + float PDOP; + /**< Position dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \item PDOP = square root of (HDOP^2 + VDOP^2) + \vspace{-0.18in} \end{itemize1} */ + + float HDOP; + /**< Horizontal dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ + + float VDOP; + /**< Vertical dilution of precision. + \begin{itemize1} + \item Range: 1 (highest accuracy) to 50 (lowest accuracy) + \vspace{-0.18in} \end{itemize1} */ +}qmiLocDOPStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocSensorUsageMaskT_v02; +#define QMI_LOC_SENSOR_MASK_USED_ACCEL_V02 ((qmiLocSensorUsageMaskT_v02)0x00000001) /**< Bitmask to specify whether an accelerometer was used. */ +#define QMI_LOC_SENSOR_MASK_USED_GYRO_V02 ((qmiLocSensorUsageMaskT_v02)0x00000002) /**< Bitmask to specify whether a gyroscope was used. */ +typedef uint32_t qmiLocSensorAidedMaskT_v02; +#define QMI_LOC_SENSOR_AIDED_MASK_HEADING_V02 ((qmiLocSensorAidedMaskT_v02)0x00000001) /**< Bitmask to specify whether a sensor was used to calculate heading. */ +#define QMI_LOC_SENSOR_AIDED_MASK_SPEED_V02 ((qmiLocSensorAidedMaskT_v02)0x00000002) /**< Bitmask to specify whether a sensor was used to calculate speed. */ +#define QMI_LOC_SENSOR_AIDED_MASK_POSITION_V02 ((qmiLocSensorAidedMaskT_v02)0x00000004) /**< Bitmask to specify whether a sensor was used to calculate position. */ +#define QMI_LOC_SENSOR_AIDED_MASK_VELOCITY_V02 ((qmiLocSensorAidedMaskT_v02)0x00000008) /**< Bitmask to specify whether a sensor was used to calculate velocity. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSensorUsageMaskT_v02 usageMask; + /**< Specifies which sensors were used in calculating the position in the + position report. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SENSOR_USED_ACCEL + \item 0x00000002 -- SENSOR_USED_GYRO + \vspace{-0.18in} \end{itemize1} */ + + qmiLocSensorAidedMaskT_v02 aidingIndicatorMask; + /**< Specifies which results were aided by sensors. + + Valid bitmasks: \n + - 0x00000001 -- AIDED_HEADING \n + - 0x00000002 -- AIDED_SPEED \n + - 0x00000004 -- AIDED_POSITION \n + - 0x00000008 -- AIDED_VELOCITY */ +}qmiLocSensorUsageIndicatorStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCTIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_TIME_SRC_INVALID_V02 = 0, /**< Invalid time. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER_V02 = 1, /**< Time is set by the 1x system. */ + eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING_V02 = 2, /**< Time is set by WCDMA/GSM time tagging (i.e., + associating network time with GPS time). */ + eQMI_LOC_TIME_SRC_EXTERNAL_INPUT_V02 = 3, /**< Time is set by an external injection. */ + eQMI_LOC_TIME_SRC_TOW_DECODE_V02 = 4, /**< Time is set after decoding over-the-air GPS navigation data + from one GPS satellite. */ + eQMI_LOC_TIME_SRC_TOW_CONFIRMED_V02 = 5, /**< Time is set after decoding over-the-air GPS navigation data + from multiple satellites. */ + eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED_V02 = 6, /**< Both time of the week and the GPS week number are known. */ + eQMI_LOC_TIME_SRC_NAV_SOLUTION_V02 = 7, /**< Time is set by the position engine after the fix is obtained. */ + eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME_V02 = 8, /**< Time is set by the position engine after performing SFT. + This is done when the clock time uncertainty is large. */ + eQMI_LOC_TIME_SRC_GLO_TOW_DECODE_V02 = 9, /**< Time is set after decoding GLO satellites */ + eQMI_LOC_TIME_SRC_TIME_TRANSFORM_V02 = 10, /**< Time is set after transforming the GPS to GLO time */ + eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING_V02 = 11, /**< Time is set by the sleep time tag provided by the WCDMA network */ + eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING_V02 = 12, /**< Time is set by the sleep time tag provided by the GSM network */ + eQMI_LOC_TIME_SRC_UNKNOWN_V02 = 13, /**< Source of the time is unknown */ + eQMI_LOC_TIME_SRC_SYSTEM_TIMETICK_V02 = 14, /**< Time is derived from system clock (better known as slow clock). + GNSS time is maintained irrespective of the GNSS receiver state */ + QMILOCTIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocTimeSourceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCRELIABILITYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_RELIABILITY_NOT_SET_V02 = 0, /**< Location reliability is not set */ + eQMI_LOC_RELIABILITY_VERY_LOW_V02 = 1, /**< Location reliability is very low; use it at your own risk */ + eQMI_LOC_RELIABILITY_LOW_V02 = 2, /**< Location reliability is low; little or no cross-checking is possible */ + eQMI_LOC_RELIABILITY_MEDIUM_V02 = 3, /**< Location reliability is medium; limited cross-check passed */ + eQMI_LOC_RELIABILITY_HIGH_V02 = 4, /**< Location reliability is high; strong cross-check passed */ + QMILOCRELIABILITYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocReliabilityEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the position report to the control point. */ +typedef struct { + + /* Mandatory */ + /* Session Status */ + qmiLocSessionStatusEnumT_v02 sessionStatus; + /**< Session status. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SESS_STATUS_SUCCESS + \item 0x00000001 -- SESS_STATUS_IN_PROGRESS + \item 0x00000002 -- SESS_STATUS_GENERAL_FAILURE + \item 0x00000003 -- SESS_STATUS_TIMEOUT + \item 0x00000004 -- SESS_STATUS_USER_END + \item 0x00000005 -- SESS_STATUS_BAD_PARAMETER + \item 0x00000006 -- SESS_STATUS_PHONE_OFFLINE + \item 0x00000007 -- SESS_STATUS_ENGINE_LOCKED + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Session ID */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request + QMI_LOC_START_REQ. \n + - Range: 0 to 255 */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Elliptical Horizontal Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal uncertainty confidence.\n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. \n + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t speedHorizontal_valid; /**< Must be set to true if speedHorizontal is being passed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Units: Meters/second */ + + /* Optional */ + /* Speed Uncertainty */ + uint8_t speedUnc_valid; /**< Must be set to true if speedUnc is being passed */ + float speedUnc; + /**< 3-D Speed uncertainty.\n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence.\n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. \n + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Vertical Speed */ + uint8_t speedVertical_valid; /**< Must be set to true if speedVertical is being passed */ + float speedVertical; + /**< Vertical speed.\n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. */ + + /* Optional */ + /* Technology Used */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + /**< \n Dilution of precision associated with this position. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Units: Milliseconds since Jan. 1, 1970 */ + + /* Optional */ + /* Leap Seconds */ + uint8_t leapSeconds_valid; /**< Must be set to true if leapSeconds is being passed */ + uint8_t leapSeconds; + /**< Leap second information. If leapSeconds is not available, + timestampUtc is calculated based on a hard-coded value + for leap seconds. \n + - Units: Seconds */ + + /* Optional */ + /* GPS Time */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + /**< \n The number of weeks since Jan. 5, 1980, and + milliseconds into the current week. */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Units: Milliseconds */ + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. Valid values: \n + - eQMI_LOC_TIME_SRC_INVALID (0) -- Invalid time. + - eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER (1) -- Time is set by the 1x system. + - eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING (2) -- Time is set by WCDMA/GSM time tagging (i.e., + associating network time with GPS time). + - eQMI_LOC_TIME_SRC_EXTERNAL_INPUT (3) -- Time is set by an external injection. + - eQMI_LOC_TIME_SRC_TOW_DECODE (4) -- Time is set after decoding over-the-air GPS navigation data + from one GPS satellite. + - eQMI_LOC_TIME_SRC_TOW_CONFIRMED (5) -- Time is set after decoding over-the-air GPS navigation data + from multiple satellites. + - eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED (6) -- Both time of the week and the GPS week number are known. + - eQMI_LOC_TIME_SRC_NAV_SOLUTION (7) -- Time is set by the position engine after the fix is obtained. + - eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME (8) -- Time is set by the position engine after performing SFT. + This is done when the clock time uncertainty is large. + - eQMI_LOC_TIME_SRC_GLO_TOW_DECODE (9) -- Time is set after decoding GLO satellites + - eQMI_LOC_TIME_SRC_TIME_TRANSFORM (10) -- Time is set after transforming the GPS to GLO time + - eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING (11) -- Time is set by the sleep time tag provided by the WCDMA network + - eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING (12) -- Time is set by the sleep time tag provided by the GSM network + - eQMI_LOC_TIME_SRC_UNKNOWN (13) -- Source of the time is unknown + - eQMI_LOC_TIME_SRC_SYSTEM_TIMETICK (14) -- Time is derived from system clock (better known as slow clock). + GNSS time is maintained irrespective of the GNSS receiver state */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + /**< \n Whether sensor data was used in computing the position in this + position report. */ + + /* Optional */ + /* Fix Count for This Session */ + uint8_t fixId_valid; /**< Must be set to true if fixId is being passed */ + uint32_t fixId; + /**< Fix count for the session. Starts with 0 and increments by one + for each successive position report for a particular session. */ + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ +}qmiLocEventPositionReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSYSTEMENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_SYSTEM_GPS_V02 = 1, /**< GPS satellite. */ + eQMI_LOC_SV_SYSTEM_GALILEO_V02 = 2, /**< GALILEO satellite. */ + eQMI_LOC_SV_SYSTEM_SBAS_V02 = 3, /**< SBAS satellite. */ + eQMI_LOC_SV_SYSTEM_COMPASS_V02 = 4, /**< COMPASS satellite. */ + eQMI_LOC_SV_SYSTEM_GLONASS_V02 = 5, /**< GLONASS satellite. */ + QMILOCSVSYSTEMENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvSystemEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSVSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SV_STATUS_IDLE_V02 = 1, /**< SV is not being actively processed. */ + eQMI_LOC_SV_STATUS_SEARCH_V02 = 2, /**< The system is searching for this SV. */ + eQMI_LOC_SV_STATUS_TRACK_V02 = 3, /**< SV is being tracked. */ + QMILOCSVSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSvStatusEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocSvInfoValidMaskT_v02; +#define QMI_LOC_SV_INFO_MASK_VALID_SYSTEM_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000001) /**< System field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_GNSS_SVID_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000002) /**< gnssSvId field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_HEALTH_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000004) /**< healthStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_PROCESS_STATUS_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000008) /**< processStatus field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SVINFO_MASK_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000010) /**< svInfoMask field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_ELEVATION_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000020) /**< Elevation field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_AZIMUTH_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000040) /**< Azimuth field is valid in SV information. */ +#define QMI_LOC_SV_INFO_MASK_VALID_SNR_V02 ((qmiLocSvInfoValidMaskT_v02)0x00000080) /**< SNR field is valid in SV information. */ +typedef uint8_t qmiLocSvInfoMaskT_v02; +#define QMI_LOC_SVINFO_MASK_HAS_EPHEMERIS_V02 ((qmiLocSvInfoMaskT_v02)0x01) /**< Ephemeris is available for this SV. */ +#define QMI_LOC_SVINFO_MASK_HAS_ALMANAC_V02 ((qmiLocSvInfoMaskT_v02)0x02) /**< Almanac is available for this SV. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSvInfoValidMaskT_v02 validMask; + /**< Bitmask indicating which of the fields in this TLV are valid. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- VALID_SYSTEM + \item 0x00000002 -- VALID_GNSS_SVID + \item 0x00000004 -- VALID_HEALTH_STATUS + \item 0x00000008 -- VALID_PROCESS_STATUS + \item 0x00000010 -- VALID_SVINFO_MASK + \item 0x00000020 -- VALID_ELEVATION + \item 0x00000040 -- VALID_AZIMUTH + \item 0x00000080 -- VALID_SNR + \vspace{-0.18in} \end{itemize1} */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + + Valid values: \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} */ + + uint16_t gnssSvId; + /**< GNSS SV ID. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For GLONASS: 1 to 32 + \item For SBAS: 120 to 151 + \end{itemize1} \end{itemize1} + + The GPS and GLONASS SVs can be disambiguated using the system field. */ + + uint8_t healthStatus; + /**< Health status. + \begin{itemize1} + \item Range: 0 to 1; 0 = unhealthy, \newline 1 = healthy + \vspace{-0.18in} \end{itemize1}*/ + + qmiLocSvStatusEnumT_v02 svStatus; + /**< SV processing status. \n + Valid values:\n + - 0x00000001 -- SV_STATUS_IDLE \n + - 0x00000002 -- SV_STATUS_SEARCH \n + - 0x00000003 -- SV_STATUS_TRACK + */ + + qmiLocSvInfoMaskT_v02 svInfoMask; + /**< Whether almanac and ephemeris information is available. \n + Valid bitmasks: \n + - 0x01 -- SVINFO_HAS_EPHEMERIS \n + - 0x02 -- SVINFO_HAS_ALMANAC + */ + + float elevation; + /**< SV elevation angle.\n + - Units: Degrees \n + - Range: 0 to 90 */ + + float azimuth; + /**< SV azimuth angle.\n + - Units: Degrees \n + - Range: 0 to 360 */ + + float snr; + /**< SV signal-to-noise ratio. \n + - Units: dB-Hz */ +}qmiLocSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends a satellite report to the control point. */ +typedef struct { + + /* Mandatory */ + /* Altitude Source */ + uint8_t altitudeAssumed; + /**< Whether altitude is assumed or calculated: \begin{itemize1} + \item 0x00 (FALSE) -- Valid altitude is calculated + \item 0x01 (TRUE) -- Valid altitude is assumed; there may not be + enough satellites to determine precise altitude + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Satellite Info */ + uint8_t svList_valid; /**< Must be set to true if svList is being passed */ + uint32_t svList_len; /**< Must be set to # of elements in svList */ + qmiLocSvInfoStructT_v02 svList[QMI_LOC_SV_INFO_LIST_MAX_SIZE_V02]; + /**< \n SV information list. */ +}qmiLocEventGnssSvInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends NMEA sentences to the control point */ +typedef struct { + + /* Mandatory */ + /* NMEA String */ + char nmea[QMI_LOC_NMEA_STRING_MAX_LENGTH_V02 + 1]; + /**< NMEA string. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 201 + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocEventNmeaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNINOTIFYVERIFYENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_USER_NO_NOTIFY_NO_VERIFY_V02 = 1, /**< No notification and no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_ONLY_V02 = 2, /**< Notify only; no verification required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_ALLOW_NO_RESP_V02 = 3, /**< Notify and verify, but no response required. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_NOT_ALLOW_NO_RESP_V02 = 4, /**< Notify and verify, and require a response. */ + eQMI_LOC_NI_USER_NOTIFY_VERIFY_PRIVACY_OVERRIDE_V02 = 5, /**< Notify and Verify, and require a response. */ + QMILOCNINOTIFYVERIFYENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiNotifyVerifyEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXPOSMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_MS_ASSISTED_ONLY_V02 = 1, /**< MS-assisted only allowed. */ + eQMI_LOC_NI_VX_MS_BASED_ONLY_V02 = 2, /**< MS-based only allowed. */ + eQMI_LOC_NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED_V02 = 3, /**< MS-assisted preferred, but MS-based allowed. */ + eQMI_LOC_NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED_V02 = 4, /**< MS-based preferred, but MS-assisted allowed. */ + QMILOCNIVXPOSMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxPosModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_VX_OCTET_V02 = 0, /**< Encoding is OCTET. */ + eQMI_LOC_NI_VX_EXN_PROTOCOL_MSG_V02 = 1, /**< Encoding is EXN PROTOCOL MSG. */ + eQMI_LOC_NI_VX_ASCII_V02 = 2, /**< Encoding is ASCII. */ + eQMI_LOC_NI_VX_IA5_V02 = 3, /**< Encoding is IA5. */ + eQMI_LOC_NI_VX_UNICODE_V02 = 4, /**< Encoding is UNICODE. */ + eQMI_LOC_NI_VX_SHIFT_JIS_V02 = 5, /**< Encoding is SHIFT JIS. */ + eQMI_LOC_NI_VX_KOREAN_V02 = 6, /**< Encoding is KOREAN. */ + eQMI_LOC_NI_VX_LATIN_HEBREW_V02 = 7, /**< Encoding is LATIN HEBREW. */ + eQMI_LOC_NI_VX_LATIN_V02 = 8, /**< Encoding is LATIN. */ + eQMI_LOC_NI_VX_GSM_V02 = 9, /**< Encoding is GSM. */ + QMILOCNIVXREQUESTORIDENCODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t posQosIncl; + /**< Whether quality of service is included:\n + - 0x01 (TRUE) -- QoS is included \n + - 0x00 (FALSE) -- QoS is not included */ + + uint8_t posQos; + /**< Position QoS timeout. \n + - Units: Seconds \n + - Range: 0 to 255 */ + + uint32_t numFixes; + /**< Number of fixes allowed. */ + + uint32_t timeBetweenFixes; + /**< Time between fixes.\n + - Units: Seconds */ + + qmiLocNiVxPosModeEnumT_v02 posMode; + /**< Position mode. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NI_VX_MS_ASSISTED_ONLY + \item 0x00000002 -- NI_VX_MS_BASED_ONLY + \item 0x00000003 -- NI_VX_MS_ASSISTED_PREFERRED_MS_BASED_ALLOWED + \item 0x00000004 -- NI_VX_MS_BASED_PREFERRED_MS_ASSISTED_ALLOWED + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiVxRequestorIdEncodingSchemeEnumT_v02 encodingScheme; + /**< VX encoding scheme. + + Valid values: \begin{itemize1} + \item 0x00000000 -- NI_VX_OCTET + \item 0x00000001 -- NI_VX_EXN_PROTOCOL_MSG + \item 0x00000002 -- NI_VX_ASCII + \item 0x00000003 -- NI_VX_IA5 + \item 0x00000004 -- NI_VX_UNICODE + \item 0x00000005 -- NI_VX_SHIFT_JIS + \item 0x00000006 -- NI_VX_KOREAN + \item 0x00000007 -- NI_VX_LATIN_HEBREW + \item 0x00000008 -- NI_VX_LATIN + \item 0x00000009 -- NI_VX_GSM + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t requestorId_len; /**< Must be set to # of elements in requestorId */ + uint8_t requestorId[QMI_LOC_NI_MAX_REQUESTOR_ID_LENGTH_V02]; + /**< Requestor ID. \n + - Type: Array of bytes \n + - Maximum array length: 200 + */ + + uint16_t userRespTimerInSeconds; + /**< Time to wait for the user to respond. \n + - Units: Seconds */ +}qmiLocNiVxNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLPOSMETHODENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_V02 = 1, /**< Set assisted. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_V02 = 2, /**< Set based. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETASSISTED_PREF_V02 = 3, /**< Set assisted preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AGPS_SETBASED_PREF_V02 = 4, /**< Set based preferred. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AUTONOMOUS_GPS_V02 = 5, /**< Standalone GPS. */ + eQMI_LOC_NI_SUPL_POSMETHOD_AFLT_V02 = 6, /**< Advanced forward link trilateration. */ + eQMI_LOC_NI_SUPL_POSMETHOD_ECID_V02 = 7, /**< Exclusive chip ID. */ + eQMI_LOC_NI_SUPL_POSMETHOD_EOTD_V02 = 8, /**< Enhnaced observed time difference. */ + eQMI_LOC_NI_SUPL_POSMETHOD_OTDOA_V02 = 9, /**< Observed time delay of arrival. */ + eQMI_LOC_NI_SUPL_POSMETHOD_NO_POSITION_V02 = 10, /**< No position. */ + QMILOCNISUPLPOSMETHODENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplPosMethodEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIDATACODINGSCHEMEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SS_GERMAN_V02 = 12, /**< Language is German. */ + eQMI_LOC_NI_SS_ENGLISH_V02 = 13, /**< Language is English. */ + eQMI_LOC_NI_SS_ITALIAN_V02 = 14, /**< Language is Italian. */ + eQMI_LOC_NI_SS_FRENCH_V02 = 15, /**< Language is French. */ + eQMI_LOC_NI_SS_SPANISH_V02 = 16, /**< Language is Spanish. */ + eQMI_LOC_NI_SS_DUTCH_V02 = 17, /**< Language is Dutch. */ + eQMI_LOC_NI_SS_SWEDISH_V02 = 18, /**< Language is Swedish. */ + eQMI_LOC_NI_SS_DANISH_V02 = 19, /**< Language is Danish. */ + eQMI_LOC_NI_SS_PORTUGUESE_V02 = 20, /**< Language is Portuguese. */ + eQMI_LOC_NI_SS_FINNISH_V02 = 21, /**< Language is Finnish. */ + eQMI_LOC_NI_SS_NORWEGIAN_V02 = 22, /**< Language is Norwegian. */ + eQMI_LOC_NI_SS_GREEK_V02 = 23, /**< Language is Greek. */ + eQMI_LOC_NI_SS_TURKISH_V02 = 24, /**< Language is Turkish. */ + eQMI_LOC_NI_SS_HUNGARIAN_V02 = 25, /**< Language is Hungarian. */ + eQMI_LOC_NI_SS_POLISH_V02 = 26, /**< Language is Polish. */ + eQMI_LOC_NI_SS_LANGUAGE_UNSPEC_V02 = 27, /**< Language is unspecified. */ + eQMI_LOC_NI_SUPL_UTF8_V02 = 28, /**< Encoding is UTF 8. */ + eQMI_LOC_NI_SUPL_UCS2_V02 = 29, /**< Encoding is UCS 2. */ + eQMI_LOC_NI_SUPL_GSM_DEFAULT_V02 = 30, /**< Encoding is GSM default. */ + QMILOCNIDATACODINGSCHEMEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiDataCodingSchemeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLFORMATENUMTYPE_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SUPL_FORMAT_LOGICAL_NAME_V02 = 0, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_EMAIL_ADDRESS_V02 = 1, /**< SUPL email address format. */ + eQMI_LOC_NI_SUPL_FORMAT_MSISDN_V02 = 2, /**< SUPL logical name format. */ + eQMI_LOC_NI_SUPL_FORMAT_URL_V02 = 3, /**< SUPL URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_SIP_URL_V02 = 4, /**< SUPL SIP URL format. */ + eQMI_LOC_NI_SUPL_FORMAT_MIN_V02 = 5, /**< SUPL MIN format. */ + eQMI_LOC_NI_SUPL_FORMAT_MDN_V02 = 6, /**< SUPL MDN format. */ + eQMI_LOC_NI_SUPL_FORMAT_IMSPUBLIC_IDENTITY_V02 = 7, /**< SUPL IMS public identity */ + eQMI_LOC_NI_SUPL_FORMAT_OSS_UNKNOWN_V02 = 2147483647, /**< SUPL unknown format. */ + QMILOCNISUPLFORMATENUMTYPE_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplFormatEnumType_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplFormatEnumType_v02 formatType; + /**< Format of the formatted string. + + Valid values: \begin{itemize1} + \item 0x00000000 -- FORMAT_LOGICAL_NAME + \item 0x00000001 -- FORMAT_EMAIL_ADDRESS + \item 0x00000002 -- FORMAT_MSISDN + \item 0x00000003 -- FORMAT_URL + \item 0x00000004 -- FORMAT_SIP_URL + \item 0x00000005 -- FORMAT_MIN + \item 0x00000006 -- FORMAT_MDN + \item 0x00000007 -- FORMAT_IMSPUBLIC_IDENTITY + \item 0x7FFFFFFF -- FORMAT_OSS_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t formattedString_len; /**< Must be set to # of elements in formattedString */ + uint8_t formattedString[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Formatted string. \n + - Type: Byte array \n + - Maximum string length: 64 + */ +}qmiLocNiSuplFormattedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocSuplQopValidMaskT_v02; +#define QMI_LOC_NI_SUPL_MASK_QOP_HORZ_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x01) /**< Horizontal accuracy is valid in the Quality of Position (QoP). */ +#define QMI_LOC_NI_SUPL_MASK_QOP_VER_ACC_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x02) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_MAXAGE_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x04) /**< Vertical accuracy is valid in the QoP. */ +#define QMI_LOC_NI_SUPL_MASK_QOP_DELAY_VALID_V02 ((qmiLocSuplQopValidMaskT_v02)0x08) /**< Vertical accuracy is valid in the QoP. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSuplQopValidMaskT_v02 validMask; + /**< Bit field indicating which fields are valid in this value. + + Valid bitmasks: \n + - 0x01 -- QOP_HORZ_ACC_VALID \n + - 0x02 -- QOP_VER_ACC_VALID \n + - 0x04 -- QOP_MAXAGE_VALID \n + - 0x08 -- QOP_DELAY_VALID*/ + + uint8_t horizontalAccuracy; + /**< Horizontal accuracy. \n + - Units: Meters */ + + uint8_t verticalAccuracy; + /**< Vertical accuracy. \n + - Units: Meters */ + + uint16_t maxLocAge; + /**< Maximum age of the location if the engine sends a previously + computed position. \n + - Units: Seconds */ + + uint8_t delay; + /**< Delay the server is willing to tolerate for the fix. \n + - Units: Seconds */ +}qmiLocNiSuplQopStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocServerAddrTypeMaskT_v02; +#define QMI_LOC_SERVER_ADDR_TYPE_IPV4_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x01) /**< IPV4 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_IPV6_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x02) /**< IPV6 server address type. */ +#define QMI_LOC_SERVER_ADDR_TYPE_URL_MASK_V02 ((qmiLocServerAddrTypeMaskT_v02)0x04) /**< URL server address type. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t addr; + /**< IPV4 address. */ + + uint16_t port; + /**< IPV4 port. */ +}qmiLocIpV4AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t addr[QMI_LOC_IPV6_ADDR_LENGTH_V02]; + /**< IPV6 address. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 8 */ + + uint32_t port; + /**< IPV6 port. */ +}qmiLocIpV6AddrStructType_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerAddrTypeMaskT_v02 suplServerAddrTypeMask; + /**< Mask specifying the valid fields in this value. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ + + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< IPV4 address and port. */ + + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< IPV6 address and port. */ + + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiSuplServerInfoStructT_v02; /* Type */ +/** + @} + */ + +typedef uint32_t qmiLocNiSuplNotifyVerifyValidMaskT_v02; +#define QMI_LOC_SUPL_SERVER_INFO_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000001) /**< Mask to denote that the server information + is present in an NI SUPL notify verify request event. This mask is set in + the valid_flags field of a notify verify structure. */ +#define QMI_LOC_SUPL_SESSION_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000002) /**< Mask to denote that the SUPL session ID + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_HASH_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000004) /**< Mask to denote that the SUPL hash is present + in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_POS_METHOD_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000008) /**< Mask to denote that the position method is present + in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000010) /**< Mask to denote that the data coding scheme + is present in an NI SUPL notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_REQUESTOR_ID_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_CLIENT_NAME_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000040) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_QOP_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000080) /**< Mask to denote that the quality of position + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +#define QMI_LOC_SUPL_USER_RESP_TIMER_MASK_V02 ((qmiLocNiSuplNotifyVerifyValidMaskT_v02)0x00000100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid_flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplNotifyVerifyValidMaskT_v02 valid_flags; + /**< Indicates which of the following fields are present in this value. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SUPL_SERVER_INFO + \item 0x00000002 -- SUPL_SESSION_ID + \item 0x00000004 -- SUPL_HASH + \item 0x00000008 -- SUPL_POS_METHOD + \item 0x00000010 -- SUPL_DATA_CODING_SCHEME + \item 0x00000020 -- SUPL_REQUESTOR_ID + \item 0x00000040 -- SUPL_CLIENT_NAME + \item 0x00000080 -- SUPL_QOP + \item 0x00000100 -- SUPL_USER_RESP_TIMER + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplServerInfoStructT_v02 suplServerInfo; + /**< SUPL server information. */ + + uint8_t suplSessionId[QMI_LOC_NI_SUPL_SLP_SESSION_ID_BYTE_LENGTH_V02]; + /**< SUPL session ID. \n + - Type: Array of unsigned integers \n + - Maximum length of the array: 4 */ + + uint8_t suplHash[QMI_LOC_NI_SUPL_HASH_LENGTH_V02]; + /**< Hash for SUPL_INIT; used to validate that the message was not + corrupted. \n + - Type: Array of unsigned integers \n + - Length of the array: 8 */ + + qmiLocNiSuplPosMethodEnumT_v02 posMethod; + /**< GPS mode to be used for the fix. + + Valid values: \begin{itemize1} + \item 0x00000001 -- AGPS_SETASSISTED + \item 0x00000002 -- AGPS_SETBASED + \item 0x00000003 -- AGPS_SETASSISTED_PREF + \item 0x00000004 -- AGPS_SETBASED_PREF + \item 0x00000005 -- AUTONOMOUS_GPS + \item 0x00000006 -- AFLT + \item 0x00000007 -- ECID + \item 0x00000008 -- EOTD + \item 0x00000009 -- OTDOA + \item 0x0000000A -- NO_POSITION + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Data coding scheme applies to both the requestor ID and the client + name. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplFormattedStringStructT_v02 requestorId; + /**< Requestor ID. The encoding scheme for requestor_id is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplFormattedStringStructT_v02 clientName; + /**< Client name. The encoding scheme for client_name is specified in + the dataCodingScheme field. */ + + qmiLocNiSuplQopStructT_v02 suplQop; + /**< SUPL QoP. */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Units: Seconds*/ +}qmiLocNiSuplNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNILOCATIONTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_LOCATION_V02 = 1, /**< Current location. */ + eQMI_LOC_NI_LOCATIONTYPE_CURRENT_OR_LAST_KNOWN_LOCATION_V02 = 2, /**< Last known location; may be current location. */ + eQMI_LOC_NI_LOCATIONTYPE_INITIAL_LOCATION_V02 = 3, /**< Initial location. */ + QMILOCNILOCATIONTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiLocationTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Identifies the coding scheme of the coded string. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + + */ + + uint32_t codedString_len; /**< Must be set to # of elements in codedString */ + uint8_t codedString[QMI_LOC_NI_CODEWORD_MAX_LENGTH_V02]; + /**< Coded string. \n + - Type: Array of bytes \n + - Maximum string length: 20 */ +}qmiLocNiUmtsCpCodedStringStructT_v02; /* Type */ +/** + @} + */ + +typedef uint16_t qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02; +#define QMI_LOC_UMTS_CP_INVOKE_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0001) /**< Mask to denote that the invoke ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_DATA_CODING_SCHEME_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0002) /**< Mask to denote that the data coding scheme + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_NOTIFICATION_TEXT_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0004) /**< Mask to denote that the notification text + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CLIENT_ADDRESS_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0008) /**< Mask to denote that the client address + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_LOCATION_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0010) /**< Mask to denote that the location type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_REQUESTOR_ID_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0020) /**< Mask to denote that the requestor ID + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_CODEWORD_STRING_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0040) /**< Mask to denote that the code word string + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_SERVICE_TYPE_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0080) /**< Mask to denote that the service type + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +#define QMI_LOC_UMTS_CP_USER_RESP_TIMER_MASK_V02 ((qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02)0x0100) /**< Mask to denote that the user response timer + is present in an NI notify verify request event. + This mask is set in the valid flags field of a + notify verify structure. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiUmtsCpNotifyVerifyValidMaskT_v02 valid_flags; + /**< Fields that are valid in this value. + + Valid bitmasks: \begin{itemize1} + \item 0x0001 -- INVOKE_ID_MASK + \item 0x0002 -- DATA_CODING_SCHEME_MASK + \item 0x0004 -- NOTIFICATION_TEXT_MASK + \item 0x0008 -- CLIENT_ADDRESS_MASK + \item 0x0010 -- LOCATION_TYPE_MASK + \item 0x0020 -- REQUESTOR_ID_MASK + \item 0x0040 -- CODEWORD_STRING_MASK + \item 0x0080 -- SERVICE_TYPE_MASK + \item 0x0100 -- USER_RESP_TIMER_MASK + \vspace{-0.18in} \end{itemize1} + */ + + uint8_t invokeId; + /**< Supplementary Services invoke ID. */ + + qmiLocNiDataCodingSchemeEnumT_v02 dataCodingScheme; + /**< Type of data encoding scheme for the text. + Applies to both the notification text and the client address. + + Valid values: \begin{itemize1} + \item 0x0000000C -- NI_SS_GERMAN + \item 0x0000000D -- NI_SS_ENGLISH + \item 0x0000000E -- NI_SS_ITALIAN + \item 0x0000000F -- NI_SS_FRENCH + \item 0x00000010 -- NI_SS_SPANISH + \item 0x00000011 -- NI_SS_DUTCH + \item 0x00000012 -- NI_SS_SWEDISH + \item 0x00000013 -- NI_SS_DANISH + \item 0x00000014 -- NI_SS_PORTUGUESE + \item 0x00000015 -- NI_SS_FINNISH + \item 0x00000016 -- NI_SS_NORWEGIAN + \item 0x00000017 -- NI_SS_GREEK + \item 0x00000018 -- NI_SS_TURKISH + \item 0x00000019 -- NI_SS_HUNGARIAN + \item 0x0000001A -- NI_SS_POLISH + \item 0x0000001B -- NI_SS_LANGUAGE_UNSPEC + \item 0x0000001C -- NI_SUPL_UTF8 + \item 0x0000001D -- NI_SUPL_UCS2 + \item 0x0000001E -- NI_SUPL_GSM_DEFAULT + \vspace{-0.18in} \end{itemize1} + */ + + uint32_t notificationText_len; /**< Must be set to # of elements in notificationText */ + uint8_t notificationText[QMI_LOC_NI_MAX_CLIENT_NAME_LENGTH_V02]; + /**< Notification text; the encoding method is specified in + dataCodingScheme. \n + - Type: Array of bytes \n + - Maximum array length: 64 */ + + uint32_t clientAddress_len; /**< Must be set to # of elements in clientAddress */ + uint8_t clientAddress[QMI_LOC_NI_MAX_EXT_CLIENT_ADDRESS_V02]; + /**< Client address; the encoding method is specified in + dataCodingScheme. \n + - Maximum array length: 20 */ + + qmiLocNiLocationTypeEnumT_v02 locationType; + /**< Location type. + + Valid values: \begin{itemize1} + \item 0x00000001 -- CURRENT_LOCATION + \item 0x00000002 -- CURRENT_OR_LAST_KNOWN_LOCATION + \item 0x00000004 -- INITIAL_LOCATION + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiUmtsCpCodedStringStructT_v02 requestorId; + /**< Requestor ID; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + qmiLocNiUmtsCpCodedStringStructT_v02 codewordString; + /**< Codeword string; the encoding method is specified in the + qmiLocNiUmtsCpCodedStringStructT.dataCodingScheme field. */ + + uint8_t lcsServiceTypeId; + /**< Service type ID. */ + + uint16_t userResponseTimer; + /**< Time to wait for the user to respond. \n + - Units: Seconds */ +}qmiLocNiUmtsCpNotifyVerifyStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISERVICEINTERACTIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_SERVICE_INTERACTION_ONGOING_NI_INCOMING_MO_V02 = 1, /**< Service interaction between ongoing NI and incoming MO sessions. */ + QMILOCNISERVICEINTERACTIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiServiceInteractionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiVxNotifyVerifyStructT_v02 niVxReq; + /**< Ongoing NI session request; this information is currently not filled. */ + + qmiLocNiServiceInteractionEnumT_v02 serviceInteractionType; + /**< Service interaction type specified in qmiLocNiServiceInteractionEnumT. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ONGOING_NI_INCOMING_MO + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiVxServiceInteractionStructT_v02; /* Type */ +/** + @} + */ + +typedef uint16_t qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WLAN_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0001) /**< Denotes that WLAN measurements are allowed as part of location ID + and multiple location IDs in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_GSM_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0002) /**< Denotes that GSM measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WCDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0004) /**< Denotes that WCDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_CDMA_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0008) /**< Denotes that CDMA measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HRDP_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0010) /**< Denotes that HRDP measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_UMB_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0020) /**< Denotes that UMB measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_LTE_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0040) /**< Denotes that LTE measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_WIMAX_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0080) /**< Denotes that WIMAX measurements are allowed as part of location ID + and multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_HISTORIC_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0100) /**< Denotes that historical information is allowed as part of + multiple location ID in the SUPL_POS_INIT message. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_SUPPORTED_NETWORK_NONSVRV_V02 ((qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02)0x0200) /**< Denotes that information about nonserving cells is allowed + as part of multiple location ID in the SUPL_POS_INIT message. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_SINGLE_SHOT_V02 = -1, /**< The SUPL INIT message indicates a request for a single shot + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_PERIODIC_V02 = 0, /**< The SUPL INIT message indicates a request for a periodic + triggered session. */ + eQMI_LOC_SUPL_VER_2_EXT_TRIGGER_TYPE_AREA_EVENT_V02 = 1, /**< The SUPL INIT message indicates a request for an area event + triggered session. */ + QMILOCNISUPLVER2EXTTRIGGERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02; +/** + @} + */ + +typedef uint16_t qmiLocNiSuplVer2ExtGnssTypeMaskT_v02; +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0001) /**< GPS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GLONASS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0002) /**< GLONASS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_GALILEO_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0004) /**< Galileo is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_SBAS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0008) /**< SBAS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_QZSS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0010) /**< QZSS is allowed to be used as the positioning technology. */ +#define QMI_LOC_SUPL_VER_2_EXT_MASK_GNSS_MODERN_GPS_V02 ((qmiLocNiSuplVer2ExtGnssTypeMaskT_v02)0x0020) /**< Modern GPS is allowed to be used as the positioning technology. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocNiSuplVer2ExtSupportedNetworksMaskT_v02 supportedNetworksMask; + /**< Specifies which type of network measurements are allowed to be sent as + part of the Location ID or Multiple Location IDs parameter in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid bitmasks: \begin{itemize1} + \item 0x0001 -- SUPPORTED_NETWORK_WLAN + \item 0x0002 -- SUPPORTED_NETWORK_GSM + \item 0x0004 -- SUPPORTED_NETWORK_WCDMA + \item 0x0008 -- SUPPORTED_NETWORK_CDMA + \item 0x0010 -- SUPPORTED_NETWORK_HRDP + \item 0x0020 -- SUPPORTED_NETWORK_UMB + \item 0x0040 -- SUPPORTED_NETWORK_LTE + \item 0x0080 -- SUPPORTED_NETWORK_WIMAX + \item 0x0100 -- SUPPORTED_NETWORK_HISTORIC + \item 0x0200 -- SUPPORTED_NETWORK_NONSVRV + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocNiSuplVer2ExtTriggerTypeEnumT_v02 triggerType; + /**< Specifies the type of session trigger requested in the + SUPL_POS_INIT message (see \hyperref[S4]{[S4]}). + + Valid values: \begin{itemize1} + \item 0xFFFFFFFF -- TRIGGER_TYPE_SINGLE_SHOT + \item 0x00000000 -- TRIGGER_TYPE_PERIODIC + \item 0x00000001 -- TRIGGER_TYPE_AREA_EVENT + \vspace{-0.18in} \end{itemize1} */ + + qmiLocNiSuplVer2ExtGnssTypeMaskT_v02 gnssType; + /**< Specifies which GNSS technologies are allowed as positioning + technologies. + + Valid bitmasks: \n + - 0x0001 -- GNSS_GPS \n + - 0x0002 -- GNSS_GLONASS \n + - 0x0004 -- GNSS_GALILEO \n + - 0x0008 -- GNSS_SBAS \n + - 0x0010 -- GNSS_QZSS \n + - 0x0020 -- GNSS_MODERN_GPS + */ +}qmiLocNiSuplVer2ExtStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char eslpUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< The ESLP URL + Maximum length: 255 bytes */ +}qmiLocEmergencyNotificationStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Indicates an NI notify/verify request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIFY + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxInd_valid; /**< Must be set to true if NiVxInd is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxInd; + /**< \n Optional NI Vx request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplInd_valid; /**< Must be set to true if NiSuplInd is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplInd; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpInd_valid; /**< Must be set to true if NiUmtsCpInd is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpInd; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionInd_valid; /**< Must be set to true if NiVxServiceInteractionInd is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionInd; + /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtInd_valid; /**< Must be set to true if NiSuplVer2ExtInd is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtInd; + /**< \n Optional NI SUPL Version 2 Extension payload. When present, + this payload is to be used in conjunction with the SUPL + indication payload. */ + + /* Optional */ + /* SUPL Emergency Notification */ + uint8_t suplEmergencyNotification_valid; /**< Must be set to true if suplEmergencyNotification is being passed */ + qmiLocEmergencyNotificationStructT_v02 suplEmergencyNotification; + /**< This specifies that the corresponding NI notification is an + emergency notification. Emergency notification + can be given even without an ESLP address */ +}qmiLocEventNiNotifyVerifyReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + char serverUrl[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< Assistance server URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocAssistanceServerUrlStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t delayThreshold; + /**< The time server is to be skipped if a one-way delay to the server + exceeds this threshold. \n + - Units: Milliseconds */ + + uint32_t timeServerList_len; /**< Must be set to # of elements in timeServerList */ + qmiLocAssistanceServerUrlStructT_v02 timeServerList[QMI_LOC_MAX_NTP_SERVERS_V02]; + /**< List of Time Server URL's that are recommended by the service for time + information, the list is ordered, the client is to use the first + server specified in the list as the primary URL to fetch NTP time, + the second one as secondary, and so on. \n + - Maximum server list items: 3 */ +}qmiLocTimeServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject time information. */ +typedef struct { + + /* Optional */ + /* Time Server Info */ + uint8_t timeServerInfo_valid; /**< Must be set to true if timeServerInfo is being passed */ + qmiLocTimeServerListStructT_v02 timeServerInfo; + /**< \n Contains information about the time servers recommended by the + location service for NTP time. */ +}qmiLocEventInjectTimeReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t maxFileSizeInBytes; + /**< Maximum allowable predicted orbits file size (in bytes). */ + + uint32_t maxPartSize; + /**< Maximum allowable predicted orbits file chunk size (in bytes). */ +}qmiLocPredictedOrbitsAllowedSizesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t serverList_len; /**< Must be set to # of elements in serverList */ + qmiLocAssistanceServerUrlStructT_v02 serverList[QMI_LOC_MAX_PREDICTED_ORBITS_SERVERS_V02]; + /**< List of predicted orbits URLs. The list is ordered, so the client + must use the first server specified in the list as the primary URL + from which to download predicted orbits data, the second one as + secondary, and so on. \n + - Maximum number of servers that can be specified: 3 */ +}qmiLocPredictedOrbitsServerListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Allowed Sizes */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocEventInjectPredictedOrbitsReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to inject a position. */ +typedef struct { + + /* Mandatory */ + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Mandatory */ + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Mandatory */ + /* Circular Horizontal Uncertainty */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Mandatory */ + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEventInjectPositionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCENGINESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ENGINE_STATE_ON_V02 = 1, /**< Location engine is on. */ + eQMI_LOC_ENGINE_STATE_OFF_V02 = 2, /**< Location engine is off. */ + QMILOCENGINESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocEngineStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the engine state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Engine State */ + qmiLocEngineStateEnumT_v02 engineState; + /**< Location engine state. + + Valid values: \n + - 0x00000001 -- ON \n + - 0x00000002 -- OFF + */ +}qmiLocEventEngineStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCFIXSESSIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_FIX_SESSION_STARTED_V02 = 1, /**< Location fix session has started. */ + eQMI_LOC_FIX_SESSION_FINISHED_V02 = 2, /**< Location fix session has ended. */ + QMILOCFIXSESSIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocFixSessionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the fix session state to the control point. */ +typedef struct { + + /* Mandatory */ + /* Session State */ + qmiLocFixSessionStateEnumT_v02 sessionState; + /**< LOC fix session state. + + Valid values: \n + - 0x00000001 -- STARTED \n + - 0x00000002 -- FINISHED + */ + + /* Optional */ + /* Session ID */ + uint8_t sessionId_valid; /**< Must be set to true if sessionId is being passed */ + uint8_t sessionId; + /**< ID of the session that was specified in the Start request. + This may not be specified for a fix session corresponding to + a network-initiated request. \n + - Range: 0 to 255 */ +}qmiLocEventFixSessionStateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_START_PERIODIC_HI_FREQ_FIXES_V02 = 0, /**< Start periodic fixes with high frequency. */ + eQMI_LOC_WIFI_START_PERIODIC_KEEP_WARM_V02 = 1, /**< Keep warm for low frequency fixes without data downloads. */ + eQMI_LOC_WIFI_STOP_PERIODIC_FIXES_V02 = 2, /**< Stop periodic fixes request. */ + QMILOCWIFIREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends a WiFi request to the control point. */ +typedef struct { + + /* Mandatory */ + /* Request Type */ + qmiLocWifiRequestEnumT_v02 requestType; + /**< Request type as specified in qmiWifiRequestEnumT. + + Valid values: \begin{itemize1} + \item 0x00000000 -- START_PERIODIC_HI_FREQ_FIXES + \item 0x00000001 -- START_PERIODIC_KEEP_WARM + \item 0x00000002 -- STOP_PERIODIC_FIXES + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Time Between Fixes */ + uint8_t tbfInMs_valid; /**< Must be set to true if tbfInMs is being passed */ + uint16_t tbfInMs; + /**< Time between fixes for a periodic request.\n + - Units: Milliseconds */ +}qmiLocEventWifiReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t samplesPerBatch; + /**< Specifies the number of samples per batch the GNSS location engine is to + receive. The sensor sampling frequency can be computed as follows: \n + + samplingFrequency = samplesPerBatch * batchesPerSecond \n + + samplesPerBatch must be a nonzero positive value. + */ + + uint16_t batchesPerSecond; + /**< Number of sensor-data batches the GNSS location engine is to receive + per second. The rate is specified in an integral number of batches per + second (Hz). \n + + batchesPerSecond must be a nonzero positive value. + */ +}qmiLocSensorControlConfigSamplingSpecStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t injectEnable; + /**< Whether the GNSS location engine is ready to accept data from this + sensor. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- GNSS location engine is ready to accept sensor + data + \item 0x00 (FALSE) -- GNSS location engine is not ready to accept + sensor data + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocSensorControlConfigSamplingSpecStructT_v02 dataFrequency; + /**< Rate at which the GNSS engine would like the sensor to be sampled. \n + The rate is specified in integral number of samples per second (Hz)\n + and batches per second. + */ +}qmiLocSensorReadyStatusStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point if the GNSS location engine is + ready to accept sensor data. */ +typedef struct { + + /* Optional */ + /* Accelerometer Accept Ready */ + uint8_t accelReady_valid; /**< Must be set to true if accelReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 accelReady; + /**< \n Whether the GNSS location engine is ready to accept accelerometer + sensor data. + */ + + /* Optional */ + /* Gyroscope Accept Ready */ + uint8_t gyroReady_valid; /**< Must be set to true if gyroReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 gyroReady; + /**< \n Whether the GNSS location engine is ready to accept gyroscope sensor + data. + */ + + /* Optional */ + /* Accelerometer Temperature Accept Ready */ + uint8_t accelTemperatureReady_valid; /**< Must be set to true if accelTemperatureReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 accelTemperatureReady; + /**< \n Whether the GNSS location engine is ready to accept accelerometer + temperature data. + */ + + /* Optional */ + /* Gyroscope Temperature Accept Ready */ + uint8_t gyroTemperatureReady_valid; /**< Must be set to true if gyroTemperatureReady is being passed */ + qmiLocSensorReadyStatusStructT_v02 gyroTemperatureReady; + /**< \n Whether the GNSS location engine is ready to accept gyroscope + temperature data. + */ +}qmiLocEventSensorStreamingReadyStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point to inject time synchronization + data. */ +typedef struct { + + /* Mandatory */ + /* Opaque Time Sync Reference Counter */ + uint32_t refCounter; + /**< This TLV is sent to registered control points. It is sent by + the location engine when it needs to synchronize location engine and + control point (sensor processor) times. + This TLV must be echoed back in the Time Sync Inject request. */ +}qmiLocEventTimeSyncReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the control point to enable Stationary Position + Indicator (SPI) streaming reports. */ +typedef struct { + + /* Mandatory */ + /* Enable/Disable SPI Requests */ + uint8_t enable; + /**< Whether the client is to start or stop sending an SPI status stream. + \begin{itemize1} + \item 0x01 (TRUE) -- Client is to start sending an SPI status stream + \item 0x00 (FALSE) -- Client is to stop sending an SPI status stream + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocEventSetSpiStreamingReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWWANTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WWAN_TYPE_INTERNET_V02 = 0, /**< Bring up the WWAN type used for an Internet connection. */ + eQMI_LOC_WWAN_TYPE_AGNSS_V02 = 1, /**< Bring up the WWAN type used for AGNSS connections. */ + QMILOCWWANTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWWANTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQUESTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQUEST_OPEN_V02 = 1, /**< Open a connection to the location server. */ + eQMI_LOC_SERVER_REQUEST_CLOSE_V02 = 2, /**< Close a connection to the location server. */ + QMILOCSERVERREQUESTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerRequestEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Requests the client to open or close a connection + to the assisted GPS location server. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Identifies a connection across Open and Close request events. */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Open or close a connection to the location server. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* WWAN Type */ + qmiLocWWANTypeEnumT_v02 wwanType; + /**< Identifies the WWAN type for this request. \n + + Valid values: \begin{itemize1} + \item 0x00000000 -- WWAN_TYPE_INTERNET + \item 0x00000001 -- WWAN_TYPE_AGNSS + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventLocationServerConnectionReqIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIGEOFENCEOPERATIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_GEOFENCE_ADDED_V02 = 1, /**< An NI Geofence was added. */ + eQMI_LOC_NI_GEOFENCE_DELETED_V02 = 2, /**< An NI Geofence was deleted. */ + eQMI_LOC_NI_GEOFENCE_EDITED_V02 = 3, /**< An NI Geofence was edited. The control point can query the + Geofence to find the its current state. */ + QMILOCNIGEOFENCEOPERATIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiGeofenceOperationEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Informs the control point about + network-initiated Geofences. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Operation Type */ + qmiLocNiGeofenceOperationEnumT_v02 operationType; + /**< Operation for which this notification was generated. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NI_GEOFENCE_ADDED + \item 0x00000002 -- NI_GEOFENCE_DELETED + \item 0x00000003 -- NI_GEOFENCE_EDITED + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventNiGeofenceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEGENALERTENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE_V02 = 1, /**< GNSS is unavailable and GNSS position fixes + cannot be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_GNSS_AVAILABLE_V02 = 2, /**< GNSS is now available and GNSS postion fixes can + be used to monitor Geofences. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_OOS_V02 = 3, /**< The engine is out of service and no cell ID coverage + information is available. */ + eQMI_LOC_GEOFENCE_GEN_ALERT_TIME_INVALID_V02 = 4, /**< The engine has an invalid time. */ + QMILOCGEOFENCEGENALERTENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceGenAlertEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of the + Geofence status. */ +typedef struct { + + /* Mandatory */ + /* Geofence General Alert */ + qmiLocGeofenceGenAlertEnumT_v02 geofenceAlert; + /**< Specifies the Geofence general alert type. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_GEN_ALERT_GNSS_UNAVAILABLE + \item 0x00000002 -- GEOFENCE_GEN_ALERT_GNSS_AVAILABLE + \item 0x00000003 -- GEOFENCE_GEN_ALERT_OOS + \item 0x00000004 -- GEOFENCE_GEN_ALERT_TIME_INVALID + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventGeofenceGenAlertIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEBREACHTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_BREACH_TYPE_ENTERING_V02 = 1, /**< Denotes that a client entered the Geofence. */ + eQMI_LOC_GEOFENCE_BREACH_TYPE_LEAVING_V02 = 2, /**< Denotes that a client left the Geofence. */ + QMILOCGEOFENCEBREACHTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceBreachTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + /* UTC Timestamp */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Latitude */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Longitude */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Horizontal Elliptical Uncertainty (Semi-Minor Axis) */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Horizontal Elliptical Uncertainty (Semi-Major Axis) */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty.\n + - Units: Meters */ + + /* Elliptical Horizontal Uncertainty Azimuth */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation.\n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Horizontal Speed validity bit */ + uint8_t speedHorizontal_valid; + /**< Indicates whether the Horizontal speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Horizontal speed is valid + \item 0x00 (FALSE) -- Horizontal speed is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Horizontal Speed */ + float speedHorizontal; + /**< Horizontal speed.\n + - Units: Meters/second */ + + /* Altitude validity bit */ + uint8_t altitudeWrtEllipsoid_valid; + /**< Indicates whether the altitude field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Altitude field is valid + \item 0x00 (FALSE) -- Altitude field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} + */ + + /* Altitude With Respect to Ellipsoid */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Vertical Uncertainty validity bit */ + uint8_t vertUnc_valid; + /**< Indicates whether the Vertical Uncertainty field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Uncertainty field is valid + \item 0x00 (FALSE) -- Vertical Uncertainty field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Uncertainty */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Vertical Speed validity bit */ + uint8_t speedVertical_valid; + /**< Indicates whether the Vertical Speed field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Vertical Speed field is valid + \item 0x00 (FALSE) -- Vertical Speed field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Vertical Speed */ + float speedVertical; + /**< Vertical speed.\n + - Units: Meters/second */ + + /* heading validity bit */ + uint8_t heading_valid; + /**< Indicates whether the Heading field contains valid + information. + \begin{itemize1} + \item 0x01 (TRUE) -- Heading field is valid + \item 0x00 (FALSE) -- Heading field is invalid + and is to be ignored + \vspace{-0.18in} \end{itemize1} */ + + /* Heading */ + float heading; + /**< Heading.\n + - Units: Degrees \n + - Range: 0 to 359.999 */ +}qmiLocGeofencePositionStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the control point of + a Geofence breach event. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< ID of the Geofence for which this + notification was generated. */ + + /* Mandatory */ + /* Geofence Breach Type */ + qmiLocGeofenceBreachTypeEnumT_v02 breachType; + /**< The type of breach that generated this event. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_BREACH_TYPE_ENTERING + \item 0x00000002 -- GEOFENCE_BREACH_TYPE_LEAVING + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Geofence Position */ + uint8_t geofencePosition_valid; /**< Must be set to true if geofencePosition is being passed */ + qmiLocGeofencePositionStructT_v02 geofencePosition; + /**< \n Position of the client when it breached the Geofence. + This TLV is included if the client configures the + Geofence to report position. The position is reported + at the same confidence level that was specified in the + Add Circular Geofence request. */ +}qmiLocEventGeofenceBreachIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Recommends how pedometer reports should be + sent to the location engine */ +typedef struct { + + /* Mandatory */ + /* Request Pedometer Data */ + uint8_t requestPedometerData; + /**< \n Whether GNSS location engine is requesting the client to + send pedometer data. + \begin{itemize1} + \item 0x01 (TRUE) -- GNSS location engine is requesting + pedometer data + \item 0x00 (FALSE) -- GNSS location engine is not requesting + pedometer data + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Reset Step Count */ + uint8_t resetStepCount_valid; /**< Must be set to true if resetStepCount is being passed */ + uint8_t resetStepCount; + /**< Whether location engine desires the step count to be reset. + \begin{itemize1} + \item 0x01 (TRUE) -- Pedometer step count should be reset. + \item 0x00 (FALSE) -- Pedometer step count should not be reset. + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Step Count Threshold */ + uint8_t stepCountThreshold_valid; /**< Must be set to true if stepCountThreshold is being passed */ + uint32_t stepCountThreshold; + /**< Specifies the number of steps to be sampled in a pedometer report + as recommended by the the location engine. If the threshold is set to 0 + then the location engine desires a pedometer report at every step event. + */ +}qmiLocEventPedometerControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Recommends how motion data reports should be + sent to the location engine */ +typedef struct { + + /* Mandatory */ + /* Request Motion Data */ + uint8_t requestMotionData; + /**< \n Whether GNSS location engine is requesting the client to + send motion data. + \begin{itemize1} + \item 0x01 (TRUE) -- GNSS location engine is requesting + motion data + \item 0x00 (FALSE) -- GNSS location engine is not requesting + motion data + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocEventMotionDataControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUCCESS_V02 = 0, /**< Request was completed successfully. */ + eQMI_LOC_GENERAL_FAILURE_V02 = 1, /**< Request failed because of a general failure. */ + eQMI_LOC_UNSUPPORTED_V02 = 2, /**< Request failed because it is not supported. */ + eQMI_LOC_INVALID_PARAMETER_V02 = 3, /**< Request failed because it contained invalid parameters. */ + eQMI_LOC_ENGINE_BUSY_V02 = 4, /**< Request failed because the engine is busy. */ + eQMI_LOC_PHONE_OFFLINE_V02 = 5, /**< Request failed because the phone is offline. */ + eQMI_LOC_TIMEOUT_V02 = 6, /**< Request failed because it timed out. */ + eQMI_LOC_CONFIG_NOT_SUPPORTED_V02 = 7, /**< Request failed because an undefined configuration was requested */ + eQMI_LOC_INSUFFICIENT_MEMORY_V02 = 8, /**< Request failed because the engine could not allocate sufficent + memory for the request. */ + QMILOCSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocStatusEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetServiceRevisionReqMsgT is empty + * typedef struct { + * }qmiLocGetServiceRevisionReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Client can query the service revision using this message. */ +typedef struct { + + /* Mandatory */ + /* Get Revision Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Revision request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Interface Definition Minor Revision */ + uint32_t revision; + /**< Revision of the service. This is the minor revision of the interface that + the service implements. Minor revision updates of the service are always + backward compatible. */ + + /* Optional */ + /* GNSS Measurement Engine Firmware Version String */ + uint8_t gnssMeFWVerString_valid; /**< Must be set to true if gnssMeFWVerString is being passed */ + char gnssMeFWVerString[QMI_LOC_GNSS_ME_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS measurement engine software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in} \end{itemize1} + + \textbf{Note:} This string is only provided on platforms that have + a measurement engine that supports this version string. On all other + platforms, this optional TLV is not provided. */ + + /* Optional */ + /* GNSS Hosted Software Version String */ + uint8_t gnssHostSWVerString_valid; /**< Must be set to true if gnssHostSWVerString is being passed */ + char gnssHostSWVerString[QMI_LOC_GNSS_HOSTED_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Version of the GNSS hosted software running under the LOC API. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 128 + \vspace{0.1in}\end{itemize1} + + \textbf{Note:} This string is only provided on hosted architectures + (measurement and position engine running on different processors) that + support this version string. On all other platforms, this optional TLV + is not provided. */ + + /* Optional */ + /* GNSS Software Version String */ + uint8_t gnssSWVerString_valid; /**< Must be set to true if gnssSWVerString is being passed */ + char gnssSWVerString[QMI_LOC_GNSS_SW_VERSION_STRING_MAX_LENGTH_V02 + 1]; + /**< Aggregate version of the GNSS software. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} */ +}qmiLocGetServiceRevisionIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetFixCriteriaReqMsgT is empty + * typedef struct { + * }qmiLocGetFixCriteriaReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the fix criteria from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Fix Criteria Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Fix Criteria request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Horizontal Accuracy */ + uint8_t horizontalAccuracyLevel_valid; /**< Must be set to true if horizontalAccuracyLevel is being passed */ + qmiLocAccuracyLevelEnumT_v02 horizontalAccuracyLevel; + /**< Horizontal accuracy level. + + Valid values: \begin{itemize1} + \item 0x00000001 -- LOW: Client requires low horizontal accuracy + \item 0x00000002 -- MED: Client requires medium horizontal accuracy + \item 0x00000003 -- HIGH: Client requires high horizontal accuracy + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable Intermediate Fixes */ + uint8_t intermediateReportState_valid; /**< Must be set to true if intermediateReportState is being passed */ + qmiLocIntermediateReportStateEnumT_v02 intermediateReportState; + /**< Intermediate Report state (ON, OFF).\n + The client must explicitly set this field to OFF to stop receiving + intermediate position reports. Intermediate position reports are + generated at \n 1 Hz and are ON by default. If intermediate reports + are turned ON, the client receives position reports even if the + accuracy criteria is not met. The status in the position report is + set to IN_PROGRESS for intermediate reports. + + Valid values: \begin{itemize1} + \item 0x00000001 -- ON: Client is interested in receiving intermediate + reports + \item 0x00000002 -- OFF: Client is not interested in receiving + intermediate reports + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Minimum Interval Between Fixes */ + uint8_t minInterval_valid; /**< Must be set to true if minInterval is being passed */ + uint32_t minInterval; + /**< Time that must elapse before alerting the client. \n + - Units: Milliseconds */ + + /* Optional */ + /* ID of the Application that Sent the Position Request */ + uint8_t applicationId_valid; /**< Must be set to true if applicationId is being passed */ + qmiLocApplicationIdStructT_v02 applicationId; + /**< \n Application provider, name, and version.*/ +}qmiLocGetFixCriteriaIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCNIUSERRESPENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_ACCEPT_V02 = 1, /**< User accepted notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_DENY_V02 = 2, /**< User denied notify verify request. */ + eQMI_LOC_NI_LCS_NOTIFY_VERIFY_NORESP_V02 = 3, /**< User did not respond to notify verify request. */ + QMILOCNIUSERRESPENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocNiUserRespEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* User Response */ + qmiLocNiUserRespEnumT_v02 userResp; + /**< User accepted or denied. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NOTIFY_VERIFY_ACCEPT + \item 0x00000002 -- NOTIFY_VERIFY_DENY + \item 0x00000003 -- NOTIFY_VERIFY_NORESP + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Notification Type */ + qmiLocNiNotifyVerifyEnumT_v02 notificationType; + /**< Type of notification/verification performed. + + Valid values: \begin{itemize1} + \item 0x00000001 -- NO_NOTIFY_NO_VERIF + \item 0x00000002 -- NOTIFY_ONLY + \item 0x00000003 -- ALLOW_NO_RESP + \item 0x00000004 -- NOT_ALLOW_NO_RESP + \item 0x00000005 -- PRIVACY_OVERRIDE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Network Initiated Vx Request */ + uint8_t NiVxPayload_valid; /**< Must be set to true if NiVxPayload is being passed */ + qmiLocNiVxNotifyVerifyStructT_v02 NiVxPayload; + /**< \n Optional NI VX request payload. */ + + /* Optional */ + /* Network Initiated SUPL Request */ + uint8_t NiSuplPayload_valid; /**< Must be set to true if NiSuplPayload is being passed */ + qmiLocNiSuplNotifyVerifyStructT_v02 NiSuplPayload; + /**< \n Optional NI SUPL request payload. */ + + /* Optional */ + /* Network Initiated UMTS Control Plane Request */ + uint8_t NiUmtsCpPayload_valid; /**< Must be set to true if NiUmtsCpPayload is being passed */ + qmiLocNiUmtsCpNotifyVerifyStructT_v02 NiUmtsCpPayload; + /**< \n Optional NI UMTS-CP request payload. */ + + /* Optional */ + /* Network Initiated Service Interaction Request */ + uint8_t NiVxServiceInteractionPayload_valid; /**< Must be set to true if NiVxServiceInteractionPayload is being passed */ + qmiLocNiVxServiceInteractionStructT_v02 NiVxServiceInteractionPayload; + /**< \n Optional NI service interaction payload. */ + + /* Optional */ + /* Network Initiated SUPL Version 2 Extension */ + uint8_t NiSuplVer2ExtPayload_valid; /**< Must be set to true if NiSuplVer2ExtPayload is being passed */ + qmiLocNiSuplVer2ExtStructT_v02 NiSuplVer2ExtPayload; + /**< \n Optional SUPL Version 2 Extension payload. */ + + /* Optional */ + /* SUPL Emergency Notification */ + uint8_t suplEmergencyNotification_valid; /**< Must be set to true if suplEmergencyNotification is being passed */ + qmiLocEmergencyNotificationStructT_v02 suplEmergencyNotification; + /**< SUPL Emergency notification payload. Emergency notification + can be given even without an ESLP address */ +}qmiLocNiUserRespReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sends the NI user response back to the engine; success or + failure is reported in a separate indication. */ +typedef struct { + + /* Mandatory */ + /* NI User Response Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the NI User Response request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNiUserRespIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_PREDICTED_ORBITS_XTRA_V02 = 0, /**< Default is QCOM-XTRA format. */ + QMILOCPREDICTEDORBITSDATAFORMATENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPredictedOrbitsDataFormatEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Total Size */ + uint32_t totalSize; + /**< Total size of the predicted orbits data to be injected. \n + - Units: Bytes */ + + /* Mandatory */ + /* Total Parts */ + uint16_t totalParts; + /**< Total number of parts into which the predicted orbits data is + divided. */ + + /* Mandatory */ + /* Part Number */ + uint16_t partNum; + /**< Number of the current predicted orbits data part; starts at 1. */ + + /* Mandatory */ + /* Data */ + uint32_t partData_len; /**< Must be set to # of elements in partData */ + char partData[QMI_LOC_MAX_PREDICTED_ORBITS_PART_LEN_V02]; + /**< Predicted orbits data. \n + - Type: Array of bytes \n + - Maximum length of the array: 1024 + */ + + /* Optional */ + /* Format Type */ + uint8_t formatType_valid; /**< Must be set to true if formatType is being passed */ + qmiLocPredictedOrbitsDataFormatEnumT_v02 formatType; + /**< Predicted orbits data format. + + Valid values: \begin{itemize1} + \item 0x00000000 -- PREDICTED_ORBITS_XTRA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectPredictedOrbitsDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects predicted orbits data. */ +typedef struct { + + /* Mandatory */ + /* Data Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Data Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Part Number */ + uint8_t partNum_valid; /**< Must be set to true if partNum is being passed */ + uint16_t partNum; + /**< Number of the predicted orbits data part for which this indication + is sent; starts at 1. */ +}qmiLocInjectPredictedOrbitsDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataSourceReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataSourceReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data source. */ +typedef struct { + + /* Mandatory */ + /* Predicted Orbits Data Source Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for a predicted orbits data source. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Allowed Sizes */ + uint8_t allowedSizes_valid; /**< Must be set to true if allowedSizes is being passed */ + qmiLocPredictedOrbitsAllowedSizesStructT_v02 allowedSizes; + /**< \n Maximum part and file size allowed to be injected in the engine. */ + + /* Optional */ + /* Server List */ + uint8_t serverList_valid; /**< Must be set to true if serverList is being passed */ + qmiLocPredictedOrbitsServerListStructT_v02 serverList; + /**< \n List of servers that can be used by the client to download + predicted orbits data. */ +}qmiLocGetPredictedOrbitsDataSourceIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetPredictedOrbitsDataValidityReqMsgT is empty + * typedef struct { + * }qmiLocGetPredictedOrbitsDataValidityReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint64_t startTimeInUTC; + /**< Predicted orbits data is valid starting from this time. \n + - Units: Seconds (since Jan. 1, 1970) + */ + + uint16_t durationHours; + /**< Duration from the start time for which the data is valid.\n + - Units: Hours + */ +}qmiLocPredictedOrbitsDataValidityStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the predicted orbits data validity. */ +typedef struct { + + /* Mandatory */ + /* Predicted Orbits Data Validity Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the query request for predicted orbits data validity. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Validity Info */ + uint8_t validityInfo_valid; /**< Must be set to true if validityInfo is being passed */ + qmiLocPredictedOrbitsDataValidityStructT_v02 validityInfo; +}qmiLocGetPredictedOrbitsDataValidityIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time */ + uint64_t timeUtc; + /**< UTC time since Jan. 1, 1970.\n + - Units: Milliseconds */ + + /* Mandatory */ + /* Time Uncertainty */ + uint32_t timeUnc; + /**< Time uncertainty.\n + - Units: Milliseconds */ +}qmiLocInjectUtcTimeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects UTC time in the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Time Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Time Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectUtcTimeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_UNKNOWN_V02 = 0, /**< Source is unknown. */ + eQMI_LOC_ALT_SRC_GPS_V02 = 1, /**< GPS is the source. */ + eQMI_LOC_ALT_SRC_CELL_ID_V02 = 2, /**< Cell ID provided the source. */ + eQMI_LOC_ALT_SRC_ENHANCED_CELL_ID_V02 = 3, /**< Source is enhanced cell ID. */ + eQMI_LOC_ALT_SRC_WIFI_V02 = 4, /**< WiFi is the source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_V02 = 5, /**< Terrestrial source. */ + eQMI_LOC_ALT_SRC_TERRESTRIAL_HYBRID_V02 = 6, /**< Hybrid terrestrial source. */ + eQMI_LOC_ALT_SRC_ALTITUDE_DATABASE_V02 = 7, /**< Altitude database is the source. */ + eQMI_LOC_ALT_SRC_BAROMETRIC_ALTIMETER_V02 = 8, /**< Barometric altimeter is the source. */ + eQMI_LOC_ALT_SRC_OTHER_V02 = 9, /**< Other sources. */ + QMILOCALTSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCLINKAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_SRC_LINKAGE_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INTERDEPENDENT_V02 = 1, /**< Fully interdependent. */ + eQMI_LOC_ALT_SRC_LINKAGE_DEPENDS_ON_LAT_LONG_V02 = 2, /**< Depends on latitude and longitude. */ + eQMI_LOC_ALT_SRC_LINKAGE_FULLY_INDEPENDENT_V02 = 3, /**< Fully independent. */ + QMILOCALTSRCLINKAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcLinkageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_ALT_UNCERTAINTY_NOT_SPECIFIED_V02 = 0, /**< Not specified. */ + eQMI_LOC_ALT_UNCERTAINTY_POINT_V02 = 1, /**< Altitude uncertainty is valid at the injected horizontal + position coordinates only. */ + eQMI_LOC_ALT_UNCERTAINTY_FULL_V02 = 2, /**< Altitude uncertainty applies to the position of the device + regardless of horizontal position (within the horizontal + uncertainty region, if provided). */ + QMILOCALTSRCUNCERTAINTYCOVERAGEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocAltSrcUncertaintyCoverageEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocAltSrcEnumT_v02 source; + /**< Specifies the source of the altitude. + + Valid values: \begin{itemize1} + \item 0x00000000 -- ALT_SRC_UNKNOWN + \item 0x00000001 -- ALT_SRC_GPS + \item 0x00000002 -- ALT_SRC_CELL_ID + \item 0x00000003 -- ALT_SRC_ENHANCED_CELL_ID + \item 0x00000004 -- ALT_SRC_WIFI + \item 0x00000005 -- ALT_SRC_TERRESTRIAL + \item 0x00000006 -- ALT_SRC_TERRESTRIAL_HYBRID + \item 0x00000007 -- ALT_SRC_ALTITUDE_DATABASE + \item 0x00000008 -- ALT_SRC_BAROMETRIC_ALTIMETER + \item 0x00000009 -- ALT_SRC_OTHER + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocAltSrcLinkageEnumT_v02 linkage; + /**< Specifies the dependency between the horizontal and + altitude position components. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SRC_LINKAGE_NOT_SPECIFIED + \item 0x00000001 -- SRC_LINKAGE_FULLY_INTERDEPENDENT + \item 0x00000002 -- SRC_LINKAGE_DEPENDS_ON_LAT_LONG + \item 0x00000003 -- SRC_LINKAGE_FULLY_INDEPENDENT + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocAltSrcUncertaintyCoverageEnumT_v02 coverage; + /**< Specifies the region of uncertainty. + + Valid values: \begin{itemize1} + \item 0x00000000 -- UNCERTAINTY_NOT_SPECIFIED + \item 0x00000001 -- UNCERTAINTY_POINT: Altitude uncertainty is valid + at the injected horizontal position coordinates + only. + \item 0x00000002 -- UNCERTAINTY_FULL: Altitude uncertainty applies to + the position of the device regardless of + horizontal position (within the horizontal + uncertainty region, if provided). + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocAltitudeSrcInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCPOSITIONSRCENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_POSITION_SRC_GNSS_V02 = 0, /**< Position source is GNSS. */ + eQMI_LOC_POSITION_SRC_CELLID_V02 = 1, /**< Position source is Cell ID. */ + eQMI_LOC_POSITION_SRC_ENH_CELLID_V02 = 2, /**< Position source is Enhanced Cell ID. */ + eQMI_LOC_POSITION_SRC_WIFI_V02 = 3, /**< Position source is WiFi. */ + eQMI_LOC_POSITION_SRC_TERRESTRIAL_V02 = 4, /**< Position source is Terrestrial. */ + eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID_V02 = 5, /**< Position source is GNSS Terrestrial Hybrid. */ + eQMI_LOC_POSITION_SRC_OTHER_V02 = 6, /**< Other sources. */ + QMILOCPOSITIONSRCENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocPositionSrcEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects a position to the location engine. */ +typedef struct { + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} + */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} + */ + + /* Optional */ + /* Circular Horizontal Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Horizontal Confidence */ + uint8_t horConfidence_valid; /**< Must be set to true if horConfidence is being passed */ + uint8_t horConfidence; + /**< Horizontal confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0 to 99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} + This field must be specified together with horizontal uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid. + \begin{itemize1} + \item Units: Meters \begin{itemize1} + \item Positive = height + \item Negative = depth + \vspace{-0.18in} \end{itemize1} \end{itemize1}*/ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty. This is mandatory if either altitudeWrtEllipsoid + or altitudeWrtMeanSeaLevel is specified.\n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical confidence, as defined by ETSI TS 101 109 (\hyperref[S4]{[S4]}). + \begin{itemize1} + \item Units: Percent (0-99) + \item 0 -- invalid value + \item 100 to 256 -- not used + \item If 100 is received, reinterpret to 99 + \end{itemize1} + This field must be specified together with the vertical uncertainty. + If not specified, the default value will be 50. */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Altitude Source Info */ + uint8_t altSourceInfo_valid; /**< Must be set to true if altSourceInfo is being passed */ + qmiLocAltitudeSrcInfoStructT_v02 altSourceInfo; + /**< \n Specifies information regarding the altitude source. */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. \n + - Units: Milliseconds (since Jan. 1, 1970) */ + + /* Optional */ + /* Position Age */ + uint8_t timestampAge_valid; /**< Must be set to true if timestampAge is being passed */ + int32_t timestampAge; + /**< Position age, which is an estimate of how long ago this fix was made. \n + - Units: Milliseconds */ + + /* Optional */ + /* Position Source */ + uint8_t positionSrc_valid; /**< Must be set to true if positionSrc is being passed */ + qmiLocPositionSrcEnumT_v02 positionSrc; + /**< Source from which this position was obtained. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_POSITION_SRC_GNSS + \item 0x00000001 -- eQMI_LOC_POSITION_SRC_CELLID + \item 0x00000002 -- eQMI_LOC_POSITION_SRC_ENH_CELLID + \item 0x00000003 -- eQMI_LOC_POSITION_SRC_WIFI + \item 0x00000004 -- eQMI_LOC_POSITION_SRC_TERRESTRIAL + \item 0x00000005 -- eQMI_LOC_POSITION_SRC_GNSS_TERRESTRIAL_HYBRID + \item 0x00000006 -- eQMI_LOC_POSITION_SRC_OTHER + \end{itemize1} \vspace{0.05in} + + If altitude is specified and the altitude source is not specified, the engine + assumes that the altitude was obtained using the specified position source. \n + If both altitude and altitude source are specified, the engine assumes + that only latitude and longitude were obtained using the specified position + source. + */ +}qmiLocInjectPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects a position to the location engine. */ +typedef struct { + + /* Mandatory */ + /* UTC Position Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the UTC Position Injection request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCLOCKENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_LOCK_NONE_V02 = 1, /**< Do not lock any position sessions. */ + eQMI_LOC_LOCK_MI_V02 = 2, /**< Lock mobile-initiated position sessions. */ + eQMI_LOC_LOCK_MT_V02 = 3, /**< Lock mobile-terminated position sessions. */ + eQMI_LOC_LOCK_ALL_V02 = 4, /**< Lock all position sessions. */ + QMILOCLOCKENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocLockEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Lock Type */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + + */ +}qmiLocSetEngineLockReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Set Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Engine Lock request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetEngineLockReqMsgT is empty + * typedef struct { + * }qmiLocGetEngineLockReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location engine lock. */ +typedef struct { + + /* Mandatory */ + /* Get Engine Lock Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Engine Lock request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Lock Type */ + uint8_t lockType_valid; /**< Must be set to true if lockType is being passed */ + qmiLocLockEnumT_v02 lockType; + /**< Type of lock. + + Valid values: \n + - 0x00000001 -- LOCK_NONE \n + - 0x00000002 -- LOCK_MI \n + - 0x00000003 -- LOCK_MT \n + - 0x00000004 -- LOCK_ALL + */ +}qmiLocGetEngineLockIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* SBAS Config */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocSetSbasConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the SBAS configuration. */ +typedef struct { + + /* Mandatory */ + /* Set SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set SBAS Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSbasConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSbasConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the SBAS configuration from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get SBAS Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get SBAS Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SBAS Config */ + uint8_t sbasConfig_valid; /**< Must be set to true if sbasConfig is being passed */ + uint8_t sbasConfig; + /**< Whether SBAS configuration is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SBAS configuration is enabled + \item 0x00 (FALSE) -- SBAS configuration is disabled + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocGetSbasConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocNmeaSentenceMaskT_v02; +#define QMI_LOC_NMEA_MASK_GGA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000001) /**< Enable GGA type. */ +#define QMI_LOC_NMEA_MASK_RMC_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000002) /**< Enable RMC type. */ +#define QMI_LOC_NMEA_MASK_GSV_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000004) /**< Enable GSV type. */ +#define QMI_LOC_NMEA_MASK_GSA_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000008) /**< Enable GSA type. */ +#define QMI_LOC_NMEA_MASK_VTG_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000010) /**< Enable VTG type. */ +#define QMI_LOC_NMEA_MASK_PQXFI_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000020) /**< Enable PQXFI type. */ +#define QMI_LOC_NMEA_MASK_PSTIS_V02 ((qmiLocNmeaSentenceMaskT_v02)0x00000040) /**< Enable PSTIS type. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* NMEA Sentence Types */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< Bitmasks of NMEA types to enable. + + Valid bitmasks: \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS + */ +}qmiLocSetNmeaTypesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the NMEA types. */ +typedef struct { + + /* Mandatory */ + /* Set NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of Set NMEA Types request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetNmeaTypesReqMsgT is empty + * typedef struct { + * }qmiLocGetNmeaTypesReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the NMEA types from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get NMEA Types Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NMEA Types request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* NMEA Sentence Types */ + uint8_t nmeaSentenceType_valid; /**< Must be set to true if nmeaSentenceType is being passed */ + qmiLocNmeaSentenceMaskT_v02 nmeaSentenceType; + /**< NMEA types to enable. + + Valid bitmasks: \n + - 0x0000ffff -- NMEA_MASK_ALL \n + - 0x00000001 -- NMEA_MASK_GGA \n + - 0x00000002 -- NMEA_MASK_RMC \n + - 0x00000004 -- NMEA_MASK_GSV \n + - 0x00000008 -- NMEA_MASK_GSA \n + - 0x00000010 -- NMEA_MASK_VTG \n + - 0x00000020 -- NMEA_MASK_PQXFI \n + - 0x00000040 -- NMEA_MASK_PSTIS + */ +}qmiLocGetNmeaTypesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Enable Low Power Mode */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocSetLowPowerModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables Low Power Mode (LPM) configuration. */ +typedef struct { + + /* Mandatory */ + /* Set LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Low Power Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetLowPowerModeReqMsgT is empty + * typedef struct { + * }qmiLocGetLowPowerModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the LPM status from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get LPM Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get LPM request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable LPM */ + uint8_t lowPowerMode_valid; /**< Must be set to true if lowPowerMode is being passed */ + uint8_t lowPowerMode; + /**< Whether to enable Low Power mode:\n + - 0x01 (TRUE) -- Enable LPM \n + - 0x00 (FALSE) -- Disable LPM */ +}qmiLocGetLowPowerModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERTYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_TYPE_CDMA_PDE_V02 = 1, /**< Server type is CDMA PDE. */ + eQMI_LOC_SERVER_TYPE_CDMA_MPC_V02 = 2, /**< Server type is CDMA MPC. */ + eQMI_LOC_SERVER_TYPE_UMTS_SLP_V02 = 3, /**< Server type is UMTS SLP. */ + eQMI_LOC_SERVER_TYPE_CUSTOM_PDE_V02 = 4, /**< Server type is custom PDE. */ + QMILOCSERVERTYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL address. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Specifies the A-GPS server type and address. */ +typedef struct { + + /* Mandatory */ + /* Set Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Server request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* Server Address Type */ + uint8_t serverAddrTypeMask_valid; /**< Must be set to true if serverAddrTypeMask is being passed */ + qmiLocServerAddrTypeMaskT_v02 serverAddrTypeMask; + /**< Type of address the client wants. If unspecified, the + indication will contain all the types of addresses + it has for the specified server type. + + Valid bitmasks: \n + - 0x01 -- IPV4 \n + - 0x02 -- IPV6 \n + - 0x04 -- URL + */ +}qmiLocGetServerReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the location server from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Server Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Server request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Mandatory */ + /* Server Type */ + qmiLocServerTypeEnumT_v02 serverType; + /**< Type of server, as defined in qmiLocServerTypeEnumT. + + Valid values: \n + - 0x00000001 -- CDMA_PDE \n + - 0x00000002 -- CDMA_MPC \n + - 0x00000003 -- UMTS_SLP \n + - 0x00000004 -- CUSTOM_PDE + */ + + /* Optional */ + /* IPV4 Address */ + uint8_t ipv4Addr_valid; /**< Must be set to true if ipv4Addr is being passed */ + qmiLocIpV4AddrStructType_v02 ipv4Addr; + /**< \n IPV4 address and port. */ + + /* Optional */ + /* IPV6 Address */ + uint8_t ipv6Addr_valid; /**< Must be set to true if ipv6Addr is being passed */ + qmiLocIpV6AddrStructType_v02 ipv6Addr; + /**< \n IPV6 address and port. */ + + /* Optional */ + /* Uniform Resource Locator */ + uint8_t urlAddr_valid; /**< Must be set to true if urlAddr is being passed */ + char urlAddr[QMI_LOC_MAX_SERVER_ADDR_LENGTH_V02 + 1]; + /**< URL. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 256 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetServerIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocDeleteGnssDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_GPS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000001ull) /**< Mask to delete GPS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GPS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000002ull) /**< Mask to delete GPS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GPS_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000004ull) /**< Mask to delete GPS time. */ +#define QMI_LOC_MASK_DELETE_GPS_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000008ull) /**< Mask to delete almanac correlation. */ +#define QMI_LOC_MASK_DELETE_GLO_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000010ull) /**< Mask to delete GLONASS SVDIR. */ +#define QMI_LOC_MASK_DELETE_GLO_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000020ull) /**< Mask to delete GLONASS SVSTEER. */ +#define QMI_LOC_MASK_DELETE_GLO_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000040ull) /**< Mask to delete GLONASS time. */ +#define QMI_LOC_MASK_DELETE_GLO_ALM_CORR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000080ull) /**< Mask to delete GLONASS almanac correlation */ +#define QMI_LOC_MASK_DELETE_SBAS_SVDIR_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000100ull) /**< Mask to delete SBAS SVDIR */ +#define QMI_LOC_MASK_DELETE_SBAS_SVSTEER_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000200ull) /**< Mask to delete SBAS SVSTEER */ +#define QMI_LOC_MASK_DELETE_POSITION_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000400ull) /**< Mask to delete position estimate */ +#define QMI_LOC_MASK_DELETE_TIME_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00000800ull) /**< Mask to delete time estimate */ +#define QMI_LOC_MASK_DELETE_IONO_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00001000ull) /**< Mask to delete IONO */ +#define QMI_LOC_MASK_DELETE_UTC_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00002000ull) /**< Mask to delete UTC estimate */ +#define QMI_LOC_MASK_DELETE_HEALTH_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00004000ull) /**< Mask to delete SV health record */ +#define QMI_LOC_MASK_DELETE_SADATA_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00008000ull) /**< Mask to delete SADATA */ +#define QMI_LOC_MASK_DELETE_RTI_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00010000ull) /**< Mask to delete RTI */ +#define QMI_LOC_MASK_DELETE_SV_NO_EXIST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00020000ull) /**< Mask to delete SV_NO_EXIST */ +#define QMI_LOC_MASK_DELETE_FREQ_BIAS_EST_V02 ((qmiLocDeleteGnssDataMaskT_v02)0x00040000ull) /**< Mask to delete frequency bias estimate */ +typedef uint32_t qmiLocDeleteCelldbDataMaskT_v02; +#define QMI_LOC_MASK_DELETE_CELLDB_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000001) /**< Mask to delete cell database position */ +#define QMI_LOC_MASK_DELETE_CELLDB_LATEST_GPS_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000002) /**< Mask to delete cell database latest GPS position */ +#define QMI_LOC_MASK_DELETE_CELLDB_OTA_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000004) /**< Mask to delete cell database OTA position */ +#define QMI_LOC_MASK_DELETE_CELLDB_EXT_REF_POS_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000008) /**< Mask to delete cell database external reference position */ +#define QMI_LOC_MASK_DELETE_CELLDB_TIMETAG_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000010) /**< Mask to delete cell database time tag */ +#define QMI_LOC_MASK_DELETE_CELLDB_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000020) /**< Mask to delete cell database cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_CACHED_CELLID_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000040) /**< Mask to delete cell database cached cell ID */ +#define QMI_LOC_MASK_DELETE_CELLDB_LAST_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000080) /**< Mask to delete cell database last service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_CUR_SRV_CELL_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000100) /**< Mask to delete cell database current service cell */ +#define QMI_LOC_MASK_DELETE_CELLDB_NEIGHBOR_INFO_V02 ((qmiLocDeleteCelldbDataMaskT_v02)0x00000200) /**< Mask to delete cell database neighbor information */ +typedef uint32_t qmiLocDeleteClockInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000001) /**< Mask to delete time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_FREQ_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000002) /**< Mask to delete frequency estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_WEEK_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000004) /**< Mask to delete week number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_RTC_TIME_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000008) /**< Mask to delete RTC time from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_TIME_TRANSFER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000010) /**< Mask to delete time transfer from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GPSTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000020) /**< Mask to delete GPS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLOTIME_EST_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000040) /**< Mask to delete GLONASS time estimate from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLODAY_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000080) /**< Mask to delete GLONASS day number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO4YEAR_NUMBER_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000100) /**< Mask to delete GLONASS four year number from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000200) /**< Mask to delete GLONASS RF GRP delay from clock information */ +#define QMI_LOC_MASK_DELETE_CLOCK_INFO_DISABLE_TT_V02 ((qmiLocDeleteClockInfoMaskT_v02)0x00000400) /**< Mask to delete disable TT from clock information */ +typedef uint8_t qmiLocDeleteSvInfoMaskT_v02; +#define QMI_LOC_MASK_DELETE_EPHEMERIS_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x01) /**< Delete ephemeris for the satellite */ +#define QMI_LOC_MASK_DELETE_ALMANAC_V02 ((qmiLocDeleteSvInfoMaskT_v02)0x02) /**< Delete almanac for the satellite */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t gnssSvId; + /**< SV ID of the satellite whose data is to be deleted. + \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + qmiLocSvSystemEnumT_v02 system; + /**< Indicates to which constellation this SV belongs. + + Valid values: \begin{itemize1} + \item 0x00000001 -- eQMI_LOC_SV_SYSTEM_GPS + \item 0x00000002 -- eQMI_LOC_SV_SYSTEM_GALILEO + \item 0x00000003 -- eQMI_LOC_SV_SYSTEM_SBAS + \item 0x00000004 -- eQMI_LOC_SV_SYSTEM_COMPASS + \item 0x00000005 -- eQMI_LOC_SV_SYSTEM_GLONASS + \vspace{-0.18in} \end{itemize1} + */ + + qmiLocDeleteSvInfoMaskT_v02 deleteSvInfoMask; + /**< Indicates if the ephemeris or almanac for a satellite + is to be deleted. \n + Valid values: \n + - 0x01 -- DELETE_EPHEMERIS \n + - 0x02 -- DELETE_ALMANAC + */ +}qmiLocDeleteSvInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete All */ + uint8_t deleteAllFlag; + /**< Whether all assistance data is to be deleted. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- All assistance data is to be deleted; if + this flag is set, all the other information + contained in the optional fields for this + message are ignored + \item 0x00 (FALSE) -- The optional fields in the message are to be + used to determine which data is to be deleted + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Delete SV Info */ + uint8_t deleteSvInfoList_valid; /**< Must be set to true if deleteSvInfoList is being passed */ + uint32_t deleteSvInfoList_len; /**< Must be set to # of elements in deleteSvInfoList */ + qmiLocDeleteSvInfoStructT_v02 deleteSvInfoList[QMI_LOC_DELETE_MAX_SV_INFO_LENGTH_V02]; + /**< \n List of satellites for which the assistance data is to be deleted. + */ + + /* Optional */ + /* Delete GNSS Data */ + uint8_t deleteGnssDataMask_valid; /**< Must be set to true if deleteGnssDataMask is being passed */ + qmiLocDeleteGnssDataMaskT_v02 deleteGnssDataMask; + /**< Mask for the GNSS data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_GPS_SVDIR + \item 0x00000002 -- DELETE_GPS_SVSTEER + \item 0x00000004 -- DELETE_GPS_TIME + \item 0x00000008 -- DELETE_GPS_ALM_CORR + \item 0x00000010 -- DELETE_GLO_SVDIR + \item 0x00000020 -- DELETE_GLO_SVSTEER + \item 0x00000040 -- DELETE_GLO_TIME + \item 0x00000080 -- DELETE_GLO_ALM_CORR + \item 0x00000100 -- DELETE_SBAS_SVDIR + \item 0x00000200 -- DELETE_SBAS_SVSTEER + \item 0x00000400 -- DELETE_POSITION + \item 0x00000800 -- DELETE_TIME + \item 0x00001000 -- DELETE_IONO + \item 0x00002000 -- DELETE_UTC + \item 0x00004000 -- DELETE_HEALTH + \item 0x00008000 -- DELETE_SADATA + \item 0x00010000 -- DELETE_RTI + \item 0x00020000 -- DELETE_SV_NO_EXIST + \item 0x00040000 -- DELETE_FREQ_BIAS_EST + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Delete Cell Database */ + uint8_t deleteCellDbDataMask_valid; /**< Must be set to true if deleteCellDbDataMask is being passed */ + qmiLocDeleteCelldbDataMaskT_v02 deleteCellDbDataMask; + /**< Mask for the cell database assistance data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_CELLDB_POS + \item 0x00000002 -- DELETE_CELLDB_LATEST_GPS_POS + \item 0x00000004 -- DELETE_CELLDB_OTA_POS + \item 0x00000008 -- DELETE_CELLDB_EXT_REF_POS + \item 0x00000010 -- DELETE_CELLDB_TIMETAG + \item 0x00000020 -- DELETE_CELLDB_CELLID + \item 0x00000040 -- DELETE_CELLDB_CACHED_CELLID + \item 0x00000080 -- DELETE_CELLDB_LAST_SRV_CELL + \item 0x00000100 -- DELETE_CELLDB_CUR_SRV_CELL + \item 0x00000200 -- DELETE_CELLDB_NEIGHBOR_INFO + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Delete Clock Info */ + uint8_t deleteClockInfoMask_valid; /**< Must be set to true if deleteClockInfoMask is being passed */ + qmiLocDeleteClockInfoMaskT_v02 deleteClockInfoMask; + /**< Mask for the clock information assistance data that is to be deleted. + + Valid values: \begin{itemize1} + \item 0x00000001 -- DELETE_CLOCK_INFO_TIME_EST + \item 0x00000002 -- DELETE_CLOCK_INFO_FREQ_EST + \item 0x00000004 -- DELETE_CLOCK_INFO_WEEK_NUMBER + \item 0x00000008 -- DELETE_CLOCK_INFO_RTC_TIME + \item 0x00000010 -- DELETE_CLOCK_INFO_TIME_TRANSFER + \item 0x00000020 -- DELETE_CLOCK_INFO_GPSTIME_EST + \item 0x00000040 -- DELETE_CLOCK_INFO_GLOTIME_EST + \item 0x00000080 -- DELETE_CLOCK_INFO_GLODAY_NUMBER + \item 0x00000100 -- DELETE_CLOCK_INFO_GLO4YEAR_NUMBER + \item 0x00000200 -- DELETE_CLOCK_INFO_GLO_RF_GRP_DELAY + \item 0x00000400 -- DELETE_CLOCK_INFO_DISABLE_TT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteAssistDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; This command is used to delete the location engine + assistance data */ +typedef struct { + + /* Mandatory */ + /* Delete Assist Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Assist Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteAssistDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Enable XTRA-T */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocSetXtraTSessionControlReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Enables/disables XTRA-T session control. */ +typedef struct { + + /* Mandatory */ + /* Set XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set XTRA-T Session Control request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetXtraTSessionControlReqMsgT is empty + * typedef struct { + * }qmiLocGetXtraTSessionControlReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the XTRA-T session control value from the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Get XTRA-T Session Control Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get XTRA-T Session Control request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Enable/Disable XTRA-T */ + uint8_t xtraTSessionControl_valid; /**< Must be set to true if xtraTSessionControl is being passed */ + uint8_t xtraTSessionControl; + /**< Whether to enable XTRA-T:\n + - 0x01 (TRUE) -- Enable XTRA-T \n + - 0x00 (FALSE) -- Disable XTRA-T */ +}qmiLocGetXtraTSessionControlIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t wifiPositionTime; + /**< Common counter (typically, the number of milliseconds since bootup). + This field is only to be provided if the modem and host processors are + synchronized. */ +}qmiLocWifiFixTimeStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFIFIXERRORCODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_FIX_ERROR_SUCCESS_V02 = 0, /**< WiFi fix is successful. */ + eQMI_LOC_WIFI_FIX_ERROR_WIFI_NOT_AVAILABLE_V02 = 1, /**< WiFi fix failed because WiFi is not available on the device. */ + eQMI_LOC_WIFI_FIX_ERROR_NO_AP_FOUND_V02 = 2, /**< WiFi fix failed because no access points were found. */ + eQMI_LOC_WIFI_FIX_ERROR_UNAUTHORIZED_V02 = 3, /**< WiFi fix failed because the server denied access due to bad authorization + code. */ + eQMI_LOC_WIFI_FIX_ERROR_SERVER_UNAVAILABLE_V02 = 4, /**< WiFi fix failed because the WiFi server was unavailable. */ + eQMI_LOC_WIFI_FIX_ERROR_LOCATION_CANNOT_BE_DETERMINED_V02 = 5, /**< WiFi fix failed even though APs were found and the server could be reached. + This may be because the APs found are not in the database. */ + eQMI_LOC_WIFI_FIX_ERROR_UNKNOWN_V02 = 6, /**< WiFi fix failed, but the cause could not be determined. */ + QMILOCWIFIFIXERRORCODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiFixErrorCodeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double lat; + /**< WiFi position latitude. \n + - Type: Floating point \n + - Units: Degrees */ + + double lon; + /**< WiFi position longitude. \n + - Type: Floating point \n + - Units: Degrees */ + + uint16_t hepe; + /**< WiFi position HEPE.\n + - Units: Meters */ + + uint8_t numApsUsed; + /**< Number of Access Points (AP) used to generate a fix. */ + + qmiLocWifiFixErrorCodeEnumT_v02 fixErrorCode; + /**< WiFi position error code; set to 0 if the fix succeeds. This position + is only used by a module if the value is 0. If there was a failure, + the error code provided by the WiFi positioning system can be provided + here. + + Valid values: \begin{itemize1} + \item 0x00000000 -- ERROR_SUCCESS + \item 0x00000001 -- ERROR_WIFI_NOT_AVAILABLE + \item 0x00000002 -- ERROR_NO_AP_FOUND + \item 0x00000003 -- ERROR_UNAUTHORIZED + \item 0x00000004 -- ERROR_SERVER_UNAVAILABLE + \item 0x00000005 -- ERROR_LOCATION_CANNOT_BE_DETERMINED + \item 0x00000006 -- ERROR_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocWifiFixPosStructT_v02; /* Type */ +/** + @} + */ + +typedef uint8_t qmiLocWifiApQualifierMaskT_v02; +#define QMI_LOC_WIFI_AP_QUALIFIER_BEING_USED_V02 ((qmiLocWifiApQualifierMaskT_v02)0x01) /**< Access point is being used by the WPS. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_HIDDEN_SSID_V02 ((qmiLocWifiApQualifierMaskT_v02)0x02) /**< AP does not broadcast SSID. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_PRIVATE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x04) /**< AP has encryption turned on. */ +#define QMI_LOC_WIFI_AP_QUALIFIER_INFRASTRUCTURE_MODE_V02 ((qmiLocWifiApQualifierMaskT_v02)0x08) /**< AP is in infrastructure mode and not in ad-hoc/unknown mode. */ +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint8_t macAddr[QMI_LOC_WIFI_MAC_ADDR_LENGTH_V02]; + /**< Associated MAC address of the AP. \n + - Type: Array of unsigned integers \n + - Address length: 6 + */ + + int32_t rssi; + /**< Receive signal strength indicator.\n + - Units: dBm (offset with +100 dB) */ + + uint16_t channel; + /**< WiFi channel on which a beacon was received. */ + + qmiLocWifiApQualifierMaskT_v02 apQualifier; + /**< A bitmask of Boolean qualifiers for APs. + All unused bits in this mask must be set to 0. + + Valid values: \n + - 0x01 -- BEING_USED \n + - 0x02 -- HIDDEN_SSID \n + - 0x04 -- PRIVATE \n + - 0x08 -- INFRASTRUCTURE_MODE + */ +}qmiLocWifiApInfoStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects the WiFi position. */ +typedef struct { + + /* Optional */ + /* WiFi Fix Time */ + uint8_t wifiFixTime_valid; /**< Must be set to true if wifiFixTime is being passed */ + qmiLocWifiFixTimeStructT_v02 wifiFixTime; + /**< \n Time of WiFi position fix. */ + + /* Optional */ + /* WiFi Position */ + uint8_t wifiFixPosition_valid; /**< Must be set to true if wifiFixPosition is being passed */ + qmiLocWifiFixPosStructT_v02 wifiFixPosition; + /**< \n WiFi position fix. */ + + /* Optional */ + /* WiFi Access Point Information */ + uint8_t apInfo_valid; /**< Must be set to true if apInfo is being passed */ + uint32_t apInfo_len; /**< Must be set to # of elements in apInfo */ + qmiLocWifiApInfoStructT_v02 apInfo[QMI_LOC_WIFI_MAX_REPORTED_APS_PER_MSG_V02]; + /**< \n AP scan list. */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horizontalReliability_valid; /**< Must be set to true if horizontalReliability is being passed */ + qmiLocReliabilityEnumT_v02 horizontalReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- eQMI_LOC_RELIABILITY_NOT_SET + \item 0x00000001 -- eQMI_LOC_RELIABILITY_VERY_LOW + \item 0x00000002 -- eQMI_LOC_RELIABILITY_LOW + \item 0x00000003 -- eQMI_LOC_RELIABILITY_MEDIUM + \item 0x00000004 -- eQMI_LOC_RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectWifiPositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects the WiFi position. */ +typedef struct { + + /* Mandatory */ + /* Inject WiFi Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject WiFi Position request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectWifiPositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCWIFISTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_WIFI_STATUS_AVAILABLE_V02 = 1, /**< WiFi is available. */ + eQMI_LOC_WIFI_STATUS_UNAVAILABLE_V02 = 2, /**< WiFi is not available. */ + QMILOCWIFISTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocWifiStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Availablility of WiFi */ + qmiLocWifiStatusEnumT_v02 wifiStatus; + /**< WiFi status information. + + Valid values: \begin{itemize1} + \item 0x00000001 -- WIFI_STATUS_AVAILABLE + \item 0x00000002 -- WIFI_STATUS_UNAVAILABLE + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNotifyWifiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Notifies the location engine of the WiFi status. */ +typedef struct { + + /* Mandatory */ + /* Status of Notify WiFi Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WiFi Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocNotifyWifiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetRegisteredEventsReqMsgT is empty + * typedef struct { + * }qmiLocGetRegisteredEventsReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the mask of the events for which a client has + registered. */ +typedef struct { + + /* Mandatory */ + /* Get Registered Events Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Registered Events request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Event Registration Mask */ + uint8_t eventRegMask_valid; /**< Must be set to true if eventRegMask is being passed */ + qmiLocEventRegMaskT_v02 eventRegMask; + /**< Event registration mask. + Valid bitmasks: \n + - QMI_LOC_EVENT_MASK_POSITION_REPORT (0x00000001) -- The control point must enable this mask to receive position report + event indications. + - QMI_LOC_EVENT_MASK_GNSS_SV_INFO (0x00000002) -- The control point must enable this mask to receive satellite report + event indications. These reports are sent at a 1 Hz rate. + - QMI_LOC_EVENT_MASK_NMEA (0x00000004) -- The control point must enable this mask to receive NMEA reports for + position and satellites in view. The report is at a 1 Hz rate. + - QMI_LOC_EVENT_MASK_NI_NOTIFY_VERIFY_REQ (0x00000008) -- The control point must enable this mask to receive NI notify verify request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_TIME_REQ (0x00000010) -- The control point must enable this mask to receive time injection request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_PREDICTED_ORBITS_REQ (0x00000020) -- The control point must enable this mask to receive predicted orbits request + event indications. + - QMI_LOC_EVENT_MASK_INJECT_POSITION_REQ (0x00000040) -- The control point must enable this mask to receive position injection request + event indications. + - QMI_LOC_EVENT_MASK_ENGINE_STATE (0x00000080) -- The control point must enable this mask to receive engine state report + event indications. + - QMI_LOC_EVENT_MASK_FIX_SESSION_STATE (0x00000100) -- The control point must enable this mask to receive fix session status report + event indications. + - QMI_LOC_EVENT_MASK_WIFI_REQ (0x00000200) -- The control point must enable this mask to receive WiFi position request + event indications. + - QMI_LOC_EVENT_MASK_SENSOR_STREAMING_READY_STATUS (0x00000400) -- The control point must enable this mask to receive notifications from the + GPS engine indicating its readiness to accept data from the + sensors (accelerometer, gyroscope, etc.). + - QMI_LOC_EVENT_MASK_TIME_SYNC_REQ (0x00000800) -- The control point must enable this mask to receive time-sync requests + from the GPS engine. Time sync enables the GPS engine to synchronize + its clock with the sensor processor's clock. + - QMI_LOC_EVENT_MASK_SET_SPI_STREAMING_REPORT (0x00001000) -- The control point must enable this mask to receive Stationary Position + Indicator (SPI) streaming report indications. + - QMI_LOC_EVENT_MASK_LOCATION_SERVER_CONNECTION_REQ (0x00002000) -- The control point must enable this mask to receive location server + requests. These requests are generated when the service wishes to + establish a connection with a location server. + - QMI_LOC_EVENT_MASK_NI_GEOFENCE_NOTIFICATION (0x00004000) -- The control point must enable this mask to receive notifications + related to network-initiated Geofences. These events notify the client + when a network-initiated Geofence is added, deleted, or edited. + - QMI_LOC_EVENT_MASK_GEOFENCE_GEN_ALERT (0x00008000) -- The control point must enable this mask to receive Geofence alerts. + These alerts are generated to inform the client of the changes that may + affect Geofence, e.g., if GPS is turned off or if the network is + unavailable. + - QMI_LOC_EVENT_MASK_GEOFENCE_BREACH_NOTIFICATION (0x00010000) -- The control point must enable this mask to receive notifications when + a Geofence is breached. These events are generated when the UE enters + or leaves the perimeter of a Geofence. + - QMI_LOC_EVENT_MASK_PEDOMETER_CONTROL (0x00020000) -- The control point must enable this mask to register for Pedometer + control requests from the location engine. Location engine sends + this event out to control the injection of pedometer reports. + - QMI_LOC_EVENT_MASK_MOTION_DATA_CONTROL (0x00040000) -- The control point must enable this mask to register for motion data + control requests from the location engine. Location engine sends + this event out to control the injection of motion data. + */ +}qmiLocGetRegisteredEventsIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCOPERATIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_OPER_MODE_DEFAULT_V02 = 1, /**< Use the default engine mode. */ + eQMI_LOC_OPER_MODE_MSB_V02 = 2, /**< Use the MS-based mode. */ + eQMI_LOC_OPER_MODE_MSA_V02 = 3, /**< Use the MS-assisted mode. */ + eQMI_LOC_OPER_MODE_STANDALONE_V02 = 4, /**< Use Standalone mode. */ + eQMI_LOC_OPER_MODE_CELL_ID_V02 = 5, /**< Use cell ID. This mode is valid only for a GSM/UMTS network. */ + eQMI_LOC_OPER_MODE_WWAN_V02 = 6, /**< Use WWAN measurements to calculate the position. If this mode is + set, AFLT will be used for 1x networks and OTDOA will be used + for LTE networks. */ + QMILOCOPERATIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocOperationModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Operation Mode */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Preferred operation mode. + \label{operationMode} + + Valid values: \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetOperationModeReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Tells the engine to use the specified operation mode while + making the position fixes. This command is not to be used + by multiple clients concurrently. */ +typedef struct { + + /* Mandatory */ + /* Set Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Operation Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetOperationModeReqMsgT is empty + * typedef struct { + * }qmiLocGetOperationModeReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Gets the current operation mode from the engine. */ +typedef struct { + + /* Mandatory */ + /* Get Operation Mode Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Operation Mode request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Operation Mode */ + uint8_t operationMode_valid; /**< Must be set to true if operationMode is being passed */ + qmiLocOperationModeEnumT_v02 operationMode; + /**< Current operation mode. + + Valid values: \begin{itemize1} + \item 0x00000001 -- OPER_MODE_DEFAULT + \item 0x00000002 -- OPER_MODE_MSB + \item 0x00000003 -- OPER_MODE_MSA + \item 0x00000004 -- OPER_MODE_STANDALONE + \item 0x00000005 -- OPER_MODE_CELL_ID + \item 0x00000006 -- OPER_MODE_WWAN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetOperationModeIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Stationary Status */ + uint8_t stationary; + /**< Whether the device is stationary: + \begin{itemize1} + \item 0x00 (FALSE) -- Device is not stationary + \item 0x01 (TRUE) -- Device is stationary + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Confidence */ + uint8_t confidenceStationary_valid; /**< Must be set to true if confidenceStationary is being passed */ + uint8_t confidenceStationary; + /**< Confidence in the Stationary state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocSetSpiStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the SPI status, which + indicates whether the device is stationary. */ +typedef struct { + + /* Mandatory */ + /* Status of SPI Status Request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the SPI Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSpiStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint8_t qmiLocSensorDataFlagMaskT_v02; +#define QMI_LOC_SENSOR_DATA_FLAG_SIGN_REVERSAL_V02 ((qmiLocSensorDataFlagMaskT_v02)0x01) /**< Bitmask to specify that a sign reversal is required while interpreting + the sensor data. Only applies to the accelerometer samples. */ +#define QMI_LOC_SENSOR_DATA_FLAG_SENSOR_TIME_IS_MODEM_TIME_V02 ((qmiLocSensorDataFlagMaskT_v02)0x02) /**< Bitmask to specify that the sensor time stamp is the same as the modem + time stamp. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORDATATIMESOURCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_TIME_SOURCE_UNSPECIFIED_V02 = 0, /**< The sensor time source is unspecified */ + eQMI_LOC_SENSOR_TIME_SOURCE_COMMON_V02 = 1, /**< The time source is common between the sensors and + the location engine */ + QMILOCSENSORDATATIMESOURCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorDataTimeSourceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t timeOffset; + /**< Sample time offset. This time offset must be + relative to the timestamp of the first sensor data sample.\n + - Units: Milliseconds */ + + float xAxis; + /**< Sensor x-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ + + float yAxis; + /**< Sensor y-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ + + float zAxis; + /**< Sensor z-axis sample. \n + - Units Accelerometer: ( (meters)/(seconds^2) ) \n + - Units Gyroscope: ( (rads)/(seconds) ) */ +}qmiLoc3AxisSensorSampleStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t timeOfFirstSample; + /**< Denotes a full 32-bit timestamp of the first (oldest) sample in this + message.The timestamp is in the time reference scale that is + used by the sensor time source.\n + - Units: Milliseconds */ + + qmiLocSensorDataFlagMaskT_v02 flags; + /**< Flags to indicate any deviation from the default measurement + assumptions. All unused bits in this field must be set to 0. + + Valid bitmasks: \begin{itemize1} + \item 0x01 -- SIGN_REVERSAL + \item 0X02 -- SENSOR_TIME_IS_MODEM_TIME + \vspace{-0.18in} \end{itemize1} */ + + uint32_t sensorData_len; /**< Must be set to # of elements in sensorData */ + qmiLoc3AxisSensorSampleStructT_v02 sensorData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; + /**< Variable length array to specify sensor samples. \n + - Maximum length of the array: 50 */ +}qmiLoc3AxisSensorSampleListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint16_t timeOffset; + /**< Sample time offset. This time offset must be + relative to the timestamp of the first sensor sample.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + float temperature; + /**< Sensor temperature. \n + - Type: Floating point \n + - Units: Degree Celsius \n + - Range: -50 to +100.00 Degree Celsius */ +}qmiLocSensorTemperatureSampleStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocSensorDataTimeSourceEnumT_v02 timeSource; + /**< Denotes the time source of the sensor data. Location service will use + this field to identify the time reference used in the + sensor data timestamps. Values :\n + - eQMI_LOC_SENSOR_TIME_SOURCE_UNSPECIFIED (0) -- The sensor time source is unspecified + - eQMI_LOC_SENSOR_TIME_SOURCE_COMMON (1) -- The time source is common between the sensors and + the location engine + */ + + uint32_t timeOfFirstSample; + /**< Denotes a full 32-bit timestamp of the first (oldest) sample in this + message. The timestamp is in the time reference scale that is + used by the sensor time source.\n + - Type: Unsigned integer \n + - Units: Milliseconds */ + + uint32_t temperatureData_len; /**< Must be set to # of elements in temperatureData */ + qmiLocSensorTemperatureSampleStructT_v02 temperatureData[QMI_LOC_SENSOR_DATA_MAX_SAMPLES_V02]; + /**< Variable length array to specify sensor temperature samples. \n + - Maximum length of the array: 50 */ +}qmiLocSensorTemperatureSampleListStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< An opaque identifier that is sent in by the client that will be echoed + in the indication so the client can relate the indication to the + request. */ + + /* Optional */ + /* 3-Axis Accelerometer Data */ + uint8_t threeAxisAccelData_valid; /**< Must be set to true if threeAxisAccelData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisAccelData; + /**< \n Accelerometer sensor samples. */ + + /* Optional */ + /* 3-Axis Gyroscope Data */ + uint8_t threeAxisGyroData_valid; /**< Must be set to true if threeAxisGyroData is being passed */ + qmiLoc3AxisSensorSampleListStructT_v02 threeAxisGyroData; + /**< \n Gyroscope sensor samples. */ + + /* Optional */ + /* 3-Axis Accelerometer Data Time Source */ + uint8_t threeAxisAccelDataTimeSource_valid; /**< Must be set to true if threeAxisAccelDataTimeSource is being passed */ + qmiLocSensorDataTimeSourceEnumT_v02 threeAxisAccelDataTimeSource; + /**< Time source for the 3-axis accelerometer data. Location service will use + this field to identify the time reference used in the accelerometer data + timestamps. If not specified the location service will assume that the + time source for the accelereometer data is unknown. Values: \n + - eQMI_LOC_SENSOR_TIME_SOURCE_UNSPECIFIED (0) -- The sensor time source is unspecified + - eQMI_LOC_SENSOR_TIME_SOURCE_COMMON (1) -- The time source is common between the sensors and + the location engine + */ + + /* Optional */ + /* 3-Axis Gyroscope Data Time Source */ + uint8_t threeAxisGyroDataTimeSource_valid; /**< Must be set to true if threeAxisGyroDataTimeSource is being passed */ + qmiLocSensorDataTimeSourceEnumT_v02 threeAxisGyroDataTimeSource; + /**< Time source for the 3-axis gyroscope data. Location service will use + this field to identify the time reference used in the gyroscope data + timestamps.If not specified the locations ervice will assume that the + time source for the gyroscope data is unknown. Values: \n + - eQMI_LOC_SENSOR_TIME_SOURCE_UNSPECIFIED (0) -- The sensor time source is unspecified + - eQMI_LOC_SENSOR_TIME_SOURCE_COMMON (1) -- The time source is common between the sensors and + the location engine + */ + + /* Optional */ + /* Accelerometer Temperature Data */ + uint8_t accelTemperatureData_valid; /**< Must be set to true if accelTemperatureData is being passed */ + qmiLocSensorTemperatureSampleListStructT_v02 accelTemperatureData; + /**< Accelerometer temperature samples. This data is optional and does not + have to be included in the message along with accelerometer data. */ + + /* Optional */ + /* Gyroscope Temperature Data */ + uint8_t gyroTemperatureData_valid; /**< Must be set to true if gyroTemperatureData is being passed */ + qmiLocSensorTemperatureSampleListStructT_v02 gyroTemperatureData; + /**< Gyroscope temperature samples. This data is optional and does not + have to be included in the message along with gyroscope data. */ +}qmiLocInjectSensorDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject sensor data into the + GNSS location engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Sensor Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Sensor Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Opaque Identifier */ + uint8_t opaqueIdentifier_valid; /**< Must be set to true if opaqueIdentifier is being passed */ + uint32_t opaqueIdentifier; + /**< Opaque identifier that was sent in by the client echoed + so the client can relate the indication to the request. */ + + /* Optional */ + /* Accelerometer Samples Accepted */ + uint8_t threeAxisAccelSamplesAccepted_valid; /**< Must be set to true if threeAxisAccelSamplesAccepted is being passed */ + uint8_t threeAxisAccelSamplesAccepted; + /**< Lets the client know how many 3-axis accelerometer samples + were accepted. This field is present only if the accelerometer + samples were sent in the request. */ + + /* Optional */ + /* Gyroscope Samples Accepted */ + uint8_t threeAxisGyroSamplesAccepted_valid; /**< Must be set to true if threeAxisGyroSamplesAccepted is being passed */ + uint8_t threeAxisGyroSamplesAccepted; + /**< Lets the client know how many 3-axis gyroscope samples were + accepted. This field is present only if the gyroscope + samples were sent in the request. */ + + /* Optional */ + /* Accelerometer Samples Accepted */ + uint8_t accelTemperatureSamplesAccepted_valid; /**< Must be set to true if accelTemperatureSamplesAccepted is being passed */ + uint8_t accelTemperatureSamplesAccepted; + /**< This field lets the client know how many accelerometer temperature + samples were accepted. This field is present only if the accelerometer + temperature samples were sent in the request. */ + + /* Optional */ + /* Gyroscope Temperature Samples Accepted */ + uint8_t gyroTemperatureSamplesAccepted_valid; /**< Must be set to true if gyroTemperatureSamplesAccepted is being passed */ + uint8_t gyroTemperatureSamplesAccepted; + /**< This field lets the client know how many gyroscope temperature samples + were accepted. This field is present only if the gyroscope + temperature samples were sent in the request. */ +}qmiLocInjectSensorDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Reference Time Sync Counter */ + uint32_t refCounter; + /**< Must be set to the value that was sent to the control point when the + GNSS location engine requested time sync injection. */ + + /* Mandatory */ + /* Sensor Receive Time */ + uint32_t sensorProcRxTime; + /**< Value of the sensor time when the control point received the + Time Sync Inject request from the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Units: Milliseconds */ + + /* Mandatory */ + /* Sensor Transmit Time */ + uint32_t sensorProcTxTime; + /**< Value of the sensor time when the control point injects this message + for use by the GNSS location engine. + + Must be monotonically increasing, jitter @latexonly $\leq$ @endlatexonly 1 + millisecond, never stopping until the process is rebooted.\n + - Units: Milliseconds */ +}qmiLocInjectTimeSyncDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject time sync data. */ +typedef struct { + + /* Mandatory */ + /* Inject Time Sync Data Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Time Sync Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectTimeSyncDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCCRADLEMOUNTSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_CRADLE_STATE_NOT_MOUNTED_V02 = 0, /**< Device is mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_MOUNTED_V02 = 1, /**< Device is not mounted on the cradle */ + eQMI_LOC_CRADLE_STATE_UNKNOWN_V02 = 2, /**< Unknown cradle mount state */ + QMILOCCRADLEMOUNTSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocCradleMountStateEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetCradleMountConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetCradleMountConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Cradle Mount Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Cradle Mount State */ + uint8_t cradleMountState_valid; /**< Must be set to true if cradleMountState is being passed */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence of the Cradle Mount state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocGetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Cradle Mount State */ + qmiLocCradleMountStateEnumT_v02 cradleMountState; + /**< Cradle Mount state set by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- CRADLE_STATE_NOT_MOUNTED + \item 0x00000001 -- CRADLE_STATE_MOUNTED + \item 0x00000002 -- CRADLE_STATE_UNKNOWN + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Cradle Mount Confidence */ + uint8_t confidenceCradleMountState_valid; /**< Must be set to true if confidenceCradleMountState is being passed */ + uint8_t confidenceCradleMountState; + /**< Confidence in the Cradle Mount state expressed as a percentage.\n + - Range: 0 to 100 */ +}qmiLocSetCradleMountConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + cradle mount configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Cradle Mount Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Cradle Mount Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetCradleMountConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCEXTERNALPOWERCONFIGENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_EXTERNAL_POWER_NOT_CONNECTED_V02 = 0, /**< Device is not connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_CONNECTED_V02 = 1, /**< Device is connected to an external power source. */ + eQMI_LOC_EXTERNAL_POWER_UNKNOWN_V02 = 2, /**< Unknown external power state. */ + QMILOCEXTERNALPOWERCONFIGENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocExternalPowerConfigEnumT_v02; +/** + @} + */ + +/* + * qmiLocGetExternalPowerConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetExternalPowerConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get External Power Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* External Power State */ + uint8_t externalPowerState_valid; /**< Must be set to true if externalPowerState is being passed */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* External Power State */ + qmiLocExternalPowerConfigEnumT_v02 externalPowerState; + /**< Power state; injected by the control point. + + Valid values: \begin{itemize1} + \item 0x00000000 -- EXTERNAL_POWER_NOT_CONNECTED + \item 0x00000001 -- EXTERNAL_POWER_CONNECTED + \item 0x00000002 -- EXTERNAL_POWER_UNKNOWN + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetExternalPowerConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to set the current + external power configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Ext Power Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set External Power Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetExternalPowerConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERPDNENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4_V02 = 0x01, /**< IPV4 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV6_V02 = 0x02, /**< IPV6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_IPV4V6_V02 = 0x03, /**< IPV4V6 PDN type. */ + eQMI_LOC_APN_PROFILE_PDN_TYPE_PPP_V02 = 0x04, /**< PPP PDN type. */ + QMILOCSERVERPDNENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerPDNEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocServerPDNEnumT_v02 pdnType; + /**< PDN type of the APN profile. + + Valid values: \n + - 0x00000001 -- PDN_TYPE_IPV4 \n + - 0x00000002 -- PDN_TYPE_IPV6 \n + - 0x00000003 -- PDN_TYPE_IPV4V6 \n + - 0x00000004 -- PDN_TYPE_PPP + */ + + char apnName[QMI_LOC_MAX_APN_NAME_LENGTH_V02 + 1]; + /**< APN name. + \begin{itemize1} + \item Type: NULL-terminated string + \item Maximum string length (including NULL terminator): 101 + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocApnProfilesStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSERVERREQSTATUSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SERVER_REQ_STATUS_SUCCESS_V02 = 1, /**< Location server request was successful. */ + eQMI_LOC_SERVER_REQ_STATUS_FAILURE_V02 = 2, /**< Location server request failed. */ + QMILOCSERVERREQSTATUSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocServerReqStatusEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Connection Handle */ + uint32_t connHandle; + /**< Connection handle that the service specified in the + Location Server Connection request event. */ + + /* Mandatory */ + /* Request Type */ + qmiLocServerRequestEnumT_v02 requestType; + /**< Type of connection request service that was specified in the + Location Server Connection Request event. + + Valid values: \n + - 0x00000001 -- OPEN \n + - 0x00000002 -- CLOSE + */ + + /* Mandatory */ + /* Connection Status */ + qmiLocServerReqStatusEnumT_v02 statusType; + /**< Status of the Connection request. + + Valid values: \n + - 0x00000001 -- STATUS_SUCCESS = 1 \n + - 0x00000002 -- STATUS_FAILURE = 2 + + */ + + /* Optional */ + /* APN Profile */ + uint8_t apnProfile_valid; /**< Must be set to true if apnProfile is being passed */ + qmiLocApnProfilesStructT_v02 apnProfile; + /**< \n Access Point Name (APN) profile information is present only when + requestType is OPEN and statusType is SUCCESS. */ +}qmiLocInformLocationServerConnStatusReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inform the service about the + status of the location server connection request that the + service may have sent via the + QMI_LOC_EVENT_LOCATION_SERVER_REQ_IND event. */ +typedef struct { + + /* Mandatory */ + /* Status of Inform Loc Server Conn Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inform Location Server Connection Status request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInformLocationServerConnStatusIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCVXVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_VX_VERSION_V1_ONLY_V02 = 1, /**< V1 VX version. */ + eQMI_LOC_VX_VERSION_V2_ONLY_V02 = 2, /**< V2 VX version. */ + QMILOCVXVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocVxVersionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSUPLVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_VERSION_1_0_V02 = 1, /**< SUPL version 1.0. */ + eQMI_LOC_SUPL_VERSION_2_0_V02 = 2, /**< SUPL version 2.0. */ + QMILOCSUPLVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSuplVersionEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocLppConfigMaskT_v02; +#define QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000001) /**< Enable user plane configuration for LTE Positioning Profile (LPP). */ +#define QMI_LOC_LPP_CONFIG_ENABLE_CONTROL_PLANE_V02 ((qmiLocLppConfigMaskT_v02)0x00000002) /**< Enable control plane configuration for LPP. */ +typedef uint32_t qmiLocAssistedGlonassProtocolMaskT_v02; +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000001) /**< Assisted GLONASS is supported over RRC in the control plane. */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000002) /**< Assisted GLONASS is supported over RRLP in the user plane. */ +#define QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_LPP_UP_V02 ((qmiLocAssistedGlonassProtocolMaskT_v02)0x00000004) /**< Assisted GLONASS is supported over LPP in the user plane. + The QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE should be set + in the LPP configuration for this to take effect. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSUPLHASHALGOENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_HASH_ALGO_SHA1_V02 = 0, /**< SHA1 Hash Algorithm for SUPL Version 2.0 or higher */ + eQMI_LOC_SUPL_HASH_ALGO_SHA256_V02 = 1, /**< SHA-256 Hash Algorithm for SUPL Version 2.0 or higher */ + QMILOCSUPLHASHALGOENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSuplHashAlgoEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSUPLTLSVERSIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SUPL_TLS_VERSION_1_0_V02 = 0, /**< SUPL TLS Version 1.0 */ + eQMI_LOC_SUPL_TLS_VERSION_1_1_V02 = 1, /**< SUPL TLS Version 1.1 */ + QMILOCSUPLTLSVERSIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSuplTlsVersionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCEMERGENCYPROTOCOLENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_CP_V02 = 0, /**< use Control plane protocol during emergency while on WCDMA */ + eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_UP_V02 = 1, /**< use SUPL 2.0 emergency services during emergency while on WCDMA */ + QMILOCEMERGENCYPROTOCOLENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocEmergencyProtocolEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Configures the protocols that the location service supports + for assisted GLONASS. + + Valid bitmasks: \n + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP (0x00000001) -- Assisted GLONASS is supported over RRC in the control plane. + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP (0x00000002) -- Assisted GLONASS is supported over RRLP in the user plane. + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_LPP_UP (0x00000004) -- Assisted GLONASS is supported over LPP in the user plane. + The QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE should be set + in the LPP configuration for this to take effect. + */ + + /* Optional */ + /* SUPL Hash Algorithm */ + uint8_t suplHashAlgo_valid; /**< Must be set to true if suplHashAlgo is being passed */ + qmiLocSuplHashAlgoEnumT_v02 suplHashAlgo; + /**< SUPL Hash Algorithm that needs to be used. Values: \n + - eQMI_LOC_SUPL_HASH_ALGO_SHA1 (0) -- SHA1 Hash Algorithm for SUPL Version 2.0 or higher + - eQMI_LOC_SUPL_HASH_ALGO_SHA256 (1) -- SHA-256 Hash Algorithm for SUPL Version 2.0 or higher + */ + + /* Optional */ + /* SUPL TLS Version */ + uint8_t suplTlsVersion_valid; /**< Must be set to true if suplTlsVersion is being passed */ + qmiLocSuplTlsVersionEnumT_v02 suplTlsVersion; + /**< SUPL TLS (Transport Layer Security) Version. This configuration is only + applicable to SUPL 2.0 or higher as SUPL 1.0 always uses TLS version 1.0. + Values: \n + - eQMI_LOC_SUPL_TLS_VERSION_1_0 (0) -- SUPL TLS Version 1.0 + - eQMI_LOC_SUPL_TLS_VERSION_1_1 (1) -- SUPL TLS Version 1.1 + */ + + /* Optional */ + /* Emergency Protocol */ + uint8_t emergencyProtocol_valid; /**< Must be set to true if emergencyProtocol is being passed */ + qmiLocEmergencyProtocolEnumT_v02 emergencyProtocol; + /**< Configures the protocol to be used during emergency. + Note: Currently only can select on WCDMA. FOR GSM and 1x UE + will always allow only Control plane NI trigger for positioning. + For LTE, UE Can allow either SUPL or Control plane NI trigger. + Values: \n + - eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_CP (0) -- use Control plane protocol during emergency while on WCDMA + - eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_UP (1) -- use SUPL 2.0 emergency services during emergency while on WCDMA + */ +}qmiLocSetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint64_t qmiLocProtocolConfigParamMaskT_v02; +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000001ull) /**< Mask for the SUPL security configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000002ull) /**< Mask for the VX version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000004ull) /**< Mask for the SUPL version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000008ull) /**< Mask for the LPP configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000010ull) /**< Mask for the assisted glonass configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_HASH_ALGO_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000020ull) /**< Mask for the SUPL Hash algorithm configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_TLS_VERSION_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000040ull) /**< Mask for the SUPL TLS version configuration parameter. */ +#define QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_EMERGENCY_PROTOCOL_V02 ((qmiLocProtocolConfigParamMaskT_v02)0x0000000000000080ull) /**< Mask for the emergency protocol configuration parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure parameters stored + in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Set Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedProtocolConfigParamMask_valid; /**< Must be set to true if failedProtocolConfigParamMask is being passed */ + qmiLocProtocolConfigParamMaskT_v02 failedProtocolConfigParamMask; + /**< Identifies parameters that were not set successfully. This field + is sent only if the status is not a success. + + Valid bitmasks: \n + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY (0x0000000000000001) -- Mask for the SUPL security configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION (0x0000000000000002) -- Mask for the VX version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION (0x0000000000000004) -- Mask for the SUPL version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG (0x0000000000000008) -- Mask for the LPP configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL (0x0000000000000010) -- Mask for the assisted glonass configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_HASH_ALGO (0x0000000000000020) -- Mask for the SUPL Hash algorithm configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_TLS_VERSION (0x0000000000000040) -- Mask for the SUPL TLS version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_EMERGENCY_PROTOCOL (0x0000000000000080) -- Mask for the emergency protocol configuration parameter. + */ +}qmiLocSetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocProtocolConfigParamMaskT_v02 getProtocolConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + + Valid bitmasks: \n + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_SECURITY (0x0000000000000001) -- Mask for the SUPL security configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_VX_VERSION (0x0000000000000002) -- Mask for the VX version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_VERSION (0x0000000000000004) -- Mask for the SUPL version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_LPP_CONFIG (0x0000000000000008) -- Mask for the LPP configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_ASSISTED_GLONASS_PROTOCOL (0x0000000000000010) -- Mask for the assisted glonass configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_HASH_ALGO (0x0000000000000020) -- Mask for the SUPL Hash algorithm configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_SUPL_TLS_VERSION (0x0000000000000040) -- Mask for the SUPL TLS version configuration parameter. + - QMI_LOC_PROTOCOL_CONFIG_PARAM_MASK_EMERGENCY_PROTOCOL (0x0000000000000080) -- Mask for the emergency protocol configuration parameter. + */ +}qmiLocGetProtocolConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the configuration + parameters stored in the nonvolatile memory. */ +typedef struct { + + /* Mandatory */ + /* Get Config Params Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Security */ + uint8_t suplSecurity_valid; /**< Must be set to true if suplSecurity is being passed */ + uint8_t suplSecurity; + /**< Indicates whether SUPL security is enabled. + \begin{itemize1} + \item 0x01 (TRUE) -- SUPL security is enabled + \item 0x00 (FALSE) -- SUPL security is disabled + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* VX Version */ + uint8_t vxVersion_valid; /**< Must be set to true if vxVersion is being passed */ + qmiLocVxVersionEnumT_v02 vxVersion; + /**< VX version. + + Valid values: \begin{itemize1} + \item 0x00000001 -- VX_VERSION_V1_ONLY + \item 0x00000002 -- VX_VERSION_V2_ONLY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* SUPL Version */ + uint8_t suplVersion_valid; /**< Must be set to true if suplVersion is being passed */ + qmiLocSuplVersionEnumT_v02 suplVersion; + /**< SUPL version. + + Valid values: \n + - 0x00000001 -- SUPL_VERSION_1_0 \n + - 0x00000002 -- SUPL_VERSION_2_0 + */ + + /* Optional */ + /* LPP Configuration */ + uint8_t lppConfig_valid; /**< Must be set to true if lppConfig is being passed */ + qmiLocLppConfigMaskT_v02 lppConfig; + /**< LTE Positioning Profile (LPP) configuration. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- LPP_CONFIG_ENABLE_USER_PLANE + \item 0x00000002 -- LPP_CONFIG_ENABLE_CONTROL_PLANE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Assisted GLONASS Protocol Mask */ + uint8_t assistedGlonassProtocolMask_valid; /**< Must be set to true if assistedGlonassProtocolMask is being passed */ + qmiLocAssistedGlonassProtocolMaskT_v02 assistedGlonassProtocolMask; + /**< Assisted GLONASS Protocol mask. + + Valid bitmasks: \n + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRC_CP (0x00000001) -- Assisted GLONASS is supported over RRC in the control plane. + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_RRLP_UP (0x00000002) -- Assisted GLONASS is supported over RRLP in the user plane. + - QMI_LOC_ASSISTED_GLONASS_PROTOCOL_MASK_LPP_UP (0x00000004) -- Assisted GLONASS is supported over LPP in the user plane. + The QMI_LOC_LPP_CONFIG_ENABLE_USER_PLANE should be set + in the LPP configuration for this to take effect. + */ + + /* Optional */ + /* SUPL Hash Algorithm */ + uint8_t suplHashAlgo_valid; /**< Must be set to true if suplHashAlgo is being passed */ + qmiLocSuplHashAlgoEnumT_v02 suplHashAlgo; + /**< SUPL Hash Algorithm that needs to be used. Values: \n + - eQMI_LOC_SUPL_HASH_ALGO_SHA1 (0) -- SHA1 Hash Algorithm for SUPL Version 2.0 or higher + - eQMI_LOC_SUPL_HASH_ALGO_SHA256 (1) -- SHA-256 Hash Algorithm for SUPL Version 2.0 or higher + */ + + /* Optional */ + /* SUPL TLS Version */ + uint8_t suplTlsVersion_valid; /**< Must be set to true if suplTlsVersion is being passed */ + qmiLocSuplTlsVersionEnumT_v02 suplTlsVersion; + /**< SUPL TLS (Transport Layer Security) Version. This configuration is only + applicable to SUPL 2.0 or higher as SUPL 1.0 always uses TLS version 1.0. + Values: \n + - eQMI_LOC_SUPL_TLS_VERSION_1_0 (0) -- SUPL TLS Version 1.0 + - eQMI_LOC_SUPL_TLS_VERSION_1_1 (1) -- SUPL TLS Version 1.1 + */ + + /* Optional */ + /* Emergency Protocol */ + uint8_t emergencyProtocol_valid; /**< Must be set to true if emergencyProtocol is being passed */ + qmiLocEmergencyProtocolEnumT_v02 emergencyProtocol; + /**< The protocol to be used during emergency. + Values: \n + - eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_CP (0) -- use Control plane protocol during emergency while on WCDMA + - eQMI_LOC_EMERGENCY_PROTOCOL_WCDMA_UP (1) -- use SUPL 2.0 emergency services during emergency while on WCDMA + */ +}qmiLocGetProtocolConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_ENABLE_V02 = 0, /**< Sensors data should be requested whenever a position request is + received. If sensor data are injected, the positioning engine + attempts to improve the heading and positioning performance using sensors. + This is the default. + */ + eQMI_LOC_SENSOR_CONFIG_SENSOR_USE_DISABLE_V02 = 1, /**< Inertial sensors are not to be used to aid heading and position + improvement. */ + QMILOCSENSORSCONTROLCONFIGSENSORUSEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorsControlConfigSensorUseEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the sensor control configuration. */ +typedef struct { + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid heading and positioning + performance. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS_USE_DISABLED: + Inertial sensors are not to be used to aid in heading and + position improvement. + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor control configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Sensors Usage */ + uint8_t sensorsUsage_valid; /**< Must be set to true if sensorsUsage is being passed */ + qmiLocSensorsControlConfigSensorUseEnumT_v02 sensorsUsage; + /**< Controls how sensors are used to aid the heading and positioning + performance. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SENSORS_USE_ENABLED: + Sensors data is to be requested whenever a position request is + received. If sensors data is injected, the GNSS location engine + attempts to improve the heading and positioning performance using + sensors. This is the default. + \item 0x00000001 -- SENSORS_USE_DISABLED: + Inertial sensors are not to be used to aid in the heading and + position improvement. + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetSensorControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocSensorPropertiesMaskT_v02; +#define QMI_LOC_SENSOR_PROPERTIES_MASK_GYRO_BIAS_VARIANCE_RANDOM_WALK_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000001) /**< Denotes the gyro bias variance random walk parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000002) /**< Denotes the velocity random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000004) /**< Denotes the acceleration random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000008) /**< Denotes the angle random walk spectral density parameter. */ +#define QMI_LOC_SENSOR_PROPERTIES_MASK_RATE_RANDOM_WALK_SPECTRAL_DENSITY_V02 ((qmiLocSensorPropertiesMaskT_v02)0x00000010) /**< Denotes the rate random walk spectral density parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Optional */ + /* Gyro Bias Random Walk Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 + + */ +}qmiLocSetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Sets the properties specific to the type of sensor used. + The control point must set sensor properties before they can be + used to aid in heading and positioning performance improvement. + */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Properties request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Set Sensor Properties */ + uint8_t failedSensorPropertiesMask_valid; /**< Must be set to true if failedSensorPropertiesMask is being passed */ + qmiLocSensorPropertiesMaskT_v02 failedSensorPropertiesMask; + /**< This field will be sent only if the status is not a success. + Identifies the parameters that were not set successfully. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Sensor Properties Config Parameters */ + qmiLocSensorPropertiesMaskT_v02 getSensorPropertiesMask; + /**< Mask denoting the sensor properties parameters to be retrieved. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- GYRO_BIAS_VARIANCE_RANDOM_WALK + \item 0x00000002 -- VELOCITY_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000004 -- ACCELERATION_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000008 -- ANGLE_RANDOM_WALK_SPECTRAL_DENSITY + \item 0x00000010 -- RATE_RANDOM_WALK_SPECTRAL_DENSITY + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetSensorPropertiesReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor properties. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Properties Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensors Properties request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000007 -- CONFIG_NOT_SUPPORTED + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Gyro Bias Random Walk Variance */ + uint8_t gyroBiasVarianceRandomWalk_valid; /**< Must be set to true if gyroBiasVarianceRandomWalk is being passed */ + float gyroBiasVarianceRandomWalk; + /**< Specifies the gyro bias random walk variance parameter as a positive + floating-point value. This value has internal default value 1.0e-5 radian^2/second^4. + The gyro bias variance random walk parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians^2/seconds^4 + + */ + + /* Optional */ + /* Velocity Random Walk Spectral Density */ + uint8_t velocityRandomWalkSpectralDensity_valid; /**< Must be set to true if velocityRandomWalkSpectralDensity is being passed */ + float velocityRandomWalkSpectralDensity; + /**< Specifies the velocity random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The velocity random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^2/Hertz^0.5 + + */ + + /* Optional */ + /* Acceleration Random Walk Spectral Density */ + uint8_t accelerationRandomWalkSpectralDensity_valid; /**< Must be set to true if accelerationRandomWalkSpectralDensity is being passed */ + float accelerationRandomWalkSpectralDensity; + /**< Specifies the acceleration random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The acceleration random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Meters/seconds^3/Hertz^0.5 + + */ + + /* Optional */ + /* Angle Random Walk Spectral Density */ + uint8_t angleRandomWalkSpectralDensity_valid; /**< Must be set to true if angleRandomWalkSpectralDensity is being passed */ + float angleRandomWalkSpectralDensity; + /**< Specifies the angle random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The angle random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds/Hertz^0.5 + + */ + + /* Optional */ + /* Rate Random Walk Spectral Density */ + uint8_t rateRandomWalkSpectralDensity_valid; /**< Must be set to true if rateRandomWalkSpectralDensity is being passed */ + float rateRandomWalkSpectralDensity; + /**< Specifies the rate random walk spectral density parameter as a positive + floating-point value. This value does not have any internal defaults. + The rate random walk spectral density parameter is derived from either the + sensors data sheet or a sensors conformance test. \n + - Units: Radians/seconds^2/Hertz^0.5 + + */ +}qmiLocGetSensorPropertiesIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_AUTO_V02 = 0, /**< Sensors usage is to be determined by the GNSS location engine. + This mode can optimize power consumption and give a + power-balanced positioning and heading enhancement using + inertial sensors */ + eQMI_LOC_SENSOR_PERFORMANCE_CONTROL_MODE_FORCED_V02 = 1, /**< Sensors usage is to be forced ON. + This mode can be requested by the control point when + power consumption is not a restriction to the use of + inertial sensors. */ + QMILOCSENSORPERFORMANCECONTROLMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocSensorPerformanceControlModeEnumT_v02; +/** + @} + */ + +typedef uint32_t qmiLocSensorAlgorithmMaskT_v02; +#define QMI_LOC_SENSOR_ALGORITHM_MASK_DISABLE_INS_POSITIONING_FILTER_V02 ((qmiLocSensorAlgorithmMaskT_v02)0x00000001) /**< Inertial sensors are not to be used in Accelerometer-integrated fashion with + GNSS. They can still be used for aiding in heading improvements. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Optional */ + /* Sensor Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensors data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensors control configuration. + + Valid values: \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x00000001 -- FORCED: \n + The GNSS location engine must request use of sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request acceleration data to be used by the low data rate + filter. The sensor data rate is specified in terms of the nominal number + of samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n \vspace{0.06in} Sets the nominal rate at which the GNSS location + engine is to request gyro data to be used by the high data rate filter. + The sensor data rate is specified in terms of the nominal number of + samples per batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Sets which sensor algorithms are to be used when processing sensor data. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ +}qmiLocSetSensorPerformanceControlConfigReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocSensorPerformanceControlConfigFailureMaskT_v02; +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_PERFORMANCE_MODE_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000001) /**< Failed to set the performance mode. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000002) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000004) /**< Failed to set the gyroscope sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ALGORITHM_CONFIG_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000008) /**< Failed to set the algorithm configuration */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_ACCEL_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000010) /**< Failed to set the accelerometer sampling specification. */ +#define QMI_LOC_SENSOR_PERFORMANCE_CONTROL_CONFIG_PARAM_MASK_GYRO_SAMPLING_SPEC_HIGH_V02 ((qmiLocSensorPerformanceControlConfigFailureMaskT_v02)0x00000020) /**< Failed to set the gyroscope sampling specification. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Provides fine-grained control of sensor based positioning + performance */ +typedef struct { + + /* Mandatory */ + /* Set Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Sensor Performance Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Configuration */ + uint8_t failedConfiguration_valid; /**< Must be set to true if failedConfiguration is being passed */ + qmiLocSensorPerformanceControlConfigFailureMaskT_v02 failedConfiguration; + /**< Identifies parameters that were not configured successfully. This field + is sent only if the status is not a success. + + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- PERFORMANCE_MODE + \item 0x00000002 -- ACCEL_SAMPLING_SPEC + \item 0x00000004 -- GYRO_SAMPLING_SPEC + \item 0x00000008 -- ALGORITHM_CONFIG + \item 0x00000010 -- ACCEL_SAMPLING_SPEC_HIGH + \item 0x00000020 -- GYRO_SAMPLING_SPEC_HIGH + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocGetSensorPerformanceControlConfigReqMsgT is empty + * typedef struct { + * }qmiLocGetSensorPerformanceControlConfigReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Retrieves the current sensor performance control + configuration. */ +typedef struct { + + /* Mandatory */ + /* Get Sensor Perf Control Config Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Sensor Performance Control Configuration request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Performance Control Mode */ + uint8_t performanceControlMode_valid; /**< Must be set to true if performanceControlMode is being passed */ + qmiLocSensorPerformanceControlModeEnumT_v02 performanceControlMode; + /**< Controls when sensor data is requested during GNSS fix processing. + This field is relevant only when sensors have been enabled using the + sensor control configuration. + + Valid values: \begin{itemize1} + \item 0x00000000 -- AUTO: \n + The GNSS location engine can decide when to request sensor data + injection based on internal criteria. This is the default. + \item 0x0000001 -- FORCED: \n + The GNSS location engine must request use of the sensors every time + the GNSS location engine turns on. + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Accelerometer Sampling Specification */ + uint8_t accelSamplingSpec_valid; /**< Must be set to true if accelSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2Hz batching rate. + */ + + /* Optional */ + /* Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpec_valid; /**< Must be set to true if gyroSamplingSpec is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpec; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data + rate is specified in terms of the nominal number of samples per batch + and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 10 Hz sampling rate and 2 Hz batching rate. + */ + + /* Optional */ + /* Algorithm Configuration */ + uint8_t algorithmConfig_valid; /**< Must be set to true if algorithmConfig is being passed */ + qmiLocSensorAlgorithmMaskT_v02 algorithmConfig; + /**< Informs which sensor algorithms are currently set. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- DISABLE_INS_POSITIONING_FILTER + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* High Data Rate Filter Accelerometer Sampling Specification */ + uint8_t accelSamplingSpecHigh_valid; /**< Must be set to true if accelSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 accelSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + acceleration data to be used by the high data rate filter. The sensor + data rate is specified in terms of the nominal number of samples per + batch and the number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ + + /* Optional */ + /* High Data Rate Filter Gyroscope Sampling Specification */ + uint8_t gyroSamplingSpecHigh_valid; /**< Must be set to true if gyroSamplingSpecHigh is being passed */ + qmiLocSensorControlConfigSamplingSpecStructT_v02 gyroSamplingSpecHigh; + /**< \n Sets the nominal rate at which the GNSS location engine is to request + gyro data to be used by the high data rate filter. The sensor data rate + is specified in terms of the nominal number of samples per batch and the + number of batches per second. + However, the final control of the actual requested rate resides with + the Sensors Manager Module/GNSS location engine. \n + Default: 100 Hz sampling rate and 4 Hz batching rate. + */ +}qmiLocGetSensorPerformanceControlConfigIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate ID */ + uint8_t suplCertId; + /**< Certificate ID of the SUPL certificate. \n + - Units: Bytes \n + - Range: 0 to 9 */ + + /* Mandatory */ + /* SUPL Certificate Data */ + uint32_t suplCertData_len; /**< Must be set to # of elements in suplCertData */ + uint8_t suplCertData[QMI_LOC_MAX_SUPL_CERT_LENGTH_V02]; + /**< SUPL certificate contents. \n + - Type: Array of bytes. \n + - Maximum certificate size: 2000 bytes */ +}qmiLocInjectSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects a SUPL certificate to be used in AGNSS sessions. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate Injection Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject SUPL Certificate request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Deletes a SUPL certificate. */ +typedef struct { + + /* Optional */ + /* SUPL Certificate ID */ + uint8_t suplCertId_valid; /**< Must be set to true if suplCertId is being passed */ + uint8_t suplCertId; + /**< Certificate ID of the SUPL certificate to be deleted. \n + - Units: Bytes \n + - Range: 0 to 9 \n + If suplCertId is not specified, + all SUPL certificates are deleted. */ +}qmiLocDeleteSuplCertificateReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Deletes a SUPL certificate. */ +typedef struct { + + /* Mandatory */ + /* SUPL Certificate Deletion Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete SUPL Certificate request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocDeleteSuplCertificateIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocPositionEngineConfigParamMaskT_v02; +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_INJECTED_POSITION_CONTROL_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000001) /**< Denotes whether the position engine uses the + injected position in a direct position calculation. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_FILTER_SV_USAGE_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000002) /**< Denotes whether the position engine filters the + SV usage in the fix. */ +#define QMI_LOC_POSITION_ENGINE_CONFIG_PARAM_MASK_STORE_ASSIST_DATA_V02 ((qmiLocPositionEngineConfigParamMaskT_v02)0x00000004) /**< Denotes whether the position engine stores assistance data + in persistent memory. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Controls how the injected position is used in the position engine. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Use the injected position in a direct position + calculation + \item 0x00 (FALSE) -- Do not use the injected position in a direct + position calculation + \end{itemize1} + The default value is TRUE. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Controls whether SV usage is filtered in a position fix. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Filter the usage of SVs in the fix + \item 0x00 (FALSE) -- Do not filter the usage of SVs in the fix + \end{itemize1} + The default value is FALSE. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Controls whether assistance data is to be stored in + persistent memory. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Store assistance data in persistent memory + \item 0x00 (FALSE) -- Do not store assistance data in persistent memory + \end{itemize1} + The default value is TRUE. + */ +}qmiLocSetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to configure position engine + functionality. */ +typedef struct { + + /* Mandatory */ + /* Set Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Set Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedPositionEngineConfigParamMask_valid; /**< Must be set to true if failedPositionEngineConfigParamMask is being passed */ + qmiLocPositionEngineConfigParamMaskT_v02 failedPositionEngineConfigParamMask; + /**< Identifies the parameters that were not set successfully. + This field is sent only if the status is other than SUCCESS. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocSetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Config Parameters */ + qmiLocPositionEngineConfigParamMaskT_v02 getPositionEngineConfigParamMask; + /**< Mask denoting the configuration parameters to be retrieved. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- INJECTED_POSITION_CONTROL + \item 0x00000002 -- FILTER_SV_USAGE + \item 0x00000004 -- STORE_ASSIST_DATA + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocGetPositionEngineConfigParametersReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the position engine + configuration parameters. */ +typedef struct { + + /* Mandatory */ + /* Get Position Engine Configuration Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Configuration Parameters request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Injected Position Control */ + uint8_t injectedPositionControl_valid; /**< Must be set to true if injectedPositionControl is being passed */ + uint8_t injectedPositionControl; + /**< Specifies whether the injected position is used for a direct calculation + in the position engine. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- The injected position is used in a direct + position calculation + \item 0x00 (FALSE) -- The injected position is not used in a direct + position calculation + \end{itemize1} + The default value is TRUE. + */ + + /* Optional */ + /* Filter SV Usage */ + uint8_t filterSvUsage_valid; /**< Must be set to true if filterSvUsage is being passed */ + uint8_t filterSvUsage; + /**< Specifies whether SV usage is filtered in a position fix. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- SV usage is filtered in the fix + \item 0x00 (FALSE) -- SV usage is not filtered in the fix + \end{itemize1} + The default value is FALSE. + */ + + /* Optional */ + /* Store Assist Data */ + uint8_t storeAssistData_valid; /**< Must be set to true if storeAssistData is being passed */ + uint8_t storeAssistData; + /**< Specifies whether assistance data is stored in persistent memory. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Assistance data is stored in persistent memory + \item 0x00 (FALSE) -- Assistance data is not stored in persistent + memory + \end{itemize1} + The default value is TRUE. + */ +}qmiLocGetPositionEngineConfigParametersIndMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint8_t qmiLocGeofenceBreachMaskT_v02; +#define QMI_LOC_GEOFENCE_BREACH_ENTERING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x01) /**< If this mask is set, a breach event is reported + when the Geofence is entered. */ +#define QMI_LOC_GEOFENCE_BREACH_LEAVING_MASK_V02 ((qmiLocGeofenceBreachMaskT_v02)0x02) /**< If this mask is set, a breach event is reported + when the Geofence is exited. */ +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCERESPONSIVENESSENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_LOW_V02 = 0x01, /**< The Geofence is monitored for a breach at a + lower rate. The gap between actual breach and + the time it is reported is higher. This + setting results in lower power usage. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_MED_V02 = 0x02, /**< The Geofence is monitored for a breach at a + medium rate. This is the default setting. */ + eQMI_LOC_GEOFENCE_RESPONSIVENESS_HIGH_V02 = 0x03, /**< The Geofence is monitored for a breach at a + high rate. The gap between actual breach and + the time it is reported is low. This results + in higher power usage. */ + QMILOCGEOFENCERESPONSIVENESSENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceResponsivenessEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCECONFIDENCEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_CONFIDENCE_LOW_V02 = 0x01, /**< The Geofence engine indicates a breach with + low confidence. This setting results in lower + power usage. This setting can impact the "yield" because + incorrect breach events may be sent. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_MED_V02 = 0x02, /**< The Geofence engine indicates a breach with + medium confidence. This is the default setting. */ + eQMI_LOC_GEOFENCE_CONFIDENCE_HIGH_V02 = 0x03, /**< The Geofence engine indicates a breach with + high confidence. This setting results in higher + power usage. */ + QMILOCGEOFENCECONFIDENCEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceConfidenceEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + double latitude; + /**< Latitude of the center of the Geofence.*/ + + double longitude; + /**< Longitude of the center of the Geofence.*/ + + uint32_t radius; + /**< Radius of the circular Geofence in meters. */ +}qmiLocCircularGeofenceArgsStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEPOSITIONENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_POSITION_INSIDE_V02 = 0x01, /**< Position inside a Geofence. */ + eQMI_LOC_GEOFENCE_POSITION_OUTSIDE_V02 = 0x02, /**< Position outside a Geofence. */ + QMILOCGEOFENCEPOSITIONENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofencePositionEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Add Circular Geofence + indication. */ + + /* Mandatory */ + /* Circular Geofence Arguments */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Mandatory */ + /* Breach Event Mask */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ + + /* Mandatory */ + /* Include Position in Breach Event */ + uint8_t includePosition; + /**< Specifies whether the Geofence engine is to include the position + in a breach event. + + Valid values: \begin{itemize1} + \item 0x01 (TRUE) -- Position will be reported with the breach event + \item 0x00 (FALSE) -- Position will not be reported with the breach + event + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Responsiveness */ + uint8_t responsiveness_valid; /**< Must be set to true if responsiveness is being passed */ + qmiLocGeofenceResponsivenessEnumT_v02 responsiveness; + /**< Specifies the rate of detection for a Geofence breach. + This may impact the time lag between the actual breach event and + when it is reported. This parameter has power implications + and is to be fine-tuned to optimize power savings. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_RESPONSIVENESS_LOW + \item 0x00000002 -- GEOFENCE_RESPONSIVENESS_MED + \item 0x00000003 -- GEOFENCE_RESPONSIVENESS_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Confidence */ + uint8_t confidence_valid; /**< Must be set to true if confidence is being passed */ + qmiLocGeofenceConfidenceEnumT_v02 confidence; + /**< Given a breach event, the confidence determines the probability + that the breach happened at the Geofence boundary. + This parameter has power implications and + is to be fine-tuned to optimize power savings. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_CONFIDENCE_LOW + \item 0x00000002 -- GEOFENCE_CONFIDENCE_MED + \item 0x00000003 -- GEOFENCE_CONFIDENCE_HIGH + \vspace{-0.18in} \end{itemize1} */ +}qmiLocAddCircularGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to add a circular Geofence. */ +typedef struct { + + /* Mandatory */ + /* Add Circular Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Add Circular Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \item 0x00000008 -- INSUFFICIENT_MEMORY + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Add Circular + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Geofence identifier allocated by the engine. + The client must include this identifier in all transactions + pertaining to this Geofence. */ +}qmiLocAddCircularGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be deleted. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Delete Geofence + indication. */ +}qmiLocDeleteGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to delete a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Delete Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Delete Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was deleted. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Delete + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ +}qmiLocDeleteGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCEORIGINENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_ORIGIN_NETWORK_V02 = 1, /**< The Geofence was initiated by a network-initiated client. */ + eQMI_LOC_GEOFENCE_ORIGIN_DEVICE_V02 = 2, /**< The Geofence was initiated by the device. */ + QMILOCGEOFENCEORIGINENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceOriginEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCGEOFENCESTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_GEOFENCE_STATE_ACTIVE_V02 = 1, /**< The Geofence is being actively monitored. */ + eQMI_LOC_GEOFENCE_STATE_SUSPEND_V02 = 2, /**< The Geofence monitoring is suspended. */ + QMILOCGEOFENCESTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocGeofenceStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence that is to be queried. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned with the Query Geofence + indication. */ +}qmiLocQueryGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to query a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Query Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Query Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was queried. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Query + Geofence request. This parameter will always be present + if the status field is set to SUCCESS. */ + + /* Optional */ + /* Geofence Origin */ + uint8_t geofenceOrigin_valid; /**< Must be set to true if geofenceOrigin is being passed */ + qmiLocGeofenceOriginEnumT_v02 geofenceOrigin; + /**< Originator of the Geofence. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_ORIGIN_NETWORK + \item 0x00000002 -- GEOFENCE_ORIGIN_DEVICE + \vspace{-0.18in} \end{itemize1} + */ + + /* Optional */ + /* Position with Respect to Geofence */ + uint8_t posWrtGeofence_valid; /**< Must be set to true if posWrtGeofence is being passed */ + qmiLocGeofencePositionEnumT_v02 posWrtGeofence; + /**< Indicates if the client is currently inside or outside + the Geofence. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_POSITION_INSIDE + \item 0x00000002 -- GEOFENCE_POSITION_OUTSIDE + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Circular Geofence Parameters */ + uint8_t circularGeofenceArgs_valid; /**< Must be set to true if circularGeofenceArgs is being passed */ + qmiLocCircularGeofenceArgsStructT_v02 circularGeofenceArgs; + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ +}qmiLocQueryGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Geofence ID */ + uint32_t geofenceId; + /**< Identifier for the Geofence to be edited. */ + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Edit Geofence + request. This parameter will always be present if the + status field is set to SUCCESS. + */ + + /* Optional */ + /* Geofence State */ + uint8_t geofenceState_valid; /**< Must be set to true if geofenceState is being passed */ + qmiLocGeofenceStateEnumT_v02 geofenceState; + /**< Specifies whether the Geofence is to be actively monitored. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_STATE_ACTIVE + \item 0x00000002 -- GEOFENCE_STATE_SUSPEND + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Breach Event Mask */ + uint8_t breachMask_valid; /**< Must be set to true if breachMask is being passed */ + qmiLocGeofenceBreachMaskT_v02 breachMask; + /**< Specifies the breach events in which the client is interested. + + Valid values: \begin{itemize1} + \item 0x01 -- GEOFENCE_BREACH_ENTERING_MASK + \item 0x02 -- GEOFENCE_BREACH_LEAVING_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceReqMsgT_v02; /* Message */ +/** + @} + */ + +typedef uint32_t qmiLocGeofenceConfigParamMaskT_v02; +#define QMI_LOC_GEOFENCE_PARAM_MASK_GEOFENCE_STATE_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000001) /**< Mask for the Geofence state parameter. */ +#define QMI_LOC_GEOFENCE_PARAM_MASK_BREACH_MASK_V02 ((qmiLocGeofenceConfigParamMaskT_v02)0x00000002) /**< Mask for Geofence breach mask parameter. */ +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to edit a Geofence. */ +typedef struct { + + /* Mandatory */ + /* Edit Geofence Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Edit Geofence request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Geofence ID */ + uint8_t geofenceId_valid; /**< Must be set to true if geofenceId is being passed */ + uint32_t geofenceId; + /**< Identifier for the Geofence that was edited. */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is specified in the Edit Geofence request. */ + + /* Optional */ + /* Failed Parameters */ + uint8_t failedParams_valid; /**< Must be set to true if failedParams is being passed */ + qmiLocGeofenceConfigParamMaskT_v02 failedParams; + /**< Specified only when the status is not set to SUCCESS. If + the mask corresponding to a field is set, it indicates that + the Geofence parameter could not be edited. + + Valid values: \begin{itemize1} + \item 0x00000001 -- GEOFENCE_PARAM_MASK_GEOFENCE_STATE + \item 0x00000002 -- GEOFENCE_PARAM_MASK_BREACH_MASK + \vspace{-0.18in} \end{itemize1} */ +}qmiLocEditGeofenceIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The transaction ID + is returned in the Get Best Available Position indication. */ +}qmiLocGetBestAvailablePositionReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to get the best available + position estimate from the location engine. */ +typedef struct { + + /* Mandatory */ + /* Get Best Available Position Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get Best Available Position request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Get Best + Available Position request. This parameter will + always be present if the status field is set to + SUCCESS. */ + + /* Optional */ + /* Latitude */ + uint8_t latitude_valid; /**< Must be set to true if latitude is being passed */ + double latitude; + /**< Latitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -90.0 to 90.0 \begin{itemize1} + \item Positive values indicate northern latitude + \item Negative values indicate southern latitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Longitude */ + uint8_t longitude_valid; /**< Must be set to true if longitude is being passed */ + double longitude; + /**< Longitude (specified in WGS84 datum). + \begin{itemize1} + \item Type: Floating point + \item Units: Degrees + \item Range: -180.0 to 180.0 \begin{itemize1} + \item Positive values indicate eastern longitude + \item Negative values indicate western longitude + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ + + /* Optional */ + /* Circular Horizontal Position Uncertainty */ + uint8_t horUncCircular_valid; /**< Must be set to true if horUncCircular is being passed */ + float horUncCircular; + /**< Horizontal position uncertainty (circular).\n + - Units: Meters */ + + /* Optional */ + /* Altitude With Respect to Ellipsoid */ + uint8_t altitudeWrtEllipsoid_valid; /**< Must be set to true if altitudeWrtEllipsoid is being passed */ + float altitudeWrtEllipsoid; + /**< Altitude with respect to the WGS84 ellipsoid.\n + - Units: Meters \n + - Range: -500 to 15883 */ + + /* Optional */ + /* Vertical Uncertainty */ + uint8_t vertUnc_valid; /**< Must be set to true if vertUnc is being passed */ + float vertUnc; + /**< Vertical uncertainty.\n + - Units: Meters */ + + /* Optional */ + /* UTC Timestamp */ + uint8_t timestampUtc_valid; /**< Must be set to true if timestampUtc is being passed */ + uint64_t timestampUtc; + /**< UTC timestamp. + \begin{itemize1} + \item Units: Milliseconds since Jan. 1, 1970 + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Time Uncertainty */ + uint8_t timeUnc_valid; /**< Must be set to true if timeUnc is being passed */ + float timeUnc; + /**< Time uncertainty. \n + - Units: Milliseconds */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Minor Axis */ + uint8_t horUncEllipseSemiMinor_valid; /**< Must be set to true if horUncEllipseSemiMinor is being passed */ + float horUncEllipseSemiMinor; + /**< Semi-minor axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Semi-Major Axis */ + uint8_t horUncEllipseSemiMajor_valid; /**< Must be set to true if horUncEllipseSemiMajor is being passed */ + float horUncEllipseSemiMajor; + /**< Semi-major axis of horizontal elliptical uncertainty. \n + - Units: Meters */ + + /* Optional */ + /* Horizontal Elliptical Uncertainty Azimuth */ + uint8_t horUncEllipseOrientAzimuth_valid; /**< Must be set to true if horUncEllipseOrientAzimuth is being passed */ + float horUncEllipseOrientAzimuth; + /**< Elliptical horizontal uncertainty azimuth of orientation. \n + - Units: Decimal degrees \n + - Range: 0 to 180 */ + + /* Optional */ + /* Horizontal Circular Confidence */ + uint8_t horCircularConfidence_valid; /**< Must be set to true if horCircularConfidence is being passed */ + uint8_t horCircularConfidence; + /**< Horizontal circular uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Elliptical Confidence */ + uint8_t horEllipticalConfidence_valid; /**< Must be set to true if horEllipticalConfidence is being passed */ + uint8_t horEllipticalConfidence; + /**< Horizontal elliptical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Horizontal Reliability */ + uint8_t horReliability_valid; /**< Must be set to true if horReliability is being passed */ + qmiLocReliabilityEnumT_v02 horReliability; + /**< Specifies the reliability of the horizontal position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Horizontal Speed */ + uint8_t horSpeed_valid; /**< Must be set to true if horSpeed is being passed */ + float horSpeed; + /**< Horizontal speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Horizontal Speed Uncertainty */ + uint8_t horSpeedUnc_valid; /**< Must be set to true if horSpeedUnc is being passed */ + float horSpeedUnc; + /**< Horizontal speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Altitude With Respect to Sea Level */ + uint8_t altitudeWrtMeanSeaLevel_valid; /**< Must be set to true if altitudeWrtMeanSeaLevel is being passed */ + float altitudeWrtMeanSeaLevel; + /**< Altitude with respect to mean sea level. \n + - Units: Meters */ + + /* Optional */ + /* Vertical Confidence */ + uint8_t vertConfidence_valid; /**< Must be set to true if vertConfidence is being passed */ + uint8_t vertConfidence; + /**< Vertical uncertainty confidence. \n + - Units: Percent \n + - Range: 0 to 99 */ + + /* Optional */ + /* Vertical Reliability */ + uint8_t vertReliability_valid; /**< Must be set to true if vertReliability is being passed */ + qmiLocReliabilityEnumT_v02 vertReliability; + /**< Specifies the reliability of the vertical position. + + Valid values: \begin{itemize1} + \item 0x00000000 -- RELIABILITY_NOT_SET + \item 0x00000001 -- RELIABILITY_VERY_LOW + \item 0x00000002 -- RELIABILITY_LOW + \item 0x00000003 -- RELIABILITY_MEDIUM + \item 0x00000004 -- RELIABILITY_HIGH + \vspace{-0.18in} \end{itemize1}*/ + + /* Optional */ + /* Vertical Speed */ + uint8_t vertSpeed_valid; /**< Must be set to true if vertSpeed is being passed */ + float vertSpeed; + /**< Vertical speed. \n + - Units: Meters/second */ + + /* Optional */ + /* Vertical Speed Uncertainty */ + uint8_t vertSpeedUnc_valid; /**< Must be set to true if vertSpeedUnc is being passed */ + float vertSpeedUnc; + /**< Vertical speed uncertainty. \n + - Units: Meters/second */ + + /* Optional */ + /* Heading */ + uint8_t heading_valid; /**< Must be set to true if heading is being passed */ + float heading; + /**< Heading. \n + - Units: Degrees \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Heading Uncertainty */ + uint8_t headingUnc_valid; /**< Must be set to true if headingUnc is being passed */ + float headingUnc; + /**< Heading uncertainty. \n + - Type: Floating point \n + - Range: 0 to 359.999 */ + + /* Optional */ + /* Magnetic Deviation */ + uint8_t magneticDeviation_valid; /**< Must be set to true if magneticDeviation is being passed */ + float magneticDeviation; + /**< Difference between the bearing to true north and the bearing shown + on a magnetic compass. The deviation is positive when the magnetic + north is east of true north. */ + + /* Optional */ + /* Technology Used Mask */ + uint8_t technologyMask_valid; /**< Must be set to true if technologyMask is being passed */ + qmiLocPosTechMaskT_v02 technologyMask; + /**< Technology used in computing this fix. + + Valid bitmasks: \begin{itemize1} + \item 0x00000001 -- SATELLITE + \item 0x00000002 -- CELLID + \item 0x00000004 -- WIFI + \item 0x00000008 -- SENSORS + \item 0x00000010 -- REFERENCE_LOCATION + \item 0x00000020 -- INJECTED_COARSE_POSITION + \vspace{-0.18in} \end{itemize1} */ + + /* Optional */ + /* Dilution of Precision */ + uint8_t DOP_valid; /**< Must be set to true if DOP is being passed */ + qmiLocDOPStructT_v02 DOP; + + /* Optional */ + /* GPS Time */ + uint8_t gpsTime_valid; /**< Must be set to true if gpsTime is being passed */ + qmiLocGPSTimeStructT_v02 gpsTime; + + /* Optional */ + /* Time Source */ + uint8_t timeSrc_valid; /**< Must be set to true if timeSrc is being passed */ + qmiLocTimeSourceEnumT_v02 timeSrc; + /**< Time source. + Valid values: \n + - eQMI_LOC_TIME_SRC_INVALID (0) -- Invalid time. + - eQMI_LOC_TIME_SRC_NETWORK_TIME_TRANSFER (1) -- Time is set by the 1x system. + - eQMI_LOC_TIME_SRC_NETWORK_TIME_TAGGING (2) -- Time is set by WCDMA/GSM time tagging (i.e., + associating network time with GPS time). + - eQMI_LOC_TIME_SRC_EXTERNAL_INPUT (3) -- Time is set by an external injection. + - eQMI_LOC_TIME_SRC_TOW_DECODE (4) -- Time is set after decoding over-the-air GPS navigation data + from one GPS satellite. + - eQMI_LOC_TIME_SRC_TOW_CONFIRMED (5) -- Time is set after decoding over-the-air GPS navigation data + from multiple satellites. + - eQMI_LOC_TIME_SRC_TOW_AND_WEEK_CONFIRMED (6) -- Both time of the week and the GPS week number are known. + - eQMI_LOC_TIME_SRC_NAV_SOLUTION (7) -- Time is set by the position engine after the fix is obtained. + - eQMI_LOC_TIME_SRC_SOLVE_FOR_TIME (8) -- Time is set by the position engine after performing SFT. + This is done when the clock time uncertainty is large. + - eQMI_LOC_TIME_SRC_GLO_TOW_DECODE (9) -- Time is set after decoding GLO satellites + - eQMI_LOC_TIME_SRC_TIME_TRANSFORM (10) -- Time is set after transforming the GPS to GLO time + - eQMI_LOC_TIME_SRC_WCDMA_SLEEP_TIME_TAGGING (11) -- Time is set by the sleep time tag provided by the WCDMA network + - eQMI_LOC_TIME_SRC_GSM_SLEEP_TIME_TAGGING (12) -- Time is set by the sleep time tag provided by the GSM network + - eQMI_LOC_TIME_SRC_UNKNOWN (13) -- Source of the time is unknown + - eQMI_LOC_TIME_SRC_SYSTEM_TIMETICK (14) -- Time is derived from system clock (better known as slow clock). + GNSS time is maintained irrespective of the GNSS receiver state + */ + + /* Optional */ + /* Sensor Data Usage */ + uint8_t sensorDataUsage_valid; /**< Must be set to true if sensorDataUsage is being passed */ + qmiLocSensorUsageIndicatorStructT_v02 sensorDataUsage; + + /* Optional */ + /* SVs Used to Calculate the Fix */ + uint8_t gnssSvUsedList_valid; /**< Must be set to true if gnssSvUsedList is being passed */ + uint32_t gnssSvUsedList_len; /**< Must be set to # of elements in gnssSvUsedList */ + uint16_t gnssSvUsedList[QMI_LOC_MAX_SV_USED_LIST_LENGTH_V02]; + /**< Each entry in the list contains the SV ID of a satellite + used for calculating this position report. The following + information is associated with each SV ID: \begin{itemize1} + \item Range: \begin{itemize1} + \item For GPS: 1 to 32 + \item For SBAS: 33 to 64 + \item For GLONASS: 65 to 96 + \item For QZSS: 193 to 197 + \vspace{-0.18in} \end{itemize1} \end{itemize1} */ +}qmiLocGetBestAvailablePositionIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONSTATEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_STATE_UNKNOWN_V02 = 0, /**< Device state is not known. */ + eQMI_LOC_MOTION_STATE_STATIONARY_V02 = 1, /**< Device state is Stationary. */ + eQMI_LOC_MOTION_STATE_IN_MOTION_V02 = 2, /**< Device state is In Motion. */ + QMILOCMOTIONSTATEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionStateEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCMOTIONMODEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_MOTION_MODE_UNKNOWN_V02 = 0, /**< Device movement is not known. */ + eQMI_LOC_MOTION_MODE_STATIONARY_V02 = 1, /**< Device is not moving. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_UNKNOWN_V02 = 200, /**< Device movement is in Pedestrian mode; nothing else is known about the movement. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_WALKING_V02 = 201, /**< Device movement is in pedestrian Walking mode. */ + eQMI_LOC_MOTION_MODE_PEDESTRIAN_RUNNING_V02 = 202, /**< Device movement is in pedestrian Running mode. */ + eQMI_LOC_MOTION_MODE_VEHICLE_UNKNOWN_V02 = 300, /**< Device movement is in Vehicular mode; nothing else is known about the movement. */ + QMILOCMOTIONMODEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocMotionModeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + qmiLocMotionStateEnumT_v02 motion_state; + /**< Current motion state of the user. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_STATE_UNKNOWN (0) -- Device state is not known. + \item eQMI_LOC_MOTION_STATE_STATIONARY (1) -- Device state is Stationary. + \item eQMI_LOC_MOTION_STATE_IN_MOTION (2) -- Device state is In Motion. + \vspace{0.06in} \end{itemize1} + + Absolute rest and relative rest are both indicated by setting motion_state + to Stationary. The relative rest state can be distinguished from absolute + rest by reducing probability_of_state. + */ + + qmiLocMotionModeEnumT_v02 motion_mode; + /**< Modes of user motion. \n + + Valid values: \begin{itemize1} + \item eQMI_LOC_MOTION_MODE_ UNKNOWN (0) -- Device movement is not known. + \item eQMI_LOC_MOTION_MODE_ STATIONARY (1) -- Device is not moving. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_UNKNOWN (200) -- Device movement + is in Pedestrian mode; nothing else is known about the movement. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_WALKING (201) -- Device movement + is in Pedestrian Walking mode. + \item eQMI_LOC_MOTION_MODE_ PEDESTRIAN_RUNNING (202) -- Device movement + is in Pedestrian Running mode. + \item eQMI_LOC_MOTION_MODE_ VEHICLE_UNKNOWN (300) -- Device movement is + in Vehicular mode; nothing else is known about the movement. + \vspace{0.06in} \end{itemize1} + + The motion_mode value is independent of the motion_state value. + */ + + float probability_of_state; + /**< Probability that the device is actually undergoing the motion state + specified by the combination of the values of motion_state, motion_mode, + and motion_sub_mode. \vspace{0.06in} + + This value is a floating point number in the range of 0 to 100, in + units of percent probability. Any value greater than 99.9999 is + applied as 99.9999. \vspace{0.06in} + + It is recommended that if a particular combination of motion_state and + motion_mode cannot be determined with more than 50 percent confidence, + that a more general statement of user motion be made. + For example, if the mode of In-Motion + Pedestrian-Running can only be + determined with 50 percent probability, and the simpler statement of In-Motion + can be determined with 90 percent probability, it is recommended that this field + be used to simply state In-Motion with 90 percent probability. \vspace{0.06in} + + If the motion_state is not known, the value in this field is not used. + */ + + uint16_t age; + /**< Age of the motion data in milliseconds at the time of injection. + */ + + uint16_t timeout; + /**< If the age of the motion data input exceeds the timeout value, the data + will no longer be used. The timeout value is in units of milliseconds. + Values in the range of 0 to 10000 are accepted. If 65535 is provided, + the motion data input is applied until the next input is + received. \vspace{0.06in} + + If the determination of motion data is an instantaneous observation + and no notice is guaranteed to be given via the QMI on a change in the + state of the motion data, it is recommended that this field be set to 0. \vspace{0.06in} + + If the determination of motion data is continuously monitored + external to the QMI and an update is always applied to the QMI upon any + change in state, a value of 65535 is used for this field. + Note that in this case, if a certain mode is set and is not later + unset (e.g., by sending in the request message with a user motion + state of Unknown), the value is applied indefinitely. + */ +}qmiLocMotionDataStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Motion Data */ + qmiLocMotionDataStructT_v02 motion_data; + /**< Current motion data of the client */ +}qmiLocInjectMotionDataReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Injects motion data for MSM GPS service use. */ +typedef struct { + + /* Mandatory */ + /* Inject Motion Data Request Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Motion Data request. + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_ PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocInjectMotionDataIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to retrieve the list of network + initiated Geofence IDs. */ +typedef struct { + + /* Mandatory */ + /* Transaction ID */ + uint32_t transactionId; + /**< Identifies the transaction. The same transaction ID + will be returned in the Get NI Geofence ID List indication. */ +}qmiLocGetNiGeofenceIdListReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to retrieve the list of network + initiated Geofence IDs. */ +typedef struct { + + /* Mandatory */ + /* Get NI Geofence ID List status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Get NI Geofence ID List request. + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ + + /* Optional */ + /* Transaction ID */ + uint8_t transactionId_valid; /**< Must be set to true if transactionId is being passed */ + uint32_t transactionId; + /**< Transaction ID that was specified in the Get NI + Geofence ID List request. */ + + /* Optional */ + /* NI Geofence ID List */ + uint8_t niGeofenceIdList_valid; /**< Must be set to true if niGeofenceIdList is being passed */ + uint32_t niGeofenceIdList_len; /**< Must be set to # of elements in niGeofenceIdList */ + uint32_t niGeofenceIdList[QMI_LOC_MAX_NI_GEOFENCE_ID_LIST_LENGTH_V02]; + /**< List containing the NI Geofence IDs. + - Type: Array of unsigned 32-bit integers \n + - Maximum NI Geofence ID List length: 16 */ +}qmiLocGetNiGeofenceIdListIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_aggregates + @{ + */ +typedef struct { + + uint32_t MCC; + /**< GSM mobile country code. Refer to ITU-T E.212 specification */ + + uint32_t MNC; + /**< GSM mobile network code. Refer to ITU-T E.212 specification*/ + + uint32_t LAC; + /**< GSM location area code.Refer to ITU-T E.212 specification */ + + uint32_t CID; + /**< GSM cell identification.Refer to ITU-T E.212 specification */ +}qmiLocGSMCellIdStructT_v02; /* Type */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* GSM Cell ID */ + qmiLocGSMCellIdStructT_v02 gsmCellId; + /**< Identifies the GSM Cell the device is currently camped on.*/ + + /* Mandatory */ + /* Roaming Status */ + uint8_t roamingStatus; + /**< Whether the device is roaming. + \begin{itemize1} + \item 0x01 (TRUE) -- The device is roaming. + \item 0x00 (FALSE) -- The device is not roaming. + \vspace{-0.18in} \end{itemize1}*/ +}qmiLocInjectGSMCellInfoReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject GSM Cell information into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject GSM Cell Info Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject GSM Cell Info request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT */ +}qmiLocInjectGSMCellInfoIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_enums + @{ + */ +typedef enum { + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MIN_ENUM_VAL_V02 = -2147483647, /**< To force a 32 bit signed enum. Do not change or use*/ + eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL_V02 = 0, /**< SUPL netwrok initiated message is being injected. */ + QMILOCINJECTEDNETWORKINITIATEDMESSAGETYPEENUMT_MAX_ENUM_VAL_V02 = 2147483647 /**< To force a 32 bit signed enum. Do not change or use*/ +}qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02; +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Injected Network Initiated Message Type */ + qmiLocInjectedNetworkInitiatedMessageTypeEnumT_v02 injectedNIMessageType; + /**< Type of the network initiated message being injected + Valid Values: + - eQMI_LOC_INJECTED_NETWORK_INITIATED_MESSAGE_TYPE_SUPL (0) -- SUPL netwrok initiated message is being injected. */ + + /* Mandatory */ + /* Injected Network Initiated Message */ + uint32_t injectedNIMessage_len; /**< Must be set to # of elements in injectedNIMessage */ + uint8_t injectedNIMessage[QMI_LOC_MAX_INJECTED_NETWORK_INITIATED_MESSAGE_LENGTH_V02]; + /**< Network initiated message body. + If the inject NI message type is TYPE_SUPL, the message contains + a SUPL INIT message as defined in OMA-TS-ULP-V2_0-20110527-C specification. */ +}qmiLocInjectNetworkInitiatedMessageReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to inject a network initiated message into the location + engine. */ +typedef struct { + + /* Mandatory */ + /* Inject Network Initiated Message Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Inject Network Initiated Message request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + - 0x00000008 -- INSUFFICIENT_MEMORY \n */ +}qmiLocInjectNetworkInitiatedMessageIndMsgT_v02; /* Message */ +/** + @} + */ + +/* + * qmiLocWWANOutOfServiceNotificationReqMsgT is empty + * typedef struct { + * }qmiLocWWANOutOfServiceNotificationReqMsgT_v02; + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used to notify the location engine that the device is + no longer camped. */ +typedef struct { + + /* Mandatory */ + /* Notify WWAN Out of Service Status */ + qmiLocStatusEnumT_v02 status; + /**< Status of the Notify WWAN out of service request. + + Valid values: \n + - 0x00000000 -- SUCCESS \n + - 0x00000001 -- GENERAL_FAILURE \n + - 0x00000002 -- UNSUPPORTED \n + - 0x00000003 -- INVALID_PARAMETER \n + - 0x00000004 -- ENGINE_BUSY \n + - 0x00000006 -- TIMEOUT \n + */ +}qmiLocWWANOutOfServiceNotificationIndMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Request Message; Used by the control point to inject pedometer data + into the location engine. */ +typedef struct { + + /* Mandatory */ + /* Time Source */ + qmiLocSensorDataTimeSourceEnumT_v02 timeSource; + /**< Time source for the pedometer. Location service will use + this field to identify the time reference used in the + pedometer data timestamp. Values: \n + - eQMI_LOC_SENSOR_TIME_SOURCE_UNSPECIFIED (0) -- The sensor time source is unspecified + - eQMI_LOC_SENSOR_TIME_SOURCE_COMMON (1) -- The time source is common between the sensors and + the location engine*/ + + /* Mandatory */ + /* Pedometer report timestamp */ + uint32_t timestamp; + /**< Timestamp of the last step event in this report, i.e timestamp + of the step event that caused this report to be generated. + The timestamp is in the time reference scale that is + used by the pedometer time source. \n + - Unit: Milliseconds */ + + /* Mandatory */ + /* Time Interval */ + uint32_t timeInterval; + /**< Time interval during which the step count was calculated. Subtracting + timeInterval from the timestamp field will yield the the time when + the step detection for the first step in this report started. + Unit : Milliseconds. */ + + /* Mandatory */ + /* Step Count */ + uint32_t stepCount; + /**< Number for steps counted during the time interval.*/ + + /* Optional */ + /* Step Confidence */ + uint8_t stepConfidence_valid; /**< Must be set to true if stepConfidence is being passed */ + uint8_t stepConfidence; + /**< Confidence associated with the step. This field is only applicable + for a single step report, i.e if the stepCount is one. + Range: 0 to 100. + Note: The report will be ignored if confidence is 0. */ + + /* Optional */ + /* Step Count Uncertainty */ + uint8_t stepCountUncertainty_valid; /**< Must be set to true if stepCountUncertainty is being passed */ + float stepCountUncertainty; + /**< Uncertainty (in steps) associated with the step count. */ + + /* Optional */ + /* Step Rate */ + uint8_t stepRate_valid; /**< Must be set to true if stepRate is being passed */ + float stepRate; + /**< Current estimate for the rate of steps per second. + Units: steps/second + Range: >= 0.0 + */ +}qmiLocPedometerReportReqMsgT_v02; /* Message */ +/** + @} + */ + +/** @addtogroup loc_qmi_messages + @{ + */ +/** Indication Message; Used by the control point to inject pedometer data + into the location engine. */ +typedef struct { + + /* Mandatory */ + /* Status of Pedometer report request */ + qmiLocStatusEnumT_v02 status; + /**< Status of the pedometer report request + + Valid values: \begin{itemize1} + \item 0x00000000 -- SUCCESS + \item 0x00000001 -- GENERAL_FAILURE + \item 0x00000002 -- UNSUPPORTED + \item 0x00000003 -- INVALID_PARAMETER + \item 0x00000004 -- ENGINE_BUSY + \item 0x00000005 -- PHONE_OFFLINE + \item 0x00000006 -- TIMEOUT + \vspace{-0.18in} \end{itemize1} + */ +}qmiLocPedometerReportIndMsgT_v02; /* Message */ +/** + @} + */ + +/*Service Message Definition*/ +/** @addtogroup loc_qmi_msg_ids + @{ + */ +#define QMI_LOC_INFORM_CLIENT_REVISION_REQ_V02 0x0020 +#define QMI_LOC_INFORM_CLIENT_REVISION_RESP_V02 0x0020 +#define QMI_LOC_REG_EVENTS_REQ_V02 0x0021 +#define QMI_LOC_REG_EVENTS_RESP_V02 0x0021 +#define QMI_LOC_START_REQ_V02 0x0022 +#define QMI_LOC_START_RESP_V02 0x0022 +#define QMI_LOC_STOP_REQ_V02 0x0023 +#define QMI_LOC_STOP_RESP_V02 0x0023 +#define QMI_LOC_EVENT_POSITION_REPORT_IND_V02 0x0024 +#define QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02 0x0025 +#define QMI_LOC_EVENT_NMEA_IND_V02 0x0026 +#define QMI_LOC_EVENT_NI_NOTIFY_VERIFY_REQ_IND_V02 0x0027 +#define QMI_LOC_EVENT_INJECT_TIME_REQ_IND_V02 0x0028 +#define QMI_LOC_EVENT_INJECT_PREDICTED_ORBITS_REQ_IND_V02 0x0029 +#define QMI_LOC_EVENT_INJECT_POSITION_REQ_IND_V02 0x002A +#define QMI_LOC_EVENT_ENGINE_STATE_IND_V02 0x002B +#define QMI_LOC_EVENT_FIX_SESSION_STATE_IND_V02 0x002C +#define QMI_LOC_EVENT_WIFI_REQ_IND_V02 0x002D +#define QMI_LOC_EVENT_SENSOR_STREAMING_READY_STATUS_IND_V02 0x002E +#define QMI_LOC_EVENT_TIME_SYNC_REQ_IND_V02 0x002F +#define QMI_LOC_EVENT_SET_SPI_STREAMING_REPORT_IND_V02 0x0030 +#define QMI_LOC_EVENT_LOCATION_SERVER_CONNECTION_REQ_IND_V02 0x0031 +#define QMI_LOC_GET_SERVICE_REVISION_REQ_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_RESP_V02 0x0032 +#define QMI_LOC_GET_SERVICE_REVISION_IND_V02 0x0032 +#define QMI_LOC_GET_FIX_CRITERIA_REQ_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_RESP_V02 0x0033 +#define QMI_LOC_GET_FIX_CRITERIA_IND_V02 0x0033 +#define QMI_LOC_NI_USER_RESPONSE_REQ_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_RESP_V02 0x0034 +#define QMI_LOC_NI_USER_RESPONSE_IND_V02 0x0034 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_REQ_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_RESP_V02 0x0035 +#define QMI_LOC_INJECT_PREDICTED_ORBITS_DATA_IND_V02 0x0035 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_REQ_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_RESP_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_SOURCE_IND_V02 0x0036 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_REQ_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_RESP_V02 0x0037 +#define QMI_LOC_GET_PREDICTED_ORBITS_DATA_VALIDITY_IND_V02 0x0037 +#define QMI_LOC_INJECT_UTC_TIME_REQ_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_RESP_V02 0x0038 +#define QMI_LOC_INJECT_UTC_TIME_IND_V02 0x0038 +#define QMI_LOC_INJECT_POSITION_REQ_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_RESP_V02 0x0039 +#define QMI_LOC_INJECT_POSITION_IND_V02 0x0039 +#define QMI_LOC_SET_ENGINE_LOCK_REQ_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_RESP_V02 0x003A +#define QMI_LOC_SET_ENGINE_LOCK_IND_V02 0x003A +#define QMI_LOC_GET_ENGINE_LOCK_REQ_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_RESP_V02 0x003B +#define QMI_LOC_GET_ENGINE_LOCK_IND_V02 0x003B +#define QMI_LOC_SET_SBAS_CONFIG_REQ_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_RESP_V02 0x003C +#define QMI_LOC_SET_SBAS_CONFIG_IND_V02 0x003C +#define QMI_LOC_GET_SBAS_CONFIG_REQ_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_RESP_V02 0x003D +#define QMI_LOC_GET_SBAS_CONFIG_IND_V02 0x003D +#define QMI_LOC_SET_NMEA_TYPES_REQ_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_RESP_V02 0x003E +#define QMI_LOC_SET_NMEA_TYPES_IND_V02 0x003E +#define QMI_LOC_GET_NMEA_TYPES_REQ_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_RESP_V02 0x003F +#define QMI_LOC_GET_NMEA_TYPES_IND_V02 0x003F +#define QMI_LOC_SET_LOW_POWER_MODE_REQ_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_RESP_V02 0x0040 +#define QMI_LOC_SET_LOW_POWER_MODE_IND_V02 0x0040 +#define QMI_LOC_GET_LOW_POWER_MODE_REQ_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_RESP_V02 0x0041 +#define QMI_LOC_GET_LOW_POWER_MODE_IND_V02 0x0041 +#define QMI_LOC_SET_SERVER_REQ_V02 0x0042 +#define QMI_LOC_SET_SERVER_RESP_V02 0x0042 +#define QMI_LOC_SET_SERVER_IND_V02 0x0042 +#define QMI_LOC_GET_SERVER_REQ_V02 0x0043 +#define QMI_LOC_GET_SERVER_RESP_V02 0x0043 +#define QMI_LOC_GET_SERVER_IND_V02 0x0043 +#define QMI_LOC_DELETE_ASSIST_DATA_REQ_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_RESP_V02 0x0044 +#define QMI_LOC_DELETE_ASSIST_DATA_IND_V02 0x0044 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0045 +#define QMI_LOC_SET_XTRA_T_SESSION_CONTROL_IND_V02 0x0045 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_REQ_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_RESP_V02 0x0046 +#define QMI_LOC_GET_XTRA_T_SESSION_CONTROL_IND_V02 0x0046 +#define QMI_LOC_INJECT_WIFI_POSITION_REQ_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_RESP_V02 0x0047 +#define QMI_LOC_INJECT_WIFI_POSITION_IND_V02 0x0047 +#define QMI_LOC_NOTIFY_WIFI_STATUS_REQ_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_RESP_V02 0x0048 +#define QMI_LOC_NOTIFY_WIFI_STATUS_IND_V02 0x0048 +#define QMI_LOC_GET_REGISTERED_EVENTS_REQ_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_RESP_V02 0x0049 +#define QMI_LOC_GET_REGISTERED_EVENTS_IND_V02 0x0049 +#define QMI_LOC_SET_OPERATION_MODE_REQ_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_RESP_V02 0x004A +#define QMI_LOC_SET_OPERATION_MODE_IND_V02 0x004A +#define QMI_LOC_GET_OPERATION_MODE_REQ_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_RESP_V02 0x004B +#define QMI_LOC_GET_OPERATION_MODE_IND_V02 0x004B +#define QMI_LOC_SET_SPI_STATUS_REQ_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_RESP_V02 0x004C +#define QMI_LOC_SET_SPI_STATUS_IND_V02 0x004C +#define QMI_LOC_INJECT_SENSOR_DATA_REQ_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_RESP_V02 0x004D +#define QMI_LOC_INJECT_SENSOR_DATA_IND_V02 0x004D +#define QMI_LOC_INJECT_TIME_SYNC_DATA_REQ_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_RESP_V02 0x004E +#define QMI_LOC_INJECT_TIME_SYNC_DATA_IND_V02 0x004E +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_REQ_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_RESP_V02 0x004F +#define QMI_LOC_SET_CRADLE_MOUNT_CONFIG_IND_V02 0x004F +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_REQ_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_RESP_V02 0x0050 +#define QMI_LOC_GET_CRADLE_MOUNT_CONFIG_IND_V02 0x0050 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0051 +#define QMI_LOC_SET_EXTERNAL_POWER_CONFIG_IND_V02 0x0051 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_REQ_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_RESP_V02 0x0052 +#define QMI_LOC_GET_EXTERNAL_POWER_CONFIG_IND_V02 0x0052 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_REQ_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_RESP_V02 0x0053 +#define QMI_LOC_INFORM_LOCATION_SERVER_CONN_STATUS_IND_V02 0x0053 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0054 +#define QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0054 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_RESP_V02 0x0055 +#define QMI_LOC_GET_PROTOCOL_CONFIG_PARAMETERS_IND_V02 0x0055 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0056 +#define QMI_LOC_SET_SENSOR_CONTROL_CONFIG_IND_V02 0x0056 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_REQ_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_RESP_V02 0x0057 +#define QMI_LOC_GET_SENSOR_CONTROL_CONFIG_IND_V02 0x0057 +#define QMI_LOC_SET_SENSOR_PROPERTIES_REQ_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_RESP_V02 0x0058 +#define QMI_LOC_SET_SENSOR_PROPERTIES_IND_V02 0x0058 +#define QMI_LOC_GET_SENSOR_PROPERTIES_REQ_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_RESP_V02 0x0059 +#define QMI_LOC_GET_SENSOR_PROPERTIES_IND_V02 0x0059 +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005A +#define QMI_LOC_SET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005A +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_REQ_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_RESP_V02 0x005B +#define QMI_LOC_GET_SENSOR_PERFORMANCE_CONTROL_CONFIGURATION_IND_V02 0x005B +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_REQ_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_RESP_V02 0x005C +#define QMI_LOC_INJECT_SUPL_CERTIFICATE_IND_V02 0x005C +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_REQ_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_RESP_V02 0x005D +#define QMI_LOC_DELETE_SUPL_CERTIFICATE_IND_V02 0x005D +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005E +#define QMI_LOC_SET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005E +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_REQ_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_RESP_V02 0x005F +#define QMI_LOC_GET_POSITION_ENGINE_CONFIG_PARAMETERS_IND_V02 0x005F +#define QMI_LOC_EVENT_NI_GEOFENCE_NOTIFICATION_IND_V02 0x0060 +#define QMI_LOC_EVENT_GEOFENCE_GEN_ALERT_IND_V02 0x0061 +#define QMI_LOC_EVENT_GEOFENCE_BREACH_NOTIFICATION_IND_V02 0x0062 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_REQ_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_RESP_V02 0x0063 +#define QMI_LOC_ADD_CIRCULAR_GEOFENCE_IND_V02 0x0063 +#define QMI_LOC_DELETE_GEOFENCE_REQ_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_RESP_V02 0x0064 +#define QMI_LOC_DELETE_GEOFENCE_IND_V02 0x0064 +#define QMI_LOC_QUERY_GEOFENCE_REQ_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_RESP_V02 0x0065 +#define QMI_LOC_QUERY_GEOFENCE_IND_V02 0x0065 +#define QMI_LOC_EDIT_GEOFENCE_REQ_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_RESP_V02 0x0066 +#define QMI_LOC_EDIT_GEOFENCE_IND_V02 0x0066 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_REQ_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_RESP_V02 0x0067 +#define QMI_LOC_GET_BEST_AVAILABLE_POSITION_IND_V02 0x0067 +#define QMI_LOC_INJECT_MOTION_DATA_REQ_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_RESP_V02 0x0068 +#define QMI_LOC_INJECT_MOTION_DATA_IND_V02 0x0068 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_REQ_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_RESP_V02 0x0069 +#define QMI_LOC_GET_NI_GEOFENCE_ID_LIST_IND_V02 0x0069 +#define QMI_LOC_INJECT_GSM_CELL_INFO_REQ_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_RESP_V02 0x006A +#define QMI_LOC_INJECT_GSM_CELL_INFO_IND_V02 0x006A +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_REQ_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_RESP_V02 0x006B +#define QMI_LOC_INJECT_NETWORK_INITIATED_MESSAGE_IND_V02 0x006B +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_REQ_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_RESP_V02 0x006C +#define QMI_LOC_WWAN_OUT_OF_SERVICE_NOTIFICATION_IND_V02 0x006C +#define QMI_LOC_EVENT_PEDOMETER_CONTROL_IND_V02 0x006D +#define QMI_LOC_EVENT_MOTION_DATA_CONTROL_IND_V02 0x006E +#define QMI_LOC_PEDOMETER_REPORT_REQ_V02 0x006F +#define QMI_LOC_PEDOMETER_REPORT_RESP_V02 0x006F +#define QMI_LOC_PEDOMETER_REPORT_IND_V02 0x006F +/** + @} + */ + +/* Service Object Accessor */ +/** @addtogroup wms_qmi_accessor + @{ + */ +/** This function is used internally by the autogenerated code. Clients should use the + macro loc_get_service_object_v02( ) that takes in no arguments. */ +qmi_idl_service_object_type loc_get_service_object_internal_v02 + ( int32_t idl_maj_version, int32_t idl_min_version, int32_t library_version ); + +/** This macro should be used to get the service object */ +#define loc_get_service_object_v02( ) \ + loc_get_service_object_internal_v02( \ + LOC_V02_IDL_MAJOR_VERS, LOC_V02_IDL_MINOR_VERS, \ + LOC_V02_IDL_TOOL_VERS ) +/** + @} + */ + + +#ifdef __cplusplus +} +#endif +#endif + From e4f800932f55a36e792ec3cbb6420556919c061e Mon Sep 17 00:00:00 2001 From: Tushar Janefalkar Date: Wed, 31 Oct 2012 16:56:19 -0700 Subject: [PATCH 29/33] Add NULL checks for callbacks As a security measure, callbacks are checked to make sure they are not NULL pointers. Change-Id: I391e1cc373e8098449303709d8d1b67d305fb633 CRs-Fixed: 404438 --- loc_api/libloc_api_50001/loc.cpp | 7 +++- loc_api/libloc_api_50001/loc_eng.cpp | 44 +++++++++++++++-------- loc_api/libloc_api_50001/loc_eng_ni.cpp | 4 ++- loc_api/libloc_api_50001/loc_eng_xtra.cpp | 15 +++++--- 4 files changed, 49 insertions(+), 21 deletions(-) diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp index 8ac78625..8100a718 100755 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -317,7 +317,13 @@ SIDE EFFECTS ===========================================================================*/ static int loc_init(GpsCallbacks* callbacks) { + int retVal = -1; ENTRY_LOG(); + if(callbacks == NULL) { + LOC_LOGE("loc_init failed. cb = NULL\n"); + EXIT_LOG(%d, retVal); + return retVal; + } LOC_API_ADAPTER_EVENT_MASK_T event = LOC_API_ADAPTER_BIT_PARSED_POSITION_REPORT | LOC_API_ADAPTER_BIT_SATELLITE_REPORT | @@ -341,7 +347,6 @@ static int loc_init(GpsCallbacks* callbacks) gps_loc_cb = callbacks->location_cb; gps_sv_cb = callbacks->sv_status_cb; - int retVal = -1; if (loc_eng_ulp_inf == NULL) retVal = loc_eng_init(loc_afw_data, &clientCallbacks, event, NULL); diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 300fb21f..1b55f288 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -272,11 +272,13 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, void (*loc_external_msg_sender) (void*, void*)) { + int ret_val =-1; + ENTRY_LOG_CALLFLOW(); if (NULL == callbacks || 0 == event) { LOC_LOGE("loc_eng_init: bad parameters cb %p eMask %d", callbacks, event); - EXIT_LOG(%d, 0); - return NULL; + EXIT_LOG(%d, ret_val); + return ret_val; } STATE_CHECK((NULL == loc_eng_data.context), @@ -321,7 +323,6 @@ int loc_eng_init(loc_eng_data_s_type &loc_eng_data, LocCallbacks* callbacks, callbacks->location_ext_parser, callbacks->sv_ext_parser); loc_eng_data.client_handle = LocApiAdapter::getLocApiAdapter(locEngHandle); - int ret_val =-1; if (NULL == loc_eng_data.client_handle) { // drop the context and declare failure ((LocEngContext*)(loc_eng_data.context))->drop(); @@ -852,6 +853,11 @@ void loc_eng_agps_init(loc_eng_data_s_type &loc_eng_data, AGpsCallbacks* callbac STATE_CHECK((NULL == loc_eng_data.agps_status_cb), "agps instance already initialized", return); + if(callbacks == NULL) { + LOC_LOGE("loc_eng_agps_init: bad parameters cb %p", callbacks); + EXIT_LOG(%s, VOID_RET); + return; + } loc_eng_data.agps_status_cb = callbacks->status_cb; loc_eng_data.agnss_nif = new AgpsStateMachine(loc_eng_data.agps_status_cb, @@ -1875,15 +1881,15 @@ int loc_eng_ulp_init(loc_eng_data_s_type &loc_eng_data, const ulpInterface * loc { ENTRY_LOG(); int ret_val=-1; - - if(loc_eng_ulpInf != NULL) + if((loc_eng_ulpInf != NULL) && (((ulpInterface *)loc_eng_ulpInf)->init != NULL)) { // Initialize the ULP interface ((ulpInterface *)loc_eng_ulpInf)->init(loc_eng_data); loc_eng_data.ulp_initialized = TRUE; + ret_val = 0; } - ret_val = 0; -exit: + else + LOC_LOGE("ulp not initialized. NULL parameter"); EXIT_LOG(%d, ret_val); return ret_val; } @@ -2037,9 +2043,14 @@ SIDE EFFECTS ===========================================================================*/ int loc_eng_ulp_phone_context_init(loc_eng_data_s_type &loc_eng_data,UlpPhoneContextCallbacks *callback) { + int ret_val = -1; ENTRY_LOG(); - loc_eng_data.ulp_phone_context_req_cb = callback->ulp_request_phone_context_cb ; - int ret_val =0; + if(callback != NULL) { + loc_eng_data.ulp_phone_context_req_cb = callback->ulp_request_phone_context_cb ; + ret_val = 0; + } + else + LOC_LOGE("loc_eng_ulp_phone_context_init: bad parameters cb %p", callback); EXIT_LOG(%d, ret_val); return ret_val; } @@ -2063,11 +2074,16 @@ SIDE EFFECTS int loc_eng_ulp_network_init(loc_eng_data_s_type &loc_eng_data, UlpNetworkLocationCallbacks *callbacks) { - ENTRY_LOG_CALLFLOW(); - loc_eng_data.ulp_network_callback = callbacks->ulp_network_location_request_cb; - int ret_val =0; - EXIT_LOG(%d, ret_val); - return ret_val; + int ret_val = -1; + ENTRY_LOG_CALLFLOW(); + if(callbacks != NULL) { + loc_eng_data.ulp_network_callback = callbacks->ulp_network_location_request_cb; + ret_val = 0; + } + else + LOC_LOGE("loc_eng_ulp_network_init: bad parameters cb %p", callbacks); + EXIT_LOG(%d, ret_val); + return ret_val; } diff --git a/loc_api/libloc_api_50001/loc_eng_ni.cpp b/loc_api/libloc_api_50001/loc_eng_ni.cpp index c2d78af8..06a52a57 100644 --- a/loc_api/libloc_api_50001/loc_eng_ni.cpp +++ b/loc_api/libloc_api_50001/loc_eng_ni.cpp @@ -249,7 +249,9 @@ void loc_eng_ni_init(loc_eng_data_s_type &loc_eng_data, GpsNiCallbacks *callback { ENTRY_LOG_CALLFLOW(); - if (NULL == callbacks->notify_cb) { + if(callbacks == NULL) + EXIT_LOG(%s, "loc_eng_ni_init: failed, cb is NULL"); + else if (NULL == callbacks->notify_cb) { EXIT_LOG(%s, "loc_eng_ni_init: failed, no cb."); } else if (NULL != loc_eng_data.ni_notify_cb) { EXIT_LOG(%s, "loc_eng_ni_init: already inited."); diff --git a/loc_api/libloc_api_50001/loc_eng_xtra.cpp b/loc_api/libloc_api_50001/loc_eng_xtra.cpp index ebc7c6fb..01b805e7 100644 --- a/loc_api/libloc_api_50001/loc_eng_xtra.cpp +++ b/loc_api/libloc_api_50001/loc_eng_xtra.cpp @@ -54,12 +54,17 @@ SIDE EFFECTS int loc_eng_xtra_init (loc_eng_data_s_type &loc_eng_data, GpsXtraCallbacks* callbacks) { - loc_eng_xtra_data_s_type *xtra_module_data_ptr; + int ret_val = -1; + loc_eng_xtra_data_s_type *xtra_module_data_ptr; - xtra_module_data_ptr = &loc_eng_data.xtra_module_data; - xtra_module_data_ptr->download_request_cb = callbacks->download_request_cb; - - return 0; + if(callbacks == NULL) + LOC_LOGE("loc_eng_xtra_init: failed, cb is NULL"); + else { + xtra_module_data_ptr = &loc_eng_data.xtra_module_data; + xtra_module_data_ptr->download_request_cb = callbacks->download_request_cb; + ret_val = 0; + } + return ret_val; } /*=========================================================================== From 9fd717a6ae77ebdfa86c51ad156e8dda84c5042b Mon Sep 17 00:00:00 2001 From: Dante Russo Date: Wed, 24 Oct 2012 14:01:13 -0700 Subject: [PATCH 30/33] gps: do not lock mutex during loc_ioctl Locking the slot mutext during a loc_ioctl call can cause deadlock in some rare cases. Change-Id: I09aa2ad7c67c326fee90447db960895d7f1fb149 CRs-fixed: 412208 --- .../src/loc_api_sync_call.c | 67 +++++++++++++++++-- 1 file changed, 60 insertions(+), 7 deletions(-) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c index c488ff5d..09ae49b5 100644 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/loc_api_sync_call.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2011, Code Aurora Forum. All rights reserved. +/* Copyright (c) 2011-2012, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -259,8 +259,6 @@ static int loc_lock_a_slot() if (!slot->in_use && !slot->not_available) { select_id = i; - slot->in_use = 1; - slot->signal_sent = 0; /* Return from here and leave the mutex locked. * will unlock it in loc_unlock_slot() */ @@ -278,7 +276,7 @@ static int loc_lock_a_slot() FUNCTION loc_unlock_slot DESCRIPTION - Frees a buffer slot after the synchronous API call + Unlocks a buffer slot DEPENDENCIES N/A @@ -292,13 +290,58 @@ SIDE EFFECTS ===========================================================================*/ static void loc_unlock_slot(int select_id) { - loc_sync_data.slots[select_id].in_use = 0; - pthread_mutex_unlock(&loc_sync_data.slots[select_id].lock); } /*=========================================================================== +FUNCTION loc_lock_slot + +DESCRIPTION + Locks a specific slot that was previously locked from loc_lock_a_slot + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_lock_slot(int select_id) +{ + pthread_mutex_lock(&loc_sync_data.slots[select_id].lock); +} + +/*=========================================================================== + +FUNCTION loc_set_slot_in_use + +DESCRIPTION + Sets the in_use flag of slot to true or false. + Should be called only after the slot is locked + +DEPENDENCIES + N/A + +RETURN VALUE + None + +SIDE EFFECTS + N/A + +===========================================================================*/ +static void loc_set_slot_in_use(int select_id, boolean in_use) +{ + loc_sync_data.slots[select_id].in_use = in_use; + if (in_use == 1) + loc_sync_data.slots[select_id].signal_sent = 0; +} + +/*=========================================================================== + FUNCTION loc_api_save_callback DESCRIPTION @@ -399,7 +442,7 @@ static int loc_api_wait_callback( ) { int ret_val = RPC_LOC_API_SUCCESS; /* the return value of this function: 0 = no error */ - int rc; /* return code from pthread calls */ + int rc = 0; /* return code from pthread calls */ struct timespec expire_time; @@ -467,11 +510,20 @@ int loc_api_sync_ioctl return rc; } + loc_set_slot_in_use(select_id, 1); // set slot in use to true + // Select the callback we are waiting for loc_api_save_callback(select_id, handle, 0, ioctl_type); + loc_unlock_slot(select_id); // slot is unlocked, but in_use is still true + + // we want to avoid keeping the slot locked during the loc_ioctl because the rpc + // framework will also lock a different mutex during this call, and typically + // locking two different mutexes at the same time can lead to deadlock. rc = loc_ioctl(handle, ioctl_type, ioctl_data_ptr); + loc_lock_slot(select_id); + if (rc != RPC_LOC_API_SUCCESS) { ALOGE("loc_ioctl failed select_id = %d, ioctl_type %s, returned %s", @@ -502,6 +554,7 @@ int loc_api_sync_ioctl } /* wait callback */ } /* loc_ioctl */ + loc_set_slot_in_use(select_id, 0); // set slot in use to false loc_unlock_slot(select_id); return rc; From 63c5ac48c7d0b9245abd1a5e3ab45c3f331655d5 Mon Sep 17 00:00:00 2001 From: Tushar Janefalkar Date: Thu, 8 Nov 2012 11:41:43 -0800 Subject: [PATCH 31/33] Utility to identify target HW Earlier this identification was done in loc.cpp This change moves that to a separate utility. Also included is a change to not return a handle to the GPS interface if the target is found to be MPQ8064. CRs-Fixed: 418009 Change-Id: I98d5619d2e6e63711a9b56f0af2b3ddd27372871 --- loc_api/libloc_api_50001/loc.cpp | 81 +++++------------------ utils/Android.mk | 6 +- utils/loc_log.cpp | 30 ++++++++- utils/loc_log.h | 2 + utils/loc_target.cpp | 109 +++++++++++++++++++++++++++++++ utils/loc_target.h | 51 +++++++++++++++ 6 files changed, 210 insertions(+), 69 deletions(-) create mode 100644 utils/loc_target.cpp create mode 100644 utils/loc_target.h diff --git a/loc_api/libloc_api_50001/loc.cpp b/loc_api/libloc_api_50001/loc.cpp index 8100a718..add8aab8 100755 --- a/loc_api/libloc_api_50001/loc.cpp +++ b/loc_api/libloc_api_50001/loc.cpp @@ -32,10 +32,10 @@ #include #include +#include #include #include #include - #include #include #include @@ -167,65 +167,6 @@ static const UlpPhoneContextInterface sLocEngUlpPhoneContextInterface = static loc_eng_data_s_type loc_afw_data; static int gss_fd = 0; -#define TARGET_NAME_OTHER 0 -#define TARGET_NAME_APQ8064_STANDALONE 1 -#define TARGET_NAME_APQ8064_FUSION3 2 - -static int read_a_line(const char * file_path, char * line, int line_size) -{ - FILE *fp; - int result = 0; - - * line = '\0'; - fp = fopen(file_path, "r" ); - if( fp == NULL ) { - LOC_LOGE("open failed: %s: %s\n", file_path, strerror(errno)); - result = -1; - } else { - int len; - fgets(line, line_size, fp); - len = strlen(line); - len = len < line_size - 1? len : line_size - 1; - line[len] = '\0'; - LOC_LOGD("cat %s: %s", file_path, line); - fclose(fp); - } - return result; -} - -#define LINE_LEN 100 -#define STR_LIQUID "Liquid" -#define STR_SURF "Surf" -#define STRLEN_LIQUID (sizeof(STR_LIQUID) - 1) -#define STRLEN_SURF (sizeof(STR_SURF) - 1) -#define IS_STR_END(c) ((c) == '\0' || (c) == '\n' || (c) == '\r') - -static int get_target_name(void) -{ - int target_name = TARGET_NAME_OTHER; - - char hw_platform[] = "/sys/devices/system/soc/soc0/hw_platform"; // "Liquid" or "Surf" - char id[] = "/sys/devices/system/soc/soc0/id"; //109 - char mdm[] = "/dev/mdm"; // No such file or directory - - char line[LINE_LEN]; - - read_a_line( hw_platform, line, LINE_LEN); - if(( !memcmp(line, STR_LIQUID, STRLEN_LIQUID) && IS_STR_END(line[STRLEN_LIQUID]) ) || - ( !memcmp(line, STR_SURF, STRLEN_SURF) && IS_STR_END(line[STRLEN_SURF]) ) - ) { - if (!read_a_line( mdm, line, LINE_LEN)) { - target_name = TARGET_NAME_APQ8064_FUSION3; - } else { - read_a_line( id, line, LINE_LEN); - if(!strncmp(line, "109", strlen("109")) || !strncmp(line, "153", strlen("153"))) { - target_name = TARGET_NAME_APQ8064_STANDALONE; - } - } - } - return target_name; -} - /*=========================================================================== FUNCTION gps_get_hardware_interface @@ -267,22 +208,30 @@ const GpsInterface* gps_get_hardware_interface () // for gps.c extern "C" const GpsInterface* get_gps_interface() { + targetEnumType target = TARGET_OTHER; loc_eng_read_config(); //We load up libulp module at this point itself if ULP configured to be On if(gps_conf.CAPABILITIES & ULP_CAPABILITY) { loc_eng_ulp_inf = loc_eng_get_ulp_inf(); } - if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) - { + target = get_target(); + LOC_LOGD("Target name check returned %s", loc_get_target_name(target)); + //APQ8064 + if(target == TARGET_APQ8064_STANDALONE) { gps_conf.CAPABILITIES &= ~(GPS_CAPABILITY_MSA | GPS_CAPABILITY_MSB); gss_fd = open("/dev/gss", O_RDONLY); - if (gss_fd < 0) { + if (gss_fd < 0) LOC_LOGE("GSS open failed: %s\n", strerror(errno)); + else { + LOC_LOGD("GSS open success! CAPABILITIES %0lx\n", gps_conf.CAPABILITIES); } - LOC_LOGD("GSS open success! CAPABILITIES %0x\n", gps_conf.CAPABILITIES); } - + //MPQ8064 + else if(target == TARGET_MPQ8064) { + LOC_LOGE("No GPS HW on this target (MPQ8064). Not returning interface"); + return NULL; + } return &sLocEngInterface; } @@ -383,7 +332,7 @@ static void loc_cleanup() gps_sv_cb = NULL; /* - * if (get_target_name() == TARGET_NAME_APQ8064_STANDALONE) + * if (get_target() == TARGET_NAME_APQ8064_STANDALONE) * { * close(gss_fd); * LOC_LOGD("GSS shutdown.\n"); diff --git a/utils/Android.mk b/utils/Android.mk index 4bf04014..7dc1799e 100644 --- a/utils/Android.mk +++ b/utils/Android.mk @@ -15,7 +15,8 @@ LOCAL_SRC_FILES += \ loc_log.cpp \ loc_cfg.cpp \ msg_q.c \ - linked_list.c + linked_list.c \ + loc_target.cpp LOCAL_CFLAGS += \ -fno-short-enums \ @@ -32,7 +33,8 @@ LOCAL_COPY_HEADERS:= \ loc_cfg.h \ log_util.h \ linked_list.h \ - msg_q.h + msg_q.h \ + loc_target.h LOCAL_MODULE := libgps.utils diff --git a/utils/loc_log.cpp b/utils/loc_log.cpp index e4fb76c4..1b4ecee0 100644 --- a/utils/loc_log.cpp +++ b/utils/loc_log.cpp @@ -34,7 +34,6 @@ #include #include "loc_log.h" #include "msg_q.h" - #include "log_util.h" // Logging Improvements @@ -100,6 +99,35 @@ const char* log_succ_fail_string(int is_succ) return is_succ? "successful" : "failed"; } +//Target names +loc_name_val_s_type target_name[] = +{ + NAME_VAL(TARGET_OTHER), + NAME_VAL(TARGET_APQ8064_STANDALONE), + NAME_VAL(TARGET_APQ8064_FUSION3), + NAME_VAL(TARGET_MPQ8064), + NAME_VAL(TARGET_MSM8930) +}; + +static int target_name_num = sizeof(target_name)/sizeof(loc_name_val_s_type); + +/*=========================================================================== + +FUNCTION loc_get_target_name + +DESCRIPTION + Returns pointer to a string that contains name of the target + + XX:XX:XX.000\0 + +RETURN VALUE + The target name string + +===========================================================================*/ +const char *loc_get_target_name(targetEnumType target) +{ + return loc_get_name_from_val(target_name, target_name_num, (long)target); +} /*=========================================================================== diff --git a/utils/loc_log.h b/utils/loc_log.h index 8b071a48..cb8e1d5b 100644 --- a/utils/loc_log.h +++ b/utils/loc_log.h @@ -36,6 +36,7 @@ extern "C" #endif #include +#include "loc_target.h" typedef struct { @@ -54,6 +55,7 @@ typedef struct const char* loc_get_name_from_mask(loc_name_val_s_type table[], int table_size, long mask); const char* loc_get_name_from_val(loc_name_val_s_type table[], int table_size, long value); const char* loc_get_msg_q_status(int status); +const char* loc_get_target_name(targetEnumType target); extern const char* log_succ_fail_string(int is_succ); diff --git a/utils/loc_target.cpp b/utils/loc_target.cpp new file mode 100644 index 00000000..06b2a377 --- /dev/null +++ b/utils/loc_target.cpp @@ -0,0 +1,109 @@ +/* Copyright (c) 2012, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include "loc_target.h" +#include "loc_log.h" +#include "log_util.h" + +#define APQ8064_ID_1 "109" +#define APQ8064_ID_2 "153" +#define MPQ8064_ID_1 "130" +#define MSM8930_ID_1 "142" +#define MSM8930_ID_2 "116" + +#define LINE_LEN 100 +#define STR_LIQUID "Liquid" +#define STR_SURF "Surf" +#define IS_STR_END(c) ((c) == '\0' || (c) == '\n' || (c) == '\r') +#define LENGTH(s) (sizeof(s) - 1) +#define GPS_CHECK_NO_ERROR 0 +#define GPS_CHECK_NO_GPS_HW 1 + +static int gss_fd = 0; + +static int read_a_line(const char * file_path, char * line, int line_size) +{ + FILE *fp; + int result = 0; + + * line = '\0'; + fp = fopen(file_path, "r" ); + if( fp == NULL ) { + LOC_LOGE("open failed: %s: %s\n", file_path, strerror(errno)); + result = -1; + } else { + int len; + fgets(line, line_size, fp); + len = strlen(line); + len = len < line_size - 1? len : line_size - 1; + line[len] = '\0'; + LOC_LOGD("cat %s: %s", file_path, line); + fclose(fp); + } + return result; +} + +targetEnumType get_target(void) +{ + targetEnumType target = TARGET_OTHER; + + char hw_platform[] = "/sys/devices/system/soc/soc0/hw_platform"; + char id[] = "/sys/devices/system/soc/soc0/id"; + char mdm[] = "/dev/mdm"; // No such file or directory + + char rd_hw_platform[LINE_LEN]; + char rd_id[LINE_LEN]; + char rd_mdm[LINE_LEN]; + + read_a_line(hw_platform, rd_hw_platform, LINE_LEN); + read_a_line( id, rd_id, LINE_LEN); + + if( (!memcmp(rd_hw_platform, STR_LIQUID, LENGTH(STR_LIQUID)) && IS_STR_END(rd_hw_platform[LENGTH(STR_LIQUID)])) || + (!memcmp(rd_hw_platform, STR_SURF, LENGTH(STR_SURF)) && IS_STR_END(rd_hw_platform[LENGTH(STR_SURF)])) ) { + if (!read_a_line( mdm, rd_mdm, LINE_LEN)) + target = TARGET_APQ8064_FUSION3; + else if( (!memcmp(rd_id, APQ8064_ID_1, LENGTH(APQ8064_ID_1)) && IS_STR_END(rd_id[LENGTH(APQ8064_ID_1)])) || + (!memcmp(rd_id, APQ8064_ID_2, LENGTH(APQ8064_ID_2)) && IS_STR_END(rd_id[LENGTH(APQ8064_ID_2)])) ) + target = TARGET_APQ8064_STANDALONE; + } + else if( !memcmp(rd_id, MPQ8064_ID_1, LENGTH(MPQ8064_ID_1)) && IS_STR_END(rd_id[LENGTH(MPQ8064_ID_1)]) ) + target = TARGET_MPQ8064; + else if( (!memcmp(rd_id, MSM8930_ID_1, LENGTH(MSM8930_ID_1)) && IS_STR_END(rd_id[LENGTH(MSM8930_ID_1)])) || + (!memcmp(rd_id, MSM8930_ID_2, LENGTH(MSM8930_ID_2)) && IS_STR_END(rd_id[LENGTH(MSM8930_ID_2)])) ) + target = TARGET_MSM8930; + return target; +} diff --git a/utils/loc_target.h b/utils/loc_target.h new file mode 100644 index 00000000..1e633902 --- /dev/null +++ b/utils/loc_target.h @@ -0,0 +1,51 @@ +/* Copyright (c) 2012, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Code Aurora Forum, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef LOC_TARGET_H +#define LOC_TARGET_H + +#ifdef __cplusplus +extern "C" +{ +#endif + +typedef enum { + TARGET_OTHER = 0, + TARGET_APQ8064_STANDALONE, + TARGET_APQ8064_FUSION3, + TARGET_MPQ8064, + TARGET_MSM8930 +}targetEnumType; + +targetEnumType get_target(void); + +#ifdef __cplusplus +} +#endif + +#endif /*LOC_TARGET_H*/ From 8e9cb2338608a56bf678a9c75bc7d7edd92807c3 Mon Sep 17 00:00:00 2001 From: Neethu Joseph Date: Thu, 15 Nov 2012 12:06:07 -0800 Subject: [PATCH 32/33] Loc_Api: Support A-GLONASS Position protocol Support to read A-GLONASS Prosition protocol from gps.conf Change-Id: If91d6754aaee73c1360728793f4cc2ef1f015fe7 CRs-fixed: 378515 --- loc_api/libloc_api_50001/LocApiAdapter.h | 3 ++ loc_api/libloc_api_50001/loc_eng.cpp | 16 ++++++++++ loc_api/libloc_api_50001/loc_eng.h | 1 + loc_api/libloc_api_50001/loc_eng_log.cpp | 3 +- loc_api/libloc_api_50001/loc_eng_msg.h | 10 ++++++ loc_api/libloc_api_50001/loc_eng_msg_id.h | 3 ++ loc_api/loc_api_v02/LocApiV02Adapter.cpp | 39 +++++++++++++++++++++++ loc_api/loc_api_v02/LocApiV02Adapter.h | 1 + 8 files changed, 75 insertions(+), 1 deletion(-) mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng.h mode change 100644 => 100755 loc_api/libloc_api_50001/loc_eng_log.cpp mode change 100644 => 100755 loc_api/loc_api_v02/LocApiV02Adapter.h diff --git a/loc_api/libloc_api_50001/LocApiAdapter.h b/loc_api/libloc_api_50001/LocApiAdapter.h index ec53805e..a876b0aa 100755 --- a/loc_api/libloc_api_50001/LocApiAdapter.h +++ b/loc_api/libloc_api_50001/LocApiAdapter.h @@ -216,6 +216,9 @@ public: inline virtual enum loc_api_adapter_err setExtPowerConfig(int isBatteryCharging) {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} + inline virtual enum loc_api_adapter_err + setAGLONASSProtocol(unsigned long aGlonassProtocol) + {LOC_LOGW("%s: default implementation invoked", __func__); return LOC_API_ADAPTER_ERR_SUCCESS;} inline const LocPosMode& getPositionMode() const {return fixCriteria;} diff --git a/loc_api/libloc_api_50001/loc_eng.cpp b/loc_api/libloc_api_50001/loc_eng.cpp index 1b55f288..da464af0 100755 --- a/loc_api/libloc_api_50001/loc_eng.cpp +++ b/loc_api/libloc_api_50001/loc_eng.cpp @@ -105,6 +105,7 @@ static loc_param_s_type loc_parameter_table[] = {"SENSOR_ALGORITHM_CONFIG_MASK", &gps_conf.SENSOR_ALGORITHM_CONFIG_MASK, NULL, 'n'}, {"QUIPC_ENABLED", &gps_conf.QUIPC_ENABLED, NULL, 'n'}, {"LPP_PROFILE", &gps_conf.LPP_PROFILE, NULL, 'n'}, + {"A_GLONASS_POS_PROTOCOL_SELECT", &gps_conf.A_GLONASS_POS_PROTOCOL_SELECT, NULL, 'n'}, }; static void loc_default_parameters(void) @@ -145,6 +146,9 @@ static void loc_default_parameters(void) /* LTE Positioning Profile configuration is disable by default*/ gps_conf.LPP_PROFILE = 0; + + /*By default no positioning protocol is selected on A-GLONASS system*/ + gps_conf.A_GLONASS_POS_PROTOCOL_SELECT = 0; } LocEngContext::LocEngContext(gps_create_thread threadCreator) : @@ -367,6 +371,11 @@ static int loc_eng_reinit(loc_eng_data_s_type &loc_eng_data) msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, sensor_control_config_msg, loc_eng_free_msg); + loc_eng_msg_a_glonass_protocol *a_glonass_protocol_msg(new loc_eng_msg_a_glonass_protocol(&loc_eng_data, + gps_conf.A_GLONASS_POS_PROTOCOL_SELECT)); + msg_q_snd((void*)((LocEngContext*)(loc_eng_data.context))->deferred_q, + a_glonass_protocol_msg, loc_eng_free_msg); + /* Make sure at least one of the sensor property is specified by the user in the gps.conf file. */ if( gps_conf.GYRO_BIAS_RANDOM_WALK_VALID || gps_conf.ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID || @@ -1430,6 +1439,13 @@ static void loc_eng_deferred_action_thread(void* arg) } break; + case LOC_ENG_MSG_A_GLONASS_PROTOCOL: + { + loc_eng_msg_a_glonass_protocol *svMsg = (loc_eng_msg_a_glonass_protocol*)msg; + loc_eng_data_p->client_handle->setAGLONASSProtocol(svMsg->a_glonass_protocol); + } + break; + case LOC_ENG_MSG_SUPL_VERSION: { loc_eng_msg_suple_version *svMsg = (loc_eng_msg_suple_version*)msg; diff --git a/loc_api/libloc_api_50001/loc_eng.h b/loc_api/libloc_api_50001/loc_eng.h old mode 100644 new mode 100755 index 646d1716..16ab1d7e --- a/loc_api/libloc_api_50001/loc_eng.h +++ b/loc_api/libloc_api_50001/loc_eng.h @@ -180,6 +180,7 @@ typedef struct loc_gps_cfg_s unsigned long QUIPC_ENABLED; unsigned long LPP_PROFILE; unsigned long SENSOR_ALGORITHM_CONFIG_MASK; + unsigned long A_GLONASS_POS_PROTOCOL_SELECT; uint8_t ACCEL_RANDOM_WALK_SPECTRAL_DENSITY_VALID; double ACCEL_RANDOM_WALK_SPECTRAL_DENSITY; uint8_t ANGLE_RANDOM_WALK_SPECTRAL_DENSITY_VALID; diff --git a/loc_api/libloc_api_50001/loc_eng_log.cpp b/loc_api/libloc_api_50001/loc_eng_log.cpp old mode 100644 new mode 100755 index 843f558f..e324ca72 --- a/loc_api/libloc_api_50001/loc_eng_log.cpp +++ b/loc_api/libloc_api_50001/loc_eng_log.cpp @@ -104,7 +104,8 @@ static loc_name_val_s_type loc_eng_msgs[] = NAME_VAL( ULP_MSG_INJECT_NETWORK_POSITION ), NAME_VAL( ULP_MSG_REPORT_QUIPC_POSITION ), NAME_VAL( ULP_MSG_REQUEST_COARSE_POSITION ), - NAME_VAL( LOC_ENG_MSG_LPP_CONFIG ) + NAME_VAL( LOC_ENG_MSG_LPP_CONFIG ), + NAME_VAL( LOC_ENG_MSG_A_GLONASS_PROTOCOL ) }; static int loc_eng_msgs_num = sizeof(loc_eng_msgs) / sizeof(loc_name_val_s_type); diff --git a/loc_api/libloc_api_50001/loc_eng_msg.h b/loc_api/libloc_api_50001/loc_eng_msg.h index 9c5c03bd..62bc3543 100755 --- a/loc_api/libloc_api_50001/loc_eng_msg.h +++ b/loc_api/libloc_api_50001/loc_eng_msg.h @@ -158,6 +158,16 @@ struct loc_eng_msg { } }; +struct loc_eng_msg_a_glonass_protocol : public loc_eng_msg { + const unsigned long a_glonass_protocol; + inline loc_eng_msg_a_glonass_protocol(void* instance, unsigned long protocol) : + loc_eng_msg(instance, LOC_ENG_MSG_A_GLONASS_PROTOCOL), + a_glonass_protocol(protocol) + { + LOC_LOGV("A-GLONASS protocol: 0x%lx", protocol); + } +}; + struct loc_eng_msg_suple_version : public loc_eng_msg { const int supl_version; inline loc_eng_msg_suple_version(void* instance, int version) : diff --git a/loc_api/libloc_api_50001/loc_eng_msg_id.h b/loc_api/libloc_api_50001/loc_eng_msg_id.h index 0761b89d..17064699 100755 --- a/loc_api/libloc_api_50001/loc_eng_msg_id.h +++ b/loc_api/libloc_api_50001/loc_eng_msg_id.h @@ -128,6 +128,9 @@ enum loc_eng_msg_ids_t { // Message is sent by Android framework (GpsLocationProvider) // to inject the raw command ULP_MSG_INJECT_RAW_COMMAND, + + /* Message is sent by HAL to LOC API to select A-GLONASS protocol */ + LOC_ENG_MSG_A_GLONASS_PROTOCOL, }; #ifdef __cplusplus diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 4c7b7124..4203ffb8 100755 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -1441,6 +1441,45 @@ enum loc_api_adapter_err LocApiV02Adapter :: setExtPowerConfig(int isBatteryChar return LOC_API_ADAPTER_ERR_SUCCESS; } +/* set the Positioning Protocol on A-GLONASS system */ +enum loc_api_adapter_err LocApiV02Adapter :: setAGLONASSProtocol(unsigned long aGlonassProtocol) +{ + locClientStatusEnumType result = eLOC_CLIENT_SUCCESS; + locClientReqUnionType req_union; + qmiLocSetProtocolConfigParametersReqMsgT_v02 aGlonassProtocol_req; + qmiLocSetProtocolConfigParametersIndMsgT_v02 aGlonassProtocol_ind; + + memset(&aGlonassProtocol_req, 0, sizeof(aGlonassProtocol_req)); + memset(&aGlonassProtocol_ind, 0, sizeof(aGlonassProtocol_ind)); + + aGlonassProtocol_req.assistedGlonassProtocolMask_valid = 1; + aGlonassProtocol_req.assistedGlonassProtocolMask = aGlonassProtocol; + + req_union.pSetProtocolConfigParametersReq = &aGlonassProtocol_req; + + LOC_LOGD("%s:%d]: aGlonassProtocolMask = 0x%lx\n", __func__, __LINE__, + aGlonassProtocol_req.assistedGlonassProtocolMask); + + result = loc_sync_send_req(clientHandle, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_REQ_V02, + req_union, LOC_ENGINE_SYNC_REQUEST_TIMEOUT, + QMI_LOC_SET_PROTOCOL_CONFIG_PARAMETERS_IND_V02, + &aGlonassProtocol_ind); + + if(result != eLOC_CLIENT_SUCCESS || + eQMI_LOC_SUCCESS_V02 != aGlonassProtocol_ind.status) + { + LOC_LOGE ("%s:%d]: Error status = %s, ind..status = %s ", + __func__, __LINE__, + loc_get_v02_client_status_name(result), + loc_get_v02_qmi_status_name(aGlonassProtocol_ind.status)); + + return LOC_API_ADAPTER_ERR_GENERAL_FAILURE; + } + return LOC_API_ADAPTER_ERR_SUCCESS; +} + + /* Convert event mask from loc eng to loc_api_v02 format */ locClientEventMaskType LocApiV02Adapter :: convertMask( LOC_API_ADAPTER_EVENT_MASK_T mask) diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.h b/loc_api/loc_api_v02/LocApiV02Adapter.h old mode 100644 new mode 100755 index 60c2a5ce..e6441db9 --- a/loc_api/loc_api_v02/LocApiV02Adapter.h +++ b/loc_api/loc_api_v02/LocApiV02Adapter.h @@ -161,6 +161,7 @@ public: int accelSamplesPerBatchHigh, int accelBatchesPerSecHigh, int gyroSamplesPerBatchHigh, int gyroBatchesPerSecHigh, int algorithmConfig); virtual enum loc_api_adapter_err setExtPowerConfig(int isBatteryCharging); + virtual enum loc_api_adapter_err setAGLONASSProtocol(unsigned long aGlonassProtocol); }; #endif //LOC_API_V_0_2_ADAPTER_H From e065604f303d2e0a7cac3e97572a70d04cc21657 Mon Sep 17 00:00:00 2001 From: Kevin Tang Date: Fri, 21 Sep 2012 16:56:18 -0700 Subject: [PATCH 33/33] OTDOA support (must have CR 370306 as dependency) CRs-Fixed: 402746 Change-Id: I505becab45f643b352e8ff3aeb242b15b623cb7b --- .../libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp | 1 + loc_api/libloc_api_50001/loc.h | 3 ++- loc_api/libloc_api_50001/loc_eng_log.cpp | 3 ++- loc_api/loc_api_v02/LocApiV02Adapter.cpp | 4 ++++ 4 files changed, 9 insertions(+), 2 deletions(-) diff --git a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp index a20820e8..5108780e 100644 --- a/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp +++ b/loc_api/libloc_api-rpc-50001/libloc_api-rpc-glue/src/LocApiRpcAdapter.cpp @@ -332,6 +332,7 @@ LocApiRpcAdapter::setPositionMode(const LocPosMode *posMode) op_mode = RPC_LOC_OPER_MODE_DATA_OPTIMAL; break; case LOC_POSITION_MODE_RESERVED_4: + case LOC_POSITION_MODE_RESERVED_5: op_mode = RPC_LOC_OPER_MODE_MSA; fix_criteria_ptr->preferred_response_time = 0; break; diff --git a/loc_api/libloc_api_50001/loc.h b/loc_api/libloc_api_50001/loc.h index b823e476..b1eee671 100755 --- a/loc_api/libloc_api_50001/loc.h +++ b/loc_api/libloc_api_50001/loc.h @@ -54,7 +54,8 @@ typedef enum loc_position_mode_type { LOC_POSITION_MODE_RESERVED_1, LOC_POSITION_MODE_RESERVED_2, LOC_POSITION_MODE_RESERVED_3, - LOC_POSITION_MODE_RESERVED_4 + LOC_POSITION_MODE_RESERVED_4, + LOC_POSITION_MODE_RESERVED_5 } LocPositionMode; typedef void (*loc_location_cb_ext) (GpsLocation* location, void* locExt); diff --git a/loc_api/libloc_api_50001/loc_eng_log.cpp b/loc_api/libloc_api_50001/loc_eng_log.cpp index 843f558f..53548228 100644 --- a/loc_api/libloc_api_50001/loc_eng_log.cpp +++ b/loc_api/libloc_api_50001/loc_eng_log.cpp @@ -124,7 +124,8 @@ static loc_name_val_s_type loc_eng_position_modes[] = NAME_VAL( LOC_POSITION_MODE_RESERVED_1 ), NAME_VAL( LOC_POSITION_MODE_RESERVED_2 ), NAME_VAL( LOC_POSITION_MODE_RESERVED_3 ), - NAME_VAL( LOC_POSITION_MODE_RESERVED_4 ) + NAME_VAL( LOC_POSITION_MODE_RESERVED_4 ), + NAME_VAL( LOC_POSITION_MODE_RESERVED_5 ) }; static int loc_eng_position_mode_num = sizeof(loc_eng_position_modes) / sizeof(loc_name_val_s_type); diff --git a/loc_api/loc_api_v02/LocApiV02Adapter.cpp b/loc_api/loc_api_v02/LocApiV02Adapter.cpp index 4c7b7124..046ef3b1 100755 --- a/loc_api/loc_api_v02/LocApiV02Adapter.cpp +++ b/loc_api/loc_api_v02/LocApiV02Adapter.cpp @@ -250,6 +250,10 @@ enum loc_api_adapter_err LocApiV02Adapter :: startFix() set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_CELL_ID_V02; break; + case LOC_POSITION_MODE_RESERVED_5: + set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_WWAN_V02; + break; + default: set_mode_msg.operationMode = eQMI_LOC_OPER_MODE_STANDALONE_V02; break;