We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello, I am working on a project using the 8051. I am almost on my completion of the project. But my code size has cross the 64k limit. I have heard that by using paging technique it is possible to access more than 64K code. But i have no idea how to implement paging in 8051.Can any one help me for the same. Thanks in anticipation. Viral.
Hi, Thanks every one for your valuable feedback. I have try using different optimising level but my code started behaving eraticly. It may be because my code is very time critical. I will try some of your other suggestion and hope it works. Regards, Viral.
If raising optimization levels makes your code behave erratically, that's almost certainly not just because the program is time-critical. It's because either there's a bug in the optimizer, a bug in your code, or bad design of the code. Bugs in your code would usually be lack of "volatile" qualifiers on some variables shared between main and interrupt routines. Design errors would be things like expecting that you can generate fixed-time delays by empty loops coded in C, which the optimizer may justifiably delete completely.
"I have try using different optimising level but my code started behaving eraticly." What levels have you tried? At what level do the problems appear? I agree that this is probably due to flaws in your code that only become evident at higher optimisations; therefore, you should debug these problems!
There were some compiler/linker problems with high levels of optimisation. See: http://www.keil.com/forum/docs/thread2094.asp. I belive that these have been fixed in the very latest versions of the tools, so make sure that you are up-to-date.