Post Top Ad

Showing posts with label Android Guide. Show all posts
Showing posts with label Android Guide. Show all posts
May 21, 2014

Android 2nd Tutorial

Android Hello World Example



This is the most easy tutorial as far as android is concerned.





When you create a new project, by default Google has included hello world code for you. But what happens behind the code is the important part.
 
Summary steps to develop an Android application :
  1. Install Android SDK
  2. Install ADT Eclipse plugin
  3. Create an Android Virtual Device (AVD)
  4. Create Android Project with Eclipse (Wizard)
  5. Code it…
  6. Start it in Android Virtual Device (AVD)
In android all the code is normally written in Java
GUI is created using XML
So you have to attach GUI elements to the code. How we do this is via a file called R. R is a automatically generated file where you have all the default name for the elements which you have included in the GUI.
When you run the code what happen is all the components will be linked together with the code and display the output


But How come Hello world String appear in the GUI
Hello world string is in actually String file. 

String Resources

 A string resource provides text strings for your application with optional text styling and formatting. There are three types of resources that can provide your application with strings:
String

    XML resource that provides a single string.

String Array
    XML resource that provides an array of strings.

Quantity Strings (Plurals)
    XML resource that carries different strings for pluralization.
All strings are capable of applying some styling markup and formatting arguments. For information about styling and formatting strings.
Useful Links

Android Developer Guide

 



May 20, 2014

Android 1st Tutorial

What is Android



• A software platform and operating system for mobile devices
• Based on the Linux kernel
• Developed by Google and later the Open Handset Alliance (OHA)
• Allows writing managed code in the Java language

Introduction

• Possibility to write applications
native code (support of Google? No)
• Unveiling of the Android platform was announced on 5 November 2007
with the founding of OHA


What is the Open Handset Alliance

• Devoted to advancing open standards for mobile devices
• Develop technologies that will significantly lower the cost of developing and
distributing mobile devices and services

Operating System(s)

• Android uses Linux for its device drivers, memory management, process
management, and networking.
• The next level up contains the Android native libraries. They are all written in
in C/C++ internally, but you’ll be calling them throutgh java interfaces. In this
layer you can find the Surface Manager, 2D and 3D graphics, Media
codecs, the SQL database (SQLite), and a native web browser engine

• Dalvik Virtual Machine. Dalvik runs dex files, which are converted at compile
time from standard class and jar files.

Network Connectivity
It supports wireless communications using:
  • GSM mobile-phone technology3G
  • Edge
  • Platform
  • Edge
  • 802.11 Wi-Fi networks

Security
Android is a multi-process system, in which each application (and parts of the system) runs in its own process. Most security between applications and the system  is enforced at the process level through standard Linux facilities,such as user and group IDs that are assigned to applications.


Additional finer gained security features are provided through a “permission ” mechanism that enforces restrictions on the specific operations that a particular process can perform, and per-URI permissions for granting ad-hoc access to specific pieces of data.

Performance


Android Development

What you will need




Actually there are a lot of ways to get these setup up and running. But the most preferred way is to download the complete ADT bundle. Here is the link



Software Development

• Java – officially supported
• C/C++ – also possible but not supported

How Things work




Linux Kernel

• Works as a HAL (Hardware abstractionLayer)
• Device drivers
• Memory management
• Process management
• Networking
Libraries
• C/C++ libraries
• Interface through Java
• Surface manager – Handling UI Windows
• 2D and 3D graphics
• Media codecs, SQLite, Browser engine

Android Runtime

• Dalvik VM
– Dex files
– Compact and efficient than class files
– Limited memory and battery power
• Core Libraries
– Java 5 Std edition
– Collections, I/O etc…

Application Framework

• API interface
• Activity manager – manages application
life cycle.

Applications

• Built in and user apps
• Can replace built in apps

 Overall Evaluation

There are a host of advantages that Google’s Android will derive from being and open source software. Some of the advantages include
• The ability for anyone to customize the Google Android platform
• The consumer will benefit from having a wide range of mobile applications to choose from since the monopoly will be broken by Google Android
• Men will be able to customize a mobile phones using Google Android platform like never before
• Features like weather details, opening screen, live RSS feeds and even the icons on the opening screen will be able to be customized
• As a result of many mobile phones carrying Google Android, companies will come up with such innovative products like the location
• In addition the entertainment functionalities will be taken a notch higher by Google Android being able to offer online real time multiplayer games

 

 













My Instagram