Merge "Make TrustAgentEnrollmentMgr available through Car API."
diff --git a/car-cluster-logging-renderer/res/values-en-rXC/strings.xml b/car-cluster-logging-renderer/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..04b729a
--- /dev/null
+++ b/car-cluster-logging-renderer/res/values-en-rXC/strings.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2016 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="app_name" msgid="8762201061451645291">"LOGGING_INSTRUMENT_CLUSTER_RENDERER"</string>
+</resources>
diff --git a/car-default-input-service/res/values-en-rXC/strings.xml b/car-default-input-service/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..7a58b83
--- /dev/null
+++ b/car-default-input-service/res/values-en-rXC/strings.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2016 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="app_name" msgid="2732799531977169961">"Car Default Input Service"</string>
+</resources>
diff --git a/car-lib/Android.bp b/car-lib/Android.bp
index c037284..1d887fa 100644
--- a/car-lib/Android.bp
+++ b/car-lib/Android.bp
@@ -71,7 +71,7 @@
installable: true,
}
-doc_defaults {
+stubs_defaults {
name: "android.car-docs-default",
srcs: [
"src/**/*.java",
@@ -80,7 +80,6 @@
libs: [
"android.car",
],
- custom_template: "droiddoc-templates-sdk",
product_variables: {
pdk: {
enabled: false,
@@ -121,13 +120,13 @@
],
}
-droiddoc {
+droidstubs {
name: "android.car-stubs-docs",
defaults: ["android.car-docs-default"],
api_tag_name: "ANDROID_CAR",
api_filename: "api.txt",
removed_api_filename: "removed.txt",
- args: "-hide 113 -hide 110 -nodocs -stubpackages android.car* ",
+ args: "--hide UnavailableSymbol --no-docs --stub-packages android.car* ",
installable: false,
check_api: {
last_released: {
@@ -147,14 +146,14 @@
},
}
-droiddoc {
+droidstubs {
name: "android.car-system-stubs-docs",
defaults: ["android.car-docs-default"],
api_tag_name: "ANDROID_CAR_SYSTEM",
api_filename: "api.txt",
removed_api_filename: "removed.txt",
- args: "-hide 113 -hide 110 -nodocs -stubpackages android.car* " +
- "-showAnnotation android.annotation.SystemApi ",
+ args: "--hide UnavailableSymbol --no-docs --stub-packages android.car* " +
+ "--show-annotation android.annotation.SystemApi ",
installable: false,
check_api: {
last_released: {
@@ -174,14 +173,14 @@
},
}
-droiddoc {
+droidstubs {
name: "android.car-test-stubs-docs",
defaults: ["android.car-docs-default"],
api_tag_name: "ANDROID_CAR_SYSTEM",
api_filename: "api.txt",
removed_api_filename: "removed.txt",
- args: "-hide 113 -hide 110 -nodocs -stubpackages android.car* " +
- "-showAnnotation android.annotation.TestApi ",
+ args: "--hide UnavailableSymbol --no-docs --stub-packages android.car* " +
+ "--show-annotation android.annotation.TestApi ",
installable: false,
check_api: {
current: {
@@ -194,7 +193,7 @@
},
}
-droiddoc {
+droidstubs {
name: "android.car-stub-docs",
srcs: [
"src/**/*.java",
@@ -204,8 +203,7 @@
],
api_tag_name: "ANDROID_CAR_STUB",
api_filename: "api.txt",
- custom_template: "droiddoc-templates-sdk",
- args: "-nodocs -stubpackages android.car* ",
+ args: "--hide UnavailableSymbol --no-docs --stub-packages android.car* ",
installable: false,
product_variables: {
pdk: {
diff --git a/car-lib/api/baseline.txt b/car-lib/api/baseline.txt
new file mode 100644
index 0000000..16e4b7b
--- /dev/null
+++ b/car-lib/api/baseline.txt
@@ -0,0 +1,41 @@
+// Baseline format: 1.0
+HiddenTypeParameter: android.car.hardware.CarSensorManager#getPropertyList():
+ Method android.car.hardware.CarSensorManager.getPropertyList() references hidden type class android.car.hardware.CarPropertyConfig.
+HiddenTypeParameter: android.car.navigation.CarNavigationStatusManager#getInstrumentClusterInfo():
+ Method android.car.navigation.CarNavigationStatusManager.getInstrumentClusterInfo() references hidden type android.car.navigation.CarNavigationInstrumentCluster.
+
+
+HiddenTypedefConstant: android.car.CarInfoManager#getEvConnectorTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.EvConnectorType#UNKNOWN
+HiddenTypedefConstant: android.car.CarInfoManager#getFuelTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.FuelType#UNKNOWN
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#getLatestSensorEvent(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int[], int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#unregisterListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+
+
+ReferencesHidden: android.car.hardware.CarSensorManager#getPropertyList():
+ Class android.car.hardware.CarPropertyConfig is hidden but was referenced (as return type parameter) from public method android.car.hardware.CarSensorManager.getPropertyList()
+ReferencesHidden: android.car.navigation.CarNavigationStatusManager#getInstrumentClusterInfo():
+ Class android.car.navigation.CarNavigationInstrumentCluster is hidden but was referenced (as return type) from public method android.car.navigation.CarNavigationStatusManager.getInstrumentClusterInfo()
+
+
+RequiresPermission: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int):
+ Method 'registerListener' documentation mentions permissions already declared by @RequiresPermission
+
+
+SdkConstant: android.car.Car#CAR_INTENT_ACTION_MEDIA_TEMPLATE:
+ Field 'CAR_INTENT_ACTION_MEDIA_TEMPLATE' is missing @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+
+
+Todo: android.car.CarInfoManager#getVehicleId():
+ Documentation mentions 'TODO'
+
+
diff --git a/car-lib/api/system-baseline.txt b/car-lib/api/system-baseline.txt
new file mode 100644
index 0000000..3d4f02d
--- /dev/null
+++ b/car-lib/api/system-baseline.txt
@@ -0,0 +1,59 @@
+// Baseline format: 1.0
+HiddenTypeParameter: android.car.vms.VmsAvailableLayers#VmsAvailableLayers(java.util.Set<android.car.vms.VmsAssociatedLayer>, int) parameter #0:
+ Parameter associatedLayers references hidden type class android.car.vms.VmsAssociatedLayer.
+HiddenTypeParameter: android.car.vms.VmsAvailableLayers#getAssociatedLayers():
+ Method android.car.vms.VmsAvailableLayers.getAssociatedLayers() references hidden type class android.car.vms.VmsAssociatedLayer.
+HiddenTypeParameter: android.car.vms.VmsOperationRecorder#VmsOperationRecorder(android.car.vms.VmsOperationRecorder.Writer) parameter #0:
+ Parameter writer references hidden type android.car.vms.VmsOperationRecorder.Writer.
+HiddenTypeParameter: android.car.vms.VmsPublisherClientService#getSubscriptions():
+ Method android.car.vms.VmsPublisherClientService.getSubscriptions() references hidden type android.car.vms.VmsSubscriptionState.
+HiddenTypeParameter: android.car.vms.VmsPublisherClientService#onVmsSubscriptionChange(android.car.vms.VmsSubscriptionState) parameter #0:
+ Parameter subscriptionState references hidden type android.car.vms.VmsSubscriptionState.
+
+
+HiddenTypedefConstant: android.car.CarInfoManager#getEvConnectorTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.EvConnectorType#UNKNOWN
+HiddenTypedefConstant: android.car.CarInfoManager#getFuelTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.FuelType#UNKNOWN
+HiddenTypedefConstant: android.car.hardware.CarPropertyValue#getStatus():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarPropertyValue#STATUS_AVAILABLE
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#getLatestSensorEvent(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int[], int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#unregisterListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+
+
+ReferencesHidden: android.car.vms.VmsAvailableLayers#VmsAvailableLayers(java.util.Set<android.car.vms.VmsAssociatedLayer>, int) parameter #0:
+ Class android.car.vms.VmsAssociatedLayer is hidden but was referenced (as parameter type) from public parameter associatedLayers in android.car.vms.VmsAvailableLayers(java.util.Set<android.car.vms.VmsAssociatedLayer> associatedLayers, int sequence)
+ReferencesHidden: android.car.vms.VmsAvailableLayers#getAssociatedLayers():
+ Class android.car.vms.VmsAssociatedLayer is hidden but was referenced (as return type parameter) from public method android.car.vms.VmsAvailableLayers.getAssociatedLayers()
+ReferencesHidden: android.car.vms.VmsOperationRecorder#VmsOperationRecorder(android.car.vms.VmsOperationRecorder.Writer) parameter #0:
+ Class android.car.vms.VmsOperationRecorder.Writer is hidden but was referenced (as parameter type) from public parameter writer in android.car.vms.VmsOperationRecorder(android.car.vms.VmsOperationRecorder.Writer writer)
+ReferencesHidden: android.car.vms.VmsPublisherClientService#getSubscriptions():
+ Class android.car.vms.VmsSubscriptionState is hidden but was referenced (as return type) from public method android.car.vms.VmsPublisherClientService.getSubscriptions()
+ReferencesHidden: android.car.vms.VmsPublisherClientService#onVmsSubscriptionChange(android.car.vms.VmsSubscriptionState) parameter #0:
+ Class android.car.vms.VmsSubscriptionState is hidden but was referenced (as parameter type) from public parameter subscriptionState in android.car.vms.VmsPublisherClientService.onVmsSubscriptionChange(android.car.vms.VmsSubscriptionState subscriptionState)
+
+
+RequiresPermission: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int):
+ Method 'registerListener' documentation mentions permissions already declared by @RequiresPermission
+
+
+SdkConstant: android.car.Car#CAR_INTENT_ACTION_MEDIA_TEMPLATE:
+ Field 'CAR_INTENT_ACTION_MEDIA_TEMPLATE' is missing @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+
+
+Todo: android.car.CarInfoManager#getVehicleId():
+ Documentation mentions 'TODO'
+Todo: android.car.cluster.renderer.InstrumentClusterRenderer:
+ Documentation mentions 'TODO'
+Todo: android.car.drivingstate.CarDrivingStateEvent#DRIVING_STATE_IDLING:
+ Documentation mentions 'TODO'
+
+
diff --git a/car-lib/api/test-baseline.txt b/car-lib/api/test-baseline.txt
new file mode 100644
index 0000000..d71a9e5
--- /dev/null
+++ b/car-lib/api/test-baseline.txt
@@ -0,0 +1,55 @@
+// Baseline format: 1.0
+HiddenTypeParameter: android.car.drivingstate.CarUxRestrictionsManager#getConfig():
+ Method android.car.drivingstate.CarUxRestrictionsManager.getConfig() references hidden type android.car.drivingstate.CarUxRestrictionsConfiguration.
+HiddenTypeParameter: android.car.drivingstate.CarUxRestrictionsManager#getStagedConfig():
+ Method android.car.drivingstate.CarUxRestrictionsManager.getStagedConfig() references hidden type android.car.drivingstate.CarUxRestrictionsConfiguration.
+HiddenTypeParameter: android.car.hardware.CarSensorManager#getPropertyList():
+ Method android.car.hardware.CarSensorManager.getPropertyList() references hidden type class android.car.hardware.CarPropertyConfig.
+HiddenTypeParameter: android.car.navigation.CarNavigationStatusManager#getInstrumentClusterInfo():
+ Method android.car.navigation.CarNavigationStatusManager.getInstrumentClusterInfo() references hidden type android.car.navigation.CarNavigationInstrumentCluster.
+
+
+HiddenTypedefConstant: android.car.CarInfoManager#getEvConnectorTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.EvConnectorType#UNKNOWN
+HiddenTypedefConstant: android.car.CarInfoManager#getFuelTypes():
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.FuelType#UNKNOWN
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#getLatestSensorEvent(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int) parameter #0:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#isSensorSupported(int[], int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+HiddenTypedefConstant: android.car.hardware.CarSensorManager#unregisterListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int) parameter #1:
+ Typedef references constant which isn't part of the API, skipping in documentation: android.car.hardware.CarSensorManager#SENSOR_TYPE_ENGINE_OIL_LEVEL
+
+
+MissingPermission: android.car.drivingstate.CarUxRestrictionsManager#getConfig():
+ Permission Car.PERMISSION_CAR_UX_RESTRICTIONS_CONFIGURATION required by method android.car.drivingstate.CarUxRestrictionsManager.getConfig() is hidden or removed
+MissingPermission: android.car.drivingstate.CarUxRestrictionsManager#getStagedConfig():
+ Permission Car.PERMISSION_CAR_UX_RESTRICTIONS_CONFIGURATION required by method android.car.drivingstate.CarUxRestrictionsManager.getStagedConfig() is hidden or removed
+
+
+ReferencesHidden: android.car.drivingstate.CarUxRestrictionsManager#getConfig():
+ Class android.car.drivingstate.CarUxRestrictionsConfiguration is hidden but was referenced (as return type) from public method android.car.drivingstate.CarUxRestrictionsManager.getConfig()
+ReferencesHidden: android.car.drivingstate.CarUxRestrictionsManager#getStagedConfig():
+ Class android.car.drivingstate.CarUxRestrictionsConfiguration is hidden but was referenced (as return type) from public method android.car.drivingstate.CarUxRestrictionsManager.getStagedConfig()
+ReferencesHidden: android.car.hardware.CarSensorManager#getPropertyList():
+ Class android.car.hardware.CarPropertyConfig is hidden but was referenced (as return type parameter) from public method android.car.hardware.CarSensorManager.getPropertyList()
+ReferencesHidden: android.car.navigation.CarNavigationStatusManager#getInstrumentClusterInfo():
+ Class android.car.navigation.CarNavigationInstrumentCluster is hidden but was referenced (as return type) from public method android.car.navigation.CarNavigationStatusManager.getInstrumentClusterInfo()
+
+
+RequiresPermission: android.car.hardware.CarSensorManager#registerListener(android.car.hardware.CarSensorManager.OnSensorChangedListener, int, int):
+ Method 'registerListener' documentation mentions permissions already declared by @RequiresPermission
+
+
+SdkConstant: android.car.Car#CAR_INTENT_ACTION_MEDIA_TEMPLATE:
+ Field 'CAR_INTENT_ACTION_MEDIA_TEMPLATE' is missing @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+
+
+Todo: android.car.CarInfoManager#getVehicleId():
+ Documentation mentions 'TODO'
+
+
diff --git a/car-maps-placeholder/res/values-en-rXC/strings.xml b/car-maps-placeholder/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..4e862cd
--- /dev/null
+++ b/car-maps-placeholder/res/values-en-rXC/strings.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2016 The Android Open Source Project
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="app_name" msgid="6575346965016311017">"Maps"</string>
+ <string name="error_text" msgid="5575174711944349180">"No maps application installed. Please contact your car manufacturer."</string>
+</resources>
diff --git a/car-usb-handler/res/values-en-rXC/strings.xml b/car-usb-handler/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..1a5589e
--- /dev/null
+++ b/car-usb-handler/res/values-en-rXC/strings.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2015 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="app_name" msgid="6963366455471441257">"USB Handler"</string>
+ <string name="usb_saved_devices" msgid="2829442070749964872">"Saved devices"</string>
+ <string name="usb_pref_delete_title" msgid="3885061814853467483">"Remove handling app for USB device"</string>
+ <string name="usb_pref_delete_message" msgid="5849493572520646218">"Are you sure you wan to delete dafault handling app for %1$s?"</string>
+ <string name="usb_pref_delete_yes" msgid="7803356145103146036">"Yes"</string>
+ <string name="usb_pref_delete_cancel" msgid="5999791462730255929">"Cancel"</string>
+ <string name="usb_resolving_handlers" msgid="1943100136172948686">"Getting supported handlers"</string>
+ <string name="usb_unknown_device" msgid="4211439272338937095">"Unknown USB device"</string>
+</resources>
diff --git a/car-usb-handler/res/values/strings.xml b/car-usb-handler/res/values/strings.xml
index cb59e27..e73a03a 100644
--- a/car-usb-handler/res/values/strings.xml
+++ b/car-usb-handler/res/values/strings.xml
@@ -24,4 +24,11 @@
<string name="usb_pref_delete_cancel">Cancel</string>
<string name="usb_resolving_handlers">Getting supported handlers</string>
<string name="usb_unknown_device">Unknown USB device</string>
+
+ <!-- VID:PID pairs (in hexadecimal and separated by a colon, e.g. 18d1:4e11)
+ of Android devices known to be incompatible with AOAP. Devices in this
+ list will not be probed by UsbHostManagementActivity for AOAP support. -->
+ <string-array name="config_AoapIncompatibleDeviceIds">
+ <item>18d1:9302</item>
+ </string-array>
</resources>
diff --git a/car-usb-handler/src/android/car/usb/handler/AoapInterface.java b/car-usb-handler/src/android/car/usb/handler/AoapInterface.java
index e4d843f..35b570a 100644
--- a/car-usb-handler/src/android/car/usb/handler/AoapInterface.java
+++ b/car-usb-handler/src/android/car/usb/handler/AoapInterface.java
@@ -13,11 +13,16 @@
*/
package android.car.usb.handler;
+import android.content.Context;
import android.hardware.usb.UsbConstants;
import android.hardware.usb.UsbDevice;
import android.hardware.usb.UsbDeviceConnection;
import android.util.Log;
+import android.util.Pair;
+
import java.io.IOException;
+import java.util.HashSet;
+import java.util.Set;
final class AoapInterface {
/**
@@ -94,6 +99,12 @@
*/
public static final int AOAP_TIMEOUT_MS = 2000;
+ /**
+ * Set of VID:PID pairs blacklisted through config_AoapIncompatibleDeviceIds. Only
+ * isDeviceBlacklisted() should ever access this variable.
+ */
+ private static Set<Pair<Integer, Integer>> sBlacklistedVidPidPairs;
+
private static final String TAG = AoapInterface.class.getSimpleName();
public static int getProtocol(UsbDeviceConnection conn) {
@@ -107,8 +118,8 @@
return (buffer[1] << 8) | buffer[0];
}
- public static boolean isSupported(UsbDeviceConnection conn) {
- return getProtocol(conn) >= 1;
+ public static boolean isSupported(Context context, UsbDevice device, UsbDeviceConnection conn) {
+ return !isDeviceBlacklisted(context, device) && getProtocol(conn) >= 1;
}
public static void sendString(UsbDeviceConnection conn, int index, String string)
@@ -134,6 +145,33 @@
}
}
+ public static synchronized boolean isDeviceBlacklisted(Context context, UsbDevice device) {
+ if (sBlacklistedVidPidPairs == null) {
+ sBlacklistedVidPidPairs = new HashSet<>();
+ String[] idPairs =
+ context.getResources().getStringArray(R.array.config_AoapIncompatibleDeviceIds);
+ for (String idPair : idPairs) {
+ boolean success = false;
+ String[] tokens = idPair.split(":");
+ if (tokens.length == 2) {
+ try {
+ sBlacklistedVidPidPairs.add(Pair.create(Integer.parseInt(tokens[0], 16),
+ Integer.parseInt(tokens[1], 16)));
+ success = true;
+ } catch (NumberFormatException e) {
+ }
+ }
+ if (!success) {
+ Log.e(TAG, "config_AoapIncompatibleDeviceIds contains malformed value: "
+ + idPair);
+ }
+ }
+ }
+
+ return sBlacklistedVidPidPairs.contains(Pair.create(device.getVendorId(),
+ device.getProductId()));
+ }
+
public static boolean isDeviceInAoapMode(UsbDevice device) {
if (device == null) {
return false;
diff --git a/car-usb-handler/src/android/car/usb/handler/BootUsbScanner.java b/car-usb-handler/src/android/car/usb/handler/BootUsbScanner.java
index 18dabdc..9658a37 100644
--- a/car-usb-handler/src/android/car/usb/handler/BootUsbScanner.java
+++ b/car-usb-handler/src/android/car/usb/handler/BootUsbScanner.java
@@ -20,7 +20,8 @@
} else {
UsbDeviceConnection connection = UsbUtil.openConnection(manager, device);
try {
- if (connection != null && AoapInterface.isSupported(connection)) {
+ if (connection != null
+ && AoapInterface.isSupported(context, device, connection)) {
handle(context, device);
}
} finally {
diff --git a/car-usb-handler/src/android/car/usb/handler/UsbDeviceHandlerResolver.java b/car-usb-handler/src/android/car/usb/handler/UsbDeviceHandlerResolver.java
index 51c2838..b5abc58 100644
--- a/car-usb-handler/src/android/car/usb/handler/UsbDeviceHandlerResolver.java
+++ b/car-usb-handler/src/android/car/usb/handler/UsbDeviceHandlerResolver.java
@@ -489,7 +489,7 @@
DeviceContext deviceContext =
new DeviceContext(device, UsbDeviceSettings.constructSettings(device), settings);
if (deviceContext.connection != null
- && AoapInterface.isSupported(deviceContext.connection)) {
+ && AoapInterface.isSupported(mContext, device, deviceContext.connection)) {
deviceContext.mActiveDeviceOptions.addAll(getDeviceMatches(device, intent, true));
queryNextAoapHandler(deviceContext);
} else {
diff --git a/car-usb-handler/src/android/car/usb/handler/UsbUtil.java b/car-usb-handler/src/android/car/usb/handler/UsbUtil.java
index 823c660..b251715 100644
--- a/car-usb-handler/src/android/car/usb/handler/UsbUtil.java
+++ b/car-usb-handler/src/android/car/usb/handler/UsbUtil.java
@@ -16,6 +16,7 @@
package android.car.usb.handler;
import android.annotation.Nullable;
+import android.content.Context;
import android.hardware.usb.UsbDevice;
import android.hardware.usb.UsbDeviceConnection;
import android.hardware.usb.UsbManager;
@@ -30,12 +31,13 @@
* Util methods to work with USB devices.
*/
class UsbUtil {
- public static List<UsbDevice> findAllPossibleAndroidDevices(UsbManager usbManager) {
+ public static List<UsbDevice> findAllPossibleAndroidDevices(Context context,
+ UsbManager usbManager) {
HashMap<String, UsbDevice> devices = usbManager.getDeviceList();
ArrayList<UsbDevice> androidDevices = new ArrayList<>(devices.size());
for (UsbDevice device : devices.values()) {
UsbDeviceConnection connection = openConnection(usbManager, device);
- if (AoapInterface.isSupported(connection)) {
+ if (AoapInterface.isSupported(context, device, connection)) {
androidDevices.add(device);
}
connection.close();
diff --git a/car_product/overlay/frameworks/base/core/res/res/values-en-rXC/strings.xml b/car_product/overlay/frameworks/base/core/res/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..da28702
--- /dev/null
+++ b/car_product/overlay/frameworks/base/core/res/res/values-en-rXC/strings.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright 2019 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="owner_name" msgid="3416113395996003764">"Driver"</string>
+</resources>
diff --git a/service/res/values-en-rXC/config.xml b/service/res/values-en-rXC/config.xml
new file mode 100644
index 0000000..8188d25
--- /dev/null
+++ b/service/res/values-en-rXC/config.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/*
+** Copyright 2015, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<!-- Resources to configure car service based on each OEM's preference. -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="inputService" msgid="3911088558664251138">"android.car.input.service/.DefaultInputService"</string>
+ <string name="instrumentClusterRendererService" msgid="2610429499504752025">"android.car.cluster.loggingrenderer/.LoggingClusterRenderingService"</string>
+ <string name="activityBlockingActivity" msgid="1307583481022873450">"com.android.car/com.android.car.pm.ActivityBlockingActivity"</string>
+ <string name="activityWhitelist" msgid="3812149730686980242">"com.android.systemui,com.google.android.packageinstaller/com.android.packageinstaller.permission.ui.GrantPermissionsActivity"</string>
+ <string name="activityBlacklist" msgid="4824386090073724380"></string>
+ <string-array name="allowedAppInstallSources">
+ </string-array>
+ <string name="defaultHomeActivity" msgid="5991064545193106309"></string>
+ <string name="activityHandlerForFlashWearChanges" msgid="8628535766919400479">"com.google.android.car.defaultstoragemonitoringcompanionapp/.MainActivity"</string>
+ <string name="intentReceiverForUnacceptableIoMetrics" msgid="4017502061746918341">"com.google.android.car.defaultstoragemonitoringcompanionapp/.ExcessiveIoIntentReceiver"</string>
+</resources>
diff --git a/service/res/values-en-rXC/strings.xml b/service/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..9c48d03
--- /dev/null
+++ b/service/res/values-en-rXC/strings.xml
@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2015 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="app_title" msgid="2818894849672603016">"Car service"</string>
+ <string name="car_permission_label" msgid="2215078736675564541">"Car information"</string>
+ <string name="car_permission_desc" msgid="37967366937946700">"Access your car\'s information."</string>
+ <string name="car_permission_label_cabin" msgid="7737204489497269651">"Car Cabin"</string>
+ <string name="car_permission_desc_cabin" msgid="5658746726474282714">"Access your car\'s accessories, including doors, mirrors, seats, and windows."</string>
+ <string name="car_permission_label_camera" msgid="608969838109034886">"Car Camera"</string>
+ <string name="car_permission_desc_camera" msgid="7177565584644606387">"Access your car\'s camera(s)."</string>
+ <string name="car_permission_label_energy" msgid="3398092932402178393">"Car energy"</string>
+ <string name="car_permission_desc_energy" msgid="2925098075119509004">"Access your car\'s energy information."</string>
+ <string name="car_permission_label_hvac" msgid="8047274427463154164">"Car Hvac"</string>
+ <string name="car_permission_desc_hvac" msgid="7837686458309247154">"Access your car\'s hvac."</string>
+ <string name="car_permission_label_mileage" msgid="811821331694754443">"Car mileage"</string>
+ <string name="car_permission_desc_mileage" msgid="261946195057016914">"Access your car\'s mileage information."</string>
+ <string name="car_permission_label_speed" msgid="7315924371063443241">"Car speed"</string>
+ <string name="car_permission_desc_speed" msgid="4394638712070011650">"Access your car\'s speed."</string>
+ <string name="car_permission_label_vehicle_dynamics_state" msgid="6475840407257670137">"Vehicle dynamics state"</string>
+ <string name="car_permission_desc_vehicle_dynamics_state" msgid="2458601597024393569">"Access your car\'s dynamics state"</string>
+ <string name="car_permission_label_vendor_extension" msgid="9173884051360575867">"Car vendor channel"</string>
+ <string name="car_permission_desc_vendor_extension" msgid="7223384502421767491">"Access your car\'s vendor channel to exchange car-specific information."</string>
+ <string name="car_permission_label_radio" msgid="4768692394049267617">"Car Radio"</string>
+ <string name="car_permission_desc_radio" msgid="3544198603152937942">"Access your car\'s radio."</string>
+ <string name="car_permission_label_projection" msgid="7830068427803303154">"Car Projection"</string>
+ <string name="car_permission_label_audio_volume" msgid="4802249016680066596">"Car Audio Volume"</string>
+ <string name="car_permission_label_audio_settings" msgid="7788327093945466775">"Car Audio Settings"</string>
+ <string name="car_permission_desc_projection" msgid="2680001094361534439">"Project phone interface on car display."</string>
+ <string name="car_permission_label_mock_vehicle_hal" msgid="7429043278386896118">"Emulate vehicle HAL"</string>
+ <string name="car_permission_desc_mock_vehicle_hal" msgid="3549687008625373417">"Emulate your car\'s vehicle HAL for internal testing purpose."</string>
+ <string name="car_permission_desc_audio_volume" msgid="7484628324723179580">"Control your car\'s audio volume."</string>
+ <string name="car_permission_desc_audio_settings" msgid="2871870084988702516">"Control your car\'s audio settings."</string>
+ <string name="car_permission_label_control_app_blocking" msgid="9112678596919993386">"Application blocking"</string>
+ <string name="car_permission_desc_control_app_blocking" msgid="7539378161760696190">"Control application blocking while driving."</string>
+ <string name="car_permission_car_navigation_manager" msgid="5895461364007854077">"Navigation Manager"</string>
+ <string name="car_permission_desc_car_navigation_manager" msgid="6188751054665471537">"Report navigation data to instrument cluster"</string>
+ <string name="car_permission_car_display_in_cluster" msgid="4005987646292458684">"Direct rendering to instrument cluster"</string>
+ <string name="car_permission_desc_car_display_in_cluster" msgid="2668300546822672927">"Allow an application to declare activities to be displayed in the instrument cluster"</string>
+ <string name="car_permission_car_cluster_control" msgid="1382247204230165674">"Instrument cluster control"</string>
+ <string name="car_permission_desc_car_cluster_control" msgid="9222776665281176031">"Launch apps in the instrument cluster"</string>
+ <string name="car_permission_label_bind_instrument_cluster_rendering" msgid="8627480897198377418">"Instrument Cluster Rendering"</string>
+ <string name="car_permission_desc_bind_instrument_cluster_rendering" msgid="5073596870485006783">"Receive instrument cluster data"</string>
+ <string name="car_permission_label_car_ux_restrictions_configuration" msgid="6801393970411049725">"UX Restrictions Configuration"</string>
+ <string name="car_permission_desc_car_ux_restrictions_configuration" msgid="5711926927484813777">"Configure UX Restrictions"</string>
+ <string name="car_permission_label_bind_input_service" msgid="6698489034024273750">"Car Input Service"</string>
+ <string name="car_permission_desc_bind_input_service" msgid="1670323419931890170">"Handle input events"</string>
+ <string name="car_can_bus_failure" msgid="2334035748788283914">"CAN bus failed"</string>
+ <string name="car_can_bus_failure_desc" msgid="4125516222786484733">"CAN bus does not respond. Unplug and plug back headunit box and restart the car"</string>
+ <string name="activity_blocked_text" msgid="7117775117422916032">"For your safety, this activity isn’t available while you’re driving"</string>
+ <string name="debug_button_text" msgid="6395881820644544676">"Debug Info"</string>
+ <string name="exit_button" msgid="626660628135437972">"Restart App"</string>
+ <string name="car_permission_label_diag_read" msgid="2539365760945541902">"Diagnostic Data"</string>
+ <string name="car_permission_desc_diag_read" msgid="6300061847723430001">"Read diagnostic data from the car"</string>
+ <string name="car_permission_label_diag_clear" msgid="5276954546130303905">"Diagnostic Data"</string>
+ <string name="car_permission_desc_diag_clear" msgid="6890216593617069473">"Clear diagnostic data from the car"</string>
+ <string name="car_permission_label_vms_publisher" msgid="5738544816086673968">"VMS publisher"</string>
+ <string name="car_permission_desc_vms_publisher" msgid="154858011053838907">"Publish vms messages"</string>
+ <string name="car_permission_label_vms_subscriber" msgid="2776578987390414930">"VMS subscriber"</string>
+ <string name="car_permission_desc_vms_subscriber" msgid="6846187370448294450">"Subscribe to vms messages"</string>
+ <string name="car_permission_label_storage_monitoring" msgid="2327639346522530549">"Flash storage monitoring"</string>
+ <string name="car_permission_desc_storage_monitoring" msgid="2075712271139671318">"Monitor flash storage usage"</string>
+ <string name="car_permission_label_driving_state" msgid="6069696010591163256">"Driving State"</string>
+ <string name="car_permission_desc_driving_state" msgid="4082684279226021396">"Listen to Driving state changes"</string>
+ <string name="car_permission_label_car_engine_detailed" msgid="9002892724697007617">"Engine Detailed"</string>
+ <string name="car_permission_desc_car_engine_detailed" msgid="7360817472577625295">"Access your car\'s detailed engine information"</string>
+ <string name="car_permission_label_car_energy_ports" msgid="4263949434683308884">"Energy Ports"</string>
+ <string name="car_permission_desc_car_energy_ports" msgid="557965577468080620">"Access energy ports"</string>
+ <string name="car_permission_label_car_identification" msgid="1729154715508060432">"Car identification"</string>
+ <string name="car_permission_desc_car_identification" msgid="3446202891279037295">"Access car\'s identification"</string>
+ <string name="car_permission_label_control_car_doors" msgid="982176169678332325">"Car Doors"</string>
+ <string name="car_permission_desc_control_car_doors" msgid="438796526924485694">"Control car\'s doors"</string>
+ <string name="car_permission_label_control_car_windows" msgid="8495424050848179521">"Car Windows"</string>
+ <string name="car_permission_desc_control_car_windows" msgid="7191531366203590752">"Control car\'s windows"</string>
+ <string name="car_permission_label_control_car_mirrors" msgid="5695032398073590372">"Car Mirrors"</string>
+ <string name="car_permission_desc_control_car_mirrors" msgid="1329068133900689986">"Control car\'s mirrors"</string>
+ <string name="car_permission_label_control_car_seats" msgid="4068728236135716379">"Car Seats"</string>
+ <string name="car_permission_desc_control_car_seats" msgid="5319108612196099191">"Control car\'s seats"</string>
+ <string name="car_permission_label_car_info" msgid="5638680944359440535">"Car basic information"</string>
+ <string name="car_permission_desc_car_info" msgid="1697298888275875496">"Access car basic information"</string>
+ <string name="car_permission_label_car_exterior_lights" msgid="6756996909877627936">"Car exterior lights"</string>
+ <string name="car_permission_desc_car_exterior_lights" msgid="5404593475424542202">"Access car exterior lights state"</string>
+ <string name="car_permission_label_control_car_exterior_lights" msgid="822902629489856498">"Car exterior lights"</string>
+ <string name="car_permission_desc_control_car_exterior_lights" msgid="1131149440610151914">"Control car exterior lights"</string>
+ <string name="car_permission_label_car_exterior_environment" msgid="7617025356417480155">"Car exterior temperature"</string>
+ <string name="car_permission_desc_car_exterior_environment" msgid="7665860792016287191">"Access car exterior temperature"</string>
+ <string name="car_permission_label_car_tires" msgid="7261327603773636683">"Car tires"</string>
+ <string name="car_permission_desc_car_tires" msgid="4398458490319322940">"Access car tire information"</string>
+ <string name="car_permission_label_car_powertrain" msgid="246182551556313624">"Car Powertrain"</string>
+ <string name="car_permission_desc_car_powertrain" msgid="3838172429633520832">"Access car powertrain information"</string>
+ <string name="car_permission_label_car_power" msgid="3671174734416372201">"Car Power"</string>
+ <string name="car_permission_desc_car_power" msgid="8955018800799758403">"Access car power state"</string>
+</resources>
diff --git a/tests/obd2_app/res/values-en-rXC/arrays.xml b/tests/obd2_app/res/values-en-rXC/arrays.xml
new file mode 100644
index 0000000..0e5cd26
--- /dev/null
+++ b/tests/obd2_app/res/values-en-rXC/arrays.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Copyright (C) 2017 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string-array name="scan_delay_entries">
+ <item msgid="6824939704660193492">"2 seconds"</item>
+ <item msgid="4283574244056233745">"5 seconds"</item>
+ <item msgid="8984629990034652828">"10 seconds"</item>
+ </string-array>
+ <string-array name="scan_delay_entryValues">
+ <item msgid="9084818712104183355">"2"</item>
+ <item msgid="7912051093881958943">"5"</item>
+ <item msgid="8452837398897797309">"10"</item>
+ </string-array>
+</resources>
diff --git a/user/car-user-lib/src/android/car/userlib/CarUserManagerHelper.java b/user/car-user-lib/src/android/car/userlib/CarUserManagerHelper.java
index 4e7e02c..fe39d51 100644
--- a/user/car-user-lib/src/android/car/userlib/CarUserManagerHelper.java
+++ b/user/car-user-lib/src/android/car/userlib/CarUserManagerHelper.java
@@ -63,7 +63,8 @@
* Default set of restrictions for Non-Admin users.
*/
private static final Set<String> DEFAULT_NON_ADMIN_RESTRICTIONS = Sets.newArraySet(
- UserManager.DISALLOW_FACTORY_RESET
+ UserManager.DISALLOW_FACTORY_RESET,
+ UserManager.DISALLOW_RUN_IN_BACKGROUND
);
/**