Sample ADC project of Micro-Controller (PIC16f877A) with ‘C’ code.
Here V1 and V2 is Variable DC voltage and V3 is Rectified DC Voltage which is the analog input in Micro-controller and the internal ADC in Micro-Controller is measured the Analog signal and the LCD is showing the result through the Micro-Controller. P/N Port indicate the positive and negative phase of the AC Signal. And the Micro-Controller detect the phase condition from P/N port and display in LCD. ADC input voltage range is 5V Max
C Code in the Micro-Controller – PIC16F877A