SlideShare a Scribd company logo
1 of 15
Download to read offline
Amritendu Mondal
Deepankar Patra
Mahesh Gupta
Re-engineering & Integrating
Bluetooth 3.0 Device Driver in MOOL
Linux Bluetooth Driver Architecture
10-08-20132
 Bluetooth stack is divided into two parts
 Controller Stack:
 Implemented in the silicon device containing Bluetooth radio &
a µ-processor
 Device Specific
 Host Stack:
 Implemented as a part of OS.
 BluetoothApplications interact with this
Controller Stack (Device Specific)
10-08-20133
 Contains following interfaces
 ACL (Asynchronous connectionless link)
 SCO (Synchronous Connection Oriented link)
 LMP (Link Management Protocol)
 HCI (Host Controller Interface)
 LELL (Low Energy Link Layer)
Host Stack (OS Specific)
10-08-20134
 L2CAP (Logical Link Controller andAdaptation Protocol)
 Passes packets to either HCI or on a host less system directly to
the link manager /ACL link.
 BNEP (Bluetooth Network Encapsulation Protocol)
 Bound to L2CAP
 Used for delivering network packets on top of L2CAP
 RFCOMM (Radio Frequency Communication)
 Bound to L2CAP
 Provides simple reliable data stream to users
Host Stack (OS Specific)
10-08-20135
 CMTP (CAPI MessageTransport Protocol)
 Used to transfer common ISDN application interface messages
 Data is transferred via L2CAP
 HIDP (Human Interface Device Profile)
 Provides support for Devices such as Keyboard, mouse etc.
 Designed to provide low latency link with low power
requirements.
 SDP (Service Discovery Protocol)
 Bound to L2CAP
Our Work
10-08-20136
 Re-engineering Bluetooth 3.0 device driver from C to object
oriented C++ code
 Integrating Re-engineered Bluetooth 3.0 in MOOL
Why Integrating Bluetooth 3.0 and
What’s new in it?
10-08-20137
 It gives 8 times more speedup than the previous version
 L2CAP is enhanced(EL2CAP), which adds an additional
ERTM(Enhanced Retransmission Mode) to the core
specification.
 A new featureAMP(Alternate Mac/Phy) is added to increase
the transmission speed
 All the stack protocols are affected due to these changes
Why Re-engineering?
10-08-20138
 Changes in signature of multiple functions, and in many cases
change in the implementation of the same also in Bluetooth
3.0 made it difficult to integrate it in MOOL
 Newly introduced features, likeAMP, require significant
effort to update the current code, as the code is not
modularized.
Why Re-engineering?
10-08-20139
 Some functions written only for the use of Bluetooth device,
can be extracted into a different class and reused in other
device drivers also(e.g. CRC extraction from packets).
Re-engineering Bluetooth 3.0
10-08-201310
 Controller Stack:
 Controller Stack is device specific.
 Each driver file is implemented by different vendors
independently.
 usb_driver instance is common which is initialized with function
pointers.
 Each such function pointer has specific action.
 But the implementation differs as the device does, so no
function level abstraction is possible at controller stack level
Re-engineering Bluetooth 3.0
10-08-201311
 Host Stack:
 This is OS specific and common for all devices
 Lots of scope was there for OO abstraction
 All the procedures related to one Protocol, kept in one file
initially, was broken up into multiple classes according their
functionalities
An Example of Code Modularization
10-08-201312
 Previously the entire L2CAP protocol was implemented in
two files l2cap_core.c and l2cap_sock.c.
 We divided the functions in l2cap_core.c into some classes,
which are:
 L2cap_core_channel
 L2cap_core_seq_list
 L2cap_core_sls
 L2cap_core_connection
 L2cap_core_signalling
 L2cap_core_hci
Code Conversion Steps
10-08-201313
 Take a specific protocol
 Extract feature wise independent functions
 Put them into unique classes
 Make static functions private, and non static ones public
 Write wrapper functions for the public methods and call the
class functions inside them
 Put all the class definitions in a .h file and their
implementations in a .cc file
Problems Faced
10-08-201314
 C++ keywords used as variable names in C drivers
 Structure declarations inside sizeof() is allowed in C, but not
in C++
 enum constructs were not supported and replaced with
macros
 (void *) casting needed to be casted to a specific type
 Support for some built-in C functions is not there in C++,
e.g. __builtin_choose_expr(evaluates one of two expressions
based on compile time evaluated condition)
Redesigning & integrating bluetooth 3

More Related Content

What's hot

Link Aggregation Control Protocol
Link Aggregation Control ProtocolLink Aggregation Control Protocol
Link Aggregation Control ProtocolKashif Latif
 
An introduction to MPLS networks and applications
An introduction to MPLS networks and applicationsAn introduction to MPLS networks and applications
An introduction to MPLS networks and applicationsShawn Zandi
 
Multi-Protocol Label Switching: Basics and Applications
Multi-Protocol Label Switching: Basics and ApplicationsMulti-Protocol Label Switching: Basics and Applications
Multi-Protocol Label Switching: Basics and ApplicationsVishal Sharma, Ph.D.
 
a brief overview on link aggregation ieee 802.3ad
a brief overview on link aggregation ieee 802.3ada brief overview on link aggregation ieee 802.3ad
a brief overview on link aggregation ieee 802.3adtanay_7even
 
Etherchannel in Cisco Switches & Routers, Link Aggregation & PAgP LACP
Etherchannel in Cisco Switches & Routers,  Link Aggregation & PAgP LACPEtherchannel in Cisco Switches & Routers,  Link Aggregation & PAgP LACP
Etherchannel in Cisco Switches & Routers, Link Aggregation & PAgP LACPNetProtocol Xpert
 
MPLS Deployment Chapter 1 - Basic
MPLS Deployment Chapter 1 - BasicMPLS Deployment Chapter 1 - Basic
MPLS Deployment Chapter 1 - BasicEricsson
 
MPLS (Multi-Protocol Label Switching)
MPLS  (Multi-Protocol Label Switching)MPLS  (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)NetProtocol Xpert
 
Mpls basics introduction
Mpls basics introductionMpls basics introduction
Mpls basics introductionPhilip Agu Bah
 
EtherChannel PAgP and LACP modes
EtherChannel PAgP and LACP modesEtherChannel PAgP and LACP modes
EtherChannel PAgP and LACP modesNetProtocol Xpert
 
Mpls Traffic Engineering ppt
Mpls Traffic Engineering pptMpls Traffic Engineering ppt
Mpls Traffic Engineering pptNitin Gehlot
 
Link Aggregation Group - LACP
Link Aggregation Group - LACPLink Aggregation Group - LACP
Link Aggregation Group - LACPPLVision
 
Solaris multipathing
Solaris multipathingSolaris multipathing
Solaris multipathingBui Van Cuong
 
IP forwarding architectures and Overlay Model
IP forwarding architectures and Overlay ModelIP forwarding architectures and Overlay Model
IP forwarding architectures and Overlay ModelPradnya Saval
 

What's hot (20)

Implementing cisco mpls
Implementing cisco mplsImplementing cisco mpls
Implementing cisco mpls
 
Link Aggregation Control Protocol
Link Aggregation Control ProtocolLink Aggregation Control Protocol
Link Aggregation Control Protocol
 
MPLS ppt
MPLS pptMPLS ppt
MPLS ppt
 
MPLS
MPLSMPLS
MPLS
 
An introduction to MPLS networks and applications
An introduction to MPLS networks and applicationsAn introduction to MPLS networks and applications
An introduction to MPLS networks and applications
 
Multi-Protocol Label Switching: Basics and Applications
Multi-Protocol Label Switching: Basics and ApplicationsMulti-Protocol Label Switching: Basics and Applications
Multi-Protocol Label Switching: Basics and Applications
 
MPLS
MPLSMPLS
MPLS
 
a brief overview on link aggregation ieee 802.3ad
a brief overview on link aggregation ieee 802.3ada brief overview on link aggregation ieee 802.3ad
a brief overview on link aggregation ieee 802.3ad
 
Mpls
MplsMpls
Mpls
 
Etherchannel in Cisco Switches & Routers, Link Aggregation & PAgP LACP
Etherchannel in Cisco Switches & Routers,  Link Aggregation & PAgP LACPEtherchannel in Cisco Switches & Routers,  Link Aggregation & PAgP LACP
Etherchannel in Cisco Switches & Routers, Link Aggregation & PAgP LACP
 
