src.bluetooth_sig.gatt.characteristics.battery_level_status¶
Battery Level Status characteristic implementation.
Classes¶
Name | Description |
|---|---|
Battery Level Status data structure. |
|
Battery Level Status characteristic (0x2BED). |
|
Battery Level Status flags. |
Module Contents¶
- class src.bluetooth_sig.gatt.characteristics.battery_level_status.BatteryLevelStatus¶
Bases:
msgspec.StructBattery Level Status data structure.
- battery_charge_level: bluetooth_sig.types.battery.BatteryChargeLevel¶
- battery_charge_state: bluetooth_sig.types.battery.BatteryChargeState¶
- charging_type: bluetooth_sig.types.battery.BatteryChargingType¶
- flags: BatteryLevelStatusFlags¶
- service_required: bluetooth_sig.types.battery.ServiceRequiredState | None = None¶
- wired_external_power_connected: bluetooth_sig.types.battery.PowerConnectionState¶
- wireless_external_power_connected: bluetooth_sig.types.battery.PowerConnectionState¶
- class src.bluetooth_sig.gatt.characteristics.battery_level_status.BatteryLevelStatusCharacteristic¶
Bases:
src.bluetooth_sig.gatt.characteristics.base.BaseCharacteristic[BatteryLevelStatus]Battery Level Status characteristic (0x2BED).
org.bluetooth.characteristic.battery_level_status
- BIT_START_BATTERY_FAULT = 2¶
- BIT_START_BATTERY_PRESENT = 0¶
- BIT_START_CHARGE_LEVEL = 7¶
- BIT_START_CHARGE_STATE = 5¶
- BIT_START_CHARGING_TYPE = 9¶
- BIT_START_FAULT_BATTERY = 12¶
- BIT_START_FAULT_EXTERNAL = 13¶
- BIT_START_FAULT_OTHER = 14¶
- BIT_START_SERVICE_REQUIRED = 0¶
- BIT_START_WIRED_POWER = 1¶
- BIT_START_WIRELESS_POWER = 3¶
- BIT_WIDTH_BATTERY_FAULT = 1¶
- BIT_WIDTH_BATTERY_PRESENT = 1¶
- BIT_WIDTH_CHARGE_LEVEL = 2¶
- BIT_WIDTH_CHARGE_STATE = 2¶
- BIT_WIDTH_CHARGING_TYPE = 3¶
- BIT_WIDTH_FAULT_BATTERY = 1¶
- BIT_WIDTH_FAULT_EXTERNAL = 1¶
- BIT_WIDTH_FAULT_OTHER = 1¶
- BIT_WIDTH_SERVICE_REQUIRED = 2¶
- BIT_WIDTH_WIRED_POWER = 2¶
- BIT_WIDTH_WIRELESS_POWER = 2¶
- allow_variable_length = True¶
- max_length = 7¶
- min_length = 3¶
- class src.bluetooth_sig.gatt.characteristics.battery_level_status.BatteryLevelStatusFlags¶
Bases:
enum.IntFlagBattery Level Status flags.
- ADDITIONAL_STATUS_PRESENT = 4¶
- BATTERY_LEVEL_PRESENT = 2¶
- IDENTIFIER_PRESENT = 1¶