Cutting power the easy way

Turned off all unused units like the analog comparator, Timer0, USI, and  USART.

Saved about 0.2mA. Not much, but I guess worth the tiny amount of effort.

ACSR |= ACD;        // Turn off analog compare unit. We don't use it, so save power. Saves about 0.1ma   3.6mA drops to  3.5 mA

PRR = PRTIM0 | PRUSI | PRUSART;        // Turn off Timer/Counter0, USI, USART since we don't need them. Saves about 0.1mA.

Brownout detector already off via fuses. Won’t really worry about setting IO pins to output since the input is disabled during sleep and we will be asleep almost all the time except when updating display.

I guess it is now all about maximizing time in SLEEP!

Commit here…

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s