View previous topic :: View next topic |
Author |
Message |
jma_1
Joined: 08 Feb 2005 Posts: 147 Location: Wisconsin
|
basic bootloader question |
Posted: Thu May 19, 2005 3:40 pm |
|
|
Greetings,
I have a few questions on the bootloader example. The ex_bootloader.c example uses a #int_global for redefinition of interrupt routines. How would you include / change this to use serial interrupts (load code based on messages)? How do you combine serial routines in your application? Thanks in advance for any thoughts.
JMA |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
|
Guest
|
|
Posted: Fri May 20, 2005 10:32 am |
|
|
Thanks for the post. I wasn't clear on the application. I would like to have the ability to load code into the pic through the serial port when it receives a command (serial). Your posting (link to post w/ code) looks promising. Just to double check that I'm understanding your code, the code acts as a bootloader and is embedded inside the application code. Does the hex file need to parsed when sent by the pc application? As I'm a newbie to pics, what potential items will I need to changes will I need to make to work with the 18f458? Thanks again for the information.
JMA |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Fri May 20, 2005 11:12 am |
|
|
Yes, it does. There's a Visual Basic program that goes with the PIC code.
http://www.ccsinfo.com/forum/viewtopic.php?t=10534&start=0
It sounds like you want to send a HEX file directly to the PIC, perhaps
from a terminal program. In that case, the bootloader must parse
the HEX file. My bootloader code doesn't do that, since the parsing
is done by the VB program.
You should probably look at the CCS example files for a bootloader.
I think they may be closer to what you want. Here are the filenames
and their locations:
c:\program files\picc\examples\ex_bootload.c
c:\program files\picc\examples\ex_bootloader.c
c:\program files\picc\drivers\bootloader.c
c:\program files\picc\drivers\loader.c |
|
|
jma_1
Joined: 08 Feb 2005 Posts: 147 Location: Wisconsin
|
|
Posted: Fri May 20, 2005 12:40 pm |
|
|
Does the VB program use the same parsing which the loader.c uses? If I opt to use the ccs example bootloader, I'm not sure how to change the #int_global definition and the nop within the interrupt routine to use serial interrupts for entering boot mode based on a command received. Questions: (if I go w/ bootloader) how to make the ex_bootloader.c work with receiving a command through the serial port to enter boot mode? If I use serial communication in my application (loaded with bootloader), how to combine both serial routines? Thanks in advance. |
|
|
|