From e4d0d6d352975be30ea1ed236fc5e93e39b96584 Mon Sep 17 00:00:00 2001 From: Jake Hillion Date: Sun, 26 Apr 2020 19:08:59 +0100 Subject: [PATCH] Added test python script --- python/server.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 python/server.py diff --git a/python/server.py b/python/server.py new file mode 100644 index 0000000..d23961e --- /dev/null +++ b/python/server.py @@ -0,0 +1,15 @@ +#!/usr/bin/python3 + +import serial + +with serial.Serial('/dev/ttyACM0') as ser: + while True: + for i in range(30): # selected LED + for j in range(30): # LED + for k in range(3): # colour + for l in range(2): + ser.write('f' if (i==j and k==1) else '0') + ser.write('n') + ser.write('l') + ser.write('q') +