Open niccs opened 8 years ago
@jmatsushita,
Existing flow:-- AlarmManager is scheduled to be fired every 5 mins or alert delay time which is set by the user in Alert setting screen.
There are two options:--
Option 1--
Location updates are done independent of distance moved and is requested every 1 min. We can request location updates adding minimum distance moved parameter also-- which means if there is a change in location coordinates by say 50 mt( in addition to 1 min settings) then only update the location.
So once there is a location change as explained above, then only we can trigger panic sms. It can be more than one sms per minute also, in case user travels more distance than 50 mt,
In this case no need of repeated alarm which is based on intervals(5 mins). and we can remove Alaram Manager and base the trigger code on loactionupdate reciever.
Option 2 --
Suppose user selects 5 mins. so sms is sent every 5 mins. and if location is not changed by say 50 mt even after 5 mins, the new SMS is not triggered.
In this case, Both alarm manager and Location receiver will work together.
Let me know your view points on same.
Do not send alert, if location is not changed.