Technical Information Motorola G24 KJAVA User’s Guide JULY 15, 2008 6802981C50-D
SPECIFICATIONS SUBJECT TO CHANGE WITHOUT NOTICE Notice While reasonable efforts have been made to assure the accuracy of this document, Motorola, Inc. assumes no liability resulting from any inaccuracies or omissions in this document, or from use of the information obtained herein. The information in this document has been carefully checked and is believed to be entirely reliable. However, no responsibility is assumed for inaccuracies or omissions. Motorola, Inc.
Trademarks MOTOROLA and the Stylized M Logo are registered in the US Patent & Trademark Office. All other product or service names are the property of their respective owners. ©Copyright 2008 Motorola, Inc.
Table of Contents Manual Scope . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .ix Target Audience . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .ix Disclaimer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Table of Contents Chapter 4: Development and Maintenance. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1 General . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1 JTool Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1 KDWP . . . . . . . . . . . . . . . . . . . . . . . . . . .
Table of Contents Messages Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-3 Java/MMS Session Update. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-3 OTA (Over the Air) Download Trigger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . B-5 Fault Report Addresses Update . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Table of Contents iv G24 KJAVA User’s Guide July 15, 2008
List of Figures 1-1 1-2 2-1 3-1 3-2 5-1 5-2 5-3 E-1 E-2 July 15, 2008 G24 - Basic Module Architecture. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 G24 - KJAVA Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 Evaluation Board - Major Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1 G24 KJAVA Architecture . . . . . . . . . . . . . . . .
List of Figures vi G24 KJAVA User’s Guide July 15, 2008
List of Tables 1-1 2-1 3-1 3-2 4-1 5-1 5-2 5-3 5-4 5-5 A-1 A-2 July 15, 2008 G24 Java Compared to a Handset. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 Evaluation Board Description. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1 KMgr Pin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3 OEM Mode Settings . . . . . .
List of Tables viii G24 KJAVA User’s Guide July 15, 2008
Preface Manual Scope This guide gives an overview of the G24 KJAVA product and its capabilities. Target Audience This guide is intended for G24 KJAVA customers, developers and support groups. Disclaimer Motorola reserves the right to make changes without notice to any of the products or services described herein. "Typical" parameters, which may be provided in Motorola Data sheets and/or specifications can and do vary in different applications and actual performance may vary.
Abbreviations, Acronyms And Definitions Motorola products or services are not designed, intended, or authorized for use as components in systems intended for surgical implant into the body, or other applications intended to support or sustain life, or for any other application in which the failure of the Motorola product or service could create a situation where personal injury or death may occur.
Preface Abbreviation Full Name JAR Java Archive JAL Java Application Loader JPDA Java Platform Debugger Architecture KDWP KVM Debug Wire Protocol Kjava Kilobyte Java KMgr pin KJAVA Manager GPIO pin KVM Kilobyte VM. Java VM for limited systems such as embedded ones Local Clock The unit's clock. This clock may be synchronized with the network or set by the user with the OSC class methods M2M Machine to Machine MIDlet An application that conforms to the MIDP standard.
Applicable Documentation Applicable Documentation [1] Motorola G24 Developer's Guide, Module Hardware Description, at G24-J MOTODEV Web Page [2] Motorola G24 Developer's Guide, Developer's Kit, at G24-J MOTODEV Web Page [3] Motorola G24 Developer’s Guide, AT Commands reference manual, at G24-J MOTODEV Web Page [4] G24-J MOTODEV Web Page [5] Motorola G24-J HMI Display Integration Guide, G24-J MOTODEV Web Page Problem Reporting Instructions Problems or corrections to this guide should be reported to G24 cus
Preface Warning Warning: Presents information to warn you of a potentially hazardous situation in which there is a possibility of personal injury. Important Important: Presents information to help you avoid an undesirable situation or provides additional information to help you understand a topic or concept. Caution Caution: Presents information to identify a situation in which damage to software, stored data, or equipment could occur, thus avoiding the damage. General Safety Remember!. . .
Caring for the Environment Do not service or adjust alone Do not attempt internal service or adjustment unless another person, capable of rendering first aid is present. Keep away from live circuits Operating personnel must: • not remove equipment covers. Only Factory Authorized Service Personnel or other qualified maintenance personnel may remove equipment covers for internal subassembly, or component replacement, or any internal adjustment • not replace components with power cable connected.
Preface Disposal of Motorola equipment in EU countries Please do not dispose of Motorola equipment in landfill sites. In the EU, Motorola in conjunction with a recycling partner will ensure that equipment is collected and recycled according to the requirements of EU environmental law. Please contact the Customer Network Resolution Center (CNRC) for assistance. The 24 hour telephone numbers are listed at http://mynetworksupport.motorola.com Select Customer Network Resolution Center contact information.
Revision History Revision History Manual Number 6802981C50-D Manual Title G24 KJAVA User’s Guide Version Information The following table lists the manual version, date of version, and remarks about the version. Revision History Version xvi Date Issue Remarks A May 15, 2007 Initial Release. B June 21, 2007 Updated due to software updates. C February 15, 2008 Appendix E added (IP Director) due to software updates. Additional minor updates.
Chapter 1: Product Overview Introduction G24 is a GSM/GPRS/EDGE OEM module. It is similar to a condensed cellular phone core, which can be integrated into a communication system to enable the transfer of voice or data information over a cellular network. For a detailed description of the G24 cellular engine refer to reference [1]. This OEM module which once was controlled by an external CPU is now enhanced to be controlled by the customer’s java MIDlet applications running on G24's CPU.
Introduction Figure 1-1 and Figure 1-2 present the differences between basic module architecture and the KJAVA one: Figure 1-1: G24 - Basic Module Architecture Figure 1-2: G24 - KJAVA Architecture Two G24 hardware configurations are available: • OEM - display and keypad are disabled • HMI - display and keypad are enabled Note: These two configurations look identical and can be identified by the model name printed on the units.
Chapter 1: Product Overview A handset, display and keypad can be attached to the EVB. Such an EVB configuration requires the use of an HMI G24 unit. Product Advantages 1. Cheaper & Simpler - No External CPU (the traditional controller). • Java MIDlet controls G24 functionality by running on its own CPU ("On target"), instead of using external controller CPU executing AT commands. • Smaller PCB. 2. Friendly & Flexible - Java Language has rich verity of standard cellular APIs. 3.
Typical Use Case 1-4 G24 KJAVA User’s Guide July 15, 2008
Chapter 2: General Setup Evaluation Board Figure 2-1 shows a G24 unit, display and SIM card mounted on the evaluation board (EVB) and other major EVB components. Table 2-1 gives a description of the components. Figure 2-1: Evaluation Board - Major Components Table 2-1: Evaluation Board Description No. July 15, 2008 Reference Designator Description 1. J210 Wall adapter supply connector 2.
Evaluation Board Table 2-1: Evaluation Board Description (Cont.) Reference Designator No. Description 3. D200 Main power supply indication LED 4. J380 USB Mini-B Connector 5. J300 RS232-1 Connector 6. J330 RS232-2 Connector 7. J350 RS232-3 Data Logger Connector 8. J430 Speaker Connector 9. J460 Microphone Connector 10. J440 Headset Connector 11. J480 Alert speaker Connector 12. - Keypad and Display 13. - G24 14. J100 SIM card Tray 15.
Chapter 2: General Setup Power Supply Installation 1. The supplied wall adapter includes a North-American type electrical plug, with optional adapter for European wall sockets. Connect the supplied wall adapter (1), or connect the power supply via the DC supply jacks. Note: • When using a DC supply, set its voltage level to 3.6V-4.2V, and its current limiting to 2.5A. • Use the power supply source selection jumper (P204 and P203) to activate either of the power supply sources.
Software Configuration Software Configuration G24 KJAVA has several GSM models available: • Dual Band Europe • Dual Band USA • Quad Band • Quad Edge Software Version User should use the following versions and up: G24: G24_G_0C.11.B2R. DM: DM_20_11_07.hs - version 2.2.3 Available Memory Flash: 10 MB - Jar file and all data saved by MIDlet (RMS, File System). RAM: 1.8 MB - Heap size. USB PC Driver USB PC driver can be found in: http://developer.motorola.
Chapter 2: General Setup MIDlet Downloading Serial (UART2) Downloading a MIDlet via serial communications can be done using two different applications. The first is a multipurpose tool developed alongside the G24, called "Jadpur". The second is a Motorola Java loader application tool called "MIDway". Both tools are available in MOTODEV website [4]. Jadpur Setup Stages: Note: Jadpur requires MS .NET framework installed on your PC. 1. Connect G24 UART2 to PC COM via RS232 cable. 2.
Software Configuration 2. Triggering an OTA download from the DM. Common Errors 1. Attributes common to JAR manifest and JAD are not identical. 2. The MIDlet-JAR-Size attribute field does not contain the correct JAR size in bytes. 3. Wrong JAD attributes: MIDlet-Name must be "UserMIDlet" (case sensitive). MicroEdition-Configuration should be CLDC-1.1. MicroEdition-Profile must be MIDP-2.0. 4. Untrusted MIDlet trying to replace trusted MIDlet (resolution: trusted MIDlet must be deleted first).
Chapter 3: KJAVA Architecture General The G24 KJAVA product runs one of the following two types of MIDlets: User MIDlet (UM) The UM is the customer's MIDlet which controls the G24 to its needs. The UM is the core concept within the G24 Java module. It lets the customers to run their own code on the G24's CPU.
Functional Description Functional Description G24 KJAVA module has three entities: • MIDlet Manager - Manages and executes the MIDlet. • JTool Manager - Manages G24 maintenance • JAL • G24 SW reflash • KDWP activation • Module configuration • OTA download Manager - Over The Air MIDlet download procedure The handshake between these three entities, controlling the G24, is shown in Figure 3-1. These three entities are mutually exclusive, i.e.
Chapter 3: KJAVA Architecture KMgr assigned pin depends on the hardware configuration (OEM or HMI) as described in Table 3-1. Table 3-1: KMgr Pin G24 HW Type Pin Number in 70 Pin Connector GPIO Pin Name EVB Switch OEM 42 GPIO8 S120, GPIO8 reference HMI 16 WKUPI_N/GPIO16 S100 WKUPI_N Also refer to“GPIO Lines”and reference [2]. Switching between MIDlet Manager and JTool Manager without GPIO Pin Toggling Switching between MIDlet Manager and JTool Manager can also be done using dedicated commands.
MIDlet Manager MIDlet Manager The MIDlet Manager manages and executes the MIDlet. It is activated when KMgr pin is ON. MIDlet Manager executes UM if it exists and valid, otherwise it executes the DM. In case DM is invalid too, MIDlet Manager will move to "Fault" state (reports can be observed via AMS logs mechanism) - waiting for MIDlet upgrade via JTool commands. When MIDlet exits by invalid operations, it is marked with "Invalidity flag".
Chapter 3: KJAVA Architecture JTool Manager JTool Manager enables users to communicate with the G24 KJAVA module via RS232 over UART2 using a set of predefined commands (refer to “Default RS232 Configuration”). JTool Manager functionality: 1. Downloading a MIDlet via Jadpur or MIDway. 2. Reflashing of G24 software. 3. KDWP activation. 4. Module configuration.
OEM Modes OEM Modes The G24 unit has three functional modes (OEM modes): 1. Java - Only MIDlet controls the unit. 2. Partial Java - The unit is controlled by MIDlet and a limited set of AT commands. 3. AT - Only AT commands control the unit (KJAVA module is disabled). OEM modes can be controlled by the OSC class. For OEM mode settings see Table 3-2. Table 3-2: OEM Mode Settings OEM Mode API Connectivity availability JAVA OSC.setProperty("oem.
Chapter 3: KJAVA Architecture There are two types of commands. "Type 1" consists of permanently blocked commands and "Type 2" consists of configurable blocked commands (can be reconfigured to be unblocked). Configuration is done on the entire list and by Motorola only.
MIDlet Security MIDlet Security This paragraph describes the MIDP 2.0 Security Model for the Motorola G24 KJAVA product. Two types of MIDlets can be downloaded into the G24: “Untrusted” (Unsigned) or “Trusted” (Signed). Security modes: MIDlet may run in one of two security modes: • Normal mode (Trusted domain) - Full access is granted to all APIs • Safe mode (Untrusted domain) - Limited access to API. Any access to a protected API will be blocked and an exception will be thrown (java.lang.
Chapter 4: Development and Maintenance General The following log types are available: AMS logs - Issued by unit components (AMS, KVM, and Native Code) MIDlet logs - Issued by running MIDlet (stdout) JTool Commands JTool commands enable external communication to G24 KJAVA module over serial connection (See “JTool Manager”section for more information). When switching to JTool, running MIDlet is stopped.
JTool Commands Table 4-1: JTool Commands (Cont.) Subject UART's Baud Rate Log Routing JTool commands Action OEMconfig_BaudRead:X Read baud rate for serial X OEMconfig_BaudDefaultSet:X,Y Set default baud rate Y for UART X OEMconfig_BaudDefaultRestore:X Restore default baud rate for UART X OEMconfig_BaudSet:X,Y Set baud rate Y for UART X for the current session.
Chapter 4: Development and Maintenance Table 4-1: JTool Commands (Cont.) Subject Clear invalidity flag JTool commands OEMconfig_clearFlag:UM Action Clear UM invalidity flag (for debug purposes) Notes See see“KJAVA Architecture” for additional information.
KDWP KDWP KDWP is used for MIDlet "on target" debugging. Its "Debug agent" (PC application) communicates with the target’s KVM over RS232 (A serial connection must be set between G24 UART2 and PC COM). Only UART2 can be used, therefore Serial Logs should be routed to UART1, USB or disabled. IDE application must be JPDA (Java Platform Debugger Architecture) compliant to be able to attach to "Debug agent". Known JPDA compliant IDEs are: NetBeans, Eclipse and JBuilder.
Chapter 5: JAVA API KJAVA Content The APIs available in G24 KJAVA product are listed in Table 5-1. Table 5-1: Motorola API Matrix G24 APIs Description JSR’s CLDC 1.1 Infrastructure MIDP 2.0 UI, RMS, Connections, Basic Audio COMM Connection Logical serial port connection WMA 1.1/2.0 SMS, MMS 120,205 MMAPI 1.
Packages Overview Packages Overview For detailed package usage information refer to Javadoc. Access Package Package name: com.motorola.oem.access The Access package provides these SIM card services: 1. SIM card status: indication and query. 2. SIM PIN1: • Lock utility - enable/disable and query status • Unlock • Change Code Note: • Enabling/ Disabling Lock utility will take effect after next power cycle. • Unlocking is valid until next power cycle.
Chapter 5: JAVA API Some network indication response require user's action (example: password for barring). For each transaction response a required-action code will be attached. Possible action codes: • Further user action required - session continues, the MIDlet should follow with a new MO transaction. • No action needed - session is closed. Some indications, sent by the network are Network Initiated messages.
Packages Overview OSC System Properties The OSC system properties are listed in Table 5-2. Table 5-2: OSC System Properties Property name Description Possible values Default value Available for get/set method oem.lastfault.running UM/DM Last run fault information. NA NA Get oem.lastfault.panic Last panic information. NA NA Get oem.lastfault.ota Last OTA fault information. NA NA Get oem.lastfault.reportaddre ssX Report destination address (X: 1 to 3).
Chapter 5: JAVA API Note: • USB device connected to G24 will prevent unit from entering sleep mode. • If data (Serial Logs or Comm Connection) is not being read by external device (remains in UART1 or UART2 buffers) G24 will not enter Sleep Mode. • To reduce power consumption to minimum, Kmgr pin time sample (polling) should be reduced respectively. Use setProperty("oem.kmgrpin.timesample",XXX).
Packages Overview Measurements The G24 KJAVA module supports measurements of antenna presence, battery level and temperature. Battery All available range of battery voltage - from 3200 mV to 4200 mV is broken on pre-defined levels according to the table below:. Level Battery Voltage 5 3700 - 4200 4 3500 - 3700 3 3400 - 3500 2 3350 - 3400 1 3300 - 3350 0 3200 - 3300 (Low battery) Notification will be sent if average value of battery voltage crosses to new range.
Chapter 5: JAVA API Temperature Temperature measurement is mapped from 0-255 A2D units to Celsius.
Packages Overview A temperature level approximation can be obtained using the following 5th order polynomial formula: Temp [C] = A5* ADCp5 + A4* ADCp4 + A3* ADCp3 +A2* ADCp2 +A1* ADCp1 +A0 A5 = -1.3e-09, A4=8.91591e-07, A3=-0.00024, A2=0.032894, A1=-2.56084, A0=103.2997 • ADCpN means ADC value powered by N • XeY means X*(10 powered by Y) Figure 5-1: Actual Temperature Level (in degrees Celsius) Antenna Presence Antenna presence measurement reports whether antenna is attached or not.
Chapter 5: JAVA API Once it is activated, the platform sends events every 10 seconds that can be caught by OSCWdogListener interface implementer. This will allow the MIDlet to kick the watchdog timer (by calling KickMIDletWatchdog) without maintaining its own Timer mechanism. Note: The watchdog default state is not active. WebSession Package Package name: com.motorola.oem.websession Web Session is a collection of parameters which configure and manage the Internet connection (GPRS, MMS).
Packages Overview AUTH_METHOD_USERNETWPIN, AUTH_METHOD_USERPIN, and AUTH_METHOD_USERPINMAC. The following table describes the 3 predefined (reserved) web session entries: Web Session Name Web Session Name Web Session Index Java Session "Java Session" SESSION_INDEX_JAVA Mms Session "Mms Session" SESSION_INDEX_MMS Prov Session "Prov Session" SESSION_INDEX_PROV Note: Prov Session is read only. See Table 5-4 for Web Session Parameters.
Chapter 5: JAVA API Table 5-4: Web Session Parameters (Cont.) Web Session Parameter Sub Parameters Parameter Description CSD 1/2 Phone Number User Name Password Speed Line type CSD session 1 and 2 configuration GPRS APN User Name Password GPRS session access parameters Possible values Speed Baud rates available: 2400, 4800, 9600,14400 Line type available: Modem, Isdn Default value Speed: 14400 Line type: Modem null HAPI Package Package name: com.motorola.oem.
Packages Overview platform Set GPIO counter Counter++ Java Midlet Notify java VM Is counter expiry? YES NO Figure 5-2: GPIO Counter Mechanism Interrupt and Counter performance 1. Interrupt latency - notification to UM. • Idle - 10 ms. • While HTTP download session - 15 ms. • While UDP download session - 20ms. Note: For both HTTP and UDP, thread yielding must occur. See “GPIO Interrupt Latency” for more information. 2. Counter frequency: • Idle - 2 KHz. • While HTTP download session - 500 Hz.
Chapter 5: JAVA API b. Notifications: both edges. c. Counter: cyclical. d. Counter expiry: 50 pulses. 5. GpioCounter - Service methods for GPIO counter. Actions: Read and reset counter. A2D API A2D API is responsible for configuring and handling the 3 external A2D converters, pins: 37, 43 and 47. Converter values are between 0 to 255 unit ranges, representing 0-2.3 Volt. Automatic notifications: 1. Periodical - cyclically with pre-defined period. 2.
Packages Overview A2D Classes 1. A2dManager - Manages the access to A2D converters. 2. A2dChannel - A2D converter configuration and notification (access to A2D value, Enable/Disable notification). 3. A2dAutoPeriodConfig - A2D period notification container, default period is 4 sec. 4. A2dAutoThresholdConfig - A2D threshold notification container. Default value for "low limit range" - 50 to 60 and "high limit range" - 190 to 200. Call Package Package name: com.motorola.oem.
Chapter 5: JAVA API I2C default configuration: After opening I2C connection, its default configuration will be: Bus mode: Single master. Data rate: Standard. Device address type: 7 bits. Register address length: 0 byte. Start Type: start bit. Receive start bit enabled: True. Receive stop bit enabled: True. I2C performance: • Data rate 1. I2C support standard mode - up to 100 Kbit/s. 2. G24 I2C bus effective data rate is 80 Kbit/sec. 3.
Packages Overview 2. NACK - in case it is not the first byte transfer on the bus. • For known issues, please refer to G24-J Customer Notes. IPD Package Note: For detailed information regarding IPD, see “IP Director”. Package name: com.motorola.oem.ipd com.motorola.oem.ipd package enables the UM to utilize the IP Director feature, to establish local socket connection over the serial link with an external device.
Chapter 5: JAVA API Standard Classes Deviations Comm Connections Package: javax.microedition.io.CommConnection. Description: Handling serial connection. Three parallel serial ports are available: UART1, UART2 and USB. See Table 5-5 for Port to Serial mapping. Table 5-5: Port to Serial Mapping Port Identifier Serial COM0 UART2 COM1 UART1 COM2 UART2 COM3 USB Server Socket Connection Package: javax.microedition.io.ServerSocketConnection. Description: Handling listen TCP/UDP socket. Deviations: 1.
Standard Classes Deviations while (true) { int len = is.read(ReceiveData); if (len > -1) { //receive data System.out.println("Receive data - " + new String(ReceiveData) + "\n"); System.out.println("Number of bytes - " + len + "\n"); } else if (len == -1) { //connection with client has been broken. openConnection(getAppProperty("PORT")); } } } catch (IOException e) { ... } } private void openConnection(String port) { try { //create ServerSocketConnection instance scn = (ServerSocketConnection) Connector.
Chapter 5: JAVA API Message Connection Package: javax.wireless.messaging. Default SMS Port API. All regular incoming SMS (without destination and source port) will be redirected to a special, default MT port; • Destination port - 6024 • Source port - 49153 In order to be able to get this kind of SMS, MIDlet should listen on port 6024 using JSR120. MIDlet Messages are stored in a separate JSR120 Inbox folder (up to 26 messages).
Standard Classes Deviations Initialization of a GPS Device The GPS device should be initialized before usage, in order to wake-up in the periodical broadcasting NMEA mode. The special commands in binary format could be sent using Comm Connection APIs. It could be @@Oi, @@OF, @@Oa, @@Oj, @@Ot, @@Oa configuration commands for basic GPS initialization and $PMOTG commands to assign NMEA format for broadcasted messages. These commands may be different for different GPS types.
Chapter 5: JAVA API Parameters in square brackets are optional. If an optional parameter is omitted, the default value will be set. The following table shows the possible parameters values: Parameter Description Port setting Default Value Possible values Comm.. UART number. "com1", "com2" N/A baudrate UART speed.
Standard Classes Deviations // display location results coordinates = location.getQualifiedCoordinates(); float altitude = coordinates.getAltitude(); double latitude = coordinates.getLatitude(); double llongitude = coordinates.getLongitude(); Example of Periodical Listening for Location Update in Java MIDlet: // Set criteria for selecting a location provider: // accurate to 500 meters horizontally Criteria criteria = null; criteria = new Criteria(); criteria.
Appendix A: GPIO Lines Pin assignment details for G24 KJAVA module GPIO lines are listed in the following tables. Note: 1. 2. 3. 4. GPIO 1-8 can be accessed via EVB switch S120. Pin dedicated for Java Tool is marked yellow. GPIO13 must not be grounded at power up. If GPIO direction is input and line is not connected, its state will be defined according Initial value. 5. If GPIO direction is output, "Floating" state is not available. Initial state depends on initial configuration.
Table A-1: Java Module GPIO Lines, OEM Units (Cont.) 70 Pin Conn. Pin No. G24 Signal Java Signal Input Internal resistor (Pull Up) Initial Value Default Direction Direction Counter Interrupt 19 DTR_N GPIO14 100k 1 I/O I Y Y 17 DCD_N GPIO15 100k 1 I/O O Y Y 16 WKUPI_N (EVB S100) GPIO16 22k 1 I/O I Y N Table A-2: Java Module GPIO Lines, HMI Units 70 Pin Conn. Pin No.
Appendix B: Default MIDlet Features Supply Of All Available Unit Information DM outputs all available unit information to the standard output. If it's an HMI unit, information is printed to the screen as well.
CQA Testing Routines Handler The following table shows report types: Report Type Report Address Report Address Example Description File file file A text file containing a detailed report in XML format is saved in the file system under "file:///c/mobile/kjava/" folder. Three fault reports may be saved, named "fault_report.xml", where "fault_report1.xml" is the most recent and "fault_report3.xml" is the least recent.
Appendix B: Default MIDlet Features SMS Updates / Requests Listener The DM starts an SMS listener which allows updates and requests to be sent to the unit. The SMS sent to this listener must meet a specific format. Upon initialization, the DM reads the OSC property "oem.dm.smslistener", if set to "on", which is the default value, it starts listening to SMS messages. To turn off the listener set the property to "off". Using these messages, updates and requests can be sent to the unit.
SMS Updates / Requests Listener Message fields are given in the table below: Description Field String Action to be performed (Update "Java Session" or "Mms Session" web sessions) action Homepage homepage Service Type 1 service1 Proxy 1 proxy1 Port 1 port1 Domain 1 domain1 Service Type 2 Service2 Proxy 2 proxy2 Port 2 port2 Domain 2 domain2 DNS 1 dns1 DNS 2 dns2 Timeout (minutes) timeout CSD No. 1 csd1 CSD No. 1 User Name csduser1 CSD No.
Appendix B: Default MIDlet Features Description Field String Valid Values CSD No. 2 csd2 CSD No. 2 User Name csduser2 CSD No. 2 Password csdpass2 Speed (Bps) 2 speed2 • • • • Line Type 2 line2 • modem • isdn GPRS APN apn GPRS User Name gprsuser GPRS Password gprspass Notes 2400 4800 9600 14400 Default value is modem Example: Update the Java Session action:java session homepage:http://www.domain.com/directory/midlet.
SMS Updates / Requests Listener Example 2: Download, install and run the MIDlet found at http://www.domain.com/directory/midlet.jad action:ota url:http://www.domain.com/directory/midlet.jad Fault Report Addresses Update This message updates the fault report addresses of the unit.
Appendix B: Default MIDlet Features Ping This message is used to verify if the unit is working. When the DM receives this message, it returns a message to the sender containing the text "Ping (Motorola Wireless Modules)". Message fields are given in the table below: Description Action to be performed: Ping the unit Field String action Valid Values fping Notes This field defines the message type. This is a mandatory field. Example: Ping the unit.
SMS Updates / Requests Listener B-8 G24 KJAVA User’s Guide July 15, 2008
Appendix C: GPIO Interrupt Latency Introduction In order to achieve minimal average interrupt latency (HW I/O to Java) one should understand JVM limitation, and how to manipulate code accordingly. Java VM provides limited RT abilities. Programming in a multithreading environment while trying to ensure strict RT scheduling, is an impossible mission.
Code Example • Thread.yield() This method enforces current thread to give up the CPU resource. In order to create minimal average interrupt latency, one should set interrupt thread (NativeExtEventThread) priority to the maximum level, other threads to the lower one and limit those threads execution time by using yield function (if not used, interrupt thread can be delayed for a significant amount of time: 40-50 milliseconds).
Appendix D: MIDlet Signing General There are two types of MIDlet signing: • Generic signing • Bound signing Generic Signing Generically signed MIDlet can be downloaded to all G24 units. Once a MIDlet is tested and ready for deployment to production, it will be generically signed. Only the manufacturer (Motorola Wireless Modules) can generically sign a MIDlet. To request a generic signature, refer to M2MCare@motorola.com. Bound Signing Bound signed MIDlet can be downloaded to a specific G24 unit.
Bound Signing 5. Send the "example.csr" file created in step 2 and the "G24_Bound_Cert_Request_Form_182-1.doc" created in step 4 to M2MCare@motorola.com. You will receive from Motorola a bound certificate within a few days. 6. Upon receiving the "Bound Certificate" (.crt) file from Motorola, you should create a directory for G24 in the following location: C:\BOUND_Certificate\cert\G24. 7. Place the "Bound Certificate" (.
Appendix E: IP Director Using The IPD Feature The external device will trigger the IPD state changes via a serial connectivity. There are two applicable java modes for the IPD: 1. Partial java mode 2. 2. Partial java mode 3. See OSC.setProperty("oem.mode", ). IPD Configuration Configurable parameters are: 1. UM fixed IP - the MIDlet will be assigned a fixed IP by the IPD. 2.
IPD Activation IPD Activation The External device will generally have to establish a PPP link over serial, in order to activate the IPD. This can be done in one of two ways: 1. With GPRS Issue ATD*99# command and establish PPP link (GPRS dialup). In this case the cellular network will assign an IP address (IP4 in the figure below) to the external device. External device may communicate with outside world Internet and the UM using the same PPP link.
Appendix E: IP Director IPD Deactivation One of the following actions will deactivate the IPD: 1. External device terminated PPP by sending LCP-Terminate message. 2. External device dropped DTR line. This will drop the PPP link in both cases (with and w/o GPRS) and will restore serial to AT command mode. The MIDlet is notified of the IPD new state by the IpDirectorAvailabilityListener. From this point on, the External device <--> MIDlet IP connection (local socket service) is unavailable.
OTA (Over The Air) Over Serial PPP Link E-4 G24 KJAVA User’s Guide July 15, 2008
MOTOROLA and the Stylized M Logo are registered in the US Patent & Trademark Office. All other product or service names are the property of their respective owners. ?Copyright 2007 Motorola, Inc. Java? Technology and/or J2ME? : Java and all other Java–based marks are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries. UNIX? : UNIX is a registered trademark of The Open Group in the United States and other countries.