Introduction: Tic Tac Toe Game With Arduino Mega 2560
Hi every body.
This is my third post here.
I came back this time with the funny Tic Tac Toe game in a new edition.
I searched the web for similar project, but the idea here is unique. I HOPE :)
So lets start now.
Step 1: Tools
We shall need:
9 pcs of bi-color LEDs (Red/Green for example)
9 pcs of 330 ohm resistor
2 pcs of Male/Male long wires (pack of 9 for each color of the LEDs)
2 pcs of Male/Male long wires (pack of 7 for each keypad)
1 pc of Male/Male long wire (for GND connection)
1 pc of I2C LCD
1 pc of 9 VDC battery with holder and ON/OFF switch
1 pc of Arduino Mega 2560
1 pc of wood box (for examle 35x15x4 cm)
Step 2: Connection
First step: we connect the two keypads to pins 2 thru 8 and A0 thru A6
Second step: we connect the LCD to VCC, GND, SDL, and SDA ports
Third step: we connect the Red LED Anodes to pins 51, 49, 47, thru 35
Fourth step: we connect the Green LED Anodes to pins 50, 48, 46, thru 34
Fifth Step: we connect the common cathode for each LED to 330 ohm resistors and connect all the resistors together
Sixth step: we connect the GND of the Mega to the common terminal of the 330 ohm resistors
Seventh step: connect the battery and upload the code
Eighth step: ENJOY :D
Step 3: The CODE
We have a be nice policy.
Please be positive and constructive.