0

我正在开发blackberry phonegap application. 我已经设置了构建应用程序所需的所有环境。当我构建成功构建的应用程序时,我正在使用命令提示符来调试应用程序。但是在加载设备时会导致如下错误。

C:\bbtest>ant blackberry load-device
Buildfile: C:\bbtest\build.xml

blackberry:

load-device:

generate-cod-name:
     [echo] Generated name: cordovaExample.cod

clean:
   [delete] Deleting directory C:\bbtest\build

package-app:
    [mkdir] Created dir: C:\bbtest\build\widget
     [copy] Copying 24 files to C:\bbtest\build\widget
      [zip] Building zip: C:\bbtest\build\cordovaExample.zip

load-device:
     [exec] [INFO]                      Parsing command line options
     [exec] [INFO]                      Parsing bbwp.properties
     [exec] [INFO]                      Validating application archive
     [exec] [INFO]                      Parsing config.xml
     [exec] [INFO]                      Populating application source
     [exec] [INFO]                      Compiling BlackBerry WebWorks applicatio
n
     [exec] [INFO]                      Starting signing tool
     [exec] [INFO]                      Signing complete
     [exec] [INFO]                      Generating output files
     [exec] [INFO]                      BlackBerry WebWorks application packagin
g complete
     [exec] RIM Wireless Handheld Java Loader
     [exec] Copyright 2001-2009 Research In Motion Limited
     [exec] Connecting to device...debug: HRESULT error during Open: 80040154
     [exec] Error: unable to open port

BUILD FAILED
C:\bbtest\build.xml:49: The following error occurred while executing this line:
C:\bbtest\blackberry.xml:53: exec returned: 3

Total time: 53 seconds

C:\bbtest>

任何想法为什么会发生任何帮助将不胜感激。

4

3 回答 3

0

很难确定该信息的问题,但我怀疑您的 xml 中的“目标名称”有问题。

确保加载设备在您的 blackberry.xml 中正确定位,如图所示。

<target name="load-device" depends="package-app">
        <bbwp code-sign="true" />
        <exec executable="${javaloader}" dir="." failonerror="true">
            <arg value="-u" />
            <arg value="-w${properties.blackberry.sim.password}" />
            <arg value="load" />
            <arg file="${build.dir}/StandardInstall/${cod.name}.cod" />
        </exec>
    </target>

还要确保在 project.properties 中正确设置了您的目录。

blackberry.bbwp.dir=C:\\TheBlackBerryWebWorksSDK
blackberry.sim.dir=C:\\TheEclipseBlackBerry\\plugins\\net.rim.ejde.componentpack5.0.0_5.0.0.25\\components\\simulator
blackberry.mds.dir=C:\\TheBlackBerryWebWorksSDK\\mds
于 2013-06-03T12:23:36.140 回答
0

我认为您可能没有安装 BlackBerry Desktop Manager。您可以从http://uk.blackberry.com/software/desktop/desktop-pc.html下载

于 2014-03-30T18:31:05.157 回答
0

使用不正确的部署命令时也会引发此错误。就我而言,我尝试使用ant blackberry load-device而不是ant qnx load-device 将我的应用程序部署到 BB10 设备。

这是文档中的一个片段:

黑莓 10 (QNX) - ant qnx load-device

BlackBerry PlayBook - 蚂蚁剧本加载设备

黑莓智能手机 (OS5-7) - 蚂蚁黑莓加载设备

请参阅http://cordova.apache.org/docs/en/2.5.0/guide_getting-started_blackberry_index.md.html

于 2014-05-07T08:48:48.183 回答