summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--radio/1.3/Android.bp4
-rw-r--r--radio/1.3/IRadio.hal43
-rw-r--r--radio/1.3/IRadioIndication.hal53
-rw-r--r--radio/1.3/IRadioResponse.hal74
-rw-r--r--radio/1.3/types.hal57
5 files changed, 231 insertions, 0 deletions
diff --git a/radio/1.3/Android.bp b/radio/1.3/Android.bp
index 3c7b5c5a..042df6c5 100644
--- a/radio/1.3/Android.bp
+++ b/radio/1.3/Android.bp
@@ -9,6 +9,8 @@ hidl_interface {
9 srcs: [ 9 srcs: [
10 "types.hal", 10 "types.hal",
11 "IRadio.hal", 11 "IRadio.hal",
12 "IRadioIndication.hal",
13 "IRadioResponse.hal",
12 ], 14 ],
13 interfaces: [ 15 interfaces: [
14 "android.hardware.radio@1.0", 16 "android.hardware.radio@1.0",
@@ -18,6 +20,8 @@ hidl_interface {
18 ], 20 ],
19 types: [ 21 types: [
20 "AccessNetwork", 22 "AccessNetwork",
23 "EmergencyNumber",
24 "EmergencyServiceCategory",
21 ], 25 ],
22 gen_java: true, 26 gen_java: true,
23} 27}
diff --git a/radio/1.3/IRadio.hal b/radio/1.3/IRadio.hal
index 16e66844..480a61fb 100644
--- a/radio/1.3/IRadio.hal
+++ b/radio/1.3/IRadio.hal
@@ -17,9 +17,11 @@
17package android.hardware.radio@1.3; 17package android.hardware.radio@1.3;
18 18
19import @1.0::DataProfileInfo; 19import @1.0::DataProfileInfo;
20import @1.0::Dial;
20import @1.2::DataRequestReason; 21import @1.2::DataRequestReason;
21import @1.2::IRadio; 22import @1.2::IRadio;
22import @1.3::AccessNetwork; 23import @1.3::AccessNetwork;
24import @1.3::EmergencyServiceCategory;
23 25
24/** 26/**
25 * This interface is used by telephony and telecom to talk to cellular radio. 27 * This interface is used by telephony and telecom to talk to cellular radio.
@@ -82,4 +84,45 @@ interface IRadio extends @1.2::IRadio {
82 oneway setupDataCall_1_3(int32_t serial, AccessNetwork accessNetwork, 84 oneway setupDataCall_1_3(int32_t serial, AccessNetwork accessNetwork,
83 DataProfileInfo dataProfileInfo, bool modemCognitive, bool roamingAllowed, 85 DataProfileInfo dataProfileInfo, bool modemCognitive, bool roamingAllowed,
84 bool isRoaming, DataRequestReason reason, vec<string> addresses, vec<string> dnses); 86 bool isRoaming, DataRequestReason reason, vec<string> addresses, vec<string> dnses);
87
88 /**
89 * Request the current emergency number list.
90 *
91 * Each emergency number (@1.3::EmergencyNumber) in the emergency number list contains a
92 * dialing number, one or more service category(s), and mobile country code.
93 *
94 * Radio must collect all sources of the emergency number to build the response.
95 * For example, network operator signals, sim card information, modem configuration, OEM
96 * configuration (for example, OEM system properties), always-available emergency numbers and
97 * sim-absence emergency numbers, etc.
98 *
99 * 112, 911 are always available. Besides, 000, 08, 110, 999, 118 and 119 should be available
100 * when sim is not present.
101 *
102 * Please refer the document of @1.3::EmergencyNumber to construct each emergency number to be
103 * returned.
104 *
105 * Reference: 3GPP TS 22.101 version 9.1.0 Release 9
106 *
107 * @param serial Serial number of request.
108 *
109 * Response function is IRadioResponse.getCurrentEmergencyNumberListResponse()
110 */
111 oneway getCurrentEmergencyNumberList(int32_t serial);
112
113 /**
114 * Initiate emergency voice call, with one or more emergency service category(s).
115 *
116 * Note this API is the same as IRadio.dial except using the
117 * @1.3::EmergencyServiceCategory as the input param.
118 *
119 * @param serial Serial number of request.
120 * @param dialInfo the same @1.0::Dial information used by @1.0::IRadio.dial.
121 * @param categories bitfield<@1.3::EmergencyServiceCategory> the Emergency Service Category(s)
122 * of the call.
123 *
124 * Response function is IRadioResponse.emergencyDialResponse()
125 */
126 oneway emergencyDial(int32_t serial, Dial dialInfo,
127 bitfield<EmergencyServiceCategory> categories);
85}; 128};
diff --git a/radio/1.3/IRadioIndication.hal b/radio/1.3/IRadioIndication.hal
new file mode 100644
index 00000000..c80e7626
--- /dev/null
+++ b/radio/1.3/IRadioIndication.hal
@@ -0,0 +1,53 @@
1/*
2 * Copyright (C) 2018 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.radio@1.3;
18
19import @1.0::RadioIndicationType;
20import @1.2::IRadioIndication;
21
22/**
23 * Interface declaring unsolicited radio indications.
24 */
25interface IRadioIndication extends @1.2::IRadioIndication {
26 /**
27 * Indicate and update all of the current Emergency Number information known to the radio,
28 * when any of the Emergency Number sources (For example, network operator signals, sim card
29 * information, modem configuration, OEM configuration or system properties, etc.) change the
30 * list of emergency numbers.
31 *
32 * 112, 911 are always available. Besides, 000, 08, 110, 999, 118 and 119 should be available
33 * when sim is not present.
34 *
35 * This should be the same information as returned by getCurrentEmergencyNumberList() in
36 * 1.3::IRadio.
37 *
38 * The indicated list of emergency numbers should not have duplicate @1.3::EmergencyNumber.
39 * Please refer the document of @1.3::EmergencyNumber to construct each emergency number to be
40 * returned.
41 *
42 * Reference: 3GPP TS 22.101 version 9.1.0 Release 9
43 *
44 * @param type Type of radio indication
45 * @param emergencyNumberList List of current Emergency Number information
46 * (@1.3::EmergencyNumber) known to radio. Radio must collect all sources of the emergency
47 * numbers to build the indication. For example, network operator signals, sim card
48 * information, modem configuration, OEM configuration (for example, OEM specific system
49 * properties), always-available emergency numbers and sim-absence emergency numbers, etc.
50 */
51 oneway currentEmergencyNumberList(RadioIndicationType type,
52 vec<EmergencyNumber> emergencyNumberList);
53};
diff --git a/radio/1.3/IRadioResponse.hal b/radio/1.3/IRadioResponse.hal
new file mode 100644
index 00000000..6912d0ae
--- /dev/null
+++ b/radio/1.3/IRadioResponse.hal
@@ -0,0 +1,74 @@
1/*
2 * Copyright (C) 2018 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.radio@1.3;
18
19import @1.0::RadioResponseInfo;
20import @1.2::IRadioResponse;
21
22/**
23 * Interface declaring response functions to solicited radio requests.
24 */
25interface IRadioResponse extends @1.2::IRadioResponse {
26 /**
27 * @param info Response info struct containing response type, serial no. and error
28 * @param emergencyNumberList List of current Emergency Number information known to radio.
29 *
30 * Radio must collect all sources of the emergency number to build the response. For example,
31 * network operator signals, sim card information, modem configuration, OEM configuration (for
32 * example, OEM system properties), always-available emergency numbers and sim-absence
33 * emergency numbers, etc.
34 *
35 * The returned list of emergency numbers must not have duplicate @1.3::EmergencyNumber. Please
36 * refer the document of @1.3::EmergencyNumber to construct each emergency number to be
37 * returned.
38 *
39 * Reference: 3GPP TS 22.101 version 9.1.0 Release 9
40 *
41 * Valid errors returned:
42 * RadioError:NONE
43 * RadioError:RADIO_NOT_AVAILABLE
44 * RadioError:NO_MEMORY
45 * RadioError:MODEM_ERR
46 */
47 oneway getCurrentEmergencyNumberListResponse(RadioResponseInfo info,
48 vec<EmergencyNumber> emergencyNumberList);
49
50 /**
51 * @param info Response info struct containing response type, serial no. and error
52 *
53 * Valid errors returned:
54 * RadioError:NONE
55 * RadioError:RADIO_NOT_AVAILABLE (radio resetting)
56 * RadioError:DIAL_MODIFIED_TO_USSD
57 * RadioError:DIAL_MODIFIED_TO_SS
58 * RadioError:DIAL_MODIFIED_TO_DIAL
59 * RadioError:INVALID_ARGUMENTS
60 * RadioError:NO_MEMORY
61 * RadioError:NO_RESOURCES
62 * RadioError:INTERNAL_ERR
63 * RadioError:FDN_CHECK_FAILURE
64 * RadioError:MODEM_ERR
65 * RadioError:NO_SUBSCRIPTION
66 * RadioError:NO_NETWORK_FOUND
67 * RadioError:INVALID_CALL_ID
68 * RadioError:DEVICE_IN_USE
69 * RadioError:ABORTED
70 * RadioError:INVALID_MODEM_STATE
71 * RadioError:CANCELLED
72 */
73 oneway emergencyDialResponse(RadioResponseInfo info);
74};
diff --git a/radio/1.3/types.hal b/radio/1.3/types.hal
index b80aabd4..c04451f5 100644
--- a/radio/1.3/types.hal
+++ b/radio/1.3/types.hal
@@ -24,3 +24,60 @@ enum AccessNetwork : @1.2::AccessNetwork {
24 */ 24 */
25 UNKNOWN = 0, 25 UNKNOWN = 0,
26}; 26};
27
28/**
29 * Emergency number contains information of number, one or more service category(s), and mobile
30 * country code (mcc).
31 *
32 * If the source of the emergency number is associated with country, field ‘mcc’ must be
33 * provided; otherwise the field ‘mcc’ must be an empty string.
34 *
35 * A unique EmergencyNumber has a unique combination of ‘number’ and ‘mcc’ fields.
36 * Multiple @1.3::EmergencyServiceCategory should be merged into the bitfield for the same
37 * EmergencyNumber.
38 *
39 * Reference: 3GPP TS 22.101 version 9.1.0 Release 9
40 */
41struct EmergencyNumber{
42 /**
43 * The emergency number. The character in the number string should only be the dial pad
44 * character('0'-'9', '*', or '#'). For example: 911.
45 */
46 string number;
47 /**
48 * 3-digit Mobile Country Code, 0..999. Empty string if not applicable.
49 */
50 string mcc;
51 /**
52 * The bitfield of @1.3::EmergencyServiceCategory(s). See @1.3::EmergencyServiceCategory for
53 * the value of each bit.
54 */
55 bitfield<EmergencyServiceCategory> categories;
56};
57
58/**
59 * Defining Emergency Service Category as follows:
60 * - General emergency call, all categories;
61 * - Police;
62 * - Ambulance;
63 * - Fire Brigade;
64 * - Marine Guard;
65 * - Mountain Rescue;
66 * - Manually Initiated eCall (MIeC);
67 * - Automatically Initiated eCall (AIeC);
68 *
69 * Type GENERIC (General emergency call, all categories) is considered to use if the reported type
70 * is not any of the other specific types.
71 *
72 * Reference: 3GPP TS 22.101 version 9.1.0 Release 9
73 */
74enum EmergencyServiceCategory : int32_t {
75 GENERIC = 0, // General emergency call, all categories
76 POLICE = 1 << 0,
77 AMBULANCE = 1 << 1,
78 FIRE_BRIGADE = 1 << 2,
79 MARINE_GUARD = 1 << 3,
80 MOUNTAIN_RESCUE = 1 << 4,
81 MIEC = 1 << 5, // Manually Initiated eCall (MIeC)
82 AIEC = 1 << 6, // Automatically Initiated eCall (AIeC)
83};