I'm relatively new to PBP, and am still in the learning stages. I'm using a 12F629 to control a servo based on two inputs via pins 1 and 2. Pin 0 is the output pin. For some reason, the 12F629 doesn't recognize any inputs on pins 1 and 2. I've checked to make sure there's no port/pin type conflicts, but I'm sure I'm missing something. Does anyone know what I'm missing?
Thanks in advance,
Dave
(see program below)
-------------------------------------------------
i VAR BYTE
output 0
input 1
input 2
Define OSCCAL_1K 1
low 0
pause 100
loop:
if GPIO.1=1 then turn1
if GPIO.2=1 then turn2
goto loop
turn1:
for i=0 to 5
pulsout 0, 147
pause 20
next i
goto loop
turn2:
for i=0 to 5
pulsout 0, 152
pause 20
next i
goto loop
-------------------------------------------------
Bookmarks