service - SMS gateway how to program android app -
i want make sms gateway app, polls website , checks if there messages send in queue, , if there is, app send destination number.
there should callback function, post information message, android did it.
i thought first create service , poll check on wifi website, refering website "http://www.androidguys.com/2009/09/09/diamonds-are-forever-services-are-not/" not possible create service run forever.
what should take in mind make app possible. there lot of tricks, wakelocks, startforeground etc, still service not run forever.
thanks.
shafqat
for sending sms messages: http://developer.android.com/reference/android/telephony/smsmanager.html
for checking/polling new messages, best way using push messages. since 2.2 can done cloud device messaging: http://android-developers.blogspot.com/2010/05/android-cloud-to-device-messaging.html , http://blog.boxedice.com/2010/10/07/android-push-notifications-tutorial/
that should work in background, in same way gmail checks mail (for example)
Comments
Post a Comment