Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
New Contributor
Posts: 3
Registered: ‎12-10-2013
My Device: Blackberry Q5
My Carrier: Fido
Accepted Solution

Running Blackberry10 App With Cordova

Hey Guys,

 

We have an application on iOS and Android using Cordova 3.1. I've followed the tutorial on the cordova website and have set up all the neccessary signing with my Q5. The phone appears in on my computer (and is in developer mode)

but i'm getting this error on the command:

 

cordova run -d blackberry10

 

Processing configuration changes for plugins.

Iterating over installed plugins: [ 'org.apache.cordova.console',

  'org.apache.cordova.device',

  'org.apache.cordova.dialogs',

  'org.apache.cordova.file',

  'org.apache.cordova.network-information',

  'org.apache.cordova.splashscreen',

  'org.apache.cordova.vibration',

  'com.phonegap.plugins.PushPlugin' ]

Writing out cordova_plugins.js...

Ensuring plugin "com.phonegap.plugins.PushPlugin" is installed correctly...

Plugin "com.phonegap.plugins.PushPlugin" is good to go.

Ensuring plugin "org.apache.cordova.console" is installed correctly...

Plugin "org.apache.cordova.console" is good to go.

Ensuring plugin "org.apache.cordova.device" is installed correctly...

Plugin "org.apache.cordova.device" is good to go.

Ensuring plugin "org.apache.cordova.dialogs" is installed correctly...

Plugin "org.apache.cordova.dialogs" is good to go.

Ensuring plugin "org.apache.cordova.file" is installed correctly...

Plugin "org.apache.cordova.file" is good to go.

Ensuring plugin "org.apache.cordova.network-information" is installed correctly...

Plugin "org.apache.cordova.network-information" is good to go.

Ensuring plugin "org.apache.cordova.splashscreen" is installed correctly...

Plugin "org.apache.cordova.splashscreen" is good to go.

Ensuring plugin "org.apache.cordova.vibration" is installed correctly...

Plugin "org.apache.cordova.vibration" is good to go.

Running app on platform "blackberry10" via command "/Users/jamezon/hotspot-mobile/platforms/blackberry10/cordova/run" --device

No connected BlackBerry 10 device found

 

child_process.spawn(/Users/jamezon/hotspot-mobile/platforms/blackberry10/cordova/run,[--device]) = 2

Error: An error occurred while running the blackberry10 project.No connected BlackBerry 10 device found

 

    at ChildProcess.<anonymous> (/usr/local/lib/node_modules/cordova/src/run.js:67:22)

    at ChildProcess.EventEmitter.emit (events.js:98:17)

    at maybeClose (child_process.js:735:16)

    at Socket.<anonymous> (child_process.js:948:11)

    at Socket.EventEmitter.emit (events.js:95:17)

    at Pipe.close (net.js:466:12)

 

Retired
Posts: 165
Registered: ‎09-24-2012
My Device: Passport
My Carrier: Bell

Re: Running Blackberry10 App With Cordova

Hi James,

 

"No connected BlackBerry 10 device found" indicates that the device cannot be detected by the build system.

 

First, to make sure, check the development mode and IP under:

Settings > Security and Privacy > Development Mode > IP Address (also try toggling the switch for Dev Mode)

 

Once this is confirmed, see if you can ping the device.

In windows:

Start > Run > cmd

>ping 169.254.0.1

 

Paste the response into your reply.

Cheers.

New Contributor
Posts: 3
Registered: ‎12-10-2013
My Device: Blackberry Q5
My Carrier: Fido

Re: Running Blackberry10 App With Cordova

Hey anzor_b,

 

Thanks for help. I've toggled the debug mode off and on and checked the ip address as well.

here is the result from my ping:

 

ping 169.254.0.1

PING 169.254.0.1 (169.254.0.1): 56 data bytes

64 bytes from 169.254.0.1: icmp_seq=0 ttl=255 time=1.009 ms

64 bytes from 169.254.0.1: icmp_seq=1 ttl=255 time=0.881 ms

64 bytes from 169.254.0.1: icmp_seq=2 ttl=255 time=0.779 ms

 

also I should note I'm developing off of a mac, if that makes a difference.

Retired
Posts: 165
Registered: ‎09-24-2012
My Device: Passport
My Carrier: Bell

Re: Running Blackberry10 App With Cordova

Thanks James,

 

I was able to reproduce your issue and logged this internally. I will post back as soon as I hear back from our engineers.

Retired
Posts: 165
Registered: ‎09-24-2012
My Device: Passport
My Carrier: Bell

Re: Running Blackberry10 App With Cordova

[ Edited ]

Hi James,

  

Instead of using the global "cordova run...", use the run bash script located within the project structure:

 

EDIT: The issue is with auto device detection. Use the following commands to add a target and deploy:

 

./platforms/blackberry10/cordova/target add mydevice 169.254.0.1 --pin 1234ABCD

 

Then, use the local run command, and pass target=mydevice to bypass the auto-detect:

 

./platforms/blackberry10/cordova/run blackberry10 --target=mydevice --devicepass pass --keystorepass ********

 

Note: on Mac, you may need to preceed the command with bash/sh.


Let me know what this does for you.

 

Also, while the device is plugged in and development mode enabled, please run ifconfig > output.txt and post the output of the text file here.

 

Cheers.

New Contributor
Posts: 3
Registered: ‎12-10-2013
My Device: Blackberry Q5
My Carrier: Fido

Re: Running Blackberry10 App With Cordova

[ Edited ]

This seems to have worked, I am now having a signing issue.

 

[INFO]    Target mydevice selected

[INFO]    Generating debug token

[ERROR]   The specified CSK password is not valid.

An error has occurred

 

I have recreated my tokenid but no luck. Smiley Sad

 

 

Highlighted
Retired
Posts: 165
Registered: ‎09-24-2012
My Device: Passport
My Carrier: Bell

Re: Running Blackberry10 App With Cordova

Check the steps at the following URL, I have a feeling you haven't created a developer certificate yet.

 

https://developer.blackberry.com/html5/documentation/beta/testing_and_signing_setup.html#kba13821044...

 

By the way, if you have Momentics for BlackBerry 10 installed, or the WebWorks SDK 2.0 you can create this using a GUI. It's much easier.