PDA

View Full Version : Pic16f877a 20mhz



freqout
- 21st August 2007, 15:01
I'm try to make led blinking using PIC16F877A 20MHZ with PICBASIC Pro 2.45,LED not blinking. LED Still ON. I dont know why...I write code like this...

define OSC 20
MAIN:
HIGH PORTB.0
PAUSE 1000
LOW PORTB.0
PAUSE 1000
GOTO MAIN

any problem with my code????

Johan
- 21st August 2007, 15:36
try this



define OSC 20
TRISB = 0
MAIN:
HIGH PORTB.0
PAUSE 1000
LOW PORTB.0
PAUSE 1000
GOTO MAIN

freqout
- 21st August 2007, 15:39
Continue....

When i'm use that code for PIC16F819 and PIC16F84A , It work !

locko
- 21st August 2007, 17:34
I had a similar problem with a 20MHz program and it turned out I was using the wrong fuse setting for the clock when burning the chip. I was setting it as XT but when I set it as HS all was good.

Just something else to try :)

Paul