Enabling the Machine-to-Machine Vision
Hundreds of millions of mobile devices now support the Mobile Information Device Profile (MIDP), the most popular profile in the Micro Edition of the Java platform (Java ME). The most common mobile devices comfortably meet or exceed MIDP's requirements for interactive use: a minimum graphical display of 96x64x1, and a simple keyboard or touch screen. There are many kinds of devices, however, that have only a very simple user interface, or none at all: vending machines, alarm systems, routers, elevators, automobile engines, industrial utility meters, and others. These devices, called information modules (IMs), are designed for stand-alone operations. They're becoming intelligent and connected. Imagine a vending machine that can talk to its suppliers and order restocking as needed. Although such devices don't need the display and input mechanisms to support a sophisticated GUI, they do need many of MIDP's other capabilities. To address these requirements, a separate profile has been developed and enhanced within the Java Community Process (JCP). JSR 195, the Information Module Profile (IMP), supports features found in MIDP 1.0, and JSR 228, Information Module Profile - Next Generation (IMP-NG) adds support for features added to MIDP in its 2.0 release. IMP defines the architecture and the associated APIs needed to provide a Java environment for developing IMlets – applications intended to run on networked embedded devices that lack rich interaction capabilities, or whose resources are limited in other ways. This article provides a technical introduction to IMP, describes the profile's architecture and programming model, and provides sample code. In addition, the article identifies kinds of applications that depend on information modules, and discusses some of the wireless modules that support IMP. Contents
Introduction to IMP
JSR 195 defines a profile that's a strict subset of MIDP 1.0. Like MIDP, it's based on the Connected Limited Device Configuration (CLDC). JSR 195's expert group based IMP's original capabilities on MIDP 1.0 rather than MIDP 2.0 because the latter had not yet been finalized when work on IMP began, in October 2002. IMP has inherited key features from MIDP 1.0:
IMP-NG, released in November 2005, was a response to the growing needs of embedded networked devices for the advanced features added to MIDP in release 2.0, principally security enhancements and additional communication protocols. JSR 228 is a strict subset of MIDP 2.0, tailored to the requirements of information modules. The stated goals of IMP-NG were to:
Device Requirements
To help ensure that IMP can address the needs of modems, alarm systems, routers, and other devices with primitive user interaction or none, the IMP expert group has clarified and quantified the definition of "information module," specifying these characteristics:
Even within these specifications, there is a broad range of possible software capabilities. IMP makes minimal assumptions about the information module's system software:
IMP Architecture
To give you a general idea how IMP fits into a device, Figure 1 provides a high-level view of the architecture. Note that not all devices that implement IMP will have all the components you see here, and devices are not required to layer the software as shown.
In this figure, the lowest-level block represents the information module's hardware. On top of that resides the native system software, including the operating system and libraries the device uses. The next layer is CLDC, which comprises the Java virtual machine and associated libraries defined by the CLDC specification. On top of CLDC are two categories of APIs: IMP and OEM-specific. Given the diversity among information module devices, it's impossible for a platform-independent profile like IMP to address all device capabilities fully. To access functionality specific to a given device, developers may need to use APIs provided by the OEM, reducing portability. As a result, there are three types of applications:
IMP APIs
IMP 1.0 inherits five packages from MIDP 1.0:
IMP-NG inherits some additional functionality for networking, in the
IMlets
An IMlet's life-cycle is similar to that of a MIDlet. You even implement it by extending the IMP defines two additional property values that the application must be available to retrieve using the
Just as you package MIDlets in a MIDlet suite, you can package one or more IMlets in an IMlet suite, a single Java ARchive (JAR) file that includes a manifest file describing the contents, a Java Application Descriptor (JAD) file, Java classes for the IMlets, and any resource files used. You'll see a sample manifest and an application descriptor later. Once you've developed some IMlets, you need to deploy them. The IMlet management software handles the retrieval, installation, launching, version management, and removal of IMlets and IMlet suites. A device may support retrieval of IMlets by way of a serial cable, an IRDA port, or a wireless network. Once an IMlet has been retrieved, it will be verified and installed. Then the user can launch it. Developing IMlets
Because IMP is based on MIDP, developers find that their knowledge of MIDP transfers to the IMP sphere easily, and they soon feel at home. An IMP application's starting point is the IMlet class itself, inherited from
The IMlet development cycle too is similar to that of a MIDlet:
Machine-to-Machine Systems
Machine-to-machine (M2M) refers to systems that enable machines such as home devices, vending machines, or utility meters to communicate automatically, without human intervention. In such systems intelligence is embedded in the communicating devices, heralding an equivalent of the industrial revolution for connectivity. IMP provides the core application functionality needed by M2M applications, including network connectivity, local data storage, and application life-cycle management. M2M promises to be a challenging and profitable sphere of business. Solutions are developed by combining contributions of several kinds of players, including system integrators, service providers, mobile operators, and application developers. Example opportunities include:
Wireless modules are the key to the communication that's at the heart of M2M. Not only do they improve existing products, but they increase effectiveness. They help users of M2M systems lower costs by deploying personnel more efficiently, and save time by identifying problems early and reacting immediately. M2M Products
M2M products relying on IMP are on the rise. For example, Siemens offers M2M solutions that include a range of wireless modules that support voice, fax, and SMS transmission based on IMP. These are commonly used for security systems or for remote reading of electricity meters, but can also be found in M2M applications such as fleet management and tracking systems, vending machines, POS terminals, and GSM gateways. Nokia developed the Nokia 12 GSM module to support IMP, along with Serial, I/O, wireless messaging, HTTP, Socket, Whatchdog, and ORB APIs. Nokia has since spun off this product to another Finland-based company, Aplicom. Nokia continues to offer the Nokia 12 IMP 1.0 Concept Simulator, which lets a developer do the initial verification of an application in a simulation environment, before acquiring the actual GSM module. In the next two sections I'll show you how to integrate this simulator into a popular integrated development environment, and how to build an application and test it in the simulator. Integrating the Nokia Simulator With an IDE
You can integrate Nokia's simulator into development environments like JBuilder, Sun One Studio, and the Sun Java Wireless Toolkit, which you can download freely. I tested the simulator in version 1.0.4 of this toolkit. Integration is straightforward:
Using the Nokia 12 IMP 1.0 Concept Simulator
In this section, you'll use the Nokia simulator from the command line to simulate execution of an IMlet. Instructions assume you have downloaded the simulator and installed it in
If all goes well, you will see a dialog similar to Figure 3. Note that the box for output pin 7 is checked.
Conclusion
Machine-to-machine systems will compose a significant sector in the mobility industry as information modules join mobile phones and pagers in the fast-growing world of mobile connectivity and Internet access. Given the tens of billions of machines in the world, the potential for the M2M market is vast, but the only way to remove the barriers to this market is through standardized solutions. The Information Module Profile (IMP) is a major step towards standardization. IMP provides a Java application environment for networked embedded devices with limited capabilities for user interaction, or none. This article provided a quick tutorial on IMP 1.0 and IMP-NG, the IMP programming model, and using the Nokia 12 IMP 1.0 Concept Simulator for IMlet development. For More Information
About the Author
Qusay H. Mahmoud provides Java consulting and training services. He has published dozens of articles on Java technology, and is the author of Distributed Programming with Java (Manning Publications, 1999) and Learning Wireless Java (O'Reilly, 2002). | |||||||||||||||||||||||||||
|
| ||||||||||||