by Toma Dana Georgiana 1221B
In this memory game, the LEDs light up in a random order each round, and the player must recreate that order by pushing the buttons that correspond to each LED.
When the start button is pressed, the game begins. The LEDs will turn on and off in a random order. The correct LED (green LED) will light up if the corresponding buttons are pressed in the same order. If not, the wrong LED (the red LED) will turn on. The current level will be displayed on the 7-segment display.
Components list:
Electric scheme:
A random sequence is established as the game begins. The LEDs are flashed in the order prescribed by the sequence at each level, and the player input is compared to the sequence. The level increases if the order is accurate; otherwise, the level is repeated. The current level is displayed on the 7-segment display. The LEDs are accompanied by a buzzer that plays distinct noises for each of them, as well as a winning and a losing sound. Each level increases the challenge by increasing the pace of the flashing LEDs and the number of LEDs that light up.
The finished code can be found in the download section.
The game functions properly in its final form. I learned how to use Arduino software to make a simple project as well as how to connect the various components.