Coder Social home page Coder Social logo

lostzen / lost Goto Github PK

View Code? Open in Web Editor NEW
349.0 42.0 75.0 1.87 MB

A drop-in replacement for Google Play services location APIs for Android

Home Page: http://mapzen.github.io/lost/

License: Other

Java 99.10% Shell 0.66% AIDL 0.24%
location location-services location-based location-privacy android android-library android-development

lost's Introduction

Deprecated

This project is deprecated for use and not recommended for modern Android applications. The maintainers are no longer available to maintain it and the implementation is now fairly divergent from modern Android requirements. We appreciate everyone who has contributed to this project in the past. Thank you!

Lost

Location Open Source Tracker (for Android)

Circle CI Build Status

Usage

This project seeks to provide an open source alternative to the Google Play services location APIs that depends only on the Android SDK. It provides 1:1 replacements for the FusedLocationProviderApi, GeofencingApi, and SettingsApi.

Lost operates by making calls directly to the LocationManager. Lost can run on any Android device running API 15 or higher regardless of whether or not it supports the Google Play ecosystem.

Set up:

Sample

For a working example please refer to the Sample App.

lost's People

Contributors

baldur avatar clydebarrow avatar crankycoder avatar ecgreb avatar eldk avatar friesenkiwi avatar kingofirony avatar mapnerd avatar matteblair avatar msmollin avatar sarahsnow1 avatar serv-inc avatar westnordost avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lost's Issues

Fix tests using Thread.sleep(100)

Description

A number of tests are currently ignored due to intermittent failures. These tests all depend on concurrency used by MockEngine to deliver mock location updates from a GPX trace file. We need to find a better way to test the behavior of FusedLocationProviderApi.setMockTrace(File) without the use of Thread.sleep(100).

Steps to Reproduce

Remove all @Ignore("Intermittently failing. Find a better way to test without Thread.sleep(100)") annotations and run tests.

Lost & Android Version

LOST 1.1.1

Make .gpx speed list optional

Currently, NodeList speedList is mandatory or the app will crash while mocking the file. It should be a trivial modification to make it optional.

Most tracks available on openstreetmap lack speed tags, and the current workaround is to append a large number of <speed>0</speed> to the track segment.

Possibly related: it would be nice to make a gpx extension allowing accuracy, since this might be important while testing an app. Also see #37.

Location listener demo crashes on first launch

Description

After installing demo app and launching for the first time if you navigate to the "LocationListener" demo activity the app crashes. User is never prompted to agree to location permissions.

Steps to Reproduce

  1. Uninstall demo app (if installed)
  2. Install demo app
  3. Launch and navigate to FusedLocationApi > LocationListener example
  4. Runtime permission dialog will not be displayed and app will force quit

Lost & Android Version

Lost 1.1.2-SNAPSHOT (local build on master)
Android 6.0.1

Support multiple location clients

We should explore the feasibility of supporting multiple location clients from multiple threads and/or processes.

This primary use case would be for a single application if the UI thread and a service thread both needed to register for location updates via separate clients.

The secondary and potential future use case would be to allow a shared instance of lost to run in a background service that could be used by more than one application.

Unable to register for network updates

When I try to implement LOST library, I receive this exception: (I am using Genymotion emulator for Android API 21, GPS is turned on and the example app is working properly)

'
FusionEngine﹕ Unable to register for network updates.
java.lang.IllegalArgumentException: provider doesn't exist: network
'

This exception can be seen, when calling 'LocationServices.FusedLocationApi.requestLocationUpdates(locationRequest, mLocationListener);'

Of course, before this I run 'mLOSTClient = new LostApiClient.Builder(mContext).build();' and then 'mLOSTClient.connect();'. and listener is also initialized.

What should I do?

Remove location permissions from library

The LOST library manifest should not include permissions ACCESS_COARSE_LOCATION and ACCESS_FINE_LOCATION. It should be the responsibility of client applications to include necessary permissions in its manifest based on usage.

Requires permission annotations should be added to the appropriate methods in the FusedLocationProviderApi.

    @RequiresPermission(
        anyOf = {"android.permission.ACCESS_COARSE_LOCATION", "android.permission.ACCESS_FINE_LOCATION"}
    )

Check if connected in LostApiClient#connect()

Avoid creating a new instance of FusedLocationProviderApiImpl if already connected. Registers duplicate listeners on the LocationManager and old instances are not properly cleaned up.

GoogleApiClient and LostApiClient differences

Hey guys,

Nice work implementing FusedLocation API! Thanks for it. I was going through the code base and it seemed like the FusionEngine just takes care of switching between NETWORK, GPS and PASSIVE location providers based on conditions?

GoogleApiClient implements additional strategies right? Like using Sensor data as a means to accurate the location and also battery saving strategies. Are those things in pipeline?

Thanks again!

Enforce one-to-one relationship for requests and listeners

Each LocationRequest should have only one LocationListener and each LocationListener should be associated with only one LocationRequest.

