cart 306 logo


nav about


























































































































































































   
Milk and Cookie Pong
 

Idea - This project required that we create a game that involved the use of milk. Our inspiration came from the Atari's Home Pong Console, released in 1977. The goal of this two-player game is to defeat your opponent. It is a 'tennis-like' game featuring simple two dimensional graphics. Each player controls a moveable bar or tab, which he or she uses to prevent the adversary's ball to pass onto his or her side of the board.

Concept - Our primary idea was to use both a projector and infrared sensors to display the game on a milk surface. Milk is a good surface onto which to project, as it absorbs and reflects the light and colors, without letting visible spectrum light waves pass through it, and thus not loosing any of the projected image. The choice of using IR Range Finder sensors and a projector was to create an original interactive game in which the players actually interfere and modify the projection based on their motion.

Usability - As the player places his hand over the board game through the sensor's detection field whitin a 10cm range, the placement of the hand in space is detected and transmitted to a computer via an arduino circuit. The location of the moveable bar or tab controlled by each player is then displaced to the hand's location, allowing the player to move it as desired and block the boucing ball with his or her hand.

By: Jason Roussel, Drausio R.Haddad & Stephanie Bouchard

1. Setting up the sensor wires
In order to bring this project to life, the following materials were needed:

2 IR Range Finder sensors
2 sensors holders
1 solderless breadboard
2 resistors
1 arduino
1 computer
1 projector
1 mirror
2 aluminum containers
1 liter of milk

 



Step 1: Wires were soldered to the two IR Range Finder sensors to connect them to the arduino via the breadboard.


2. Test to connect sensors to arduino



Step 2 : We then tested if the circuit connections were functional by running the arduino code.

Arduino Code for the GP2D12


int IR_SENSOR1 = 0;
int IR_SENSOR2 = 1;
int irVal1 = 0;
int irVal2 = 0;

void setup()
{
Serial.begin(9600);
}

void loop()
{
// read the value from the ir sensor
int temp1 = 0;
int temp2 = 0;
for(int i = 0;i<28; i++){
irVal1 = analogRead(IR_SENSOR1);
irVal2 = analogRead(IR_SENSOR2);
temp1 = temp1+irVal1;
temp2 = temp2+irVal2;
}
temp1/=28;
temp2/=28;
Serial.println('!');
Serial.println(temp1);
Serial.println(temp2);
delay(100);

}
 

3. Installation set-up of the projector/mirror + game
 
d


Step 3 : Because the projector was fixed and its orientation could not be moved, we had to come up with a solution to project the game on the horizontal game board, located on a table. To do so we made use of a small mirror, which we placed in front of the projector to reflect the images, fixing it at the angle that would match the emplacement and size of the board.

j


Step 4 : Above is a photo of the installation of the game itself. In order to adjust the two IR Range Finder sensors to the appropriate height, these were fixed onto holders, that were placed at a 10cm distance from the board game. This distance is the minimal distance requirement for optimal detection of motion and displacement range by the sensors.



4. Test and Video of final game

 
Step 5: Once all the components were in place, we tested the projection onto the boardgame, and the efficiency of the sensors and code to make the bar or tab move according to the motion of our hands.