I built a laptop for EMF Camp 2024
Published: 2024-05-14
This blog post is also available in video form! Watch it on YouTube
EMF camp is coming up soon. It's a camping festival with talks, workshops, and fascinating installations. Attended by tech folk, craft folk, artists, and engineers.
Last time I took a giant playable LED Rubik's cube. I'm not doing that again this time, sadly. The cube is a bit broken, and it was a lot of effort to do, so this time I'm just doing a personal thing rather than a big installation.
Because of the kind of event that EMF is, I need to take with me some kind of device that is:
- portable
- has a battery that will last for most of the event
- is capable of displaying the timetable
- is capable of displaying the camp map
- can fetch updates to the timetable and camp map
- and provides a convenient way to contact my friends at the camp
So that's why I built a ZX Spectrum based laptop with a dial up modem, telephone handset, and a cassette deck! With all that functionality, I might not even need my smartphone while I'm there!

The phone bit
There's going to be a copper telephone network, and a DECT network at EMF camp. DECT is the standard that your cordless home phone uses to connect to the base station. Hopefully there will be some interesting ViewData services running somewhere on the phone network. So I'm planning to take this ViewData modem to access those services. It needs to be connected to a ZX Spectrum, and needs a separate telephone for dialling. The modem is the black box underneath the ZX Spectrum in this photo.

ViewData is a telephone based information access system. You dial a number, wait for an answer, and then let the modem join the call, and then you can receive what is essentially a TeleText page that contains the information you want.
In the UK, there was a ViewData service offered by the Post Office Telecoms service, which later became British Telecom (BT). Their service was called Prestel, so you might hear these modems referred to as Prestel modems. Prestel ran from 1978 to 1994. It is now thoroughly obsolete. There is nothing you can do with ViewData that you can't do more easily with an internet connection. But, of course, I enjoy playing with esoteric old computer systems, and so do a lot of other people that attend EMF Camp. So we're still gonna use it just for fun.

I could just take this assortment of components and connect them all together, but I'm gonna be in a field, and I kinda want to be able to take it around the camp without much effort. So that's why I decided to turn them into a laptop. All I really had to do was put all these parts into a case, and add a battery and power circuitry.

For some reason I decided to massively overcomplicate the phone part though. I bought a cheap landline phone, disassembled it, replaced the dial pad, and built a custom housing for it.

The phone line is kinda interesting. I was wondering about how to connect to the camp phone network while I'm wandering the camp. It's not like landline phones are portable, and the modem certainly doesn't support DECT. But then someone pointed out to me that BT makes a device called a Digital Voice adapter. You see, BT is trying to switch everyone over to VoIP. They want the whole phone network to be digital. If you register for an internet and phone service from BT today then they'll send you a "hub" which is a modem, wifi router, and a DECT base station all in the same package. But some customers have old style phones that they still want to use. In fact, you can still buy brand new BT branded analog telephones, which is what I did for this project. So they sell these devices for "upgrading" an old phone to be a DECT phone. I just need to embed one of those in my laptop.

With the DECT adapter, I can connect wirelessly to the phone network and have a completely mobile solution to accessing the timetable and camp map. Oh, and it will let me contact my friends while I'm there too, the phone still works as normal.
Another EMF-goer, called Ben, has put together a viewdata service for accessing the schedule information. I've left a link in the description to a browser based viewdata terminal emulator that he's set up to demo his service. I'm planning to make use of it while I'm there. But, of course, just in case that doesn't work for some reason, I have a backup plan.
You can find a demo of this on his website... On last inspection, the site appears to no longer work, but the link is preserved here anyway
https://viewdata.microwavepizza.co.uk/
Offline schedule access

It's possible that I won't be able to connect to the DECT network, or that my modem might develop a fault, or something else I've not expected. So my backup plan for if I can't access the schedule on the phone network is to just have a local copy on cassette tape, and load it directly.
I put quite a bit of effort into the software for this. It can show the timetable, and even filter it based on event type. You can view just a specific day's events, or even search in the title or speaker name fields.
The full 2024 timetable is not released yet, so I've used the 2022 timetable as a placeholder. I'm hoping that the 2024 timetable is distributed in the same JSON format that the 2022 timetable was. I'm also hoping that there's not significantly more data in the 2024 timetable, since it's such a struggle to fit it all in the spectrum's memory.
In fact, I already can't fit it all in. There's way too much text. My friend, Lissa, came up with a really clever text encoding scheme that gets the text down below 60% of its original size. She analysed a whole bunch of encoding and compression schemes before settling on this design. So, thank you Lissa! you made this a whole lot easier!
Instead of using the file as a stream of bytes, this encoding considers them to be a stream of bits. The encoding process analyses the text to create a list of characters ordered by frequency of use, and then assigns shorter encodings to the more frequently used characters. The encodings are chosen so that no short encoding is a prefix to a larger one. This is essential for the decoder to be able to identify when it has parsed a complete character.
The shortest encodings are only 3 bits long, but they get longer and longer as you have more unique characters. The encodings can get really long, and some characters are actually much larger in this encoding, but those are only the really infrequent characters, so overall you get a good space saving.
However, even with that I can't load all the text at once. Each event on the timetable has a detailed description attached to it. This is great, and I want to make sure that my program can display it. The only problem is that even just the description fields alone is too much to load all of it at once. The encoded description text is about 94k. The Spectrum only has 48k and after loading the program, map data, and other event information, there's only about 10k left over anyway.
The solution to this problem is to simply not load it all at once. If it's currently saturday, then I probably don't care too much about what happened on friday, or what's going to happen on sunday. So I don't need all of the descriptions for all of the events to be loaded at once. I've split up the descriptions into modules that can be loaded and unloaded as long as there is space in memory for them. In practice this means that you can only have one description module loaded at a time.
The Map
I decided it was worthwhile allocating a little bit of RAM for the map feature. This can stay loaded all the time. It does take up about 6k of RAM, but I think it will be worth it for the convenience of being able to navigate the camp in a hurry when a talk is about to start. It's not particularly detailed. There's only two zoom levels. The first one is just an overview of the camp, with only the biggest landmarks visible. You can zoom in on the north or south of the camp to see a little more detail. I mainly just want to be able to find all the venues listed on the timetable.

Have a go!
If you want to, you can play around with the software. Download the tap file for use in your favourite ZX Spectrum Emulator. You can also find all the code and releases on GitHub
I've tried to design it so that it can easily be ported to some other systems too, so that if you're going to EMF camp and bringing your own retro laptop that isn't ZX Spectrum based, then you can use the same software with a little bit of porting effort. I'd love to add support for MS DOS and Amiga myself, but I doubt I'll find the time before the event. It's only a couple of weeks away. Update: There is now an MS DOS version and also a Linux version
Since I'm taking this around a field, I've tried to make it easy to carry. The rainbow guitar strap isn't just to make it look cool, and the screen hinge is also a sturdy carry handle. Fortunately, I even had the foresight to design this little spring-loaded telephone handset retention system, so that the phone stays in place while I have the laptop on my shoulder.
I'll probably be quite easy to spot in the field. If you do find me at EMF camp, and have a cassette recorder, you can take a copy of the software from my cassette tape if you like.
Or, even better: I've never actually used this user-to-user communication software that came with the Prism modem. I've only got one modem, and never known anyone else with one while I've also had a proper phone system to try it with. So if you have one at EMF camp, come find me! Let's try it out!