This also implies that each request/listener pair would have its own FusionEngine using the current architecture and that engine would not be re-used for other requests or listeners.

Alternatively we could adopt a model that uses a single FusionEngine for all requests/listeners. This is how it's performed in the Android framework and would require implementing some form of request bundling.

Either way we decide to implement this it should simplify the logic required in FusedLocationProviderApiImpl (especially when toggling mock mode) and better match the behavior of the [play services APIs](https://developers.google.com/android/reference/com/google/android/gms/location/FusedLocationProviderApi#requestLocationUpdates%28com.google.android.gms.common.api.GoogleApiClient, com.google.android.gms.location.LocationRequest, com.google.android.gms.location.LocationListener%29).

Is orientation provided?

For instance, with google maps user can change the phone orientation (phone is oriented to the west/east/north etc) and the angle of arrow on a map will be changed. Is this possible with LOST? Or, if not, maybe you could advise me, how to achieve this?

Thanks in advance for help.

Geofencing intent should have a GeofencingEvent extra

Description

Pending intents that are sent by a proximity alert trigger should attach a GeofencingEvent extra that has been populated with the triggering geofences, location, and transition.

Steps to Reproduce

  1. Register a Geofence using the Geofencing API.
  2. When the proximity alert is triggered the PendingIntent returned is missing the GeofencingEvent extra.

Could not run de lost-sample project

Hi !
I m imported the lost-sample project to Android Studio and deploy the application to my device GT-N7100.

When the app starts it just give me the follow error message: SettingsActivity}: android.view.InflateException: Binary XML file line #5: Error inflating class com.mapzen.prefsplus.EditIntPreference (bellow is the full error).

I already tried to use the lib with grandle, and after this download the jar to the libs folder... nothing works...

I would really appreciate if you guys help me on this. I liked the lib and it would be nice to use it on one of my projects.

Thanks,

Elcio A.

java.lang.RuntimeException: Unable to start activity ComponentInfo{br.com.qpainformatica.mylostsample/br.com.qpainformatica.mylostsample.SettingsActivity}: android.view.InflateException: Binary XML file line #5: Error inflating class com.mapzen.prefsplus.EditIntPreference
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2308)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2362)
        at android.app.ActivityThread.access$700(ActivityThread.java:168)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1329)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loop(Looper.java:137)
        at android.app.ActivityThread.main(ActivityThread.java:5493)
        at java.lang.reflect.Method.invokeNative(Native Method)
        at java.lang.reflect.Method.invoke(Method.java:525)
        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1209)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1025)
        at dalvik.system.NativeStart.main(Native Method)
 Caused by: android.view.InflateException: Binary XML file line #5: Error inflating class com.mapzen.prefsplus.EditIntPreference
        at android.preference.GenericInflater.createItemFromTag(GenericInflater.java:441)
        at android.preference.GenericInflater.rInflate(GenericInflater.java:481)
        at android.preference.GenericInflater.inflate(GenericInflater.java:326)
        at android.preference.GenericInflater.inflate(GenericInflater.java:263)
        at android.preference.PreferenceManager.inflateFromResource(PreferenceManager.java:272)
        at android.preference.PreferenceFragment.addPreferencesFromResource(PreferenceFragment.java:326)
        at br.com.qpainformatica.mylostsample.SettingsActivity$SettingsFragment.onCreate(SettingsActivity.java:40)
        at android.app.Fragment.performCreate(Fragment.java:1677)
        at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:872)
        at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1075)
        at android.app.BackStackRecord.run(BackStackRecord.java:682)
        at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1455)
        at android.app.Activity.performStart(Activity.java:5381)
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2279)

            at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2362)
            at android.app.ActivityThread.access$700(ActivityThread.java:168)
            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1329)
            at android.os.Handler.dispatchMessage(Handler.java:99)
            at android.os.Looper.loop(Looper.java:137)
            at android.app.ActivityThread.main(ActivityThread.java:5493)
            at java.lang.reflect.Method.invokeNative(Native Method)
            at java.lang.reflect.Method.invoke(Method.java:525)
            at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1209)
            at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1025)
            at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.mapzen.prefsplus.EditIntPreference" on path: /data/app/br.com.qpainformatica.mylostsample-2.apk
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:64)
at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
at android.preference.GenericInflater.createItem(GenericInflater.java:375)
at android.preference.GenericInflater.createItemFromTag(GenericInflater.java:430)
            at android.preference.GenericInflater.rInflate(GenericInflater.java:481)
            at android.preference.GenericInflater.inflate(GenericInflater.java:326)
            at android.preference.GenericInflater.inflate(GenericInflater.java:263)
            at android.preference.PreferenceManager.inflateFromResource(PreferenceManager.java:272)
            at android.preference.PreferenceFragment.addPreferencesFromResource(PreferenceFragment.java:326)
            at br.com.qpainformatica.mylostsample.SettingsActivity$SettingsFragment.onCreate(SettingsActivity.java:40)
            at android.app.Fragment.performCreate(Fragment.java:1677)
            at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:872)
            at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1075)
            at android.app.BackStackRecord.run(BackStackRecord.java:682)
            at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1455)
            at android.app.Activity.performStart(Activity.java:5381)
            at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2279)
            at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2362)
            at android.app.ActivityThread.access$700(ActivityThread.java:168)
            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1329)
            at android.os.Handler.dispatchMessage(Handler.java:99)
            at android.os.Looper.loop(Looper.java:137)
            at android.app.ActivityThread.main(ActivityThread.java:5493)
            at java.lang.reflect.Method.invokeNative(Native Method)
            at java.lang.reflect.Method.invoke(Method.java:525)

