Android alarm manager not working on Samsung Galaxy phone
<p>I have created an app which polls a server to fetch SMS that have to be sent to our users. For the polling functionality i have used the alarm manager to fire every 5 min to poll server</p>

<pre><code>AlarmManager alarm = (AlarmManager) getSystemService(Context.ALARM_SERVICE); 
        Intent pintent = new Intent(this, SMSSender.class);
        PendingIntent pIntent = PendingIntent.getBroadcast(this,0,pintent, 0);
        if(checkbox.isChecked()) {
            long interval = 60*Integer.valueOf(PreferenceManager.getDefaultSharedPreferences(this).getString("pref_poll_interval", "5000"));//5mins;//5mins
            long firstPoll = SystemClock.elapsedRealtime() + 60*Integer.valueOf(PreferenceManager.getDefaultSharedPreferences(this).getString("pref_poll_interval", "5000"));
            alarm.setInexactRepeating(AlarmManager.ELAPSED_REALTIME_WAKEUP, firstPoll, interval, pIntent);
            Log.d("SMS_GATEWAY", "alarm manager turned on "+interval);
        }else {
            alarm.cancel(pIntent);
            Log.d("SMS_GATEWAY", "alarm manager turned off");
        }
</code></pre>

<p>I have tested the application on the emulator against the 2.2 build and everything works fine, now test the final out of SMS going out i have installed the app on a Samsung Galaxy S phone. </p>

<p>Once the app is installed and the preference to poll server is selected, nothing really happens.</p>

<p>What could be the problem</p>
