Coverage for src / bluetooth_sig / gatt / characteristics / time_exponential_8.py: 100%
6 statements
« prev ^ index » next coverage.py v7.13.5, created at 2026-03-18 11:17 +0000
« prev ^ index » next coverage.py v7.13.5, created at 2026-03-18 11:17 +0000
1"""Time Exponential 8 characteristic (0x2B13)."""
3from __future__ import annotations
5from datetime import timedelta
7from .base import BaseCharacteristic
8from .templates import TimeExponentialTemplate
11class TimeExponential8Characteristic(BaseCharacteristic[timedelta]):
12 """Time Exponential 8 characteristic (0x2B13).
14 org.bluetooth.characteristic.time_exponential_8
16 Time duration using exponential encoding: value = 1.1^(N - 64) seconds.
17 - Raw 0x00 represents 0 seconds.
18 - Raw 0xFE represents total life of the device.
19 - Raw 0xFF represents 'value is not known'.
21 Raises:
22 SpecialValueDetectedError: If raw value is a sentinel (e.g. 0xFE, 0xFF).
23 """
25 _template = TimeExponentialTemplate()