Skip to content

feat(firmware): add evil OLED eye style - #119

Merged
jamro merged 4 commits into
mainfrom
feat/evil-eyes
Nov 21, 2026
Merged

jamro merged 4 commits into
mainfrom
feat/evil-eyes

Conversation

@jamro

@jamro jamro commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Add eyes_style=evil: solid white scowling silhouettes on the 128×32 OLED (pointed high outers, rounded low inners, concave brow, convex bottoms; no pupils), always menacing for every animation
  • Reuse the classic pose/blink/sleep/dead-X pipeline (dots-tier); wire registry, settings validate, Config UI, API docs, and web/eyes preview
  • Keep draws cheap (drawFastVLine) and pump a few WAV chunks per tick so heavy OLED work cannot starve I2S (slow/gappy welcome audio, early cut)
Screenshot 2026-11-21 at 08 47 54

Test plan

  • pio run (default env)
  • pio test -e native (eyes_style accepts evil, rejects unknown)
  • npm run lint --prefix ui
  • Config: set evil, confirm OLED look + blink/glance
  • POST /anim welcome (and optionally attention): speech at normal speed, full clip, no early cut
  • Dead X hold still shows X marks with evil
  • Gallery: /eyes shows an evil preview card

Summary by CodeRabbit

  • New Features
    • Added the Evil OLED eye style, featuring mirrored, pupil-free scowling eyes that follow existing poses, blinks, and animations.
    • Evil is available in configuration and API settings, with a preview in the eye-style gallery.
  • Improvements
    • WAV playback processes multiple audio chunks per update, helping keep speech and clips playing smoothly.
  • Documentation
    • Added guidance on eye styles and efficient OLED drawing, including checking audio playback on-device.

@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Adds an evil OLED eye style with firmware and browser renderers, settings and API documentation, and a gallery preview. WAV updates now pump up to three chunks per call. Two Face me wizard tests record servo-move request counts before save attempts.

Changes: Evil OLED eye style and audio updates

Layer / File(s) Summary
Style requirements and design
openspec/changes/evil-eyes-style/*, openspec/changes/evil-eyes/specs/evil-eyes/spec.md
The OpenSpec proposal and requirements describe the evil style’s shape, animation behavior, settings compatibility, and integration points.
Firmware rendering and audio updates
src/display/eyes/styles/evil.cpp, src/display/eyes/styles/eye_style_ids.cpp, src/display/eyes/styles/registry.cpp, src/audio/wav_stream.cpp, test/test_settings_validate/test_settings_validate.cpp, src/display/eyes/styles/README.md, AGENTS.md, docs/README.md, docs/testing.md
Firmware draws and registers the evil style, and validation accepts its ID. WAV updates pump up to three chunks per call. The documentation adds style and audio-underrun guidance.
Settings, API, and previews
docs/api.md, ui/src/config/ConfigForm.tsx, ui/src/views/ApiReference.tsx, web/eyes/index.html, web/js/eyes-preview.js
The configuration form, API references, and browser gallery include evil. The browser preview draws mirrored, tapered eye shapes.

Face me wizard test assertions

Layer / File(s) Summary
Servo-move request baselines
ui/test/wizard.test.tsx
The successful and failed save tests record the servo-move request count before the save attempt.

Estimated code review effort: 4 (Complex) | ~45 minutes

Change: Feature

Suggested reviewers: blakelton, mechazawa

Merge Risk: Minimal · up to 88b01

This adds a new evil eye style with matching settings, API documentation and a preview, and makes speech playback process more audio per update. No concrete problems were found. Check speech playback on a device before release.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "feat(firmware): add evil OLED eye style" matches the main change. The PR adds an evil eye style for the OLED, registers it, and wires it through validation, the Config UI, API docs, and the…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "feat(firmware): add evil OLED eye style" matches the main change. The PR adds an evil eye style for the OLED, registers it, and wires it through validation, the Config UI, API docs, and the web preview. The title is specific and concise, and it follows a conventional commit format. It does not cover the WAV streaming change or the wizard test fix, which is expected for a title.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: bf45ee6f-92cb-43db-b184-420047597af4
Commits

Reviewing files that changed from the base of the PR and between 3e9addf and 88b019c.

Files selected for processing: 20

  • AGENTS.md
  • docs/README.md
  • docs/api.md
  • docs/testing.md
  • openspec/changes/evil-eyes-style/.openspec.yaml
  • openspec/changes/evil-eyes-style/design.md
  • openspec/changes/evil-eyes-style/proposal.md
  • openspec/changes/evil-eyes-style/specs/evil-eyes/spec.md
  • openspec/changes/evil-eyes-style/tasks.md
  • src/audio/wav_stream.cpp
  • src/display/eyes/styles/README.md
  • src/display/eyes/styles/evil.cpp
  • src/display/eyes/styles/eye_style_ids.cpp
  • src/display/eyes/styles/registry.cpp
  • test/test_settings_validate/test_settings_validate.cpp
  • ui/src/config/ConfigForm.tsx
  • ui/src/views/ApiReference.tsx
  • ui/test/wizard.test.tsx
  • web/eyes/index.html
  • web/js/eyes-preview.js

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

@jamro
jamro merged commit 3778f5a into main Nov 21, 2026
5 checks passed
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.

1 participant