MPLS Deployment Chapter 1 - Basic
MPLS Deployment Chapter 1 - BasicMPLS Deployment Chapter 1 - Basic
MPLS Deployment Chapter 1 - Basic
 
MPLS Tutorial
MPLS TutorialMPLS Tutorial
MPLS Tutorial
 
MPLS (Multi-Protocol Label Switching)
MPLS  (Multi-Protocol Label Switching)MPLS  (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)
 
Mpls basics introduction
Mpls basics introductionMpls basics introduction
Mpls basics introduction
 
EtherChannel PAgP and LACP modes
EtherChannel PAgP and LACP modesEtherChannel PAgP and LACP modes
EtherChannel PAgP and LACP modes
 
Mpls Traffic Engineering ppt
Mpls Traffic Engineering pptMpls Traffic Engineering ppt
Mpls Traffic Engineering ppt
 
Link Aggregation Group - LACP
Link Aggregation Group - LACPLink Aggregation Group - LACP
Link Aggregation Group - LACP
 
Solaris multipathing
Solaris multipathingSolaris multipathing
Solaris multipathing
 
IP forwarding architectures and Overlay Model
IP forwarding architectures and Overlay ModelIP forwarding architectures and Overlay Model
IP forwarding architectures and Overlay Model
 
Mpls
MplsMpls
Mpls
 

Viewers also liked

ad:tech New York: Marketing to Millennials
ad:tech New York: Marketing to Millennialsad:tech New York: Marketing to Millennials
ad:tech New York: Marketing to MillennialsContext Optional
 
Refueling
RefuelingRefueling
Refuelingpkryan
 
ad:tech App Exchange: McDonald's Monopoly Case Study
ad:tech App Exchange: McDonald's Monopoly Case Studyad:tech App Exchange: McDonald's Monopoly Case Study
ad:tech App Exchange: McDonald's Monopoly Case StudyContext Optional
 
ad:tech Expo Theater: Why Social is Worth More
ad:tech Expo Theater: Why Social is Worth Moread:tech Expo Theater: Why Social is Worth More
ad:tech Expo Theater: Why Social is Worth MoreContext Optional
 
Web Application Cache (APC, Memcache)
Web Application Cache (APC, Memcache)Web Application Cache (APC, Memcache)
Web Application Cache (APC, Memcache)Vijay Kumbhar
 
Intellectual property
Intellectual propertyIntellectual property
Intellectual propertyRexNige
 
基于linux-HA 的PG高可用性
基于linux-HA 的PG高可用性基于linux-HA 的PG高可用性
基于linux-HA 的PG高可用性babyyellow li
 
Altamaha School Media Center
Altamaha School Media CenterAltamaha School Media Center
Altamaha School Media Centerjessmiles04
 
Open Source Presentation
Open Source PresentationOpen Source Presentation
Open Source PresentationRexNige
 
Mass 201 CMR 17 Data Privacy Law
Mass 201 CMR 17 Data Privacy LawMass 201 CMR 17 Data Privacy Law
Mass 201 CMR 17 Data Privacy Lawguest8b10a3
 
Presentatie inkooptraining.com voor de bouw 1.0
Presentatie inkooptraining.com voor de bouw 1.0Presentatie inkooptraining.com voor de bouw 1.0
Presentatie inkooptraining.com voor de bouw 1.0Hans de Waay
 
Heritage Observatory Open Data GIS Platform
Heritage Observatory Open Data GIS PlatformHeritage Observatory Open Data GIS Platform
Heritage Observatory Open Data GIS PlatformDaniel Caune
 

Viewers also liked (20)

ad:tech New York: Marketing to Millennials
ad:tech New York: Marketing to Millennialsad:tech New York: Marketing to Millennials
ad:tech New York: Marketing to Millennials
 
Refueling
RefuelingRefueling
Refueling
 
ad:tech App Exchange: McDonald's Monopoly Case Study
ad:tech App Exchange: McDonald's Monopoly Case Studyad:tech App Exchange: McDonald's Monopoly Case Study
ad:tech App Exchange: McDonald's Monopoly Case Study
 
