i have a problem of turning on LED light at RA4 for PIC16F628A.
i know that this pin (RA4) is also T0CKI and CMP2 pin.
i think by default this pin (RA4) is set as TOCKI or CMP2 but not as I/O pin, therefore this pin can't turn High.
So is anyone know how to set this pin (RA4 pin) as I/O pin?
i am using ccs c compiler.tx.
below is my source code and circuit picture, please refer it for more detail. Tx.
Code:
#include <16F628A.h>
#fuses XT, NOWDT, NOPROTECT, BROWNOUT, PUT, NOLVP,INTRC_IO
#use delay(clock=4000000)
void main()
{
set_tris_a(0b00000000);
output_a(0b00000000);
while (true)
{
output_a(0b11111111);
}
}
my picture link: http://www.imagehosting.com/show.php/1726932_pic16f628a.JPG.html
i know that this pin (RA4) is also T0CKI and CMP2 pin.
i think by default this pin (RA4) is set as TOCKI or CMP2 but not as I/O pin, therefore this pin can't turn High.
So is anyone know how to set this pin (RA4 pin) as I/O pin?
i am using ccs c compiler.tx.
below is my source code and circuit picture, please refer it for more detail. Tx.
Code:
#include <16F628A.h>
#fuses XT, NOWDT, NOPROTECT, BROWNOUT, PUT, NOLVP,INTRC_IO
#use delay(clock=4000000)
void main()
{
set_tris_a(0b00000000);
output_a(0b00000000);
while (true)
{
output_a(0b11111111);
}
}
my picture link: http://www.imagehosting.com/show.php/1726932_pic16f628a.JPG.html