diff --git a/automotive/remoteaccess/aidl_api/android.hardware.automotive.remoteaccess/current/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl b/automotive/remoteaccess/aidl_api/android.hardware.automotive.remoteaccess/current/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl index 9b6eb2f297..b0935c2fb2 100644 --- a/automotive/remoteaccess/aidl_api/android.hardware.automotive.remoteaccess/current/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl +++ b/automotive/remoteaccess/aidl_api/android.hardware.automotive.remoteaccess/current/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl @@ -34,8 +34,9 @@ package android.hardware.automotive.remoteaccess; @VintfStability interface IRemoteAccess { - String getDeviceId(); + String getVehicleId(); String getWakeupServiceName(); + String getProcessorId(); void setRemoteTaskCallback(android.hardware.automotive.remoteaccess.IRemoteTaskCallback callback); void clearRemoteTaskCallback(); void notifyApStateChange(in android.hardware.automotive.remoteaccess.ApState state); diff --git a/automotive/remoteaccess/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl b/automotive/remoteaccess/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl index a198b038a5..0f4125f475 100644 --- a/automotive/remoteaccess/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl +++ b/automotive/remoteaccess/android/hardware/automotive/remoteaccess/IRemoteAccess.aidl @@ -28,19 +28,19 @@ import android.hardware.automotive.remoteaccess.IRemoteTaskCallback; @VintfStability interface IRemoteAccess { /** - * Gets a unique device ID that could be recognized by wake up server. + * Gets a unique vehicle ID that could be recognized by wake up server. * - * This device ID is provisioned during car production and is registered + *
This vehicle ID is provisioned during car production and is registered * with the wake up server. * - * @return a unique device ID. + * @return a unique vehicle ID. */ - String getDeviceId(); + String getVehicleId(); /** * Gets the name for the remote wakeup server. * - * This name will be provided to remote task server during registration + *
This name will be provided to remote task server during registration * and used by remote task server to find the remote wakeup server to * use for waking up the device. This name must be pre-negotiated between * the remote wakeup server/client and the remote task server/client and @@ -50,6 +50,17 @@ interface IRemoteAccess { */ String getWakeupServiceName(); + /** + * Gets a unique processor ID that could be recognized by wake up client. + * + *
This processor ID is used to identify each processor in the vehicle. + * The wake up client which handles many processors determines which + * processor to wake up from the processor ID. + * + *
The processor ID must be unique in the vehicle.
+ */
+ String getProcessorId();
+
/**
* Sets a callback to be called when a remote task is requested.
*
diff --git a/automotive/remoteaccess/hal/default/include/RemoteAccessService.h b/automotive/remoteaccess/hal/default/include/RemoteAccessService.h
index 74c2af4c9f..5cfca613f4 100644
--- a/automotive/remoteaccess/hal/default/include/RemoteAccessService.h
+++ b/automotive/remoteaccess/hal/default/include/RemoteAccessService.h
@@ -62,7 +62,9 @@ class RemoteAccessService
~RemoteAccessService();
- ndk::ScopedAStatus getDeviceId(std::string* deviceId) override;
+ ndk::ScopedAStatus getVehicleId(std::string* vehicleId) override;
+
+ ndk::ScopedAStatus getProcessorId(std::string* processorId) override;
ndk::ScopedAStatus getWakeupServiceName(std::string* wakeupServiceName) override;
@@ -103,8 +105,8 @@ class RemoteAccessService
void runTaskLoop();
void maybeStartTaskLoop();
void maybeStopTaskLoop();
- ndk::ScopedAStatus getDeviceIdWithClient(
- android::frameworks::automotive::vhal::IVhalClient& client, std::string* deviceId);
+ ndk::ScopedAStatus getVehicleIdWithClient(
+ android::frameworks::automotive::vhal::IVhalClient& client, std::string* vehicleId);
void setRetryWaitInMs(size_t retryWaitInMs) { mRetryWaitInMs = retryWaitInMs; }
void dumpHelp(int fd);
diff --git a/automotive/remoteaccess/hal/default/src/RemoteAccessService.cpp b/automotive/remoteaccess/hal/default/src/RemoteAccessService.cpp
index 4be30a20fa..d9445933ae 100644
--- a/automotive/remoteaccess/hal/default/src/RemoteAccessService.cpp
+++ b/automotive/remoteaccess/hal/default/src/RemoteAccessService.cpp
@@ -48,11 +48,12 @@ using ::grpc::StatusCode;
using ::ndk::ScopedAStatus;
const std::string WAKEUP_SERVICE_NAME = "com.google.vehicle.wakeup";
+const std::string PROCESSOR_ID = "application_processor";
constexpr char COMMAND_SET_AP_STATE[] = "--set-ap-state";
constexpr char COMMAND_START_DEBUG_CALLBACK[] = "--start-debug-callback";
constexpr char COMMAND_STOP_DEBUG_CALLBACK[] = "--stop-debug-callback";
constexpr char COMMAND_SHOW_TASK[] = "--show-task";
-constexpr char COMMAND_GET_DEVICE_ID[] = "--get-device-id";
+constexpr char COMMAND_GET_VEHICLE_ID[] = "--get-vehicle-id";
std::vector