Coverage for src / bluetooth_sig / gatt / services / industrial_measurement_device.py: 100%

6 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-04-03 16:41 +0000

1"""IndustrialMeasurementDevice Service implementation.""" 

2 

3from __future__ import annotations 

4 

5from typing import ClassVar 

6 

7from ..characteristics.registry import CharacteristicName 

8from .base import BaseGattService 

9 

10 

11class IndustrialMeasurementDeviceService(BaseGattService): 

12 """Industrial Measurement Device Service implementation (0x185A). 

13 

14 Used for industrial measurement instruments. Provides device 

15 status, historical measurement data, and control capabilities. 

16 """ 

17 

18 service_characteristics: ClassVar[dict[CharacteristicName, bool]] = { 

19 CharacteristicName.IMD_STATUS: False, 

20 CharacteristicName.IMDS_DESCRIPTOR_VALUE_CHANGED: False, 

21 CharacteristicName.FIRST_USE_DATE: False, 

22 CharacteristicName.LIFE_CYCLE_DATA: False, 

23 CharacteristicName.WORK_CYCLE_DATA: False, 

24 CharacteristicName.SERVICE_CYCLE_DATA: False, 

25 CharacteristicName.IMD_CONTROL: False, 

26 CharacteristicName.IMD_HISTORICAL_DATA: False, 

27 CharacteristicName.RECORD_ACCESS_CONTROL_POINT: False, 

28 # IMD Measurement permitted characteristics (at least one required if service is present) 

29 CharacteristicName.ACCELERATION: False, 

30 CharacteristicName.FORCE: False, 

31 CharacteristicName.LINEAR_POSITION: False, 

32 CharacteristicName.ROTATIONAL_SPEED: False, 

33 CharacteristicName.LENGTH: False, 

34 CharacteristicName.TORQUE: False, 

35 CharacteristicName.TEMPERATURE: False, 

36 }