I have recently been working with C2DM on a Samsung Galaxy Tab 10.1″ running stock Honeycomb. I finally got the device registering and my server sending out push messages, however, when I tried to run the exact same code on a Motorola Xoom (running Stock Honeycomb), two Sony tablets (running Stock Honeycomb), and a phone (running CM7.1) none of them worked.
I got fresh registration IDs for each of the devices and tried again and again, but always only the Samsung works.
I have a print statement in the onRecieve() of my BroadcastReceiver class and this gets printed every single time for registration of each device. It only ever gets printed again (when I send a push message) on the Samsung tablet. Does anyone know why this might happen?
I would post some code, but I honestly don’t know which part of my code to post. I cen’t even figure out if it’s server side or client side. I did, however, try to follow the Google Doc as much as possible.
Make sure each device is properly registered and that you pass in the proper device id when you send the POST request to google. Also, the devices need to have a Google account logged in. Check all the requirements here: http://code.google.com/android/c2dm/
Also, if the device is already registered, don’t register it again. Once it’s registered, confirm it in
onReceiveand if it is, then try sending an actual push with a payload.