CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

basic bootloader question

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
jma_1



Joined: 08 Feb 2005
Posts: 147
Location: Wisconsin

View user's profile Send private message

basic bootloader question
PostPosted: Thu May 19, 2005 3:40 pm     Reply with quote

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

View user's profile Send private message

PostPosted: Thu May 19, 2005 4:15 pm     Reply with quote

Not sure what you want to do. Look at the Flash.c code posted in
this thread:
http://www.ccsinfo.com/forum/viewtopic.php?t=7791
Guest








PostPosted: Fri May 20, 2005 10:32 am     Reply with quote

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

View user's profile Send private message

PostPosted: Fri May 20, 2005 11:12 am     Reply with quote

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

View user's profile Send private message

PostPosted: Fri May 20, 2005 12:40 pm     Reply with quote

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.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group