<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Apoorva Satish on Medium]]></title>
        <description><![CDATA[Stories by Apoorva Satish on Medium]]></description>
        <link>https://medium.com/@apoorvasatish822?source=rss-827d8f104335------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*dmbNkD5D-u45r44go_cf0g.png</url>
            <title>Stories by Apoorva Satish on Medium</title>
            <link>https://medium.com/@apoorvasatish822?source=rss-827d8f104335------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 08:45:07 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@apoorvasatish822/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Binder IPC]]></title>
            <link>https://medium.com/@apoorvasatish822/binder-ipc-56977128172f?source=rss-827d8f104335------2</link>
            <guid isPermaLink="false">https://medium.com/p/56977128172f</guid>
            <dc:creator><![CDATA[Apoorva Satish]]></dc:creator>
            <pubDate>Mon, 16 Nov 2026 10:58:15 GMT</pubDate>
            <atom:updated>2026-11-16T10:58:15.466Z</atom:updated>
            <content:encoded><![CDATA[<p>Binder IPC is Android’s Remote Procedure Call (RPC) framework that enables processes to invoke methods on objects residing in other processes as if they were local. It relies on a dedicated Binder kernel driver, which facilitates service discovery, message delivery, object reference management, security enforcement, and thread scheduling across process boundaries.</p><p>As you can see in the below diagram CarService and VHAL communicate via binder ipc.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RELDdJ04CyVJlTRaI4f01w.png" /></figure><ol><li>Context Manager — The Context Manager is the central directory service that knows where all Binder services are registered. Only one user-mode process can request to register as context manager.</li><li>Service Manager —A core system component that acts as a context manager , allowing applications to access various system services by providing a way to look up and retrieve references to those services by their names, essentially acting as a “yellow pages” for system services within the Android framework; it manages the registration and retrieval of system services through the Binder IPC mechanism, enabling communication between different processes on the device. It functions as a service mapper.</li><li>CarService — A framework system service that provides automotive-specific functionality and acts as an intermediary between application-layer APIs and underlying vehicle services.</li><li>CarPropertyManager — An application-facing framework API that provides access to vehicle properties. It enables applications to read, write, and subscribe to property updates by communicating with CarService through Binder IPC.</li><li>Binder driver — The kernel-level IPC mechanism in Android that enables communication between processes. It transfers requests and responses between Binder clients and Binder services, manages object references, thread scheduling, and security checks.</li></ol><p>The first Binder component to come up is the <strong>Service Manager</strong>, which registers itself as the system’s <strong>Context Manager</strong>. When <strong>VHAL</strong> is initialized, it registers its service with the Service Manager using addService(). Within <strong>Car Service</strong>, the <strong>CarPropertyService</strong> discovers the VHAL service by calling getService(). The <strong>Binder Driver</strong> then provides a handle to the requested service, enabling communication between the client and server processes. From an application perspective, Binder IPC remains hidden because framework managers like <strong>CarPropertyManager</strong> abstract all Binder interactions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eqO4Owb1lbur_kirKxYsog.png" /></figure><ol><li><strong>Binder</strong> — Android’s inter-process communication (IPC) framework that enables processes to invoke methods on objects residing in other processes as if they were local.</li><li><strong>BnXXX</strong> — The native Binder server-side implementation generated from an AIDL or Binder interface. It receives requests from remote clients and dispatches them to the actual service implementation.</li><li><strong>BpXXX</strong> — The native Binder client-side proxy generated from a Binder interface. It packages method arguments into Binder transactions and sends them to the remote service.</li><li><strong>Proxy</strong> — A client-side object representing a remote service. It hides IPC details and makes remote method calls appear like local function calls.</li><li><strong>Stub</strong> — A server-side object that receives Binder transactions, unpacks the request data, invokes the corresponding service method, and returns the result.</li><li><strong>Binder Object</strong> — An object that implements a Binder interface and can participate in Binder communication. It can be published as a service or passed between processes.</li><li><strong>Binder Token</strong> — A lightweight Binder object used primarily for identity, ownership, lifecycle tracking, synchronization, or permission enforcement rather than exposing callable APIs.</li><li><strong>IBinder Interface</strong> — The core Android interface that represents a Binder object. It provides the fundamental APIs required for Binder communication, transaction handling, and service discovery.</li></ol><p>When the user changes the cabin temperature from <strong>22°C to 24°C</strong>, the HVAC app invokes CarPropertyManager.setProperty(). The application does not interact with Binder directly; the framework manager abstracts the IPC details. The request is forwarded to <strong>CarPropertyService</strong>, which acts as a client to VHAL. Using the Binder handle obtained during service discovery, CarPropertyService invokes methods on the generated <strong>BpVehicle</strong> Binder proxy, which marshals the request into a Parcel and sends it through the Binder Driver. The proxy packages the request into a Parcel and sends it through the <strong>Binder Driver</strong>. The Binder Driver delivers the transaction to <strong>BnVehicle</strong> (the Binder Stub) in the VHAL process. BnVehicle unpacks the Parcel and invokes the corresponding VHAL method. VHAL then translates the request into a vehicle-network message and sends it to the HVAC ECU. After the ECU updates the temperature, a property-change event is sent back to VHAL. The callback follows the reverse Binder path and eventually reaches the HVAC app through CarPropertyManager, updating the UI with the new value.</p><p>During the Android build process, the <strong>Soong build system</strong> detects AIDL or HIDL interface definitions and invokes the appropriate code generator. The generator automatically creates client-side <strong>Proxy (BpXXX)</strong> classes and server-side <strong>Stub (BnXXX)</strong> classes. The Proxy packages method calls into Binder transactions, while the Stub receives and dispatches them to the actual service implementation. This auto-generated code hides the IPC details from developers. As a result, remote service calls can be made almost like ordinary function calls.</p><p>Binder IPC allows CarService and VHAL to communicate across process boundaries using generated Proxy (BpXXX) and Stub (BnXXX) classes, while framework APIs such as CarPropertyManager hide these IPC details from applications.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=56977128172f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Android Vehicle Properties]]></title>
            <link>https://medium.com/@apoorvasatish822/android-vehicle-properties-12abc78f3455?source=rss-827d8f104335------2</link>
            <guid isPermaLink="false">https://medium.com/p/12abc78f3455</guid>
            <category><![CDATA[vehicle-properties]]></category>
            <category><![CDATA[android-automotive]]></category>
            <category><![CDATA[vhal]]></category>
            <category><![CDATA[aosp]]></category>
            <dc:creator><![CDATA[Apoorva Satish]]></dc:creator>
            <pubDate>Thu, 05 Nov 2026 05:24:50 GMT</pubDate>
            <atom:updated>2026-11-05T05:24:50.911Z</atom:updated>
            <content:encoded><![CDATA[<p>In the previous article, we explored the importance of the Vehicle Hardware Abstraction Layer (VHAL) and briefly introduced vehicle properties. In this article, we’ll look at vehicle properties in more detail and understand how Android Automotive uses them to exchange vehicle data.</p><p>Android Automotive provides a set of predefined vehicle properties and also allows OEMs to create custom properties when required.</p><p>Each vehicle property is identified by a unique<strong> </strong>Property ID.</p><h3><strong>Vehicle Property ID Structure</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/774/1*gblQLmWczzEmEbUVOBXy7A.png" /><figcaption>Vehicle Property Id</figcaption></figure><p>→ Property group<br>Indicates whether the property belongs to the Android-defined system group or an OEM-defined vendor group.</p><ul><li><strong>System Group</strong>: Contains standard Android Automotive properties such as vehicle speed, HVAC controls, and fuel level.</li><li><strong>Vendor Group</strong>: Contains custom properties created by OEMs for vehicle-specific requirements.</li></ul><p>→ Vehicle area<br>Defines where the property applies within the vehicle.<br>Examples include:</p><ul><li>GLOBAL</li><li>WINDOW</li><li>DOOR</li><li>SEAT</li><li>MIRROR</li></ul><p>For example, a seat-heating property may apply to a specific seat, while vehicle speed is a global property applicable to the entire vehicle.</p><p>→ Value type<br>Specifies the data type used by the property. Common value types include:</p><ul><li>Boolean</li><li>Integer</li><li>Float</li><li>String</li><li>Integer Array</li><li>Float Array</li></ul><p>→ Unique Id <br>A unique identifier that distinguishes one property from another within the same group, area, and type.</p><p>The combination of these fields forms a unique Vehicle Property ID.</p><p>0x15200505 is the property ID of HVAC_AC_ON. Let’s decode it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/384/1*HcNap8GwXO8T111_WSlMJw.png" /></figure><h3><strong>Property Update</strong></h3><p>Applications do not continuously poll the vehicle for data. Instead, they subscribe to the properties they are interested in and receive notifications from VHAL when updates occur. The notification behavior is controlled by a parameter called <strong>Change Mode</strong>. Android Automotive supports three main change modes:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*53RwmNtr-YNMOU2t1XwzJg.png" /></figure><p>Let’s revisit the <strong>HVAC_AC_ON</strong> property.</p><p>When a user toggles the AC button on the HVAC application:</p><ol><li>The HVAC application subscribes to the HVAC_AC_ON property.</li><li>VHAL monitors the property’s value.</li><li>Whenever the AC status changes, VHAL sends a notification to the subscribed client.</li><li>The HVAC application receives the updated value and refreshes the UI accordingly.</li></ol><p>Since HVAC_AC_ON changes only when the user turns the AC on or off, its change mode is configured as <strong>ON_CHANGE</strong>.</p><p>Some vehicle signals like Vehicle speed, Sterring angle, Engine RPM etc change frequently while the vehicle is in motion. These properties are typically configured with the <strong>CONTINUOUS</strong> change mode, allowing applications to receive updates at a defined rate. Certain vehicle information remains constant throughout the vehicle’s lifetime.</p><p>Examples include:</p><ul><li>INFO_VIN</li><li>INFO_MAKE</li><li>INFO_MODEL_YEAR</li></ul><p>These are configured as <strong>STATIC</strong> properties because their values are usually set once and are not expected to change.</p><p>Most vehicle properties use <strong>ON_CHANGE</strong> updates because sending notifications only when values change helps:</p><ul><li>Reduce CPU usage</li><li>Minimize communication overhead</li><li>Lower power consumption</li><li>Prevent unnecessary processing by applications</li></ul><p>By choosing the appropriate change mode for each property, Android Automotive ensures efficient communication between applications and the vehicle hardware.</p><p>Every interaction between an Android Automotive application and the vehicle ultimately revolves around vehicle properties. Whether it is reading vehicle speed, controlling HVAC settings, or displaying vehicle information, properties act as the common language between Android and the vehicle.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=12abc78f3455" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Vehicle Hardware Abstraction Layer]]></title>
            <link>https://medium.com/@apoorvasatish822/vehicle-hardware-abstraction-layer-3de83618c415?source=rss-827d8f104335------2</link>
            <guid isPermaLink="false">https://medium.com/p/3de83618c415</guid>
            <category><![CDATA[android]]></category>
            <category><![CDATA[aosp-hal]]></category>
            <category><![CDATA[vhal]]></category>
            <dc:creator><![CDATA[Apoorva Satish]]></dc:creator>
            <pubDate>Wed, 28 Oct 2026 05:39:14 GMT</pubDate>
            <atom:updated>2026-10-28T05:39:14.611Z</atom:updated>
            <content:encoded><![CDATA[<p>The Vehicle Hardware Abstraction Layer (VHAL) is one of the most important HALs in Android Automotive. It acts as a bridge between the Android framework and vehicle-specific hardware. VHAL receives signals from the vehicle’s Input/Output Controller (IOC) and maps them to standardized vehicle properties that can be understood by the framework and applications.</p><p><strong>Why is VHAL Required?</strong></p><p>Consider two vehicle manufacturers:</p><ul><li>Car A represents the <strong>Ignition ON</strong> state with a signal value of <strong>3</strong></li><li>Car B represents the <strong>Ignition ON</strong> state with a signal value of <strong>2</strong></li></ul><p>Without VHAL, applications would need to understand the vehicle-specific signal definitions for every platform they run on. To avoid this complexity, Android Automotive defines standard vehicle properties and their corresponding enum values.</p><p>For example, the IGNITION_STATE property can be represented as:</p><p><em>Undefined-0<br> Lock-1<br> Off-2<br> Acc-3<br> On-4<br> Start-5</em></p><p>VHAL translates the vehicle-specific signal values into these standardized values. In the above scenarios, it is mapped to ON(4). As a result, applications do not need to know the actual signal values used by different vehicles. They simply read the standardized vehicle property exposed by the Android Automotive framework.</p><p>A practical example of this can be seen in HVAC controls. When a driver taps the <strong>AC ON</strong> button on the HMI, the action appears simple, but several software components work together behind the scenes. The request is ultimately routed through VHAL to the HVAC ECU, and once the ECU processes the request, the updated vehicle property is propagated back through the stack to update the HMI. This complete flow demonstrates how VHAL enables consistent communication between Android Automotive and vehicle hardware.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Wl-gTzQ0PqxApXsFzAScrw.png" /><figcaption>HVAC AC ON End-to-End Flow</figcaption></figure><p>VHAL is much more than a simple translation layer. It provides a consistent interface between Android Automotive and vehicle hardware, enabling applications to remain independent of vehicle-specific signal implementations. In the next article, we’ll take a deeper look at vehicle properties and trace an HVAC property update through the Android Automotive framework, from the ECU all the way to the HMI.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3de83618c415" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>