Unit 2
Unit 2
Operating System:
The operating system is the main software that manages your computer's h/w and s/w
resources. It provides an environment for other software, like development tools, to run.
The OS (e.g., Windows, macOS, or Linux) allows you to install and use tools like Android
Studio.
It handles file systems, memory management, and hardware drivers needed for
development.
Java JDK:
The JDK is a software development kit for creating Java applications. It includes tools for
writing, compiling, debugging, and running Java programs.
Many Android apps are built using Java. The JDK helps you write Java code for your app.
It includes the Java Compiler (to convert code into machine-readable instructions) and the
Java Runtime Environment (JRE) to test the app.
Android SDK:
The Android SDK is a collection of tools, libraries, and emulators specifically for creating
Android apps. It helps developers build, test, and debug applications for Android devices.
Provides APIs (Application Programming Interfaces) to access Android features like the
camera, GPS, or notifications.
Includes tools like ADB (Android Debug Bridge) for testing apps on real or virtual
devices.
Comes with emulators to simulate Android devices for testing.
These three components are essential for Android Application Development
Operating System: Runs development tools like Android Studio.
Java JDK: Helps you write and run Java code for Android apps.
Android SDK: Provides the tools and libraries to create apps specifically for Android
devices.
Emulator
- An emulator is a software program that copy the functions of a physical device on your computer.
- In Android development, an Android Emulator is a tool that simulates an Android phone or tablet,
allowing you to run and test apps on your computer without needing a real device.
- Key Points About Emulators:
Simulate Devices: It creates a virtual version of a physical Android device (e.g., phone,
tablet).
Testing: Developers use it to test their apps on different Android versions, screen sizes, and
resolutions.
Simulate Features: It can simulate features like the camera, GPS, touch input, and more.
Faster Development: It saves time by allowing developers to test apps quickly without
needing a physical device for each test.
In short, an emulator is like a "fake" Android device on your computer, used for testing apps in a
controlled environment.
JVM DVM
1. Purpose JVM Designed for running Java DVM Specifically built for
programs on computers and running Android apps on
servers. mobile devices.
2. Code Format JVM Runs Java bytecode DVM Converts Java bytecode
directly. into Dalvik bytecode for better
performance on Android.
3. Platform JVM Works on desktops, DVM Works only on Android
servers, and non-Android devices.
systems.
4. Memory Usage JVM Uses more memory, DVM Uses less memory,
suitable for devices with more optimized for low-resource
resources (like PCs). mobile devices.
5. Execution Process JVM Uses Just-In-Time (JIT) DVM Also uses JIT, but its
compilation to convert bytecode bytecode is already optimized
to machine code during for mobile devices.
runtime.
8. Replacement JVM Still widely used for Java DVM Replaced by ART
applications. (Android Runtime) in modern
Android versions for faster and
more efficient performance.
Steps to install and configure Android Studio and SDK
Step 1: Download Android Studio
1.Go to the official Android Studio Website.
2.Click Download Android Studio and save the file.
Tips
Ensure your computer meets the requirements (e.g., enough RAM and disk space).
Use a fast and stable internet connection for downloading files.
Keep Android Studio and the SDK up-to-date via Help > Check for Updates.
Now you’re ready to start creating Android apps.