Hi guys
So I was looking at some bootloader source code, with the intention to understand how it works. I think I got the basic idea, but there are a few details that I don't understand and I need some help with these.
The first part that I am not quire understand is how it remap the interrupt to a new locations, here is the source code, where can I find more info about this? I can tell what they do from the comments, but I don't understand them at all.
Thanks guys!
PS: using XC8 compiler.
So I was looking at some bootloader source code, with the intention to understand how it works. I think I got the basic idea, but there are a few details that I don't understand and I need some help with these.
The first part that I am not quire understand is how it remap the interrupt to a new locations, here is the source code, where can I find more info about this? I can tell what they do from the comments, but I don't understand them at all.
Code:
// *****************************************************************************
// The bootloader code does not use any interrupts.
// However, the application code may use interrupts.
// The interrupt vector on a PIC16F is located at
// address 0x0004.
// The following function will be located
// at the interrupt vector and will contain a jump to
// the new application interrupt vector
asm ("psect intentry,global,class=CODE,delta=2");
asm ("pagesel " str(NEW_INTERRUPT_VECTOR));
asm ("GOTO " str(NEW_INTERRUPT_VECTOR));
PS: using XC8 compiler.