After using this new code below, I get value of sayi +2 each time I click.
device 16f84a
ON_INTERRUPT goto flash
intcon = %10001000
input portb.6 ' Bu pinleri sıfırladıktan sonra alıcı olarak ayarlamalısın
dim sayi as byte
sayi = 0
loop:
high porta
delayms 200
serout portb.3,16780,[Dec sayi ,13]
goto loop
disable
flash:
MOVF PORTB, W
low porta
intcon.0 = 0
sayi = sayi + 1
CONTEXT RESTORE
end
Bookmarks