Getting Started with BlackBerry

Getting Started with BlackBerry

Cordova for BlackBerry makes use of the BlackBerry WebWorks framework. BlackBerry WebWorks tooling is available for Windows or Mac environments.

WebWorks applications can ONLY be deployed to the following BlackBerry platforms:

1. Requirements

2. Install the WebWorks SDK

Download and install the appropriate WebWorks SDKs for your development. BlackBerry 10, BlackBerry PlayBook, and BlackBerry Smartphone WebWorks SDKs can all be downloaded from the following locations. Please note that BlackBerry PlayBook development requires the Adobe Air SDK as well.

3. Register for Signing Keys

If you wish to publish your application on BlackBerry App World, or deploy on an actual device you’ll need to register for a set of free Code Signing Keys.

To register for Signing Keys visit, and complete the BlackBerry Keys Order Form.

Once you receive your Signing Keys, they'll need to be setup. To learn how to setup your Signing Keys visit the BlackBerry HTML5/WebWorks website.

4. Install Cordova

Download the latest copy of Cordova and extract its contents to your local machine.

5. Setup New Project

BlackBerry 10 (QNX)

BlackBerry PlayBook

BlackBerry Smartphone (OS5-7)

6. Hello World

Build the Cordova sample project by typing ./cordova/build <target> in your command prompt/terminal while you are in your project's directory. Replace <target> with either qnx playbook or blackberry. For example...

BlackBerry 10 (QNX)

BlackBerry PlayBook

BlackBerry Smartphone (OS5-7)

7A. Deploy to Simulator

BlackBerry smartphone simulators are only available on Windows. BlackBerry 10, and PlayBook simulators require VMWare Player (Windows) or VMWare Fusion (Mac OS X). The WebWorks SDK provides a default simulator. Additional simulators are available.

For instructions on installing simulators, please visit the following link(s):

BlackBerry 10

Playbook

Smartphone (Optional)

While in your project directory, in command prompt/terminal type ./cordova/run <target>. Replace <target> with either qnx, playbook, or blackberry. Note, for BlackBerry 10 and PlayBook, the simulator virtual image must already be started. For example...

BlackBerry 10 (QNX)

BlackBerry PlayBook

BlackBerry Smartphone (OS5-7)

Answer 'n' when prompted "Do you have a BlackBerry device connected to your computer? (y/n)"

The application will be installed to the home screen of the simulator. Note, on BlackBerry OS 5 the application is installed in the Downloads folder.

7B. Deploy to Device (Windows and Mac)

To deploy your app to a device you must have registered for, and setup BlackBerry Code Signing Keys. See section 3 for details. Also, to deploy apps on BlackBerry 10 or PlayBook, the device must be set to Development Mode which can be enabled from the Settings > Security menu.

BlackBerry 10 (QNX)

BlackBerry PlayBook

BlackBerry Smartphone (OS5-7)

While in your project directory, in command prompt/terminal type ./cordova/run <target>. Replace <target> with either qnx, playbook, or blackberry. For example...

BlackBerry 10 (QNX)

BlackBerry PlayBook

BlackBerry Smartphone (OS5-7)

Answer "y" when prompted "Do you have a BlackBerry device connected to your computer? (y/n)"

The application will be installed to the home screen of the device. Note, on BlackBerry OS 5 the application is installed in the Downloads folder.

Additional Information

The following articles provide help to issues you may encounter when developing a Cordova application which is based on the BlackBerry WebWorks framework