Skip to content

Latest commit

 

History

History
40 lines (21 loc) · 1.7 KB

README.md

File metadata and controls

40 lines (21 loc) · 1.7 KB

LPC2378_ADC

This repo contains the basic configurations for ADC module of the LPC2378 based development kit (MCB2300) and displaying the A2D converted value through on-board LCD

Following are the configurations to be followed for setting the ADC module of the LPC 2378 (available in the "Program.c" file of the repository):

  • Enable ADC using PCONP.PCAD register (bit 12) image

  • Enabling ADC in AD0CR.PDN register (bit 21) image

  • Enabling clock for ADC: PCLK_SEL0 bits [25:24] image

  • Select AD0.0 in PINSEL1 register (bit 14) image

  • Select channel 0 in AD0CR register bits [7:0] image

  • Select ClockDiv for ADC in AD0CR register bits [15:8] image

  • Start ADC conversion in AD0CR register bits [25:24] image

  • Wait for conversion result to be available - bit 31 of AD0GDR image

  • Process the available results - available in AD0GDR bits [15:6] image