Skip to content

Script that pulls data from pokeapi.co and prints a Pokemon on thermal paper.

License

Notifications You must be signed in to change notification settings

StefanAvra/print-a-pokemon

Repository files navigation

print_a_pokemon.py

This script prints a Pokemon once a day on thermal paper. Data is retrieved via pokeapi.co.

Example of a print:

bulbasaur scan

Printer

I'm using a cheap thermal printer and the ZJ-58 Driver on Raspberry Pi. Text is printed via serial connection and images are sent to CUPS, so CUPS has to be configured.

Usage

print_a_pokemon.py depends on ImageMagick. Install that first and check if it can be executed via convert in terminal.

Clone this repo and cd into ./print-a-pokemon.

Create and activate virtual env

python3 -m venv venv
source venv/bin/activate

Install dependencies

pip install -r requirements.txt

To create a cron job that runs print_pokemon.sh everyday at 20:00 you can run

crontab -e

and add

0 20 * * * /path/to/directory/print-a-pokemon/print_pokemon.sh

About

Script that pulls data from pokeapi.co and prints a Pokemon on thermal paper.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published