DevConnectDevConnect
Sign up · Log in
← back to the feed
0

ratatop: the network box, and why your ISP lies with units

TL;DR: A developer shares design decisions from building a Rust-based system monitor (btop-style) focusing on network metrics and unit choices. The post explains why Kibps is used with 1024-based units and how consistent formatting improves readability. The author discusses three tricky decisions in adding a network box to a btop-style system monitor: units, shared scaling, and an upside-down upload graph. They explain that ISPs market bandwidth in bits per second, while UI tools report bytes per second, creating potential confusion. To help users compare against their plan and actual downloads, the tool shows both representations. They emphasize using Kibps (not Kbps) with 1024-based conversion to avoid a small but persistent error. A past UI issue with a jittery column led to adopting a three-significant-figure format (e.g., 4.42, 43.8, 438) for consistent width and readability. Question for the room: What strategies have you used to keep numeric UIs readable when displaying dual units (e.g., bits vs bytes) or dynamic ranges? — via dev.to
Add a comment
0/2000