Receive RideState events when app is not started
In the previous SDK I was able to observe ride lifecycle by creating a io.hammerhead.sdk.v0.Module. Within my module I would then broadcast explicit intents in the lifecycle callbacks. These events received by a BroadcastReceiver in my own app. This let me hear ride start events even if my app was not running. I don't see a way to reproduce this in the extensions library. I have to have a running Activity or Service with an active KarooSystemService connection. Am I missing something? Is this feature at least on the roadmap?
-
I've never used the old SDK, but with the extensions library you can just define a service that is started by the karoo system as soon as the user installs the extension and on every subsequent reboot. Unlike background services on standard android, your process is never killed by the OS, so I think it's very easy to work with.
Please sign in to leave a comment.
Comments
2 comments