Background service

Explore the option of running the fused location provider in a background service.

Implement transition type

Description

Geofence.Builder should allow setting of transition types. Alerts should only be generated for the specified transitions.

getLastLocation() throws SecurityException on API 23+

Unfortunately we need to check if the ACCESS_FINE_LOCATION permission is granted every time we call this function.
Is this an intended behavior or some improvement is possible?

Process: com.amayatsky.test, PID: 5948 java.lang.SecurityException: "passive" location provider requires ACCESS_FINE_LOCATION permission.

Manage multiple location listeners in FusedLocationProviderApi

Currently, only one LocationListener can be register at a given time in the implementation of the FusedLocationProviderApi (the FusedLocationProviderApiImpl). It would be nice to have a list of listeners.

The reason: I currently develop an application with Mapbox, which use the FusedLocationProviderApi, but I also have another component that requires listening to location updates (using the LOST API). If my other component sends a request for location updates, the Mapbox component will not receive any more location updates because there is only one LocationListener in FusedLocationProviderApiImpl (and also because the FusedLocationProviderApi is static, which seems normal).

This modification would require a bit of coding to "combine" the requests. For instance, if a request asks for a PRIORITY_HIGH_ACCURACY and another for PRIORITY_LOW_POWER, then the PRIORITY_HIGH_ACCURACY will be the effective priority. Same for the updates intervals and displacement.

Set geofence initial trigger

Description

Add ability to set behavior for initial trigger when a new geofence is added.

GeofencingRequest.Builder setInitialTrigger (int initialTrigger)

Implement GEOFENCE_TRANSITION_DWELL and loitering delay

Description

Implement ability to set loitering delay value for GEOFENCE_TRANSITION_DWELL transition type. LocationManager.addProximityAlert(...) only supports enter and exit transitions so dwelling logic will need to reside in LOST.

Circle CI is not building fork pull requests

Why isn't Circle CI building pull requests coming from forks of this project? (for example #91)

According to the Circle CI docs fork pull requests should build just without any environment variables configured via the web UI (sonatype username/password) which is fine since these are only needed to deploy snapshots from master.

https://circleci.com/docs/fork-pr-builds/

Email has been sent to @circleci support and we are awaiting a reply.

Use real timestamps when mocking GPX locations

Currently mocking a GPX trace file replays all locations at the interval specified in the LocationRequest. Mock mode should optionally replay locations using the timestamps in the GPX file to replay them at the actual interval they were received.

Javadoc

Improve Javadoc coverage for public API

Injection of an Alternative Location Provider

I have been working on a project that involves writing a geolocation tracker in Android. My client has based itself in the AP region and thus the app inevitably has to deal with Chinese phones, of which the Google Location APIs based on the Wifi hotspots/cell towers don't perform particularly well.

Thus, I am looking for a way to integrate alternative location providers from e.g. Mozilla Location Service. A crude plan to do so is to modify FusionEngine to accept other external location providers in form of a LocationProvider, probably via an API of LocationServices.FusedLocationApi.addLocationProvider() (and a pairing LocationServices.FusedLocationApi.removeLocationProvider()) that allows others to add their favourite providers.

Any suggestions/pointers?

Unnecessarily huge method count

I have to enable multidex in my very small app just so I can include Mapbox, which includes this. Why is Guava used in something like this? It's completely unsuitable for Android development and should really be avoided at all costs.

Implement notification responsiveness

Description

Notification responsiveness is a battery optimization feature of the play services geofencing API that is subject to change by the system. It is not exposed in LocationManager.addProximityAlert(...) so its not immediately clear how this might be implemented in the context of LOST.

Runtime Exception thrown on a route start on Eraser Map

Got a runtime exception in LOST, when debugging with a locally build tangram version. Have noticed this exception occur a few times now on a start of a route. Unfortunately I do not have any specific steps to repro it. Following are device logs:

Device: Samsung Galaxy s5 (running 5.0)

Exception and surrounding device logs:

