Hi Gary,
here is your blinky, this code works as is.
it's your code with some add ins, after you check what skimask suggested,
try this and it should work, then remove parts of this code until it stops working and see what you learned. I think it is the trisb setting your code needed. The chip just didn't know whether to input or output.
JS
Code:
@ DEVICE pic16F84, XT_OSC
@ DEVICE pic16F84, WDT_OFF
' Watchdog Timer
@ DEVICE PIC16F84, PWRT_ON
' Power-On Timer
DEFINE OSC 4
TrisB = %00000000 ' Sets all bits portb as outputs
loop:
High PORTB.0 ' Turn on LED connected to PORTB.0
Pause 1500 ' Delay for 1.5 seconds
Low PORTB.0 ' Turn off LED connected to PORTB.0
Pause 1500 ' Delay for 1.5 seconds
Goto loop ' Go back to loop and blink LED forever
End
Bookmarks