mirror of
https://gitlab.sectorq.eu/jaydee/mqtt_srv.git
synced 2025-12-14 18:44:53 +01:00
bitwarden
This commit is contained in:
27
mqtt_srv.py
27
mqtt_srv.py
@@ -233,7 +233,7 @@ for o, a in opts:
|
||||
_THR_VAL = sys.argv[3]
|
||||
else:
|
||||
_WIZZARD = True
|
||||
MQTT_HOST = "mqtt.lan"
|
||||
MQTT_HOST = "mqtt.home.lan"
|
||||
MQTT_PORT = 1883
|
||||
|
||||
if _PUBLISH:
|
||||
@@ -729,9 +729,28 @@ def on_message(client, userdata, msg):
|
||||
tright = config['morefine']['tright']
|
||||
left = config['morefine']['left']
|
||||
mid = config['morefine']['mid']
|
||||
|
||||
|
||||
|
||||
myCmd = "bash /home/jd/test.sh"
|
||||
status, output = subprocess.getstatusoutput(myCmd)
|
||||
f = open( "/tmp/monitors.txt" )
|
||||
contents = f.read().splitlines()
|
||||
f.close()
|
||||
writeLog(contents)
|
||||
for i in contents:
|
||||
writeLog(i)
|
||||
d = i.split(";")
|
||||
if len(d) < 2:
|
||||
continue
|
||||
writeLog(d[1])
|
||||
if d[1] == "DELL P3421W":
|
||||
mid[0] = d[0]
|
||||
elif d[1] == "VG27WQ":
|
||||
left[0] = d[0]
|
||||
elif d[1] == "PHL 243V5":
|
||||
tleft[0] = d[0]
|
||||
elif d[1] == "PHL 273V7":
|
||||
tright[0] = d[0]
|
||||
writeLog("dpc")
|
||||
writeLog(contents)
|
||||
|
||||
#xrandr --output DisplayPort-1 --primary --auto --mode 3440x1440 --output HDMI-A-0 --auto --left-of DVI-I-1-1 --mode 1920x1080 --output DisplayPort-0 --auto --left-of DisplayPort-1 --mode 2560x1440 --output DVI-I-1-1 --above DisplayPort-1 --mode 1920x1080
|
||||
if myObj["target"] == "mid":
|
||||
|
||||
Reference in New Issue
Block a user