Raspberry Pi Shopping List Printer
I decided to finish a project from last year - a shopping list that would print from a thermal printer.
I wrote a PHP website with a MySQL backend last year that both my husband and I could access. It contained an easy to edit shopping list. You click on an item to add it to the shopping list and click on it in the list to remove it. Items would be grouped by type.
Then I bought this thermal printer from Pimoroni
Using this guide from Adafruit I was able to setup the printer up with a Raspberry Pi.
I created a php file that would dump the shopping list into json.
Then I created a python file on the pi that would call that page and dump the data on the pi
The second python file runs all the time, checking for a button press.
I added an arcade button to the Pi so when a button press was detected it would format and print the shopping list.
Here's the shopping list code
https://github.com/Lorrainbow/thermal-printer/blob/master/print_shopping.py