Industrial manufacturing
Industrial Internet of Things | Industrial materials | Equipment Maintenance and Repair | Industrial programming |
home  MfgRobots >> Industrial manufacturing >  >> Manufacturing Technology >> Manufacturing process

Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial

Components and supplies

Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Arduino Nano R3
×1
Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Digilent WS2812 Addressable LED Strip
×1
Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Buzzer
×1
Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Tactile Switch, Top Actuated
×4
Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
General Purpose Transistor NPN
×1
Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Resistor 2.21k ohm
×1

Apps and online services

Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial
Arduino IDE

About this project

In this project it is presented 1-dimensional version of the classic game ‘Pong’ made with NeoPixel LED strip. The game is for 2 players, in which the ‘ball’ the travels down the length of the LED strip, and will bounce back if the button is pressed when few end LEDs are illuminated.

The speed of the ball is changed after every hit, making it more difficult to hit the ball in time.

Device is very simple and easy to make and contains the following components:

- Arduino Nano microcontroller

- WS2812 Led strip with 60 leds

- 4 buttons

- Buzzer

- Transistor

- and two resistors

Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial

Unlike simple hardware, software is more complex and is taken from vagrearg.org web. Many parameters can be easily changed in the code, such as: Number of pixels in strip, Bounce-back zone size, Led dots intensity, Points needed to win etc...

The game is made interesting with several features. Firstly, the ball will become faster and faster for every time it is hit back and forth. Secondly, the ball can be hit back within a blue "zone" and will be returned faster the longer into the zone you let the ball come. This is, of course, at the risk of hitting too late. Thirdly, you can boost the return by holding the boost-button down while hitting. The cost of a boost is reduction of your hit-back zone.

Finally, all the parts are placed in a suitable box made of PVC plate and coated with self-adhesive colored wallpaper, so that the device got a functional and interesting look.

Thanks for watching

Code

  • Code
CodeC/C++
No preview (download only).

Schematics

Build a 1‑D Pong Game with Arduino and WS2812 LED Strip – Step‑by‑Step DIY Tutorial

Manufacturing process

  1. Build a Retro Numitron Clock with Arduino: Simple, Reliable, and Energy‑Efficient
  2. Build a Real-Time Gyroscope Game with Arduino Nano & MPU-6050 Sensor
  3. Build Your Own 37‑LED Roulette Game with Arduino Nano
  4. DIY Arduino USB Gaming Controller – Build Your Own High-Performance Gamepad
  5. Build a 24×16 LED Pong Console with Arduino Nano & MAX7219
  6. Control an LED via Bluetooth with Arduino – Simple DIY Guide
  7. Pixel Chaser: Interactive One-Tap LED Game with Arduino Nano
  8. Build a Precise DIY Measuring Wheel with Arduino Nano & Rotary Encoder
  9. DIY LED Roulette Game – Build a One‑Person Arcade with Arduino Nano
  10. Build a Sensitive Arduino Metal Detector with Ferrous/Nonferrous Discrimination