Posts Tagged ‘Android’

Motorola Droid 2 ? Verizon Unveils New Android Phone

Posted By admin on November 13th, 2011

Verizon wireless has officially released the Droid 2 cell phone and an official launch date is scheduled on 23rd Aug 2010. The Verizon Motorola droid 2 is an updated version of Verizons original droid and is now apart of a line of cell phones using the droid name. The droid line of phones is Verizons flagship phones that are placing some tough competition on the smartphone market. While the droid 2 is mostly a business phone it has lots of capabilities for multimedia, making it a great all around device.

Motorola Droid 2 Android:
The droid uses the Android OS which is basically taking over the smartphone market as the OS of choice. Motorola droid 2 android OS works perfectly with each other and is a winning combination though. No longer is windows mobile the way to go as windows mobile is an outdated smartphone. OS lacking the features of other popular OS’s such as Android.

Motorola Droid 2 Review:
I am going to give you a basic Motorola droid 2 review in this article. I have always found reviews helpful when buying phone because why buy a phone that is not going to suit your needs or is not as good as they make it out to be? The Motorola droid 2 is a good phone having top notch quality like the first one. The droid 2 does not look much different from the original droid. Its outside appearance has been barely changed. So, overall it has the same design and shape as that of original. Looking both phones at a distance, you would not be able to differentiate between droid and droid 2.

The Verizon Motorola droid 2 changed at least one thing which the people were complaining about, and that is the keyboard. Many people complained that the original droids keyboard keys were just too flat and not that great. With the release of the droid 2, you will notice an updated keyboard with raised keys and that the D-pad is now gone. This means, the keys are actually bigger so this is a welcome update.

The internal updates are much more staggering. The original droids CPU was only about half the speed of the new ones. So, you can expect the Droid 2 to operate at a much faster pace and not to be sluggish. You also get the new Android 2.2 OS update with this phone. It is just an improvement on the Android OS and if you have never used Android OS before then you won’t pay much attention to this.

The Motorola Droid 2 is a great phone that is much improved over the original. With wider and better keys on the keyboard to the much faster CPU, this phone is just purely amazing. The IPhone best just watch it’s back with the Droid lineup of cell phones. If you are considering the droid 2 then I say go ahead and buy it. This is the perfect phone for you if you want a good business phone with a real keyboard on it. You can also use the onscreen keyboard if you want. Some people prefer a physical keyboard so this droid version has just that.

Motorola Droid 2 Price:
You may wonder about the motorola droid 2 price as well. Well this phone with a 2 year contract won’t break the bank. You can get it for a cool 200 bucks with a 2 year contract. Without the contract this phone will cost a lot more as all other smartphones do without a contract.

Motorola Droid 2 ? Verizon Unveils New Android Phone

Posted By admin on November 8th, 2011

Verizon wireless has officially released the Droid 2 cell phone and an official launch date is scheduled on 23rd Aug 2010. The Verizon Motorola droid 2 is an updated version of Verizons original droid and is now apart of a line of cell phones using the droid name. The droid line of phones is Verizons flagship phones that are placing some tough competition on the smartphone market. While the droid 2 is mostly a business phone it has lots of capabilities for multimedia, making it a great all around device.

Motorola Droid 2 Android:
The droid uses the Android OS which is basically taking over the smartphone market as the OS of choice. Motorola droid 2 android OS works perfectly with each other and is a winning combination though. No longer is windows mobile the way to go as windows mobile is an outdated smartphone. OS lacking the features of other popular OS’s such as Android.

Motorola Droid 2 Review:
I am going to give you a basic Motorola droid 2 review in this article. I have always found reviews helpful when buying phone because why buy a phone that is not going to suit your needs or is not as good as they make it out to be? The Motorola droid 2 is a good phone having top notch quality like the first one. The droid 2 does not look much different from the original droid. Its outside appearance has been barely changed. So, overall it has the same design and shape as that of original. Looking both phones at a distance, you would not be able to differentiate between droid and droid 2.

The Verizon Motorola droid 2 changed at least one thing which the people were complaining about, and that is the keyboard. Many people complained that the original droids keyboard keys were just too flat and not that great. With the release of the droid 2, you will notice an updated keyboard with raised keys and that the D-pad is now gone. This means, the keys are actually bigger so this is a welcome update.

The internal updates are much more staggering. The original droids CPU was only about half the speed of the new ones. So, you can expect the Droid 2 to operate at a much faster pace and not to be sluggish. You also get the new Android 2.2 OS update with this phone. It is just an improvement on the Android OS and if you have never used Android OS before then you won’t pay much attention to this.

The Motorola Droid 2 is a great phone that is much improved over the original. With wider and better keys on the keyboard to the much faster CPU, this phone is just purely amazing. The IPhone best just watch it’s back with the Droid lineup of cell phones. If you are considering the droid 2 then I say go ahead and buy it. This is the perfect phone for you if you want a good business phone with a real keyboard on it. You can also use the onscreen keyboard if you want. Some people prefer a physical keyboard so this droid version has just that.

