Showing posts with label android sdk. Show all posts
Showing posts with label android sdk. Show all posts

Sunday, 7 October 2012

What is Dalvik Virtual Machine?

Dalvik is an Open Source Software originally written by Dan Bornstein who named it after the fishing village of Dalvik in Iceland.

Dalvik Virtual Mahcine is a process virtual machine (VM) in Android Operating System. It is a software that runs the applications on Android Devices. Dalvik is used primarily in smartphones and tablets but recently it is also being used in smart Tvs and media streamers.

Programs are written in Java and compiled to java bytecode. They are then converted from Java Virtual Machine .class files to Dalvik compatible .dex (Dalvik Executable)files. The compatc Dalvik Executable format is suitable for systems that are constrained in terms of memory and processor speed.

Salient Features of Dalvik VM

  • Dalvik VM uses a register based architecture instead of stack based architecture used by Java Virtual Machine.
  • VM is trimmed down to limit memory space requirement.
  • The constant pool has been modified to use only 32-bit indices to simplify the interpreter
  • Standard Java bytecode executes 8-bit stack instructions. Local variables must be copied to or from the operand stack by separate instructions. Dalvik instead uses its own 16-bit instruction set that works directly on local variables. The local variable is commonly picked by a 4-bit 'virtual register' field. This lowers Dalvik's instruction count and raises its interpreter speed.
  • Dalvik has the capacity to compress resources that you have in your application there by reducing the final apk size and makes the device run multiple instances of the VM efficiently
Difference between Dalvik VM and Java VM

                                            Dalvik                               JVM
Architecture                          Register                            Stack
OS Support                          Android                            Many
Executables                          APK                                 JAR
Constant Pool                       Per Application                 Per Class
Memory Reqt                       Low                                  High

Licenses

Dalvik is said to be a clean-room implementation rather than a development on top of a standard Java runtime, which would mean it does not inherit copyright-based license restrictions from either the standard-edition or open-source-edition Java runtimes. Dalvik is published under the Apache 2 license.
(Source: wikipedia)



Saturday, 6 October 2012

Android Application Development - Getting Started

All Android Applications are developed in Java Language. You must know Java in order to be able to develop any android application. 

You need to have the set up of android development environment. You would require the following:

The   Android SDK  is composed of modular packages that you can download separately using the Android  SDK Manager Whenever there is a new release for SDK tools or platforms , you can use the  SDK Manager to quickly download them to your environment. 

Once your environment is ready, you can start creating your apps. Lets develop our first project "Hello World" and learn how to create and run a project/application in Eclipse.

What is Android - An Introduction

Android is a Linux-based operating system designed primarily for touchscreen mobile devices such as smartphones and tablet computers, developed by Google in conjunction with the Open Handset Alliance.

Just like we have Windows operating system for PCs, Android is an operating system for smartphones and tablets which soon will be extended to other products like cars, TVs etc.

Why Android is so popular?


You go to any mobile shop today and you will find majority of smartphones with Android operating system.

Some of the major reasons for its huge popularity are:

1. Android is Free

Android is and will always be free to use. That is one of the biggest reason for its huge popularity and adoption among the phone manufacturers. Why pay a royalty to any company for using the OS when you can get Android for free? This also made possible for the phone manufacturers to come out with smartphones at low cost and still having high end features. You could see many companies like Micromax, Lava , Spice and many others offering low cost smart phones.

Would you buy a normal feature phone when you can get a smartphone at roughly the same price? Probably, NOT. This has in turn benefitted normal feature phone buyers as well because their prices have come down drastically. A WIN WIN situation for all.

2. Android is Open Source and Open for customization 

You get the full source code of Android without paying any royalty to Google. This enables the phone manufacturers to customize the OS according to their requirements. With many brains working on the system, newer and newer ideas were incorporated, which in turn helped in making Android a preferred choice.

3. Huge number of Mobile Applications

Android Market created an opportunity for millions of application developers around the globe to show their skills and come up with newer applications for Android phones. Its users therefore have a wide variety of applications to choose from and can customise their phones for a personal experience. It has attracted millions of developers around the world as they can now earn by selling their applications on Android Market.

4. Excellent tools for developers

Google has provided complete toolset for developing applications for free. Applications are usually developed in the Java language using the Android Software Development Kit, but other development tools are available, including a Native Development Kit for applications or extensions in C or C++.

Market Share of Android

Here are IDC's figures for worldwide smartphone unit sales and market share in the second quarter of 2012, by operating system.

— Android (Google Inc.) — 104.8 million units, 68.1 percent share (46.9 percent a year earlier)
— iOS (Apple Inc.'s iPhone) — 26.0 million units, 16.9 percent share (18.8 percent a year earlier)
— BlackBerry (Research in Motion Ltd.) — 7.4 million units, 4.8 percent share (11.5 percent a year earlier)
— Symbian (mostly used by Nokia Corp.) — 6.8 million units, 4.4 percent share (16.9 percent a year earlier)
— Windows (Microsoft Corp.) — 5.4 million units, 3.5 percent share (2.3 percent a year earlier)
— Linux — 3.5 million units, 2.3 percent share (3.0 percent a year earlier)
— Others — 0.1 million units, 0.1 percent share (0.5 percent a year earlier) 


Future of Android

 As per market research, Android is here to stay atleast till 2015. With android set to come in TVs, cars and other appliances, there is a huge scope for android usage. 

Cars - Till now cars are provided with multimedia facilities such as GPS, Bluetooth etc. But in future Android, QNX, Linux operating systems will provide additional facilities in cars. Operating system will control all the things such as  nearby garages, air condition, seats suspension, climate control etc. It will also give the information such as the location, details of the accidents that happened nearby and traffic. It will also be possible to know the details of the hotels in the route the car is travelling.

TVs - Televisions are already coming with operating system. Google television is one of the examples. Net can be browsed with Chrome browser that is installed. Applications and multimedia content in Chrome can be utilized as in system. Lenovo and Onida have designed televisions that run with android operating system. All the television channels available in net can be watched. With the new features that will be available. Televisions can be connected to the mobile.

Our life will change drastically in future when most of the products like Car, TV, Refrigerator, Mirror, Ovens will go SMART.
Application developers can start thinking on ideas they would like their home products to have. Lets share our ideas and thoughts about future andriod applications.