Christmas p3
Christmas p3Christmas p3
Christmas p3
 
Spring
SpringSpring
Spring
 
ad:tech Expo Theater: Why Social is Worth More
ad:tech Expo Theater: Why Social is Worth Moread:tech Expo Theater: Why Social is Worth More
ad:tech Expo Theater: Why Social is Worth More
 
Web Application Cache (APC, Memcache)
Web Application Cache (APC, Memcache)Web Application Cache (APC, Memcache)
Web Application Cache (APC, Memcache)
 
Meals
MealsMeals
Meals
 
Intellectual property
Intellectual propertyIntellectual property
Intellectual property
 
基于linux-HA 的PG高可用性
基于linux-HA 的PG高可用性基于linux-HA 的PG高可用性
基于linux-HA 的PG高可用性
 
Sp%20 pendidikan%20islam%20kbsm
Sp%20 pendidikan%20islam%20kbsmSp%20 pendidikan%20islam%20kbsm
Sp%20 pendidikan%20islam%20kbsm
 
Altamaha School Media Center
Altamaha School Media CenterAltamaha School Media Center
Altamaha School Media Center
 
Open Source Presentation
Open Source PresentationOpen Source Presentation
Open Source Presentation
 
Family Tree
Family TreeFamily Tree
Family Tree
 
Mass 201 CMR 17 Data Privacy Law
Mass 201 CMR 17 Data Privacy LawMass 201 CMR 17 Data Privacy Law
Mass 201 CMR 17 Data Privacy Law
 
Presentatie inkooptraining.com voor de bouw 1.0
Presentatie inkooptraining.com voor de bouw 1.0Presentatie inkooptraining.com voor de bouw 1.0
Presentatie inkooptraining.com voor de bouw 1.0
 
Heritage Observatory Open Data GIS Platform
Heritage Observatory Open Data GIS PlatformHeritage Observatory Open Data GIS Platform
Heritage Observatory Open Data GIS Platform
 
Islandscapes By Night
Islandscapes By NightIslandscapes By Night
Islandscapes By Night
 
Peggy and mummy
Peggy and mummyPeggy and mummy
Peggy and mummy
 
Psychology 4 11
Psychology 4 11Psychology 4 11
Psychology 4 11
 

Similar to Redesigning & integrating bluetooth 3

Unit 2 software partitioning
Unit 2 software partitioningUnit 2 software partitioning
Unit 2 software partitioningPRADEEP
 
Transforming a traditional home gateway into a hardwareaccelerated SDN switch
Transforming a traditional home gateway into a hardwareaccelerated SDN switchTransforming a traditional home gateway into a hardwareaccelerated SDN switch
Transforming a traditional home gateway into a hardwareaccelerated SDN switchIJECEIAES
 
DCN 5th ed. slides ch02-Network Models.pptx
DCN 5th ed. slides ch02-Network Models.pptxDCN 5th ed. slides ch02-Network Models.pptx
DCN 5th ed. slides ch02-Network Models.pptxBilal Munir Mughal
 
Protols used in bluetooth
Protols used in bluetoothProtols used in bluetooth
Protols used in bluetoothSonali Parab
 
Question 7 of 30 . Which type of hardware can.pdf
Question 7 of 30 . Which type of hardware can.pdfQuestion 7 of 30 . Which type of hardware can.pdf
Question 7 of 30 . Which type of hardware can.pdfaman05bhatia1
 
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoT
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoTMphasis Digital POV - Emerging Open Standard Protocol stack for IoT
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoTAniruddha Chakrabarti
 
5 pipeline arch_rationale
5 pipeline arch_rationale5 pipeline arch_rationale
5 pipeline arch_rationalevideos
 
uPortal Roadmap
uPortal RoadmapuPortal Roadmap
uPortal Roadmapkweiner
 
SuperConnectivity: One company’s heroic mission to deliver on the promises of...
SuperConnectivity: One company’s heroic mission to deliver on the promises of...SuperConnectivity: One company’s heroic mission to deliver on the promises of...
SuperConnectivity: One company’s heroic mission to deliver on the promises of...4DK Technologies, Inc.
 
