6:81a2208f13e4 | 7:e336d6afc5a6 |
---|---|
10 class DriveMode(): | 10 class DriveMode(): |
11 PUSH_PULL = 0 | 11 PUSH_PULL = 0 |
12 OPEN_DRAIN = 0 | 12 OPEN_DRAIN = 0 |
13 | 13 |
14 class DigitalInOut(): | 14 class DigitalInOut(): |
15 direction = 0 | |
16 value = 0 | |
17 drive_mode = 0 | |
18 pull = 0 | |
19 | |
15 def __init__(self, pin): | 20 def __init__(self, pin): |
16 pass | 21 pass |
17 | 22 |
18 def deinit(self): | 23 def deinit(self): |
19 pass | 24 pass |
21 def switch_to_output(self, value=False, drive_mode=DriveMode.PUSH_PULL): | 26 def switch_to_output(self, value=False, drive_mode=DriveMode.PUSH_PULL): |
22 pass | 27 pass |
23 | 28 |
24 def switch_to_input(self, pull=None): | 29 def switch_to_input(self, pull=None): |
25 pass | 30 pass |
26 | |
27 @property | |
28 def direction(self): | |
29 pass | |
30 | |
31 @property | |
32 def value(self): | |
33 pass | |
34 | |
35 @property | |
36 def drive_mode(self): | |
37 pass | |
38 | |
39 @property | |
40 def pull(self): | |
41 pass | |
42 | 31 |
43 class Pull(): | 32 class Pull(): |
44 UP = 0 | 33 UP = 0 |
45 DOWN = 0 | 34 DOWN = 0 |