forked from zietzm/Helmholtz_Test_Bench
22 lines
364 B
Python
22 lines
364 B
Python
import time
|
|
|
|
from Arduino import Arduino
|
|
|
|
print("Searching for Arduino...")
|
|
board = Arduino()
|
|
print("Arduino found.")
|
|
board.pinMode(9, "Output")
|
|
|
|
i = 0
|
|
while i <= 4:
|
|
print("running: ", i)
|
|
board.digitalWrite(9, "HIGH")
|
|
time.sleep(0.5)
|
|
time.sleep(1)
|
|
board.digitalWrite(9, "LOW")
|
|
time.sleep(0.5)
|
|
time.sleep(1)
|
|
i = i + 1
|
|
|
|
board.close()
|