Olin Lathrop ha scritto: > You do if you want good noise immunity. ok > Take a look at the cycles though. Compared to a 24F at anything near full > speed, the cycles used by this is a tiny fraction. Let's say for example > the PIC is running at 30MHz instruction rate. That's 30K instructions per > 1mS sample. 1% of that would be 300 instruction, which is way more than the > filtering and peak detection would take. Are you really so tight on CPU > cycles that a fraction of 1% makes a difference? I have some other interrupts going on - I posted a thread @ forum but was going to replicate it in here. Basically I have an underlying Ethernet or USB app going on (or even none of them - simplest case), a text LCD and some simple keys; and I have dimmer going on (zero-crossing plus 100uS steps for triggering the Triac), and a FM-out which is basically a 1000-2000 Hz sine-wave that I plan on doing using a HW PWM and a 16 step sine-table. This calls for a total of: 1KHz IRQ for RMS 10KHz IRQ for dimmer 32KHz IRQ for the 16step sine-wave @2KHz Should be definitely doable, but of course I want to do it "best I can" :) -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist