blob: 9fd71aef2a19d4692905533e9e0bb7288a0d3c65 [file] [log] [blame]
Wyatt Riley4d3c8e22017-11-07 17:39:29 -08001/*
2 * Copyright (C) 2017 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package android.hardware.gnss@1.1;
18
19import @1.0::IGnssCallback;
20
21/**
22 * The interface is required for the HAL to communicate certain information
23 * like status and location info back to the platform, the platform implements
24 * the interfaces and passes a handle to the HAL.
25 */
26interface IGnssCallback extends @1.0::IGnssCallback {
27 /**
28 * Callback to inform framework of the GNSS HAL implementation model & version name.
29 *
30 * This is a user-visible string that identifies the model and version of the GNSS HAL.
31 * For example "ABC Co., Baseband Part 1234, RF Part 567, Software version 3.14.159"
32 *
33 * This must be called in response to IGnss::setCallback
34 *
35 * @param name String providing the name of the GNSS HAL implementation
36 */
37 gnssNameCb(string name);
Yu-Han Yang90a35dc2018-01-22 15:54:51 -080038
39 /**
40 * Callback for requesting Location.
41 *
42 * HAL implementation shall call this when it wants the framework to provide location to assist
43 * with GNSS HAL operation. For example, to assist with time to first fix, and/or error
44 * recovery, it may ask for a location that is independent from GNSS (e.g. from the "network"
45 * LocationProvier), or to provide a Device-Based-Hybrid location to supplement A-GPS/GNSS
46 * emergency call flows managed by the GNSS HAL.
47 *
48 * @param independentFromGnss True if requesting a location that is independent from GNSS.
49 */
50 gnssRequestLocationCb(bool independentFromGnss);
Wyatt Riley4d3c8e22017-11-07 17:39:29 -080051};