How to make Arduino pong game-Arduino Project

In this project, we will learn how to build Arduino pong game with UNO and Oled color display screen. The Pong game is the very easiest arcade game. Now you can make it with Arduino; you can play with the computer.

User Also Read:

Getting Started with Raspberry Pi3.

DIY Arduino Voltmeter.

You can play towards the laptop through controlling the touch button. Every time a participant rankings, the score displayed on the Oled screen. The first player to attain eight points to wins! It’s far a fun mission to build and as you’re going to find out, it won’t take you more than 10 minutes to make it. Let’s start…,

Arduino pong game step by step guide:

For Arduino pong game project we need Arduino UNO or Mega 2560, it is your choice. One color OLED display, A breadboard, Two touch button to play game one for the right side other for the left side.

List of required components:

  • Arduino Board (Any) 5$.
  • OLED Display 10$.
  • Two Buttons.
  • 1x beadboard.
  • jumper wires.

The cost of this project is around about 17$ max however you can use Arduino Nano board to make it more compatible in size to fit in the box and inexpensive.

Wiring:

Now connect all components together. At first, we will connect display and buttons on the breadboard then connect all the ground to negative rail on the breadboard then connect negative rail to Arduino GND pin with jumper wires.

OLED Connections:

GND to the Breadboard negative rail.

Vcc to Arduino 3.3V of the Arduino.

SCL to Digital Pin 13 of the Arduino.

SDA to Digital Pin 11 of the Arduino.

Reset to Digital Pin 9 of the Arduino.

DC pin to Digital Pin 8 of the Arduino.

CS pin to Digital Pin 10 of the Arduino.

Now next step is to connect left button to digital pin3 and right button to digital pin2. We made all the connection of components now the final step is to upload the code to Arduino board. Read below for the Source code of this project.

How to make Arduino pong game-Arduino Project

Code for Arduino pong game project:

Now the final step is to upload the code to Arduino board to play pong game. You need two libraries for this project to work code correctly.

Step 1: Download Adafruit GFX library from here.

Step 2: Download Color OLED Library from here

Step 3: when you download the both libraries from the above links now you have to install them on your Arduino IDE. If you don’t know how to install libraries on Arduino IDE tools, No need to worry. Just follow Step 4 and 5.

Step 4: Open Arduino Goto Sketch then select Include Library from the scroll down menu.

Step 5: Select Add.zip Library give the library zip file path which you have download. That’s it.

How to make Arduino pong game-Arduino Project

Step 6: When you successfully installed libraries now you need to upload Main code to Arduino board. You can find the code from here.

Now you have done everything give power to Arduino and enjoy the Most famous PONG GAME on your Arduino 😀

NOTE: If you want the modification to the game like ball speed, score limit, you have to change some values from the below code.

If you like my work must comment below and share with others. For any question OR help drop comment below 🙂

 

Leave a Reply

Subscribe To Our Newsletter

Subscribe To Our Newsletter

Join our mailing list to receive the latest news and updates from our team.

You have Successfully Subscribed!

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close