Dr. Wireless » Linux Magazine

0
37


Why is the WiFi not working? Instead of always typing the same steps to diagnose the problem, Mike Schilli writes a tool in Go that puts the wireless network through its paces and helps isolate the cause.

Imagine you’ve just arrived at your vacation resort, and the WiFi isn’t working. Is the router’s DHCP server failing to assign an IP address to your laptop? Is it DNS? Or is it just that the throughput is so poor that everything seems to be stalling?

You can diagnose all of these issues by running various command-line tools, but it is tedious and annoying to have to repeat the procedure every time. How about a tool that repeatedly runs these steps at regular intervals, visualizes the results, and hopefully zeroes in on the root cause?

I will use the tview [1] library from GitHub as the terminal user interface (UI) for my wifi diagnostic tool. After all, some well-known projects, such as Kubernetes, also use it for their command-line tools. With just a few lines of code, tview switches the current terminal to raw mode and displays simple graphical elements such as tables or forms in a retro white on black background style0 (Figure  1). It accepts keyboard input in raw mode, and applications can use it to control actions on the interface.

[…]

Use Express-Checkout link below to read the full article (PDF).



Source link