SlideShare una empresa de Scribd logo
1 de 8
Descargar para leer sin conexión
GSMPhone

          1                             10

                       RIL
                                              9
                                                                    Android 
2
        RILSender               RILReceiver                        Telephony 
          3                             8

                                                      Java API
                                                                     Stack
                      RILD
                                                      Native API
         4                              7

                       libril
                                              6
         5                              6

              Proprietary RIL library              
                                                         © David Marques ­ dpsmarques@gmail.com
GSMPhone

          1                          10

                      RIL


The  com.android.internal.telephony.gsm.GSMPhone  class  implements  a  GSM  phone  and 
exposes  all  phone  capabilities  to  the  other  components  inside  the  android  framework.  This 
class interfaces with the radio interface layer in order to communicate to the baseband radio 
modem  though  the  com.android.internal.telephony.RIL  class.  The  top­down  communication 
between these layers is done by asynchronous function calls passing an android.os.Message 
instance to be used in order to send the response back to the function caller with the function 
result within the message itself.




                                                   
RIL
                                               9


2
        RILSender           RILReceiver




The  com.android.internal.telephony.RIL  class  has  two  internal  classes  responsible  for 
sending the requests and receiving the responses to and from the RIL daemon respectively. 
Both  RILSender  and  RILReceiver  classes  run  on  its  own  threads  interacting  with  the  RIL 
daemon through a linux socket to send and receive messages to the baseband radio. 




                                                    
RILSender          RILReceiver

       3                       8

                 RILD




The RIL daemon (RILD) is a native linux process that communicates with the Java telephony 
API through a linux socket exposing a radio implementation agnostic protocol. 




                                              
RILD

      4                             7

                   libril
                                            6
      5                             6

          Proprietary RIL library


The  RIL  daemon  (RILD)  loads  the  proprietary  RIL  library  and  registers  its  radio  specific 
functions  implementation  into  the  telephony  stack.  The  RILD  receives  requests  through  a 
linux  socket  and  processes  the  request  calling  the  proprietary  library's  radio  function 
implementation  passing  the  appropriate  parameters.  The  proprietary  library  returns  a 
response  to  the  telephony  stack  through  a  callback  function  which  marshals  the  response 
and sends it back to the Java API though the same socket used to receive the request. The 
Java  layers  processes  the  request  on  the  RILReceiver  class  and  forwards  the  response  to 
the original request owner.



                                                   
Solicited command flow: android RIL -> proprietary RIL



                 R                            RILD
                 I                                                                     libril
                 L
                                                                                      proprietary ril




1. Phone implementation calls RIL class to communicate with the baseband radio;
2.  RIL class creates a Parcel and fills its content with the specified parameters;
3.  RIL marshals the parcel into raw data and sends through the RILD socket;
4. RILD unmarshals the raw data into a Parcel and extracts the request parameters from the 
Parcel;
5.  RILD  calls  through  libril  the  proprietary  RIL  library  request  handler  function  passing  the 
extracted parameters;
Solicited command flow: proprietary RIL -> android RIL



                 R                           RILD
                 I                                                                    libril
                 L
                                                                                     proprietary ril




1. Proprietary RIL library calls the response function on the android libril passing the result;
2. Android libril creates a Parcel, puts the result within it and marshals the Parcel into raw 
data to be sent through the RILD socket back to the Java layer;
3.  At  the  Java  layer  the  raw  data  that  came  from  the  socket  is  unmarshaled  into  a  Parcel 
and the result is extracted and sent to the original request owner;
4. The request owner receives the response on a Message instance passed to the RIL class 
method called to make the request;
Note:  All  the  information  in  this  document  comes 
from  the  Android  2.2  release  (aka  Froyo)  of  the 
Android  open­source  project.  Any  future  updates 
may  invalidate  the  information  contained  on  this 
document.

Más contenido relacionado

La actualidad más candente

Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Using and Customizing the Android Framework / part 4 of Embedded Android Work...Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Opersys inc.
 
Android Boot Time Optimization
Android Boot Time OptimizationAndroid Boot Time Optimization
Android Boot Time Optimization
Kan-Ru Chen
 
