mot1639
Member level 1

hi all
i am trying to switch LED in PIC16f877a when i press push button..
it work with PIC16f84a and not in PIC16f877a ...
where is the problem
i build the circuit in isis proteus .... it work for PIC16f84a and not with PIC16f877a ...

where is the Problem
regards for all and thanks in advance...
i am trying to switch LED in PIC16f877a when i press push button..
it work with PIC16f84a and not in PIC16f877a ...
where is the problem
i build the circuit in isis proteus .... it work for PIC16f84a and not with PIC16f877a ...

Code:
void main() {
ADCON1=1;
TRISA=0xff;
TRISB=0;
PORTB=0;
while(1){
if (RA2_bit==0){
PORTB=0xFF;
delay_ms(1000);
}
}
}
where is the Problem
regards for all and thanks in advance...