Holiday

Search Site

Dice Project using 555 and 4017B  IC's

Building the circuit:

 

 

The components you will need for this circuit are:

Overview / how it works:

 This circuit works using two integrated circuits – a 555 timer and a 4017b decade counter. Since we are not using a programmable micro controller, the dice is not ‘random’. Instead it only appears to be random because the 555 timer make the decade counter count so fast.

 

The 4017B decade counter is essentially what it says in the name, a counter. It has 10 output pins (hence decade – meaning ten) a reset pin, a clock pin, an enable pin, and then obviously power and ground. The enable pin is simply used to enable the counting function, when it is LOW the counting is enabled, however when it goes HIGH the counting stops. The clock pin is used to advance the counting; when the chip is first set, the Q0 pin (output 1) is HIGH, however if you pulse the clock pin once – by making it HIGH, then LOW again, the Q1 pin will go HIGH, and the Q0 pin will go LOW. In the same way, every time you pulse the clock pin, the output will advance to the next, until it reaches Q9, after which it starts again.

 

In our circuit we don’t want all ten outputs, we only want 6, so we hook the 7th output up to the reset pin of the chip, meaning when it tries to enable the seventh pin, it resets itself to the first again.

 

The circuit works by connecting up the 555 timer so it outputs an astable pulse very quickly out of pin 3. Then we take that as a feed into the clock pin on the 4017b decade counter. This then makes the counter, cycle very fast, giving the impression of randomness when you look at the LEDs flashing. When we stop the 555 timer pulsing, it stops the decade counter in its cycle so there is one LED solidly on (which corresponds to a number from 1 to 6). A push to make switch is used, and is then inverted so when you press it, the dice rolls rather than stops rolling, however a push to break switch could be used instead of this part of the circuit.

The Circuit:

Circuit Diagram for the dice

This is the finished schematic of the circuit; however pins 8 and 16 on the 4017b chip have not shown up. Pin 8 needs to be connected to ground, and pin 16 to power. You can adapt this circuit to have up to 10 LEDs, by moving the reset from output number 6 on the counter, to one further down. You can see in here the 555 timer, with its output going to the clock pin of the 4017B. Also note the way the button is hooked up with the transistor to invert it, going into the enable pin on the 4017B.

Below are the images of the circuit up and working on a breadboard:

Dice image  Dice image

Dice image  Dice image

Dice image  Dice image

Dice image

Back to top