MPLS (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)MPLS (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)Vipin Sahu
 
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...EMC
 
Multi-layer Control Plane
Multi-layer Control Plane Multi-layer Control Plane
Multi-layer Control Plane Metaswitch NTD
 
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...OpenStack
 
Oo Design And Patterns
Oo Design And PatternsOo Design And Patterns
Oo Design And PatternsAnil Bapat
 
OPC OLE for Process Control (OPC)
OPC OLE for Process Control (OPC)OPC OLE for Process Control (OPC)
OPC OLE for Process Control (OPC)Mostafa Ragab
 
Video Streaming over Bluetooth: A Survey
Video Streaming over Bluetooth: A SurveyVideo Streaming over Bluetooth: A Survey
Video Streaming over Bluetooth: A SurveyVideoguy
 
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)Open Mobile Alliance
 

Similar to Redesigning & integrating bluetooth 3 (20)

Unit 2 software partitioning
Unit 2 software partitioningUnit 2 software partitioning
Unit 2 software partitioning
 
Transforming a traditional home gateway into a hardwareaccelerated SDN switch
Transforming a traditional home gateway into a hardwareaccelerated SDN switchTransforming a traditional home gateway into a hardwareaccelerated SDN switch
Transforming a traditional home gateway into a hardwareaccelerated SDN switch
 
DCN 5th ed. slides ch02-Network Models.pptx
DCN 5th ed. slides ch02-Network Models.pptxDCN 5th ed. slides ch02-Network Models.pptx
DCN 5th ed. slides ch02-Network Models.pptx
 
Protols used in bluetooth
Protols used in bluetoothProtols used in bluetooth
Protols used in bluetooth
 
Question 7 of 30 . Which type of hardware can.pdf
Question 7 of 30 . Which type of hardware can.pdfQuestion 7 of 30 . Which type of hardware can.pdf
Question 7 of 30 . Which type of hardware can.pdf
 
Abhilash_CV
Abhilash_CVAbhilash_CV
Abhilash_CV
 
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoT
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoTMphasis Digital POV - Emerging Open Standard Protocol stack for IoT
Mphasis Digital POV - Emerging Open Standard Protocol stack for IoT
 
5 pipeline arch_rationale
5 pipeline arch_rationale5 pipeline arch_rationale
5 pipeline arch_rationale
 
uPortal Roadmap
uPortal RoadmapuPortal Roadmap
uPortal Roadmap
 
SuperConnectivity: One company’s heroic mission to deliver on the promises of...
SuperConnectivity: One company’s heroic mission to deliver on the promises of...SuperConnectivity: One company’s heroic mission to deliver on the promises of...
SuperConnectivity: One company’s heroic mission to deliver on the promises of...
 
MPLS (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)MPLS (Multi-Protocol Label Switching)
MPLS (Multi-Protocol Label Switching)
 
REEJA_CV1
REEJA_CV1REEJA_CV1
REEJA_CV1
 
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...
Converged Data Center: FCoE, iSCSI, & the Future of Storage Networking ( EMC ...
 
Multi-layer Control Plane
Multi-layer Control Plane Multi-layer Control Plane
Multi-layer Control Plane
 
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...
The Why and How of HPC-Cloud Hybrids with OpenStack - Lev Lafayette, Universi...
 
Oo Design And Patterns
Oo Design And PatternsOo Design And Patterns
Oo Design And Patterns
 
Resume
ResumeResume
Resume
 
OPC OLE for Process Control (OPC)
OPC OLE for Process Control (OPC)OPC OLE for Process Control (OPC)
OPC OLE for Process Control (OPC)
 
Video Streaming over Bluetooth: A Survey
Video Streaming over Bluetooth: A SurveyVideo Streaming over Bluetooth: A Survey
Video Streaming over Bluetooth: A Survey
 
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)
IETF building block in the LwM2M Ecosystem (IoT World 2017 Workshop)
 

Recently uploaded

Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
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 textsMaria Levchenko
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 

Recently uploaded (20)

Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
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
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 

