SlideShare a Scribd company logo
Android MO Call Flow – Code
Overview – ANDROID (N and below)
The MAIN components
• The DIALER – UI
• TELECOM FRAMEWORK / SERVICES
• TELEPHONY FRAMEWORK / SERVICES
• RADIO INTERFACE LAYER (RIL)
The UI or DIALER
~This is the user interface for making a CALL.
~A Call is transferred from the UI( your dialer) to the Android Framework through
Broadcast Actions.
~These Actions are defined in android source and can be found here :Call Defines
• public static final String ACTION_DIAL = "android.intent.action.DIAL";
• public static final String ACTION_CALL = "android.intent.action.CALL";
• public static final String ACTION_CALL_EMERGENCY = "android.intent.action.CALL_EMERGENCY";
These broadcasts along with bundles containing the user data (dialed
number/information)are received by the Telecom service and further processing of the CALL
happens
TELECOM
File : Packages/services/Telecomm/AndroidManifest.xml Telecom Manifest
• The Telecom Framework. (Components: Connection Service and InCallUiService). The telecom service , if you see binds to
ITelscomService :
The Telecom Service receives the Call Intent from the Dialer with different
permissions –
TELECOM contd..
• The Call Activity. CallActivity.java
• As we reach here, The received intent is processed (the processing
basically checks if something needs to be restored from the bundle, check
privileges, allow/disallow based on restrictions.
• Finally, sendBroadcastAsUser(intent, UserHandle.OWNER); is called.
TELECOM Contd ..
CallReceiver.java
• This is the default broadcast receiver for Incoming and Out Going Calls. Here , as we are discussing about outgoing
calls, let us see how that goes ~
TELECOM Contd ..
• CallReceiver Continued :
• -----------------------------The descriptions are sin the code are self-explanatory----------------------------
• The NewOutgoingCallBroadcaster further tranfers the call to Call Manager, after its own processing.Check
out the Class to see what things it takes care of : NewOutgoingCallIntentBroadcaster.java
TELECOM Contd ..
• CallsManager.java
TELECOM Contd ..
• Call.java
The Create ConnectionProcessor processes/handles the connection logics.
TELECOM Contd ..
• CreateConnectionProcessor.java
TELECOM Contd ..
• CreateConnectionProcessor.java
• It firstly creates and CallAttemptRecord and collects into its list, then process it by a new
class' function ConnectionServiceWrapper.createConnection().
TELECOM Contd ..
• CreateConnectionProcessor.java
/* in this API(attemptNextPhoneAccount), A ConnectionServiceWrapper is used[NEXT
SLIDE]. The logic of creation of this Wrapper class, initialization etc. will be discussed
separately. You are welcome to look into the implementation/code yourself.*/
TELECOM Contd ..
TELECOM Contd ..
• ConnectionServiceWrapper.java. See the definition of the class
Here is where the IConnectionService is bound. Check the below Function: It is in the ServiceBinder the class
which is the parent class of ConnectionServiceWrapper.
TELECOM Contd ..
• ServiceBinder.java
• Let us check the CreateConnection API in detail. A BinderCallBack object [implemented in ServiceBinder ]
is associated with mBinder. What is mBinder?
~ private Binder2 mBinder = new Binder2() / / code in ConnectionServiceWrapper
~Then, mBinder.bind(callback,call) is done so the callback is associated with the call. We will see
the implementation of Binder2 class in a short while. In the onSuccess() of the Callback,
mServiceInterface.createConnection is done which is actually the implementation in the stub.
• Let us check out the important parts of ServiceBinder.java
TELECOM Contd ..
Second, the Binder2 Class. As per the code description, It Performs an asynchronous bind to the
Service and executes the specific callback. Let us go step by step with it here –
~ mCallbacks.add(callback); -
~ setBinder(binder); -- > setServiceInterface(binder); //in the child class where we retrieve
IConnnectionnService as interface.
~ ServiceConnection connection = new ServiceBinderConnection(call);
~ mContext.bindService(serviceIntent, connection, bindingFlags);
~ private final class ServiceBinderConnection implements ServiceConnection { …
~ handleFailedConnection(); -- > callback.onSuccess(); // Call back that was bound to.
ServiceConnected(ComponentName..
TELECOM Contd ..
• The Actual implmementation of the IConnectionService –
• Check the Constructor of connection Service Wrapper. Look for :
super(ConnectionService.SERVICE_INTERFACE, componentName, context, userHandle);
• Check frameworks/base/telecomm/java/android/telecom/ConnectionService.java
• As I have already pointed out, this service is bound in the Binder2 class of ServiceBinder.java and through
the following call mServiceInterface is obtained.
(Check previous Slides)
setBinder(binder); -- > setServiceInterface(binder); //in the child class where we retrieve
IConnnectionnService as interface.
• So, there it is , Telecom is all set to transfer the call to Telephony now which implements the
ConnectionService.
Telephony FW
• Here, the android.telecom.ConnectionService is registered.
This is extended by TelephonyConnectionService.java
From here, Connection onCreateIncomingConnection will call
placeOutgoingConnection() and will transfer the Call to the Target Phone.
Telephony FW
*Here is to note that the target phone is made at the boot time based on the NW
TYPE the phone latches to. It can be of type – GSM, CDMA or IMS. The instance of
the PHONE is provided to TelephonyConnectionService with the PhoneFactory Class.
The discussion about creation of Phone object will be left for another day.
TelephonyConnectionService.java
Telephony FW
The Phone Call in PHONE.
Let us assume, we have a GSM Phone as our Active Phone. Now, DIAL(..) will
come here.
GSMPhone.java
From GSMPhone , the Call is transferred to the CallTracker, where we have
the RIL Command interfaces implemented, which in turn transfers the Call to
modem through the RIL command interface.
Telephony FW
• GsmCallTracker.java
• public CommandsInterface mCM; is associated with each Phone which is
the connection point to RIL.java. You can find and understand it in
PhoneBase.java. The implementation of Commands Interface is in RIL.java
Telephony FW(RIL-J)
• Commands Interface Implementation and DIAL and request to RILD through socket. The details are for
another day.
RIL.java
Thank You
• So, that was a very brief overview of the flow of APIs for an
Android Outgoing CALL. Going forward we will discuss about the
RIL and the PHONE class hierarchy in a detailed fashion.
• The above slides were based on Android (N) code. There is a
major change in OOS architecture as far as the Radio interface is
concerned. We shall discuss that too in the future.
• Credits : Android Open Source Project.

More Related Content

What's hot

Android Binder: Deep Dive
Android Binder: Deep DiveAndroid Binder: Deep Dive
Android Binder: Deep Dive
Zafar Shahid, PhD
 
Embedded Android : System Development - Part III
Embedded Android : System Development - Part IIIEmbedded Android : System Development - Part III
Embedded Android : System Development - Part III
Emertxe Information Technologies Pvt Ltd
 
Maven
MavenMaven
Android graphic system (SurfaceFlinger) : Design Pattern's perspective
Android graphic system (SurfaceFlinger) : Design Pattern's perspectiveAndroid graphic system (SurfaceFlinger) : Design Pattern's perspective
Android graphic system (SurfaceFlinger) : Design Pattern's perspective
Bin Chen
 
Learning AOSP - Android Booting Process
Learning AOSP - Android Booting ProcessLearning AOSP - Android Booting Process
Learning AOSP - Android Booting Process
Nanik Tolaram
 
Understanding the Android System Server
Understanding the Android System ServerUnderstanding the Android System Server
Understanding the Android System Server
Opersys inc.
 
Aidl service
Aidl serviceAidl service
Aidl service
Anjan Debnath
 
Explore Android Internals
Explore Android InternalsExplore Android Internals
Explore Android Internals
National Cheng Kung University
 
Android Binder IPC for Linux
Android Binder IPC for LinuxAndroid Binder IPC for Linux
Android Binder IPC for Linux
Yu-Hsin Hung
 
Embedded Android : System Development - Part IV (Android System Services)
Embedded Android : System Development - Part IV (Android System Services)Embedded Android : System Development - Part IV (Android System Services)
Embedded Android : System Development - Part IV (Android System Services)
Emertxe Information Technologies Pvt Ltd
 
Embedded Android : System Development - Part I
Embedded Android : System Development - Part IEmbedded Android : System Development - Part I
Embedded Android : System Development - Part I
Emertxe Information Technologies Pvt Ltd
 
Android Booting Sequence
Android Booting SequenceAndroid Booting Sequence
Android Booting Sequence
Jayanta Ghoshal
 
Low Level View of Android System Architecture
Low Level View of Android System ArchitectureLow Level View of Android System Architecture
Low Level View of Android System Architecture
National Cheng Kung University
 
Android OTA updates
Android OTA updatesAndroid OTA updates
Android OTA updates
Gary Bisson
 
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...Opersys inc.
 
Learning AOSP - Android Linux Device Driver
Learning AOSP - Android Linux Device DriverLearning AOSP - Android Linux Device Driver
Learning AOSP - Android Linux Device Driver
Nanik Tolaram
 
Booting Android: bootloaders, fastboot and boot images
Booting Android: bootloaders, fastboot and boot imagesBooting Android: bootloaders, fastboot and boot images
Booting Android: bootloaders, fastboot and boot images
Chris Simmonds
 
40234553 drive-test
40234553 drive-test40234553 drive-test
40234553 drive-test
محمد مشعل
 
Binder: Android IPC
Binder: Android IPCBinder: Android IPC
Binder: Android IPC
Shaul Rosenzwieg
 

What's hot (20)

Android Binder: Deep Dive
Android Binder: Deep DiveAndroid Binder: Deep Dive
Android Binder: Deep Dive
 
Embedded Android : System Development - Part III
Embedded Android : System Development - Part IIIEmbedded Android : System Development - Part III
Embedded Android : System Development - Part III
 
Maven
MavenMaven
Maven
 
Android graphic system (SurfaceFlinger) : Design Pattern's perspective
Android graphic system (SurfaceFlinger) : Design Pattern's perspectiveAndroid graphic system (SurfaceFlinger) : Design Pattern's perspective
Android graphic system (SurfaceFlinger) : Design Pattern's perspective
 
Learning AOSP - Android Booting Process
Learning AOSP - Android Booting ProcessLearning AOSP - Android Booting Process
Learning AOSP - Android Booting Process
 
Understanding the Android System Server
Understanding the Android System ServerUnderstanding the Android System Server
Understanding the Android System Server
 
Aidl service
Aidl serviceAidl service
Aidl service
 
Explore Android Internals
Explore Android InternalsExplore Android Internals
Explore Android Internals
 
Android Binder IPC for Linux
Android Binder IPC for LinuxAndroid Binder IPC for Linux
Android Binder IPC for Linux
 
Embedded Android : System Development - Part IV (Android System Services)
Embedded Android : System Development - Part IV (Android System Services)Embedded Android : System Development - Part IV (Android System Services)
Embedded Android : System Development - Part IV (Android System Services)
 
Embedded Android : System Development - Part I
Embedded Android : System Development - Part IEmbedded Android : System Development - Part I
Embedded Android : System Development - Part I
 
Android Booting Sequence
Android Booting SequenceAndroid Booting Sequence
Android Booting Sequence
 
Low Level View of Android System Architecture
Low Level View of Android System ArchitectureLow Level View of Android System Architecture
Low Level View of Android System Architecture
 
Android OTA updates
Android OTA updatesAndroid OTA updates
Android OTA updates
 
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...
Native Android Userspace part of the Embedded Android Workshop at Linaro Conn...
 
Learning AOSP - Android Linux Device Driver
Learning AOSP - Android Linux Device DriverLearning AOSP - Android Linux Device Driver
Learning AOSP - Android Linux Device Driver
 
Booting Android: bootloaders, fastboot and boot images
Booting Android: bootloaders, fastboot and boot imagesBooting Android: bootloaders, fastboot and boot images
Booting Android: bootloaders, fastboot and boot images
 
40234553 drive-test
40234553 drive-test40234553 drive-test
40234553 drive-test
 
Binder: Android IPC
Binder: Android IPCBinder: Android IPC
Binder: Android IPC
 
Tomcat
TomcatTomcat
Tomcat
 

Similar to Outgoing Call Flow ~ Android ( < Nougat).

Vert.x for Microservices Architecture
Vert.x for Microservices ArchitectureVert.x for Microservices Architecture
Vert.x for Microservices Architecture
Idan Fridman
 
Android framework design and development
Android framework design and developmentAndroid framework design and development
Android framework design and development
ramalinga prasad tadepalli
 
Call Center Operation
Call Center OperationCall Center Operation
Call Center OperationTaaham
 
WCF tutorial
WCF tutorialWCF tutorial
WCF tutorial
Abhi Arya
 
Ind twss-pdf
Ind twss-pdfInd twss-pdf
Ind twss-pdf
Raghu Juluri
 
Extract from TEMS Investigation 17.0 Help
Extract from TEMS Investigation 17.0 HelpExtract from TEMS Investigation 17.0 Help
Extract from TEMS Investigation 17.0 HelpPeter Eriksson
 
INLINE FUNCTIONS IOT68.pptx
INLINE FUNCTIONS IOT68.pptxINLINE FUNCTIONS IOT68.pptx
INLINE FUNCTIONS IOT68.pptx
ZalakPatel228771
 
Architecture your android_application
Architecture your android_applicationArchitecture your android_application
Architecture your android_application
Mark Brady
 
IBM iSeries Terminal Based Performance Testing with Rational Performance Tester
IBM iSeries Terminal Based Performance Testing with Rational Performance TesterIBM iSeries Terminal Based Performance Testing with Rational Performance Tester
IBM iSeries Terminal Based Performance Testing with Rational Performance Tester
Winton Winton
 
Real Time App with SignalR
Real Time App with SignalRReal Time App with SignalR
Real Time App with SignalR
Mojammel Haque
 
You are a new administrator for Contoso, Ltd., working on a test dep.docx
You are a new administrator for Contoso, Ltd., working on a test dep.docxYou are a new administrator for Contoso, Ltd., working on a test dep.docx
You are a new administrator for Contoso, Ltd., working on a test dep.docx
maryettamckinnel
 
AltBeacon in the IoT
AltBeacon in the IoTAltBeacon in the IoT
AltBeacon in the IoT
AntonioIonta
 
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
InfluxData
 
I hear you like meshes, here’s a mesh to connect your meshes
I hear you like meshes, here’s a mesh to connect your meshesI hear you like meshes, here’s a mesh to connect your meshes
I hear you like meshes, here’s a mesh to connect your meshes
All Things Open
 

Similar to Outgoing Call Flow ~ Android ( < Nougat). (20)

Vert.x for Microservices Architecture
Vert.x for Microservices ArchitectureVert.x for Microservices Architecture
Vert.x for Microservices Architecture
 
Android framework design and development
Android framework design and developmentAndroid framework design and development
Android framework design and development
 
Call Center Operation
Call Center OperationCall Center Operation
Call Center Operation
 
WCF tutorial
WCF tutorialWCF tutorial
WCF tutorial
 
Dwr
DwrDwr
Dwr
 
Ind twss-pdf
Ind twss-pdfInd twss-pdf
Ind twss-pdf
 
Angularjs
AngularjsAngularjs
Angularjs
 
Extract from TEMS Investigation 17.0 Help
Extract from TEMS Investigation 17.0 HelpExtract from TEMS Investigation 17.0 Help
Extract from TEMS Investigation 17.0 Help
 
Rmi
RmiRmi
Rmi
 
Rmi
RmiRmi
Rmi
 
INLINE FUNCTIONS IOT68.pptx
INLINE FUNCTIONS IOT68.pptxINLINE FUNCTIONS IOT68.pptx
INLINE FUNCTIONS IOT68.pptx
 
Architecture your android_application
Architecture your android_applicationArchitecture your android_application
Architecture your android_application
 
IBM iSeries Terminal Based Performance Testing with Rational Performance Tester
IBM iSeries Terminal Based Performance Testing with Rational Performance TesterIBM iSeries Terminal Based Performance Testing with Rational Performance Tester
IBM iSeries Terminal Based Performance Testing with Rational Performance Tester
 
Session 1
Session 1Session 1
Session 1
 
Nesc tutorial
Nesc tutorialNesc tutorial
Nesc tutorial
 
Real Time App with SignalR
Real Time App with SignalRReal Time App with SignalR
Real Time App with SignalR
 
You are a new administrator for Contoso, Ltd., working on a test dep.docx
You are a new administrator for Contoso, Ltd., working on a test dep.docxYou are a new administrator for Contoso, Ltd., working on a test dep.docx
You are a new administrator for Contoso, Ltd., working on a test dep.docx
 
AltBeacon in the IoT
AltBeacon in the IoTAltBeacon in the IoT
AltBeacon in the IoT
 
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
Samantha Wang [InfluxData] | Data Collection Overview | InfluxDays 2022
 
I hear you like meshes, here’s a mesh to connect your meshes
I hear you like meshes, here’s a mesh to connect your meshesI hear you like meshes, here’s a mesh to connect your meshes
I hear you like meshes, here’s a mesh to connect your meshes
 

Recently uploaded

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
Pierluigi Pugliese
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
sonjaschweigert1
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
RinaMondal9
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
UiPathCommunity
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 

Recently uploaded (20)

Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024By Design, not by Accident - Agile Venture Bolzano 2024
By Design, not by Accident - Agile Venture Bolzano 2024
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...A tale of scale & speed: How the US Navy is enabling software delivery from l...
A tale of scale & speed: How the US Navy is enabling software delivery from l...
 
Free Complete Python - A step towards Data Science
Free Complete Python - A step towards Data ScienceFree Complete Python - A step towards Data Science
Free Complete Python - A step towards Data Science
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
Assure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyesAssure Contact Center Experiences for Your Customers With ThousandEyes
Assure Contact Center Experiences for Your Customers With ThousandEyes
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 

Outgoing Call Flow ~ Android ( < Nougat).

  • 1. Android MO Call Flow – Code Overview – ANDROID (N and below)
  • 2. The MAIN components • The DIALER – UI • TELECOM FRAMEWORK / SERVICES • TELEPHONY FRAMEWORK / SERVICES • RADIO INTERFACE LAYER (RIL)
  • 3. The UI or DIALER ~This is the user interface for making a CALL. ~A Call is transferred from the UI( your dialer) to the Android Framework through Broadcast Actions. ~These Actions are defined in android source and can be found here :Call Defines • public static final String ACTION_DIAL = "android.intent.action.DIAL"; • public static final String ACTION_CALL = "android.intent.action.CALL"; • public static final String ACTION_CALL_EMERGENCY = "android.intent.action.CALL_EMERGENCY"; These broadcasts along with bundles containing the user data (dialed number/information)are received by the Telecom service and further processing of the CALL happens
  • 4. TELECOM File : Packages/services/Telecomm/AndroidManifest.xml Telecom Manifest • The Telecom Framework. (Components: Connection Service and InCallUiService). The telecom service , if you see binds to ITelscomService : The Telecom Service receives the Call Intent from the Dialer with different permissions –
  • 5. TELECOM contd.. • The Call Activity. CallActivity.java • As we reach here, The received intent is processed (the processing basically checks if something needs to be restored from the bundle, check privileges, allow/disallow based on restrictions. • Finally, sendBroadcastAsUser(intent, UserHandle.OWNER); is called.
  • 6. TELECOM Contd .. CallReceiver.java • This is the default broadcast receiver for Incoming and Out Going Calls. Here , as we are discussing about outgoing calls, let us see how that goes ~
  • 7. TELECOM Contd .. • CallReceiver Continued : • -----------------------------The descriptions are sin the code are self-explanatory---------------------------- • The NewOutgoingCallBroadcaster further tranfers the call to Call Manager, after its own processing.Check out the Class to see what things it takes care of : NewOutgoingCallIntentBroadcaster.java
  • 8. TELECOM Contd .. • CallsManager.java
  • 9. TELECOM Contd .. • Call.java The Create ConnectionProcessor processes/handles the connection logics.
  • 10. TELECOM Contd .. • CreateConnectionProcessor.java
  • 11. TELECOM Contd .. • CreateConnectionProcessor.java • It firstly creates and CallAttemptRecord and collects into its list, then process it by a new class' function ConnectionServiceWrapper.createConnection().
  • 12. TELECOM Contd .. • CreateConnectionProcessor.java /* in this API(attemptNextPhoneAccount), A ConnectionServiceWrapper is used[NEXT SLIDE]. The logic of creation of this Wrapper class, initialization etc. will be discussed separately. You are welcome to look into the implementation/code yourself.*/
  • 14. TELECOM Contd .. • ConnectionServiceWrapper.java. See the definition of the class Here is where the IConnectionService is bound. Check the below Function: It is in the ServiceBinder the class which is the parent class of ConnectionServiceWrapper.
  • 15. TELECOM Contd .. • ServiceBinder.java • Let us check the CreateConnection API in detail. A BinderCallBack object [implemented in ServiceBinder ] is associated with mBinder. What is mBinder? ~ private Binder2 mBinder = new Binder2() / / code in ConnectionServiceWrapper ~Then, mBinder.bind(callback,call) is done so the callback is associated with the call. We will see the implementation of Binder2 class in a short while. In the onSuccess() of the Callback, mServiceInterface.createConnection is done which is actually the implementation in the stub. • Let us check out the important parts of ServiceBinder.java
  • 16. TELECOM Contd .. Second, the Binder2 Class. As per the code description, It Performs an asynchronous bind to the Service and executes the specific callback. Let us go step by step with it here – ~ mCallbacks.add(callback); - ~ setBinder(binder); -- > setServiceInterface(binder); //in the child class where we retrieve IConnnectionnService as interface. ~ ServiceConnection connection = new ServiceBinderConnection(call); ~ mContext.bindService(serviceIntent, connection, bindingFlags); ~ private final class ServiceBinderConnection implements ServiceConnection { … ~ handleFailedConnection(); -- > callback.onSuccess(); // Call back that was bound to. ServiceConnected(ComponentName..
  • 17. TELECOM Contd .. • The Actual implmementation of the IConnectionService – • Check the Constructor of connection Service Wrapper. Look for : super(ConnectionService.SERVICE_INTERFACE, componentName, context, userHandle); • Check frameworks/base/telecomm/java/android/telecom/ConnectionService.java • As I have already pointed out, this service is bound in the Binder2 class of ServiceBinder.java and through the following call mServiceInterface is obtained. (Check previous Slides) setBinder(binder); -- > setServiceInterface(binder); //in the child class where we retrieve IConnnectionnService as interface. • So, there it is , Telecom is all set to transfer the call to Telephony now which implements the ConnectionService.
  • 18. Telephony FW • Here, the android.telecom.ConnectionService is registered. This is extended by TelephonyConnectionService.java From here, Connection onCreateIncomingConnection will call placeOutgoingConnection() and will transfer the Call to the Target Phone.
  • 19. Telephony FW *Here is to note that the target phone is made at the boot time based on the NW TYPE the phone latches to. It can be of type – GSM, CDMA or IMS. The instance of the PHONE is provided to TelephonyConnectionService with the PhoneFactory Class. The discussion about creation of Phone object will be left for another day. TelephonyConnectionService.java
  • 20. Telephony FW The Phone Call in PHONE. Let us assume, we have a GSM Phone as our Active Phone. Now, DIAL(..) will come here. GSMPhone.java From GSMPhone , the Call is transferred to the CallTracker, where we have the RIL Command interfaces implemented, which in turn transfers the Call to modem through the RIL command interface.
  • 21. Telephony FW • GsmCallTracker.java • public CommandsInterface mCM; is associated with each Phone which is the connection point to RIL.java. You can find and understand it in PhoneBase.java. The implementation of Commands Interface is in RIL.java
  • 22. Telephony FW(RIL-J) • Commands Interface Implementation and DIAL and request to RILD through socket. The details are for another day. RIL.java
  • 23. Thank You • So, that was a very brief overview of the flow of APIs for an Android Outgoing CALL. Going forward we will discuss about the RIL and the PHONE class hierarchy in a detailed fashion. • The above slides were based on Android (N) code. There is a major change in OOS architecture as far as the Radio interface is concerned. We shall discuss that too in the future. • Credits : Android Open Source Project.