Ubuntu Bionic for OpenFrame
Ubuntu Bionic for OpenFrame (Development Version with Kernel 5.2)
Follow the instructions on this page for installing to external media,
or use the Reflashing Tool to install to internal memory.
I've recently had the need to run Ubuntu Bionic on most of my OpenFrames and I've spent some time (far too much time!) tidying up my efforts into something which I'm happy to release for everybody. Given that this probably the last Ubuntu LTS to support 32-bit hardware I thought it was worth a bit of polish.
This single image works for both internal and external storage for OpenFrame 1 (Joggler) and OpenFrame 2 devices.
There are a few things which are a bit different to previous images; most notably this is a command line only image, created to be as 'vanilla' as possible. This means you can use instructions available for any Ubuntu Bionic system to install whichever GUI environment you might like. Or none at all if you just want a single-use system.
I also needed to add Bluetooth to my OpenFrames and tried out a bunch of combination adapters. I eventually found this EZCast WiFi 2.4/5 GHz + Bluetooth 4.2 Adapter for £10 from Amazon. You can easily remove the plastic housing (though not strictly necessary) and replace the old internal Ralink 2770F card.
- Single image for any OpenFrame.
- Built for size; about 430 MB space used initially.
- Fully working audio and OpenGL with kernel drivers.
- Automating scripts for completing common tasks (eg. installing X.Org Server).
- Support for the Realtek 8821CU combined 5 GHz WiFi and Bluetooth 4.2 module.
- Simple before-boot wireless network configuration.
- of-allsudo - Allow all users to use the sudo command with no password. Nice security hole puncher there.
- of-autologin <user> - Enable automatic login for a given user account.
- of-expand - Expand the root partition to fill the space available.
- of-getip - Output all IP addresses and their interfaces.
- of-install-build - Fetch kernel headers and install build-essential packages.
- of-install-xorg - Installs the X.Org Server
- of-netplan - Apply new network settings and restart interfaces.
Installation and Setup
Follow the instructions from one of the pages linked at the top (I'll create a proper page for this eventually). Boot the system and log in with:
If you're not installed to an OpenFrame 1's internal memory, run the comand of-expand to increase the root partition size to fill the whole volume (will reboot). Give it at least 10 minutes to complete - while it's running there'll be a file called 'expand' in the /root directory and there'll be a lot of drive activity.
Run passwd root to change the default root password. Use adduser <username> to add new user accounts and usermod -aG sudo <username> to give your user the right to run commands with sudo. Don't use the of-allsudo script unless you're developing something. In fact, I should probably remove that one.
If you need to save more space you could certainly uninstall some packages; the trick was balancing size and functionality. You can install a complete X.Org Server system with OpenGL running and a basic desktop within 1 GB, which was a loose aim when I was developing the image.
To save drive space, all apt package lists are stored in RAM. The OpenFrame has 512 MB RAM and half of this will be used when you've run apt update. If you install anything using apt, reboot to clear the package lists afterwards or you'll run into low memory issues. If you have plenty of drive space, remove or comment out the two lines related to apt lists in /etc/fstab. You should be left with only /var/log and /tmp mapped to tmpfs. I may automate this in of-expand. Don't remove the lines if you're running from internal memory!
If you're using an OpenFrame 2 the wireless connection does work... sort of. Performance is absolutely terrible and I've not been able to do anything about it. Maybe it's my OF2 which is at fault, but feedback would be appreciated. We're using the brcmsmac driver; the b43 was worse and broke Bluetooth for me. The broadcom-wl driver might do the trick, but there are licensing issues, so I can't distribute it. Good luck!
Because I wanted to experiment with automated image creation, Ubuntu Bionic for OpenFrame is built without user intervention on one of my servers. Every time a new version of the 3.16 kernel is released the build system will automatically fetch, patch and compile it, along with all support modules, then create a new image. You can tell if it's an automated build as the kernel version will be, for example, 3.16.71op (no number at the end).
Individual builds are not tested, so please post here if there's something obviously broken.
If you want to see the build log for the last run, they're all here.
This was really an experiment in producing an end-to-end, intervention-free process for creating operating system images which could be applied to any system, starting with kernel source code and working up from there. It's not quite as hardcore as compiling the entire OS a la Gentoo Linux, but there was still a decent learning curve. We're cross-compiling everything in a 32-bit schroot environment on a 64-bit server, using the headers from the kernel we've built to compile external modules and then building and updating the entire OS from the Ubunutu base system into an image file, without ever touching a real OpenFrame device.
I was particularly pleased to be able to add support for a decent 5 GHz wireless adapter with Bluetooth, even though it required a lot of work to find suitable drivers which could be 'encouraged' into compiling for kernel 3.16, plus the added work of automatically recompiling them for every new kernel. I did try to get the drivers working for the original Openpeak OS, but there's no way it was worth the effort for me; I'm no driver programmer and I think there's a lot that would need modifying. Someone prove me wrong!
Anyone wanting to investigate any of this for themselves, all of the code is here:
You may notice we're still using kernel 3.16. Everything works for this process right up to the latest kernel 5.2, except for ALSA audio switching. If you know anything about C programming or ALSA, please help in the 'Annual ALSA Appeal' thread. We have almost everything working, including line out detection; the only thing remaining is properly muting the internal speaker when a line out is connected. At the moment the speaker remains powered and an audio system interference crackle is always present. Get this fixed and I'll be able to bump us up to the latest long-term kernel.
This should be a great little project platform, so have fun with it! You'll find many Debian or Ubuntu guides are directly applicable, including a lot of Raspberry Pi guides - just don't go trying to install their ARM binaries, that won't work!