PiM17 Introduction and early days

Pi-Star is an excellent hotspot firmware image that has brought multi mode hotspots to the amateur masses.

It could be improved in several areas, as it does not use many of the tools that make managing Linux systems easier.

Unfortunately, I don’t want to work on it directly.

(This was originally written 2022-02-14 when I first started this. I never published it, and decided to publish it now and have updated it today, 2023 Oct 01.)

The dashboard system is a pile of PHP which I assume without evidence is going to have security issues. There have been complaints that when viewing logs or other streaming responses in the browser that it is slow or inefficient. None of this is particularly interesting to me - I just want it to use Linux packages!

I am convinced a proper Linux distribution with everything in an automatically built system package is a good way to solve entire classes of problems that Pi-Star has now in supporting its users.

But, because I don’t want to deal with PHP, I started on a replacement dashboard too. And then I realized there must be a way to edit the config files for people who are not comfortable with SSH.

Then I started adding a method for snapshotting these config files after watching my dad try the config file editor.

These projects are nowhere’s near minimally viable. They need more attention, but unfortunately I don’t myself care about a dashboard all that much. It would be nice to have other devs try these out and see if it’s something they’d like to see improved. I’m happy to work on it, but limited hours in the day means that anything people aren’t using is not at the top of the list.

Anyway, it’s a new distribution based on Alpine called PiM17.

I might rename it later if it stops being M17 focused.

It is standard Alpine, but has additional PiM17 package repos that have packages for MMDVMHost, M17Gateway, mmdvmcal, that sort of thing.

It has a pretty barebones automated build system for releases that is functional, even if kind of hacky. That’ll do for now.

It runs on anything Alpine will run on, and I have an x86_64 hotspot that is functionally identical to the pi image in every way. All it takes is adding the repo and package signing key, and installing the packages.

I realized when I was about to test MMMDVMHost and M17Gateway on the Pi for the first time, that I needed to update the firmware on that particular hotspot board. So, knowing me, what did I do?

Yeah, I made another subproject. Well, three of them. First I added CI/CD builds to a fork of the MMDVM_HS firmware repo. Then I made a package that when built pulls down the latest release from that repo. Okay, we now have several hotspot firmwares pre-built. Let’s flash them! Easy right?

No, nothing is that simple. Hah.

First we need to know what board we are talking to. That’s not as easy as you might think, so let’s try to do it programmatically. This is subproject 2 of this effort for those of you not keeping track.

And to do that programmatically, we need to know the MMDVM protocol. That’s not too bad, but it started pyMMDVM. Which is nowhere’s near useful yet and not a priority, but got me familiar enough to at least get the hotspot firmware version!

Our flasher does not need all the features of a full pyMMDVM, so it doesn’t rely on that as a package or anything and just has enough to get the firmware version.

So now we have a little Python project mmdvm_easyflash, that knows where the firmware images are held in PiM17, knows what version hotspot we are dealing with and a couple other parameters, and can (for the most popular hotspot boards) select hopefully the right firmware, and then flash it. Automatically. Packaged as a system package. We can run this on boot if we want.

Updates are easy - apk update; apk upgrade - and they will pull down any new pre-built firmware as long as I’ve published something.

The goal here is not to be responsible for MMDVM hotspot modem firmwares myself - the goal is to automate as much as possible so there’s nothing manual that needs to be done except maybe tag something as a release.

We’re a long way from any level of completion, but I’ve been enjoying PiM17 for several radio-related and some non-radio purposes already.

I’m confident in saying PiM17 is a good base to build a new hotspot distribution on. I hope I’m not the only one interested in a good, properly Linux-y distribution so updates to the system don’t consist of a whole disk image.

I’d like help with this. I want to support the regular, not-hotspot modems like the stm32-dvm. I want pyMMDVM to be useful. I want mmdvm_easyflash to make the bar for updating modem/hotspot firmware so easy that there’s no excuse.

I can’t do it alone. I need you and other devs to try it out. Send feedback, let’s make hotspots and repeaters easy to automate and administer and ensure no poor soul need compile hotspot firmware on their pi ever again just because it’s the easiest way for them to cross-compile.

Find the images and repo link here.

Keep up to date by emailing me asking to be put on the manual news mailing list, or join my brand new discord server for the same purpose.