These days I only use C too (HI-TECH), a trick I've used when running short of program memory is to preset the result of a test, for example; Fred = 10; if(RB0) Fred = 20; uses 3 program words less than, if(RB0) Fred = 10; else Fred = 20; Beware of any interrupt routine which uses Fred though! Regards, Nigel On Thursday, March 01, 2001 7:35 AM, Simon-Thijs de Feber [SMTP:stdf23173@YAHOO.CO.UK] wrote: > Gents, > > > I promissed i would do this. > > I am one of the poor basterds that writes in C instead > of assembler. Just out of convenience. > > At the moment i am struggling with the amount of code > space in my 16F84 so i am trying to find ways to > reduce it. > > I found out that i can save 19 program words when i > use a switch instead of multiple IF's. > The switch has 7 cases. > > and yes, when all fails i have to manually improve the > assembler code. > > grtz, > > > Simon > > > ____________________________________________________________ > Do You Yahoo!? > Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk > or your free @yahoo.ie address at http://mail.yahoo.ie > > -- > http://www.piclist.com#nomail Going offline? Don't AutoReply us! > email listserv@mitvma.mit.edu with SET PICList DIGEST in the body -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body