RTC_WAKEUP

by /dev/null » Tue, 15 Sep 2009 07:59:30 GMT


Sponsored Links
 I thought that the intention for the RTC_WAKEUP alarm was to wake up a
sleeping or powered off device. I was a bit surprised to find out that
it was not only the Alarm Clock application that registered RTC_WAKEUP
alarms, but also the Calendar does this to drive its synchronization.
I assume the GMail application uses the same technique.

This means that I cannot use RTC_WAKEUP alarms on my hardware to
program an RTC to power on a device on an alarm. Because if I did it
would also power up the device when a synchronization activity is
scheduled, the device would stay powered up, the battery power would
eventually be exhausted, possibly long before the alarm set in the
Alarm Clock app is reached.

Is this the intended behaviour, or am I assuming to much that the
intention for Android was to support alarms to power up a device and
sound an alarm as many classic feature phones have supported almost
since time immemorial? If this wasn't intended then there needs to be
a new RTC category of alarms that does power up the device, and only
alarms set in the Alarm Clock or a Calendar event with a reminder can
trigger it.

TIA

--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



RTC_WAKEUP

by Dianne Hackborn » Tue, 15 Sep 2009 08:10:43 GMT


 It is there to bring the device out of deep sleep (that is when no wake
locks are held), not to turn it on when it is off.

If you want to allow the device to turn on while off, a new kind of wakeup
alarm will need to be defined.  This is not currently feature that is
supported by the platform.






-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---


Sponsored Links


RTC_WAKEUP

by Dianne Hackborn » Tue, 15 Sep 2009 08:11:08 GMT


 (Oh also such an alarm would have very different semantics than current ones
because all existing alarms do not persist across a boot, and then rely on
sending to a PendingIntent that can not surface across a reboot.)







-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



RTC_WAKEUP

by /dev/null » Tue, 15 Sep 2009 17:55:12 GMT


 t least as far as the alarms set in the Alarm Clock app go,
PendingIntents do in fact resurface after a reboot. At least as long
as you make sure to have the device up and running in time for the
alarm to go off. Those alarms and their on/off state are persisted
through the database and re-registered with the AlarmManagerService
when the Alarm Clock app comes up following a reboot.

The only gotcha I can think of is that you need to make sure to turn
off the device in the same timezone as you want to wake up in.
Otherwise the device will power up and sound the alarm that many hours
early or late depending on how many timezones you've crossed and in
which direction. Probably if daylight savings go into or out-of effect
while the device is off you'd get a similar result. Setting the time
automatically through NITZ, NTP, GPS or other mechanism will may also
cause problems.

Anyway, now that I know that Gogle never intended for Android to work
this way I'll go ahead and make the changes which I assume will be
submitted through the usual channels.

Thanks,

On 15 Sep, 02:10, Dianne Hackborn <hack...@android.com> wrote:
--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



RTC_WAKEUP

by Dianne Hackborn » Wed, 16 Sep 2009 00:45:09 GMT


 hey definitely don't survive.  What is specifically happening for the alarm
clock is that it runs at boot and schedules new alarms for the times it has
in its database. If this is sufficient for what you need, that makes things
easier.

On Tue, Sep 15, 2009 at 2:54 AM, /dev/null <mmm...@gmail.com> wrote:



--
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails. All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



Other Threads

1. Programatically end an Intent - Specifically the RecognizerIntent

Hi, I'm now and in my app I'm starting the recognizer to listen for
speech. (My app is API level 4)

If it fails, it brings up a dialog to try again or cancel.

How could my Activity cancel that activity and try again
automatically?

Thanks for any advice.

I have a handler that is calling a runnable but I'm not sure how to
kill the dialog.

<code>

        Intent intent = new
Intent(oRecognizerIntent.ACTION_RECOGNIZE_SPEECH);
        intent.putExtra(oRecognizerIntent.EXTRA_LANGUAGE_MODEL,
                        oRecognizerIntent.LANGUAGE_MODEL_FREE_FORM);
        intent.putExtra(oRecognizerIntent.EXTRA_PROMPT, "Your
Command?");

</code>

-- 

2. What is iconLevel on notification?

What is iconLevel on Notification?  I've read the doc.
http://developer.android.com/reference/android/app/Notification.html#iconLevel.
It just says public int         iconLevel       If the icon in the status bar is
to have more than one level, you can set this.  I might want to do
this if I knew what it means. What does this mean, any example?

-- 

3. Is there any way to get foreground activity's window preference?

4. GET queries not sending HTTP_USER_AGENT

5. Android Beginner

6. Non-crippled NFC API

7. Android Market Client with new Merchandising and Billing Features