Skip to content

Add Libra Colour / Elipsa 2E support, fix config persistence, UTF-8 rendering, and page-turn buttons#12

Merged
Ashex merged 1 commit intoAshex:mainfrom
systematiccaos:additional_devices
Mar 22, 2026
Merged

Add Libra Colour / Elipsa 2E support, fix config persistence, UTF-8 rendering, and page-turn buttons#12
Ashex merged 1 commit intoAshex:mainfrom
systematiccaos:additional_devices

Conversation

@systematiccaos
Copy link
Copy Markdown
Contributor

Device support:

  • Add touch quirks for Kobo Libra Colour (monza/390) and Elipsa 2E (condor/389) with APP_TOUCH_MIRROR_Y=1
  • Query actual framebuffer dimensions at runtime in diagnostics instead of hardcoding 1072x1448

Config persistence:

  • Add fflush()+fsync() before fclose() in config_save() to ensure data reaches persistent storage before the forced reboot
  • Guard persist_session() and save_session() against writing empty session data that would overwrite a valid config.ini
  • Add double sync with 2s delay before reboot in run.sh to let the eMMC write-back cache drain (prevents FAT32 corruption / FSCK files)
  • Add diagnostic logging throughout bootstrap, config, and path code

UTF-8 rendering:

  • Rework sanitize_bitmap_text() → sanitize_display_text(): when OT fonts are loaded, pass UTF-8 through to FBInk's FreeType/HarfBuzz renderer instead of replacing all non-ASCII with '?'. German umlauts, accented characters, CJK, etc. now render correctly. The ASCII-only fallback is kept for the bitmap VGA font path.
  • Expose font_ot_enabled() so callers can query the rendering mode

Physical page-turn buttons:

  • Accept any EV_KEY device during input scan (the Libra Colour's gpio-keys was silently dropped because it didn't match the narrow key code allowlist)
  • Accept key_press events from all key-capable devices, not just the first one found
  • Map KEY_F23 (193) / KEY_F24 (194) for Libra Colour, plus KEY_PAGEUP/DOWN, KEY_NEXTSONG/PREVIOUSSONG, KEY_BACK/FORWARD for other models
  • Route page-turn buttons to feed (next/prev page), thread (scroll), and settings (scroll) views

…endering, page-turn buttons, and feed list scrollbar

Device support:
- Add touch quirks for Kobo Libra Colour (monza/390) and Elipsa 2E
  (condor/389) with APP_TOUCH_MIRROR_Y=1
- Query actual framebuffer dimensions at runtime in diagnostics
  instead of hardcoding 1072x1448

Config persistence:
- Add fflush()+fsync() before fclose() in config_save() to ensure
  data reaches persistent storage before the forced reboot
- Guard persist_session() and save_session() against writing empty
  session data that would overwrite a valid config.ini
- Add double sync with 2s delay before reboot in run.sh to let the
  eMMC write-back cache drain (prevents FAT32 corruption / FSCK files)
- Add diagnostic logging throughout bootstrap, config, and path code

UTF-8 rendering:
- Rework sanitize_bitmap_text() → sanitize_display_text(): when OT
  fonts are loaded, pass UTF-8 through to FBInk's FreeType/HarfBuzz
  renderer instead of replacing all non-ASCII with '?'.  German
  umlauts, accented characters, CJK, etc. now render correctly.
  The ASCII-only fallback is kept for the bitmap VGA font path.
- Expose font_ot_enabled() so callers can query the rendering mode

Physical page-turn buttons:
- Accept any EV_KEY device during input scan (the Libra Colour's
  gpio-keys was silently dropped because it didn't match the narrow
  key code allowlist)
- Accept key_press events from all key-capable devices, not just the
  first one found
- Map KEY_F23 (193) / KEY_F24 (194) for Libra Colour, plus
  KEY_PAGEUP/DOWN, KEY_NEXTSONG/PREVIOUSSONG, KEY_BACK/FORWARD
  for other models
- Route page-turn buttons to feed (next/prev page), thread (scroll),
  settings (scroll), and feed list (scroll) views

Feed list scrollbar:
- The feed list view (paper roll icon, top-left) previously cut off
  feeds that didn't fit on screen with no way to scroll
- Add vertical scrollbar with UP/DN end caps and draggable track
- Narrow content area to make room for scrollbar on the right
- Support scrolling via touch (scrollbar) and physical page-turn
  buttons
- Fix feed selection to account for scroll offset (page_start)
@Ashex Ashex merged commit 9d01070 into Ashex:main Mar 22, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants