File tree Expand file tree Collapse file tree 1 file changed +19
-8
lines changed
adafruit_ble/services/standard Expand file tree Collapse file tree 1 file changed +19
-8
lines changed Original file line number Diff line number Diff line change 9
9
10
10
"""
11
11
12
+ from __future__ import annotations
13
+
12
14
import binascii
13
15
import os
14
16
import sys
17
19
from ...uuid import StandardUUID
18
20
from ...characteristics .string import FixedStringCharacteristic
19
21
22
+ try :
23
+ from typing import Optional , TYPE_CHECKING
24
+
25
+ if TYPE_CHECKING :
26
+ import _bleio
27
+
28
+ except ImportError :
29
+ pass
30
+
20
31
__version__ = "0.0.0-auto.0"
21
32
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_BLE.git"
22
33
@@ -35,14 +46,14 @@ class DeviceInfoService(Service):
35
46
def __init__ (
36
47
self ,
37
48
* ,
38
- manufacturer = None ,
39
- software_revision = None ,
40
- model_number = None ,
41
- serial_number = None ,
42
- firmware_revision = None ,
43
- hardware_revision = None ,
44
- service = None
45
- ):
49
+ manufacturer : Optional [ str ] = None ,
50
+ software_revision : Optional [ str ] = None ,
51
+ model_number : Optional [ str ] = None ,
52
+ serial_number : Optional [ str ] = None ,
53
+ firmware_revision : Optional [ str ] = None ,
54
+ hardware_revision : Optional [ str ] = None ,
55
+ service : Optional [ _bleio . Service ] = None ,
56
+ ) -> None :
46
57
if not service :
47
58
if model_number is None :
48
59
model_number = sys .platform
You can’t perform that action at this time.
0 commit comments