|Re: uWatch Source code released|
Message #9 Posted by DaveJ on 19 May 2008, 9:27 p.m.,
in response to message #8 by megarat
My apologies if this has been discussed before, or if it is mentioned in the documentation on your site. (I wasn't able to find anything, hence the question.)
How much space/capacity is there for programming in new functions and conversions? Is the code you have written close to maximum capacity, or is there room to grow this into something larger?
The current code uses about 60% of the 64KB. And that is with the free version of the compiler which does not have code-size optimisations (well, it does for the first 60days, but I'm past that so am restricted)
When I had the code size optimisation option I was getting much smaller code sizes, like >30% reduction or something.
Also, I have not tried to optimise any code to reduce size.
SRAM usage is running about 15% I think.
New functions don't take much extra space at all, in the order of tens or hundreds of bytes not KB. Most of the code space it taken up by the overhead of the floating point routines.
So there is plenty of room to expand and add whatever you want. You'd be hard pressed to fill the memory with just extra menu functions and conversions.
One thing to note. The internal delay routine (used for keystroke and LCD timing etc) is dependent upon the speed-optimisation compiler setting. It is written for the lowest level optimisation (the default restricted Student version one). I should probably try and fix this!
Edited: 19 May 2008, 9:30 p.m.