You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Just came across the package - i have periodic GPS messages coming in from my device, where best to add a handler to parse/process either in a generic (new) callback or how to add a callback for my specific message type? currently they are getting tagged as 'Unhandled unsolicited modem notification'. any suggestions welcome.
The text was updated successfully, but these errors were encountered:
Hi @dhershko2 !
I've looked into the code and I'd propose to copy logic used in _callStatusUpdates, create a new field (e.g. _userNotoficationHandlers) and a new method (e.g. addNotificationHandler or registerNotificationHandler). Afterwards - you should be able to extend the notification logic from your app.
It is questionable if the user-defined callback should be called as the first one or the last one. Calling at the begining allows to easily override the default modem behaviour.
On the contrary, if the notification is not custom, but well-specified, I'd advise to simply add another if statement and a notification-specific, configurable handler.
I'm not a code owner, so I cannot guarantee that the proposal is good enough. Either way - I hope that you will find my suggestion valuable 🙂
Just came across the package - i have periodic GPS messages coming in from my device, where best to add a handler to parse/process either in a generic (new) callback or how to add a callback for my specific message type? currently they are getting tagged as 'Unhandled unsolicited modem notification'. any suggestions welcome.
The text was updated successfully, but these errors were encountered: