Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UNKNOWN_LOG_ENTRY #14

Closed
ValentinMerlet opened this issue Dec 20, 2017 · 2 comments
Closed

UNKNOWN_LOG_ENTRY #14

ValentinMerlet opened this issue Dec 20, 2017 · 2 comments
Labels

Comments

@ValentinMerlet
Copy link

Hello !

I'm trying to log the accelerometer after killing my app but from the time I kill the app, the BLE Service is disconnected and when I try to get the logs from the sensor I have the following error :
UNKNOWN_LOG_ENTRY from the errorHandler of the downloadAsync() method.

It's working fine when I start and stop logging inside my app without killing it.

Here the project https://github.com/umanit/metawear_sensor_logging_example/tree/master/app/src/main/java/capteur/umanit/fr/testcapteur I just created as an example. ConfigureActivity start the logging and GetLogActivity stop it, is there something I'm missing ? Again, those activities are achieving their job well if I don't kill the app.

@scaryghost
Copy link
Contributor

If you kill your app, you've lost its entire state so of course you will get errors when trying to resume the app.

Either save the object state before closing the app or use anonymous routes. These are described in the documentation under Serialization and Anonymous Routes.
https://mbientlab.com/androiddocs/latest/advanced_features.html

@ValentinMerlet
Copy link
Author

Thank for your answer,

Just to specify my question, what I'm trying to do is getting the logs from the sensor through a background Service (a JobScheduler technically).

I thought that AnonymousRoutes was made only to manipulate sensors across multiple devices, I didn't notice that I can use them in my case. I'm gonna use serialization in last resort.

Thank for your assistance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants