Skip to content

how does LGT8Fx correctly set the reset vector? #304

Answered by malaouar
whyameye asked this question in Q&A
Discussion options

You must be logged in to vote

The LGT8F328P has no special bootloader section in the flash as the ATMEGA328P has.
So how the bootloader is implemented?
The RESET vector is changed so it points to the address where the bootloader is flashed (top of flash). And when you upload an application via the bootloader the entry address of the code (which RESET vector should point normaly) is put in place of the WATCHDOG interrupt vector which is rarely used.
The bootloader code make this change and jumps to the address of the WDT vector (entry address of the application code).
Hope this helps a little.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by whyameye
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants