Oh, that's great. How do I implement this using DT interrupt?
Below is what I'm currently doing, using pause 25ms before the next AD.
Code:define OSC 20 ' Define ADCIN parameters Define ADC_BITS 10 ' Set number of bits in result Define ADC_CLOCK 3 ' Set clock source (3=rc) Define ADC_SAMPLEUS 50 ' Set sampling time in uS ADCON1= %00000111 'PIC16F877 all analog input except RE1,RE2 'start AD here ADCIN 0, adval ' Read channel0 RA.0 to adval pause 25 ADCIN 1, adval2 ' Read channel1 RA.1 to adval pause 25




Bookmarks