Writing Your First MIDlet Running JAVA on a Cell Phone Jon A. Batcheller January 27, 2004.

Slides:



Advertisements
Similar presentations
MIDP Mobile Information Device Profile Johnny Yau CIS 642 Prof. Insup Lee.
Advertisements

Java 2D Training. Basic Tools Java SDK 1.4x Wireless Toolkit 2.x NetBeans IDE + mobility pack Global Code editor Text Comparer Tools Graphics Editor Sprite.
Presentation 11: SOAP on small devices. Ingeniørhøjskolen i Århus Slide 2 af 14 Outline Which small devices? What are the limitations and what kind of.
Pengantar Teknologi Mobile 12
Introduction of J2ME Mobile solutions. Overview What is J2ME. How does J2ME work? Java J2ME Carriers and Products. The Two Configuration of J2ME. Profiles.
Multimedia Network Communications Subject:T0934 / Multimedia Programming Foundation Session:13 Tahun:2009 Versi:1/0.
J2ME 25 July Overview  What is J2ME?  The CLDC and CDC configurations  MIDP and MIDlets  Development Tools  Demonstrations.
UNDERSTANDING JAVA APIS FOR MOBILE DEVICES v0.01.
Introduction to Java 2 Micro Edition Mark Balbes, Ph.D. Senior Software Engineer Jeff Brown Senior Software Engineer.
Programming Handheld and Mobile devices 1 Programming of Handheld and Mobile Devices Lecture 10 Java for MIDs Rob Pooley
Java2 Platform Micro Edition (ME) Benedek Balázs
Quality Assurance and Testing of J2ME Programs for Mobiles Phones.
Developing an Application with J2ME Technology Scott Palmer, Nat Panchee, Judy Sullivan, Karen Thabet, Sten Westgard.
J2ME RMI 1 Java 2 Platform, Micro Edition Implementation of J2ME RMI Application Farooq Sheikh.
Interactive Visual System By Arthur Evans, John Sikorski, and Patricia Thomas.
J2ME for Palm Speaker: Chen-Nien Tsai Adviser: Kai-Wei Ke.
Introduction to Mobility Java Technology Mobile and Wireless Networks.
Developing Software for Wireless Devices
J2ME Prepared by: - Gaery- Ronny - Alan- Andy. Why Technology for Mobile Devices? The nature of wireless devices is changing Old devices: All the software.
Presenting a Technical Paper. Outline Wireless Development – Introduction Wireless Development – Introduction Wireless Issues & Considerations Wireless.
PDA Programming Using J2ME Presenter :涂俊凱 Date : 2003/4/8.
Making Cell Phone Games An Overview Ray Ratelis Guild Software, Inc.
Developing J2ME Applications Mobile and Wireless Networks.
The 21th century Repairman Agenda Introduction J2EE J2ME Demonstration.
Cosc 4730 Phone Programming in Java An Introduction.
Java 2 Micro Edition Mano Chen Senior Technical Consultant
Java Platform, Micro Edition (J2ME)
Java 2 Platform, Micro Edition (J2ME) By Xiaorong Wang.
J2ME and WAP Technologies CSCI – Independent Study Fall 2002 Presented by: Kashif Syed.
01 Introduction to Java Technology. 2 Contents History of Java What is Java? Java Platforms Java Virtual Machine (JVM) Java Development Kit (JDK) Benefits.
LESSON 1 INTRODUCTION Compiled By: Edwin O. Okech [Tutor, Amoud University] JAVA PROGRAMMING.
J2ME -Kushal Modi(09BIT056).
Topics on KVM Presented By Xiaozhou David Zhu. Topics covered Introduction Java2 Platform Micro Edition CLDC KVM.
Android Introduction Platform Overview.
EclipseME Java Micro Edition The Eclipse Way Craig Setera April 19, 2006.
J2ME Java for Mobile Environments Based on J2ME In A Nutshell, by Kim Topley, O’Reilly & Associates Inc., 2002, and Tetris by Alexei Patinov.
An Introduction to the Java ME Project Jens A Andersson.
Programming Handheld and Mobile devices 1 Programming of Handheld and Mobile Devices Lecture 12 Using the KToolbar Rob Pooley
Platforms and tools for Web Services and Mobile Applications J2ME based Applications Bent Thomsen Aalborg University 3rd and 4th of June 2004.
Getting Started with JXTA for J2ME Advisor : Dr. Ching-Long Yeh Report : DI.2, 洪泰昌 ( ) Course: XML 文件管理.
Michael Brockway Advanced Applications Development in Java J2ME -- Introduction l Introduction / Overview l Java 2 Micro Edition n CLDC n MIDP l Examples.
Programming Handheld and Mobile devices 1 Programming of Handheld and Mobile Devices Lecture 11 J2ME and MIDlets Rob Pooley
Mobile Applications with Java ME & BlackBerry. Overview Java ME –Networking –Databases Java ME and the BlackBerry –The BlackBerry wireless device –Converting.
Mobile Applications and Java ME
Framework and application bytecode size CLDC MIDP kXML parser Utility classes Graphics Logic (MIDlet) Application Data (XML file)
Computer Science Wi-Fi App using J2ME and MVC Architecture Advisor : Dr. Chung-E Wang Department of Computer Science Sacramento State University Date:
J2ME Presented by May Sayed & Menna Hawash. Outline Introduction “Java Technology” Introduction “What is J2ME?” J2ME Architecture J2ME Core Concepts 
Java 2 Micro Edition (J2ME) and the world of java
PROG Mobile Java Application Development PROG Mobile Java Application Development BlackBerry App Lifecycle Java ME API.
1Basics of J2ME. 2 Objectives –Understand the different java API’s and how the mobile edition API’s fit in –Understand what a mobile configuration and.
Programming Handheld and Mobile devices 1 Programming of Handheld and Mobile Devices Lecture 14 Various MIDlet examples Rob Pooley
8-January-2003cse ProjectOverview © 2003 University of Washington1 Project Overview CSE 403, Winter 2003 Software Engineering
Other Popular Java Technologies Internationalization in Java Graphics Programming in Java Security Programming in Java Collections and Data Structures.
A Frame Work For Developing Wireless Mobile Online Applications.
Java 2 Platform, Micro Edition (J2ME)
Presentation 11: SOAP on small devices. Ingeniørhøjskolen i Århus Slide 2 af 10 Outline Which small devices? What are the limitations and what kind of.
1 Introduction to J2ME Outline MIDP Building J2ME Apps- Tool J2ME Wireless Toolkit Demo MIDlet Programming -- MIDlet Transition States -- Midlet Skeleton.
Presentation 11: SOAP on small devices. Ingeniørhøjskolen i Århus Slide 2 af 10 Outline Which small devices? What are the limitations and what kind of.
Mobile Programming Mobile Programming - Ordibehesht Ordibehesht 1390.
Enhanced mobile services in Java enabled phones Björn Hjelt Sonera zed ltd Supervisor: Professor Jorma Jormakka.
J2ME Programming. Java2 Micro edition Introduction 년 5 월 26 일 CLDC, MIDP 라이브러리 Reference :
Advance Computer Programming Market for Java ME The Java ME Platform – Java 2 Micro Edition (J2ME) combines a resource- constrained JVM and a set of Java.
The Java Platform Micro Edition Java ME
Java N Amanquah.
Part II Software When developing software there are several particularities to be aware of: Java is widespread used because of the platform independence.
MOBILE DEVICE OPERATING SYSTEM
Wireless Instant Messaging Using J2ME
By Jeff Heaton An Overview of J2ME By Jeff Heaton
Java for Mobile Devices
Presentation transcript:

Writing Your First MIDlet Running JAVA on a Cell Phone Jon A. Batcheller January 27, 2004

Overview The MID The CLDC & MIDP API Developing Code Emulation Deployment

MID – Mobile Information Device Cell Phones, Palms, Blackberry…. Pocket Fisherman? JAVA = one program, multi-platforms “similar platforms” - WORA

MIDP Reduced JVM J2ME – Java 2 Mobile Edition CLDC – Connected Limited Device Configuration CDC – Connected Device Configuration – full JVM imp. MIDP – Mobile Information Device Profile Personal Java, Embedded Java, JavaPhone

MIDP MID MID Native (SYMBIAN OS) CLDC MIDP Native Apps JAVA MIDP Apps

CLDC 128K to 512K total memory Limited Power Limited Connectivity (9600bps) Reduced UI Cell Phones, Pagers, PDA’s

MIDP API and virtual machine to device domain java.lang java.util java.io javax.microedition.io javax.microedition.lcdui javax.microedition.rms javax.microedition.midlet

Development Tools Sun Micro – J2ME Wireless Toolkit MIDP Borland & Sun Forte Nokia – Standalone & JBuilder attachment Need environment to compile (library), verify, package, emulate, and finally deploy

Writing our first MIDlet Application written for the MIDP Profile Must derive from javax.microedition.midlet.MIDlet Must implement startApp(), pauseApp() and destroyApp() Typically also implement a default constructor and a commandAction() from the CommandListener interface

MIDlet Lifecycle

HelloMIDlet.java Extends MIDlet Implements startApp, pauseApp, destroyApp Like an Applet, need something and somewhere to display Display.vs. Displayable Foreground.vs. Background Current Displayable

HelloMIDlet.java Extends MIDlet Implements startApp, pauseApp, destroyApp Like an Applet, need something and somewhere to display Display.vs. Displayable Foreground.vs. Background Current Displayable

Display Object Displayable current = Display.getDisplay(this).getCurrent(); Returns current Displayable Typically in startApp(), look for current Displayable, if null, create own and set it as current.

HelloScreen Displayable current = Display.getDisplay(this).getCurrent(); Returns current Displayable Typically in startApp(), look for current Displayable, if null, create own and set it as current.

HelloMIDlet.java Compile Note project library Package Emulate Deploy Test

Package JAD Versions – JAD, CLDC, MIDP Multiple MIDlets – Suites Other Classes Other Files JAR

JAD – Java Application Descriptor Usually a link on a WAP site Info on the MIDlet Most Important – URL of the JAR Downloaded to MID then user queried to download JAR

JAD – Java Application Descriptor MIDlet-Name: HelloWorld MIDlet-Version: MIDlet-Vendor: Solidware, Inc MicroEdition-Profile: MIDP-1.0 MicroEdition-Configuration: CLDC-1.0 MIDlet-Jar-URL: HelloWorld.jar MIDlet-Jar-Size: 1592 MIDlet-1: HelloWorldApp,, HelloWorldApp

Deploy JAD first JAR on request Methods –IR –BlueTooth – –WEB – “Over the Air”

Emulate Emulators – part of toolkits – Sun or Phone articles/emulators Debugging Environment Interesting Behaviors

Test –Download jad –Queries user if new or different version –Download jar –Execute Application Review Application details

PropExample.java Review Code Emulators Test

javax.microedition.lcdui MIDP Low & High-level APIs Displayable CanvasScreen AlertFormListTextBox

javax.microedition.lcdui Contents of Form and Alert Screens Item ChoiceGroupDateFieldGaugeImageItemStringItemTextField

UiDemo.java Look and Feel Bejeweled

javax.microedition.io CLDC – HTTP protocol! Connection object Content, Datagram, HTTP, Stream Normal Stream I/O –Open with URL –Get input/output streams –Read/Write –Close

javax.microedition.io HttpExample.java Log & Server2.java

javax.microedition.rms Named record store Access to byte array records Add, Get, Store Stock Ticker

Writing Your First MIDlet Running JAVA on a Cell Phone And the discussion continues at McMenamin’s Greenway Pub, SW Scholls Ferry Road North on 217 next exit, then West