duggan / inkystock Goto Github PK
View Code? Open in Web Editor NEWA tiny, hackable, Raspberry Pi Zero powered e-ink display for cryptocurrency, stocks and more.
License: GNU General Public License v3.0
A tiny, hackable, Raspberry Pi Zero powered e-ink display for cryptocurrency, stocks and more.
License: GNU General Public License v3.0
Maybe look into https://finnhub.io?
Free API key. As used in this project: https://github.com/bgant/inkyphat-stockmarket
I have been searching for an e-ink stock ticker, and I think that this is the only one that stands out, it would be really nice if you would add support because a lot of people come from the pwnagotchi project, and having a pi0 with a waveshare screen unused for months.
This seems like a really cool project and I hope that you will add support.
When I follow the installation instructions, upon executing ./run.sh
the code fails to execute:
root@PiZero:~/inkystock# ./run.sh
Traceback (most recent call last):
File "main.py", line 7, in
from inkystock.paint import Pillow
File "/root/inkystock/inkystock/paint.py", line 11, in
from PIL import ImageFont as PILFont, Image as PILImage, ImageDraw as PILDraw
File "/usr/local/lib/python3.7/dist-packages/PIL/ImageFont.py", line 34, in
from . import Image, features
File "/usr/local/lib/python3.7/dist-packages/PIL/Image.py", line 94, in
from . import _imaging as core
ImportError: libxcb.so.1: cannot open shared object file: No such file or directory
root@PiZero:~/inkystock#
Looks like it should work fine based on the output, the screen clears itself but never draws new image
./run.sh
2022-09-03 11:13:44,813 INFO [main.py:main:main:51]: Pulling current data from API and caching
2022-09-03 11:13:45,860 INFO [main.py:main:main:55]: Pulling historical data from API and caching
/home/pi/inkystock/inkystock/db.py:84: SAWarning: Dialect sqlite+pysqlite does not support Decimal objects natively, and SQLAlchemy must convert from floating point - rounding errors and other issues may occur. Please consider storing Decimal numbers as strings or integers on this platform for lossless storage.
rs = self.conn.execute(s)
2022-09-03 11:13:46,103 INFO [main.py:main:main:85]: Most recent price in USD for BTC: 19789.82 (last close: 20153.975977982507)
2022-09-03 11:13:48,866 WARNING [layout.py:layout:size:132]: (Container name=ticker_bar_text) will have elements outside the visible canvas (w:413)
2022-09-03 11:13:48,870 WARNING [layout.py:layout:size:132]: (Container name=chart) will have elements outside the visible canvas (w:249)
2022-09-03 11:13:48,875 WARNING [layout.py:layout:size:140]: (Container name=chart) will have elements outside the visible canvas (h:64)
2022-09-03 11:13:48,895 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(18, 8), text=BTC, font=./resources/fonts/CozetteVector.ttf, font_size=12) to canvas, size: (18, 8) position: Position(x=0, y=1)
2022-09-03 11:13:48,898 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(8, 6), text=w, font=./resources/fonts/04B_21__.TTF, font_size=10) to canvas, size: (8, 6) position: Position(x=18, y=1)
2022-09-03 11:13:48,902 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(18, 8), text=USD, font=./resources/fonts/CozetteVector.ttf, font_size=12) to canvas, size: (18, 8) position: Position(x=26, y=1)
2022-09-03 11:13:48,912 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(60, 10), text=3/9 11:13, font=./resources/fonts/CozetteVector.ttf, font_size=12) to canvas, size: (60, 10) position: Position(x=64, y=0)
2022-09-03 11:13:48,924 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(413, 5), text=> 19902.33 > 19901.61 > 19903.67 > 19903.34 > 19904.13 > 19832.75 > 19833.02 > 19773.22 > 19789.82, font=./resources/fonts/04B_03__.TTF, font_size=8) to canvas, size: (413, 5) position: Position(x=-163, y=1)
2022-09-03 11:13:48,939 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(143, 27), text=19,789, font=./resources/fonts/04B_30__.TTF, font_size=30) to canvas, size: (143, 27) position: Position(x=0, y=0)
2022-09-03 11:13:48,948 INFO [paint.py:paint:paint:241]: Rendering Text(image_size=(29, 5), text=-364.16, font=./resources/fonts/04B_03__.TTF, font_size=8) to canvas, size: (29, 5) position: Position(x=0, y=0)
2022-09-03 11:13:48,955 INFO [paint.py:paint:paint:241]: Rendering (PillowImage size=(20, 10)) to canvas, size: (20, 10) position: Position(x=0, y=7)
2022-09-03 11:13:48,964 INFO [paint.py:paint:paint:241]: Rendering (PillowImage size=(20, 21)) to canvas, size: (20, 21) position: Position(x=5, y=0)
2022-09-03 11:13:48,976 INFO [paint.py:paint:paint:241]: Rendering (Chart size=(248, 63), dpi=130.60084411852694) to canvas, size: (248, 63) position: Position(x=1, y=1)
Small enhancement suggestion:
Easy setting to rotate the screen 180 degrees.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.