Deploy to a simulator

Before you distribute your application to users, you can test it using the BlackBerry 10 Device Simulator. You can use the simulator to run and view your applications exactly as you would on a real BlackBerry 10 device. The BlackBerry 10 Device Simulator operates using VMware.

Install the simulator now.

Running your application in the simulator

Start the BlackBerry 10 Device Simulator. See Installing the simulator for details.

Note the IP address displayed in the lower-left corner of the simulator window.

This image shows the location of the simulator IP address.

You can deploy your application to the simulator using the Ripple emulator or the command line.

Using the Ripple emulator to deploy your app to the simulator

Before you start:

  1. In the Ripple emulator, click Build > Settings. Fill in the fields in the Launch section as follows:
    • In the Target field, select Simulator.
    • In the Device IP field, type the IP address of your simulated device.
    • In the Device Password field, type the password that you set for your simulated device. If you did not set a password for the simulator, leave this field blank.
    • Click the X to close the window and save your settings.
  2. Click Package & Launch.

If the package and launch process is successful, the message Build succeeded! is displayed, the .zip and .bar files for the application are saved in the output folder that you specified, and your application is opened in the BlackBerry 10 Device Simulator.

Using the command line to deploy your app to the simulator

Before you start:

  1. In a command prompt, navigate to where you installed the BlackBerry 10 WebWorks SDK.
  2. Navigate to the dependencies\tools\bin folder.
  3. On the command line, type the following command:

    For Windows:

    blackberry-deploy -installApp -password <simulator password> 
        -device <simulator IP address> -package <.bar file path>

    For Mac OS:

    ./blackberry-deploy -installApp -password <simulator password> 
        -device <simulator IP address> -package <.bar file path>

    You can omit including the -password <simulator password> if you didn't set a password for your BlackBerry 10 Device Simulator.

A result::success message appears if your application is deployed successfully.

Removing your application from the simulator

  1. In a command prompt, navigate to where you installed the BlackBerry 10 WebWorks SDK.
  2. Navigate to the dependencies\tools\bin folder.
  3. On the command line, type the following command:

    For Windows:

    blackberry-deploy -uninstallApp -device <IP_address> 
        -package <.bar file path> -password <device password>

    For Mac OS:

    ./blackberry-deploy -uninstallApp -device <IP_address> 
        -package <.bar file path> -password <device password>

Troubleshooting

Error message Description Possible solutions
500 development apps pool exhausted This message appears if too many apps are installed on the simulator. Remove any unused applications from the simulator and deploy your application again.
500 navigator interlock failed This message appears when a version of the application is already running on the simulator.
  • Wait for the simulator to release the application lock. If it fails to release the application lock, restart the simulator.
  • Remove the application from the simulator.
A black screen appears when you start the simulator, or the simulator freezes at the device splash screen.
  • Close the simulator. Verify that the 3D accelerator check box is selected on the VMware Player properties screen.
  • Reset the simulator from the VMware Player menu. Click Virtual Machine > Power > Reset.
Cannot connect: Connection to https://<IP address> refused. You may have to reboot the target. This message appears when the simulator is not responding.
  • Restart the simulator.
  • If the blackberry-deploy command no longer accepts the password, clear the password and set it again.
Connection to <IP address> Refused This message appears when a VPN connection is blocking deployment.
  1. Test the IP address by typing ping ip_address at the command prompt, where ip_address is the IP address of your simulator.
  2. If testing the IP address with the ping command is unsuccessful, then the VPN connection may be interfering with the connection to the simulator. Disable the VPN connection and try deploying your app again.
Device is not in the development mode. Switch to Development from Security settings on the device. This message appears when development mode is turned off on your simulator.
  1. On the simulator, click the Settings icon.
  2. On the Security tab, set Development Mode to On.
Username or password is invalid or not specified or time on the device is out of sync

This message appears if:

  • The VMware Player was suspended instead of the BlackBerry 10 Device Simulator being closed. The timestamp on the simulator may be out of sync with that of the your development computer.
  • The simulator password that was used during development is incorrect or expired.
  • Update the simulator system time to match that of your development computer.
  • Verify that the password is correct and not expired.

Last modified: 2014-03-10

comments powered by Disqus