I am no fan of doing the RMS thing on the PIC itself, but in any case you probably be better served by having the CCP module trigger the ADC conversion. That way you get a very precise sampling rate (look at section 15.2.5 SPECIAL EVENT TRIGGER of the datasheet).