Ch-6 clean

This commit is contained in:
Danny Staple
2022-03-20 22:27:49 +00:00
parent 481cac28de
commit 36240090bf
19 changed files with 71 additions and 92 deletions
+2 -6
View File
@@ -14,13 +14,9 @@ pio_input = """
assembled = adafruit_pioasm.assemble(pio_input)
sm = rp2pio.StateMachine(
assembled,
frequency=2000,
first_in_pin=board.GP20
)
sm = rp2pio.StateMachine(assembled, frequency=2000, first_in_pin=board.GP20)
buffer = array.array('I', [0])
buffer = array.array("I", [0])
while True:
# read data from the fifo
+2 -5
View File
@@ -15,13 +15,10 @@ assembled = adafruit_pioasm.assemble(pio_input)
## set up a statemachine
sm = rp2pio.StateMachine(
assembled,
frequency=2000,
first_in_pin=board.GP20,
in_pin_count=2
assembled, frequency=2000, first_in_pin=board.GP20, in_pin_count=2
)
buffer = bytearray(1) # an array of bytes to read into - we are just asking for a byte
buffer = bytearray(1) # an array of bytes to read into - we are just asking for a byte
while True:
# read data from the fifo