Contributions: Sarthak Shah, Samarth Singh, Prajjwal Pandey, Deepak Reddy Nayani, Shashank Shivarasi
The GuardianAngelTeenApp is an Android application designed to empower parents with a versatile tool to ensure the safety and well-being of their teenage children. This app introduces a range of essential features to help parents stay informed and take proactive measures when needed. These functionalities encompass Speed Monitoring, Geofencing, Fall Detection, and Health Vitals Monitoring. Additionally, the app includes an SOS button for immediate emergency communication and live location sharing to keep parents updated on their child's whereabouts.
To run the GuardianAngelTeenApp Android application, follow these steps:
-
Clone the project repository from https://github.com/Samarth66/guardianTeenApp.git
-
Open the project using Android Studio.
-
Build and launch the application either on an Android emulator or a physical Android device.
-
Grant the necessary permissions, specially Notification permissions to test notifications
-
Ensure that you check the following functionalities:
- Logging in and signing up to enable communication.
- Adding a childId in parent screen
- Sending alerts SOS, Health Vital Check, Fall Detection, Set Geofence, Overspeeding.
- Sending alert from parent device to child device by clicking health vital check button.
The backend of this project is already deployed on https://render.com). You can directly install the app using above instructions and test the endpoints using the app. However, if you want to deploy the backend code on your own laptop locally, follow these steps:
- Clone the repository.
- Open the project in Visual Studio.
- Navigate to the server folder.
- Run
npm installto install all dependencies. - Execute
node appornode app.jsto start the backend server.
To update the Android frontend with the new API endpoints, follow these steps:
-
Replace all instances of the following example format API endpoint:
https://guardianteenbackend.onrender.com/signup
with:
http://192.168.0.95:5001/login(Replace the middle part with your IPv4 address, which can be found by runningipconfig)
This will ensure that all requests are received on your laptop.
Make these endpoint updates in the following locations within the Android app:
https://guardianteenbackend.onrender.com/login(Present inloginActivity)https://guardianteenbackend.onrender.com/updateDeviceToken(Present inloginActivity)https://guardianteenbackend.onrender.com/create(Present inchildActivity)https://guardianteenbackend.onrender.com/health-alert(InParentActivity)https://guardianteenbackend.onrender.com/fetch-alerts?pid=$parentId(Present inparentActivity)https://guardianteenbackend.onrender.com/add_child(Present inparentActivity)https://guardianteenbackend.onrender.com/signup(Present insignupActivity)
#NOTE : If you are running the app the first time round, on initial sign-in it will say network error, keep trying, it will log-in in under 2-3 minutes (apologies for the inconvenience)
The guardianTeenApp consists of several key components:
-
ChildScreenActivity: Responsible for monitoring the child's speed and health vitals. It utilizes GPS technology to track speed and mobile sensors for health monitoring.
-
HealthRateCalculator: This class calculates health data, including heart rate and respiratory rate. It uses data from the device's camera to calculate heart rate and accelerometer data for respiratory rate.
-
HealthDataRepository: Manages the storage and retrieval of health data, including heart rate and respiratory rate.
-
ChildScreenActivity: Implemented the features for free fall detection and SOS emergency button with optional video recording
-
SOS Alert: Sends an alert to the respective parent as type "SOS", and allows the child to record a 30 second video in case of emergencies
-
Fall Detection: Uses the device accelerometer to detect free falls using a threshold value (computed through trial and error) and sends a notification alert to the respective parent.
-
AlertFunction and VibrateFunction: These components are responsible for triggering alerts and vibrations in predefined scenarios, ensuring prompt communication during emergencies.
-
Make sure your Android development environment is set up correctly with the required SDK and dependencies.
-
The application may require additional setup, such as API key configurations or device permissions, depending on the development environment and target Android version.
-
This README provides a high-level overview of the project and basic execution instructions. Detailed documentation, including code structure, architecture, and usage guidelines, can be found within the project source code and associated documentation files.
Thank you for using guardianAngelTeen App, and we hope this application enhances the safety and well-being of your teenage children.