IFD:Eclectic Electric!/DocumentationWS2013/Lydia Kluge/MainProject: Difference between revisions
Lydiakluge (talk | contribs) (Created page with "== Playing Pong == '''Abstract''' I recreated the famous game "Pong" in Processing; to touch my hat to the old pong consoles I used an Arduino and two potentiometers to build o...") |
Lydiakluge (talk | contribs) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 6: | Line 6: | ||
Arduino and two potentiometers to build one myself. | Arduino and two potentiometers to build one myself. | ||
[[File:Pong-console-arduino-potentiometer.jpg|800px]] | |||
' | That's the finished setup. | ||
'''Pong''' | |||
The final Processing sketch is based on a program I wrote during the class "Tangible Programming - An Introduction" held by Johannes Deich. I went for a more colourful look than the original game. | |||
[[File:Pong-processing.jpg|800px]] | |||
I used the serial and the Arduino (Firmata) library to import data from the Arduino, which runs the "StandartFirmata"-sketch, to Processing. In short, the first potentiometer is attached to the analogue pin 0 and its data moves the left paddle, while the second potentiometer is attached to the analogue pin 1 and moves the right paddle. Self-evidently, I mapped the value range of the potentiometers to match the height of the canvas. | |||
If you are interested, feel free to download the [[Media:Pong.zip|Processing sketch]] and have a closer look. | |||
'''Prototype''' | |||
This full-functioning prototype already shows the unfussy electronic setup as it is in the final console. | |||
[[File:Pong-console-arduino-potentiometer-prototype.jpg|800px]] | |||
[[File:Pong-console-arduino-potentiometer-prototype-close.jpg|357px]] | |||
[[File:Pong-console-arduino-potentiometer-breadboard.jpg|357px]] | |||
'''Final Console''' | |||
The finished console is made of plywood and has one rotary button attached to each potentiometer, enabling the user to control the paddles by rotating movement; just like with the original consoles. The wires and electronic components are all hidden on the inside. | |||
[[File:Pong-console-arduino-potentiometer-player.jpg|800px]] | |||
'''Video''' | '''Video''' | ||
Feel free to watch a, rather unexciting, video of me doing a test run. | |||
<videoflash>g0C0RPArRzo|800|450</videoflash> | <videoflash>g0C0RPArRzo|800|450</videoflash> |
Latest revision as of 23:52, 28 June 2014
Playing Pong
Abstract
I recreated the famous game "Pong" in Processing; to touch my hat to the old pong consoles I used an Arduino and two potentiometers to build one myself.
That's the finished setup.
Pong
The final Processing sketch is based on a program I wrote during the class "Tangible Programming - An Introduction" held by Johannes Deich. I went for a more colourful look than the original game.
I used the serial and the Arduino (Firmata) library to import data from the Arduino, which runs the "StandartFirmata"-sketch, to Processing. In short, the first potentiometer is attached to the analogue pin 0 and its data moves the left paddle, while the second potentiometer is attached to the analogue pin 1 and moves the right paddle. Self-evidently, I mapped the value range of the potentiometers to match the height of the canvas.
If you are interested, feel free to download the Processing sketch and have a closer look.
Prototype
This full-functioning prototype already shows the unfussy electronic setup as it is in the final console.
Final Console
The finished console is made of plywood and has one rotary button attached to each potentiometer, enabling the user to control the paddles by rotating movement; just like with the original consoles. The wires and electronic components are all hidden on the inside.
Video
Feel free to watch a, rather unexciting, video of me doing a test run.
<videoflash>g0C0RPArRzo|800|450</videoflash>