I'm having some trouble programming a 16F628. I'm trying to get it to communicate with my computer via RS232 using the program shown below. I have LED (w/1k res) hooked up to portb.1 to indicate that it's operating. However, when I turn it on, it will sometimes operate for a few seconds and then stop. Then maybe turn back on, etc... ? I've tried it with a 20MHz ex. osc, and the internal osc. I'm powering it from 4 AA bats through a 5V regulator from Radioshack. I also tied portb.4 (low power programming pin) to ground via another 1k resistor, as I understand when portb.4 floats it can act erratically. Can anyone see what I might be doing wrong?
Thanks,
Dave
________________________________
INCLUDE "modedefs.bas"
PORTB=0
CMCON = 7
loop: Serout portb.0,T2400,["TACOS"]
pause 100
low portb.1
pause 100
high portb.1
Goto loop
________________________________
Bookmarks