Problem in driving two segment together

Thread Starter

Vindhyachal Takniki

Joined Nov 3, 2014
562
1. I have attached two pic 1 & 2. Driving together two segment as in circuit attached.
Since segment pins are drived from same data pins, so I have done multiplex them using bc557.
2. problem is when I display two different character on segments, there is shadow of each segment on another segment. Foe example in pc1, 12 is displayed. First segment as 1 on it & second segment has 2 on it. As can be seen, there is shadow of 2 on segment 1 ans 1 on segment 2.
3. I dont know why it it is happening. Pic2 shows 11 displayed on it which is correct probably because both overshadow each other.
4. Ckt attached shows thee segment & MCU is powered by +5V. BC557 base is driven by MCU open drain pins at T1 & T2. Code is while 1 loop where eac segment is refreshed every 1ms. I have also increased time to 10ms, but same result.1.png 2.png ckt.png
 

bertus

Joined Apr 5, 2008
20,888
Hello,

It looks like the one transistor is not in complete off state when the other transistor is active.
Try a resistor of 2 - 10 K from the base to the +5 Volts of each transistor.

Bertus
 

John P

Joined Oct 14, 2008
1,848
You can't drive a transistor that way, and you might damage your processor. What you're doing is turning the transistors on without a current-limiting resistor whenever the processor pin goes low. This will cause a very large current flow, and there may be interaction between two outputs. Put the 1K resistors between the transistor bases and the processor pins, and put larger resistors from the bases to +5 in place of R1 and R2; 22K would be about right.
 

JohnInTX

Joined Jun 26, 2012
4,344
What the others have said plus be sure your code turns off the active digit drive before changing the segment pattern to the new digit. Turn on the new digit driver only after the new segment pattern has been written.
 

John P

Joined Oct 14, 2008
1,848
JohnInTx is making a good point--you'll see that ghosting effect if the digit selection and segment selection overlap in time. If you can't change all the outputs simultaneously, turn off both digit drivers T1 and T2, then set up the segment drive for the other digit, then turn T1 or T2 on.
 

Thread Starter

Vindhyachal Takniki

Joined Nov 3, 2014
562
Modified the circuit as attached.
Also code is bit changed. I had enabled segment first & then data was written.
Now have put data & then enabled segment.Now it is working fine. Thanks for help.
Untitled.png
 
Top