ATMega 32u4 sleep mode

i want to make an atmega32u4 read out the battery status while sleeping using the adc as a wake-up in idle mode, or alternatively using an alarm condition on my clock chip to wake up the 32u4 periodically using power-down. when it detects the battery power being low, it is supposed to turn on an led and then go back to sleep. will the output pin latch during idle and power-down mode, or do i need an external latch?

Study this excellent tutorial on low power operation with the ATmega series. Almost all of it applies to the 32u4.

jremington:
Study this excellent tutorial on low power operation with the ATmega series. Almost all of it applies to the 32u4.

that just loops me back to "ok, if almost all of it applies to the 32u4, then some of it doesnt. so does the 32u4 latch output pins while in sleep mode?"

What does the data sheet say about output pins in sleep mode?

jremington:
What does the data sheet say about output pins in sleep mode?

mate, youre like my mom helping me with my homework by going "yes you do know the solution, you just gotta think harder" whenever i ask a question. do you think i would be asking if the datasheet had told me the answer? after 2 people tried to interpret the 438 page datasheet for an hour and couldnt figure it out, do you think taking another quick look will solve my issue?

do you actually know whether the pins stay latched during sleep mode? cause if not, ill just ask somewhere else.

It latches while in sleep mode, i finally got my 32u4 and got to test it.

mate, youre like my mom helping me with my homework by going "yes you do know the solution, you just gotta think harder" whenever i ask a question. do you think i would be asking if the datasheet had told me the answer?

Your mom and I both recognize laziness when we see it.

I believe most people would find this statement, conveniently located in the section titled "Sleep Modes" in the ATMega32u4 data sheet, reasonably clear.

sleep_io.png

sleep_io.png