msg MQTT message

main
zart 5 months ago
parent d1eefe3adf
commit f7bbca59a3

@ -8,6 +8,7 @@ port = 48835
print(os.getcwd())
with open("smp_coder/user.txt", "r") as f:
user_id = f.read().strip()
user_id = user_id.split("=")[-1]
@ -64,3 +65,7 @@ client.loop_stop()
client.disconnect()
print("收到响应,客户端退出。")
os.system("sudo myenv/bin/python3 smp_coder/extur_smp.py > logex.txt 2>&1 &")
print("启动树莓派拍照客户端成功。")

@ -52,12 +52,12 @@ else
fi
# 运行第二关的extur_smp.py
nohup sudo $env_dir/bin/python3 smp_coder/extur_smp.py > logex.txt 2>&1 &
if [ $? -eq 0 ]; then
echo "extur_smp.py 启动成功"
else
echo "extur_smp.py 启动失败"
fi
#nohup sudo $env_dir/bin/python3 smp_coder/extur_smp.py > logex.txt 2>&1 &
#if [ $? -eq 0 ]; then
# echo "extur_smp.py 启动成功"
#else
# echo "extur_smp.py 启动失败"
#fi

Loading…
Cancel
Save