added client and reqs

Signed-off-by: Ebbe Baß <ebbe@ping-mee.de>
master
Ebbe Baß 2022-08-12 02:15:58 +02:00
parent b0b1d81c6f
commit 9579055ca6
2 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,18 @@
import time
import os
current_path = os.path.dirname(os.path.realpath(__file__))
try:
import serial
except ImportError:
try:
os.system("pip install pyserial")
import serial
except ImportError:
print("Please execute'pip install -r requirements.txt'")
exit()
host = serial.Serial('COM3', 9600)
while True:
output = host.readline()
print(output)

1
requirements.txt 100644
View File

@ -0,0 +1 @@
pyserial==3.5