avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [avr-libc-dev] Problem writing to flash - atmega644


From: Patrick Mahoney
Subject: RE: [avr-libc-dev] Problem writing to flash - atmega644
Date: Thu, 23 Aug 2007 16:46:18 -0400

Greetings,

I agree it looks very much like this. But...
- I have the interrupts disabled before the call to the subroutine
located in the bls section
- the stack pointer, right before the call, still points to the top of
the internal ram (0x10ff on the mega644), while the _end symbol is very
low (0x1b7), which leaves almost all of ram to the stack.

And once again, if I leave this routine in the .text section, the
unexpected resets suddenly disappear.

Pat


-----Original Message-----
From: address@hidden
[mailto:address@hidden On
Behalf Of Joerg Wunsch
Sent: August 22, 2007 5:38 PM
To: address@hidden
Cc: Patrick Mahoney
Subject: Re: [avr-libc-dev] Problem writing to flash - atmega644

As Patrick Mahoney wrote:

> It might not be an actual reset because all bits in the MCUSR register
> are cleared. So it could be a jmp to address 0, but it doesn't make
more
> sense... Again, the sims run perfectly...

Smells like either a problem with the stack initialization, or you've
enabled an interrupt source that has no ISR assigned.
-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)


_______________________________________________
AVR-libc-dev mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/avr-libc-dev




reply via email to

[Prev in Thread] Current Thread [Next in Thread]