I have a device that is a simple BLE device with a button, and I need to detect when the user long presses the device (via characteristic change) even when the app is in the background.
This click will trigger a remote call the server.
I have two questions regarding this:
#1 Can I have this achieved without a foreground service?
#2 If I have a foreground service running with the BLE GATT callbacks how can I detect when the device is in range again?
My current solution is to have a foreground service always running in the background but with that, the user will need an always showing notification of the app.