Remote Shell

Remote Shell

NEW RED FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
NEW RED FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
Paypal   US $2.99
Orange PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag 3BT
Orange PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag 3BT
Paypal   US $.99
Orange PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2 Button
Orange PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2 Button
Paypal   US $.99
New Style PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
New Style PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
Paypal   US $.99
Cool White PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
Cool White PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
Paypal   US $.99
White PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag 3BT
White PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag 3BT
Paypal   US $.99
Light Blue PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag
Light Blue PEUGEOT CITROEN Remote KEY SHELL Silicone Protective Cover Hold Bag
Paypal   US $.99
White Land Rover Remote KEY FOB SHELL Silicone Anti vibration Protective Cover
White Land Rover Remote KEY FOB SHELL Silicone Anti vibration Protective Cover
Paypal   US $.99
VW SEAT SKODA Folding Flip REMOTE KEY CASE FOB SHELL Silicone Protective Cover
VW SEAT SKODA Folding Flip REMOTE KEY CASE FOB SHELL Silicone Protective Cover
Paypal   US $6.50
Light Blue Silicone Protective Cover Hold Bag for Audi Remote KEY FOB Case Shell
Light Blue Silicone Protective Cover Hold Bag for Audi Remote KEY FOB Case Shell
Paypal   US $.99
Light Blue PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
Light Blue PEUGEOT Remote KEY CASE SHELL Silicone Protective Cover Hold Bag 2BT
Paypal   US $.99
REMOTE KEY SHELL SUITS HOLDEN COMMODORE VS VT VX VY
REMOTE KEY SHELL SUITS HOLDEN COMMODORE VS VT VX VY
Paypal   US $6.32
REMOTE KEYLESS BLANK REPLACEMENT KEY FOB CASE SHELL w PAD FOR FORD 5 Buttons New
REMOTE KEYLESS BLANK REPLACEMENT KEY FOB CASE SHELL w PAD FOR FORD 5 Buttons New
Paypal   US $4.99
Silicone Protective Cover Hold Bag Shell for VW Flip REMOTE KEY CASE FOB orange
Silicone Protective Cover Hold Bag Shell for VW Flip REMOTE KEY CASE FOB orange
Paypal   US $.99
4 Buttons REMOTE KEY PAD CASE SHELL NISSAN Maxima Sentra INFINITI I30 New
4 Buttons REMOTE KEY PAD CASE SHELL NISSAN Maxima Sentra INFINITI I30 New
Paypal   US $1.26
3 BUTTONS REMOTE KEY REPLACEMENT SHELL CASE for TOYOTA Yaris RAV4 Venza Matrix
3 BUTTONS REMOTE KEY REPLACEMENT SHELL CASE for TOYOTA Yaris RAV4 Venza Matrix
Paypal   US $.99
REMOTE KEY CASE Shell for GM BUICK Rendezvous Century Regal Aztek 2 Buttons New
REMOTE KEY CASE Shell for GM BUICK Rendezvous Century Regal Aztek 2 Buttons New
Paypal   US $.90
2 PCS New Battery Back Door Shell Cover for Nintendo Wii Remote Controller White
2 PCS New Battery Back Door Shell Cover for Nintendo Wii Remote Controller White
Paypal   US $.99
Remote Flip Folding Car Key Shell Case For Audi A4 A6 A8 S4 S8 TT 31 Panic
Remote Flip Folding Car Key Shell Case For Audi A4 A6 A8 S4 S8 TT 31 Panic
Paypal   US $11.88
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL YELLOW
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL YELLOW
Paypal   US $5.49
NEW NISSAN KEYLESS REMOTE REPLACEMENT SHELL BUTTON PAD HOUSING CASE FOB CLICKER
NEW NISSAN KEYLESS REMOTE REPLACEMENT SHELL BUTTON PAD HOUSING CASE FOB CLICKER
Paypal   US $5.95
3 BUTTONS REMOTE KEY CASE Shell FOB FOR VW BEETLE GOLF JETTA PASSAT W logo stick
3 BUTTONS REMOTE KEY CASE Shell FOB FOR VW BEETLE GOLF JETTA PASSAT W logo stick
Paypal   US $1.54
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL BLUE
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL BLUE
Paypal   US $6.49
NEW BLACK FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
NEW BLACK FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
Paypal   US $1.99
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL PINK
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL PINK
Paypal   US $5.49
1 PC NISSAN 2 BUTTON REMOTE KEY SHELL CASE ONLY NO REMOTE KEY BLANK
1 PC NISSAN 2 BUTTON REMOTE KEY SHELL CASE ONLY NO REMOTE KEY BLANK
Paypal   US $4.33
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL GREEN
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL GREEN
Paypal   US $5.49
2 BTN Folding Remote Key Shell Case for TOYOTA Land Cruiser Camry Corolla Rav4
2 BTN Folding Remote Key Shell Case for TOYOTA Land Cruiser Camry Corolla Rav4
Paypal   US $9.99
Folding Remote Key Case Shell for 2 Button TOYOTA Corolla Rav4 Yaris Avensis
Folding Remote Key Case Shell for 2 Button TOYOTA Corolla Rav4 Yaris Avensis
Paypal   US $4.99
Folding Remote Key Shell Case for TOYOTA Prado Avensis Echo Avalon Kluger
Folding Remote Key Shell Case for TOYOTA Prado Avensis Echo Avalon Kluger
Paypal   US $10.99
2 BUTTONS BUICK PONTIAC OLDSMOBILE REMOTE SHELL no electronic inside
2 BUTTONS BUICK PONTIAC OLDSMOBILE REMOTE SHELL no electronic inside
Paypal   US $6.99
NEW PINK FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
NEW PINK FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
Paypal   US $2.99
BRAND NEW VOLVO KEYLESS SHELL CASE 4 BUTTON for REMOTE FCCID HYQ1512J 9166200
BRAND NEW VOLVO KEYLESS SHELL CASE 4 BUTTON for REMOTE FCCID HYQ1512J 9166200
Paypal   US $14.99
2x Four Buttons Remote Key Case 4 Toyota Avalon Corolla Camry
2x Four Buttons Remote Key Case 4 Toyota Avalon Corolla Camry
Paypal   US $12.99
2x THREE BUTTONS FORD KEYLESS ENTRY REMOTE KEY FOB SHELL CASE
2x THREE BUTTONS FORD KEYLESS ENTRY REMOTE KEY FOB SHELL CASE
Paypal   US $11.99
NEW Remote Key Case Shell VW BEETLE JETTA PASSAT GOLF Rabbit MK4 MK5 R32 GTI
NEW Remote Key Case Shell VW BEETLE JETTA PASSAT GOLF Rabbit MK4 MK5 R32 GTI
Paypal   US $9.99
NEW BLUE FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
NEW BLUE FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
Paypal   US $2.99
NEW FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
NEW FORD KEYLESS REMOTE CASE HOUSING PAD SHELL KEY FOB REPLACEMENT CLICKER
Paypal   US $1.99
Uncut Remote Blank Blade Key Shell Case For Mazda 3 5 6 RX 8 CX 7 CX 9 MX 5 FOB
Uncut Remote Blank Blade Key Shell Case For Mazda 3 5 6 RX 8 CX 7 CX 9 MX 5 FOB
Paypal   US $25.00
Remote Key FOB Silicone Case Cover VW Volkswagen Orange
Remote Key FOB Silicone Case Cover VW Volkswagen Orange
Paypal   US $9.99
Remote Key FOB Silicone Case Cover VW Volkswagen PINK Fuchsia
Remote Key FOB Silicone Case Cover VW Volkswagen PINK Fuchsia
Paypal   US $9.99
VW Remote Key FOB Silicone Case Cover Volkswagen NEW CHOOSE YOUR COLOR
VW Remote Key FOB Silicone Case Cover Volkswagen NEW CHOOSE YOUR COLOR
Paypal   US $7.50
Mercedes Benz 31 Remote Flip Key Shell Case for 98 05 M CLASS ML
Mercedes Benz 31 Remote Flip Key Shell Case for 98 05 M CLASS ML
Paypal   US $15.99
98 99 00 01 02 NEW AUDI SWITCHBLADE REMOTE KEY CASE SHELL ONLY A3 A4 A6 A8 P4D0
98 99 00 01 02 NEW AUDI SWITCHBLADE REMOTE KEY CASE SHELL ONLY A3 A4 A6 A8 P4D0
Paypal   US $12.99
98 99 00 01 NEW AUDI SWITCHBLADE REMOTE KEY SHELL CASE ONLY A3 S3 S4 A4 2B4D0
98 99 00 01 NEW AUDI SWITCHBLADE REMOTE KEY SHELL CASE ONLY A3 S3 S4 A4 2B4D0
Paypal   US $12.99
BRAND NEW GENUINE NISSAN INFINITI OEM KEYLESS REMOTE CASE SHELL AND BUTTON PAD
BRAND NEW GENUINE NISSAN INFINITI OEM KEYLESS REMOTE CASE SHELL AND BUTTON PAD
Paypal   US $9.99
BRAND NEW GM KEYLESS REMOTE FOB REPLACEMENT SHELL CASE RUBBER BUTTON PAD 4BTS
BRAND NEW GM KEYLESS REMOTE FOB REPLACEMENT SHELL CASE RUBBER BUTTON PAD 4BTS
Paypal   US $7.99
NEW LEXUS SHORT BLADE KEYLESS KEY REMOTE SHELL CASE UNIQUE RED COLOR
NEW LEXUS SHORT BLADE KEYLESS KEY REMOTE SHELL CASE UNIQUE RED COLOR
Paypal   US $5.99
MINI R50 R53 SHELL FREE DIY REPLACEMENT KEYLESS ENTRY KEY REMOTE CASE ONLY
MINI R50 R53 SHELL FREE DIY REPLACEMENT KEYLESS ENTRY KEY REMOTE CASE ONLY
Paypal   US $18.99
NEW VW SWITCHBLADE KEYLESS KEY REMOTE FOB CASE SHELL ONLYBRAND NEW SHELL 4BTS
NEW VW SWITCHBLADE KEYLESS KEY REMOTE FOB CASE SHELL ONLYBRAND NEW SHELL 4BTS
Paypal   US $12.99
31 Button Uncut Flip Remote Car Key Shell Case Blank Blade FOR VW Volkswagen
31 Button Uncut Flip Remote Car Key Shell Case Blank Blade FOR VW Volkswagen
Paypal   US $9.99
New Remote Key Shell Case Fob for TOYOTA RAV4 Camry Corolla Avalon 4 Buttons
New Remote Key Shell Case Fob for TOYOTA RAV4 Camry Corolla Avalon 4 Buttons
Paypal   US $.99
RED Silicone Protective Cover Hold Bag Shell for VW Flip REMOTE KEY CASE FOB
RED Silicone Protective Cover Hold Bag Shell for VW Flip REMOTE KEY CASE FOB
Paypal   US $.99
2x Thre Button Buick Chevy Hummer Isuzu Pontiac Keyless Entry Remote Shell Case
2x Thre Button Buick Chevy Hummer Isuzu Pontiac Keyless Entry Remote Shell Case
Paypal   US $11.88
2x 3 Button Buick Chevrolet GM Yukon Keyless Entry Remote Shell Case
2x 3 Button Buick Chevrolet GM Yukon Keyless Entry Remote Shell Case
Paypal   US $11.88
THREE BUTTONS FORD KEYLESS ENTRY REMOTE SWITCHBLADE KEY FOB
THREE BUTTONS FORD KEYLESS ENTRY REMOTE SWITCHBLADE KEY FOB
Paypal   US $13.88
Three Buttons Buick Chevrolet GM Yukon Keyless Entry Remote Shell Case
Three Buttons Buick Chevrolet GM Yukon Keyless Entry Remote Shell Case
Paypal   US $5.88
2X THREE BTNS REMOTE CASE FOR CHEVROLET AVALANCHE EQUINOX GMC YUKON
2X THREE BTNS REMOTE CASE FOR CHEVROLET AVALANCHE EQUINOX GMC YUKON
Paypal   US $12.99
2X TOYOTA 3 BUTTONS REMOTE KEY FOB CASE FOR FJ LAND CRUISER
2X TOYOTA 3 BUTTONS REMOTE KEY FOB CASE FOR FJ LAND CRUISER
Paypal   US $12.99
NEW FORD REMOTE CASE REPLACEMENT PAD KEY 3 BUTTON SHELL
NEW FORD REMOTE CASE REPLACEMENT PAD KEY 3 BUTTON SHELL
Paypal   US $9.99
10 PCS OF REPLACEMENT BMW 3 BUTTON REMOTE BMW KEY PAD BMW KEY BUTTON KEY SHELL
10 PCS OF REPLACEMENT BMW 3 BUTTON REMOTE BMW KEY PAD BMW KEY BUTTON KEY SHELL
Paypal   US $17.99
TAMIYA 1 14 RC TRUCK TRACTOR TRAILER SHELL GAS TANKER W REMOTE COMPLETE POCHER
TAMIYA 1 14 RC TRUCK TRACTOR TRAILER SHELL GAS TANKER W REMOTE COMPLETE POCHER
Paypal   US $410.00
MERCEDES BENZ REMOTE FLIP CASE FOR 2000 2005 M CLASS
MERCEDES BENZ REMOTE FLIP CASE FOR 2000 2005 M CLASS
Paypal   US $13.99
BRAND NEW HONDA 4 BUTTONS REMOTE KEY SHELL WITHOUT CHIP SLOT
BRAND NEW HONDA 4 BUTTONS REMOTE KEY SHELL WITHOUT CHIP SLOT
Paypal   US $7.77
2X THREE BTNS REMOTE CASE FOR CHEVROLET AVALANCHE GMC YUKON HUMMER H2
2X THREE BTNS REMOTE CASE FOR CHEVROLET AVALANCHE GMC YUKON HUMMER H2
Paypal   US $12.99
BRAND NEW FOUR BUTTON FORD REMOTE SHELL WITH RUBBER PAD
BRAND NEW FOUR BUTTON FORD REMOTE SHELL WITH RUBBER PAD
Paypal   US $6.78
Three Buttons Remote KEY Case for Mitsubishi Eclipse Galant Lancer
Three Buttons Remote KEY Case for Mitsubishi Eclipse Galant Lancer
Paypal   US $6.99
FORD 4 BUTTONS KEYLESS ENTRY REMOTE SWITCHBLADE SHELL CASE
FORD 4 BUTTONS KEYLESS ENTRY REMOTE SWITCHBLADE SHELL CASE
Paypal   US $13.99
SHORT three Button Remote KEY Case for Lexus LS IS LX
SHORT three Button Remote KEY Case for Lexus LS IS LX
Paypal   US $6.99
3 Button FLIP REMOTE KEY SHELL CASE FOR VW Volkswagen JETTA PASSAT GOLF BEETLE
3 Button FLIP REMOTE KEY SHELL CASE FOR VW Volkswagen JETTA PASSAT GOLF BEETLE
Paypal   US $9.99
3 Button Folding Remote Key SHELL Case for PEUGEOT 307 107 207 407 308 408
3 Button Folding Remote Key SHELL Case for PEUGEOT 307 107 207 407 308 408
Paypal   US $10.99
Entry Remote Flip Folding Key Keyless CASE Shell For Mazda 3 5 6
Entry Remote Flip Folding Key Keyless CASE Shell For Mazda 3 5 6
Paypal   US $11.99
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL RED
NEW UNIQUE NISSAN INFINITI REPLACEMENT KEYLESS REMOTE FOB CASE SHELL RED
Paypal   US $5.49
BUICK GMC BUICK PONTTIAC OLDSMOBILE KEYLESS REMOTE SHELL no electronic inside
BUICK GMC BUICK PONTTIAC OLDSMOBILE KEYLESS REMOTE SHELL no electronic inside
Paypal   US $6.99
BUICK CHEVROLET GMC HUMMER 3 BUTTONS REMOTE SHELL no electronic inside
BUICK CHEVROLET GMC HUMMER 3 BUTTONS REMOTE SHELL no electronic inside
Paypal   US $6.99
2 Button Folding Remote Key SHELL Case for PEUGEOT 307 107 207 407 607 1007
2 Button Folding Remote Key SHELL Case for PEUGEOT 307 107 207 407 607 1007
Paypal   US $9.99
BRAND NEW FORD FOUR BUTTONS REMOTE FLIP KEY CASE NO REMOTE INSIDE
BRAND NEW FORD FOUR BUTTONS REMOTE FLIP KEY CASE NO REMOTE INSIDE
Paypal   US $15.99
BRAND NEW FORD THREE BUTTON REMOTE FLIP KEY CASE NO REMOTE INSIDE
BRAND NEW FORD THREE BUTTON REMOTE FLIP KEY CASE NO REMOTE INSIDE
Paypal   US $15.99
2X BUICK CHEVROLET GMC HUMMER 3 BUTTONS REMOTE SHELL no electronic inside
2X BUICK CHEVROLET GMC HUMMER 3 BUTTONS REMOTE SHELL no electronic inside
Paypal   US $13.99
2x GMC PONTIAC OLDSMOBILE 2 BUTTONS REMOTE SHELL no electronic inside
2x GMC PONTIAC OLDSMOBILE 2 BUTTONS REMOTE SHELL no electronic inside
Paypal   US $12.99
LOT 10 NEW VOLVO 3 BUTTON PAD KEY KEYLESS SHELL CASE REMOTES REMOTE REPLACEMENT
LOT 10 NEW VOLVO 3 BUTTON PAD KEY KEYLESS SHELL CASE REMOTES REMOTE REPLACEMENT
Paypal   US $79.00
NEW LEXUS SHORT BLADE KEYLESS KEY REMOTE SHELL CASE UNIQUE LIGHT BLUE COLOR
NEW LEXUS SHORT BLADE KEYLESS KEY REMOTE SHELL CASE UNIQUE LIGHT BLUE COLOR
Paypal   US $5.99
LOT OF 10 BRAND NEW FORD 4 BUTTON KEY KEYLESS REMOTE SHELL CASE BUTTON PAD
LOT OF 10 BRAND NEW FORD 4 BUTTON KEY KEYLESS REMOTE SHELL CASE BUTTON PAD
Paypal   US $14.99
DIY Flip Remote Key Shell Case for Audi A4 A6 A8 Quattro TT UPGRADE 3BTPANIC
DIY Flip Remote Key Shell Case for Audi A4 A6 A8 Quattro TT UPGRADE 3BTPANIC
Paypal   US $13.79
Plasmodium Remote Control Monster Shocker Shell Alien Awesome with remote
Plasmodium Remote Control Monster Shocker Shell Alien Awesome with remote
Paypal   US $5.00
10 PCS VW VOLKSWAGEN SMART REMOTE EMERGENCY KEY BLADE BLANK CASE ONLY KEY SHELL
10 PCS VW VOLKSWAGEN SMART REMOTE EMERGENCY KEY BLADE BLANK CASE ONLY KEY SHELL
Paypal   US $38.99
White Silicone Protective Cover Hold Bag for VW Flip REMOTE KEY CASE FOB SHELL
White Silicone Protective Cover Hold Bag for VW Flip REMOTE KEY CASE FOB SHELL
Paypal   US $.99
Keyless Entry Key Remote Control FOB Shell Case for Ford 4 BUTTON New
Keyless Entry Key Remote Control FOB Shell Case for Ford 4 BUTTON New
Paypal   US $1.04
New Keyless Key Pad Remote Control FOB Shell Case for NISSAN Sentra INFINITI I30
New Keyless Key Pad Remote Control FOB Shell Case for NISSAN Sentra INFINITI I30
Paypal   US $1.10
REMOTE KEY CASE Shell for GM BUICK Rendezvous Century Regal Aztek 4 Buttons New
REMOTE KEY CASE Shell for GM BUICK Rendezvous Century Regal Aztek 4 Buttons New
Paypal   US $.99

Remote Shell

Development and remote installation of Java service for the Android Devices

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:

  1. 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(); }

  1. 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); }

  1. 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(); }

  1. 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 service) { 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> <ARG_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

About the Author

Apriorit is an Ukrainian software development company.

Apriorit develops its own products as well as provide offshore development and QA services in the areas of advanced system programming, driver development, software for devices.

One of the key values of Apriorit's specialists is knowledge generation and sharing of experience.

Learn more about Apriorit and its experience at Apriorit Official site


Remote Shell


Remote Shell


$79.66


High Quality Content by WIKIPEDIA articles The remote shell (rsh) is a command line computer program that can execute shell commands as another user, and on another computer across a computer network. The remote system to which rsh connects runs the rshd daemon. The rshd daemon typically uses the wellknown Transmission Control Protocol (TCP) port number 514. Rsh originated as part of the BSD Unix operating system, along with rcp, as part of the rlogin package on 4.2BSD in 1983. rsh has since been ported to other operating systems. The rsh command shares the same name as another common UNIX utility, the restricted shell, which first appeared in PWB/UNIX; in System V Release 4, the restricted shell is often located at /usr/lib/rsh. As described in the rlogin article, the rsh protocol is not secure for network use, because it sends unencrypted information over the network, among other reasons. Some implementations also authenticate by sending unencrypted passwords over the network. rsh has largely been replaced by the secure shell (ssh) program on untrusted networks like the Internet. Author: Surhone, Lambert M./ Tennoe, Mariam T./ Henssonow, Susan F. Binding Type: Paperback Number of Pages: 116 Publication Date: 2010/09/11 Language: English Dimensions: 6.00 x 9.02 x 0.28 inches

Shell


Shell


$22.99


Shell

CET Domain 10300802 Transparent Shell Skin for Nintendo Wii Remote Controller  Nunchuk


CET Domain 10300802 Transparent Shell Skin for Nintendo Wii Remote Controller Nunchuk


$29.51


Shells which fit Wii Remote Control and Nunchuk perfectly. Transparent and ultrathin. Keeps your Nintendo Wii Controller amp;amp;amp;amp; Nunchuk safe amp;amp;amp;amp; protected. Protect Wii Remote Controller and Nunchuk against scratches dirt and grease caused by everyday use. Unique design allows easy access to all buttons controls amp;amp;amp;amp; ports without removing the skin. CONTENT. 1 x Transparent Shell for Nintendo Wii Controller. 1 x Transparent Shell for Nintendo Wii Nunchuk. Nintendo Wii Remote Controller and Nunchuk not included. This item takes between 721 days to ship/arrive because it ships out of Hong Kong or China.

The Ghost in the Shell 1.5 (Paperback)


The Ghost in the Shell 1.5 (Paperback)


$20.51


Deep into the 21st century, the line between man and machine has been inexorably blurred as humans rely on the enhancement of mechanical implants and robots are upgraded with human tissue. In this rapidly converging technoscape, the covert-ops agents of Section 9 are charged to track and crack the most dangerous terrorists, cybercriminals, and ghost hackers the digital future has to offer. Whether dealing with remote-controlled corpses, lethally malfunctioning micromachines, or cop-killer cyborgs, Section 9 is determined to serve and protect . . . and reboot some cybercrook ass! Ghost in the Shell 1.5: Human-Error Processor presents for the first time in America the &quot;lost&quot; Ghost in the Shell stories, created by Shirow Masamune after completing work on the original Ghost in the Shell manga and prior to his tour-de-force, Ghost in the Shell 2: Man-Machine Interface, but never collected until now.

CK250 - Monte Carlo - CK250 > Remote Controls


CK250 - Monte Carlo - CK250 > Remote Controls


$83.6


Wall / Hand-held Remote Control KitFor fans with manual reverseCanopy installed receiver converts pull chain fan to remote capabilityFeatures:Reverse motor and downlight controlAlmond or White face plates"Clam-shell" design enclosure for use as hand-held optionBattery operated transmitter, no hardwiring required

Car MP3 Player With FM Modulator, Digital Display, Remote Control, SD/MMC-Shell Color


Car MP3 Player With FM Modulator, Digital Display, Remote Control, SD/MMC-Shell Color


$7.99


HighlightsFashionable and novel design, unique appearance Digital display, showing the name of songs, FM channels and work state.Remember the last frequency and music, track and recall them when restarting.206 FM frequencies, Remote control Excellent sound quality for great music experience Audio input/output Power from cigarette lighter socket or DC12V FM Transmitt broadcasting Distance: 5 Metre SD/MMC Slot for SD/MMC Memory Cards USD Connector for USB Flash Disk and mp4/mp3 players File format supported: Mp3 and WMASpecificationVoltage: DC 12VRadio Tuner: FMStation preset qty: 206File Format Supported: Mp3,WmaAudio Source: USB flash disk,SD card,MP3 playerAngle Adjust: NoRemote Control: YesBluetooth: NoBuilt-in microphone: NoWireless Earphone: NoInterface Port: USB,SD Color: Shell colorUnit Dimensions / LxWxH(cm): 9×5.5×5cmNet Weight(kg): 0.04

RC Plasmodium Shell Shocker Robot Remote Control Toy


RC Plasmodium Shell Shocker Robot Remote Control Toy


$112.57


- RC Plasmodium - Go forward and backward / Turn left and right / Spin - It transforms from a cyberball to a cyberbeast in seconds! - Mud, grass, pavement can NOT stop the Plasmodium. - The incredibly adaptability will fascinate kids! - The LED flash lights make the item more beautiful and attractive - The Plasmodium one beast of a radio control vehicle with machinery arms and head armour. - With a back wheel that allows for flipping action and the ability to drive over obstacles - Snap attack tail - Package included: - 1X R/C Plasmodium - 1X 9V Battery - 1X Antenna - 1X Charger - 1X Rechargeable battery

Remote, Uvn800/Boxw Remote , Uv


Remote, Uvn800/Boxw Remote , Uv


$41.99


REMOTE, UVN800/BOXW REMOTE , UV

The Shell


The Shell


$44.99


Odilon Redon The Shell - Giclee Print

Moon Shell Beach


Moon Shell Beach


$11.99


New York Times bestselling author Nancy Thayer delighted readers with her sparkling Hot Flash Club series. Now she has written a vibrant new novel set within a tight-knit island community, where two women struggle to rekindle a childhood friendship damaged by harsh words, betrayal, and the passing years. Lexi Laney and Clare Hart grew up together swimming in the surf, riding remote bike trails, and having wondrous adventures across picturesque Nantucket. And when it was time to share intimate secrets and let their girlish imaginations run free, they escaped to their magical private hideaway: Moon Shell Beach. But nothing stays the same. With the complicated pressures of adulthood, their intense bond is frayed, hurtful words are exchanged, and Lexi flees Nantucket to a life of luxury while Clare stays behind. Ten years later, a newly divorced Lexi returns to make amends with those she left in her wake. Living at home with her father and dating a gorgeous carpenter, Clare still simmers with resentment toward her glamorous friend. And when Lexi opens an upscale clothing boutique next door to Clare&#8217;s chocolate shop, their paths are fated to cross. Their emotional reunion is beset with major challenges: Lexi&#8217;s return sets off a series of startling events that fracture the status quo and set the town gossips&#8217; tongues wagging. And as Clare&#8217;s life takes an abrupt detour, Lexi wonders if the happiness and peace they once knew on Moon Shell Beach will, in the end, prove to be as fleeting as time and the tide. In the turbulent adult world, awash in failed loves and romantic disappointment, can childhood dreams still come true? Irresistible reading, Moon Shell Beach explores the evolution of a tumultuous lifelong friendship, the power of forgiveness, and the rewards of believing in miracles. From the Hardcover edition.

CK300 - Monte Carlo - CK300 > Remote Controls


CK300 - Monte Carlo - CK300 > Remote Controls


$106.4


Reversible Wall / Hand-Held Remote Control KitSwitch housing receiver installation with reverse motion and downlight controlReverse motor and downlight controlAlmond or white face plates"Clam-shell" design enclosure for use as hand-held optionBattery operated transmitter, no hardwiring required.

Leave a Reply

 

wordpress counter