Hi,
Im using a PIC16F877A. Is it normal to have all the pins of port A be 5V when nothing is connected except power ? The other pins are at 0V.
I suspect that I may have burnt my port A, because I accidentally sent about 10V into the Vref+ pin of port A (but only for a short while, about 1 sec). I also tried this simple code,
but the program couldnt run as expected. How do I check if my port A is OK ?
Thank you.
Im using a PIC16F877A. Is it normal to have all the pins of port A be 5V when nothing is connected except power ? The other pins are at 0V.
I suspect that I may have burnt my port A, because I accidentally sent about 10V into the Vref+ pin of port A (but only for a short while, about 1 sec). I also tried this simple code,
define osc 20
define adc_bits 10 'define number of bits in result
define adc_clock 2 'clock source 2 = Fosc/32 = 20Mhz
define adc_sampleus 50 'set sampling time in microsec
trisa = %11111111
trisd=0
adcon1 = %10000010
pause 500
adc var word
start:
adcin 0, adc
if adc > 10 then
high portd.0
else
low portd.0
endif
pause 500
goto start
but the program couldnt run as expected. How do I check if my port A is OK ?
Thank you.