Overview of Android binder IPC implementation
Overview of Android binder IPC implementationOverview of Android binder IPC implementation
Overview of Android binder IPC implementation
Chethan Pchethan
 
ADB(Android Debug Bridge): How it works?
ADB(Android Debug Bridge): How it works?ADB(Android Debug Bridge): How it works?
ADB(Android Debug Bridge): How it works?
Tetsuyuki Kobayashi
 

La actualidad más candente (20)

Embedded Android : System Development - Part II (HAL)
Embedded Android : System Development - Part II (HAL)Embedded Android : System Development - Part II (HAL)
Embedded Android : System Development - Part II (HAL)
 
Android IPC Mechanism
Android IPC MechanismAndroid IPC Mechanism
Android IPC Mechanism
 
Android internals By Rajesh Khetan
Android internals By Rajesh KhetanAndroid internals By Rajesh Khetan
Android internals By Rajesh Khetan
 
Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Using and Customizing the Android Framework / part 4 of Embedded Android Work...Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Using and Customizing the Android Framework / part 4 of Embedded Android Work...
 
Binder: Android IPC
Binder: Android IPCBinder: Android IPC
Binder: Android IPC
 
Android Boot Time Optimization
Android Boot Time OptimizationAndroid Boot Time Optimization
Android Boot Time Optimization
 
Inside Android's UI
Inside Android's UIInside Android's UI
Inside Android's UI
 
Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)
 
Design and Concepts of Android Graphics
Design and Concepts of Android GraphicsDesign and Concepts of Android Graphics
Design and Concepts of Android Graphics
 
Introduction to Android Window System
Introduction to Android Window SystemIntroduction to Android Window System
Introduction to Android Window System
 
Overview of Android binder IPC implementation
Overview of Android binder IPC implementationOverview of Android binder IPC implementation
Overview of Android binder IPC implementation
 
Android Things : Building Embedded Devices
Android Things : Building Embedded DevicesAndroid Things : Building Embedded Devices
Android Things : Building Embedded Devices
 
Explore Android Internals
Explore Android InternalsExplore Android Internals
Explore Android Internals
 
Pentesting Android Apps using Frida (Beginners)
Pentesting Android Apps using Frida (Beginners)Pentesting Android Apps using Frida (Beginners)
Pentesting Android Apps using Frida (Beginners)
 
Applied Computer Science Concepts in Android
Applied Computer Science Concepts in AndroidApplied Computer Science Concepts in Android
Applied Computer Science Concepts in Android
 
Q4.11: Porting Android to new Platforms
Q4.11: Porting Android to new PlatformsQ4.11: Porting Android to new Platforms
Q4.11: Porting Android to new Platforms
 
ADB(Android Debug Bridge): How it works?
ADB(Android Debug Bridge): How it works?ADB(Android Debug Bridge): How it works?
ADB(Android Debug Bridge): How it works?
 
Embedded Android : System Development - Part I
Embedded Android : System Development - Part IEmbedded Android : System Development - Part I
Embedded Android : System Development - Part I
 
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
 
Embedded Android : System Development - Part III
Embedded Android : System Development - Part IIIEmbedded Android : System Development - Part III
Embedded Android : System Development - Part III
 

Destacado

Android Telephony Manager and SMS
Android Telephony Manager and SMSAndroid Telephony Manager and SMS
Android Telephony Manager and SMS
Jussi Pohjolainen
 
Psi android telephony_case_study_v10
Psi android telephony_case_study_v10Psi android telephony_case_study_v10
Psi android telephony_case_study_v10
Primesoftinc
 
Voice encryption for gsm using arduino
Voice encryption for gsm using arduinoVoice encryption for gsm using arduino
Voice encryption for gsm using arduino
iruldaworld
 
RT Procedure new KTM
RT Procedure new KTMRT Procedure new KTM
RT Procedure new KTM
Raj Pradhan
 
What is a smartphone-R1
What is a smartphone-R1What is a smartphone-R1
What is a smartphone-R1
Yong Heui Cho
 
Android Application Component: BroadcastReceiver Tutorial
Android Application Component: BroadcastReceiver TutorialAndroid Application Component: BroadcastReceiver Tutorial
Android Application Component: BroadcastReceiver Tutorial
Ahsanul Karim
 
