loading

How to troubleshooting counter?

We had a problem troubleshooting our project "Counter"? We had set it to count to 0 to 9. But the only output we get is 2 and 3. I would like to ask, what would be the possible errors due to the outputs. Thank you in advance. We really appreciate your answer.

sort by: active | newest | oldest
jehniel(^_^) (author) 5 years ago
Sir 74LS47 and 74LS93
So, a BCD decoder and a 4 bit counter. Yes, that should work - but you are doing something wrong. Without seeing your circuit nothing more can be said.

What you can try:
- download, read and understand the datasheets of the ICs (not everything, but at least the function of the pins)
- compare the your circuit diagram against the datasheets
- make sure the pins are correct SMD might have a different pin out compared to DIP
- check your wiring against the circuit diagram. Do it again. Got to sleep and compare once more. Let someone else do it. Don't just look at it, measure the connections and the
- try another set of ICs (they might be faulty). If you are 100% sure, your circuit is okay, buy some new ICs from another vendor (the whole batch might be faulty).
- make sure, the power supply is okay - check voltage, current, ripple, noise
- put a small 100nF ceramic capacitor between +5V anf GND _directly_ at each IC
- debounce your clock signal
- do a measurement at the outputs of the counter - the lowest bit has to toggle with every clock cycle, the second bit with every second cycle, the third with every fourth and the fourth bit with every eighth cycle (except for the roll-over from 9 to 0)

And next time when you ask such a question, please show at least your circuit diagram. Our long-distance crystal balls are not reliable enough.
iceng5 years ago
Most problems occur with wiring the 7-segment LED, they are not all the
pinout the same.
One way to make sure is to test the 7-seg alone with a resistor on a
clip cord to ground and +5 to both pins and locate all of the segments
a b c d e f g ...
Do they correspond to your wiring of the 74LS47 ?

Also include the LS93 Sheet for you :)

A
74LS47-7segLED.gif74ls93.png
AndyGadget5 years ago
 
Have you properly decoupled your supply rails?
Start with a 100uF capacitor where the power enters the board and a 0.1uF across the power rails vary close to the power pins of each IC.
SHOW YOUR CIRCUIT.

Odds on, either you failed to tie a line to the right voltage, or you're getting noise.

Steve
thegeeke5 years ago
I don't know what language you are using, so just translate the following:

X=(-1)
Count:
X=(X+1)
If X=9 then end else goto count

This should give the value of x as your counter. Add/change any code as necessary, but this should put you on the right track. Although I'm just a beginner in programming, I am currently using this basic code in a project I am working on, and on previous projects. It works... I don't know if it's the most effecient code, but it works. Just be sure to put X=(-1) before your count tag.
What kind of counter is it? Assuming this is a digital counter what platform are you using? Can you post your code so we can help debug it?