I make two different program, application and
bootloader for ATMEGA8
I compile both separately. My bootloader program
size is 512 byte, so I located in smallest bootloader section (Address
1E00h).
I want my program some time switch from bootloader
section to application section and vice versa.
The bootloader program have a function to reprogram
the flash (app section only, coz I I block spm command for boot
section).
Could You help me ?
Andi
----- Original Message -----
Sent: Monday, February 21, 2005 6:10
PM
Subject: Re: [avr-gcc-list] switch from
application to bootloader section
Don't you make the opposite ?
to switch app section to boot section
is:
//....
cli();
GICR = (1<<IVCE);
GICR = (1<<IVSEL);
void (*function)(void) = 0x1E000
function();
Anyone know how to switch interupt vector from
bootloader section to application section ?
I Try :
//...
cli();
GICR = (1<<IVCE);
GICR = (0<<IVCE);
// try
this
void (*function)(void) = 0x0000
function();
//...
Can you give more details :
- what happen ?
Do you disable watch dog
?
----- Original Message -----
Sent: Monday, February 21, 2005 10:23
AM
Subject: [avr-gcc-list] switch from
application to bootloader section
I know to switch app section to boot section
is:
//....
cli();
GICR = (1<<IVCE);
GICR = (1<<IVSEL);
void (*function)(void) = 0x0000
function();
Anyone know how to switch interupt vector from
bootloader section to application section ?
I Try :
//...
cli();
GICR = (1<<IVCE);
GICR = 0;
void (*function)(void) = 0x1E000
function();
//...
but didn't work.
Andi
_______________________________________________ AVR-GCC-list
mailing
list address@hidden http://lists.nongnu.org/mailman/listinfo/avr-gcc-list
|