-
Runing a PIc16F876A
HI am having problem working with a PIc16F876A (and PIc16F877A) it compiles but nothing is happening, Its a simple led blinking. Oscillation is running good too..
@ DEVICE PIC16F876A , HS_OSC , WDT_OFF , PWRT_ON , BOD_ON , LVP_OFF , PROTECT_OFF
'HS 20mhz, watchdog off, powerup timer on, mclr external, brown out detect on, low volt program off , code protect off
DEFINE OSC 20
INCLUDE "modedefs.bas"
TRISC =0
loop:
portc.3=1 'Blink led
pause 300
portC.3=0
pause 300
goto loop
end
-
Something is bad in your hardware or PicProgrammer, it's working here.
-
Same project . . .
Hello,
I am asuming this is the same temp monitor you have been working on and as such I am also asuming it is running off the 9v battery, anyway what I was thinking was . . . you have set BOD_ON . . . maybe your power supply voltage is too low to run that way.
JS
-
To confirm the pic is programmed try reading it back and dumping the HEX to a file, and then read that file in notepad. If that's fine then as Steve has varified the code works it must be hardware related
1) - check that you are using the correct crystal for timing
2) - check that the two capacitors are the correct values for that crystal (33pf - 22pf)
3) - check that the supply voltage is regulated to 5v (5.5v max)
4) - place a 0.1uF decoupling capacitor accross the supply as close to the PIC as possible.
-
I removed the Bod_on,
the input to the chip is 4.97 v.
I posted a picture of my circuit here,
there is little blue wire near the Lm7805, its not connected to anything, I blew on it and it rolled off the breadboard ;)
http://www3.sympatico.ca/lerameur/
-
MCLR pin must be set High, not Low...
Keep your Crystal capacitor pins as short as possible. Most of the time you can remove them when using a breadboard.... the breadboard capacitance is often enough.
-
pin 1 MCLR appears to be connected to GND - try moving it to +5 V :)
EDIT - as always, Steve beat me by a couple minutes
-
a my ,all this time for a MCLR on low... I looked at it so many times...
its Working on high.
Thank you
-