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

bootloader configs

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



Joined: 27 Mar 2010
Posts: 167

View user's profile Send private message

bootloader configs
PostPosted: Fri Dec 04, 2015 3:44 pm     Reply with quote

Hello,
I modified a bootloader to read the EEPROM of code to update GPRS.
It worked.

But I need to know details of how to configure the bootloader and it will run for main_code not happen any bug.

I need those lines in the two codes (bootloader and main_code)?
Code:
#define LOADER_END 2751
#include <bootloader.h>


In the main code so I need it?
Code:
#define LOADER_END 2751
#include <bootloader.h>


The LOADER_END may be larger than what I need without causing trouble?

The FUSES have to be equal in the two codes (bootloader and main_code)?

Is there any limitation on the use of bootloader?

Any tips or trick I need to know for the bootloader run smoothly?
temtronic



Joined: 01 Jul 2010
Posts: 9246
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Sat Dec 05, 2015 6:27 am     Reply with quote

general comments since I don't know what 'bootloader' code you're using...

1) fuses must be the same or you can run into serious trouble

2) having bootloaderend larger than needed reduces available program space especially if not at end of a 'block' of memory.

3) performance is tied to code which we don't see.Depending on wh cut the code it might be as fast as it can get but waste space or it could be 'tight' but messy or ???

4) with ANY bootloader you MUST ensure the PIC power supply doesn't fail during loading! Having a good battery backup with seamless switchover is important. Also some form of data checking is required(checksum, validation,etc.). Loading in ONE bad bit WILL spell disaster.

5) there are no 'limitations' to a bootloader though any that are 'generic' tend to have features your specific application doesn't need. Some 'all-in-one' programs will take longer. Obvious you should test the PIC to be sure you can download the new code though! You can't stuff 16KW of code into a 1KW PIC !!

Jay
jeremiah



Joined: 20 Jul 2010
Posts: 1358

View user's profile Send private message

PostPosted: Sat Dec 05, 2015 6:39 am     Reply with quote

temtronic wrote:

1) fuses must be the same or you can run into serious trouble


Just wanted to add on to this. Another option you have is:

In the bootloader, specify the fuses.
In the application, specify #FUSES NONE

That way, your application doesn't clobber the bootloader's fuses.
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