Coverage for src / bluetooth_sig / gatt / characteristics / chromatic_distance_from_planckian.py: 100%

5 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-03-18 11:17 +0000

1"""Chromatic Distance from Planckian characteristic (0x2AE3).""" 

2 

3from __future__ import annotations 

4 

5from .base import BaseCharacteristic 

6from .templates import ScaledSint16Template 

7 

8 

9class ChromaticDistanceFromPlanckianCharacteristic(BaseCharacteristic[float]): 

10 """Chromatic Distance from Planckian characteristic (0x2AE3). 

11 

12 org.bluetooth.characteristic.chromatic_distance_from_planckian 

13 

14 Unitless distance from the Planckian locus. 

15 M=1, d=-5, b=0 -> resolution 0.00001 (-0.05 to 0.05). 

16 A value of 0x7FFF represents 'value is not valid'. 

17 A value of 0x7FFE represents 'value is not known'. 

18 

19 Raises: 

20 SpecialValueDetectedError: If raw value is a sentinel (e.g. 0x7FFF). 

21 """ 

22 

23 _template = ScaledSint16Template.from_letter_method(M=1, d=-5, b=0)