Keywords

1 Introduction

In the 21stcentury, India has been labelled as one of the most unsafe places to live in for women and children. Throughout the two decades, we saw so many movements that empowered women, change in laws that should have instilled fear among the men. This means that not only do women require extra safety, but the oppressors who are 99.9% of the time men, need to be shown their place by bringing their patriarchal and animalistic ego down. Our project thrives on this major motivation to instill fear among the men who have been oppressing and committing heinous crimes for years, so that they wouldn’t even think to commit one and to supply such a safety system for women that will not only keep them away at risk, but also give them the bravery and upper hand to defend themselves in case of aggressive advancements by the assault. This can be fit in a handbag for women who are travelling. The Raspberry Pi also works with a powerful GPS GSM Module, that will effectively track the location of the person in trouble and send their location via a help message on Telegram, E-Mail and WhatsApp of the emergency contacts or police so that they can arrive to their help seeing the GPS coordinates along with its Google Map marker location. Meanwhile, the victim in trouble can make use of two self-defense mechanisms and flee from the location until help arrives. Not only is safety prioritized, but the entire evidence in the form of image detected and video captured by the Raspberry Pi will safely be backed up to a storage spot such as Database, Google Drive or Cloud which can be accessed later for verifying.

2 Literature Review

Bharathwaj [1] has proposed a method to get the location of the police station which is situated the nearest to the victim and alert them through a message when the women/victim is in shear distress, there are some flaws which needs to be clear, though this gets the location of the police station which is near to the victim there will be a minimum amount of delay that is occurring due to the official themselves. Viswanath [2] had built a device so compact that it can be worn on the feet of the victim which consists of a light blue bean microcontroller, when the sound is measured by the sensor about 4–5 times and conveys the message through message or email. In this paper, it was mentioned that the speed of the light blue bean is minimum. Monisha [3] had built a device using buttons for meeting the emergency by single/double pressing the buttons while, pressing the buttons during such situation is not at all possible.

VamsiPriya [4] had built a portable device and a professionally written code for the entire project that made Code readable and more professional on the contrary, the microcontroller chosen for the same is very primitive one that is the Arduino Uno that can’t do multitasking and the range of the same is mentioned to be 10 m that is very less. Rasool [5] was able to successfully implement a lot of test case real world situation with one single written Program. Also, they made use of common household bat as a self-defense mechanism but, the major disadvantage of the developed system is it leads to confusion when the person is severely suffering from a health issue and it has been explicitly mentioned that the circuitry is affected by weather. Krishnamurthy [6] had achieved in obtaining the GPS coordinates dynamically and updating the same every 30secs and it will be sent to the emergency helper numbers. Even if the women are safe, the device will be active state and conveys a false message to the registered helper which may lead to waste of time etc. and this whole thing fails if the device goes into aero plane mode or into a network less area.

Prashanth [7] developed an application with particular features for security and authentication purpose. The person will get access to it only if he is authenticated, he can use the app. Even though, it is a security application providing their credentials and authenticating will be tough at a distress situation. Mehta [8] built a device which upon shaking the device gets activated and the location is sent to register emergency contacts. The major flaw in this system is that it may lead to confusion when mobile trembles accidently. Verma [9] developed a device for tracking the pulse rate and the temperature of the body. If the sensor reading is in abnormal state, then it automatically sends a location police station. To protect themselves the person must press a buzzer and the location is sent to their contacts. The fact to be noted in the paper is only the people who are close to the victim can help the affected person.

Dandamudi [10] developed a CNN based system aerial image processing which classifies if the women are in distress or not and creates an alert message. The main disadvantage of the system this is very difficult to be employed in everyday life and it may lead to very costly livelihood. Ravisankar [11] built an Android based security and tracking system for children which involves having a mobile phone and an app has been developed to send messages and email to the helper but it is not possible to have mobile phone in every situation. Mohan [12] had developed a wearable gadget which track the location and sends to the helper but it has no other feature and the feature of instant recovery has not been planned. [13] and [14] gives a general idea on what women are facing these days and how the problem can be solved using IoT and provides a wide range of ideas and facts on the problem and an IoT solution for the same.

3 Hardware Components

The device is designed in a way that, when the button is pressed by the user, it would track the location where the system is located and would also capture the face of the person, who is assaulting detects their gender, save it as a video and is uploaded to GDrive. The location tracked is been sent to the user’s family/friends through telegram and Gmail. When the receiver wants to get location again after sometimes, he/she can send a specific keyword, so that the device can track the new location and send it again. The main hardware components used here are Raspberry Pi a GPS module, a camera module [15, 16].

3.1 Raspberry Pi and GPS Module

Raspberry Pi is a device which is like a mini computer with high computational capability. The main reason we need to use raspberry pi is because of the high computational need when using programs for face detection, gender detection and so on. The Python 3 programming language is used to code the program for this project. The GPS module is a module which uses Global Positioning Satellite to get the location of the device and sends many data such as the latitude, the longitude, timestamp of the satellite and few more data of the location where the device is present. In this project we require only latitude and longitude coordinates of the device, which is depicted in Figs. 1 and 2.

Fig. 1
A device like mini computer, called raspberry p i.

Raspberry Pi

Fig. 2
A G P S or G S M module, to detect location of devices.

GPS/GSM module

3.2 Camera Module and 555 Timer Based Buzzer System

