Bill's Computer Circus
Don't get caught with your system down.
NOTICE: This web site may not render correctly in older browers like
Internet Explorer 5.2 for the Mac. May the gods help you if you are
using Internet Explorer on any machine! Otherwise, if this site does
not look right on your browser, please let me know what browser you
are using (and what version and on what computer). Thanks!
"Visual Basic makes the easy things easier. Delphi makes the hard things easy." -- unknown |
||
|
Tuesday, July 13, 2004
Wowie, wowie, wowie!
What the hell is wowie? Just thought I would add a bit to my earlier statistics. The current instruction count is 1951 instructions for PIC1, and 1705 instructions for PIC2, for a total of 3656 instructions. I added a few today (trying to bring my development rate up to one instruction per hour - haha). And things are moving right along. I have only one critical item remaining on my list, then it's play time! But this last item is a bugger to track down, because it is a reset issue that has a lot of strings attached. Anyway, I thought I would provide a count of RAM bytes that I use for accomplishing all that this device does. It's really pretty amazing (to me, anyway). PIC1 uses 133 bytes of RAM and 60 bytes of EEPROM data (for identification purposes). PIC2 uses 125 bytes of RAM and 84 bytes of EEPROM (that get copied into a portion of the 125 bytes of RAM on power-up). So, in total, RC4 uses 258 bytes of RAM and 144 bytes of EEPROM to do what it does. That's just amazing to me. Hey - it wasn't easy! It took me two years to figure out how to cram all that in there. Hmm. Where would we be if Microsoft worked that way? I think the days of writing efficient code to fit into tight spaces, are gone. I think that's why I like doing embedded stuff (well, I say I like it, but it's really a love-hate relationship...or an addiction) - I can hone my skills and my craft in the art of cramming code. I just don't want to let that art die, I suppose. It's not something people seem to learn these days. People these days seem to solve programming problems by throwing more memory at it. I like to solve programming problems by ripping out code that's not necessary. After two years, you can bet that every BIT in this thing is absolutely necessary. In fact, I had a long-standing issue (that is still open) about deciding what function to assign to one last bit that was available in a mode selection byte, as there were four competing potential features that wanted it. It turns out I had to use that bit to solve another issue that I just resolved last week. So there are four potential features that got locked out due to the lack of available bits! But if I start using the PIC16F87 microcontroller, I will suddenly have a lot more room to play with. My code will port over to it directly as the chip is a direct upgrade from the PIC16F628 that I am using now. The 'F87 has twice the code space (4K!) and twice the EEPROM space (256 bytes!). But then again, I don't expect to be expanding this project, anyway. I've got other things I want to do with my life. |
Archives:
February 2004March 2004 April 2004 May 2004 June 2004 July 2004 August 2004 September 2004 October 2004 November 2004 December 2004 January 2005 March 2005 April 2005 June 2005 July 2005 September 2005 October 2005 November 2005 December 2005 January 2006 February 2006 April 2006 May 2006 July 2006 June 2007 July 2007 May 2008 January 2009 March 2009 October 2009 |