Browse Source

bottombarupdate in case of a new mqtt message

master
root 1 year ago
parent
commit
b178d6ce27
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      mqtt_sniffer.py

+ 2
- 0
mqtt_sniffer.py View File

1
+import bottombar as bb
1
 import argparse
2
 import argparse
2
 from console_bottombar import BottomBar
3
 from console_bottombar import BottomBar
3
 import getpass
4
 import getpass
53
                 logfile = open('mqtt_sniffer.log', 'w')
54
                 logfile = open('mqtt_sniffer.log', 'w')
54
             logfile.write("%9.04f::%s::%s\n" % (ts, message.topic, data))
55
             logfile.write("%9.04f::%s::%s\n" % (ts, message.topic, data))
55
             logfile.flush()
56
             logfile.flush()
57
+    bb.redraw()
56
 
58
 
57
 
59
 
58
 if __name__ == "__main__":
60
 if __name__ == "__main__":

Loading…
Cancel
Save