github marcoand75/cpr-vcodex-steroids 1.5.0.22-dev1-cpr-vcodex-steroids

3 hours ago

🚀 CPR-vCodex Steroids — Upstream Alignment + Status Bar Enhancements

This release consolidates the full upstream 1.5.0.20–1.5.0.22 alignment into Steroids, plus expands the status bar time display with two new reading-time modes.

📊 Status Bar Time-Left: 2 New Modes (5 total)

The reader status bar now offers 5 options instead of 3 for what to display:

Mode Shows What it means
Hide Nothing (as before)
Chapter Est. time to finish the chapter Per-book pace from page turns (as before)
Book Est. time to finish the book Per-book pace + progress extrapolation (as before)
🆕 Session Duration Time read since you opened this book Resets every time you open/close a book. Shows how long you've been reading this session.
🆕 Today Total Total time read today Sum of all reading today across all books, including the current session.

The label in settings was renamed from "Time Left""Display Time" (EN) / "Tempo rimanente""Tempo visualizzato" (IT) since it now also shows elapsed time, not just remaining estimates.

How it works (simplified):

  • Session Duration uses the internal reading session timer — it starts counting when you open a book and resets when you close it.
  • Today Total reads from the existing daily summary file (summary.json), which already tracks everything you've read today. It includes the current session automatically — no double counting.

Settings → Customize Status Bar → Display Time → cycle through all 5 options. Also configurable from the web interface (/steroids-settings page).


🛠️ What Was Ported from Upstream 1.5.0.20–1.5.0.22

All deferred items from the previous alignment are now resolved:

📟 HAL Crash Detection

  • Ported the panic capture mechanism (PANIC_CAPTURE_MAGIC) that distinguishes genuine crashes (watchdog resets with the magic marker set) from normal deep-sleep wake cycles. False-positive crash reports after sleep are now suppressed.
  • CrashActivity no longer redundantly clears the panic marker — the HAL handles it automatically after verifying the capture was written completely.

📚 SdCardFont Fragmentation-Resistant Storage (1.5.0.20)

The single biggest technical port — 16 files changed, 800+ lines. The font system no longer allocates one large contiguous buffer for glyphs. Instead:

  • 4 KiB chunked storage (24 chunks × 4 KiB = 96 KiB virtual space) — each chunk allocated independently, so only one 4 KiB contiguous block is needed at a time instead of a large buffer. Eliminates render failures caused by heap fragmentation on the 380 KB ESP32-C3.
  • CJK fallback font resolution — new hasCodepoint() + coverageHandler on font families automatically picks a font that can render Chinese/Japanese/Korean characters.
  • TextGetter prewarm — pre-warms font data before rendering without re-allocating.
  • FrameBufferLoan — loans the framebuffer during EPUB section builds, giving the inflate stream a guaranteed ~43 KB contiguous window. Prevents "Failed to init inflate stream" errors.
  • FontDecompressor refactor — raw uint8_t* + realloc instead of std::vector, removing lazy-init complexity.

🖼️ Grayscale Image Pipeline (Steroids-specific, unchanged)

  • Shared gamma LUT (1.5) + empiric thresholds (50/120/200) + error-diffusion dithering. Already in place.

🔌 Web Server Serial + FirmwareFlasher Chip Validation

  • Web server serial number endpoint and FirmwareFlasher now validate the chip target before flashing. Ported from upstream.

🏠 Carousel Recents Panel Fix

  • The "Carousel Recents (N)" panel was appearing in the wrong theme. Fixed the guard so it only shows in Lyra Marcoand75, not Lyra Carousel.
  • App icon menu slots increased from 5 → 7 (matching Marcoand75).
  • Recent books count increased from 3 → 20 (clamped to 10 by the home activity).

📦 Files Changed

Area Files
Status bar time-left CrossPointSettings.h, ReadingStatsStore.h/.cpp, EpubReaderActivity.cpp, StatusBarSettingsActivity.cpp, SettingsList.cpp, CrossPointWebServer.cpp, I18nKeys.h, english.yaml, italian.yaml
HAL crash detection lib/hal/HalSystem.cpp, CrashActivity.cpp
SdCardFont (font system) SdCardFont.h/.cpp, SdCardFontManager.h/.cpp, EpdFont.h/.cpp, EpdfFamily.h/.cpp, EpdFontData.h, FontDecompressor.h/.cpp, GfxRenderer.h/.cpp, FontCacheManager.h/.cpp, main.cpp
Carousel fix HomeActivity.cpp, LyraCarouselTheme.h/.cpp
FirmwareFlasher FirmwareFlasher.cpp/.h
Docs STEROIDS-ADDICTIONS.md, STEROIDS-ALIGN-TO-UPSTREAM.md, README.md, CHANGELOG.md

📋 Build Verification

  • RAM: 16.0% (52,276 / 327,680 bytes)
  • Flash: 98.5% (6,456,613 / 6,553,600 bytes)
  • Warnings: 0

📝 Full Commit List (14 commits)

Don't miss a new cpr-vcodex-steroids release

NewReleases is sending notifications on new releases.