Data Handning with Sqlite for Android
Data Handning with Sqlite for AndroidData Handning with Sqlite for Android
Data Handning with Sqlite for Android
Jakir Hossain
 

Destacado (20)

Android Telephony Manager and SMS
Android Telephony Manager and SMSAndroid Telephony Manager and SMS
Android Telephony Manager and SMS
 
Telephony API
Telephony APITelephony API
Telephony API
 
Android internals 10 - Debugging/Profiling, Bluetooth/WiFI/RIL (rev_1.1)
Android internals 10 - Debugging/Profiling, Bluetooth/WiFI/RIL (rev_1.1)Android internals 10 - Debugging/Profiling, Bluetooth/WiFI/RIL (rev_1.1)
Android internals 10 - Debugging/Profiling, Bluetooth/WiFI/RIL (rev_1.1)
 
Psi android telephony_case_study_v10
Psi android telephony_case_study_v10Psi android telephony_case_study_v10
Psi android telephony_case_study_v10
 
[2C6]SQLite DB 의 입출력 특성분석 : Android 와 Tizen 사례
[2C6]SQLite DB 의 입출력 특성분석 : Android 와 Tizen 사례[2C6]SQLite DB 의 입출력 특성분석 : Android 와 Tizen 사례
[2C6]SQLite DB 의 입출력 특성분석 : Android 와 Tizen 사례
 
Android Core Aula 5 - RIL (Radio Interface Layer)
Android Core Aula 5 -  RIL (Radio Interface Layer)Android Core Aula 5 -  RIL (Radio Interface Layer)
Android Core Aula 5 - RIL (Radio Interface Layer)
 
Embedded Android Workshop at Embedded Linux Conference Europe 2011
Embedded Android Workshop at Embedded Linux Conference Europe 2011Embedded Android Workshop at Embedded Linux Conference Europe 2011
Embedded Android Workshop at Embedded Linux Conference Europe 2011
 
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM SystemLabmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
 
Encrypted Voice Communications
Encrypted Voice CommunicationsEncrypted Voice Communications
Encrypted Voice Communications
 
Kernel modules
Kernel modulesKernel modules
Kernel modules
 
Voice encryption for gsm using arduino
Voice encryption for gsm using arduinoVoice encryption for gsm using arduino
Voice encryption for gsm using arduino
 
RT Procedure new KTM
RT Procedure new KTMRT Procedure new KTM
RT Procedure new KTM
 
Cellular network
Cellular networkCellular network
Cellular network
 
Linux kernel modules
Linux kernel modulesLinux kernel modules
Linux kernel modules
 
5432 cellular network
5432 cellular network5432 cellular network
5432 cellular network
 
Kernel Configuration and Compilation
Kernel Configuration and CompilationKernel Configuration and Compilation
Kernel Configuration and Compilation
 
What is a smartphone-R1
What is a smartphone-R1What is a smartphone-R1
What is a smartphone-R1
 
Voice securityprotocol review
Voice securityprotocol reviewVoice securityprotocol review
Voice securityprotocol review
 
Android Application Component: BroadcastReceiver Tutorial
Android Application Component: BroadcastReceiver TutorialAndroid Application Component: BroadcastReceiver Tutorial
Android Application Component: BroadcastReceiver Tutorial
 
Data Handning with Sqlite for Android
Data Handning with Sqlite for AndroidData Handning with Sqlite for Android
Data Handning with Sqlite for Android
 

Similar a Android telephony stack

Cisco ios ip routing advanced rip features
Cisco ios ip routing advanced rip featuresCisco ios ip routing advanced rip features
Cisco ios ip routing advanced rip features
Kong King
 

Similar a Android telephony stack (8)

Android - Phone Calls
Android - Phone CallsAndroid - Phone Calls
Android - Phone Calls
 
Remote Method Innovation (RMI) In JAVA
Remote Method Innovation (RMI) In JAVARemote Method Innovation (RMI) In JAVA
Remote Method Innovation (RMI) In JAVA
 
CORBA.ppt
CORBA.pptCORBA.ppt
CORBA.ppt
 
