# Package com.codename1.bluetooth.le

package com.codename1.bluetooth.le

BLE central role: scanning (`BluetoothLE`, `ScanSettings`, `ScanFilter`, `ScanResult`, `BleScan`), connections and the GATT client (`BlePeripheral`, connection events) and L2CAP connection-oriented channels (`L2capChannel`, `L2capServer`).

Obtain the entry point via `Bluetooth.getInstance().getLE()`. Any number of scans and per-peripheral GATT operations may run concurrently -- an internal queue serializes operations toward the platform stack and every call returns its own `AsyncResource`.

- Related Packages
  Package
  Description
  com.codename1.bluetooth
  Cross-platform Bluetooth API: adapter state, runtime permissions and capability queries.
  com.codename1.bluetooth.le.server
  BLE peripheral role: the local GATT server (`GattServer`, `GattLocalService`, `GattLocalCharacteristic`, request envelopes) and advertising (`AdvertiseSettings`, `AdvertiseData`, `BleAdvertisement`).
  com.codename1.bluetooth.classic
  Classic Bluetooth (BR/EDR): inquiry discovery (`ClassicDiscovery`), bonded-device listing and RFCOMM stream connections (`RfcommConnection`, `RfcommServer`).
  com.codename1.bluetooth.gatt
  The client-side GATT model discovered on a remote peripheral: `GattService`, `GattCharacteristic` (read/write/subscribe), `GattDescriptor`, notification listeners and ATT status codes.
- Class
  Description
  AdvertisementData
  The parsed payload of a BLE advertisement: local name, advertised service UUIDs, manufacturer data, service data and TX power.
  BlePeripheral
  A remote BLE peripheral: connection lifecycle, GATT client operations and L2CAP channels.
  BleScan
  Live handle of a running BLE scan returned by `BluetoothLE.startScan(ScanSettings, ScanListener)`.
  BluetoothLE
  The BLE central role: scanning for peripherals and re-obtaining known ones.
  ConnectionEvent
  Payload of a `ConnectionListener` callback describing a `BlePeripheral` state transition.
  ConnectionListener
  Observes `BlePeripheral` connection state transitions registered via `BlePeripheral.addConnectionListener(ConnectionListener)`.
  ConnectionOptions
  Options for `BlePeripheral.connect(ConnectionOptions)`.
  ConnectionPriority
  Connection-interval preference requested via `BlePeripheral.requestConnectionPriority(ConnectionPriority)`.
  ConnectionState
  Lifecycle states of a `BlePeripheral` connection.
  L2capChannel
  An open L2CAP connection-oriented channel -- a raw bidirectional byte stream to a peripheral, obtained via `BlePeripheral.openL2capChannel(int, boolean)` on the central side or accepted from an `L2capServer` on the peripheral side.
  L2capServer
  A listening L2CAP endpoint on the local device, opened via `BluetoothLE.openL2capServer(boolean)` when acting as a peripheral.
  ScanFilter
  A single scan filter -- all criteria set on one filter are AND-combined; multiple filters added to a `ScanSettings` are OR-combined.
  ScanListener
  Receives advertisement sightings during a scan started via `BluetoothLE.startScan(ScanSettings, ScanListener)`.
  ScanMode
  Power/latency trade-off of a BLE scan, mirroring Android's scan modes.
  ScanResult
  One advertisement sighting delivered to a `ScanListener` during a scan.
  ScanSettings
  Options for a BLE scan started via `BluetoothLE.startScan(ScanSettings, ScanListener)`.