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

BlackBerry Push Development

Reply
New Contributor
julyate
Posts: 3
Registered: ‎04-15-2013
My Device: Dev Alpha B

Android BlackBerry10 Application Error C2DM

I have an Android app, with functioning push notification. I followed the instructions for converting the app the BB10, with the push configuration added. However, when I start up the app, the following error occurs: 

"The application C2DM(process com.google.android.gsf) has stopped unexpectedly. Please try again."

 

Anyone have an idea why this is occuring?

 

Please use plain text.
Retired
gbeukeboom
Posts: 2,559
Registered: ‎10-16-2009
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM

Hello and welcome to the forums!

 

Are you testing on a real device or simulator?

What is the OS version?

Can you post your CFG file (you can blank out any sensitive data)?

Garett
@garettBeuk
--
Goodbye everybody!
Please use plain text.
New Contributor
julyate
Posts: 3
Registered: ‎04-15-2013
My Device: Dev Alpha B

Re: Android BlackBerry10 Application Error C2DM

[ Edited ]

Hi, thanks Garett :smileyhappy:

 

I'm testing on a real device:

- Model: BlackBerry 10 Dev Alpha (B)

- Model Number: Dev Alpha

- Software Release: 10.9.9.339

 

The Config file is as follows:

<?xml version="1.0" encoding="utf-8"?> 
<android> 
   <push>
      <appid>XXX-yyyyyyyyyyyyyyyyyy</appid> 
      <ppgurl>https://cpXXX.pushapi.na.blackberry.com</ppgurl> 
      <tokenprefix>bb-</tokenprefix>
   </push>
</android>

I run apk2bar with the -m -ma parameters to include the config in the bar file. (with the config filename the same as the apk name)

 

Please use plain text.
Retired
gbeukeboom
Posts: 2,559
Registered: ‎10-16-2009
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM

The PPG URL should be HTTP on the client side, so try this:

http://pushapi.na.blackberry.com

 

HTTPS is needed on the server side only.

Garett
@garettBeuk
--
Goodbye everybody!
Please use plain text.
Retired
mdandrea
Posts: 311
Registered: ‎08-08-2012
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM

Leave the cpXXX part in though - just switch to http.

Please use plain text.
New Contributor
julyate
Posts: 3
Registered: ‎04-15-2013
My Device: Dev Alpha B

Re: Android BlackBerry10 Application Error C2DM

I'm afraid neither of those worked, I'm still getting the same error message in the application.

Please use plain text.
Retired
gbeukeboom
Posts: 2,559
Registered: ‎10-16-2009
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM

Have you added the required permission to the app?

Are you testing using a Release or Debug build? If Debug, could you delete then recreate your debug token and see if that helps.

 

Do you have any other apps on the device, or have you in the past?

Garett
@garettBeuk
--
Goodbye everybody!
Please use plain text.
Retired
mdandrea
Posts: 311
Registered: ‎08-08-2012
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM

You also might want to try updating your Dev Alpha B software from here:

http://developer.blackberry.com/blackberry10devalpha/devalpha_update.html

 

Make sure you change the one you download to match Dev Alpha B (instead of Dev Alpha C).

Please use plain text.
Regular Contributor
martinwang
Posts: 84
Registered: ‎12-02-2009
My Device: Not Specified

Re: Android BlackBerry10 Application Error C2DM

I have question?

 

after convert android apk file  to bb 10 bar file and install it on BB 10, Does Google C2DM server can detect BB 10 device and send push notification ?

 

I convert my android apk  to bar file install it on BB Z10,  it show you need create acount, I create gmail account on Z10, the app still show need account

Thanks

Please use plain text.
Retired
gbeukeboom
Posts: 2,559
Registered: ‎10-16-2009
My Device: BlackBerry Z10

Re: Android BlackBerry10 Application Error C2DM


martinwang wrote:

I have question?

 

after convert android apk file  to bb 10 bar file and install it on BB 10, Does Google C2DM server can detect BB 10 device and send push notification ?

 

I convert my android apk  to bar file install it on BB Z10,  it show you need create acount, I create gmail account on Z10, the app still show need account

Thanks


You would need to use the BlackBerry Push service:

https://developer.blackberry.com/develop/platform_services/push_overview.html

Garett
@garettBeuk
--
Goodbye everybody!
Please use plain text.