Have y'all seen the latest "Circuit Cellar" magazine? There's an article in there that makes an interesting case study, WRT to the ASM vs compiler (and related) questions. It'a about a simulated candle (for use on-stage) using an LED. The simulation is based on some flame science, and includes a random number ("White noise") generator and a floating point SW implementation of a low pass filter, samples a self-heated thermistor to get air current info, and drives a single PWM output. It's done on an atmel AT90S8535, which is a somewhat sizeable AVR (8K memory, 40pin device) to support the single input, single output, and of course a good deal of floating point support and compiler library support for the PWM and A-D peripherals on the chip. It's hard to argue with the design choices here, for a one-piece item where the designer's time undoubtably cost a lot more than the parts. But it's also a design that just cries out for a "cost reduction effort"; there's no reason I can think of that it wouldn't run in an 8-pin PIC, given some attention to size and clever use of fixed point math. (OTOH, Bob Pease or other analog expert could probably convert it to a code-less design based around a $0.30 quad op-amp, but that's another issue entirely :-) BillW -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body