loading

Welcome

Here is one grand weekend project!

Make this awesome Bubble Bot:


While being a bit lengthy and requiring experience with Arduino, this contraption is bound to grant you infinite glory among your friends, toddlers and grownups alike!


Avast, then!

Step 1: What You Need

Here's a list of the materials and parts I used:

The Frame

* 5 x 4-feet long rectangular profile (0.5" x 0.5") pieces of wood, as solid as possible.
Although you could probably get away with plywood if you wanted to, I always like to go for something sturdier than what I actually need, to compensate for unexpected shortcomings.

* 12" x 4"  x 0.5" piece of wood for holding the fan and servo.
From now forth I'll refer to it as the wooden shelf. Please excuse my English, I am Israeli.

* 2 hinges, mine were about 1.5" in length.

 * 4 Colorful plastic floats a.k.a "Wacky Noodles", ~5 feet long.
these, for instance.

* 20 medium-size zip ties for securing the plastic floats to the wooden frame
alternatively, you could go with glue...

* 5 tiny-size zip ties for attaching the opening-closing arm to the servo
Make them colorful if you can, to go with the rest of the design!

* Some bolts, nuts, washers
I used 1/8" diameter ones, various lengths. Sorry for being somewhat vague, it'd take quite a coincidence for you to get exactly the same parts, do your scavenging & adjustments

* 6 feet fishing line
This will be used to connect the motor to the arms, so better get a strong one

* 6 feet thick thread for making the bubbles, preferably made of cloth
Use a thread that is both absorbing and flexible - important for bubble making, as you'll find out.
I actually used a mountaineering thread I had, about 5mm wide. The important features you want are: a. that it would be able to absorb the soap and b. that it would be flexible enough and not form knots. One of the reasons I like using distilled water, is that the thread will never hardens.

* 2 round wooden sticks, 2 feet long, 3mm in diameter
(Or zip-tie together two 1-feet sticks)
These will be used as the poles holding the threads that create the bubbles. One of them will be fixed to the piece of flat wood, and the other will be mounted to the servo - this means they need to be as light-weight as possible
.

* 1 round wooden stick, 2 feet long, 5mm in diameter
(Or - zip-tie together two 1-feet sticks!)
This will be used as the lever allowing the motor to bring the arms up and down, using the fishing line. Therefore, it should be sturdier than the others.


* 10 1.5" long wood screws, 3-4mm in diameter

* Plastic tub for the soap fluid



The Brains

* 3 feet of ordinary 1-lead wire

* A levered micro-switch, something like this one
.
* A Servo, preferably not the lamest one you can get.
I got mine for free in a time of blissful need from someone during geekcon2010, but it was roughly similar in size and torque to this one.

* 6V Geared motor
This one's responsible for raising and lowering the arms that go into the soap bucket and spread open in the air, so it better be geared to take some load. I used a geared motor module I disassembled from a scanner/printer, but you can use anything, as long as it's 6v, around 5-10 RPM

* A roller/pully, used to collect the wire
It should be attached to the motor's shaft, so make sure you get parts that can play nicely together. I got mine by taking down all solder from my soldering kit's roller (see photo). Not the best option, I'll admit.

* 12V Tower-rack computer fan.
I used a 4.7" X 4.7" one. You can always slow down a fan by rapidly switching it (using PWM or otherwise), but not the other way around.

* 10 feet of  3-pin servo leads extension cables
I used these ones , which are hassle-free 

* Circuit Prototyping board, I use something that looks like this

* 1 Arduino or an Arduino-clone.
I use this RBBB from ModernDevice, which is pretty cheap and easy to work with. Instead of the supplied transistor I install a 7805 regulator to take down my 12V input (mopad battery)

* 1 plastic kit-box for the electronic components. Mine was 5" x 3" x 2".

* 12V battery / Power adapter
I use my mopad's battery when outdoor or the adapter when in civilization.

* H-Bridge components:
2 x TIP107 PNP Darlingtons
2 x TIP102 NPN Darlingtons
4 x 2N3904 transistors
4 x 1/4W 1K resistors
4 x 1/4W 10K resistors
I am grateful to Chuck McManis, who wrote this must-read piece on H-Bridges which I pretty much implemented as written. See schema in photos.


Soap Mixture

I used the instructions published by these guys , quantities multiplied by 4:

4 liter of distilled water
3.2 liters of a pre-made bubble mixture 
1 deciliter of detergent (I used regular green Fairy with great success)
1 deciliter of glycerin



Tools

* Solder iron and solder

* Hot Glue Gun:
Although abominable when overused, there aren't many engineering problems that cannot be solved with enough hot glue. Or design-related problems, coming to think of it. Hack, it'll probably solve most kinds of domestic problems, too. Not that I preach for this kind of usage, but hey, I'm just sayin'. The hot glue gun is our weapon in the war against sophisticated (as boring) product assembly lines.

* Electric screwdriver/drill
We will drill some holes and screw some screws when building the frame

* 3mm and 5mm wood drills

* Wood Glue

* Hand Saw, Awesome!

Step 2: Building the Frame

ok,
there are 2 ways of starting up:

By Hand

1. Screw together two sticks into a V shape. Than do another pair

make sure they come out as similar as possible, for maximum stability .

Then,
2. Connect them with one another with a horizontal stick.
When sawing the horizontal piece of wood, you may want to leave some room for the Arduino box, to be attached to it, taking extra 5-6" that will stick from the side.
you now supposed to get two triangles, connected by their vertexes.

See main image for an example of the outcome.


Premade

Just buy separately one table stand
it probably makes more sense unless you enjoy any kind of woodwork (like me).


Now,

Onto that horizontal stick, evenly attach hinges.
I am such a pretty bad carpenter, hinges are my all time nemesis. I hope you do better.

Attach their other end to the little shelf
yes, that's the last piece of wood on the list -
keep in mind that you should be able to drill a 5mm hole in it's width, so double check you chose a piece thick enough; this hole is going to be used for the round pole that is connected to the motor with a fishing line.

Onto the wooden shelf's profile, drill holes for the needed peripherals

Facing backwards:

* 5mm hole for the stick mentioned above

Facing forwards:

* 3mm hole for the fixed bubble-making arm
* 2 holes for attaching the fan via screws.
* Depending on the servo's size: Holes for attaching the servo or saw a socket for it, which is what I did (see image 4)



Step 3: Adding the Bubbling Subsystem (*)


(*) Includes: servo, arms and thread loop

Attach the servo to the wooden shelf
Either use the socket you sawed or drill it in.
At any case, servo should be leveled with the shelf so that when the shelf is facing down, pulled by gravity, the servo's arm should also be on a plane almost perpendicular to the ground


Stick (and later glue) the 3mm round wooden stick in the hole you made for it

Attach the second 3mm stick to the servo using zip ties.
Servos are designed to control little RC airplanes, and their physical arrangement is somewhat awkward when it comes to things other than that, imho. Just do the best you can to get a stable, fixed-as-possible, arrangement.
Alternatively, if you're up to it, you can make better fittings with a piece of tin and 0.5mm drill


Cut the 6 feet of string to 2-feet piece and 4-feet piece.
Minor size adjustments may be made later on, but these sizes should put you in the safe zone.

Tie each end of the string to each end of the wooden sticks
So, now when the arms are open, a loop is formed.
See last image, or this photo which sums it up nicely, except that your sticks will be attached to the wooden shelf and the servo



