Skip to main content

STATUS

Syntax​

STATUS

Description​

Returns a one-line snapshot of the acquisition state, the data stream and the network link. Useful to monitor a live session and to spot a network that cannot keep up.

Response​

STATUS <RUN|STOP> <key> <value> <key> <value> ...

The line is a state followed by key value pairs. The fields below are supported; the line also carries diagnostic fields that you should ignore.

FieldDescription
RUN / STOPWhether acquisition is running.
stream_spsRows per second actually delivered on the data stream.
buf_dropData buffers dropped because the network could not keep up (non-zero = overload).
tx_failFailed transmissions.
netif_link1 = network link up, 0 = down.
phy_stateLink state: 1 down, 2 100 Mb/s full duplex, 3 100 Mb/s half duplex, 4 10 Mb/s full duplex, 5 10 Mb/s half duplex, 6 negotiating.
mac_speedNegotiated link speed in Mb/s.
mac_duplexFD = full duplex, HD = half duplex.

Normal operation shows 0 for buf_drop and tx_fail.

Example​

status.py
from hmcls_udp import Board

def parse_status(line):
tokens = line.split()
fields = {"state": tokens[1]}
fields.update(zip(tokens[2::2], tokens[3::2]))
return fields

board = Board("192.168.1.11")
for line in board.query("STATUS"):
if line.startswith("STATUS"):
s = parse_status(line)
print(s["state"], s.get("stream_sps"), "rows/s, dropped:", s.get("buf_drop"))