![]() ![]() */ #include const int NewnumberButton = 2 // Digital IO pin 2 is connected to the Newnumber button with a normally open contact // Pin 2 will be driven with the built-in pull-up resistor to make it normally HIGH // The switch will pull the pin to ground momentarily. ![]() * This is the code for a Bingo Machine developed and produced by Pierre Pennings (November 2018) The machine uses 2 DIGIT large A4 sized 7-Segment displays made with WS2811 LED strip powered with 12V (pairs of 3 LEDs with 1 control chip) Each segment consisting of 3 LEDs is adressed with just one control adress Each display has 7 segments plus a decimal point (DP) The numbers presented on the 2 displays run from 1 to 75, just like in a normal BINGO game A momentary push button is connected to GND and to digital IO pin 6 of an ARDUINO UNO Pushing the button starts the generation of a New random Number After a short "Light Show 1" the random number is shown on the two 7-Segment displays The generated Number is also stored in an Array called SCORE consisting of 75 positions either filled with "0" or "1" If the generated New Number allready exist, automatically a new random number is generated All electronics including the ARDUINO UNO itself have been built in a separate Score Board Display The 75 numbers are lit with one WS2812B controller chips with one SMD5050 LED each (powered with 5 V) The Score Board shows all the random numbers generated until a valid BINGO is achieved A push button called "BINGO" will end the round with a short "BingoLightShow" Hereafter the SCORE array is cleared and a new round can be started A New Round can also be started by toggeling the power switch (disconnecting the 12V power) which will RESET the ARDUINO and restart the programme A 12V, 2A charger supplies the power to the complete BINGO machine The 12 V input on the ARDUINO power jack has been modified to enable power switching (on - off) The 5 V power for the 99 LEDs (75 + 24) used for the Score Board is derived from the 12V input power by means of a 7805 voltage regulator (which can nearly handle the current drawn by the WS2812 LED strip) installing a Heatsink or a power version is recommended This code is licensed under GP元+ license. ![]() The layout in a Fritzing diagram looks as follows: I have made the sketch for the Arduino in such a way that the power demand of the scoreboard is moderate. The 5 V power for the 99 LEDs (75 + 24) used for the scoreboard is derived from the 12V input power by means of a 7805 voltage regulator (which can nearly handle the current drawn by the WS2812 LED strip) installing a Heatsink or a power version is recommended (in an update I will probably add a power transistor to deal with the required 5V power mainly consumed by the 99 WS2812 LEDs inside the scoreboard. The 12V input on the Arduino power jack has been modified to enable power switching (on - off). Hereafter the SCORE array is cleared and a new round can be started.Ī New Round can also be started by toggling the power switch (disconnecting the 12V power) which will RESET the Arduino and restart the programme.Ī 12V, 2A charger supplies the power to the complete Bingo Machine. ![]() A push button called "BINGO" will end the round with a short "BingoLightShow" The scoreboard keeps showing all the random numbers generated until a valid Bingo is achieved. The new number is lit on the scoreboard (with 75 numbers) and at the same time the new number is shown on the 7-Segment displays The generated number is stored in an array called SCORE consisting of 75 positions either filled with "0" or "1." If the generated new number already exists, automatically a new random number is generated. ![]()
0 Comments
Leave a Reply. |