This is our pinball project.
Each group member has a set of tasks that they must complete to get a full pinball machine.
The craftsmanship of the machine must be professional.
The pinball machine must be fully functional and playable.
Today we went to a pinball arcade. Our goal was to learn more about how pinball machines worked and what most of them have in common.
All pinball machines have these elements in common:
Bumpers
Flippers
Ball slides
Scoreboard
Start Button
Ball shooters
Launcher
On/off switch
Coin Slots (these will not be implemented)
Lights
Screens
Sound effects
A theme
Graphics
Scoring info
Bumpers are the mechanisms that react when the pinball runs into them. When the ball comes in contact with one, it launches the ball back in the direction it came.
Flippers are the controllable paddles that flip up when a button is pressed. This is the only directly controllable element other than the launcher.
Ball shooters activate when the ball hits the rubber band that is on it. It then shoots the ball back the direction it came.
the launcher is what puts the pinball into play. It is used by pulling a spring on the front of the machine, and releasing it launches the ball.
the start button turns on the machine and puts the balls in the launcher guide.
This is our scoreboard displaying a message on an LCD screen. It is showing a greeting in a different language.
This is our scoreboard responding to buttons. We can make the score increase and the amount of balls decrease. It has a game over screen too.
This is our laser printed mount for our scoreboard. It can screw into the LCD.
This is our 3d printed solenoid. We have coiled magnetic wire around it to be able to use it as a mechanism to extend our bumpers.
I am going to start designing my Target for my Pinball Machine. In order to do this I will first research any existing ideas on how to make a pinball target out of the materials that we are provided with. Next, I will start sketching ideas based on my research and drawing multiple iterations of them. After this, I will construct my design out of disposable materials such as cardboard to validate that my idea works. Then I will go into tinkerCAD and construct my design in 3D. After this, I will print the parts that my design is made out of on the 3D printer. I will test my design by pushing on it like how a pinball would and making sure nothing breaks and every part works as intended. I will connect it to the score counter and make sure the electronic side works as well. If anything doesn't work or works badly then I will print a new iteration of my idea. I will know I am finished when my target works reliably and is also not clunky and is smooth.
This is the frame for our pinball machine. It is made of plywood and is pretty sturdy.
We have installed our scoreboard onto the frame of the machine. It is now screwed in and works as intended.
This is the switch that will control the power to our pinball machine. It is bolted to the side and connected to a power source inside the box.
This is the power source that will power all of the components that are needed for the machine to work. We have secured it by making a holder that is attached to the machine box.
The next step was to wire the power source to the switch and plug it to the wall. We did this by stripping DC wire attaching it to the power source. We also attached the switch with other wires.
Each member of out group was assigned to construct a different component of the pinball machine. My component was the target. The target is used for getting points when the pinball makes contact with them.
This is an example of a target in a real pinball machine. It is essentially a switch that is connected to the scoreboard. The switch is actuated when th pinball hits the target. The lever actuates and makes contact with the wires that increase the score. Different targets can be tied to different score values. There can also be different types of targets. The one in the picture and the one I am constructing is called a stand-up or stationary target. There are drop targets which disappear once they are hit, bullseye targets; they give more score if they are hit closer to the center, and kicking targets which kick the ball away once hit.
This is the switch that will actuate my target. i can connect it to my lcd display through my arduino to display score. i can also attach an extension that sticks up above the board so that the pinball can hit it.
This is my first idea about how the target should be built. It is just a paddle attached to the actuating end of the limit switch. It is attached to a casing via a hinge, so that it moves and actuates the switch when it is contacted.
This is my first prototype that I made on onshape. It is the pieces to the casing that I will construct. The triangle shaped object is the paddle. The squares are parts of the casing.
This is my first prototype constructed and completed. It is working as expected and the switch turns on when I push on it. It is not connected to the scoreboard yet though.
This is my idea for my second prototype. My first one did not have a backstop for the switch nor a part to keep it from flying forward. I also thought of a more reliable hinge system.
This is my second prototype. It has a backstop and a front stop so that the switch can stay in place. It also has a better hinge using a screw and I also reinforced the part that the ball makes contact with.
This is the sketch for my third prototype based on problems and improvements from the previous one. I needed a longer stalk because the wood is thicker on the pinball machine. I also needed a larger plate for the pinball to hit. Finally I needed a larger case so that it can better attach to the pinball machine.
This is my third prototype. It is significantly different from the past ones. It has a circular contact point and a longer stalk so that it can stick up over the pinball machine. it also has a longer back so that it can have a bigger contact point to the bottom of the board.
My third prototype had some flaws. I first made the stalk shorter because the plate was too far up. I also made the case smaller because it was hard to reach the limit switch.
This is my fourth prototype. It is very similar to the last one, but in contrast this one has a bigger face, a shorter stalk, and a shorter casing with another plate on the top for a wider contact point. This one is also wired up to the scoreboard and increases the score when it is pressed.
This is a spreadsheet that allows us to track our progress.
The next steps are to attach the mechanism to the machine body. I also need to make more of them so that I can have multiple targets on the board.
This is my fifth prototype sketch. I have added screw holes to be able to screw the limit switch into the case instead of gluing it, making it more sturdy, because the last prototype was very flimsy..
This Is my fifth prototype. It has a sturdier stalk as well as screws in it in order to secure the limit switch.
The main flaw with my last design is that it had a short mounting point. It this sketch I decided to lengthen it.
This is my sixth prototype. it has a screw that will stop the paddle from moving outside of the case instead of a wooden piece. It also has a longer mounting point that allows it to be sturdier when on the pinball machine.
This is the sketch for my seventh prototype. The last one could have had a firmer mount, so I made finger joints on the piece that connects the target and the board.
In this prototype, I could not assemble it because the back piece that holds the frame together was too big.
This is my cad for my eight proto. It has a thinner back piece and longer fingers.
The back piece for this prototype was also too big, but I have added holes that screw into the mount.
This is my ninth cad. It has an even thinner back piece with holes and longer fingers to fit into the back walls.
This is my ninth prototype. It is screwed into the mock board and the only glue that is uses is to connect the top of the mount to the sides. It is very sturdy and I think I am almost done with prototyping.
This prototype was not connected to the board and I need to fix code and wiring error before I solder it to the board.
This is my tenth prototype. It is the same as my ninth except it is wired to the scoreboard and completely works as expected.
These are my first ideas for the launcher of my pinball machine. I will construct it from the laser printer as it is the most efficient option.
This is the first prototype for my launcher. It consists of a base, a rod, and 2 pins to hold the rod to the base as it extends.
The problem with this prototype is that the holes in the rods were too big for the pins. Also I needed one more pin to hold the springs onto the rod.
This is my second prototype. It has a second pin and it also has smaller holes to be able to hold the pins correctly.
On this prototype, the holes on the rod were actually too small. The pins could not fit.
This is my 3rd prototype. On this one I decided to double up the rods so that they are stronger. I also had to widen the hole on the base.
The problem with this prototype is that the springs were too narrow to be able to fit two rods.
This is my 4th prototype. I made the rod longer so that it could fit 2 springs for more power instead of just 1. I also tuned the hole size to fit the pins better.
This is the first working prototype. When I pull back the rod through the base, the springs compress. When I let go, the rod shoots forward.
On this prototype. I decided to shorten the rod to get rid of the extra space between the springs. I also decided to tighten the holes so that the pins fit better.
The problem with this prototype was that the rod was too flimsy to be able to hold the tension of two springs.
On this prototype, I wanted to make the rod thicker so that it would not break under stress.
This prototype works as intended and does not break or bend as easily as the previous iterations. The next step is to attach it to a rail.
This is a picture of my neopixel strip wired to an arduino and a limit switch in order to control when it turns on and what it will do.
This is my neopixel strip responding to pressing a limit switch. It procedurally lights up green.
Pinball flippers work using a solenoid device under the playfield. This solenoid is activated when the player presses the flipper button, which causes the respective flipper to flip up. When the button is released, power is cut to the solenoid and the flipper returns to its original position.
The flipper solenoid needs to generate sufficient power to kick the ball hard enough to overcome the downward slope of the playing field. Flippers are usually made of plastic with a strip of rubber added to enable more bounce when hitting the ball. Flipper length usually varies between one and a half inches to three inches, and the wider end of the flipper swivels around a vertical steel pin about an inch high.
Flippers need to kick the pinball at least as hard as any other device whenever the player presses the flipper button, but they also need to last. To avoid overheating flipper solenoids while players hold on to a trapped ball, most flippers use solenoids with two coils of wire wound together around the same core. The first coil is a high electric current/high power coil used by itself to kick the pinball up the playfield. The second coil is a much weaker, low electric current/low power coil that is really only strong enough to hold the ball behind the raised flipper.
this is my first original sketch/diagram of my flipper design. I think it should work well while being simple to build.
Launcher is separate
#include <Adafruit_NeoPixel.h>
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
#ifdef __AVR__
#include <avr/power.h> // Required for 16 MHz Adafruit Trinket
#endif
// Which pin on the Arduino is connected to the NeoPixels?
#define PIN 12
//this to 1
// How many NeoPixels are attached to the Arduino?
#define NUMPIXELS 4 // Popular NeoPixel ring size
// When setting up the NeoPixel library, we tell it how many pixels,
// and which pin to use to send signals. Note that for older NeoPixel
// strips you might need to change the third parameter -- see the
// strandtest example for more information on possible values.
Adafruit_NeoPixel pixels(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);
LiquidCrystal_I2C lcd(0x27, 20, 4); // set the LCD address to 0x27 for a 16 chars and 2 line display
int targetValueLED = 0; //ORIGINAL
#define DELAYVAL 100 // Time (in milliseconds) to pause between pixels
int targetPinLED = 13; // ORIGINAL
int ball_count_button = 8;
const int score_increase_bumper = A1; // bumper pin (touches gnd to activate)
int solenoid = A0; // (solenoid connects to this pin through mix thing
const int score_increase_bumper2 = A3; // bumper pin (touches gnd to activate)
int solenoid2 = A2; // (solenoid connects to this pin through mix thing
const int score_increase_bumper3 = 5; // bumper pin (touches gnd to activate)
int solenoid3 = 4; // (solenoid connects to this pin through mix thing
const int score_increase_bumper4 = 3; // bumper pin (touches gnd to activate)
int solenoid4 = 2; // (solenoid connects to this pin through mix thing
//connected pin
long score = 0; // long counts to 2 billion
long lastScore = -1;
int ballcount = 1;
int bumperbuttonState = 0;
int bumperbuttonState2 = 0;
int bumperbuttonState3 = 0;
int bumperbuttonState4 = 0;
void setup() {
lcd.init(); // initialize the lcd
lcd.init();
lcd.backlight();
// initialize the LED pin as an output:
pinMode(solenoid, OUTPUT);
pinMode(solenoid2, OUTPUT);
pinMode(solenoid3, OUTPUT);
pinMode(solenoid4, OUTPUT);
// initialize the pushbutton pin as an input:
pinMode(score_increase_bumper, INPUT_PULLUP);
pinMode(score_increase_bumper2, INPUT_PULLUP);
pinMode(score_increase_bumper3, INPUT_PULLUP);
pinMode(score_increase_bumper4, INPUT_PULLUP);
pinMode(targetPinLED, INPUT_PULLUP);
pinMode(ball_count_button, INPUT_PULLUP);
Serial.begin(9600);
pixels.begin(); // INITIALIZE NeoPixel strip object (REQUIRED)
lcd.setCursor(0, 4);
lcd.print("Game Start");
delay(1000);
lcd.clear();
}
void refreshLCD() {
if (lastScore != score) {
lastScore = score; // only refresh lcd when score changes
lcd.setCursor(4, 0);
lcd.print("Balls:");
if (score < 1) lcd.print('0');
lcd.setCursor(10, 0);
lcd.print(ballcount);
lcd.setCursor(1, 1);
//padding zeroes on scoreboard
lcd.print("Score:");
if (score < 100000) lcd.print('0');
if (score < 10000) lcd.print('0');
if (score < 1000) lcd.print('0');
if (score < 100) lcd.print('0');
if (score < 10) lcd.print('0');
if (score < 0) lcd.print('0');
lcd.print(score);
}
}
void loop() {
// for (int i = 0; i < NUMPIXELS; i++)
// pixels2.setPixelColor(i, pixels2.Color(255,0,0));
// pixels2.show();
int score_increase_bumper_value = digitalRead(score_increase_bumper);
int score_increase_bumper_value2 = digitalRead(score_increase_bumper2);
int score_increase_bumper_value3 = digitalRead(score_increase_bumper3);
int score_increase_bumper_value4 = digitalRead(score_increase_bumper4);
int ball_count_button_value = digitalRead(ball_count_button);
int targetValueLED = digitalRead(targetPinLED);
bumperbuttonState = digitalRead(score_increase_bumper);
if (bumperbuttonState == LOW) {
// close selenoid
digitalWrite(solenoid, HIGH);
} else {
// open selenoid
digitalWrite(solenoid, LOW);
}
bumperbuttonState2 = digitalRead(score_increase_bumper2);
if (bumperbuttonState2 == LOW) {
// close selenoid
digitalWrite(solenoid2, HIGH);
} else {
// open selenoid
digitalWrite(solenoid2, LOW);
}
bumperbuttonState3 = digitalRead(score_increase_bumper3);
if (bumperbuttonState3 == LOW) {
// close selenoid
digitalWrite(solenoid3, HIGH);
} else {
// open selenoid
digitalWrite(solenoid3, LOW);
}
bumperbuttonState4 = digitalRead(score_increase_bumper4);
if (bumperbuttonState4 == LOW) {
// close selenoid
digitalWrite(solenoid4, HIGH);
} else {
// open selenoid
digitalWrite(solenoid4, LOW);
}
if (targetValueLED == LOW ) {
Serial.println("targetValue is LOW" + targetValueLED);
pixels.clear(); // Set all pixel colors to 'off'
for (int i = 0; i < NUMPIXELS; i++)
pixels.setPixelColor(i, pixels.Color(255, 0, 0));
pixels.show();
delay(DELAYVAL);
//lcd.clear();
//lcd.setCursor(8, 0);
//placement of text, first number is x axis, second is y axis
score += 500;
//lcd.clear();
}
else {
Serial.println("High");
pixels.clear(); // Set all pixel colors to 'off'
pixels.show();
}
if (score_increase_bumper_value == LOW) {
//lcd.clear();
//lcd.setCursor(8, 0);
//placement of text, first number is x axis, second is y axis
score += 500;
//lcd.clear();
}
if (score_increase_bumper_value2 == LOW) {
//lcd.clear();
//lcd.setCursor(8, 0);
//placement of text, first number is x axis, second is y axis
score += 500;
//lcd.clear();
}
if (ballcount < 1 == true) {
lcd.clear();
lcd.setCursor(6, 0);
lcd.print("GAME");
lcd.setCursor(6, 1);
lcd.print("OVER");
delay(500);
lcd.clear();
delay(500);
} else {
refreshLCD();
delay(75);
}
}//
This is the top of the bumper. It has a 3d printed cap to force the ball out. It also has copper foil on the inside in order to trigger the selenoid when the ball makes contact.
This is the bottom of the bumper. It has A solenoid attached to a wooden support beam. It is hooked up to a mosfet and into the arduino and power source.
These are the front of the targets. They are laser cut shapes screwed into a wooden beam on a hinge.
These are the bottom of the targets. They are screwed into the board and connect to the Arduino. There is a limit switch which turns the neo pixels on raises the score.
These are the top of my flippers. They are laser cut and painted to match the theme.
These are the inside of my flippers. They are on a driveshaft that rotates when the selenoid is activated. The springs on the screws pull it back to resting position. The selenoids are wired to buttons on the side of the machine.
This is the launcher. It is a wooden beam in a tube with a face on the front. It is connected to springs which are attached to the front of the board that propel the beam through the hole.
This is the top of a neo pixel. It has lights on the top of the strip
This is the bottom of the neo pixel. It is taped to the inside of the board and connected to the arduino. It lights up when the targets are pressed.
This is the front of the LCD scoreboard. It has a ball count, and a score counter which goes up when a target or bumper is hit.
This is the back of the scoreboard. It is connected to the arduino and screwed into the back panel of the machine.
Theme: Anime "Initial D"
This project was very challenging yet very fun. It has incorporated all of the many engineering skills that I've learned such as wiring electrical circuits to woodworking. It felt very good to finally complete the project after a long time. It was very rewarding to see it work like a real pinball machine and cool to see all of them at display at the festival. I am most proud of the aesthetic and cosmetic features of the machine such as the color scheme, the vinyl, and the rotating cars in the middle.