bookmarks
This commit is contained in:
parent
d9b67442e6
commit
82944d7c77
1 changed files with 4 additions and 1 deletions
5
main.py
5
main.py
|
@ -1,5 +1,9 @@
|
||||||
#!/bin/python3
|
#!/bin/python3
|
||||||
|
|
||||||
|
# bookmarks
|
||||||
|
#
|
||||||
|
# threading: https://stackoverflow.com/questions/9848464/how-to-listen-to-http-requests-and-a-serial-channel-in-the-same-python-program
|
||||||
|
# wait for serial input: https://stackoverflow.com/questions/13017840/using-pyserial-is-it-possible-to-wait-for-data
|
||||||
import serial
|
import serial
|
||||||
import time
|
import time
|
||||||
|
|
||||||
|
@ -7,7 +11,6 @@ ser = serial.Serial('/dev/ttyACM0', baudrate = 9600, timeout = 1)
|
||||||
|
|
||||||
#time.sleep(3)
|
#time.sleep(3)
|
||||||
|
|
||||||
# https://stackoverflow.com/questions/13017840/using-pyserial-is-it-possible-to-wait-for-data
|
|
||||||
|
|
||||||
while 1:
|
while 1:
|
||||||
# { "command": "switch", "arg": "one", "state": "off"}
|
# { "command": "switch", "arg": "one", "state": "off"}
|
||||||
|
|
Loading…
Reference in a new issue