Professional Documents
Culture Documents
Supervisor:
Submitted by:
Session:
BSCS (Morning)
Roll No. IU15M2ba013
Session 2015-19
Table of Contents
Chapter 1. INTRODUCTION
1.1 Purpose
1.2 Scope
4.1 Overview of UI
4.5 Testing
3
Chapter 1. Introduction
Virtual Driver Assistant is an Android application which can help the driver during driving
in different perspectives. To enjoy the features of this app, the user will have to sign in
4
using his mobile number or Gmail address. The driver can check the moving speed of
the vehicle during driving. The user can calculate the distance between two points and
an average time will also be provided to cover the measured distance. Aside from this,
the app will use the camera to recognize and predict the traffic light indication. The user
can share his current real-time location with others through SMS using the mobile
number. A brief guide about traffic signs has also been provided in the ap, which will
help the driver to learn about traffic light signals and signboards.
1.1 Purpose:
In this document, we describe the software requirements for a yet unnamed mobile
application, further referred to as Virtual Driver Assistant, an android application. It will
explain the purpose and features of the system, interfaces of the system, what will the
system do, the constraints under which it must operate and how the system will react to
external stimuli. This document is primarily intended to be proposed to a customer or
supervisor (in my case) for its approval and a reference for developing the first version
of the system for the development team.
1.2 Scope:
This software system will be an android application for anyone who wants to use the
Virtual Driver Assistant APP in their daily life or for any other purpose.
The system will be designed to help the user to
Detect traffic light signal using image processing.
Specific traffic Signs boards detection using image processing.
Provide voice instructions on detection of traffic signs.
Provide voice instructions on detection of traffic signals.
Provide speed of the vehicle
Provide how much is traffic flow through the map on the road.
Provide calculation of the distance from one point to another.
Search the other users of the app in the same area.
Share the live location of the app with other apps.
Make the history of assistant either save in DB or not.
Provide documentation on the guide of Traffic signs.
Provide documentation on the guide of Traffic rules.
The user interface of the system is to be written or created in XML while backend
programming will be implemented in Java for Android. Further, I will use SQLite for the
local database and Firebase for cloud storage if it requires.
Image processing will be used for the detection of objects through the camera. I will use
google maps for calculating speed by dividing the covered distance over time. The last
but not least, Google Maps API and GPS will be used for location manipulation.
Terms Definitions
Stakeholder Any person who has interaction with the system who is not a
developer.
AI Artificial Intelligence.
Firebase Google’s API for storing & retrieving data on/from the cloud.
TL Traffic Lights
TS Traffic Signs
6
Open-source software Software for which the code is freely available for use and
research
UI User Interface
1.5 References
the chapter also mentions the system constraints and assumptions about the product.
It also provides the requirements specification in detailed terms and a description of the
different system interfaces, functional and nonfunctional requirements, logical database
requirements and design constraints. Different specification techniques are used in
order to specify the requirements more precisely for different stakeholders. In the end, It
deals with the prioritization of the requirements. It includes motivation for the chosen
prioritization methods and Analysis models including data flow, sequence and state
transition diagram. The third chapter will explain design and system architecture. The
actual implementation of the project will be provided in the fourth chapter.
The main goal of the project is to create a virtual driver assistant for the stakeholder.
The final product of the VDA project will be a mobile platform for Android mobile phones
or tablet systems that will enable third-party mobile application developers to easily
develop Android-based collection applications by utilizing the common Android services.
The VDA project will be an android application that is designed for users who want to
need help or assistance during driving. This project gives the user to an application
interface, by using this user can open camera of the application.
The system will capture images and process them with Image Processing techniques to
detect traffic light signals and traffic signs. Firebase machine learning kit will be used to
process the image and give predictions. If the system gets it, it will give instructions to
the user or more specifically to the driver using the voice. In this way, the driver will be
aware of each sign board or signal that will have passed.
The system is divided into three parts: one is providing assistant through image
processing, the second is providing assistant without image processing and the third
part will provide documentation to stakeholders for learning about traffic rules or all the
stuff is needed for traffic guidance. Two parts are shown in the figure:
8
In the first part, the system will be required to detect the traffic lights and signals
through camera using image processing.
In the second part, the system will have to do a lot of work. The system will be able to
give the user the distance between two points. Such means that system will use GPS to
calculate the distance between one place to another place which stakeholder selects.
Let’s talk about saving the history of system’s work into a local database so that
stakeholders will be able to see it later. Whenever the system detects any traffic signs
or light, it will immediately store it into the local DB. The system will need GPS or
accelerometer if available in the device to provide the driver his speed of the vehicle
during driving using. Same as it is the app will be needed GPS to share his live location
with other apps
Finally, the app will need to provide guidance to the user to learn about traffic rules.
The user will be authenticated using email or password If he doesn’t have an account
then the system will register the user with email or stakeholder can direct sign in using
Gmail.
The System will have the functionality to detect traffic lights or sign boards using the
camera then save it to the local database so that stakeholders could review it later.
Same as it is the system will be able to calculate the distance between provided any two
locations or speed of the vehicle and can share the live location of the driver with other
stakeholders or applications.
One assumption about the product is that it will always be used on mobile phones that
have enough performance. If the phone does not have enough hardware resources
available for the application, for example, the user might have allocated them with other
applications, there may be scenarios where the application does not work as intended
or even at all.
Another assumption is that the GPS components in all phones work in the same way. If
the phones have different interfaces to the GPS, the application need to be specifically
adjusted to each interface and that would mean the integration with the GPS would
have different requirements than what is stated in this specification.
Same as it is a mobile device must have good Camera with handy features so that It
could detect the signs and signals properly. The camera will vary from device to device
which will also affect the performance of the system.
Last but not the least mobile phone is supposed to have good sensors such as an
accelerometer of calculation of the speed of the vehicle. So system also will depend on
it.
This will be the largest and most important section of the document. This section
contains all of the functional and quality requirements of the system. It gives a detailed
description of the system and all its features.
11
This section provides a detailed description of all inputs into and outputs from the
system. It also gives a description of the hardware, software and communication
interfaces and provides basic prototypes of the user interface.
In this cluster, the system interface is to describe. Each system interface and
functionality of the software to accomplish the system requirement and interface
description to match the system will be listed.
The system will be needed an interface through which stakeholders can open the
camera and camera will do its task. The system will need to used OpenCV API to boost
up the camera to detect the Traffic signals and signs boards.
Same as it is System will be needed an interface that enables the stakeholders to
calculate the distance of two places, for this system need to use google maps to find
places. The system will require an interface in which stakeholders can share their live
location and can calculate the speed of the vehicle.
2.1.2 Interfaces
In this bunch of paragraph, It is explained that how the system will interact with users or
stakeholders, is there any kind of GUI or the voice-based system will be there.
There will be a beautiful GUI provided to the system which is built using XML through
Android SDK and Android Studio. Material design guidelines will be implemented to
design the user interface for the system. The material design keeps stakeholder very
comfortable and easy to interact with the system by providing beautiful colour scheme
and animations.
Since the mobile application has any designated hardware, it does not have any direct
hardware interfaces. The physical GPS is managed by the GPS application in the
mobile phone and the hardware connection to the database server is managed by the
underlying operating system on the mobile phone. The Accelerometer in the device
which is required by the system is managed in the app to calculate the speed of the
vehicle.
The most important hardware interface for efficient usage of the camera. Most of the
system is dependent on the camera, So the interface is needed which can take the
maximum advantage of the camera to perform functions part one of the system.
The interface will cooperate with followings:
12
❖ Camera
❖ GPS
❖ Accelerometer sensor
❖ Other sensors
❖ CPU
❖ Speakers
The mobile application communicates with the Camera of the device to detect the traffic
sign boards and signals, the GPS application in order to get geographical information
about where the user is located and the visual representation of it, and the
accelerometer sensor to efficiently determined the speed of the vehicle. The last but not
least, system contacts with the database to store data in it.
INPUT: App should be installed on the device and the stakeholder can skip the registration to
enter the app.
PROCESSING: Downloading and installing the application.
OUTPUT: System is installed on the mobile now, you have entered the app and ready to use.
ERROR HANDLING: Exception handling need to implement.
13
INPUT: The user should be able to register through the mobile application. The user must
provide user-name, password and e-mail address. The user can choose to provide a regularly
used phone number.
PROCESSING: Account creation using provided inputs.
OUTPUT: Account will be created and using can sign in now.
ERROR HANDLING: Exception handling need to implement.
INPUT: User able to sign in with already existed google account in the mobile.
PROCESSING: Google API will verify and then sign indirectly.
OUTPUT: User will be signed in without account creation
ERROR HANDLING: Exception handling is needed to implement.
2.2.1.4 Functional requirement 1.4
INPUT: User will be able to open the camera with the provided interface.
PROCESSING: The system will detect the traffic signals and signboards through the camera.
OUTPUT: The Required object will be detected through the camera.
ERROR HANDLING: Poor camera quality could cause a problem.
2.2.1.6 Functional requirement 1.6
INPUT: Detection of signals and signs will be used as input for this FR.
PROCESSING: System will analysis the detection and then give instructions to stakeholders
over voice.
OUTPUT: Voice instructions or any other indication
ERROR HANDLING: Availability of resources.
14
INPUT: Live location of the user will be used for this FR.
PROCESSING: The system will use the location to send it to the other stakeholders or maybe to
the other app.
OUTPUT: In the output, the location will be successfully sent to the required one.
ERROR HANDLING: Poor Internet connection or faulty GPS could cause the problem.
INPUT: Live location of the stakeholders will be used as input for determining the quantity of
flow.
PROCESSING: The google map API will be used to process the determination of traffic flow.
OUTPUT: The quantity of traffic flow will be determined.
ERROR HANDLING: Inaccurate location of the user could cause the problem.
15
In this case, the user enters his/her username, name, surname, password, mail address sets a
profile photo. When the user fills all necessary fields, an activation mail will be sent to
users mail address. The user will be able to login and start using the system just after activating
his/her account.
2.3.2 Use Case (Login)
17
In this case, the user enters his/her username or email and his/her password and logs in the
system.
In this case, the user enters or logs in the System without registering.
In this case, users will be able to detect traffic signals using the camera of the app.
In this case, users will be able to detect traffic sign boards using the camera of the app.
In this case, voice instructions are provided to the user when the system detects any signal or
signboards.
19
This case determines the speed of the vehicle and shows to the user.
This case determines how much traffic is on the road and show to the user.
20
This case gets the user’s location and shares it with other apps.
This case gives the user proper documentation on traffic rules and regulations to learn about
traffic rules.
There are a few requirements which are needed for the system for 100 percent
reliability. These requirements are:
➢ High-speed internet (Wifi or 3/4G).
➢ Latest Android version
➢ Efficient CPU
➢ Long-lasting bigger battery.
22
The system should have 100% availability of good internet connection, user live
location, good camera, powerhouse CPU and battery else the system will be affected
badly.
2.4.4 Security Requirements
Requirements of security for any software application related to the statement that it should be
secured according to the industry practices. Mobile application must use secure network
protocols so that no data could be leaked or hacked. Just like in our system, stakeholder’s data
in history must be protected from leakage.
2.4.5 Maintainability Requirements
Maintainability is the ease with which faults in a software system can be found and fixed. In the
system, faults could occur due to a slow internet connection or damaged hardware, So the
system can be recovered as soon as the internet connection is boosted or devices are
recovered.
2.5.1 Entities
An entity is an object in the system that we want to model and store information about.
Entities are usually recognizable concepts, either concrete or abstract, such as a
person, places, things, or events which have relevance to the database.
The system has two entities:
➢ User
➢ Snaps
2.5.2 Attributes
An attribute is an item of information which is stored about an entity. For example, the
entity 'lecturer' could have attributes such as staff id, surname, forename, date of birth,
telephone number, etc.
The VAD system must have the following attributes across entities:
23
➢ Username
➢ Email address
➢ Photo
➢ Last location
➢ Detect signal or sign snap
➢ Time at snap taken
➢ Location at snap taken.
2.5.2 Tables:
A table is a collection of related data held in a structured format within a database. It consists of
columns and rows.
The VAD system must have the following tables:
➢ User
➢ History
2.5.3 ER Diagram:
The hard drive should have a minimum of 100MB space to install and run the application
successfully.
24
The RAM should have a minimum of 1GB to run the application efficiently.
2.6.3 Camera:
The Camera should be above 5mp to capture and detect the required objects.
2.6.4 GPS:
The Mobile device should have a GPS feature to fetch the location of the stakeholder.
2.6.5 Accelerometer:
The Mobile device should have an accelerometer sensor to measure the speed of the vehicle.
A data flow diagram (DFD) shows how information flows through an information system,
including inputs, outputs, where data is stored, and where it travels.
26
Android Application will be developed as a single Android Client (apk) and it will:
❖ Capture images through camera and process it to identify specific objects.
❖ Voice instructions on object identification.
❖ Calculation of distance between two locations.
❖ Measuring the speed of the vehicle.
❖ Measuring Traffic flow.
❖ Providing Documentation
The camera will be used to capture images and process it to identify objects and maybe
to store them in the local database.
The GPS will calculate the location of stakeholder and store it in the local DB.
The sensors will use measure the speed of the vehicle.
30
User:
id:
Identity number is given from the database for each user. This attribute is unique for any
user. It also will be the primary key.
name:
The first and last name of the user.
username:
The title of stakeholder’s account.
password:
The password that stakeholder uses on the time of account creation.
email:
This is optional if the user wants to register the account using an email address.
photo:
The photo that the user will be uploaded during account creation.
description:
A brief description where the user mentions about his/herself
Snaps:
id:
Identity number is given from the database for each user. This attribute is unique for any
id. It also will be the primary key.
time:
The date and time at which snap are taken.
photo:
The photo that is taken for processing.
location:
The location where the photo was taken.
36
User:
Parameter Parameter Type
id int
username String
name String
password String
photo bytes
37
Snaps:
Parameter Parameter Type
id int
time String
photo bytes
app directly. By using this application, users can open the camera. The camera will
keep the user alert through voice if any object it identifies.
4.3.6 Speedometer:
4.4.4 Dashboard:
4.4.6 Speedometer:
4.4.10 Profile:
4.5 Testing:
4.5.1 Sign in
1 Enter valid mobile number and click on Dashboard will be opened Successful
sign up button (Internet connected)
2 Enter valid mobile number or click on sign Sign in will not be Successful
in with google (Internet disconnected) proceeded.
4.5.2 Prediction
4.5.2 Speedometer
1 Fetch real time location from GPS Show real time speed Successful
56
2 Couldn’t fetch the location from GPS Show speed 0KM/hr Successful
4.5.4 Distance
1 Calculate distance b/w two points Show real time distance Successful
2 Couldn’t fetch the location from points Will not show distance Successful
1 Fetch real time location from GPS and Toast of “delivered” will be Successful
SMS it to given valid number shown
57
2 Couldn’t fetch the location or number is Will not send sms or send Successful
invalid it with null msg
4.5.5 Profile
The lessons learned document contains information about all the project life-cycle
processes but most important the Executing and Controlling processes. These two
processes are when work of the project performed and when you will likely find
mistakes that were made in the planning document or processes. Anything you discover
that could have been clearer or any additional information that would have helped to
avoid confusion should be noted here. Process improvements, communication glitches,
or any other information that will you perform the next project better should be noted
here.
★ Location APIs
★ GPS and Fused location API
★ Camera API
★ Camera API 2
★ Custom Camera Frame processing APIs
★ Google maps.
★ Sensors, camera angles and their working for IMP.
★ Firebase
★ Firebase ML Kit
★ Tensorflow Lite
★ UI & UX for mobile screens
Term Definition
UI User Interface
UX User Experience
ER Entity Relationship
DD Data Design
AD Architecture Design
DR Design Rationale.
ML Machine Learning
AI Artificial Intelligence
lat Latitude
61
lng Longitude