[rtttl] Gate on_finished_playback callback storage behind define

Wrap the on_finished_playback CallbackManager storage, registration
method and call site behind USE_RTTTL_FINISHED_PLAYBACK_CALLBACK so
configs without an on_finished_playback automation pay zero RAM and
zero flash for it.

Keeps CallbackManager rather than switching to StaticCallbackManager
because rtttl is MULTI_CONF — a per-class compile-time N would force
every instance to reserve max(callbacks_per_instance) slots.
This commit is contained in:
J. Nick Koston
2026-04-25 14:26:23 -05:00
parent b5ccd55f4e
commit 12f744bbbe
5 changed files with 17 additions and 1 deletions
+5
View File
@@ -29,3 +29,8 @@ output:
rtttl:
output: rtttl_output
on_finished_playback:
- then:
- logger.log: "Playback finished 1"
- then:
- logger.log: "Playback finished 2"