B-LE - GATT Architectural Overview: Difference between revisions
AMaksimovic (talk | contribs) m (AMaksimovic moved page (Article title) to B-LE - GATT Architectural Overview) |
AMaksimovic (talk | contribs) |
||
| Line 1: | Line 1: | ||
= | = Description = | ||
Description what this documentation is about. | Description what this documentation is about. | ||
= Bluetooth LE = | |||
== GAP - Generic Attribute Profile == | |||
The Generic attribute profile takes care of discovery, security, connectivity and network technolgies of a device. | The Generic attribute profile takes care of discovery, security, connectivity and network technolgies of a device. | ||
| Line 23: | Line 19: | ||
ADV_SCAN_IND | ADV_SCAN_IND | ||
== GATT - Generic Attribute Profile == | |||
As soon as two Bluetooth Low Energy devices establish a connection they can start transfering data back and forth. This data is formated into Services and Characteristics in a Server/Client relationship. | As soon as two Bluetooth Low Energy devices establish a connection they can start transfering data back and forth. This data is formated into Services and Characteristics in a Server/Client relationship. | ||
== Network Topology == | |||
The network topology of GATT networks contains so-called central devices and peripheral devices. One peripheral is only connected to only one central device at a time. A central device can connect to many peripheral devices. The peripheral is also acting as the GATT server. It contains the definitions for profiles, services and characteristics of a device. The central device always initiates the data exchange. | The network topology of GATT networks contains so-called central devices and peripheral devices. One peripheral is only connected to only one central device at a time. A central device can connect to many peripheral devices. The peripheral is also acting as the GATT server. It contains the definitions for profiles, services and characteristics of a device. The central device always initiates the data exchange. | ||
== ATT - Attribute Protocol == | |||
GATT is based on ATT. Each attribute gets it’s own Unique Identifier (UUID) here. These get formatted as characteristics and services. | GATT is based on ATT. Each attribute gets it’s own Unique Identifier (UUID) here. These get formatted as characteristics and services. | ||
== Profiles == | |||
set of services per Profile | set of services per Profile | ||
Example profiles: Basic audio profile, Location and navigation profile, weight scale profile, heart rate profile | Example profiles: Basic audio profile, Location and navigation profile, weight scale profile, heart rate profile | ||
== Services == | |||
A Service can have multiple characteristics. It has it’s own UUID. It has a handle. UUID, permissions, value | A Service can have multiple characteristics. It has it’s own UUID. It has a handle. UUID, permissions, value | ||
== Characteristics == | |||
The characteristics are the lowest-level of the GATT Profiles. They also each use their own UUID. | The characteristics are the lowest-level of the GATT Profiles. They also each use their own UUID. | ||
| Line 50: | Line 46: | ||
The characteristics have a value, properties and human-readable descriptors | The characteristics have a value, properties and human-readable descriptors | ||
== Example UUIDs of a Polar Smartwatch == | |||
Example Device UUID: | Example Device UUID: | ||
| Line 82: | Line 78: | ||
Characteristic: 00002a19-0000-1000-8000-00805f9b34fb (Handle: 43) - Properties: ['read', 'notify'] | Characteristic: 00002a19-0000-1000-8000-00805f9b34fb (Handle: 43) - Properties: ['read', 'notify'] | ||
== BLE Operations == | |||
* Read | * Read | ||
| Line 93: | Line 89: | ||
Get notifications to value changes of a device by subscribing to it | Get notifications to value changes of a device by subscribing to it | ||
== Further Context == | |||
Make sure to read | Make sure to read | ||
Revision as of 15:38, 5 December 2024
Description
Description what this documentation is about.
Bluetooth LE
GAP - Generic Attribute Profile
The Generic attribute profile takes care of discovery, security, connectivity and network technolgies of a device.
ADV_IND SCAN_REQ SCAN_RSP CONNECT_IND AUX_SCAN_REQ AUX_SCAN_RSP AUX_CONNECT_REQ AUX_CONNECT_RSP ADV_SCAN_IND
GATT - Generic Attribute Profile
As soon as two Bluetooth Low Energy devices establish a connection they can start transfering data back and forth. This data is formated into Services and Characteristics in a Server/Client relationship.
Network Topology
The network topology of GATT networks contains so-called central devices and peripheral devices. One peripheral is only connected to only one central device at a time. A central device can connect to many peripheral devices. The peripheral is also acting as the GATT server. It contains the definitions for profiles, services and characteristics of a device. The central device always initiates the data exchange.
ATT - Attribute Protocol
GATT is based on ATT. Each attribute gets it’s own Unique Identifier (UUID) here. These get formatted as characteristics and services.
Profiles
set of services per Profile Example profiles: Basic audio profile, Location and navigation profile, weight scale profile, heart rate profile
Services
A Service can have multiple characteristics. It has it’s own UUID. It has a handle. UUID, permissions, value
Characteristics
The characteristics are the lowest-level of the GATT Profiles. They also each use their own UUID. These are relevant when it comes to protecting and enhancing security of a Bluetooth Low Energy device. The characteristics have a value, properties and human-readable descriptors
Example UUIDs of a Polar Smartwatch
Example Device UUID:
C6C36C4A-7F8F-52B2-2BD7-C4F6690424E7
Example Service UUIDs:
Service: 0000180a-0000-1000-8000-00805f9b34fb (Handle: 14): Device Information Service: 0000feee-0000-1000-8000-00805f9b34fb (Handle: 29): Polar Electro Oy Service: 0000180d-0000-1000-8000-00805f9b34fb (Handle: 38): Heart Rate Service: 0000180f-0000-1000-8000-00805f9b34fb (Handle: 42): Battery Service
Example Service and their Characteristics UUIDs including handles, permissions, properties, values, descriptors:
Service: 0000180a-0000-1000-8000-00805f9b34fb (Handle: 14): Device Information Characteristic: 00002a29-0000-1000-8000-00805f9b34fb (Handle: 15) - Properties: ['read'] Characteristic: 00002a24-0000-1000-8000-00805f9b34fb (Handle: 17) - Properties: ['read'] Characteristic: 00002a25-0000-1000-8000-00805f9b34fb (Handle: 19) - Properties: ['read'] Characteristic: 00002a27-0000-1000-8000-00805f9b34fb (Handle: 21) - Properties: ['read'] Characteristic: 00002a26-0000-1000-8000-00805f9b34fb (Handle: 23) - Properties: ['read'] Characteristic: 00002a28-0000-1000-8000-00805f9b34fb (Handle: 25) - Properties: ['read'] Characteristic: 00002a23-0000-1000-8000-00805f9b34fb (Handle: 27) - Properties: ['read'] Service: 0000feee-0000-1000-8000-00805f9b34fb (Handle: 29): Polar Electro Oy Characteristic: fb005c51-02e7-f387-1cad-8acd2d8df0c8 (Handle: 30) - Properties: ['write-without-response', 'write', 'notify'] Characteristic: fb005c52-02e7-f387-1cad-8acd2d8df0c8 (Handle: 33) - Properties: ['notify'] Characteristic: fb005c53-02e7-f387-1cad-8acd2d8df0c8 (Handle: 36) - Properties: ['write-without-response', 'write'] Service: 0000180d-0000-1000-8000-00805f9b34fb (Handle: 38): Heart Rate Characteristic: 00002a37-0000-1000-8000-00805f9b34fb (Handle: 39) - Properties: ['notify'] Service: 0000180f-0000-1000-8000-00805f9b34fb (Handle: 42): Battery Service Characteristic: 00002a19-0000-1000-8000-00805f9b34fb (Handle: 43) - Properties: ['read', 'notify']
BLE Operations
- Read
Read the data of a characteristic
- Write
Write data to a characteristic
- Notify
Get notifications to value changes of a device by subscribing to it
Further Context
Make sure to read
- Setting Up Ubertooth on macOS for Bluetooth Hacking [1]
Courses
Author
Are Maksimović