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.

Up/Down Counter Circuit

Status
Not open for further replies.

Mastahh

New Member
I want a circuit that will count up from 0 to 9999.
This circuit will use a dual 7 segment display.
Also, i want it to count down at any point, for example, if the value is 30, it should go back to 29, then 28 etc.
I have done some research and know that the 4029 and 4511 will help me achieve this.

Attached is my circuit so far. It does the basic counting from 0-9 upwards and downwards.
How can i carry on from this circuit to make it count up and down using a dual 7 segment display, or two individual 7 segment displays?

Thanks a lot!!!

=]
 

Attachments

  • Circuit 4029.jpg
    Circuit 4029.jpg
    37 KB · Views: 8,193
I want a circuit that will count up from 0 to 9999.
This circuit will use a dual 7 segment display.
Also, i want it to count down at any point, for example, if the value is 30, it should go back to 29, then 28 etc.
I have done some research and know that the 4029 and 4511 will help me achieve this.

Attached is my circuit so far. It does the basic counting from 0-9 upwards and downwards.
How can i carry on from this circuit to make it count up and down using a dual 7 segment display, or two individual 7 segment displays?

Thanks a lot!!!

=]

hi,
Look at this link, it may suggest a solution.
https://www.electro-tech-online.com...asic-3-digit-led-decade-up-down-counter1.html
 
Thanks for your swift reply.

My problem is that the program i use, 'Circuit Wizard' does not include the '74' chips used within the link you provided.

I think that the only chips that will benefit and suit my purpose will be the 4029 or the 4050, combined with the 4511.

How would i establish the carry out using either of the above chips?

Thanks!
 
Thanks for your swift reply.

My problem is that the program i use, 'Circuit Wizard' does not include the '74' chips used within the link you provided.

I think that the only chips that will benefit and suit my purpose will be the 4029 or the 4050, combined with the 4511.

How would i establish the carry out using either of the above chips?

Thanks!

hi,
Do you have the datasheet for the 4029.?
You would use the /TC to cascade the 4029's, used together with the UP/DN you should be able to count up/down, ensure that /CE is the correct sense.

Do you follow ok.?

EDIT:
Look at page 807 on this pdf
 

Attachments

  • fn3304.pdf
    126.2 KB · Views: 955
Last edited:
Hey,

Im sorry but i do not follow what you are trying to say there.

Do you mind to elaborate, and perhaps use the pins on my attached diagram so it is easier to understand if that it okay??

Thanks a lot!!
 
Hey,

Im sorry but i do not follow what you are trying to say there.

Do you mind to elaborate, and perhaps use the pins on my attached diagram so it is easier to understand if that it okay??

Thanks a lot!!

hi,
Did you read that pdf document I attached to my last post.?? Let me know.?
On page 807/808 it shows the circuit diagram for the 4029 up/dwn counter.
 
hi,
I have done a quick edit of your drawing showing 3 decades, just add a 4th.

Check this against the pdf I posted...OK

EDIT:
Note in the pdf how the up/down direction is selected, the CLK pulse will count up or down depending on the state of the U/D pin.
So you will have to modify your gate latches a little..
 

Attachments

  • Image1.png
    Image1.png
    238.9 KB · Views: 1,458
Last edited:
Hey,

Yeah, thanks i have read it.
I have created a circuit with two 7 segment displays.

my problem is that when i press the count up button the first time, both displays show the number 1. Then, when it go to number 9, the 'tens' section comes down to 0. When the 'units' column counts up to 0, then the tens column goes back to 1. It is always stuck between 1 and 0.

How can i prevent this??

[The tens is the bottom 7 segment]
 

Attachments

  • Counter 4029 #2.jpg
    Counter 4029 #2.jpg
    51.8 KB · Views: 4,607
Hey,

Yeah, thanks i have read it.
I have created a circuit with two 7 segment displays.

my problem is that when i press the count up button the first time, both displays show the number 1. Then, when it go to number 9, the 'tens' section comes down to 0. When the 'units' column counts up to 0, then the tens column goes back to 1. It is always stuck between 1 and 0.

How can i prevent this??

[The tens is the bottom 7 segment]

hi,
If you relook at pages 807/808, two circuits are shown, one is for a synchronous counter and the other for a ripple thru counter.

Your circuit is a combination of both.!, I would choose the synchronous version, it uses less gates than the ripple.

Also in your circuit you are showing a count up and count down clock,,,,, the clock is common to both up and down operations its the UpDn pin that determines the count direction.
Redraw and post the final circuit
 
Hey,

Thank you so much for all your help so far.

I just have one more problem unfortunately...

My count down works fine, 000, 999, 998, 997, 996, 995, 994 etc.

However my count up has a glitch.

When i first click on the push to make to count up, all of the value go to one.
So its like 000, 111, 112, 113.

How would i prevent that so it counts normally.

Also, the second one counts up at the wrong time.
So that is like 000, 111, 112, 113... 118, 119, 110, 121, 122, 123... 128, 129, 120, 131, 132 etc

How would i make this count normally too?

Thank you so much!!

=]
 

Attachments

  • Counter 4029 #3.jpg
    Counter 4029 #3.jpg
    53.1 KB · Views: 1,761
Hey,

Thank you so much for all your help so far.

I just have one more problem unfortunately...

My count down works fine, 000, 999, 998, 997, 996, 995, 994 etc.

However my count up has a glitch.

When i first click on the push to make to count up, all of the value go to one.
So its like 000, 111, 112, 113.

How would i prevent that so it counts normally.

Also, the second one counts up at the wrong time.
So that is like 000, 111, 112, 113... 118, 119, 110, 121, 122, 123... 128, 129, 120, 131, 132 etc

How would i make this count normally too?

Thank you so much!!

=]

hi,
Add these two 10K's , you should not leave CMOS inputs open...
Rewire the clock and the Up/Dn select as shown here.

NOTE: if your switches are 'noisy' you may require a simple debounce circuit.

EDIT:
You dont need that latch on the clock circuit...!

I am assuming that the Up/Dn select switch is a latching switch.?? [ ie: single pole changeover]
 

Attachments

  • AAesp06.gif
    AAesp06.gif
    51 KB · Views: 878
  • AAesp06a.gif
    AAesp06a.gif
    47.5 KB · Views: 684
Last edited:
Hey,

I have redrawn my circuit according to both your pictures attached.
However, on the first one, nothing works at all. The 7 Segments stay frozen at value 8.

On the second one, it can only count down.
Counting up does not work at all!

Sorry if you already know this, but to count down, only the clock has to be high.
However, to count up, both the clock and the UP/DOWN has to be high.

Maybe that will help.

Thanks

=]
 
hi,
Been out for a while, I will relook at your diagram.. get back to you.

hi again,
In simulation that 1st stage is counting ok , up and down,,,, I will run the 2nd stage to confirm and post again.
 

Attachments

  • AAesp01.gif
    AAesp01.gif
    44.7 KB · Views: 628
Last edited:
hi,
Been out for a while, I will relook at your diagram.. get back to you.

hi again,
In simulation that 1st stage is counting ok , up and down,,,, I will run the 2nd stage to confirm and post again.

hi,
Ran the 2nd stage all OK.

Counts up fro 0 to 12 and then back down from 12 to 0

Can you check your layout and post a corrected circuit, just in case we are not working from the same diagram...:)
 

Attachments

  • AAesp02.gif
    AAesp02.gif
    48.9 KB · Views: 690
Hey,

Attached are the pictures you wanted me to show.

In the first picture, you can see that the count up switch is pressed but the 7 segment displays show no change.

In the second picture, all the displays start off at 9, and again, you can see that the count up switch is pressed but to no avail.

[Also, im just asking here but would there be any difference if i use the 4510 instead of 4029? The reason is because the 4510 has a reset pin, whereas the 4029 does not, and a reset would be useful to me]

Thanks a lot as always!!!

=]
 

Attachments

  • Counter 4029 #4.jpg
    Counter 4029 #4.jpg
    22.8 KB · Views: 897
  • Counter 4029 #5.jpg
    Counter 4029 #5.jpg
    53.9 KB · Views: 4,467
Hey,

Attached are the pictures you wanted me to show.

In the first picture, you can see that the count up switch is pressed but the 7 segment displays show no change.

