out of rom,the segment or the program is too large Main".
In CCS, a function can't be larger than a ROM page. For the 16F877,
a ROM page is 2048 words. The solution is to break up the code in
main() and put some of it into functions. Then call those functions from
main(). This will allow the compiler to put those functions into other
ROM segments, and you won't get the "out of rom" error anymore.
// Initial main code goes here.
// Put some of the main() code into these functions.
// or more.
// Other main code goes here.
Joined: 23 Sep 2003 Posts: 852 Location: Utah
Posted: Mon Apr 07, 2008 8:55 am
There have been several posts regarding this error. Do a search on 'out of rom' and you should find the answers you are looking for.
Joined: 01 Apr 2008 Posts: 5
Posted: Mon Apr 07, 2008 10:23 am
also you must add #separate before the main function
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