This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

adc program pls check error

#include<iolpc1788.h>
int main(void)
{ int data; FIO0DIR |=(0<< 13);
PCONP =0X00001000;
AD0CR = 0X00200180;

IOCON_P0_13 =0X00000003;

while(1)
{ AD0CR |= (1 << 24); while (!( AD0GDR & (1 << 31))) ;

AD0CR |= (0<<24);

data = AD0GDR;
} // return(0);

}

Parents Reply Children
No data