shlomo
Newbie level 3

Hi everyone/
I'm having a problem using A2D code with mplab c18 .
can anyone tell me if this part of example code is correct?
and if not, whats wrong?
int result;
......
......
......
result=ADRESH;
if(result==0xff)
{
PORTB=0xaa;
}
else
{
PORTB=0xbb;
}
Thanks
Shlomo
I'm having a problem using A2D code with mplab c18 .
can anyone tell me if this part of example code is correct?
and if not, whats wrong?
int result;
......
......
......
result=ADRESH;
if(result==0xff)
{
PORTB=0xaa;
}
else
{
PORTB=0xbb;
}
Thanks
Shlomo