-
-
Notifications
You must be signed in to change notification settings - Fork 24
Description
Is your feature request related to a problem? Please describe.
Back when I designed the interface for this library in 2020, it seemed like a no-brainer to use an event-based system based on the ABI used by multiple Switch background services, which in turn makes it possible for the application using the library to span a single additional background thread that uses waitMulti() to handle multiple events and call it a day.
However, this very same reasoning falls short if the application using the library doesn't use events at all, which is something I never stopped to consider. This forces the developer to span an additional background thread to exclusively handle changes from the library, which is a bit overkill.
Please consider this library was specifically designed with nxdumptool in mind before it became a much broader project, and that application relies heavily on background services that do use this kind of ABI.
Describe the solution you'd like
A callback-based system that uses a function pointer provided by the user to handle UMS status changes under the library's very own background thread.
This new system should be able to co-exist with the current event-based system, because both designs have their own particular use cases.
Additional context
Initially proposed by averne and discussed in #26.