Sorry for my poor english.
I am using some extensions, TaifunTools, TaifunBattery and List Permission.
Is there a way to maintain the entire working of an application when it is in background and the only way to leave is to hit a button inside the app.
My apps use sensors ; GPS, accelerometers, gyroscope, clock, magnetometer in real time and makes lot of calculations driving display that must not stop or interrupt anyway.
I dont need to run background task but the entire app, is this extension useful for that ?
I am not a professional english speaking developer and i dont understand everything explained, witch way to obtain what i need ?
I hope someone wil help me.
First get your background functionality running in the foreground. Like this, you can find errors much easier. And as soon as you got it working in the foreground, then test it in the background.
Do not use global variables while in the background, use local variables instead
Do not use any user-visible or UI components in the background
In the background, use the Itoo StoreProperty/FetchProperty methods rather than TinyDB. TinyDB relies on SharedPreferences which will not ensure data synchronization across background processes.
I use more of one hundred global variables and lists used in many calculations and i never used only one local variable, i have 3673 blocs and i cannot do like that, so it wont work ?
I try to understand how to use Itoo, please how to use process (foreground) or task (background) with accelerometer, gyroscope, GPS and clock using blocks like "acceleration changed" and "gyroscope changed" ?
If i use foreground process or background task to launch gyroscope or accelerometer or GPS or clock, blocks like "acceleration changed" will work ?
When screen is locked or an other app is launched my app dont collect sensors informations and calculations are not done in real time, so when displaying again all is out of date.
It should be nice to alternate applications or lock screen to avoid batterie consumption and device heating.
Also using a tablet with Android before 10 with split screen only one off the two apps is active by clicking on it,
so my app doesnt need click after launched but using simultaneously a navigation app make it freeze, thats why using some tablets is not usefull, its a serious problem for users.
I never tried that event myself, this is something for you to try... the corresponding event handlers, which look like a procedure theoretically should work
It looks like it is now time for you to try something and if you got stuck, post a screenshot of your relevant blocks
in procedure app you forgot the argument x, which is required there
you can't use labels in the background, use a notification instead or use the text to speech component or use the notifier to log something you can read in logcat, Capturing Device Logs using adb logcat
if you want to trigger the Clock1.Timer event in the background, then you have to register that event for background processing and use a background handler which looks like a procedure...,how to register events see for example here Battery checker reminding you to unplug when fully charged