Skip to content

Conversation

@pkendall64
Copy link
Collaborator

Two parts to this PR.

  1. Devices that are not supported by the hardware can return false from their init function and the device framework will not call their start, timeout or event functions during the main loop.
  2. Event publish/subscribe
    • Events fired from the code now pass an event type so only subscribers to that event type will be notified, reducing the number of calls in the main loop.
    • Device event framework extended to allow device handlers to subscribe to certain events and their event function will only be called if that type of event is fired.

@pkendall64 pkendall64 added V4.0 🍔 house keeping 🧹 Cleanup of code and house keeping labels Nov 22, 2024
Copy link
Contributor

@mha1 mha1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, works with no obvious errors on rx and module, e.g. both serials ok, pwm ok, module screen ok.

@pkendall64 pkendall64 merged commit 383b2d1 into ExpressLRS:master Dec 18, 2024
22 checks passed
@pkendall64 pkendall64 deleted the next/event-subscription branch December 18, 2024 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

house keeping 🧹 Cleanup of code and house keeping V4.0 🍔

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants