Uart wakeup from sleep/idle modes

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

hello:

I am contemplating using a mega48 in athe sleep or idle mode to save power. RS232 commands will come in & I wish the mega48 to "wake up" and receive them. is this possible from the sleep mode? It seems possible form the idle mode. I'd prefer for the scheme to not miss any commands (thus interpret the first command sent), and avoid having to transmit a "dummy" wakeup command.

I saw several posts using a "dummy" wakeup command, but am wondering if it is easy to wake up merely by sending a byte into the uart.

Any thoughts on this idea are most welcome!

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In the deeper sleep modes, the oscillator is stoped, and you can't wake up the AVR from the UART, unless you connect the UART to an external level interrupt, which implies to send the dummy data.

Regards,
Alejandro.
http://www.ocam.cl

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

aweinstein wrote:
In the deeper sleep modes, the oscillator is stoped, and you can't wake up the AVR from the UART, unless you connect the UART to an external level interrupt, which implies to send the dummy data.

On the '48, you CAN use the pin-change interrupts in deep sleep, so you >>could<< wake up on the start bit.

But you probably will not be able to capture the first byte reliably. I agree that you may need a dummy wake-up byte, and even then you may not get synced reliably if you miss half the firtst byte; may need a couple until you no longer get framing errors.

Lee

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

theusch wrote:
aweinstein wrote:
In the deeper sleep modes, the oscillator is stoped, and you can't wake up the AVR from the UART, unless you connect the UART to an external level interrupt, which implies to send the dummy data.

On the '48, you CAN use the pin-change interrupts in deep sleep, so you >>could<< wake up on the start bit.
Lee

Damn! I knew that I should check the mega48 datasheet, not the mega8.

Regards,
Alejandro.
http://www.ocam.cl