Wizard Chess

By Russell Barnes. Posted

19-year-old Bethanie Fentiman shocked her A-level classmates when she rocked up with a fully working Harry Potter Wizard’s Chess set as her final coursework assignment

Bethanie Fentiman can’t play chess, but when her imagination sparked and the opportunity presented itself, she brought the iconic game of Wizard’s Chess from Harry Potter to life using a Raspberry Pi, stepper motors, and possibly a little magic.

For her A-level computing coursework, Bethanie took an idea that had been nestling in the back of her mind, and turned it into a reality. Well, as much of a reality one can create when the literary version includes battling chess pieces that leave their opponents crushed to rubble on the board.

The full article can be found in The MagPi 51 and was written by Alex Bate.

Luckily for Bethanie, she’s a self-proclaimed Jambassador, actively participating in the Raspberry Pi scene via the Kent Raspberry Jam. With a community of makers to support her, Bethanie knew that she could complete the build and got to work, researching similar projects online that used magnets and motors to ‘magically’ move chess pieces on a board.

After an internet search for inspiration, she came across an Instructables build for an Arduino-powered chess-playing robot by user maxjus, and used the main concept as the basis for her build. The guide provided all the information Bethanie needed to build the physical structure of the board, allowing for drawer runners, gears and, of course, the electromagnet that would move each piece when required. A 4tronix PiStep board, along with two 28BYJ-48 stepper motors, took up the job of moving the runners and electromagnet into place, linked through to the Raspberry Pi.

As mentioned previously, Bethanie didn’t actually know how to play chess. So when it came to inputting the legal movements of each piece, she had two options: learn fast, or cheat a bit. Opting for the latter due to the time constraints of her coursework deadlines, Bethanie researched all the possible moves of each chess piece and worked them into the code. She could always learn to play the game later on.

 There's a lot of room beneath it for all the mechanisms to fit

A second issue, and one far more associated with the original material from which she was taking her inspiration, was what the pieces would do as they ‘took’ an opponent. In the book, each piece defeats its foes through ‘barbaric’ means. In reality, Bethanie plans on an upgrade to allow for movement around pieces… though once she gets her belated invitation to Hogwarts, we’re sure she’ll incorporate the expected level of brutality.
With the build complete and presented to her computing A-level class, Bethanie’s Wizard Chess was met with amazement.

“When I said I was going to make it, they just thought I was going to write the code and come up with designs for the board. So when I turned up with the board at school, fully moving and playable, they were slightly shocked.”

And they weren’t the only ones. Upon finishing her board, Bethanie took it to the Kent Raspberry Jam, where Twitter soon exploded with praise. From the Jam, ‘The Wizard Chess Tour’ was born as Bethany and fellow Jam members took to the road and presented the project at Jams in both Harlow and Covent Garden.

Now actively seeking an apprentice in the field, Bethanie plans on upgrading the build while continuing the Wizard Chess Tour at more Jams in the future.

From The MagPi store