Skip to content

tommokmok/esp32s3_YetAnotherStockPricceTracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ESP32-S3 LVGL Yet Another Stock Price Tracker

A demo project for ESP32-S3 using LVGL to display stock prices with WiFi configuration and persistent storage.

Most other ESP32 stock price tracker projects require registering for an API account to fetch stock prices.

For me, I wanted a simple implementation. So I found a usable API from Yahoo, which may be blocked in the future, but works for now...

Project Core Values

  • For learning purposes.
  • The implementation is kept simple and straightforward.
  • No fancy stuff, just make it work.

Things that this project can help you

Around 80% of the code is generated by AI. The most time-consuming task was finding a proper and simple API to get the stock price.

If you need a simple and straightforward API, please check get_stock_price_all_yahoo() in appController.cpp.

14-Jul-2025 updated

After serveral test, the above simple API is not very stable, so inevitable to find a stabel API which need to register an account.

Finally, FINNHUB is a good choice which have 60 API call per 1min. That is very good for testing purpose.

Others have very little api call per min.

Screenshots & Demo

AP Setting Device Info Homepage

Don't know why github can't show the gif. You can check the demo in below link:https://i.ibb.co/1fD8GXL8/request.gif

Features

  • ESP32-S3 + LVGL GUI v9.1
  • WiFi configuration (SSID/Password)
  • Stock price fetching from Yahoo Finance
  • Persistent storage (NVS)
  • Software reset and storage reset
  • Responsive UI with FreeRTOS tasks

Getting Started

Prerequisites

  • VS Code with PlatformIO extension
  • ESP32-S3 board + 2.8" TFT LCD

    Note: It is not recommended to buy this dev board. It has some hardware issues and may reset automatically, especially when connected to a PC.

    • Using ESP32-S3-N8R8
    • LCD Driver: ST7989, 320 x 240 pixels
    • Touch Driver: XPT2046

Building & Flashing

  1. Clone this repository:

    git clone <your-repo-url>
  2. Open the project in PlatformIO.

  3. Rename the API_TOKENS.h.example to API_TOKENS.h and fill your own FINNHUB api tokens

  4. Build and upload to your ESP32-S3 board.

Usage

  • On first boot, configure WiFi via the GUI.
  • Press "Update" to fetch stock prices.
  • Use the AP Settings tab to change WiFi credentials.
  • Use the Reset button to clear storage and reboot.

File Structure

lib/
  appController/      # Main application logic
  stockPrice/         # GUI code
  storage/            # Persistent storage (NVS)
src/
  main.cpp            # Entry point

Customization

  • Edit s_Symbols in stock_price_gui.cpp to change the tracked stocks.

Future Plans

  • Multi-language support (English/Chinese)
  • Add color themes
  • Update the Arduino framework (currently using IDF v4.4)
  • Create a database and save to SD card; display charts on screen
  • Many areas can be further optimized...

License

MIT License

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published