I/wpa_supplicant( 1149): nl80211: Received scan results (30 BSSes)
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.44.D5
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.44.D4
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.44.E5
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.44.E4
I/wpa_supplicant( 1149): weak signal to handover [9C.44.E4] level [-69][5220]
I/wpa_supplicant( 1149): same security
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.38.D4
I/wpa_supplicant( 1149): same, connected : 9C.44.D4, current : 9C.37.D4
D/PdnController( 1467): Interface Changed wlan0 link up
I/CLocInfoService(  878): External Intent Received android.net.wifi.SCAN_RESULTS
I/CLocInfoCtrl(  878): isWifiMeasurementAvailable
I/CLocInfoCtrl(  878): Last Measure : 201606131211 New : 201606131208
I/CLocInfoCtrl(  878): available result : 32
I/LocationManagerService(  878): remove 13c6ab68 by com.mapzen.erasermap
D/WifiService(  878): releaseWifiLockLocked: WifiLock{NlpWifiLock type=2 binder=android.os.BinderProxy@29a3c0e9}
D/WifiService(  878): New client listening to asynchronous messages
D/LocationManagerService(  878): provider request: network ProviderRequest[ON interval=+24h0m0s0ms]
D/LocationManagerService(  878): provider request: gps ProviderRequest[OFF]
D/Tangram ( 1905): TANGRAM tileWorker.cpp:66: Passed new TileBuilder to TileWorker
D/Tangram ( 1905): TANGRAM tileWorker.cpp:66: Passed new TileBuilder to TileWorker
E/LocSvc_flp(  878): I/===> int flp_inject_location(FlpLocation*) line 222
E/LocSvc_ApiV02(  878): I/<--- void globalRespCb(locClientHandleType, uint32_t, locClientRespIndUnionType, void*) line 125 QMI_LOC_INJECT_POSITION_REQ_V02
D/GpsLocationProvider(  878): setRequest ProviderRequest[OFF]
D/GpsLocationProvider(  878): stopNavigating
E/LocSvc_ApiV02(  878): I/<--- void globalEventCb(locClientHandleType, uint32_t, locClientEventIndUnionType, void*) line 99 QMI_LOC_EVENT_POSITION_REPORT_IND_V02
D/GpsLocationProvider(  878): send an intent to notify that the GPS has been enabled or disabled mNavigating = false
E/ActivityManager(  878): checkUser: useridlist=null, currentuser=0
E/ActivityManager(  878): checkUser: useridlist=null, currentuser=0
E/ActivityManager(  878): checkUser: useridlist=null, currentuser=0
E/ActivityManager(  878): checkUser: useridlist=null, currentuser=0
I/PassiveLocTracker(  878): Location Changed
I/PassiveLocTracker(  878): Send Location
E/Zygote  ( 7200): MountEmulatedStorage()
E/Zygote  ( 7200): v2
D/LightsService(  878): [api] [SvcLED] turnOff:: id = 4 (uid: 1000 pid: 878)
D/LightsService(  878): [SvcLED] setSvcLedStateLocked:: SvcLEDState : 0x0 -> 0x0 | SvcLED(id=4) set Off
I/libpersona( 7200): KNOX_SDCARD checking this for 10118
I/libpersona( 7200): KNOX_SDCARD not a persona
D/LightsService(  878): [SvcLED] Lux failed to be updated in 700ms. -> handleForcedSvcLEDTasK
D/LightsService(  878): [SvcLED]  setSvcLedLightLocked :: Current SvcLED(id=4) maintains its priority right
I/ActivityManager(  878): Start proc com.sec.android.GeoLookout for broadcast com.sec.android.GeoLookout/.location.LocationStateReceiver: pid=7200 uid=10118 gids={50118, 9997, 1028, 1015, 3003} abi=armeabi-v7a
I/GCoreUlr( 2426): Successfully inserted 1 locations
E/LocSvc_ApiV02(  878): I/<--- void globalEventCb(locClientHandleType, uint32_t, locClientEventIndUnionType, void*) line 99 QMI_LOC_EVENT_ENGINE_STATE_IND_V02
V/GpsLocationProvider(  878): reportStatus status: 2
I/PassiveLocTracker(  878): GPS Stopped
I/CLocInfoService(  878): GPS Status : gpsoff
I/CpLocTracker(  878): Mode : 3 Param Data = 0
D/GpsLocationProvider(  878): send an intent to notify GPS has been enabled or disabled mNavigating = false
V/GpsLocationProvider(  878): reportStatus status: 4
I/CpLocTracker(  878): Sent INT Data, mode : 3
I/SELinux ( 7200): Function: selinux_compare_spd_ram, SPD-policy is existed. and_ver=SEPF_SAMSUNG-SM-G900A_5.0 ver=38
I/SELinux ( 7200): Function: selinux_compare_spd_ram , priority [1] , priority version is VE=SEPF_SAMSUNG-SM-G900A_5.0_0038
E/SELinux ( 7200): [DEBUG] get_category: variable seinfo: platform sensitivity: NULL, cateogry: NULL
I/Alfons  ( 1905): LOADED Font: Open Sans Light size: 52
I/CpLocTracker(  878): receive response
D/PersonaManager( 1167): isKioskContainerExistOnDevice
D/PersonaManager( 1167): isKioskContainerExistOnDevice
I/PhoneStatusBar( 1167): Icon Only
D/KeyguardUpdateMonitor( 1167): updateCMASText( show = false )
D/PanelView( 1167): There is/are notification(s)
D/PanelView( 1167): kidsfalse mQsExpansionEnabled:true
D/KeyguardUpdateMonitor( 1167): updateCMASText( show = false )
D/PanelView( 1167): There is/are notification(s)
D/PersonaManager( 1167): isKioskContainerExistOnDevice
I/PhoneStatusBar( 1167): Icon Only
D/KeyguardUpdateMonitor( 1167): updateCMASText( show = false )
D/PanelView( 1167): There is/are notification(s)
D/PanelView( 1167): kidsfalse mQsExpansionEnabled:true
D/KeyguardUpdateMonitor( 1167): updateCMASText( show = false )
I/Alfons  ( 1905): LOADED Font: Open Sans Regular size: 52
D/TimaKeyStoreProvider( 7200): TimaSignature is unavailable
D/ActivityThread( 7200): Added TimaKeyStore provider
D/ResourcesManager( 7200): creating new AssetManager and set to /system/app/GeoLookout/GeoLookout.apk
I/Alfons  ( 1905): LOADED Font: Open Sans Regular size: 40
W/GeoLookout( 7200): H: zOXtzplbN+8pOR8lXMN+zuVFxvDlCo+Yzxg4ugbhd7A04DIT5nFf+o6jguBECoC9dC8nZsnXtcP6wJ/Do8CKbApjnmitl3AiTeKReyJRDttBktCZIh1mNkZuovfXxXoAjd37PhyBM3ng3bcKYjYGOEDyKJaWZrwK1FfNJWfEtzYH8n1Joa422xGgCu3P2tNC0syzQpcTEb6CNvuJmw0Apg==
I/GeoLookout( 7200): H: zOXtzplbN+8pOR8lXMN+zq5rYKS75KQLo4xvOOBhIY6eGw1/GT6WQYb1SRYOugxmkGHzev/Lb2j+GB0+6UGDnw==
D/SettingsProvider(  878): name = safetycare_geolookout_registering
D/SettingsProvider(  878): edmUri: content://com.sec.knox.provider/RestrictionPolicy3
D/SettingsProvider(  878): projectionArgs: isSettingsChangesAllowed
D/SettingsProvider(  878): selectionArgs: false
D/SettingsProvider(  878): selectionArgs: 10118
D/SecContentProvider(  878): uri = 17 selection = isSettingsChangesAllowed
D/SettingsProvider(  878): ret = -1
D/GeoLookout( 7200): H: mmqeDLqBgrS1PY9ZxjAERmjpyYDSyckxRVEBLahXFCCjxEHkYkZuzwjV7ldL9/y2wUiG8ZXusFQQzoKG1FCUjw==
W/GeoLookout( 7200): H: CVccN35zteEo7uWDJ0cWTbsuAnPmDHBG4p+ywI/gN9gYfwXdFmTkL4NvcOBoUQFVCox62sA0xQCRbTYRvR0VNg==
I/Alfons  ( 1905): LOADED Font: Open Sans Semibold size: 40
W/GeoLookout( 7200): H: CVccN35zteEo7uWDJ0cWTbsuAnPmDHBG4p+ywI/gN9gYfwXdFmTkL4NvcOBoUQFVCox62sA0xQCRbTYRvR0VNg==
I/Alfons  ( 1905): LOADED Font: Open Sans Italic size: 40
D/StatusBar.NetworkController( 1167): refreshSignalCluster - setNWBoosterIndicators(false)
D/StatusBar.NetworkController( 1167): applyOpen
D/StatusBar.NetworkController( 1167): refreshSignalCluster - setNWBoosterIndicators(false)
D/StatusBar.NetworkController( 1167): applyOpen
D/StatusBar.NetworkController( 1167): refreshSignalCluster - setNWBoosterIndicators(false)
D/StatusBar.NetworkController( 1167): applyOpen
D/StatusBar.NetworkController( 1167): refreshSignalCluster - setNWBoosterIndicators(false)
D/StatusBar.NetworkController( 1167): applyOpen
E/SMD     (  286): DCD ON
D/SecContentProvider2(  878): uri = 14 selection = getSealedState
D/SecContentProvider2(  878): mCursor = null
D/SecContentProvider2(  878): KnoxCustomManagerService offline: service is not available
D/RouteEngineListener( 1905): [onRouteStart]
D/WindowManager(  878): showStatusBarByNotification() mOpenByNotification=false
W/NotificationService(  878): Pray mode not found android.content.pm.PackageManager$NameNotFoundException: Application package com.sec.android.settings.praymodewidget not found
D/SecContentProvider2(  878): uri = 14 selection = getSealedState
D/SecContentProvider2(  878): mCursor = null
D/SecContentProvider2(  878): KnoxCustomManagerService offline: service is not available
D/ConnectivityService(  878): returning getActiveNetworkInfo :[type: WIFI[] - WIFI, state: CONNECTED/CONNECTED, reason: (unspecified), extra: "Accelerator", roaming: false, failover: false, isAvailable: true, isConnectedToProvisioningNetwork: false]
D/Speakerbox( 1905): Playing: "Drive southeast on West 26th Street for 100 meters."
W/NotificationService(  878): Pray mode not found android.content.pm.PackageManager$NameNotFoundException: Application package com.sec.android.settings.praymodewidget not found
V/AudioPolicyManager( 4865): getOutput() device 2, stream 3, samplingRate 0, format 0, channelMask 0, flags 3
V/AudioPolicyManager( 4865): getOutputsForDevice device 0002 -> 0002
V/AudioPolicyManager( 4865): getOutput() returns output 2
V/AudioPolicyManager( 4865): getOutput() device 2, stream 3, samplingRate 0, format 0, channelMask 0, flags 3
V/AudioPolicyManager( 4865): getOutputsForDevice device 0002 -> 0002
V/AudioPolicyManager( 4865): getOutput() returns output 2
V/AudioPolicyManager( 4865): getOutput() device 2, stream 3, samplingRate 0, format 0, channelMask 0, flags 3
V/AudioPolicyManager( 4865): getOutputsForDevice device 0002 -> 0002
V/AudioPolicyManager( 4865): getOutput() returns output 2
V/AudioPolicyManager( 4865): getOutputForAttr() usage=1, content=1, tag= flags=00000000
V/AudioPolicyManager( 4865): getOutputForAttr() device 2, samplingRate 22050, format 1, channelMask 1, flags 0
V/AudioPolicyManager( 4865): getOutputsForDevice device 0002 -> 0002
V/AudioPolicyManager( 4865): getOutput() returns output 2
D/ConnectivityService(  878): returning getActiveNetworkInfo :[type: WIFI[] - WIFI, state: CONNECTED/CONNECTED, reason: (unspecified), extra: "Accelerator", roaming: false, failover: false, isAvailable: true, isConnectedToProvisioningNetwork: false]
D/LocationManagerService(  878): request 1f5254df gps Request[ACCURACY_FINE gps requested=+1s0ms fastest=+1s0ms] from com.mapzen.erasermap(11694)
D/LocationManagerService(  878): provider request: gps ProviderRequest[ON interval=+1s0ms]
D/GpsLocationProvider(  878): setRequest ProviderRequest[ON interval=+1s0ms]
D/LocationManagerService(  878): request 1f5254df network Request[POWER_LOW network requested=+1s0ms fastest=+1s0ms] from com.mapzen.erasermap(11694)
D/LocationManagerService(  878): provider request: network ProviderRequest[ON interval=+1s0ms]
D/GpsLocationProvider(  878): startNavigating, singleShot is false
I/Choreographer( 1905): Skipped 83 frames!  The application may be doing too much work on its main thread.
D/GpsLocationProvider_ex(  878): Data state true
D/GpsLocationProvider_ex(  878): getSKAFEnable : false
D/GpsLocationProvider(  878): setting position_mode to MS_BASED
E/        (  878): E/open failed: /dev/mdm: No such file or directory
E/LocSvc_utils_cfg(  878): W/loc_read_sec_gps_conf: no secgps conf file, using defaults
D/KnoxNotification( 1167): ----- inflateViews : modified publicViewLocal -----
D/PowerManagerService(  878): [api] acquire WakeLock flags=0x2000000a tag=WindowManager uid=1000 pid=878
E/LocSvc_ApiV02(  878): I/virtual loc_api_adapter_err LocApiV02::startFix(const LocPosMode&):427]: position_mode=1.
E/LocSvc_ApiV02(  878): I/<--- void globalRespCb(locClientHandleType, uint32_t, locClientRespIndUnionType, void*) line 125 QMI_LOC_SET_OPERATION_MODE_REQ_V02
E/LocSvc_ApiV02(  878): E/virtual loc_api_adapter_err LocApiV02::startFix(const LocPosMode&):509]:start_mode = not standalone, acc will set as eQMI_LOC_ACCURACY_MED_V02
D/KnoxNotification( 1167): ----- inflateViews : modified KnoxViewLocal -----
D/PersonaManager( 1167): PersonaID is invalid or persona doesn't exists. : 0
D/AndroidRuntime( 1905): Shutting down VM
D/PhoneStatusBar( 1167): tick(): knoxCustomManager = android.app.enterprise.knoxcustom.KnoxCustomManager@2da46586
D/PersonaManager( 1167): isKioskContainerExistOnDevice
D/PersonaManager( 1167): isKioskContainerExistOnDevice
I/PhoneStatusBar( 1167): Icon Only
E/AndroidRuntime( 1905): FATAL EXCEPTION: main
E/AndroidRuntime( 1905): Process: com.mapzen.erasermap, PID: 1905
E/AndroidRuntime( 1905): java.lang.NullPointerException: Attempt to invoke interface method 'java.util.Iterator java.util.List.iterator()' on a null object reference
E/AndroidRuntime( 1905):    at com.mapzen.android.lost.internal.FusedLocationProviderApiImpl.reportLocation(FusedLocationProviderApiImpl.java:114)
E/AndroidRuntime( 1905):    at com.mapzen.android.lost.internal.FusionEngine.onLocationChanged(FusionEngine.java:139)
E/AndroidRuntime( 1905):    at android.location.LocationManager$ListenerTransport._handleMessage(LocationManager.java:281)
E/AndroidRuntime( 1905):    at android.location.LocationManager$ListenerTransport.access$000(LocationManager.java:210)
E/AndroidRuntime( 1905):    at android.location.LocationManager$ListenerTransport$1.handleMessage(LocationManager.java:226)
E/AndroidRuntime( 1905):    at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime( 1905):    at android.os.Looper.loop(Looper.java:145)
E/AndroidRuntime( 1905):    at android.app.ActivityThread.main(ActivityThread.java:5835)
E/AndroidRuntime( 1905):    at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 1905):    at java.lang.reflect.Method.invoke(Method.java:372)
E/AndroidRuntime( 1905):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
E/AndroidRuntime( 1905):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)

