On the temporary board the led was blinking very fast (suppose to have 1 sec pause)
Only when I set MCLR to +5v it started to run ok.
On the temporary board the led was blinking very fast (suppose to have 1 sec pause)
Only when I set MCLR to +5v it started to run ok.
Sounds like bad soldering or bad connections. Glad you have it sorted though. External power source making it work points to sever current loss accross your tranny/7805 circuit. Could it be your bridge rectifier is shot in the tranny? low power output?
The LED was probably dumping your +5v line repeatedly causing a brown out causing your PIC to reset making it look like it was blinking really fast (which it probably was). If your MCLR was floating (i.e. not connected), same thing may happen (i.e. brown out triggers MCLR just by chance). Connecting MCLR to Vdd might've help alleviate the situation, but sounds to me like a temporary fix.
Not a good practice to leave MCLR floating, unless you are absolutely sure it's tied internally (which I'm not sure the 16F877A has that exact option).
Add an extra resistor inline with your LED (make it really dim), pull the +5v off of MCLR and see what happens (less current flow across the LED, less load on the main +5v rail, etc).
Then maybe try adding another capacitor between Vdd and Vss...can never have too much of that...
Bookmarks