-
Notifications
You must be signed in to change notification settings - Fork 175
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
High system load on android after deselecting "rules->lock on road" #1230
Comments
Now i got my enviroment to compile navit. Setting ANDROID_HOME solved the error. The high load is not a "logical" fail, but android GPS send position updates very often. I will try to sort out GPS updates with no or with only minimal position change. |
https://developer.android.com/training/location/change-location-settings You could configure Android to send updates only at a specified interval: Update interval Fastest update interval |
I tried to change a line in navit/android/src/org/navitproject/navit/NavitVehicle.java : and replaced 0, 0, with 1000, 1 (minimum 1 second, minimum 1 m between callbacks. The question is whether this is a general problem at all or whether it is only due to the old hardware. Should I close this? |
If you deselect rules -> "Lock on road" while navit has a GPS fix the system load rise
to 100% on the used core.
I found the problem trigger at navit.c navit_vehicle_update_position() at
if (this_->route) { if (tracking) route_set_position_from_tracking(this_->route, tracking, pro); else route_set_position(this_->route, &cursor_pc); }
It look like route_set_position() is called to often and maybe trigger a loop or excessive recalculations. I'm not able to debug this down.
If i add a timed Rate limit e.g. some seconds all work well.
The problem is tested with navit 0.5.0. to navit 0.5.6
Testdevice "LG K9 Android 7.12" and "Samsung S3 mini linage 13"
Thanks for your work.
p.s. please tel me a Linux distribution where i can build the actual version for android. My ubuntu work only till 0.5.3
The text was updated successfully, but these errors were encountered: