Skip to content

DIY Bitcoin stats display on ESP32 based eink/lcd displays

License

Notifications You must be signed in to change notification settings

nsvrn/blocktime-eink

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

₿locktime (for esp32 eink/LCD displays)


alt blocktime-eink alt tdisplay s3

Setup

NOTE: The esp32 library has breaking changes in the latest libraries (v3.0+) for the colored display, not fixed in this repo yet, details here

  1. Hardware:
    • eink: TTGO T5s 2.7in/T5 2.13in (or any similar ESP32 based eink can work with some minor code tweaks from these)
    • Color LCD: TDisplay-S3
    • Lithium-ion battery (OPTIONAL), link
    • 3d printed case (OPTIONAL), T5s/T5(printed at 102% scale for better accuracy).
  2. IDE and libraries:
    • Arduino IDE
    • Add these URLs under - Preferences > Additional boards manager URLs)
          https://adafruit.github.io/arduino-board-index/package_adafruit_index.json
          https://dl.espressif.com/dl/package_esp32_index.json
          https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json
      
    • pip install pyserial
    • Install these libraries from Arduino IDE (Tools > Manage Libraries): Arduinojson, GxEPD2, Adafruit GFX, Adafruit BusIO
    • For TDisplay-S3: copy this git repo's lib folder content to your Arduino libraries folder
    • Make sure esp32 by esspressif is installed under Tools > Board > Board Manager
  3. Connect, configure and upload:
    • Connect your device with usb and make sure to run sudo chmod 666 /dev/ttyACM0 (replace ACM0 with your correct device location)
    • If esp32 board library is installed correctly, you will be able to select "LilyGo T-Display" as the board manager.
    • Open the correct main .ino file in Arduino IDE and point to correct device location
    • Rename config_sample.h to config.h and uncomment+edit to add your WiFi SSID/password and refresh frequency
    • Compile and upload, phew!

Data Source

  • This code uses blockchair public API over https
  • You can replace the API to your choice(or host your own using py/flask like this) by editing the refreshData() and jsonToStr() functions (and the root cert)
  • If needed the root CA cert can be changed here
  • Stats in the screenshot(T5s 2.7in): block number, price in USD, sats per USD, tx fee, hashrate, difficulty, #nodes, full node data size, datetime in UTC


  • For TFT/LCD and command line display, check this repo.

About

DIY Bitcoin stats display on ESP32 based eink/lcd displays

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published