The SOME/IP transport stack manages low-level SOME/IP wire protocol and network
logic through an Android Interface Definition Language (AIDL) interface
(ISomeIpStack). This stack sends and receives SOME/IP events and remote
procedure calls (RPCs). Partners can integrate custom SOME/IP stack
implementations through ISomeIpStack, or use the included reference
implementation built atop the open-source COVESA vsomeip library. This page
describes the following concepts:
Reference implementation: SDV provides a non-production reference sample implementation for a SOME/IP stack.
Binder API: The
ISomeIpStackinterface defines methods for interacting with a SOME/IP stack instance.SELinux: A sample SELinux configuration for the reference stack enables binder communication and granular file system access.
While this stack reads the SOME/IP wire format, it leaves the payload as opaque binary blobs and forwards the payload to the SOME/IP broker.
The SOME/IP standard provides no definition of the stack or stack API layer. SDV provides an AIDL API that operates within the familiar definitions of the standard and requires a minimal amount of code to adapt existing stacks.
This API lets you select different implementations of the stack and simplifies the integration of the stack with other components in the system.
Reference implementation
SDV provides a non-production reference sample implementation for a SOME/IP
stack, consisting of a thin wrapper atop the open-source COVESA vsomeip
library. The system deploys the reference stack only to the SDV Core targets
(aosp_cf_x86_64_sdv_core and aosp_cf_arm64_sdv_core on Android
17 QPR2 and higher, or sdv_core_cf and sdv_core_arm64
on Android 17), and init starts it when
ro.boot.sdv.someip.enable=true:
On Android 17 QPR2 and higher: Configured in
device/google/sdv/aosp_cf_x86_64_sdv_core/init.aosp_cf_x86_64_sdv_core.rc(ordevice/google/sdv/aosp_cf_arm64_sdv_core/init.aosp_cf_arm64_sdv_core.rcon ARM64) withVSOMEIP_CONFIGURATIONset to/vendor/etc/someip/vsomeip_config.json:on property:dev.bootcomplete=1 && property:ro.boot.sdv.someip.enable=true start sdv_someip_stack_agentOn Android 17: Configured in
device/google/sdv/sdv_core_cf/init.sdv_core_cf.rc:on property:dev.bootcomplete=1 && property:ro.boot.sdv.someip.enable=true start sdv_someip_stack_agent
Define the production deployment configuration for your OEM-defined stack. For more information, see Integrate SOME/IP with SDV.
Configuration
The reference stack declares a configuration for the vSomeIP library. The configuration file specifies SOME/IP service discovery (SD) parameters, such as a multicast address and the port used by the stack. For a description of the configuration file structure, see the vsomeip user guide.
Binder API
The ISomeIpStack interface (ISomeIpStack.aidl) is declared in
hardware/sdv/interfaces/some_ip/stack_agent/aidl/google/sdv/someip/. The
ISomeIpStack interface defines methods for interacting with a SOME/IP stack
instance and provides essential qualities for these items.
Service availability
register_availability_callbackRegisters a callback for service availability changes.monitor_serviceInstructs the stack to monitor a specific service's availability.unregister_availability_callbackUnregisters the availability callback.on_sdv_service_availabilityIndicates a change in SDV service availability.
Remote procedure calls (RPC)
You can send an RPC request with:
rpc_transactto wait for a responserpc_onewayto not wait for a response
For RPC request handling:
register_rpc_request_callbackRegisters a callback for incoming RPC requests.unregister_rpc_request_callbackUnregisters the RPC request callback.
Event notification
register_event_notification_callbackRegisters a callback for subscribed event notifications.unregister_event_notification_callbackUnregisters the event notification callback.on_sdv_topic_availabilityIndicates a change in SDV topic availability.subscribeSubscribes to a specific event from an event group.unsubscribeUnsubscribes from a specific event.publishPublishes an event with a given payload.
SELinux
The device/google/sdv/sdv_core_base/sepolicy/samples/vendor/ folder contains a
sample SELinux configuration for the reference stack:
sdv_someip_stack_default.tedefines thesdv_someip_stack_defaulttype and maps it to attributes and contexts.file_contextsmaps binary and data folders to appropriate contexts.
The configuration enables Binder communication between the stack and the broker, allowing access to networking qualities and granular access to the file system of the device.