Motorola Droid 2 Price:
You may wonder about the motorola droid 2 price as well. Well this phone with a 2 year contract won’t break the bank. You can get it for a cool 200 bucks with a 2 year contract. Without the contract this phone will cost a lot more as all other smartphones do without a contract.

Samsung vs. Samsung S Galaxy Galaxy Tab: Choose your handset

Posted By admin on October 31st, 2011

Samsung have been many successful series in the mobile market. Once again, Samsung has arrived with its Samsung handsets and two S Galaxy Galaxy tab. Both handsets are attractive and equipped with all the latest features.

Both devices are based Android, but Samsung Galaxy tab to run the latest version of Android OS v2.2 (Froyo), while Samsung Android OS v2.1 Galaxy S (Flash) . Both have the same combination of ARM Cortex A8 processor at 1 GHz, which improves the performance of these devices.

When it comes to storage capacity of this phone, Samsung Galaxy tab large internal storage capacity, as it comes with 16/32 GB internal memory while Samsung S Galaxy 8 GB storage capacity / 16GB to come. You can use the memory of these devices up to 32 GB with microSD card slot. But if you buy Samsung cell phone tab Galaxy with 32 GB of internal storage you do not get the opportunity to extend your phone’s memory.

Samsung Galaxy S 5-megapixel camera that gives you a high quality image as a galaxy riding it as it comes with a 3.5 megapixel camera. Both phones have all the latest features that are necessary to connect to broadband Internet as GPRS, 3G, Wi-Fi and EDGE. Both phones have all the qualities of a business phone as the best video editor / image document viewer (Word, Excel, PowerPoint, PDF), Google Search, Maps, etc.. You can also access your Google account and chat with friends and relatives with their applications, Gmail and Google Talk.

Samsung has released his two mobile phones with elegant style. Samsung S Galaxy has 4.0-inch AMOLED capacitive touchscreen Samsung Super Galaxy tab then 7.0 inch TFT touch screen is capacitive. Galaxy S Samsung handset is a lightweight unit with a weight of 119g compared to Samsung Galaxy tab because it has 380 grams of weight.

You can all these listeners with all major mobile operators such as Virgin, O2, T get – Mobile, Talk Mobile, Orange and Vodafone. They are various mobile offerings on many online merchants available for mobile devices such as Samsung Galaxy S-deals, Samsung-Galaxy Tab offers pay as you go deals and sim free offers. You can get all these services on any mobile shopping site. You can win lots of prizes to those operations, such as DVD players, cell phone accessories, PSP, LCD, and much more.

Development and remote installation of Java service for the Android Devices

Posted By admin on October 30th, 2011

Written by:
Igor Darkov, Software Developer of Device Team, Apriorit Inc.

In this article I’ve described:

How to develop simple Java service for the Android Devices; How to communicate with a service from the other processes and a remote PC; How to install and start the service remotely from the PC. 1. Java Service Development for the Android Devices

Services are long running background processes provided by Android. They could be used for background tasks execution. Tasks can be different: background calculations, backup procedures, internet communications, etc. Services can be started on the system requests and they can communicate with other processes using the Android IPC channels technology. The Android system can control the service lifecycle depending on the client requests, memory and CPU usage. Note that the service has lower priority than any process which is visible for the user.

Let’s develop the simple example service. It will show scheduled and requested notifications to user. Service should be managed using the service request, communicated from the simple Android Activity and from the PC.

First we need to install and prepare environment:

Download and install latest Android SDK from the official web site (http://developer.android.com); Download and install Eclipse IDE (http://www.eclipse.org/downloads/); Also we’ll need to install Android Development Tools (ADT) plug-in for Eclipse.

After the environment is prepared we can create Eclipse Android project. It will include sources, resources, generated files and the Android manifest.

1.1 Service class development

First of all we need to implement service class. It should be inherited from the android.app.Service (http://developer.android.com/reference/android/app/Service.html) base class. Each service class must have the corresponding <service> declaration in its package’s manifest. Manifest declaration will be described later. Services, like the other application objects, run in the main thread of their hosting process. If you need to do some intensive work, you should do it in another thread.

In the service class we should implement abstract method onBind. Also we override some other methods:

onCreate(). It is called by the system when the service is created at the first time. Usually this method is used to initialize service resources. In our case the binder, task and timer objects are created. Also notification is send to the user and to the system log: public void onCreate() { super.onCreate(); Log.d(LOG_TAG, “Creating service”); showNotification(“Creating NotifyService”); binder = new NotifyServiceBinder(handler, notificator); task = new NotifyTask(handler, notificator); timer = new Timer(); } onStart(Intent intent, int startId). It is called by the system every time a client explicitly starts the service by calling startService(Intent), providing the arguments it requires and the unique integer token representing the start request. We can launch background threads, schedule tasks and perform other startup operations. public void onStart(Intent intent, int startId) { super.onStart(intent, startId); Log.d(LOG_TAG, “Starting service”); showNotification(“Starting NotifyService”); timer.scheduleAtFixedRate(task, Calendar.getInstance().getTime(), 30000); } onDestroy(). It is called by the system to notify a Service that it is no longer used and is being removed. Here we should perform all operations before service is stopped. In our case we will stop all scheduled timer tasks. public void onDestroy() { super.onDestroy(); Log.d(LOG_TAG, “Stopping service”); showNotification(“Stopping NotifyService”); timer.cancel(); } onBind(Intent intent). It will return the communication channel to the service. IBinder is the special base interface for a remotable object, the core part of a lightweight remote procedure call mechanism. This mechanism is designed for the high performance of in-process and cross-process calls. This interface describes the abstract protocol for interacting with a remotable object. The IBinder implementation will be described below. public IBinder onBind(Intent intent) { Log.d(LOG_TAG, “Binding service”); return binder; }

To send system log output we can use static methods of the android.util.Log class (http://developer.android.com/reference/android/util/Log.html). To browse system logs on PC you can use ADB utility command: adb logcat.

The notification feature is implemented in our service as the special runnable object. It could be used from the other threads and processes. The service class has method showNotification, which can display message to user using the Toast.makeText call. The runnable object also uses it:

public class NotificationRunnable implements Runnable { private String message = null; public void run() { if (null != message) { showNotification(message); } } public void setMessage(String message) { this.message = message; } }

Code will be executed in the service thread. To execute runnable method we can use the special object android.os.Handler. There are two main uses for the Handler: to schedule messages and runnables to be executed as some point in the future; and to place an action to be performed on a different thread than your own. Each Handler instance is associated with a single thread and that thread’s message queue. To show notification we should set message and call post() method of the Handler’s object.

1.2 IPC Service

Each application runs in its own process. Sometimes you need to pass objects between processes and call some service methods. These operations can be performed using IPC. On the Android platform, one process can not normally access the memory of another process. So they have to decompose their objects into primitives that can be understood by the operating system , and “marshall” the object across that boundary for developer.

The AIDL IPC mechanism is used in Android devices. It is interface-based, similar to COM or Corba, but is lighter . It uses a proxy class to pass values between the client and the implementation.

AIDL (Android Interface Definition Language) is an IDL language used to generate code that enables two processes on an Android-powered device to communicate using IPC. If you have the code in one process (for example, in Activity) that needs to call methods of the object in another process (for example, Service), you can use AIDL to generate code to marshall the parameters.

Service interface example showed below supports only one sendNotification call:

interface INotifyService { void sendNotification(String message); }

The IBinder interface for a remotable object is used by clients to perform IPC. Client can communicate with the service by calling Context’s bindService(). The IBinder implementation could be retrieved from the onBind method. The INotifyService interface implementation is based on the android.os.Binder class (http://developer.android.com/reference/android/os/Binder.html):

public class NotifyServiceBinder extends Binder implements INotifyService { private Handler handler = null; private NotificationRunnable notificator = null; public NotifyServiceBinder(Handler handler, NotificationRunnable notificator) { this.handler = handler; this.notificator = notificator; } public void sendNotification(String message) { if (null != notificator) { notificator.setMessage(message); handler.post(notificator); } } public IBinder asBinder() { return this; } }

As it was described above, the notifications could be send using the Handler object’s post() method call. The NotificaionRunnable object is passed as the method’s parameter.

On the client side we can request IBinder object and work with it as with the INotifyService interface.  To connect to the service the android.content.ServiceConnection interface implementation can be used. Two methods should be defined: onServiceConnected, onServiceDisconnected:

ServiceConnection conn = null; … conn = new ServiceConnection() { public void onServiceConnected(ComponentName name,
IBinder servi
ce) { Log.d(“NotifyTest”, “onServiceConnected”); INotifyService s = (INotifyService) service; try { s.sendNotification(“Hello”); } catch (RemoteException ex) { Log.d(“NotifyTest”, “Cannot send notification”, ex); } } public void onServiceDisconnected(ComponentName name) { } };

The bindService method can be called from the client Activity context to connect to the service:

Context.bindService(new Intent(this, NotifyService.class), conn, Context.BIND_AUTO_CREATE);

The unbindService method can be called from the client Activity context to disconnect from the service:

Context.unbindService(conn); 1.3 Remote service control

Broadcasts are the way applications and system components can communicate. Also we can use broadcasts to control service from the PC. The messages are sent as Intents, and the system handles dispatching them, including starting receivers.

Intents can be broadcasted to BroadcastReceivers, allowing messaging between applications. By registering a BroadcastReceiver in application’s AndroidManifest.xml (using <receiver> tag) you can have your application’s receiver class started and called whenever someone sends you a broadcast. Activity Manager uses the IntentFilters, applications register to figure out which program should be used for a given broadcast.

Let’s develop the receiver that will start and stop notify service on request. The base class android.content.BroadcastReceiver should be used for these purposes (http://developer.android.com/reference/android/content/BroadcastReceiver.html):

public class ServiceBroadcastReceiver extends BroadcastReceiver { … private static String START_ACTION = “NotifyServiceStart”; private static String STOP_ACTION = “NotifyServiceStop”; … public void onReceive(Context context, Intent intent) { … String action = intent.getAction(); if (START_ACTION.equalsIgnoreCase(action)) { context.startService(new Intent(context, NotifyService.class)); } else if (STOP_ACTION.equalsIgnoreCase(action)) { context.stopService(new Intent(context, NotifyService.class)); } } }

To send broadcast from the client application we use the Context.sendBroadcast call. I will describe how to use receiver and send broadcasts from the PC in chapter 2.

1.4 Android Manifest

Every application must have an AndroidManifest.xml file in its root directory. The manifest contains essential information about the application to the Android system, the system must have this information before it can run any of the application’s code. The core components of an application (its activities, services, and broadcast receivers) are activated by intents. An intent is a bundle of information (an Intent object) describing a desired action — including the data to be acted upon, the category of component that should perform the action, and other pertinent instructions. Android locates an appropriate component to respond to the intent, starts the new instance of the component if one is needed, and passes it to the Intent object.

We should describe 2 components for our service:

NotifyService class is described in the <service> tag. It will not start on intent. So the intent filtering is not needed. ServiceBroadcastReceived class is described in the <receiver> tag. For the broadcast receiver the intent filter is used to select system events: <application android:icon=”@drawable/icon” android:label=”@string/app_name”> … <service android:enabled=”true” android:name=”.NotifyService” android:exported=”true”> </service> <receiver android:name=”ServiceBroadcastReceiver”> <intent-filter> <action android:name=”NotifyServiceStart”></action> <action android:name=”NotifyServiceStop”></action> </intent-filter> </receiver> … 2. Java service remote installation and start 2.1 Service installation

Services like the other applications for the Android platform can be installed from the special package with the .apk extension. Android package contains all required binary files and the manifest.

Before installing the service from the PC we should enable the USB Debugging option in the device Settings-Applications-Development menu and then connect device to PC via the USB.

On the PC side we will use the ADB utility which is available in the Android SDK tools directory. The ADB utility supports several optional command-line arguments that provide powerful features, such as copying files to and from the device. The shell command-line argument lets you connect to the phone itself and issue rudimentary shell commands.

We will use several commands:

Remote shell command execution: adb shell <command> <arguments> File send operation: adb push <local path> <remote path> Package installation operation: adb install <package>.apk

I’ll describe the package installation process in details. It consists of several steps which are performed by the ADB utility install command:

First of all the .apk package file should be copied to the device. The ADB utility connects to the device and has limited “shell” user privileges. So almost all file system directories are write-protected for it. The /data/local/tmp directory is used as the temporary storage for package files. To copy package to the device use the command: adb push NotifyService.apk /data/local/tmp Package installation. ADB utility uses special shell command to perform this operation. The “pm” (Package Manager?) utility is present on the Android devices. It supports several command line parameters which are described in the Appendix I. To install the package by yourself execute the remote shell command: adb shell pm install /data/local/tmp/NotifyService.apk Cleanup. After the package is installed, ADB removes the temporary file stored in /data/local/tmp folder using the “rm” utility: adb shell rm /data/local/tmp/NotifyService.apk. To uninstall package use the “pm” utility: adb shell pm uninstall <package> 2.2 Remote service control

To be able to start and stop the NotifyService from the PC we can use the “am” (Activity Manager?) utility which is present on the Android device. The command line parameters are described in the Appendix II. The “am” utility can send system broadcast intents. Our service has the broadcast receiver which will be launched by the system request.

To start NotifyService we can execute remote shell command:

adb shell am broadcast –a NotifyServiceStart

To stop the NotifyService we can execute remote shell command:

adb shell am broadcast –a NotifyServiceStop

Note, that the NotifyServiceStart and NotifyServiceStop intents were described in the manifest file inside the <receiver> … <intent-filter> tag. Other requests will not start the receiver.

Appendix I. PM Usage (from Android console) pm [list|path|install|uninstall] pm list packages [-f] pm list permission-groups pm list permissions [-g] [-f] [-d] [-u] [GROUP] pm path PACKAGE pm install [-l] [-r] PATH pm uninstall [-k] PACKAGE The list packages command prints all packages. Use the -f option to see their associated file. The list permission-groups command prints all known permission groups. The list permissions command prints all known permissions, optionally only those in GROUP. Use the -g option to organize by group. Use the -f option to print all information. Use the -s option for a short summary. Use the -d option to only list dangerous permissions. Use the -u option to list only the permissions users will see. The path command prints the path to the .apk of a package. The install command installs a package to the system. Use the -l option to install the package with FORWARD_LOCK. Use the -r option to reinstall an exisiting app, keeping its data. The uninstall command removes a package from the system. Use the -k option to keep the data and cache directories around after the package removal. Appendix II. AM Usage (from Android console) am [start|broadcast|instrument] am start -D INTENT am broadcast INTENT am instrument [-r] [-e <ARG_NAME> <A

RG_VALUE>] [-p <PROF_FILE>] [-w] <COMPONENT> INTENT is described with: [-a <ACTION>] [-d <DATA_URI>] [-t <MIME_TYPE>] [-c <CATEGORY> [-c <CATEGORY>] …] [-e|--es <EXTRA_KEY> <EXTRA_STRING_VALUE> ...] [--ez <EXTRA_KEY> <EXTRA_BOOLEAN_VALUE> ...] [-e|--ei <EXTRA_KEY> <EXTRA_INT_VALUE> ...] [-n <COMPONENT>] [-f <FLAGS>] [<URI>] Resources used: Android Installation Guide.

http://developer.android.com/sdk/1.5_r2/installing.html

Android Developer reference.

http://developer.android.com/reference/classes.html

Jesse Burns. Developing Secure Mobile Applications for Android.

https://www.isecpartners.com/files/iSEC_Securing_Android_Apps.pdf

Designing a Remote Interface Using AIDL

http://developer.android.com/guide/developing/tools/aidl.html

The development and deployment of Java services for mobile Android

Posted By admin on October 29th, 2011

Written by Igor

Darkov, device software developers to the team, Apriori Inc

In this article, I described:

How simple Java service equipment Android Development How to communicate with other service process and a remote PC, install and start the service remotely from the PC. 1. development of Java services for Android

services are offered in programs long runs in the background of available Android. They could be used for background tasks running. Tasks may be different: the calculations of basic backup procedures, communications, Internet, etc. Services can be started from system queries and they can communicate with other processes with the channels of the IPC Android. The Android system, the life cycle of service based on customer requests, memory and CPU usage. Note that the service is lower priority than any process that is visible to the user.

Let’s develop a simple example of service. We are planning and show the messages the users. Service should communicate using the service request, the simple activity of Android and the PC

First, we are the installation environment and preparation.

download and install the latest Android SDK from the official website (http://developer.android.com) Download and install Eclipse IDE (http://www.eclipse.org/downloads/), we also we need Android Development Tools (ADT) Plugin for Eclipse install.

prepared by the environment, we can create Eclipse Android project. He also sources, resource files and the manifest Android.

1.1 Service-class development

First, we must implement world-class services. It must be inherited by android.app.Service base class (http://developer.android.com/reference/android/app/Service.html). Each service class must be the explanation in his manifesto package. Manifesto statement described below. Services, like other application objects running in the main thread of its hosting process. If you need to work hard, you should do it in a different thread.

In the class of service, we should implement onBind abstract method. We also override other methods:

OnCreate (). It is called by the system when the service is first created. Usually, this method is used to initialize service resources. In our case, the binder, tasks and timer objects are created. Notification is also log the user and the system: public void OnCreate () {super.onCreate (); log.de (LOG_TAG, “Building services”); showNotification (“Creating NotifyService”) binding = new NotifyServiceBinder (Handler, notificator) NotifyTask task = new (Handler notificator) timer = new Timer ();} onStart (Intent intent, int startID). It is through this system, each time a customer begins service explicitly by starting service (the intention), supply the arguments it needs and the unique integer token representing the application launch. We can begin substantive discussions, tasks, plan and execute other operations start. public void OnStart (Intent intent, int startID) {super.onStart (intention, startID) log.de (LOG_TAG, “Starting service”); showNotification (“Starting NotifyService”); timer.scheduleAtFixedRate (task, Calendar.getInstance (.) getTime (), 30000);} OnDestroy (). It is called by the system of notification of a service that is no longer used and removed. We should all operations to complete before serving. In our case, we will stop all the tasks programmed timer. OnDestroy public void () {super.onDestroy (); log.de (LOG_TAG “stop service”); showNotification (“Stop NotifyService”); timer.cancel ();} onBind (Intent intent). It will back channel communication to the service. Ibinda is special interface for an object-based remote measurement, the heart of a light mechanism remote procedure call. This mechanism is necessary for high performance in progress and the process cross. This interface describes the abstract protocol to interact with a remote object capable. The implementation described Ibinda. onBind Ibinda public (for intention) {log.de (LOG_TAG “Service Binding”); return binder;} Register you

problem with the system we are sending static methods of class android.util.Log (http:// developer.android use. com / reference / android / util / Log.html). For some of system logs on the PC, you can ADB Utility Command. logcat Adb

The notification function is implemented in our service, the special object Runnable. It could be used by other threads and processes. The service class has a method showNotification, the message to the user using the call Toast.makeText can be displayed. The Runnable object is used:

NotificationRunnable class implemented public Runnable {private String message = null; public void run () {if (null = message) {ShowNotification (message);}} public void setMessage (String message) {this.message = message;}}

code is executed in the thread service. So we run the Runnable object specific method can be used android.os.Handler. There are two main reasons for using the manager: New runnables schedule and must be performed at no other time in the future, and action can be performed on a different thread of your own body. Each instance manager is connected to a single thread and message queue of this thread. To show warning message and we would call post () method of the object manager .

1.2 CPI Service

Each application runs in its own process. Sometimes you need to pass objects between processes, and call service methods. These transactions may be using IPC. On the Android platform, you can not generally have access to the memory process of another process. So they have their primitive objects that can be understood by the decomposition of the operating system, and “Marshall” subject through the frontier for developers.

The AIDL IPC mechanism is used in Android. It is the basic interface, similar to COM or CORBA, but is lighter. It uses a proxy class to go between the client and the implementation.

AIDL (Android Interface Definition Language) IDL is a language used for code that allows two processes on an Android device to communicate with generate IPC. If you call the code into a process (eg activity), methods of the object in another process (service, for example) needs, you can AIDL on the code to generate the parameters of Marshall.

showed service interface supports only one example below sendNotification call:

interface INotifyService sendNotification {void (String message);}

Ibinda interface for a compatible remote object is used by customers for IPC performed. The customer can contact the service by calling the context bindService (). Ibinda The implementation could be derived from the method onBind. The implementation is based on class android.os.Binder INotifyService interface (http : / / developer.android.com / reference / android / os / Binder.html) listed below:

public class NotifyServiceBinder extends Binder {private Handler handler implements INotifyService = null; notificator private NotificationRunnable = null; Public NotifyServiceBinder (notificator NotificationRunnable handler) {handler = this.Handle; this.notificator notificator =;} public void sendNotification (String message) {if (null = notificator) {notificator. setMessage (message); handler.post (notificator); }} public asBinder Ibinda () {return this;}}

As described above, may send notifications to send the object handler () method. NotificaionRunnable The object is passed as the method.

On the client side, we can Ibinda query object and work with it as the interface INotifyService. To connect to the service interface implementation android.content.ServiceConnection can be used. Two methods must be defined: onServiceConnected, onServiceDisconnected:

conn service connection = null; … conn = new connection service () {public void onServiceConnected (componentName name, Ibinda Service) {log.de (NotifyTest ” “onServiceConnected”); INotifyService s = (INotifyService) try {s.sendNotification Service (“Hello”);} catch (RemoteException ex) {log.de (NotifyTest “,” Unable to send request “, null ex); }}} public onServiceDisconnected (componentName name) {};

bindServic

e method can be called from the business context to reach customer service:

Context.bindService (new Intent (this NotifyService.class) conn Context.BIND_AUTO_CREATE)

unbindService method can be called from the client’s business context, to separate from service

Context.unbindService (Conn.), 1.3 Remote Control Service

emissions are the means to communicate with applications and system components. In addition, we can control the programs on the service from a PC. Messages are sent as intended, and the system supports they are sent, including starting receivers.

Intentions can broadcast receivers are released, so that messages between applications. By registering a broadcast receiver under AndroidManifest.xml (with day ) you can start your receiver class and the application called when someone sends you a program. Activity Manager uses for filters, applications register to find out which program should be used for a particular program.

Let’s development of the recipient, the start-stop and alerting service on request. The base class android.content.BroadcastReceiver be used for this purpose (http://developer.android.com/reference/android/content/ BroadcastReceiver.html):

public class Service extends broadcast receiver broadcast receiver … {private static String START_ACTION = “NotifyServiceStart” STOP_ACTION private static String = “NotifyServiceStop” … public void OnReceive ( background context, the intention of intent) {String action = … intent.getAction () if (START_ACTION.equalsIgnoreCase (action)) {context.startService (new Intent (context, NotifyService.class));} else if (STOP_ACTION.equalsIgnoreCase (action)) {context.stopService (new Intent (context, NotifyService.class ));}}}

To send the name of the application streaming client, we use the Context.sendBroadcast. I will describe how to use the receiver and send mail from PC to Chapter 2

1.4 Android Manifest

Each application must have a file in their root AndroidManifest.xml. The manifest contains essential information on the implementation of Android, the system must have this information before any application code to execute. The main components of an application (its activities, services and broadcast receivers) are activated by intention. An attachment is a set of information (one intentional object) describes a desired action – including data on the class of the element that must perform the action, and other instructions in question are negotiated.. Android locates a suitable component, to answer for, starting the new instance of the item when you need, and passes the object in view

We should be two components to describe our Services:

NotifyService class is described in terms . It does not start on intent. So, the intent of filtering is not necessary. ServiceBroadcastReceived class is described in terms . Receiver Broadcasting the filter object is used to select events system: … Android ‘service enabled = name = ” true “Android Android” NotifyService. “export =” true “> action Android <: name =>” NotifyServiceStart “> android: name = “NotifyServiceStop”> 2.1 Installing Other applications for the Android platform with the special package. APK extension be installed. Android package contains all the needed binaries and manifests.

Before installing the service from the PC, activate the debug option USB Device Settings menu, application development, and connect peripherals to the PC via USB.

From the PC side, we have the utility of the ADB which is available for use directly in the tools Android SDK. AfDB-utility supports several optional arguments for command line provide powerful features, such as copying files to and from the device. The argument command line shell, you can log on phone itself and exit rudimentary shell commands

We will use several commands.

Remote shell command: adb shell ; send operation file: adb push local> path > section <

I describe in detail the installation package will .. It consists of several steps that are executed by the utility of the BAD control Installation:

First, the file APK-package must be copied to the device .. The ADB-utility connects to the device and is limited “shell” privileges. Thus, almost all directories System files are read-only for them. The / data / local / tmp is used as a temporary store for package files. For a copy of the package on the device with the command: push ADB NotifyService.apk / data / local / tmp-install package. utility ADB uses the shell command to perform this particular operation. The “PM” (Package Manager?) Utility is available on Android devices. It supports multiple line parameters command described in Appendix I to install the package itself to run the remote shell command: adb shell clock install / data / local / tmp / cleaning NotifyService.apk. After the package is installed, the ADB deleted the temporary file in / data / local / tmp is stored using the “rm” utility rm shell adb / data / local / tmp / NotifyService.apk. To uninstall the package, use the “Clock” program: (? Activity Manager ) adb shell clock uninstall 2.2 Remote Service Control

start and stop the PC from NotifyService can we “bin” utility that is on the Android device. The command line parameters are described in Annex II. “bin” utility can send the intentions of the transfer system. Our service has a radio receiver, which will be launched by the application of the system

So we start NotifyService can run the shell command remote.

adb shell broadcast a

NotifyServiceStart For NotifyService to stop, we can run the remote shell command:

adb shell am circulate a note that NotifyServiceStop

NotifyServiceStop NotifyServiceStart and intentions in the manifest file within the terms described …. The other requests will not launched receiver

Appendix I AM call (from the Android console) h [list | path | install | uninstall]. Clock package list [f] List of permission groups h clock Permissions list [g] [-f] [-d] [-u] [group] Clock installation path h package [-t] [-r] PATH uninstall the clock [k] The package list packages command displays all packets. Use the-f option to see the file. The list of groups permission command displays all groups Permissions known. The list command prints all authorizations authorizations known or only in the group. Use the option-g to be organized by the group. Use the-f option to print all information. Use the -s option for a brief summary. Use the-d option to list the privileges dangerous. Use the-u option to display only the user permissions to view the list. The path command displays the file path. APK package. The command installs a package to the system. Use the-l option to install the package with FORWARD_LOCK. Use the-r option to reinstall an existing application to obtain their data. Ordering Uninstalling a package removes the system. Use the option-k to the data and cache directories around, according to the package away. Appendix II AM-use (Android console) bin [Home | Order | Instrument] Clock Start-send INTENTION OF INTENT am instrument [-r] [-e ] [-p] [w-end ] is described by: [-a] [-d ] [-t] [-c [-c] …] [-e | - IT ...] [- ez ...] [-e | - AE ; [ ...]- No [] -f] [] Resources used: Installation Guide Android.

http://developer.android.com/sdk/1.5_r2/installing.html

Android Developer Reference.

http://developer.android.com/reference/classes. html

Jesse Burns. Secure Development of mobile applications for Android.

https:

/ / www.isecpartners.com / files iSEC_Securing_Android_Apps.pdf /

Design of a remote interface with AIDL

http://developer.android.com/guide/developing/tools/aidl.html

Samsung Galaxy will be hitting Tab before October

Posted By admin on October 28th, 2011

Samsung Galaxy Tab
New details about the Samsung Galaxy Tab arrived! Tablet will sport two cameras and tout GPS, WiFi, 3G and connect. As for release date, Samsung has commented that it would in reality be released before October! Samsung will have? s TouchWiz interface, and of course to run Android, probably 2.1. Cool is that the feature film works because Android will be able to share content between devices other Galaxy S! You can buy a card Galaxy S? Think about it, but it depends on the expected price tablet? Tell us what you think in the comments!

Via: Samsung Galaxy will be hitting Tab before October
Related Posting Search Result:

Samsung Tab Galaxy Official AT & T, Sprint, T-Mobile and Verizon!
Live At first, Samsung has issued the following press release confirming the Galaxy Tab Samsung will be available in a…

Samsung Galaxy Tab confirmed for all four major U.S. carriers WiFi model only also in the works
Tonight Samsung held a media event in the NYC and announced news we knew back – Galaxy card is routed to al…

Samsung Galaxy Tab – Price and Release Date Found
andlaunchdate We promise you the price of the most talked about Android devices from the moment Samsung Galaxy Tab …

Yepp! Samsung working on Android-based Media Player
Thanks to Bluetooth SIG another listing now know Samsung is prepping a music player from our beloved Android OS….

Samsung announces i5500 “Corby Smartphone” for Italy
Samsung announced their Android-based handset i5500 will be headed to Italy under the aegis of Corby. Corby smartph…

Samsung Behold II upgrade to 1.6, then quit
This is the beleaguered owners of the Samsung II was up in arms last as it became clear that Samsung is not goi…

How to convert video formats Android Phone

Posted By admin on October 20th, 2011

Android phone is famous for many applications, but it only supports video formats relatively little (that supports H.263, H.264 AVC, MPEG-4 SP video format). So what if playback AVI, Xvid, DivX, MKV, WMV, RM, FLV, SWF, ASF, MPG, MOV, MPEG, HD, MTS, M2TS TS and Android on your mobile phone like Samsung i7500 Samsung Galaxy, HTC Hero Legend HTC, HTC HD Desire, Wildfire HTC, Motorola Droid FlipOut, Sony Ericsson Xperia X10, LG and Ally etc.?

If indeed it is very simple, as long as the professional Android Bigasoft Converter Total Video Converter.

be

Bigasoft Total Video Converter, a professional Android Converter can easily convert video format to support Android. Whatever you video formats such as AVI, Xvid, DivX, MKV, WMV, RM, FLV, SWF, ASF, MPG, MOV, MTS, M2TS, TS is the professional Android Video Converter can convert the format of telephone Android video. In addition, the ideal as Android Converter Audio Converter any audio format used for the Android mobile supported audio formats, or convert audio from video and save it as Android mobile supported audio formats.

The following is a step by step guide on how to convert videos to mobile phone Android. This guide is also used to convert audio formats supported Android.

Step 1 Run Android Converter

Download Free Converter Professional Android – install Bigasoft Total Video Converter (Windows version, Mac version) and run

.

http://www.bigasoft.com/total-video-converter.html

Step 2 Importing Video Converter Android

Click on “file “to see your videos you import to play on the Android phone. Or simply drag and drop video Converter for Android.

Step 3 Android mobile phone format

Click the dropdown button on the right side of the “ profile ” to select Android Gphone mobile formats such as MPEG4 ( *. mp4).

Step 4 Customize (Optional)

The ideal Android Converter also provides advanced features to make your video before converting to edit the Android mobile phone video format.

Trim ” is for the clips you want to convert.

cultures ” is for you, cut the black edges of the original movie and video watch in full screen on your Android phone.

“Preference ” function for the output effects, image type, CPU utilization, and measures are put in after conversion is completed.

Settings ” function for the output files parameters such as frame rate, resolution, channels, sample rate, video / audio codec, video / audio bitrates, objects etc.

You can also

in several chapters in a review of “Merge into one file ” on the ground.

You can drag and drop the folder where your video files are in the converter by Android “ Copy folder structure ” on the ground.

You

output converted video in the source, adding that “the source folder output “.

Step 5 Convert video format Android mobile phone

Click on “Start ” to terminate the video format Android.

Step 6 Transfer the converted video file in Android phone

Connect the phone Android PC or Mac, then transfer the converted video on the Android phone.

Tips

What is Android? Android is a mobile operating system Android First Inc., a company Google bought in 2005 developed. Android is an open source platform for mobile phones on the Linux operating system. As the flagship player of the Open Handset Alliance (OHA) Android operating system may be installed by all members of the Open Handset Alliance, including Google, HTC, Dell, Intel, Motorola, Qualcomm, Texas Instruments, Samsung, LG, T-Mobile, Nvidia and Wind River Systems, and other Android phones mehr.Android phones, cell phones, as mobile operating system, including HTC, Samsung, Motorola, LG, Sony Ericsson, Acer Inc. , Garmin, HKC, Dell, Huawei, Lenovo, Pantech, and Android. Normally use the Android phones support H.263, H.264 (in 3GP or MP4 containers) and MPEG-4 SP video format. If you want to play AVI, Xvid, DivX, MKV, WMV, RM, FLV, SWF, ASF, MPG, MOV, MPEG, MPG, HD, MTS, M2TS, TS Android phone, you phone on Android formats such as MP4, convert 3GP.Warum phone Android phone includes various models of phones and phone model is different. But it is also common, the phone Android becoming more competitive telephony applications machen.Android simultaneously, whether to launch applications or system applications from the Android Market. In this regard, Android phone even more competitive than the iPhone OS does provide limited multi-tasking, but allows only native applications such as mail, phone and iPod to run in the background.