njh / mqtt-sn-tools

Command line tools written in C for the MQTT-SN (MQTT for Sensor Networks) protocol
MIT License
193 stars 84 forks source link

mqtt-sn-sub display current time and the topic name in verbose mode. #15

Closed MichalFoksa closed 9 years ago

MichalFoksa commented 9 years ago

New command line option -V to display current time and the topic name in verbose mode. Example output:

./mqtt-sn-sub -p 1885 -k 600 -t '$SYS/#' -V
2015-07-21 20:47:35 $SYS/broker/messages/received: 8
2015-07-21 20:47:35 $SYS/broker/messages/per second/received: 1
2015-07-21 20:47:35 $SYS/broker/bytes/received: 232
2015-07-21 20:47:35 $SYS/broker/bytes/per second/received: 38
2015-07-21 20:47:35 $SYS/broker/heap/current size: 146496 bytes
2015-07-21 20:47:35 $SYS/broker/heap/maximum size: 147552 bytes
2015-07-21 20:47:35 $SYS/broker/uptime: 210 seconds
2015-07-21 20:47:35 $SYS/broker/retained messages/count: 1
2015-07-21 20:47:41 $SYS/broker/messages/per second/received: 0
2015-07-21 20:47:41 $SYS/broker/bytes/per second/received: 0
2015-07-21 20:47:41 $SYS/broker/uptime: 216 seconds