commit b66e5a34ad5842cc71eaf52dd0a7267f5d205c6b
parent 45cd1a0390f42ede13e36826b5dd5e9bc026b096
Author: sin <sin@2f30.org>
Date: Tue, 23 Feb 2016 17:31:24 +0000
Fix labels and use Rx/Tx throughout
Thanks FRIGN!
Diffstat:
4 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/sbm-plot b/sbm-plot
@@ -23,12 +23,12 @@ set grid
set xlabel "time"
set ylabel "Mbps"
datafile=system("echo $DATAFILE")
-plot datafile using ($1/1000/1000) with lines title "RX Mbps", \
- datafile using ($2/1000/1000) with lines title "TX Mbps"
+plot datafile using ($1/1000/1000) with lines title "Rx", \
+ datafile using ($2/1000/1000) with lines title "Tx"
set xlabel "time"
set ylabel "pps"
-plot datafile using ($3) with lines title "RX pps", \
- datafile using ($4) with lines title "TX pps"
+plot datafile using ($3) with lines title "Rx", \
+ datafile using ($4) with lines title "Tx"
unset multiplot
EOF
diff --git a/sbm-rt-plot b/sbm-rt-plot
@@ -18,12 +18,12 @@ set grid
set xlabel "time / s"
set ylabel "Mbps"
datafile=system("echo $DATAFILE")
-plot datafile using ($1/1000/1000) with lines title "RX Mbps", \
- datafile using ($2/1000/1000) with lines title "TX Mbps"
+plot datafile using ($1/1000/1000) with lines title "Rx", \
+ datafile using ($2/1000/1000) with lines title "Tx"
set xlabel "time / s"
set ylabel "pps"
-plot datafile using ($3) with lines title "RX pps", \
- datafile using ($4) with lines title "TX pps"
+plot datafile using ($3) with lines title "Rx", \
+ datafile using ($4) with lines title "Tx"
unset multiplot
pause 1
reread
diff --git a/sbm.1 b/sbm.1
@@ -32,8 +32,8 @@ Monitor the selected
.Ar interface .
If not provided the first active, non-loopback interface will be used.
.It Fl t
-Enable terse output. The first pair of values is RX/TX in bps and the
-second pair is RX/TX in pps.
+Enable terse output. The first pair of values is RX/TX in bits per second and the
+second pair is RX/TX in packets per second.
.El
.Sh AUTHORS
.An Dimitris Papastamos Aq Mt sin@2f30.org
diff --git a/sbm.c b/sbm.c
@@ -166,7 +166,7 @@ print(char *ifname, uint64_t rxbits, uint64_t txbits,
if (!tflag) {
scale(&rxsuffix, &rxbits);
scale(&txsuffix, &txbits);
- printf("%s: %3llu rx %4s %3llu tx %4s %6llu rx pps %6llu tx pps\n",
+ printf("%s: %3llu Rx %4s %3llu Tx %4s %6llu Rx pps %6llu Tx pps\n",
ifname,
(unsigned long long)rxbits,
rxsuffix,