GCHQ-Inspired Interactive Escape Room

April 2021

Raspberry Pi, Python, Raspberry Pi OS, Ansible, Arduino, Teensy LC, C++

Escape Rooms Cheltenham

Myself and Char Lewis were commissioned by Escape Rooms Cheltenham to develop the electronics for a GCHQ-inspired escape room. The story behind the project was written by Escape Rooms Cheltenham, and we were responsible for designing and building the system. The escape room would be a unique experience where players could go back in time to solve puzzles and to decipher a number of different codes.

 

For this project we were responsible for sourcing parts to meet a design brief. The client had a number of different requirements and so we decided upon 2 separate systems, one controlled by a Raspberry Pi, and another controlled by a Teensy LC Arduino-based microcontroller. The components included things such as mag-locks, matrix keypads, LED lights, RFID readers and numerous switches. The system built would be used in a feature escape room at the venue, and therefore the end product had to be robust to last, but also modular enough to be easily repaired in the event of any problems. 

 

The Raspberry Pi system was the more complex of the 2, and we decided to use it as the client wanted to output information to a HDMI-connected screen as feedback to the room players. I have used Raspberry Pi's for a number of different solutions before in the past, so figured that it would be the best fit. For the Raspberry Pi OS I wrote an Ansible playbook to automatically provision the Pi ready for production. Halfway through the project the Raspberry Pi we had began developing issues and so we needed to order a replacement, running the Ansible playbook against the new Pi simplified everything massively and had the whole platform provisioned exactly as before in a matter of minutes. The code on the Raspberry Pi was all writing in Python, and I made use of a number of functionalities to get all the various different components communicating correctly. The majority of the system made use of GPIO, however I was limited to the number of GPIO pins on the Pi so needed to expand these which was done with an MCP23017 and communicated via I2C.

 

The Teensy LC system was more simplistic in terms of it having fewer connected components, however it had an equally important role in the whole escape room. This was developed using C++ code on the Arduino platform. One component controlled by the Teensy LC is an RFID/NFC reader which was interfaced using HSU communications. Both the HSU from the RFID reader and I2C communication from the Raspberry Pi system were new technologies to me, so this project required a lot of personal research to ensure that best practices were followed not just with the code, but also with the physical wiring of such components.

 

Once the prototypes for both systems were built, Char and I then had the task of building each system into a production-ready environment. This meant installing components into modified housings or on DIN rails, making up custom wires using Dupont and JST connectors, and soldering various components and creating mainboards for each component to connect on to. The specification was to have everything as modular as possible, so each component had to be able to be swapped out easily in the event of any issues. This was mainly because the components being used were all off-the-shelf solutions which were to be made to work with the overall escape room. Once the components were production-ready we then installed each system into its final location at the escape room venue.

 

Throughout the project we had a number of issues, however we were able to resolve them all without any compromises towards the original design brief. For example I had and issue with an LED which was blinking a specific sequence of lights, but should only be doing so until another part of the system received an input from a player. I was having issues with the input not fully registering until the blinking light had finished its sequence, the input wasn't being registered during the sequence. I soon found out that the cause of this was because my light sequence was part of the main loop of the Python script, and so would only register inputs once the sequence had finished. I fixed this by moving the sequence into its own process. This allowed inputs to be registered at any time and the light sequence would be able to display exactly as expected.

 

This project was hugely enjoyable to work on, and sparked a desire in me to do more of these systems. I thoroughly enjoyed the learning curve of the design and development of both the Raspberry Pi and Teensy LC sides of the escape room and I'm immensely proud of what we achieved. Without wanting to be too biased, the end product is extremely engaging and a great amount of fun with friends. If you're ever looking for a unique escape room experience I highly recommend visiting Escape Rooms Cheltenham.

GCHQ-Inspired Interactive Escape Room

Do you want to work with me on a similar project?

If you have a project requirement for your own website or web application I would love to work with you. Get in touch via the contact page or send an email to contact@alexwinder.uk with your request.