/paperstonks

eInk display with stock info. Code is utter garbage.

Primary LanguagePython

PaperStonks

Self-contained quick project for a desk stock summary page using a Pimoroni InkyWhat eInk display and Raspberry Pi Zero W. I got the eInk capable of drawing red.

Intended as a gift, so the project is intended to be done reasonably quickly and configuration after 'deployment' should be possible remotely and with minimal fuss.

Setup

Pretty standard setup:

  • Install latest minimal Raspbian and flash to a SD card with Etcher.

  • Setup the image with SSH enabled, and add WiFi credentials.

  • Configure a new hostname stockticker.local in this case.

  • Set a new password, etc.

  • Run sudo apt update && sudo apt upgrade.

  • I used Pimoroni's quick setup curl https://get.pimoroni.com/inky | bash one-liner to get that side setup (its mostly doing things like installing pip, numpy and configuring SPI mode on the Pi). It takes a very long time to run.

  • A reboot is required at this point.

  • Clone this repo into the home directory git clone https://github.com/Scottapotamas/paperstonks.git

  • Use crontab -e to edit the cron jobs. Add */5 * * * * /home/pi/paperstonks/refresh_stonks.sh and @reboot /home/pi/paperstonks/refresh_stonks.sh as new lines.

Before giving the display as a gift, setup the dispay to have a nice 'welcome' image. Run the prep_display program with python gift.py to draw a dithered image.

welcom

Usage

  • Provide power and allow the system to boot.
  • The eInk display should display content when ready (system assumes a valid wifi/network connection is present).
  • Pulls stock info from Yahoo finance and formats the output for display on the eInk.

example

Updates

The Pi will pull this git repo periodically.