Madlab Manual
Madlab Manual
LABORATORY
(Regulation 2017)
QUALITY EDUCATION”
EDUCATION
1|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
8. Ethics: Apply ethical principles and commit to professional ethics and responsibilities and
norms of the engineering practice.
9. Individual and team work: Function effectively as an individual, and as a member or leader
in diverse teams, and in multidisciplinary settings.
10. Communication: Communicate effectively on complex engineering activities with the
engineering community and with society at large, such as, being able to comprehend and write
effective reports and design documentation, make effective presentations, and give and receive
clear instructions.
11. Project management and finance: Demonstrate knowledge and understanding of the
engineering and management principles and apply these to one’s own work, as a member and
leader in a team, to manage projects and in multidisciplinary environments.
12. Life-long learning: Recognize the need for, and have the preparation and ability to engage in
independent and life-long learning in the broadest context of technological change.
3|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SYLLABUS
LIST OF EXPERIMENTS
1. Develop an application that uses GUI components, Font and Colours
2. Develop an application that uses Layout Managers and event listeners.
3. Write an application that draws basic graphical primitives on the screen.
4. Develop an application that makes use of databases.
5. Develop an application that makes use of Notification Manager
6. Implement an application that uses Multi-threading
7. Develop a native application that uses GPS location information
8. Implement an application that writes data to the SD card.
9. Implement an application that creates an alert upon receiving a message
10. Write a mobile application that makes use of RSS feed
11. Develop a mobile application to send an email.
12. Develop a Mobile application for simple needs (Mini Project)
TOTAL: 60 PERIODS
OUTCOMES:
Upon Completion of the course, the students will be able to:
Develop mobile applications using GUI and Layouts.
Develop mobile applications using Event Listener.
Develop mobile applications using Databases.
Develop mobile applications using RSS Feed, Internal/External Storage, SMS, Multi-threading
and GPS.
Analyze and discover own mobile app for simple needs.
REFERENCES:
1. Build Your Own Security Lab, Michael Gregg, Wiley India
4|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
LIST OF EXPERIMENTS
1. Develop an application that uses GUI components, Font and Colours
5|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
K/ Bloom’s
Course Course Outcome
Taxonomy
No. (Student should be able to)
Level
Build various mobile applications related to GUI components, Font and
R17C322.1 K3 - Apply
Colours using Layout managers and Event Listeners
R17C322.2 Make use of database concepts for data related mobile applications K3 - Apply
Develop mobile applications using Internal & External Storage, SMS
R17C322.3 K3 - Apply
Notification, Multithreading, and GPS.
Model the mobile application using RSS Feed, Alert upon receiving a
R17C322.4 K3 - Apply
message and send an E-Mail
R17C322.5 Develop Mobile App for simple real time needs K3 - Apply
Program
Program outcomes Specific
Course
outcomes
Outcomes
PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 PO11 PO12 PSO1 PSO2
R17C322.1 L - L - M - - - L - - L L L
R17C322.2 L - L - M - - - L - - L L L
R17C322.3 L - L - M - - - L - - L L L
R17C322.4 L - L - M - - - L - - L L L
R17C322.5 M M M L M M - - M L - M M M
R17C322 L M L L M M - - L L - L L L
Internal Assessment
6|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
INDEX
Ex.
Date Application Name Page No. Marks Signature
No.
3 Graphical Primitives
5 Notification Manager
6 Multithreading
7 GPS location
8 SD Card Manager
10 RSS Feed
11 E-Mail Notification
12 Mini Project
7|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
Marks
Category
allotted
Clear &
No proper
Layout Appropriate Appropriate Clear & Less Less features
layout design 25
Design features features [20] features [15] [10]
[5]
[25]
Record Submission 1 day delay 2 days delay 3 days delay 4 days delay 25
Submission on date [25] [22] [19] [16] [13]
8|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
Submission [25]
Marks obtained
Target Attained
Code Logic [25]
Layout Design
(Y/N)
Ex.
[25]
Exercises COs
No.
3 Graphical Primitives
5 Notification Manager
6 Multithreading
R17C322.3
7 GPS location
8 SD Card Manager
11 E-Mail Notification
9|P ag e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
Model Exam
Target
Internal Laboratory Mark Model Exam Total Mark
Attained?
Assessment (75%) (25%) (100)
[Y/N]
Marks
Note:
If CO Attainment,
Y = Laboratory Mark (%) >= Target Value (%)
N = Laboratory Mark (%) < Target Value (%)
Action Plan:
If CO not attained,
Staff In-Charge
10 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
INTRODUCTION TO ANDROID OS
INTRODUCTION
Android is a Linux based operating system it is designed primarily for touch screen
mobile devices such as smart phones and tablet computers. The android is a powerful
operating system and it supports large number of applications in Smartphones. These
applications are more comfortable and advanced for the users. The hardware that supports
android software is based on ARM architecture platform.
The android is an open source operating system. The android has got millions of apps
available that can help you managing your life one or other way and it is available low cost in
market at that reasons android is very popular.
The android development supports with the full java programming language. Even
other packages that are API and JSE are not supported. The first version 1.0 of android
development kit (SDK) was released in 2008
ANDROID ARCHITECTURE
The android is an operating system and is a stack of software components which is divided
into five sections and four main layers that is
Linux kernel
Libraries
Android runtime
LINUX KERNEL
The android uses the powerful Linux kernel and it supports wide range of hardware drivers.
The kernel is the heart of the operating system that manages input and output requests from
software. This provides basic system functionalities like process management, memory
management; device management like camera, keypad, and display etc., the kernel handles
all the things. The Linux is really good at networking and it is not necessary to interface it to
the peripheral hardware. The kernel itself does not interact directly with the user but rather
interacts with the shell and other programs as well as with the hard ware devices on the
system.
1|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
LIBRARIES
On top of a Linux kennel there is a set of libraries including open source web browser such as
webkit, library libc. These libraries are used to play and record audio and video. The SQLite
is a data base which is useful for storage and sharing of application data. The SSL libraries
are responsible for internet security etc.
ANDROID RUNTIME
The android runtime provides a key component called Dalvik Virtual Machine which is a
kind of java virtual machine. It is specially designed and optimized for android. The Dalvik
VM is the process virtual machine in the android operating system. It is software that runs
apps on android devices.
The Dalvik VM makes use of Linux core features like memory management and
multithreading which is in a java language. The Dalvik VM enables every android application
to run its own process. The Dalvik VM executes the files in the .dex format.
The application frame work layer provides many higher level services to applications such as
windows manager, view system, package manager, resource manager etc. The application
developers are allowed to make use of these services in their application.
2|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
FEATURES
Head set layout
Storage
Connectivity: GSM/EDGE, IDEN, CDMA, Bluetooth, WI-FI, EDGE,3G,NFC, LTE,GPS.
Messaging: SMS, MMS, C2DM (could to device messaging), GCM (Google could
messaging)
Multilanguage support
Multi touch
Video calling
Screen capture
External storage
Streaming media support
Optimized graphics
ANDROID VERSIONS
Android 1.5: Android Cupcake
Android 1.6: Android Donut
Android 2.0: Android Eclair
Android 2.2: Android Froyo
Android 2.3: Android Gingerbread
Android 3.0: Android Honeycomb
Android 4.0: Android Ice Cream Sandwich
Android 4.1 to 4.3.1: Android Jelly Bean
Android 4.4 to 4.4.4: Android KitKat
Android 5.0 to 5.1.1: Android Lollipop
Android 6.0 to 6.0.1: Android Marshmallow
Android 7.0 to 7.1: Android Nougat
Android 8.0 to Android 8.1: Android Oreo
Android 9.0: Android Pie
3|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
Android Studio was announced on May 16, 2013 at the Google I/O conference. It was
in early access preview stage starting from version 0.1 in May 2013, then entered beta stage
starting from version 0.8 which was released in June 2014. The first stable build was released
in December 2014, starting from version 1.0.
Since May 7, 2019, Kotlin is Google’s preferred language for Android app
development. Still, other programming languages are supported by Android Studio, such as
Java and C++.
FEATURES
4|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
PROCEDURE
Creating a New Project
Open Android Stdio and then click on File -> New -> New project.
5|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
Then select the Minimum SDK as shown below and click Next.
6|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
7|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop a Simple Android Application that uses GUI components, Font and
Colours.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open res directory -> layout -> activity_main.xml and add the code.
Step 4: Open java -> MainActivity.java and add the code.
Step 5: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
8|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
9|Page
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
10 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop a Simple Android Application that uses Layout Managers and Event
Listeners.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open res directory -> layout -> activity_main.xml and add the code.
Step 4: Open java -> MainActivity.java and add the code.
Step 5: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
11 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
12 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
13 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop a Simple Android Application that draws basic Graphical Primitives on
the screen.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components (ImageView) to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open java -> MainActivity.java and add the code.
Step 4: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
14 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
15 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
16 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop a Simple Android Application that makes use of Database.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Create two resource files (*.xml) and two activity files (*.java) named activity_ main
.xml & activity_main2.xml and MainActivity.java & Main2Activity.java.
Step 3: Open res directory -> layout -> activity_main.xml -> Click -> Design button at
bottom of the Android Studio. Put the necessary components for both resource files
(activity_main.xml, activity_main2.xml).
Step 4: Design (After the design part, the xml code will be generated automatically in the
layout file).
Step 5: Open Java ->MainActivity.java & MainActivity2.java and add the code.
Step 6: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
17 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
18 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
19 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop a Simple Android Application that makes use of Notification Manager.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open Java ->MainActivity.java and add the code.
Step 4: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
20 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
21 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
22 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android Application that implements Multithreading.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open your Android studio project folder (e.g. Project name: Multithreading)
-> Click app -> src -> main -> res -> drawable -> add *.png file.
Step 4: Open Java ->MainActivity.java and add the code.
Step 5: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
23 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
24 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
25 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android application that uses GPS location information.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Create two resource files (*.xml) and two activity files (*.java) named activity_ main
.xml & activity_main2.xml and MainActivity.java & Main2Activity.java.
Step 3: Open res directory -> layout -> activity_main.xml -> Click -> Design button at
bottom of the Android Studio. Put the necessary components for both resource files
(activity_main.xml, activity_main2.xml).
Step 4: Design (After the design part, the xml code will be generated automatically in the
layout file).
Step 5: Open AndroidManifest.xml and add the code to provide access permission.
Step 6: Open Java ->MainActivity.java & MainActivity2.java and add the code.
Step 7: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
26 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
27 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
28 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android Application that writes data to the SD Card.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open AndroidManifest.xml and add the code to provide access permission.
Step 4: Open Java ->MainActivity.java and add the code.
Step 5: Connect the Android Mobile, run the project and the output will be displayed in
Emulator.
LAYOUT DESIGN
29 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
30 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
31 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android Application that creates an alert upon receiving a message.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 4: Open Java ->MainActivity.java and add the code.
Step 5: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
32 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
33 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
34 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android Application that makes use of RSS Feed.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open AndroidManifest.xml and add the code to provide access permission.
Step 4: Open Java ->MainActivity.java and add the code.
Step 5: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
35 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
36 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
37 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
AIM
To develop an Android Application to send an Email.
PROCEDURE
Step 1: Create an android project using android studio.
Step 2: Design
2.1. Open the actual Project folder (app) in Android Studio IDE.
2.2. Click res directory -> layout -> activity_main.xml -> Design.
2.3. Insert the GUI components to Design view in activity_main.xml.
2.4. Enter the id for each component.
Step 3: Open AndroidManifest.xml and add the code to provide access permission.
Step 4: Open res/values/styles.xml and add the code.
Step 5: Open Java ->MainActivity.java and add the code.
Step 6: Run the project and the output will be displayed in Emulator.
LAYOUT DESIGN
38 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
SAMPLE OUTPUT
39 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
40 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
41 | P a g e
CS8662 – Mobile Application Development Laboratory 2019-2020 (EVEN)
42 | P a g e