test
This commit is contained in:
parent
28436dbda3
commit
6bf43da152
10
server.py
10
server.py
@ -1,5 +1,6 @@
|
||||
from flask import Flask, request
|
||||
import os
|
||||
import sys
|
||||
from colormap import rgb2hex
|
||||
|
||||
app = Flask(__name__)
|
||||
@ -31,6 +32,15 @@ def hello():
|
||||
hex = hex.replace("#", "")
|
||||
|
||||
str = "56" + hex + "00f0aa"
|
||||
try:
|
||||
subprocess = os.Popen("echo Hello World", shell=True, stdout=os.PIPE)
|
||||
subprocess_return = subprocess.stdout.read()
|
||||
print(subprocess_return)
|
||||
except print(0):
|
||||
pass
|
||||
|
||||
|
||||
|
||||
os.system(
|
||||
f"gatttool -i hci0 -b b2:3b:03:00:14:d6 --char-write-req -a 0x0009 -n {str}"
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user