gitmyhub

Mo

Python ★ 37 updated 19d ago

A Raspberry Pi thermal printer solution for Magic: The Gathering.

A Raspberry Pi project that prints physical Magic: The Gathering cards and decks on a thermal printer, fully offline.

PythonFlaskRaspberry PiGPIOsetup: hardcomplexity 4/5

Mo is a Python project that turns a Raspberry Pi (a small, affordable single-board computer) into a dedicated physical card printer for the card game Magic: The Gathering. Instead of looking up cards on a screen, you can print physical-quality card images instantly on a thermal printer — the kind of small paper printer you see printing receipts at stores.

The setup works in two stages. First, on a regular computer, you run a data pipeline that downloads card data and images from the internet, converts the images into a format optimized for thermal printing (called dithering, which reduces colors to simple black-and-white patterns), and builds a local database. Second, on the Raspberry Pi itself, a web app runs automatically at boot, letting you search for cards, browse decklists, and trigger printing — all without an internet connection.

The web interface has a numpad for quickly picking cards by their mana cost (the resource you spend to play them), a search tool for finding specific cards or tokens, and a deck list view that lets you preview and print multiple cards at once. It also includes a feature to fetch popular competitive decklists from an external site during the build stage. A physical switch on the hardware lets you toggle between connecting to your home network or broadcasting its own hotspot, which is handy at game tables away from home. The project is built in Python and runs as a background service on the Raspberry Pi.

Where it fits