1
내 코드 등록 방법은 NULL 반환 나는 점점 오전 예외가 SERVICE_NOT_AVAILABLE입니다GoogleCloudMessaging.register - 다음 SERVICE_NOT_AVAILABLE 오류
protected String doInBackground(Void... params) {
if(GooglePlayServicesUtil.isGooglePlayServicesAvailable(context) == ConnectionResult.SUCCESS){
GoogleCloudMessaging gcm_instance = GoogleCloudMessaging.getInstance(context);
String reg_id = null;
int attempts = 0;
while(attempts < 3 && reg_id == null){
try{
reg_id = gcm_instance.register(SENDER_ID);
return reg_id;
} catch (IOException e) {
e.printStackTrace();
}
attempts++;
}
}
return null;
}
입니다. 보낸 사람 ID를 확인하고 인터넷 연결이 내 장치에서 완벽하게 작동하는지 확인합니다.
도와주세요.