Routing Instructions sent before runtime exception occured:

D/Retrofit( 1905): ---> HTTP GET https://valhalla.mapzen.com/route?json=%7B%22costing%22%3A%22auto%22%2C%22directions_options%22%3A%7B%22units%22%3A%22kilometers%22%7D%2C%22locations%22%3A%5B%7B%22heading%22%3A%220%22%2C%22lat%22%3A%2240.7445966%22%2C%22lon%22%3A%22-73.9902155%22%7D%2C%7B%22city%22%3A%22%22%2C%22lat%22%3A%2240.74387576701398%22%2C%22lon%22%3A%22-73.9888620895245%22%2C%22state%22%3A%22New+York%22%2C%22street%22%3A%22Starbucks%22%7D%5D%7D&api_key=valhalla-JZUU9ZS
D/Retrofit( 1905): DNT: 1
D/Retrofit( 1905): ---> END HTTP (no body)
D/Retrofit( 1905): <--- HTTP 200 https://valhalla.mapzen.com/route?json=%7B%22costing%22%3A%22auto%22%2C%22directions_options%22%3A%7B%22units%22%3A%22kilometers%22%7D%2C%22locations%22%3A%5B%7B%22heading%22%3A%220%22%2C%22lat%22%3A%2240.7445966%22%2C%22lon%22%3A%22-73.9902155%22%7D%2C%7B%22city%22%3A%22%22%2C%22lat%22%3A%2240.74387576701398%22%2C%22lon%22%3A%22-73.9888620895245%22%2C%22state%22%3A%22New+York%22%2C%22street%22%3A%22Starbucks%22%7D%5D%7D&api_key=valhalla-JZUU9ZS (263ms)
D/Retrofit( 1905): access-control-allow-origin: *
D/Retrofit( 1905): Content-Type: application/json;charset=utf-8
D/Retrofit( 1905): Date: Mon, 13 Jun 2016 16:08:44 GMT
D/Retrofit( 1905): Server: nginx/1.4.6 (Ubuntu)
D/Retrofit( 1905): X-ApiaxleProxy-Qpd-Left: 49951
D/Retrofit( 1905): X-ApiaxleProxy-Qps-Left: 1
D/Retrofit( 1905): Connection: keep-alive
D/Retrofit( 1905): OkHttp-Selected-Protocol: http/1.1
D/Retrofit( 1905): OkHttp-Sent-Millis: 1465834125118
D/Retrofit( 1905): OkHttp-Received-Millis: 1465834125373
D/Retrofit( 1905): {"trip":{"language":"en-US","summary":{"length":1.037,"time":187},"locations":[{"type":"break","side_of_street":"left","lat":40.744598,"lon":-73.990219,"heading":0},{"state":"New York","type":"break","side_of_street":"left","lat":40.743877,"lon":-73.988861,"street":"Starbucks"}],"units":"kilometers","legs":[{"shape":"{xyulAzj_clCd_@wkAjAwD~C\\dd@tE`D^mAtDwWp{@eP`g@eZz~@ke@s[{e@c[ke@c[|m@qnB~m@pGpf@rF","summary":{"length":1.037,"time":187},"maneuvers":[{"travel_mode":"drive","begin_shape_index":0,"length":0.126,"time":12,"type":3,"end_shape_index":2,"instruction":"Drive southeast on West 26th Street.","verbal_pre_transition_instruction":"Drive southeast on West 26th Street for 100 meters.","travel_type":"car","street_names":["West 26th Street"]},{"travel_type":"car","travel_mode":"drive","verbal_multi_cue":true,"verbal_pre_transition_instruction":"Turn right onto Broadway. Then Turn right onto West 25th Street.","verbal_transition_alert_instruction":"Turn right onto Broadway.","length":0.085,"instruction":"Turn right onto Broadway.","end_shape_index":5,"type":10,"time":31,"verbal_post_transition_instruction":"Continue for 90 meters.","street_names":["Broadway"],"begin_shape_index":2},{"travel_type":"car","travel_mode":"drive","verbal_pre_transition_instruction":"Turn right onto West 25th Street.","verbal_transition_alert_instruction":"Turn right onto West 25th Street.","length":0.263,"instruction":"Turn right onto West 25th Street.","end_shape_index":9,"type":10,"time":49,"verbal_post_transition_instruction":"Continue for 300 meters.","street_names":["West 25th Street"],"begin_shape_index":5},{"travel_type":"car","travel_mode":"drive","verbal_pre_transition_instruction":"Turn right onto 6th Avenue, Avenue of the Americas.","verbal_transition_alert_instruction":"Turn right onto 6th Avenue.","length":0.236,"instruction":"Turn right onto 6th Avenue\/Avenue of the Americas.","end_shape_index":12,"type":10,"time":39,"verbal_post_transition_instruction":"Continue for 200 meters.","street_names":["6th Avenue","Avenue of the Americas"],"begin_shape_index":9},{"travel_type":"car","travel_mode":"drive","verbal_pre_transition_instruction":"Turn right onto West 28th Street.","verbal_transition_alert_instruction":"Turn right onto West 28th Street.","length":0.172,"instruction":"Turn right onto West 28th Street.","end_shape_index":13,"type":10,"time":20,"verbal_post_transition_instruction":"Continue for 200 meters.","street_names":["West 28th Street"],"begin_shape_index":12},{"travel_type":"car","travel_mode":"drive","verbal_pre_transition_instruction":"Turn right onto Broadway.","verbal_transition_alert_instruction":"Turn right onto Broadway.","length":0.155,"instruction":"Turn right onto Broadway.","end_shape_index":15,"type":10,"time":36,"verbal_post_transition_instruction":"Continue for 200 meters.","street_names":["Broadway"],"begin_shape_index":13},{"travel_type":"car","travel_mode":"drive","begin_shape_index":15,"time":0,"type":6,"end_shape_index":15,"instruction":"Starbucks is on the left.","length":0.000,"verbal_transition_alert_instruction":"Starbucks will be on the left.","verbal_pre_transition_instruction":"Starbucks is on the left."}]}],"status_message":"Found route between points","status":0}}
D/Retrofit( 1905): <--- END HTTP (3251-byte body)
E/LocSvc_ApiV02(  878): I/<--- void globalEventCb(locClientHandleType, uint32_t, locClientEventIndUnionType, void*) line 99 QMI_LOC_EVENT_GNSS_SV_INFO_IND_V02
I/PassiveLocTracker(  878): GPS Satllite Status
D/GpsLocationProvider_ex(  878): SV Count : 2      (PRN, SNR, Elevation, Azimuth, Used)
D/GpsLocationProvider_ex(  878): (16, 15.2, 43.0, 52.0, 0) (86, 18.5, 33.0, 36.0, 0)
W/View    ( 1905): requestLayout() improperly called by android.support.v7.widget.AppCompatTextView{3b4a13f7 V.ED..C. ......I. 48,1588-318,1629 #7f0e005c app:id/mz_attribution} during layout: running second layout pass
W/View    ( 1905): requestLayout() improperly called by android.support.v7.widget.AppCompatImageButton{38a9f264 VFED..C. ......I. 900,1497-1032,1629 #7f0e005b app:id/mz_find_me} during layout: running second layout pass
W/View    ( 1905): requestLayout() improperly called by android.support.v7.widget.AppCompatTextView{3b4a13f7 V.ED..C. ......ID 48,1257-318,1298 #7f0e005c app:id/mz_attribution} during layout: running second layout pass
W/View    ( 1905): requestLayout() improperly called by android.support.v7.widget.AppCompatImageButton{38a9f264 VFED..C. ......ID 900,1166-1032,1298 #7f0e005b app:id/mz_find_me} during layout: running second layout pass
D/Tangram ( 1905): TANGRAM tangram.cpp:154: resize: 1080 x 1845

Add support for compass sensor

I think a nice improvement over Google Play would be to add the ability to get compass sensor direction.

Currently this requires a lot of boilerplate code and filtering code to get a usable direction from the Android sensor APIs.

It would be great if LOST implemented this into an easy to use API integrated with the existing location updates with a flag during initialisation to enable it.

Also some good heuristics about when to use GPS derived direction or compass direction would be needed. Perhaps using current speed or some other factors.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.