Created a touchless Covid Free Electronic Dice using Arduino to play some board games with my son. My new project is an amazing way of giving our younger generation the taste of board games while staying COVID free.
Created a touchless covid free electronic dice using Arduino to play some board games with my
son. My new project is an amazing way of giving our younger generation the taste of board games
while staying covid free. This video is sponsored by PCBWay. PCBWay specializes in manufacturing of
very high quality low volume colored PCBs at a very budgetary price. In addition to standard PCBs
you can order advanced PCBs, aluminum PCBs, rigid flex PCBs. They also provide PCB assembly and
other related services which can meet your need at the greatest extent. For this project we need
one push button switch, one Arduino Nano, 8x8 LED matrix with max 7 219 IC, step-up power module,
IR sensor, AA battery holder and batteries and some connecting cables. Using a step-up power
module connected to two AA batteries I'm powering up the Arduino Nano. In my logic I'm using an IR
module to send interrupts which changes the face of the dice which is then displayed using the 8x8
LED matrix. If you want to know more about DIY IR module please check out my tutorial number 21
DIY IR module. The link is in the description below. If you want to change the face of the dice
by shaking it, you can use a tilt sensor to generate the interrupts. If you want to store
the result in a database you can use a ESP8266 board and send the result over Wi-Fi and store
it in a database. The possibilities are endless. However I just wanted to keep my circuit simple.
The code is very simple. Let's start by including the ledcontrol.h library. I have included the
link to the library in the description below. Next let's define all the pins that we are going
to use in our code. After that you'll find few functions that work in combination to generate
the dice faces and the dice animation. In the setup section we are setting up the pin mode of
the IR sensor and initializing the display. We are also showing the initial animation where in my case
number 6 flies from right to left and fills up the led display. In the loop section I'm reading
the IR sensor to check if someone has moved their hand over the sensor module. If a motion is
detected then a random number between 1 and 6 is generated and based on that the face of the dice
changes using the showDicePick function. Now let's create the body of the dice. From a broken piece
of chipboard I extracted the six sides of the dice. Next using a double-sided tape I attached
the AA battery holder to the bottom of the dice. Then I soldered the step-up converter to the AA
battery holder. The step-up boost converter has to be adjusted to approximately 5 volts before
installation by twisting the variable resistance in it. I made a hole on one of the sides for the
push-button switch and then glued the push-button switch to it. I hot-glued the 8x8 led matrix to
the top section of the dice. 8x8 led matrix with max 7 2 1 9 driver IC is a very cheap easy to
code and it takes up very little space in your project. The top section also has the IR transmitter
and receiver LEDs. Pretty much I hot-glued them all and then attached them to the Arduino Nano.
Then I made four holes on the bottom plate and attached all the sides to it. Let's do a quick
test before finalizing the project. Looks promising isn't it? Cool! So this is how my final setup looks
like. I covered the led matrix with a translucent black sheet. Let me know what you guys think of
this project. If you have any suggestions or advice please feel free to drop a comment below.
Thanks again for watching this video. I hope it helps you. If you want to support me you can
subscribe to my channel and watch my other videos. Thanks! See you again in my next video. Bye now!