PDA

View Full Version : power problem (newbie here!)



clocks
- 29th April 2009, 23:39
Hi all,

I'm making a very simple clock using a PIC16F870, with 4x 7-segment displays and latching drivers (HCF4511BE) to keep them nice and bright.

In testing the circuit with simple static digits, I get a problem when I connect more than two of the displays. I've worked out that it's a power issue as the 5 volt regulator (L7 805CV) I'm using is getting very hot.

What it the best way to isolate the logic from the display circuitry?

thanks for your time!

BobK
- 30th April 2009, 00:54
Hi clocks,

Welcome to the forum. Do you have a schematic of your project that you can share with us so that we can get an idea of what your circuit consists of? Do you have current limiting resistors between the 4511's and the displays?

BobK

clocks
- 30th April 2009, 01:16
thanks for the interest nd quick response!

below the schematic for a single display (with R220 resistors in place)

the same is repeated four times using Portc.4-7 to control the latches.

and the code:

B var portc.0
C var portc.1
D var portc.2
A var portc.3
SEG4 var portc.4
SEG3 var portc.5
SEG2 var portc.6
SEG1 var portc.7


trisc = %00000000

adcon1 = 7


test:
low seg4
gosub number1
high seg4
pause 1000

low seg3
gosub number2
high seg3
pause 1000

low seg2
gosub number3
high seg2
pause 1000

low seg1
gosub number4
high seg1
pause 1000
goto test



BLANK:
HIGH D
LOW C
HIGH B
LOW A
return


NUMBER0:
LOW D
LOW C
LOW B
LOW A
return

NUMBER1:
LOW D
LOW C
LOW B
HIGH A
return

NUMBER2:
LOW D
LOW C
HIGH B
LOW A
return

NUMBER3:
LOW D
LOW C
HIGH B
HIGH A
return

NUMBER4:
LOW D
HIGH C
LOW B
LOW A
return



end

clocks
- 30th April 2009, 01:32
(sorry, it may not be clear that I have tied all the BCDA driver inputs together)

BobK
- 30th April 2009, 11:32
Hi Clocks,

Any particular reason you are using LEDs instead of an LCD? Have you seen the data sheet for the 4511? You can do all 4 displays with 1-4511 and the SEG 1-4 pins would then go to transistors to drive the ground pins on the displays. Microchip has an application note showing how to make a clock using just the displays connected directly to the PIC. You might want to check it out.

I have a clock product that I make that uses the Maxim DS1337 clock chip that has 2 alarm outputs. I don't have a fixed display on the product but when I need to check to make sure all is well with it, I plug a serial display onto the board. 4 PIC pins to the clock chip and 1 pin to the display.

There have been quite a few clock programs on this forum over the past few years. You might want to do a search for them and also look at the Microchip site (www.microchip.com) for the app note on the clock.

I must be honest with you though, I have never built a clock with LED displays but I can provide you with some guidance and if I can't help you there are many great people on the forum here that probably can.

HTH,

BobK

mister_e
- 30th April 2009, 12:00
How hot is hot? 7 leds running ~15mA each = 105mA, worst case scenario you multiple it by the number of display you have + few mA for your PIC.

Then you multiply it with the voltage across your voltage regulator (Vo-Vi), and you have the power dissipation for your voltage regulator.

Assuming you're running it from 12 volt, things can heat up fast indeed. Heat sink will help, but not always necessary.

BobK
- 30th April 2009, 21:40
Hi Mister E,

Thanks for stepping in there. I kinda got off track with his original question!

BobK

clocks
- 1st May 2009, 00:26
Thank you gentlemen,

what I had (crucially!) forgotten to add, was that the program on the pic would stop working entirely when the more than two segments were on at a time. I have since found that it must be due to the PIC's current sourcing limitations (is this correct?). Regardless, I have added some CD4050BE buffers and now it all works fine.

I really appreciate your time and expertise. thank you.

Ps Not using a LCD as I don't have one! Beside, there's something appealing, almost 'retro' about 7 segment displays I find....



test code tags

Acetronics2
- 1st May 2009, 10:23
Hi Steve + Clocks

You do not use 105, but 4 x 105 mA ... ( no multiplexing !!! )

so, at least 2v * 420 mA = 850 mW to dissipate in the 7805 !!!

some cooling necessary then !!! ( 10° C/W will be Ok )

Alain

clocks
- 2nd May 2009, 12:09
Hi Alain,

Indeed - no multiplexing (I need bright displays).

How do cool this down - or are there high rated voltage regulators out there?
I don't understand your last sentence; what is : 10° C/W?

thanks for your help!

Acetronics2
- 2nd May 2009, 13:18
I don't understand your last sentence; what is : 10° C/W?



Hi,

It's the thermal resistance of the dissipator to use ... it's like Resistance's "Ohms" ... but for heat dissipation value.

That means it will heat at a rate of 10°C per dissipated Watt ... in your design, the temp of dissipator will be ( at blind sight ! ) ~ 25°C + (2 x 10°C) = 45°C

Alain