Raspberry Pi project: network speed tester

For my home internet, I have one choice - Spectrum, née Time Warner Cable.  I don't completely live in the boonies but it is far enough away from everything that I can't get anything but cable, and Time Warner is the only cable company I got.  Honestly it hasn't been bad - I have been a customer since they were Roadrunner, and have had nearly zero problems.  Had a mixup when we moved our phone service to them, which led to us dropping phone altogether and just using mobile (and the alarm system for emergencies). Had a couple useless repair folks.  Over a 20 year history with them, I'm pretty pleased.

However, we have started having brownouts.  We'll be tooting along, then the feed will go to a dribble. I pay for 50 Mbps down, and usually get 70, but then it will be 500 Kbps for hours.  Then it will be fine.  Is it Spectrum?  My modem?  My router?  Something else on my network? I wasn't sure, so I would lug my laptop back there, plug the ethernet from the cable model directly in, and run Speedtest. Started to get some data.  Then, the laptop that had an ethernet port went titsup.  Now what?

Enter the Speedtest Pi.  I scrapped a screen from an old POS appliance that I tested and was allowed to keep, an old mini keyboard, and one of the dozen Pis that I have laying around from various programs I have taught, and built a semi-permanent speed test appliance that I can go and use anytime I want.

I did need to buy an AV shield at Microcenter so I didn't have to soldier the heck out of the Pi, but that's OK. This was a quick and dirty job, and the shield was only $15.

Now - best way to do the speedtest?  Well, did you know there is a Speedtest API? I DID NOT.  To make it even better, there is a speedtest command line interface app in the install paths for Raspbian.  So I simply:

sudo apt-get install speedtest-cli

and that's all there was to it.

Next next step is to put a fast switch in, so that I can leave it on all the time, and then have it run every hour or so, and show a graph on the screen.  Should be a fun Python project.

Comments are closed
Mastodon