Hi, "Does anybody have any example C programs using the CCSC compiler for using the onboard A2D converter on the PIC16F877." A derivative of one of CCS' own examples - presumably they won't mind me posting it if they sell a compiler on the back of it ;-) #use delay(clock=10000000) void main (void) { int value; setup_port_a( ALL_ANALOG ); // Next 3 lines are inbuilt functions setup_adc( ADC_CLOCK_INTERNAL ); set_adc_channel( 0 ); do { value = Read_ADC(); delay_ms(100); printf("\n\r%2X\r\n", value); } while (TRUE); } Regards, Dan -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads