Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] 7 segment multiplexing problem

Status
Not open for further replies.
dear SunnySkyguy
i notice that same problem not on 7 segment and multiplexing it take very small time the problem in fetch data from ds1307 i make it fetch every 1 minute it blink at that moment
so how to fix it


the multiplexing as below

new connection.png





Thanks

- - - Updated - - -

Dear
i measure the time of get data from the ds1307 it only 3.28 ms as the function Get_DS1307_RTC_Info();
kindly need any help

- - - Updated - - -

Dear I think the blink from my pc sometimes happen and sometimes not so i attached the circuit kindly if anyone try it and tell me it blink or not
and i need solution for the led that indicate the PM time

Thanks
 

Attachments

  • clock 20141002 0957.rar
    28.1 KB · Views: 67
Last edited:

dear SunnySkyguy
i notice that same problem not on 7 segment and multiplexing it take very small time the problem in fetch data from ds1307 i make it fetch every 1 minute it blink at that moment
so how to fix it


the multiplexing as below

View attachment 109976





Thanks

- - - Updated - - -

Dear
i measure the time of get data from the ds1307 it only 3.28 ms as the function Get_DS1307_RTC_Info();
kindly need any help

- - - Updated - - -

Dear I think the blink from my pc sometimes happen and sometimes not so i attached the circuit kindly if anyone try it and tell me it blink or not
and i need solution for the led that indicate the PM time

Thanks
A scope would diagnose this pretty fast such as tracing back OE.
Monitor the LED voltage and trace back.
 

Dear
I did not understand what do you mean?
Is it work on your PC without blink (7 segments) or there is a problem?
Did you mean the PM led?

Thanks for reply
 

Dears
i need help with LED and 7 segment with 74595 the 7 segment display numbers ok but the led blink the two connected to same 74595 and have the same duration in on and off
 

Dear SunnySkyguy

OE of 74595 connect to ground as shown



Kindly more details... what do you mean? your idea?
 

Attachments

  • oe.png
    oe.png
    26.2 KB · Views: 72

I traced the "PM" line with the scope and see that the signal is 6mS apart and it lasted for only 0.4mS. Which is about (1/15)*100 duty cycle.

I dont think you are able to lite a LED with such low duty without flickering.

Why not just light it the same way you light the seconds LED or use a RS_FF to light it as you only need one pulse every 12 hours from PM.

About OE line, I think you have to have a better understanding on how 74595 is constructed inside the chip. The 74595 is more or less like a 74164 shift register with an 8-bit latch connected to the Q0-Q7 outputs of 164. OE is the control of the latch.

Read the block diagram of 74595 datasheet few more times and also try to study how others design POV multiplexed LED circuits using this chip.

Allen
 
Last edited:

Thanks Allen6502
I'll read the 74595 data sheet and try to understand how other use it, i think all of you want me to enable and disable the chip or something like that.
I did connect the PM Led direct because i want to connect another 7 led to indicate the week day
I have question how can i calculate the perfect time (25fps) for this circuit or any circuit, i mean the equations, calculation, how to measure it, i have some information and i want to expand it.
Thanks to all

- - - Updated - - -

Dear Allen6502
did you notice a blink in the 7 segments cause some time i notice it and some time not, i think it is from my PC as i use simulation with it

Thanks for your reply
 

Dears
As i see in most sites the OE connect to ground as i do with my circuit, so what your idea about it, kindly explain.
i need help, more details,
anyone have done this digital clock with LEDs and 7 segment with 8051, anyone have any idea, i reached the limit of saturation

Waiting ..........................................................................................................................................................................................................
 

As i see in most sites the OE connect to ground as i do with my circuit, so what your idea about it, kindly explain.i need help, more details, anyone have done this digital clock with LEDs and 7 segment with 8051, anyone have any idea, i reached the limit of saturation
Normally when something does not work, you compare your timing diagram with the IC Spec. The HC595 is a fast chip. Everything happens well under 100ns.
Your flashing is code related bug perhaps.

Your output is 4 bytes of serial data into DS with SHCP as clock then latch it with STCP. Both are rising edge active. Then repeat every second. for new time.

Pls. hand sketch or DSO your timing diagrams, & post OK?
 

Dear SunnySkyguy

I send 3 byte to 74595 and plan to send the 4th byte as week's days the code as:

Code:
void select_display(int digit,select1,select2)
{unsigned char i,value;
Latch=0;
value=Seven_Segment_Selector[select2];
for(i=0;i<8;++i)
{Data=value&0x01;
Clock=0;
Clock=1;
value>>=1;}
value=Seven_Segment_Selector[select1];
for(i=0;i<8;++i)
{Data=value&0x01;
Clock=0;
Clock=1;
value>>=1;}
value=Seven_Segment_Digit[digit];
for(i=0;i<8;++i)
{Data=value&0x01;
Clock=0;
Clock=1;
value>>=1;}
Latch=1;}

i select the 7 segment and led as

Code:
for(i=0;i<170;++i){
	select_display( pInfoArray[0]/10,0,8 );//Seconds higher nibble
	select_display( pInfoArray[0]%10,1,8 );//Seconds lower nibble
	select_display( pInfoArray[1]/10,2,8 );//min MSB
	select_display( pInfoArray[1]%10,3,8 );//min LSB
	if(pInfoArray[2]/10==0);else select_display( pInfoArray[2]/10,4,8 );
	select_display( pInfoArray[2]%10,5,8 );
	if(pInfoArray[4]/10==0);else select_display( pInfoArray[4]/10,6,8 );
	select_display( pInfoArray[4]%10,7,8 );
	if(pInfoArray[5]/10==0);else select_display( pInfoArray[5]/10,8,0 );
	select_display( pInfoArray[5]%10,8,1);
	select_display( pInfoArray[6]/10,8,2 );
	select_display( pInfoArray[6]%10,8,3 );
	select_display( 2,8,4 );
	select_display( 0,8,5 );
	if(pInfoArray[7]==1)select_display(0,8,6 );//select pm led	
	}

this code is running in loop for the remaining of second then i go and fetch the info form ds1307 and display it

this what i do what is the going wrong?
 

I draw simple diagram for the circuit it take a 3.73ms to display for the first time the diagram repeat it self 183 times (complete 1 sec), and take a 3.35ms to read new info from ds1307 and enter 183 times loop to complete the 2nd second and so on
i use OE to disable the 74595's when reading from DS1307
 

Attachments

  • diagram.jpg
    diagram.jpg
    1,006.4 KB · Views: 81

Dears
Kindly any advice

- - - Updated - - -

Dears
Kindly any advice
 

Are you testing in Proteus or hardware ? If in Proteus then have you adjusted refresh delay for 7 Seg model in proteus by right clicking and opening its properties ?

Please zip and post your complete project files. I will modify and add Timer ISR code for SSD refresh. That will solve the problem.
 
Last edited:

Dear milan.rajik
thanks for reply
I want to test hardware and my code with Proteus, you mean my code ok and hardware but Proteus do this or as happen in Proteus happen in real circuit i have a problem in led also ?
i attach my code with circuit and i'll attached i circuit that have 24 led work as multiplexing they should ON all time but in Proteus Not work as i want is my code ok and my hardware ok or i have wrong

kindly need help
 

Attachments

  • testRTC.zip
    29.2 KB · Views: 76
  • date&time.zip
    33.2 KB · Views: 65

If i connect the circuit in Bread Board it work or i see the blinking
What about the LED no refresh time
the 15 ms not display the digit
I mean if i connect real chips and circuit it ok or i have the same blinking in Proteus
 

the code for LEDs and clock are as attached
 

Attachments

  • clock.zip
    83.5 KB · Views: 67
  • Main.rar
    448 bytes · Views: 66

I saw your code. It seems you are using code from saeedstudio.blogspot.com It will take sometime to study the code and modify it so that it works properly. If you just want to display DS1307 time on 6 SSDs then I can write a code for you using mikroC PRO 8051 compiler. I don't have Keil C51 to compile and test your code.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top