This document provides an overview of Android's HIDL (Hardware Interface Definition Language). It begins with introductions to HIDL's goals of providing versioned hardware interface definitions and how it fits into Android's architecture. It then covers basics like HAL's traditional C-based implementation, HIDL's similarities to AIDL, and links to documentation. The document dives deeper into HIDL's architecture including the JNI, HIDL, and HIDL glue layers. It walks through an example of lights HAL implementation. Finally, it discusses adding a new HIDL interface, the supporting infrastructure, and acknowledges diagram sources.
There is a surge in number of sensors / devices that are getting connected under the umbrella of Internet-Of-Things (IoT). These devices need to be integrated into the Android system and accessed via applications, which is covered in the course. Our Android system development course curriculum over weekends with practicals ensures you learn all critical components to get started.
Embedded Android System Development - Part II talks about Hardware Abstraction Layer (HAL). HAL is an interfacing layer through which Android service can place a request to device. Uses functions provided by Linux system to service the request from android framework. A C/C++ layer with purely vendor specific implementation. Packaged into modules (.so) file & loaded by Android system at appropriate time
In order to understand HAL layers of Android Framework, having Linux device driver knowledge is important. Hence Day-2 of the workshop focuses on the same.
There is a surge in number of sensors / devices that are getting connected under the umbrella of Internet-Of-Things (IoT). These devices need to be integrated into the Android system and accessed via applications, which is covered in the course. Our Android system development course curriculum over weekends with practicals ensures you learn all critical components to get started.
Embedded Android System Development - Part II talks about Hardware Abstraction Layer (HAL). HAL is an interfacing layer through which Android service can place a request to device. Uses functions provided by Linux system to service the request from android framework. A C/C++ layer with purely vendor specific implementation. Packaged into modules (.so) file & loaded by Android system at appropriate time
In order to understand HAL layers of Android Framework, having Linux device driver knowledge is important. Hence Day-2 of the workshop focuses on the same.
For new age touch-based embedded devices, Android is becoming a popular OS going beyond mobile phones. With its roots from Embedded Linux, Android framework offers benefits in terms of rich libraries, open-source and multi-device support. Emertxe’s hands-on Embedded Android Training Course is designed to customize, build and deploy custom Embedded OS on ARM target. Rich set of projects will make your learning complete.
Embedded Android system development workshop is focused on integrating new device with Android framework. Our hands-on approach makes Emertxe as the best institute to learn android system development training. This workshop deep dives into Android porting, Android Hardware Abstraction Layer (HAL), Android Services and Linux device driver ecosystem. This workshop based training program will enable you to efficiently integrate new hardware with Android HAL / Framework.
A deep dive into Android OpenSource Project(AOSP)Siji Sunny
A deep dive into Android openSource project presented at
International Centre for Free and Open Source Software (ICFOSS), Kerala's OpenSource Mobile Computing Conference
Android Audio HAL – Audio Architecture – Audio HAL interface – Audio Policy – Audio HAL compilation & verification – Overview of Tinyalsa
Android Video HAL – Camera Architecture – Overview of camera HAL interface – Overview of V4L2 – Enabling V4l2 in kernel – Camera HAL compilation and verification
Android Things is the latest attempt from Google to connect the dots between the cloud and devices by introducing an OS that is exclusively built for IoT devices. Initially announced as project Brillo, Android Things helps developers to build devices faster and enable them integrate with cloud services. This presentation traces the architectural aspects of Android Things by connecting it back with Embedded Linux, Embedded Android and Brillo.
Binder is what differentiates Android from Linux, it is most important internal building block of Android, it is a subject every Android programmer should be familiar with
For new age touch-based embedded devices, Android is becoming a popular OS going beyond mobile phones. With its roots from Embedded Linux, Android framework offers benefits in terms of rich libraries, open-source and multi-device support. Emertxe’s hands-on Embedded Android Training Course is designed to customize, build and deploy custom Embedded OS on ARM target. Rich set of projects will make your learning complete.
Embedded Android system development workshop is focused on integrating new device with Android framework. Our hands-on approach makes Emertxe as the best institute to learn android system development training. This workshop deep dives into Android porting, Android Hardware Abstraction Layer (HAL), Android Services and Linux device driver ecosystem. This workshop based training program will enable you to efficiently integrate new hardware with Android HAL / Framework.
A deep dive into Android OpenSource Project(AOSP)Siji Sunny
A deep dive into Android openSource project presented at
International Centre for Free and Open Source Software (ICFOSS), Kerala's OpenSource Mobile Computing Conference
Android Audio HAL – Audio Architecture – Audio HAL interface – Audio Policy – Audio HAL compilation & verification – Overview of Tinyalsa
Android Video HAL – Camera Architecture – Overview of camera HAL interface – Overview of V4L2 – Enabling V4l2 in kernel – Camera HAL compilation and verification
Android Things is the latest attempt from Google to connect the dots between the cloud and devices by introducing an OS that is exclusively built for IoT devices. Initially announced as project Brillo, Android Things helps developers to build devices faster and enable them integrate with cloud services. This presentation traces the architectural aspects of Android Things by connecting it back with Embedded Linux, Embedded Android and Brillo.
Binder is what differentiates Android from Linux, it is most important internal building block of Android, it is a subject every Android programmer should be familiar with
While Android’s use in mobile and embedded systems is now common, details about how to debug and develop in its internals are still hard to come by. This session will cover the tools, techniques and hacks that developers can use to debug difficult problems within the Android stack.
View this presentation on YouTube:
https://www.youtube.com/watch?v=vnoY9WwEwIc
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Ramesh Iyer
In today's fast-changing business world, Companies that adapt and embrace new ideas often need help to keep up with the competition. However, fostering a culture of innovation takes much work. It takes vision, leadership and willingness to take risks in the right proportion. Sachin Dev Duggal, co-founder of Builder.ai, has perfected the art of this balance, creating a company culture where creativity and growth are nurtured at each stage.
Search and Society: Reimagining Information Access for Radical FuturesBhaskar Mitra
The field of Information retrieval (IR) is currently undergoing a transformative shift, at least partly due to the emerging applications of generative AI to information access. In this talk, we will deliberate on the sociotechnical implications of generative AI for information access. We will argue that there is both a critical necessity and an exciting opportunity for the IR community to re-center our research agendas on societal needs while dismantling the artificial separation between the work on fairness, accountability, transparency, and ethics in IR and the rest of IR research. Instead of adopting a reactionary strategy of trying to mitigate potential social harms from emerging technologies, the community should aim to proactively set the research agenda for the kinds of systems we should build inspired by diverse explicitly stated sociotechnical imaginaries. The sociotechnical imaginaries that underpin the design and development of information access technologies needs to be explicitly articulated, and we need to develop theories of change in context of these diverse perspectives. Our guiding future imaginaries must be informed by other academic fields, such as democratic theory and critical theory, and should be co-developed with social science scholars, legal scholars, civil rights and social justice activists, and artists, among others.
"Impact of front-end architecture on development cost", Viktor TurskyiFwdays
I have heard many times that architecture is not important for the front-end. Also, many times I have seen how developers implement features on the front-end just following the standard rules for a framework and think that this is enough to successfully launch the project, and then the project fails. How to prevent this and what approach to choose? I have launched dozens of complex projects and during the talk we will analyze which approaches have worked for me and which have not.
Let's dive deeper into the world of ODC! Ricardo Alves (OutSystems) will join us to tell all about the new Data Fabric. After that, Sezen de Bruijn (OutSystems) will get into the details on how to best design a sturdy architecture within ODC.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
The Art of the Pitch: WordPress Relationships and Sales
Android's HIDL: Treble in the HAL
1. 1
Android's HIDL:
Treble in the HAL
YouTubeTM
Livestream
March 28th
2018
Karim Yaghmour
@karimyaghmour
karim.yaghmour@opersys.com
2. 2
These slides are made available to you under a Creative Commons Share-
Alike 3.0 license. The full terms of this license are here:
https://creativecommons.org/licenses/by-sa/3.0/
Attribution requirements and misc., PLEASE READ:
● This slide must remain as-is in this specific location (slide #2), everything
else you are free to change; including the logo :-)
● Use of figures in other documents must feature the below “Originals at”
URL immediately under that figure and the below copyright notice where
appropriate.
● You are free to fill in the “Delivered and/or customized by” space on the
right as you see fit.
● You are FORBIDEN from using the default “About” slide as-is or any of its
contents.
● You are FORBIDEN from using any content provided by 3rd parties without
the EXPLICIT consent from those parties.
(C) Copyright 2018, Opersys inc.
These slides created by: Karim Yaghmour
Originals at: www.opersys.com/community/docs
Delivered and/or customized by
3. 3
About
● Author of:
● Introduced Linux Trace Toolkit in 1999
● Originated Adeos and relayfs (kernel/relay.c)
● Training, Custom Dev, Consulting, ...
6. 6
1.1. Goals
● Recap HIDL's origins
● Describe what HIDL does
● Outline how it fits into Android architecture
● Detail how to use it and how it works
7. 7
1.2. Origins
● Part of Android's Project Treble
● Extends existing HAL concepts
● Similar to AIDL
14. 14
2.1. HAL's Role
● Per-device-type hardware abstraction
● Example:
● SurfaceFlinger uses hwcomposer HAL
● Location uses gps HAL
● Lights uses lights HAL
● Etc.
● Google specifies HAL signature
● Manufacturer/SoC vendor provides HAL implementation
● Reference implementations:
● Leads devices found in AOSP
● SoC vendor reference designs/boards in BSP
15. 15
2.2. Traditional HAL Before 8.x
● Google specifies HALs as “C” header files
● HAL module author uses header in implementation
● Resulting binary shipped as part of release
● Modules loaded at boot time by system services
● Headers could (and did) change between versions
● Required reworking, rebuilding, reshipping new
version
● To update to a new version of Android:
● All modules had to be updated, be they trivial or difficult
16. 16
2.3. HIDL
● “Hardware Interface Definition Language”
● New layer under system services
● Formalized and versioned HAL interface definitions
●
Similar to AIDL, yet different
●
Example HIDLs in 8.x/Oreo:
● graphics/composer 2.1
● gnss 1.0
● Etc.
●
Once published, a given HIDL definition is immutable:
● Even in 9.x/P, graphics/composer 2.1 and gnss 1.0 will be the same as in 8.x.
● Fresh port assumes using latest HAL sig available
● Most importantly:
● Modules created against a given signature should continue to work so long as that
signature is supported.
● Depends on Google, but incentives are aligned
● More on this in tomorrow's presentation
17. 17
2.4. Links
● General doc:
● https://source.android.com/devices/architecture/hidl/
● C++
● https://source.android.com/devices/architecture/hidl-
cpp/
● Java
● https://source.android.com/devices/architecture/hidl-
java/
18. 18
3. HAL Architecture Rework
● Overall architecture
● Detailed architecture / Java
● Detailed architecture / C++
23. 23
4.1. JNI Layer
●
JNI Java<->C/C++ method/function registration -- same before and after Treble:
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/frameworks/base/services/java/com/android/server/SystemServer.java
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/frameworks/base/services/java/com/android/server/SystemServer.java#367
● System.loadLibrary("android_servers"); ==> Loads libandroid_servers.so
●
This file defines which JNI files to compile into libandroid_servers.so:
●
http://aosp.opersys.com/xref/android-8.1.0_r9/xref/frameworks/base/services/core/jni/Android.mk
●
Including: com_android_server_lights_LightsService.cpp
●
This file defines the rules to build libandroid_servers.so:
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/frameworks/base/services/Android.mk
●
Another file compiled into libandroid_servers.so is onload.cpp:
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/frameworks/base/services/core/jni/onload.cpp
● That file contains a function called: JNI_OnLoad()
● JNI_OnLoad() is automatically called by ART when libandroid_servers.so is loaded.
●
JNI_OnLoad contains calls to JNI registration functions, such as register_android_server_LightsService(env);
●
http://aosp.opersys.com/xref/android-
8.1.0_r1/xref/frameworks/base/services/core/jni/com_android_server_lights_LightsService.cpp:register_android_server_LightsService()
● JniRegisterNativeMethods()
●
jniRegisterNativeMethods() calls into the ART VM to register C/C++ calls against a Java class.
25. 25
4.3. HIDL Glue
● There are two main paths with HIDL:
●
Same-Process (passthrough)
●
Binderized
● This build file can generate BOTH options:
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/hardware/interfaces/light/2.0/default/Android.mk
– android.hardware.light@2.0-impl.so ==> default same-process implementation
– android.hardware.light@2.0-service ==> binderized remote process
● The default binderized process in the case of lights (i.e. android.hardware.light@2.0-service) essentially loads
android.hardware.light@2.0-impl.so.
● Example *legacy* lights module implementation:
● http://aosp.opersys.com/xref/android-8.1.0_r9/xref/device/huawei/angler/liblight/lights.c
●
This is the file that would be calling into drivers in the kernel.
● The decision to use passthrough vs. binderized service depends on the board-specific manifest.xml:
●
http://aosp.opersys.com/xref/android-8.1.0_r9/xref/device/generic/goldfish/manifest.xml
26. 26
5. Adding a New HIDL
● New interface definition
● Use of update-makefiles.sh
● Use of hidl-gen
● See/implement default implementation
● Tweak default implementation makefiles
● Add entry in product manifest
27. 27
6. Support Infrastructure
● HIDL tools (host + device) + libraries
● Manifest file parts + device-specific mk files
● Online doc/reference
● On-device:
● File locations
● Loaded files in address space
● Processes
● Etc.