2011-02-02 42 views
2

我可以調試我的應用程序爲「仿真Java Me Midlet」或「仿真Java Me Jad」。這些類型有什麼區別?現在我的應用程序只能在調試模擬java java jad中工作。在JavaMe(Midlet或JAD)中調試

當我運行它的MIDlet我得到以下錯誤:

Cannot create PortForwarder with necessary parameters: Failed to get device id for "null"! Syntax:

emulator [arguments]

In order to get commands supported by given device run: emulator.exe -Xdevice: -Xquery

是否有人知道如何解決這個問題?

+0

什麼IDE您使用的? – mdelolmo 2011-02-02 16:47:54

+0

我正在使用eclipse(java me) – Vincent 2011-02-02 16:50:09

回答

1

JAD = Java應用程序描述符。 JAD用於無線(OTA)部署。 JAD指定一個或多個MIDlet在設備上安裝。

您可能沒有爲模擬器正確配置MIDlet部署選項。閱讀文檔here

2

設備ID爲"null"表明此處可能存在配置問題。我建議檢查調試配置 - >仿真選項卡並檢查一切都很好。

這也有可能是這一點,你所遇到此已知問題:https://blogs.oracle.com/javamesdk/entry/eclipse_java_me_sdk_issue

If you have had issues with running your MIDlet in Eclipse + MTJ (Eclipse ME), then this article is relevant to you.

We found out that "Run as emulated MIDlet" option is not supported by Java ME SDK 3.0.5. "Run as emulated MIDlet" means that you are executing a specific MIDlet in the jar file, where jar file contains more than one MIDlet.

Please use "Run as emulated Java ME JAD" option instead...