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

6 statements  

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

1"""ContinuousGlucoseMonitoring 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 ContinuousGlucoseMonitoringService(BaseGattService): 

12 """Continuous Glucose Monitoring Service implementation (0x181F). 

13 

14 Used for continuous glucose monitoring devices. Provides real-time 

15 glucose concentration readings, session management, and device 

16 feature reporting. 

17 """ 

18 

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

20 CharacteristicName.CGM_MEASUREMENT: True, 

21 CharacteristicName.CGM_FEATURE: True, 

22 CharacteristicName.CGM_STATUS: True, 

23 CharacteristicName.CGM_SESSION_START_TIME: True, 

24 CharacteristicName.CGM_SESSION_RUN_TIME: True, 

25 CharacteristicName.CGM_SPECIFIC_OPS_CONTROL_POINT: True, 

26 CharacteristicName.RECORD_ACCESS_CONTROL_POINT: True, 

27 }