module

RNS::Rnstatus

Class methods

format_interface(ifstat : InterfaceStat, astats : Bool = false) : String

Format the status display for a single interface stat. Returns the formatted string (multiple lines).

Source
format_json(stats : TransportStats) : String

Format stats as JSON string.

Source
get_interface_stats

Collect interface stats from the running Transport instance. Matches Python Reticulum.get_interface_stats() behavior.

Source
hidden_interface?(name : String) : Bool

Check if an interface name should be hidden by default (not shown unless --all).

Source
interface_stat_to_hash(ifstat : InterfaceStat) : Hash(String, String | Int64 | Int32 | Float64 | Bool | Nil)

Convert an InterfaceStat to a JSON-compatible Hash.

Source
main(argv : Array(String) = ARGV.to_a)

Main entry point for the rnstatus binary.

Source
mode_str(mode : UInt8) : String

Return a mode string from an interface mode constant.

Source
parse_args(argv : Array(String)) : Args

Parse command-line arguments matching Python argparse behavior.

Source
size_str(num : Float64, suffix : String = "B") : String

Format a byte count with appropriate unit suffix. Matches rnstatus.py size_str() exactly.

Source
sort_interfaces(interfaces : Array(InterfaceStat), sorting : String | Nil, sort_reverse : Bool) : Array(InterfaceStat)

Sort interfaces by the given criterion.

Source
speed_str(num : Float64, suffix : String = "bps") : String

Format a speed value as a human-readable string with unit suffix. Matches rnstatus.py speed_str() exactly.

Source
version_string

Version string matching Python's "rnstatus {version}" format.

Source

Nested types