* Opening Bell

Introducing the Stock Ticker Feature

* Update stock_manager.py

Assume folder exists

* Update stock_manager.py

removing logos to focus on function for now

* Update stock_manager.py

parse yahoo scripts

* Update stock_manager.py

stock query update

* Update stock_manager.py

slow down stock display

* Update display_controller.py

adjust screen flow

* Update stock_manager.py

shipping features

* Update stock_manager.py

stock refresh in the background

* Customize Display timings

customize display timings

* Update stock_manager.py

stock font size change

* Sizing and Spacing

CHanged font sizing on chart and clock spacing

* Update clock.py

Date format changes

* Update stock_manager.py

actually read stocks from config file

* Update stock_manager.py

add config manager

* readme update

readme update and formatting for better flow

* Update .gitignore

rename reference folder

* Update config.json

changed default stocks to test update implementation

* Stock News

Stock news Ticker

* Update config.json

increase scroll speed

* Scroll Performance

Tuning news scrolling performance

* updating scroll direction

orienting scroll direction

* News tuning

removed test files and increased scroll speed

* Create test_news_manager.py

need a test script to call upon

* Update test_news_manager.py

test script tuning

* troubleshooting test script

* Update test_news_manager.py

* Update config.json

scroll speed increases

* Update config.json

scroll tuning

* Update config.json

speeding up

* Update config.json

still making text faster

* Update config.json

Trying to tune scrolling

* Update config.json

testing crazy parameters

* Update test_news_manager.py

remove sleep delay

* scroll tuning

scroll tuning

* scroll logging and debugging

FPS counter and debug messages

* Update config.json

matrix speed tuning

* Update news_manager.py

News separator

* Update news_manager.py

separator character change

* Stock News manager Rename

rename stock news ticker to enable other news in the future

* Update display_controller.py

load config update

* Update stock_manager.py

remove redundant import

* Stock news settings

Stock news has more granular control

* Stock news joins the lineup

Stock News added to the display controller and drawing display instead of image
This commit is contained in:
Chuck
2025-04-10 22:16:38 -05:00
committed by GitHub
parent 6fb65346e7
commit b4c2fff9a8
9 changed files with 834 additions and 34 deletions

View File

@@ -89,15 +89,17 @@ class Clock:
# Get AM/PM
ampm = current.strftime('%p')
# Format date with ordinal suffix
# Format date with ordinal suffix - split into two lines
day_suffix = self._get_ordinal_suffix(current.day)
date_str = current.strftime(f'%A, %B %-d{day_suffix}')
# Full weekday on first line, full month and day on second line
weekday = current.strftime('%A')
date_str = current.strftime(f'%B %-d{day_suffix}')
return time_str, ampm, date_str
return time_str, ampm, weekday, date_str
def display_time(self, force_clear: bool = False) -> None:
"""Display the current time and date."""
time_str, ampm, date_str = self.get_current_time()
time_str, ampm, weekday, date_str = self.get_current_time()
# Only update if something has changed
if time_str != self.last_time or date_str != self.last_date or force_clear:
@@ -111,7 +113,7 @@ class Clock:
# Draw time (large, centered, near top)
self.display_manager.draw_text(
time_str,
y=3, # Move down slightly from top
y=2, # Move up slightly to make room for two lines of date
color=self.COLORS['time'],
small_font=False
)
@@ -122,15 +124,23 @@ class Clock:
self.display_manager.draw_text(
ampm,
x=ampm_x,
y=5, # Align with time
y=4, # Align with time
color=self.COLORS['ampm'],
small_font=True
)
# Draw date (small, centered below time)
# Draw weekday on first line (small font)
self.display_manager.draw_text(
weekday,
y=display_height - 18, # First line of date
color=self.COLORS['date'],
small_font=True
)
# Draw month and day on second line (small font)
self.display_manager.draw_text(
date_str,
y=display_height - 9, # Move up more from bottom
y=display_height - 9, # Second line of date
color=self.COLORS['date'],
small_font=True
)