In the second picture, all the displays start off at 9, and again, you can see that the count up switch is pressed but to no avail.

[Also, im just asking here but would there be any difference if i use the 4510 instead of 4029? The reason is because the 4510 has a reset pin, whereas the 4029 does not, and a reset would be useful to me]

Thanks a lot as always!!!

=]

hi,
Will look at your diagrams.
You could use the 4510 with RESET, but the easy way to RESET the 4029 is to set all the parallel inputs to 0V [as you have done] and use the PL pin to load zero into all the 4019's. OK.


EDIT:
Which type of switches are you using, are they normally open or normally closed or are they toggle change over switches, its IMPORTANT.

EDIT2:
Look at this clip from that datasheet, it will simplify the clocking.
 

Attachments

  • AAesp07.gif
    AAesp07.gif
    30.1 KB · Views: 587
Last edited:
Hey,

Sorry about this, i have really bad knowledge.
Which one is the PL pin??
Also, you said something about a 4019??

I am using, for the moment, PTMs, but i will improve this circuit using opto-isolators and PTMs with PICs too. This is like the building block for my final circuit.

This is what i have done to my circuit according to that attachment you provided.

It does not, unfortunately, help at all.
The displays all start at 0 but none of them work.

I think this maybe because i may have connected to Vdd section wrong.

Please evaluate my circuit.

Thanks a lot

=]


EDIT:
Sorry, forgot to mention.
The top PTM should count up and the bottom down.
I have done it "exactly" like that attachment of yours showed me.
My concern is Vdd.
 

Attachments

  • Counter 4029 #6.jpg
    Counter 4029 #6.jpg
    48.2 KB · Views: 2,254
Last edited:
Hey,

Sorry about this, i have really bad knowledge.
Which one is the PL pin??
Also, you said something about a 4019??

I am using, for the moment, PTMs, but i will improve this circuit using opto-isolators and PTMs with PICs too. This is like the building block for my final circuit.

This is what i have done to my circuit according to that attachment you provided.

It does not, unfortunately, help at all.
The displays all start at 0 but none of them work.

I think this maybe because i may have connected to Vdd section wrong.

Please evaluate my circuit.

Thanks a lot

=]


EDIT:
Sorry, forgot to mention.
The top PTM should count up and the bottom down.
I have done it "exactly" like that attachment of yours showed me.
My concern is Vdd.


hi,
My typo error 4019 should be 4029, sorry if that caused confusion.

The PL pin is marked 'LD' on your drawing...

If PTM means pushed to make switches, then it means you will have to hold the UP/Down select swiitch while you push the clock switch.

As soon as you let go of the up/down switch the clocking will change direction.!!

Use the clock method shown in that clip I posted, its simpler.

One switch clocks up the clocks down

AAesp07.gif
 
Last edited:
Due to the Push to Makes switches, that was why i had so many of those NAND gates. The arrangement i had did indeed work for the basic stuff.

When i pushed to Count Down switch, it did count down because only the clock was high.
When i pushed the Count Up switch, both clock and Up/Dn were high.

Would that help reconsider what you were recently saying??
Also, i do not understand the inputs into the clock and up/dn is the clip you posted, and the Vdd section.

Thanks

=]
 
Due to the Push to Makes switches, that was why i had so many of those NAND gates. The arrangement i had did indeed work for the basic stuff.

When i pushed to Count Down switch, it did count down because only the clock was high.
When i pushed the Count Up switch, both clock and Up/Dn were high.

Would that help reconsider what you were recently saying??
Also, i do not understand the inputs into the clock and up/dn is the clip you posted, and the Vdd section.

Thanks

=]

hi,
This is showing the clock circuit from the clip connected to the 4029's.
It also shows a RESET method.

Connect your clock up and down switches from the bottom of the 10Ks and 0V.
So when you push the switch you connect the input pin to 0V.

Connect the PL [LD] pin to 0V via a 10K and the RESET switch from the 10k to +V, when you press the PMT sw the PL pin will go high and RESET the counters to 0.
 

Attachments

  • AAesp02.gif
    AAesp02.gif
    44.7 KB · Views: 559
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top