准备软件:
从Access网站(http://www.access-company.com/developers/downloads/index.html)上下载
"Garnet OS Development Suite, Version 1.2""
Java Technology for Garnet OS (Java Technology for Garnet OS Toolkit (WEME Release 5.7.1)
安装软件:
1。运行 Garnet OS Development Suite, Version 1.2 安装文件Garnet_OS_Development_Suite_1_2_Installer.zip,安装在c:/Program Files目录下, 安装完成后,可以看到C:/Program Files/ACCESS/Garnet OS Development Suite目录。
2。解压缩Java Technology for Garnet Os文件Java_Tech_for_Garnet_WEME57.zip到目录C:/Java/PalmOS下
3。准备Java程序包,打开NetBeans IDE, 找到项目VariousGames. (如何生成VarousGames项目,参考前面《(一)NetBeans IDE上的手机游戏例子》
4。鼠标右键点击VarousGames, 选择"生成项目",可以在输出窗口中,看到生成了两个文件,(VariousGames.jar, 和VariousGames.jad)Palm Os上的运行文件后缀名是prc. 下面需要将这两个文件转换为Palm Os上的prc文件
5。打开目录C:/Java/PalmOS/Tools/lib。把jclFoundation10目录和charconv.zip一起拷贝到JDK的lib目录下,比如C:/Java/jdk1.6.0/lib。
6。运行C:/Java/PalmOS/Tools/bin目录下的jartoprc_w.exe,在“JAD File or URL”中输入VariousGames.jad及路径,比如“E:/mymodules/VariousGames/dist/VariousGames.jad”, 点击“Generate PRC”按钮,可以在窗口下方看到如下结果“Done. Result is: E:/mymodules/VariousGames/dist/games.prc“
7。接下来为Palm OS Simulator 准备JVM环境。在C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/目录下新建立Autoload目录。拷贝下列文件到目标目录
源文件 |
目标文件 |
---|---|
C:/Java/PalmOS/JVM/Simulator/J9JavaVMMidp20.dll |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/J9JavaVMMidp20.dll |
C:/Java/PalmOS/JVM/Simulator/ams.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/ams.prc |
C:/Java/PalmOS/JVM/Simulator/J9JavaVMMidp20.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/J9JavaVMMidp20.prc |
C:/Java/PalmOS/JVM/Simulator/J9JavaVMMidp20_es.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/J9JavaVMMidp20_es.prc |
C:/Java/PalmOS/JVM/Simulator/J9JavaVMMidp20_zh_CN.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/J9JavaVMMidp20_zh_CN.prc |
C:/Java/PalmOS/JVM/Simulator/j9keystore.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/j9keystore.prc |
C:/Java/PalmOS/JVM/Simulator/J9Launcher.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/J9Launcher.prc |
C:/Java/PalmOS/JVM/Simulator/j9pref.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/j9pref.prc |
C:/Java/PalmOS/JVM/Simulator/j9secpol.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/j9secpol.prc |
C:/Java/PalmOS/JVM/Simulator/PalmMidp20_22.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/PalmMidp20_22.prc |
C:/Java/PalmOS/JVM/Simulator/pref.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/pref.prc |
E:/mymodules/VariousGames/dist/games.prc |
C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release/Autoload/games.prc |
Java游戏部署在Palm OS Simulator上
1。运行”Garnet OS Simulator”, 选择“ACCESS”->"Garnet SDK Tools" -> "Garnet OS Simulator", 或者双击运行C:/Program Files/ACCESS/Garnet OS Development Suite/sdk-5r4/tools/Palm_OS_54_Simulator/release目录下的PalmSim_54_rel.exe
2。 Palm中的 games图标就是之前编译的 games.prc. 鼠标点击运行 games, 可以看到如下结果:3。很不幸地是,继续在Palm OS Simulator上运行这两个Java游戏,会遇到下面的错误."SystemMgr.c, Line:6244, SysLikerStub(): Failed to load the shared library"。