A Go program tells users about nearby WiFi routers
Programming Snapshot – Go WiFi Scanner
© Lead Image © damedeeso, 123RF.com
Mike Schilli lives high above the city. Inquisitive by nature, he wrote a Go program for the Raspberry Pi Zero that detects new WiFi routers in his neighborhood and reports them via texts to his phone.
Whenever you try to connect to the WiFi network with your computer, you are likely to also see the network IDs of surrounding apartments and houses in the selection list. The names often reveal interesting facts. Do the neighbors have a sense of humor? Have they purchased a new router yet again? To keep up to date, I decided to design a scanner that would collect the names of all accessible WiFi access points every five minutes, save them with a timestamp in an SQLite database, and send a text message to my cellphone in case of changes (Figure 1).
Minimalist Hardware
A Raspberry Pi is a great choice of hardware platform for my scanner, which comes as a compiled Go binary by the name of wifiscan from the sources in this issue. My scanner will search for available WiFi beacons and is happy to use a slow CPU and a small amount of RAM during the scan. A Raspberry Pi Zero 2W with 1GB RAM costs around $15 and is perfect for the task. A plastic housing for a few dollars more provides dust protection, and I'm sure you have a power supply with a USB-C connection lying around that can provide the two watts the Raspberry Pi needs. You will also need an SD card with at least 8GB capacity.
[...]
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Framework Laptop 13 Pro Competes with the Best
Framework has released what might be considered the MacBook of Linux devices.
-
The Latest CachyOS Features Supercharged Kernel
The latest release of CachyOS brings with it an enhanced version of the latest Linux kernel.
-
Kernel 7.0 Is a Bit More Rusty
Linux kernel 7.0 has been released for general availability, with Rust finally getting its due.
-
France Says "Au Revoir" to Microsoft
In a move that should surprise no one, France announced plans to reduce its reliance on US technology, and Microsoft Windows is the first to get the boot.
-
CIQ Releases Compatibility Catalog for Rocky Linux
The company behind Rocky Linux is making an open catalog available to developers, hobbyists, and other contributors, so they can verify and publish compatibility with the CIQ lineup.
-
KDE Gets Some Resuscitation
KDE is bringing back two themes that vanished a few years ago, putting a bit more air under its wings.
-
Ubuntu 26.04 Beta Arrives with Some Surprises
Ubuntu 26.04 is almost here, but the beta version has been released, and it might surprise some people.
-
Ubuntu MATE Dev Leaving After 12 years
Martin Wimpress, the maintainer of Ubuntu MATE, is now searching for his successor. Are you the next in line?
-
Kali Linux Waxes Nostalgic with BackTrack Mode
For those who've used Kali Linux since its inception, the changes with the new release are sure to put a smile on your face.
-
Gnome 50 Smooths Out NVIDIA GPU Issues
Gamers rejoice, your favorite pastime just got better with Gnome 50 and NVIDIA GPUs.