Presentation 4 rifidi emulator lab
Presentation 4 rifidi emulator labPresentation 4 rifidi emulator lab
Presentation 4 rifidi emulator lab
 
Remote Method Invocation (RMI)
Remote Method Invocation (RMI)Remote Method Invocation (RMI)
Remote Method Invocation (RMI)
 
Cisco ios ip routing advanced rip features
Cisco ios ip routing advanced rip featuresCisco ios ip routing advanced rip features
Cisco ios ip routing advanced rip features
 
Distributed computing - november 2006
Distributed computing  - november 2006Distributed computing  - november 2006
Distributed computing - november 2006
 
Rfc high res 3 july 2012
Rfc high res   3 july 2012Rfc high res   3 july 2012
Rfc high res 3 july 2012
 

Último

Último (20)

Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 

Android telephony stack

  • 1. GSMPhone 1 10 RIL 9 Android  2 RILSender RILReceiver Telephony  3 8 Java API Stack RILD Native API 4 7 libril 6 5 6   Proprietary RIL library   © David Marques ­ dpsmarques@gmail.com
  • 2. GSMPhone 1 10 RIL The  com.android.internal.telephony.gsm.GSMPhone  class  implements  a  GSM  phone  and  exposes  all  phone  capabilities  to  the  other  components  inside  the  android  framework.  This  class interfaces with the radio interface layer in order to communicate to the baseband radio  modem  though  the  com.android.internal.telephony.RIL  class.  The  top­down  communication  between these layers is done by asynchronous function calls passing an android.os.Message  instance to be used in order to send the response back to the function caller with the function  result within the message itself.    
  • 3. RIL 9 2 RILSender RILReceiver The  com.android.internal.telephony.RIL  class  has  two  internal  classes  responsible  for  sending the requests and receiving the responses to and from the RIL daemon respectively.  Both  RILSender  and  RILReceiver  classes  run  on  its  own  threads  interacting  with  the  RIL  daemon through a linux socket to send and receive messages to the baseband radio.     
  • 4. RILSender RILReceiver 3 8 RILD The RIL daemon (RILD) is a native linux process that communicates with the Java telephony  API through a linux socket exposing a radio implementation agnostic protocol.     
  • 5. RILD 4 7 libril 6 5 6 Proprietary RIL library The  RIL  daemon  (RILD)  loads  the  proprietary  RIL  library  and  registers  its  radio  specific  functions  implementation  into  the  telephony  stack.  The  RILD  receives  requests  through  a  linux  socket  and  processes  the  request  calling  the  proprietary  library's  radio  function  implementation  passing  the  appropriate  parameters.  The  proprietary  library  returns  a  response  to  the  telephony  stack  through  a  callback  function  which  marshals  the  response  and sends it back to the Java API though the same socket used to receive the request. The  Java  layers  processes  the  request  on  the  RILReceiver  class  and  forwards  the  response  to  the original request owner.    
  • 6. Solicited command flow: android RIL -> proprietary RIL R RILD I libril L proprietary ril 1. Phone implementation calls RIL class to communicate with the baseband radio; 2.  RIL class creates a Parcel and fills its content with the specified parameters; 3.  RIL marshals the parcel into raw data and sends through the RILD socket; 4. RILD unmarshals the raw data into a Parcel and extracts the request parameters from the  Parcel; 5.  RILD  calls  through  libril  the  proprietary  RIL  library  request  handler  function  passing  the  extracted parameters;
  • 7. Solicited command flow: proprietary RIL -> android RIL R RILD I libril L proprietary ril 1. Proprietary RIL library calls the response function on the android libril passing the result; 2. Android libril creates a Parcel, puts the result within it and marshals the Parcel into raw  data to be sent through the RILD socket back to the Java layer; 3.  At  the  Java  layer  the  raw  data  that  came  from  the  socket  is  unmarshaled  into  a  Parcel  and the result is extracted and sent to the original request owner; 4. The request owner receives the response on a Message instance passed to the RIL class  method called to make the request;
  • 8. Note:  All  the  information  in  this  document  comes  from  the  Android  2.2  release  (aka  Froyo)  of  the  Android  open­source  project.  Any  future  updates  may  invalidate  the  information  contained  on  this  document.