react-native-background-geolocation icon indicating copy to clipboard operation
react-native-background-geolocation copied to clipboard

When mobile is locked in background/kill-mode, not getting location updates in Samsung M30S

Open PrasadFeker opened this issue 3 years ago • 4 comments

Your Environment

  • Plugin version:4.4.6
  • Platform: Android
  • OS version: 11
  • Device manufacturer / model: Samsung M30s
  • React Native version (react-native -v):0.63.2
  • Plugin config

BackgroundGeolocation.ready({
      desiredAccuracy: BackgroundGeolocation.DESIRED_ACCURACY_HIGH,
      distanceFilter: 0,
      stopOnTerminate: false,
      startOnBoot: true,
      enableHeadless: true,
      // debug: true,
      fastestLocationUpdateInterval: 5000,
      foregroundService: true,
    }).then((state) => {
      if (!state.enabled) {
        if (Platform.OS === 'android') {
          //   ToastAndroid.show('calledd', ToastAndroid.SHORT);
        } else {
          console.log('IOS', 'shshjs');
          //  Alert.alert('ashbdhas', 'sd');
        }

        BackgroundGeolocation.start();
      }
    });
    

Expected Behavior

Should get location updates for every 5 seconds in foreground, background and kill-mode.

Actual Behavior

When mobile screen is locked and application is in background/kill-mode, we are unable to get location updates.

PrasadFeker avatar May 10 '22 12:05 PrasadFeker

The first step for these type of issues is to visit http://dontkillmyapp.com

christocracy avatar May 10 '22 12:05 christocracy

Also see wiki Debugging and learn to observe the plug-in’s logs.

christocracy avatar May 10 '22 12:05 christocracy

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. You may also mark this issue as a "discussion" and I will leave this open.

stale[bot] avatar Sep 21 '22 03:09 stale[bot]

The first step for these type of issues is to visit http://dontkillmyapp.com

I have followed these steps but , still getting this issue , Not getting location when device screen is lock

GurjeetLamba avatar Jun 24 '23 21:06 GurjeetLamba