react-native-background-geolocation
react-native-background-geolocation copied to clipboard
When mobile is locked in background/kill-mode, not getting location updates in Samsung M30S
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.
The first step for these type of issues is to visit http://dontkillmyapp.com
Also see wiki Debugging and learn to observe the plug-in’s logs.
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.
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