Tie a zip-tie on the long thread, creating a smaller, 8" loop just below the bigger one
This will make sure that when the arms are down, dipping in the bucket of soap, the loop will not be partially covered with soap and not develop bubble. Also, it helps the loop go back into the bucket when the arms are brought down.
(In BubbaBot 1.0, the arms just dropped back into the soap bucket by gravity, movement it was much more abrupt. perhaps you don't really need that last knot here)


and now, a message from our cheerleaders:

**************************************
Voila! Forward arms are ready!

**************************************


Now stick the 5mm round wooden stick in the hole facing backwards.
As said, later glue it in

Then, tie a fishing line to its end
you can grind a small crack that will keep the line in its place.
test manually how much power it takes to pull the shelf, arms and thread. It shouldn't be too hard, if your hinges are right. If they are slightly crooked, try oiling them. If more than slightly, you're up for some alignments.



Step 4: Fan

Attach the fan to the wooden shelf,
so that it blows air just below the spreading arms. You may need to adjust it later, so don't drive the screws all the way in.

For the first version at Geekcon2010 , I used an ordinary household fan connected to AC that blew air continuously . Later I found a computer fan big enough to push enough air through the loop so that decent bubbles are created.

The mechanical motion of air is a pale imitation of the free flow of air that is created when you make bubbles manually with two sticks and a string, as in this Instructable, but it does the trick.
(Any improvements welcome, of course)



Take a break. Get a beer, you deserve it.
Watch this magnificent clip that made me build this bot at the first place.

Step 5: Attach Feedback Switch


Take the levered micro switch and hot glue it to the top frame wood
But first, solder leads to its terminals, yes? Please, see photo below.
Glue it so that when the wooden shelf is brought up, the switch clicks - just before the shelf is hitting its maximum range
.

I used a on-on switch. meaning, 3 terminals.
In case you use an on-off, you'd need to pull down - just add to the pinout a grounded 10k resistor.

Comment: As I said before, some Arduino knowledge is assumed/needed. Sorry for not going into too much detail, but there are plenty of excellent getting started arduino tutorials, videos, books, posts, and alike.

Step 6: Installing the Motor


Depending on what you have in store, size of motor, its docking points, power ratio, packaging, etc.:

Attach the motor with a pully/roller to one of the back legs.
I tried a few motors here, you may also need to do some careful experimenting too.
Printers and scanners are great to salvage, as they come with paper-feeding speed gears, like mine, I suspect.


Fix the fishing line to the roller
(the line's other end should already be tied to the 5mm wooden stick)
Do you see it now? As the roller collects the fishing line, wood stick is pulled down, lifting up the wooden shelf on the other side of the frame. Software then spreads the arms, creating the initial soap surface. Then, the fan blows air, arms close and Voila! a bubble is born.

Step 7: Building the H-Bridge

I don't have an awful lot to say here, other than:

Build or get an H-Bridge.
What's an HBridge? What do I care? - Excellent stuff, a must-read.
Some Arduino motor shields exist for that purpose, too. but then you'd probably need to tweak the code. At any case, my circuit does not use the consolidated control lines(FWD, REV, ENA in the schematics below). I just access all 4 bridges from code, keeping the right order not to short switch.
Also, I did not use an opto-isolator, although safer, as they were too expensive. Instead, I used the modified circuit (see third photo, below)

Driver code looks like this:

void HBridge::forward() {
   idle();
   digitalWrite(_positive0, LOW);
   digitalWrite(_negative0, LOW);
   digitalWrite(_positive1, HIGH);
   digitalWrite(_negative1, HIGH);
}

void HBridge::backward() {
   idle();
   digitalWrite(_negative1, LOW);
   digitalWrite(_positive1, LOW);
   digitalWrite(_positive0, HIGH);
   digitalWrite(_negative0, HIGH);
}

void HBridge::stop() {
   idle();
}

void HBridge::idle() {
   digitalWrite(_positive0, LOW);
   digitalWrite(_positive1, LOW);
   digitalWrite(_negative0, LOW);
   digitalWrite(_negative1, LOW);
}

Step 8: Connecting the Arduino

House the Arduino and H-Bridge comfortably inside a kit-box
and attach that kit box to the frame - using screws, zip locks or your favorite bonding technique.

Drill holes for the wires to come out and voltage come in.
I secured the Arduino inside of the box and drilled a hole next to the RBBB's DC-in terminal. That proved convenient.

Connecting the peripherals using the following configuration :

// scan limit switch pin
const int switchPin = 2;
// arms spread servo pin
const int servoPin = 3;
// fan source pin
const int fanPin = 4;


Connect the motor, switch and servo to the Arduino.
use the 3-wire extension cables, or any other wire you like.
During prototyping I used a small matrix like the one in the second photo, later I soldered the RBBB onto a PCB similar to the one I used for the H-Bridge.
When working with such a PCB, which I recommend, disconnecting conductivity is easily done by gently drilling the copper out (I use 3mm drill) and removing residue on that line with a good blade.


Connect the Fan through a relaying transistor or another Darlington
See here for serious documentation or here for shorter version of it.
I used shrinks to protect the transistor's terminals from closing circuit with anything when squeezed inside the kit-box.


Load the attached software onto the Arduino and dry-run

Modify servo boundary values, depending on servo type and physical arrangement
Yes, I mean this code:

// Servo boundary values
const int min_pos = 85;
const int max_pos = 127;

Step 9: Finishing Colors


Apply the Wacky Noddles on the frame
I cut the noodles on their length, about 2/3rd deep, consistently. Then I wrapped a wooden leg and just pushed the noodle onto the wood. It kinda wrapped it, and then came a zip tie to secure it. I know. call me superficial.

Add Even More Wackiness
apply differently shaped noodles on all other exposed wood surfaces.



*****************************************
Congratulations! You've Made it!
*****************************************


Prepare the bubble mix using these ingredients
Thanks, Danish bubble dudes!

Fill tub with soap mix and place below the Bubblebot
You'll need to do trial and error here, to get the right height and placement

Activate the bot and make final adjustments
* Modify source code for arms spreading speed and duration, number of spreading iterations
* Heighten / Lower the soap tub
* Try Indoor / Outdoor



 Now, you bring this colorful bliss to any birthday party and be thrice as welcome!
 

THE END



Thanks, Jonatan Bien
for some great photos!

<p>I made a little setup but the fan won't start.</p><p>This is the code /**</p><p> *</p><p> * BubbleBot Control Code</p><p> *</p><p> * By: Zvika Markfeld, Jonatan Bien, Uri Kareev</p><p> *</p><p> **/</p><p>#include &lt;Servo.h&gt; </p><p>#include &quot;HBridge.h&quot;</p><p>// scan limit switch pin</p><p>const int switchPin = 2;</p><p>// arms spread servo pin</p><p>const int servoPin = 3;</p><p>// fan source pin</p><p>const int fanPin = 4;</p><p>// H-Bridge control pins</p><p>const int positive0Pin = 5;</p><p>const int positive1Pin = 6;</p><p>const int negative0Pin = 7;</p><p>const int negative1Pin = 8;</p><p>// Servo boundry values</p><p>const int min_pos = 85;</p><p>const int max_pos = 127;</p><p>const int NUM_OF_SPREADS = 2;</p><p>const int SPREAD_SPEED = 30;</p><p>const int UNSPREAD_SPEED = 20;</p><p>const int SPREAD_DURATION = 3000;</p><p>const int SPREAD_DURATION_DECREASE_FACTOR = 3;</p><p>// H-Bridge controller (based on <a href="http://www.mcmanis.com/chuck/robotics/tutorial/h-bridge/bjt-circuit.html," rel="nofollow"> http://www.mcmanis.com/chuck/robotics/tutorial/h-...</a> but not as nice)</p><p>HBridge hbridge;</p><p>Servo myservo;</p><p>boolean forward = true;</p><p>void setup() { </p><p> myservo.attach(servoPin);</p><p> myservo.write(max_pos);</p><p> hbridge.init(positive0Pin, positive1Pin, negative0Pin, negative1Pin);</p><p> Serial.begin(115200);</p><p> Serial.println(&quot;setting FORWARD for the first time&quot;);</p><p> hbridge.forward();</p><p>}</p><p>void loop() { </p><p> // detect arms up</p><p> if(digitalRead(switchPin) == HIGH) {</p><p> Serial.println(&quot;SWITCH Detected&quot;);</p><p> hbridge.idle();</p><p> // switch fan on</p><p> digitalWrite(fanPin, HIGH);</p><p> int pos;</p><p> int times;</p><p> for(times = 0; times &lt; NUM_OF_SPREADS; ++times) {</p><p> // spread arms</p><p> for(pos = max_pos; pos&gt;=min_pos; pos-=1) { </p><p> myservo.write(pos);</p><p> delay(SPREAD_SPEED);</p><p> }</p><p> int currDelay = SPREAD_DURATION * (SPREAD_DURATION_DECREASE_FACTOR - times) / SPREAD_DURATION_DECREASE_FACTOR;</p><p> Serial.print(&quot;Delay: &quot;); Serial.println(currDelay); </p><p> delay(currDelay);</p><p> // close arms </p><p> for(pos = min_pos; pos &lt;max_pos; pos += 1) {</p><p> myservo.write(pos);</p><p> delay(UNSPREAD_SPEED);</p><p> }</p><p> }</p><p> // switch off fan</p><p> digitalWrite(fanPin, LOW);</p><p> // start bringing arms down</p><p> if(forward) {</p><p> Serial.println(&quot;setting BACKWARD&quot;);</p><p> hbridge.backward();</p><p> forward = false;</p><p> } </p><p> else {</p><p> Serial.println(&quot;setting FORWARD&quot;);</p><p> hbridge.forward();</p><p> forward = true;</p><p> }</p><p> /// wait until arm goes down and switch is off</p><p> while (digitalRead(switchPin) == HIGH);</p><p> }</p><p>}</p><p>If I use a simple test code the fan works</p><p>int motorPin = 4;</p><p>void setup() {</p><p> pinMode(motorPin, OUTPUT);</p><p>}</p><p>void loop() {</p><p> digitalWrite(motorPin, HIGH);</p><p> delay(1000); </p><p> digitalWrite(motorPin, LOW);</p><p> delay(1000);</p><p>}</p><p>Can somebody help me out? </p>
Hi,<br><br>Glad to hear you're building BubbleBot :)<br><br>if the fan does not start, this might be to various reasons:<br>fan pin burnt out (needs a reason, of course)<br>transistor not connected properly<br>transistor burnt out due to lack of resistor<br>input voltage too low (should be 12V for most fans)<br>fan polarity reversed (red wire should get the Plus)<br>and a few others<br><br>best way to debug:<br>with a voltmeter, make sure that the fan pin goes to high when the arms are spread open,<br>then make sure that the 12V's plus is connected to the fan and that the minus is connected to the arduino's GND<br>measure the voltage at the transistor's collector pin, see if you get (with the 12v's plus) a reference voltage of about 11V<br>somewhere along the way you will hopefully find the problem...<br>good luck,<br>Zvika<br>
<p>Hi,</p><p>thanks for your reply.</p><p>i checked the fan with a simple sketch and it was working.</p><p>Then I found out that i had to add a line to your script:</p><p><strong>pinMode(fanPin, OUTPUT);</strong></p><p>and now it is working.</p><p>But i have another question.</p><p>If the switch is on then the servo keeps on running.</p><p>So it needs to get a pulse instead of a closed connection.</p><p>How did you do that because if i use your script it only works if a press the switch and release it. i assume the switch will be in if the arms are up.</p><p>regards alan</p>
<p>Hi Alan,</p><p>Nice catch! that of course is a bug, this script is pretty old and I have since changed it quite a lot...</p><p>Regarding your question, the flow is after detecting the switch (signaling that the arms are in their up-most position), the arms are opened and closed based on NUMBER_OF_SPREADS and the rest of the parameters, and then a command is sent to the motor to go down. after that, the sketch waits for the switch to clear, in:</p><p>while(digitalRead(switchPin) == HIGH);</p><p>So, assuming the switch is not wired in reverse, causing the HIGH to signal a &quot;switch free&quot; state, I guess you are looking at a debouncing problem. the shortest way to solve that would be to add a delay right after the while statement above. for example, </p><p>delay(500);</p><p>should do the trick. </p><p>hope that solves your problem,</p><p> let me know if not and I'll try to help</p><p>Happy bubbling!</p><p>Zvika</p>
This is sooo cool! I want one, but it's too hard. (sigh) I know I'll make my dad do it!
thanks, dtninjagirl! its not as hard as it looks, if you're willing to learn some electronics.... good luck anyway, I hope you get your bubble bot soon
it's amazing! but have a question... How do you connect the motor to Arduino??? hope you can help me :)
Hi Emmanuel,<br><br>Thanks!<br><br>There are a few ways of connecting a motor to an Arduino, choose the one most suitable for you.<br><br>In case you need to spin it both ways, an H-Bridge would be needed. <br>See http://www.mcmanis.com/chuck/robotics/tutorial/h-bridge/ for theory and instructions, then either build one from scratch or (less laborious) get a solid-state monolithic unit such as the one that I've used, L298N (available on http://www.sparkfun.com/products/9479). Most convenient option however would be using a motor shield, such as http://www.dealextreme.com/p/l298n-stepper-motor-driver-controller-board-for-arduino-120542?item=1 or http://store.arduino.cc/eu/index.php?main_page=product_info&amp;cPath=11_5&amp;products_id=204<br>In any case make sure you have a flyback diode protecting the Adruino from back-induction coming from the motor due to its existing speed, once current stop flowing from the arduino control.<br><br>If you need to spin it in one direction only, just use a Darlington transistor to drive the high current, as explained in: http://itp.nyu.edu/physcomp/Tutorials/HighCurrentLoads<br><br>Hope that helps!<br>Good luck,<br>Zvika
try putting 50 of them on your roof!!!<br>:) :) :0
So cool! I'm gonna try to do some like that... wish me luck :D
great! <br>if you want, you can consult lfreundl, who just tackled a few building questions elegantly with a bit of my remote guidance. I think we even found a bug in the wiring diagram of the arcade controller<br>be sure to also check:<br>http://makeprojects.com/Project/Gigantic-Bubble-Generator/1364/1<br><br>and do post some photos! I'm happy to hear of the bubblebot genome replicating :)<br>good luck!
Great work!
omg, so cool, i would to make it if i had all the parts
Nice job! We like it so much we blogged about it.<br> <a href="http://www.robotliving.com/diy-robot/bubble-bot/">http://www.robotliving.com/diy-robot/bubble-bot/</a><br>
cool! thanks
awesome!!
:))<br>thanks, everybody! <br>your feedback is really a more than fair return for the effort of writing
zvizvi wrote:<br>&gt;&gt;Circuit Prototyping board, I use something that looks like this ...sorry, after pressing this link you'll get a 404 and will need to refresh the page, for some reason&lt;&lt;<br><br>The reason for the error is there is a space (manifests as %20 in html) at the end of your link. If you remove the space, it will link correctly.<br><br>Great instructable, BTW. My kids are going to love this!
thanks! fixed
This really is an Instructibubble!
I love this! Thanks. It combines the awesome of relatively complex machines performing simple functions with the awesome of bubbles!
cooooooooooooooooool ! <br>
Sweet!<br>My kids love those huge bubbles! This is a must-do project, will add to my ever-growing list :)<br>If only you could freeze those bubble mid-air... Just thinking...<br>Anyways, thanks for posting, and for the detailed instructions.
Thanks!<br>freezing bubbles is something you can easily do with small ones, just a minute or two in the freezer. Originally my idea was to electrify the bubbles, and taking photos right at the split second...
Inspiring !!! This machine seems to have a real uncle-like personality. like!<br>
:)))<br>cheers, HABUB!<br>
Great. I was considering making a bubble machine for the Sprakfun contest. Now I'm glad I didn't. Yours is awesome!
This is just ridiculously sweet. The padding makes it perfect for children chasing the gigantic spheres of beauty. We had a small toy like this when I was little. It did a decent job but the satisfaction of destroying a big one wasn't there.

About This Instructable

38,348views

140favorites

License:

Bio: Industrial design freshman. aspiring Inventor. hacking life, one bit at a time.
More by zvizvi:Audiable Memory Chest Rotary Emotiphone Cooking with Power Tools: Stuffed Zucchinnis 
Add instructable to: