Tolven Mobile Installation
Rev 0.2 (incomplete)
Tolven Mobile has two components, a server-side component in the form of a servlet sitting, like tolvenWEB, on the tolvenEJB core and a client-side component that runs in a KVM (a small JVM) running on the mobile device. The client communicates with the server via HTTP, but not HTML.
Prerequisites
In order to build and deploy the client, you will need to have the Sun Java Wireless Toolkit, version 2.5 or later installed. This kit depends on Windows XP and so, unless you make provisions otherwise, cannot be built on Linux or Mac-OS. the kit can be found here:
http://java.sun.com/products/sjwtoolkit/download-2_5.html
More information on the wireless toolkit is available here, including possible updates.
The mobile setup also depends fully on the primary Tolven Developer's Installation. Therefore, if you have not done so already, install that kit.
Modify ant-build.properties
The client build procedure depends on the Wireless Toolkit which, by now, should be installed on your system. In order to build the mobile client, you will need to configure tolven/resources/ant-build.properties to point to the wireless Toolkit. (use tolven/template/ant-build.template as an example).
wtk.home=C:/WTK25
if you installed the Wireless Toolkit to c:\WTK25
Server Side
The server side of the interface is built as part of the regular Tolven Developer's Installation. Therefore, unless you are customizing the server side, you shouldn't have to do anything special to the tolvenMobileServer project. By building and deploying the main application, you are automatically building and deploying the MobileServer.
Running the Emulator
Rather than testing changes on the device itself, the Wireless Toolkit comes with an emulator that allows you to get a general idea of how the application will run on the target device. It also supports debugging and has a console so you can see trace messages.
Client Side
The J2ME architecture is different enough from the "write once, run anywhere" environment supported everywhere else that there is no code in common between the mobile client and the rest of Tolven code. Nevertheless, it is Java and thus able to run on any mobile device that supports the Java CLDC environment.
As with other tolven components, the mobile client is built using Ant. You can drag the build.xml file from tolvenMobileClient into the Ant view in Eclipse. The only ant takes to make a special not about are sign and deploy. Distributing a jar to any client, including a mobile device should be signed. But it is done in a different way in a mobile deployment.
The deploy task only deploys as far as getting the client jar to the tolvenMobileServer/web directory. The tolvenMobileServer project is then packaged as a WAR file which in turn is packages as the tolven.ear file which in turn is deployed to the JBoss application server.
Build Path
Building tolvenMobileClient is different from the other components in that it does not use the JDK tools path at all. Everything it uses depends on just two jar files: midpapiNN and cldcapiNN.
In the Eclipse build path for this project.
KVM
The Tolven Mobile client is a built as a jar file. In order to get the jar file, the mobile device will need a Java virtual Machine, similar to desktop and server systems. This so-called KVM (K being short for kilobyte), must be installed and will be used to both download the tolvenMobile Client and to launch it. See the Palm 680 setup procedure as an example how to setup the KVM.
Signing the Jar
[TBD - not tested yet] The tolven.jar file should be signed. This is done in the usual way using tools provided in the regular JDK. The tolvenMobileClient build.xml file takes care of signing automatically.
Removing Tolven Mobile from builds
If needed, you can remove the mobile server from the tolven.ear file by
- Remove tolvenMobileServer.war from the build.xml file in the tolven project
- Edit the tolven/conf/application.xml file to remove the /Mobile web server context. This is also where you would change the web context directory, which is defaulted to /Mobile (the web application is defaulted to /Tolven in application.xml).
- Home
- The Tolven Institute
- License Agreement
- Products & Services
- Architecture Briefs
- Downloads
- Frequently Asked Questions
- Useful Links
- Complementary Projects
- Contact Us
Support
Rely on the Tolven support team to help resolve problems during any stage of your application development lifecycle, deployment or implementation.