Redesigning & integrating bluetooth 3

  • 1. Amritendu Mondal Deepankar Patra Mahesh Gupta Re-engineering & Integrating Bluetooth 3.0 Device Driver in MOOL
  • 2. Linux Bluetooth Driver Architecture 10-08-20132  Bluetooth stack is divided into two parts  Controller Stack:  Implemented in the silicon device containing Bluetooth radio & a µ-processor  Device Specific  Host Stack:  Implemented as a part of OS.  BluetoothApplications interact with this
  • 3. Controller Stack (Device Specific) 10-08-20133  Contains following interfaces  ACL (Asynchronous connectionless link)  SCO (Synchronous Connection Oriented link)  LMP (Link Management Protocol)  HCI (Host Controller Interface)  LELL (Low Energy Link Layer)
  • 4. Host Stack (OS Specific) 10-08-20134  L2CAP (Logical Link Controller andAdaptation Protocol)  Passes packets to either HCI or on a host less system directly to the link manager /ACL link.  BNEP (Bluetooth Network Encapsulation Protocol)  Bound to L2CAP  Used for delivering network packets on top of L2CAP  RFCOMM (Radio Frequency Communication)  Bound to L2CAP  Provides simple reliable data stream to users
  • 5. Host Stack (OS Specific) 10-08-20135  CMTP (CAPI MessageTransport Protocol)  Used to transfer common ISDN application interface messages  Data is transferred via L2CAP  HIDP (Human Interface Device Profile)  Provides support for Devices such as Keyboard, mouse etc.  Designed to provide low latency link with low power requirements.  SDP (Service Discovery Protocol)  Bound to L2CAP
  • 6. Our Work 10-08-20136  Re-engineering Bluetooth 3.0 device driver from C to object oriented C++ code  Integrating Re-engineered Bluetooth 3.0 in MOOL
  • 7. Why Integrating Bluetooth 3.0 and What’s new in it? 10-08-20137  It gives 8 times more speedup than the previous version  L2CAP is enhanced(EL2CAP), which adds an additional ERTM(Enhanced Retransmission Mode) to the core specification.  A new featureAMP(Alternate Mac/Phy) is added to increase the transmission speed  All the stack protocols are affected due to these changes
  • 8. Why Re-engineering? 10-08-20138  Changes in signature of multiple functions, and in many cases change in the implementation of the same also in Bluetooth 3.0 made it difficult to integrate it in MOOL  Newly introduced features, likeAMP, require significant effort to update the current code, as the code is not modularized.
  • 9. Why Re-engineering? 10-08-20139  Some functions written only for the use of Bluetooth device, can be extracted into a different class and reused in other device drivers also(e.g. CRC extraction from packets).
  • 10. Re-engineering Bluetooth 3.0 10-08-201310  Controller Stack:  Controller Stack is device specific.  Each driver file is implemented by different vendors independently.  usb_driver instance is common which is initialized with function pointers.  Each such function pointer has specific action.  But the implementation differs as the device does, so no function level abstraction is possible at controller stack level
  • 11. Re-engineering Bluetooth 3.0 10-08-201311  Host Stack:  This is OS specific and common for all devices  Lots of scope was there for OO abstraction  All the procedures related to one Protocol, kept in one file initially, was broken up into multiple classes according their functionalities
  • 12. An Example of Code Modularization 10-08-201312  Previously the entire L2CAP protocol was implemented in two files l2cap_core.c and l2cap_sock.c.  We divided the functions in l2cap_core.c into some classes, which are:  L2cap_core_channel  L2cap_core_seq_list  L2cap_core_sls  L2cap_core_connection  L2cap_core_signalling  L2cap_core_hci
  • 13. Code Conversion Steps 10-08-201313  Take a specific protocol  Extract feature wise independent functions  Put them into unique classes  Make static functions private, and non static ones public  Write wrapper functions for the public methods and call the class functions inside them  Put all the class definitions in a .h file and their implementations in a .cc file
  • 14. Problems Faced 10-08-201314  C++ keywords used as variable names in C drivers  Structure declarations inside sizeof() is allowed in C, but not in C++  enum constructs were not supported and replaced with macros  (void *) casting needed to be casted to a specific type  Support for some built-in C functions is not there in C++, e.g. __builtin_choose_expr(evaluates one of two expressions based on compile time evaluated condition)