Introduction: Combustion Engine (LittleBits Project)
Project simulates the combustion process in an engine. It uses spare parts lying around the house to
simulate a piston and cylinder. In addition, it uses a LittleBits motor, LED and Arduino board to simulate the actions of the engine parts.
Total Build Time: 2-3 hours
· Piston and cylinder construction – 2 hours
· LittleBits motor assembly – 5 minutes
· LittleBits LED assembly – 5 minutes
· Arduino coding – 10 mins
· Testing and timing – 15 minutes
Step 1: Gather All the Parts Needed for This Project.
· (2) 9v batteries and connector cables
· (2) power supplies
· (1) LittleBits Arduino board
· (1) motor
· (1) LED
· (3) connector wires
Note: the LittleBits parts are from the Deluxe Kit. I used two power supplies because (1) 9v battery doesn’t have enough power to run the whole project effectively. The assembly is a little extra work but your project will have better results.
Faux Engine Parts:
· MDF board or plywood
· Large paperclips
· Lightweight dowel
· Plastic can or cylindrical object
· Twist ties/zip ties
· Metal strapping
· Spark plug (optional)
· Cardboard (optional)
· Drill and drill bits
· Deck screws
Step 2: Build the Upright Stand.
Cut 12” x 18”
rectangle out of ½” thick board. For this project, I used MDF but plywood is just as effective. After it was cut, create a support structure that allows the board to stand upright.
The image below is a close up of the left side of the board. You’ll see two triangular wedges cut from MDF and a secondary support cut from 2” x 2” scrap wood. Circled are (3) deck screws drilled into each side. You’ll probably want to drill pilot holes, then drill the front deck screw and marry the board and 2”x 2”, then drill and attach the triangular wedge to the 2” x 2”. Drilling into the side edge of the board itself is not a good idea as it can split the wood.
Optional Step: once your board can stand securely upright, go ahead and paint it.
Step 3: Build the Piston.
If you’re not familiar with engines and don’t want to do a lot of research on it, take a look at this GIF from Wikipedia.org: http://en.wikipedia.org/wiki/Internal_combustion_engine#mediaviewer/File:4StrokeEngine_Ortho_3D_Small.gif
The key to building our piston projects is creating its three parts with lightweight materials. The lighter the weight, the easier it is for the LittleBits Motor to move it. An actual piston needs to be created from tough metals strong enough to move a vehicle. The piston itself is puck-shaped with a hole through the side of it. This allows the connecting rod to connect to the piston and move in a pivoting motion. Various types of connecting rods are show in the second image. The smaller hole will connect to the piston pin and the larger hole at the bottom of the rod will connect to the crank shaft.
To create the piston, I cut about 3” off of a Styrofoam pool noodle. Not only is it lightweight, but it is hollow in the middle to allow for the connecting rod.
To create the pin, I straightened and cut a paperclip a little longer than the width of the piston we just created.
To create the connecting rod, I used the handle to a foam paint brush. The handle is very light weight. I cut the top of it off right below the foam then sanded down the rough spots. Next, attach a very small drill bit to your drill and create two holes on the side of the rod, both facing the same direction. Don’t make the holes too large, but big enough that the paperclip/pin can pass through it freely.
When the holes are created, place one end of the rod into the
foam/piston. This next part is a bit tricky as we’re going to try to push the paperclip/pin through the side of the foam, get it through the hole of the handle/rod and then push through into the other side of the piston. Try to insert the pin somewhere on the lower half of the piston and be sure the paperclip (end to end) is completely straight across and parallel to the top and bottom of the piston.
TEST: wiggle the piston rod back and forth. If there is any resistance, make sure the hole in the rod is large enough. If the rod doesn’t have enough room in the piston to move back and forth, you may need to carve out a large area inside the piston.
Step 4: Build the Crank Shaft.
The crank shaft is what connects the piston rod to the motor. If you’re interested in how a crank shaft works, click on this link: http://en.wikipedia.org/wiki/Crank_shaft#mediaviewer/File:Cshaft.gif
The good news is to create the crank shaft is very simple. All we need is a large paperclip. Straighten out the paperclip except for the smaller inside loop; that loop will later be connected to the motor. Using the image below as a guide, use pliers to bend the clip in a Z or S shape. You’ll want about 1 ½“to 2” clearance from the board, then a downward bend about 2” long. The next bend allows about 1 ½” to go through the connecting rod/piston arm, then one last bend to secure the paperclip so the rod doesn’t fall off.
Drill a hole into the board that’s a little larger than the paperclip.
The hole should be high enough the when the piston sits at its lowest position, it’s not hitting the surface/table below.
TEST: run the paperclip through the hole, then with one hand hold the paperclip and with the other move the piston in a full circle so the paperclip has spun all the way around. If needed, make any adjustments to the parts you’ve assembled. On the board, mark the highest point the top of the piston is able to reach and the lowest point the bottom of your piston is able to reach. This will be important for cylinder placement in step 5.
Step 5: Build the Cylinder.
The cylinder is the canal-like pathway in which the piston travels. Most vehicles have a 4, 6 or 8 cylinder engine. Each cylinder has a piston and all of those pistons are connected to the same crank shaft. We’re only creating a partial cylinder, otherwise the piston would be fully enclosed and not visible. I wound up using an empty, plastic paint can and cut off the top and bottom, then cut it in half, right down the middle from top to bottom. Make sure the height of the can is at least the distance between the two points you marked in step 4.
Using about 8” of metal strapping and (2) deck screws, I fastened one half of the plastic paint can to the MDF board. I took the other half of the can and duct taped it to the one I just secured. The duct tape not only keeps the two halves together, it creates a frictionless surface for the piston to travel.
Another issue with piston travel is gravity. With my project, the piston kept falling forward, so I had to create a support that mimicked what would have been the other half of the cylinder wall. Using (3) large paperclips, I made a rail for the piston to travel. Straighten them all out and form two of them into staple-like shapes. Place one at each edge of the cylinder, then duct tape to the cylinder wall. For the last paperclip, do the same thing you did when creating the piston pin, except spear through the upper portion of the piston. Hopefully your paperclip is long enough that it will allow you wrap the ends loosely around the two rails you just made.
TEST: turn the paperclip/crank shaft from the back of the board, clockwise and counterclockwise and verify the piston travels without trouble.
Step 6: Attach the Spark Plug.
A spark plug is located at the top of the cylinder. Its function of a spark plug is to fire (or spark), causing fuel in the cylinder to ignite (or combust).
I had a burnt out spark plug (any plug will do), drilled four holes and secured it to the board using twist ties. Leave about 3” between the plug and the cylinder so we can install the LED later. In the image below, you’ll see I also drilled a hole into the metal strapping to feed the LED wire through.
Step 7: Assemble the Motor Using LittleBits.
The majority of our build time has gone into constructing the piston and cylinder. Take a big sigh because all the rest is easy. To construct the motor, I used the following parts from a LittleBits Deluxe Kit:
1A – 9v battery
2A – connector cable
3A – power supply
4A – wiring connector
5A – motor and connector piece
As you saw in the side view photo in step 4, my motor needed to be propped up in order to connect to the paperclip/crank shaft. The LittleBits boxed worked perfectly.
First, add the little white connector piece to the LittleBits motor. Next, from the back of the board, push the folded end of the crank shaft into the slot of the motor piece. You may need to turn the paperclip a little so it fits correctly. Before you connect the rest of the LittleBits, tape or strap down your motor; otherwise, the torque of the motor will cause it to flip over once it’s powered on.
Assemble your LittleBits components in the numeric order they’re listed. If you’ve worked with LittleBits before, you’ll know the ends are magnetic which will only allow you connect them the correct way. I also duct taped the battery, connector and power supply to the back of the board.
TEST: verify your motor is secure, your crank shaft is connected and power on your LittleBits motor by clicking the ON switch on the power supply. Side note: the motor component has a switch that says LEFT or RIGHT. It does not matter which direction yours is selected. Your motor should be turning the crank shaft and, in turn, lifting the piston up and down. You may need to tweak how long the crank shaft is from the board by pushing or pulling the paperclip.
If the motor is turning but the paperclip is slipping out of the white plastic connector, try readjusting the bend/loop.
If the motor appears to be struggling to turn, disconnect the crank shaft. If it continues to struggle, you may have a bad connection or a weak batter. If the motor works fine on its own, your piston assembly might be too heavy or there might be a friction point in the cylinder or piston rod.
Step 8: Code the Arduino for the LED.
We are going to code the LittleBits Arduino board so that the LED flashes at a specific time in the piston action, simulating the firing of the spark plug; however, the tricky part of the coding is knowing how long it takes your piston to travel to the point the piston is supposed to fire.
With your motor still connected to the crank shaft, turn on the motor long enough so that the piston is at its highest point in the cylinder, the immediately turn it off. This is the starting point for your piston. In mechanical terms, this is called Top Dead Center (TDC). Next, we need a stop watch…actually, I used an app on my phone…but something that can keep time. When you’re ready, turn on your motor and start your stop watch at the same time. Notate how long it takes the piston to travel a full rotation from TDC to the bottom of the piston and back to TDC. In basic terms: up, down, up. I tested my piston several times and got readings from 1.6-1.8 seconds. Yours may vary.
Turn off the motor. It’s time to code. In the Arduino software, you’ll need to Leonardo as your board. Below is the sketch to create the blinking light:
Spark Plug Sketch
Turns on an LED to simulate a spark plug fire in an interal combustion engine. Repeats.
int led = 5; // Define the pin the LED is plugged into
void setup() // Initialize setup
pinMode(led, OUTPUT); // Define the LED as an output source
void loop() // Loops through the sketch
digitalWrite(led, LOW); // Turn off the LED
delay(1800); // Delay for 1.8 seconds
digitalWrite(led, HIGH); // Turn on the LED, simulate spark plug fire
delay(250); // Delay for 0.25 seconds
digitalWrite(led, LOW); // Turn off LED
delay(1550); // Delay for 1.55 seconds
If you’ll note in the sketch, after 1.8 seconds, the LED turns on for 0.25 seconds, then is off for 1.55. In terms of the combustion process, the spark plug fires after the piston has made a full cycle up and down. In the next rotation, the spark plug does not fire because it is cycling between the power stroke and exhaust stroke. To put it in simple terms, the LED only has to blink once in two full rotations.
1.8 seconds (first full rotation) = 0.25 seconds + 1.55 seconds (second full roation)
Modify this sketch to reflect the time you notated. In your sketch, your first delay time should reflect the time it took the piston to travel from TDC, down then back to TDC. Your next delay is how long you want your LED to stay lit. The last delay should be the remaining time.
Make sure your LittleBits power supply is turned on and connected to the Arduino. Upload your code.
Step 9: Assemble the LittleBits LED.
You’ll need the following LittleBits parts:
1B – 9v battery
2B – connector cable
3B – power supply
4B – Arduino board
5B & 6B – connector wires
7B – LED
Assemble the components into that order using the images below as a guide.
Disconnect the wire from the LED (7B) so it can be feed through the hole drilled earlier. On the front of the board, I would up using another paperclip to secure the LED LittleBit through the same hole.
TEST: turn on the LittleBits powering the LED and make sure your LED flashes in the correct time you provided.
Step 10: Timing the Motor LittleBits With the LED LittleBits.
This last step just requires a little patience and hand/eye coordination. We need to make sure both LittleBits assemblies are in sync and that the LED flashes when the spark plug is supposed to fire.
First, turn on the LittleBits powering the LED. As that runs, turn on the LittleBits motor until it reaches TDC. Once it does, immediately shut off power to the motor.
What we want to do turn on the motor as soon as the LED flashes. Though it technically starts your project at the second rotation of the piston cycle, you should have a functioning combustion process simulated by LittleBits and Arduino.
TEST: if your LED flash is out of sync with the piston, turn off power to both and tweak the LED Arduino code.
We have a be nice policy.
Please be positive and constructive.