Skip to content

Commit fe5bcd9

Browse files
committed
Move INPUTS and OUTPUTS from core to helper
1 parent da7aefd commit fe5bcd9

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

ev3dev/brickpi.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,11 @@
3333
OUTPUT_B = 'ttyAMA0:outB'
3434
OUTPUT_C = 'ttyAMA0:outC'
3535
OUTPUT_D = 'ttyAMA0:outD'
36-
OUTPUTS = (OUTPUT_A, OUTPUT_B, OUTPUT_C, OUTPUT_D)
3736

3837
INPUT_1 = 'ttyAMA0:in1'
3938
INPUT_2 = 'ttyAMA0:in2'
4039
INPUT_3 = 'ttyAMA0:in3'
4140
INPUT_4 = 'ttyAMA0:in4'
42-
INPUTS = (INPUT_1, INPUT_2, INPUT_3, INPUT_4)
4341

4442

4543
class Leds(object):

ev3dev/ev3.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,11 @@
3333
OUTPUT_B = 'outB'
3434
OUTPUT_C = 'outC'
3535
OUTPUT_D = 'outD'
36-
OUTPUTS = (OUTPUT_A, OUTPUT_B, OUTPUT_C, OUTPUT_D)
3736

3837
INPUT_1 = 'in1'
3938
INPUT_2 = 'in2'
4039
INPUT_3 = 'in3'
4140
INPUT_4 = 'in4'
42-
INPUTS = (INPUT_1, INPUT_2, INPUT_3, INPUT_4)
4341

4442

4543
class Leds(object):

ev3dev/helper.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,16 @@
44
import sys
55
import time
66
import ev3dev.auto
7-
from ev3dev.auto import OUTPUTS, RemoteControl, list_motors
7+
from ev3dev.auto import (RemoteControl, list_motors,
8+
INPUT_1, INPUT_2, INPUT_3,INPUT_4,
9+
OUTPUT_A, OUTPUT_B, OUTPUT_C, OUTPUT_D)
810
from math import pi
911
from time import sleep
1012

1113
log = logging.getLogger(__name__)
1214

15+
INPUTS = (INPUT_1, INPUT_2, INPUT_3, INPUT_4)
16+
OUTPUTS = (OUTPUT_A, OUTPUT_B, OUTPUT_C, OUTPUT_D)
1317

1418
def wait_for(condition, timeout=1e5, interval=0.01):
1519
tic = time.time() + timeout

0 commit comments

Comments
 (0)