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

17 statements  

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

1"""Playing Orders Supported characteristic (0x2BA2).""" 

2 

3from __future__ import annotations 

4 

5from enum import IntFlag 

6 

7from .base import BaseCharacteristic 

8from .templates import FlagTemplate 

9 

10 

11class PlayingOrdersSupported(IntFlag): 

12 """Supported playing orders flags.""" 

13 

14 SINGLE_ONCE = 0x0001 

15 SINGLE_REPEAT = 0x0002 

16 IN_ORDER_ONCE = 0x0004 

17 IN_ORDER_REPEAT = 0x0008 

18 OLDEST_ONCE = 0x0010 

19 OLDEST_REPEAT = 0x0020 

20 NEWEST_ONCE = 0x0040 

21 NEWEST_REPEAT = 0x0080 

22 SHUFFLE_ONCE = 0x0100 

23 SHUFFLE_REPEAT = 0x0200 

24 

25 

26class PlayingOrdersSupportedCharacteristic(BaseCharacteristic[PlayingOrdersSupported]): 

27 """Playing Orders Supported characteristic (0x2BA2). 

28 

29 org.bluetooth.characteristic.playing_orders_supported 

30 

31 Bitfield indicating which playing orders are supported. 

32 """ 

33 

34 _template = FlagTemplate.uint16(PlayingOrdersSupported)