Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

PIC problems with 12V supply

Status
Not open for further replies.

quickrik

New Member
Hi there,

I'm having a funny thing happening with a circuit I've just developed.

A PIC16F876A, two buttons, and a backlit alpha LCD all powered from a 7805. When the 7805 was powered by a 9V battery everything works fine.

If I power it from a 12v battery the LCD contrast goes really white (its a blue/white LCD) and the buttons stop having any effect. The buttons are tied to ground with a 10K resistor. And the LCD backlight is powered striaght from the 5V and the contrast tied to ground.

I can make the circuit work by putting a 330ohm resistor in series on the 12v side of the 7805. Is 12v too much for a 7805?

Could somebody explain what is going on?

Many thanks Rik
 
Have you measured the voltage output from the 7805?

It sounds like there is more than 5 Volt due, as Nigel said, to a wiring error.

Or the 7805 could be faulty.

I would disconnect the PIC and the display and measure the voltage.
 
May be, there is too much power consumed by 7805. You should calculate it if exceed the max power that 7805 can consumed.
 
hi
Check your 7805 connections and the 7805, if you find the wiring OK.

Check the +5V when using the 9V battery, its probably more than +5V!
 
Last edited:
I think the LCD backlight is drawing more current. Mostly blue backlight with white character LCD’s drawing more current than the other LCD’s.
Try giving power to the LCD backlight from the input side of the 7805 through a resistor.

Also you must put a V/R between Contrast pin & GND & adjust the contrast.
 
What are you using for the 12V supply?

Are you sure it can supply enough current?

Does the LM7805 get hot?

The LM7805 can handle 12V with no problem and I doubt you're using that much current; I'd bet on a wiring error being the cause of youre porblem.
 
I can make the circuit work by putting a 330ohm resistor in series on the 12v side of the 7805.
It's oscillating. Make sure you have the capacitors shown in the data sheet/app notes.
 
My be heat?

Hero999 said:
Does the LM7805 get hot?

In case of 9V there is 1 volt more than the 7805 requirments. In case of 12V, it is 4 to 5 volts extra and that will make it hot. if this is the case use a proper heat sink.
 
It still depends on the current required by the load right? If the output current is low enough, even with more than 12 V input, no heat sink is required.
 
I hope he is having a 2 line LCD display. My 16x2 LCD’s with backlight white takes only 50mA when working. For all the LCD’s I have I’m giving supply to the backlight from the input side of the regulator.

No more problems occurred yet. No more heat sinks added to the regulator. Even for 40X4 LCD’s. My supply is 12V.
 
Thanks for the help. I was not using the capacitors around the regulator. Works fine now ther are in place. My electroincs is not very good. What do these capacitors do?
 
Nigel Goodwin said:
I would suspect you've wired it incorrectly, either the 7805 the wrong way round, or you've not fitted the reqired capacitors?.

I have a really, really stupid question: Do you absolutely need caps for the 7805? I used a 9V wall wart with a 78M05 and it powered my PIC16F876A just fine. Of course, It could just be a low-voltage fluke or something.
 
ArtemisGoldfish said:
I have a really, really stupid question: Do you absolutely need caps for the 7805? I used a 9V wall wart with a 78M05 and it powered my PIC16F876A just fine. Of course, It could just be a low-voltage fluke or something.

You should ALWAYS use them, you might occasionally, under specific conditions, get away with it - but when your input voltage or loads varies slightly it may well start to oscillate. PIC's are very tolerent of their supply, and would probably still work even with the regulator oscillating, but it's obviously not a good idea!.

The capacitors are supposed to be there, fit them!!.
 
Mind you if your regulator is oscilating and the PIC is controlled from an internal oscillator the interal oscillator frequency changes with voltage so your running frequency changes which can throw a lot of monkey wrenches into a program if you don't worry about it early. Sure for a basic project it might work without any problems, it's when you start adding on that things happen, it's why there are recommend bypass caps and external circuit loading conditions on just about every IC in existence.
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top