Ionic Safety Feature


#1

I’m quite stumped on this feature and I wanted to see if I could get some feedback on where to start.

The idea for this app feature is to detect whether a person is using their smartphone while walking. So if the phone is unlocked, which might mean that they are using and looking at their phone, and it detects that the person is moving the app should alert the person and remind them to not walk distracted. Would appreciate the input.


#2

use device motion plugin http://ngcordova.com/docs/plugins/deviceMotion/ and try to get the data. This type of functionality will be possible only with some plugin apart from the device motion plugin.

To check the face, you need access to the camera and with the current camera plugin, the camera opens, so you need to have some plugin developed by a native developer.


#3

Thanks for your answer. I wont need to check the face I will just assume that if the phone is unlocked that they are using it. The question is do I have that function to check if the phone is unlocked?


#4

if they are using your app, then you can check for events. But if you want that your app is in background and detecting the usage, you would have to get some custom plugin made.