The camera module is a module which is used to attach an external camera to the device. In this project the camera module is attached to raspberry pi and is placed in a location such that the camera is hidden and can capture the face of the assaulter. The camera module is used to get the face of the assaulter. This helps the victim to alert for help from nearby people is designed. This circuit consists of set and reset buttons, in which once the reset button is pressed the circuit becomes inactive, then once the set button is pressed, it becomes active by ringing the buzzer. The camera module and timer circuit are represented in Figs. 3 and 4.

Fig. 3
A chip with camera on it, attached to raspberry pi.

Camera module

Fig. 4.
A breadboard with a small battery and an electronic buzzer. Breadboard has connection of colorful wires and a transistor on it.

555 timer circuit

3.3 Shock Circuit

This is for the self-defense of the victim before the help arrives which is very much necessary for the victim to survive. This circuit consists of a push button which once pressed, makes contact with the battery, thus charging the circuit. Once the shock circuit is done, it gets discharged and once again the button needs to be pressed to generate shock. In the circuit shown below, the circuit becomes complex if implemented on breadboard so we have soldered it together as shown in Fig. 5.

Fig. 5
A chip have battery, capacitors, transistors, and colorful wires attached to it, makes a complete circuit.

Shock circuit

4 Software Algorithm

The main program of this project involves many fractions, in which each function performs a specific task. These specific tasks are: Location detector, Sending the location through telegram and mail, getting image from camera and detecting the face from it and saving it, detecting gender from the image saved, Uploading the continuously saved image as video to the cloud, Multitasking/multithreading to perform two tasks separately at the same time. The two tasks are: Finding and sending location, detecting face and saving it in cloud.

4.1 Location Detector

Serial, time, string, pynmea2 are the functions imported for this program into the raspberry pi. “Serial”. The location tracking is started with the code “dataout = pynmea2. NMEAStreamReader” And the data is uploaded with the code “newmsg = pynmea2. “

4.2 Sending Message

The message is sent through both mail and telegram.  The message should contain “https://www.google.com/maps/#latitude,#longitude,14z”, where latitude and longitude coordinates are entered in place of #latitude# and #longitude. “Send_message.”.#text# is the message which is send.

4.3 Detecting Face

For detecting the face, OpenCV is mainly imported. Numpy is also imported for the program. The file “haarcascade_frontalface_default.xml” is downloaded and is imported to this program. With the function “cap = cv2.Video Capture (0)” The camera module is accessed and the image is captured. The image is converted into grayscale with the code “gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)”. The image is converted into grayscale so that the face can be detected easily than having colored images. With the function “faceCascade.detectMultiScale()”, the presence of face is detected and its coordinates in the image is marked and is saved as a video.

4.4 Saving in Cloud

Creating a backup storage forum in Google Drive, Cloud or Database for the image detected and video captured, in order to show evidence. One of the main aspects of this project comes down to providing evidence of the attacker’s presence or actions. For this purpose, the video captured and face detected by the Raspberry Pi, has to be stored in a safe place like a Database, Cloud or Google Drive. This can be accessed later by uploading the video and image directly to Google Drive using Python. The essentials for this are: Creating an OAuth Client ID and Secret Key along with an authorized URI using one’s google account, storing the key in the same directory as the python program, installing Pydrive package for connection to Google Drive.

4.5 Multitasking/Multithreading

When each task is within the same program and is done at the same time, then this type of multitasking is called multithreading. #FunctionName# is the name of the function which is processed separately aside from main program. Note that the main program is also a separate process which is independent of the newly created thread.

5 Experimental Results

When the push button is pressed the entire program gets implemented. When the program runs, the GPS/GSM will work simultaneously to gather the location and a google map link will be sent to the mail of the contacts registered by the user. If the helper doesn’t have a Gmail account to receive mail, the same can be obtained by the Telegram bot that we have built. The results are shown in Figs. 6, 7, 8, and 9.

Fig. 6
A screenshot of 2 telegram messages of March 30. Forward slash start has a reply that has a link of place, Sowdeswari nagar, Neelikonampalayam, Coimbatore, Tamil Nadu, India.

Telegram message

Fig. 7
A screenshot of google maps highlights 11.024700, 76.988998.

Google map

Fig. 8
A screenshot of computer screen of databases. It has 6 sub-headers. Structure, data divided into grid view, and form view, contracts, indoors, triggers, and D O L.

Database for storing the received data

Fig. 9
Two screenshots of web pages titled results and authentication done. The left page is of the google drive before uploading. The right page is of the new files added after authentication.

Uploading files to Google Drive

6 Conclusion

Our women safety system aims to supply maximum support to the victim in the panic situation. Our shock gun system will help the victim in serving until the help arrives. The GPS system helps in sharing the location coordinates which makes up the main aim of this project. Unlike other similar works, we derive the GPS coordinates and display it on google maps. Buzzer system, camera model with drive backup are handy add ones to our project. With the technology growing every day there is a lot of future scope for this project to even reduce the time gap for the help to come. The implementation of individual circuits is big, because of which encapsulation of the entire circuit and making them into one small sized circuit is tedious. The programming is multi-fold and complex because of the usage of multiple concepts which needed different syntaxes. Unpredictable weather conditions might affect the circuitry. The Shock Circuit has a disadvantage that the law doesn’t legally allow its output voltage and licensing for a Stun Gun. In future work, with the help of VLSI technology, the circuits can be made much smaller and easily portable as a wearable device. Even though this project offers a good mechanism for safety and self-defense, the moral compass of the assaulter cannot be predicted. There are many possible situations of behavior of an assaulter, which must be taken in consideration for further development and to ensure 100% security. Further, this can also lead to creation of an interactive application on the mobile phone which will send help from the nearest police station to the women in trouble.