Let's Make Robots!

Pong

Used To Play Pong
AttachmentSize
pong_6_8_11.pde29.29 KB

A dictionary will tell you that pong is "an unpleasant smell; stink." Wikipedia would tell you that pong is "one of the earliest arcade video games, and is a tennis sports game featuring simple two-dimensional graphics." This project is closest to the latter. 

 

You can go to my blog post or website to see how the pong paddles were made and to get some information on the circuit boards. Instead of copying that info, i will try to pick up from there. 

Here are just some quick pictures of the pong paddles and circuit boards i made.

 

 

The Pong Case is built from hardwood bought at a local hardware store. The case is a bit big for the screen, but there has to be room for the circuit boards to fit inside. 

 

The case's door is also made from hardwood. A piece of Lexan acts as the window for the case allowing the players to see the screen within. The wood on the door is held together with angle brackets and the Lexan window is hot glued on the back.

 

Holes are drilled in 2 sides of the box for the audio jack plugs which connect the pong paddles to the main screen. A hole is drilled in the front for the power switch. 

 

The Arduino is bolted onto the outside platform where it and the battery pack will sit for ease.


the door is attached with hinges so i can easily access the inside electronics if need be it.

 

Then the audio jacks are wired up, power is distributed, and everything gets plugged into the Arduino.

 

 

Here is the completed game, all wired up and ready to program.

 

There are a few more things to add like feet for the case and a clasp to keep the door close on it. But besides that, the construction is done. Oh i just remembered i need to put a buzzer in it. I will update the post when it plays pong...

 

UPDATE 10.31.10

Well at the end of today i have the code almost done. 

The paddles are 3 pixels wide and they can be moved with the pong paddles i built. 

At the beginning of the game the ball randomly appears and takes off at a random angle towards the same direction right now. 

The ball can carry over to the next matrix and deflect off the walls right now. Everything works fluidly and quickly. The ball is set to maximum speed which seems like a good challenging speed.

 

What is left to do is to make it deflect off the paddle and switch directions or sound a buzzer to indicate a point was scored and restart a new game. 

 

Im learning some more about programming. Mostly working with bits  and well learning how to program pong. The next update will be when the pong program is done and i have video for you. 

 

 

UPDATE 11.4.10

 

Program is all done and pong works!! See video. (in the video, the speed of the game is not set to the fastest. If you cant tell, i am playing myself, so do not let this be a testament to my pong playing ability :) 

 

 


 

Update 12/27/10

 

I have added a few functions and modes to the pong code (see the last video).

The first function is score keeping. It keeps and displays the score after each point, 5 points to win. Once 5 points are scored, the score flashes for a bit and then a new round is started. 

Pong now has 3 different modes, each is selectable by using the pong paddle. Turning the knob changes the mode. The mode is displayed at the top of the screen for the first 3 seconds after a restart of the Arduino.

 

The first mode is just like the previous code. It is 2 player pong with the paddles being 3 pixels wide. 

 

The second mode is also 2 player code but the paddles are 2 pixels wide which makes the game more difficult.

 

The third mode is a one player game where you can practice your skill by playing against a "wall"

 

 

 


 

Update 4/11/11

 

I have fixed some of the few bugs that were left and came up with a "new bounce scenario", as I call it. See the 3 new videos.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

I still have an atari with the pong video game, guess ill dig it out.

Great memories! We owned one of the original Pong units. No LEDs, because they might not have been in use outside NASA (if they existed at all). It was TV at about the same resolution. VHF channel 2 I think. Nice job doing the repro.

Looks like my silver knobs pretty well match the ones on most machines. 

This is awesome!!! Can't wait to play with it Pat.

 You are a very talented person too :). The song is "42" by Coldplay. It does sound a bit sad but its one of the only soft songs in my itunes library...

Patrick,

You embody the statement, "You are a very talented person". So glad that you are part of LMR. Even your single-handed Pong playing is pretty good. ; j

Awesome project. Thanks for sharing it.

Also, what is that music? I liked it.

nice work 

the music on the video is a bit sad

Great work!I love the wooden cases you make for your robots. Gives them a unique retro look.

Add a robot arm that can hold a control and turn the dial.
That would add a whole new dimension to playing against the computer :D