When to activate
- Implementing BLE GATT services and characteristics
- Designing BLE advertising and scanning strategies
- Implementing BLE pairing and bonding
- Building BLE Mesh networks for IoT
- Debugging BLE connection issues and throughput
When NOT to use
- For WiFi-only IoT devices
- For classical Bluetooth audio (A2DP)
- For NFC or RFID systems
Instructions
- Define GATT profile. Services (group related data), Characteristics (individual values), Descriptors (metadata). Use standard SIG profiles where possible.
- Advertising. Include service UUIDs. Use scan response for extra data. Interval trade-off: fast = discoverable, slow = power efficient.
- Connection parameters. Interval (7.5ms-4s), latency (skip intervals), timeout. Negotiate for use case: low latency vs power.
- Pairing. Just Works (no MITM protection), Passkey (MITM protection), OOB (out-of-band key). Choose based on security needs.
- Throughput. DLE (Data Length Extension) for larger packets. MTU negotiation. Notifications > Indications (no ack needed).
- BLE Mesh. Provisioning, relay nodes, publish/subscribe model. For many-to-many communication (lighting, sensors).
- Debugging. BLE sniffer (nRF Sniffer). Connection event logging. RSSI monitoring for range issues.
Example
BLE GATT Profile: Environmental Sensor
Service: Environmental Sensing (0x181A)
Characteristic: Temperature (0x2A6E) — sint16, 0.01°C resolution, notify
Characteristic: Humidity (0x2A6F) — uint16, 0.01% resolution, notify
Characteristic: Pressure (0x2A6D) — uint32, 0.1 Pa resolution, read
Service: Device Information (0x180A)
Characteristic: Manufacturer (0x2A29) — string, read
Characteristic: Firmware Rev (0x2A26) — string, read
Advertising: 100ms interval, include Environmental Sensing UUID
Connection: 30ms interval, 0 latency, 4s timeout
1---2name: ble-connectivity3description: Implement BLE connectivity — GATT services, pairing, advertising, and BLE Mesh networking4---56## When to activate78- Implementing BLE GATT services and characteristics9- Designing BLE advertising and scanning strategies10- Implementing BLE pairing and bonding11- Building BLE Mesh networks for IoT12- Debugging BLE connection issues and throughput1314## When NOT to use1516- For WiFi-only IoT devices17- For classical Bluetooth audio (A2DP)18- For NFC or RFID systems1920## Instructions21221. **Define GATT profile.** Services (group related data), Characteristics (individual values), Descriptors (metadata). Use standard SIG profiles where possible.232. **Advertising.** Include service UUIDs. Use scan response for extra data. Interval trade-off: fast = discoverable, slow = power efficient.243. **Connection parameters.** Interval (7.5ms-4s), latency (skip intervals), timeout. Negotiate for use case: low latency vs power.254. **Pairing.** Just Works (no MITM protection), Passkey (MITM protection), OOB (out-of-band key). Choose based on security needs.265. **Throughput.** DLE (Data Length Extension) for larger packets. MTU negotiation. Notifications > Indications (no ack needed).276. **BLE Mesh.** Provisioning, relay nodes, publish/subscribe model. For many-to-many communication (lighting, sensors).287. **Debugging.** BLE sniffer (nRF Sniffer). Connection event logging. RSSI monitoring for range issues.2930## Example3132```33BLE GATT Profile: Environmental Sensor3435Service: Environmental Sensing (0x181A)36 Characteristic: Temperature (0x2A6E) — sint16, 0.01°C resolution, notify37 Characteristic: Humidity (0x2A6F) — uint16, 0.01% resolution, notify38 Characteristic: Pressure (0x2A6D) — uint32, 0.1 Pa resolution, read3940Service: Device Information (0x180A)41 Characteristic: Manufacturer (0x2A29) — string, read42 Characteristic: Firmware Rev (0x2A26) — string, read4344Advertising: 100ms interval, include Environmental Sensing UUID45Connection: 30ms interval, 0 latency, 4s timeout46```