Electrical – IC to count milliseconds

counterintegrated-circuit

As part of a school project, I need to measure milliseconds from the start of a timer. I will need that value to later process it, subtracting and adding it later multiple times. At most the timer will last 5 seconds.

I have a clock signal with a frequency of 1kHz, what component can I use as a counter?

In school we've studied the theoretical components, but I need one(or more) actual IC that can count up to 5000 (probably 2^13). The only operations i need to do are add 1 and reset.

Best Answer

CD4040 (arguably the base product) & CD4020, CD4024, CD4060 are a counter/divider family that divide by 2^N. Some have all stages output but fewer stages. Some have more stages but not all outputs available. You can divide 1 kHz by 10 bits = 1024 divide = 1.024s/transition or you can use simple feedback to reset the counter at 1000 counts. You can use more or less stages as desired.

TI CD4040 famiy datasheet
Fairchild CD4040 family datasheet

The diagram below (from the Fairchild data sheet) shows the block diagram of the 4040 4020 and 4060 counter/dividers. It can be seen that the 4040 has all outputs accessible and tghe others do not, but they have more stages. These dividers can be "chained". By detecting the 1000 counts state a reset pulse can be generated turning eg a 4040 into a divide by 1000. A simple diode gate with diodes from outputs 10 9 8 7 6 4 to reset and a pullup resistor on the reset line will reset the counter at count 1111101000 = 1000 base 10 giving a 1 Hz output for 1 kHz in.

enter image description here

OR there are dedicated divide and display ICs that do this at a higher level.

OR Easiest fastest and possibly cheapest overall is to use a low cost microcontroller (Arduino clone or other). That would also be the most flexible solution.