Repurpose Old Earphones to Capture 3D Printing Time-Lapses

by NirL in Workshop > 3D Printing

15016 Views, 124 Favorites, 0 Comments

Repurpose Old Earphones to Capture 3D Printing Time-Lapses

Instructables_Cover.jpg
Timelapse1.gif

As a writer here on instructables I've always wanted to film the process of 3D printing. However, 3D printing takes a really long time, so you have to fast-forward the video if you want to make it a little more interesting. Problem is, you can't just capture 6 hours of film and turn in into a 5 seconds video, because everything would be moving really fast and you'd be giving your audience a headache. So people have come up with a cool solution- instead of capturing the entire 3D printing process, reduce the number of images to 1 image per layer. After every 3D printed layer is complete, the printer head moves to a certain position, and an image is taken. The results are hypnotizing - the object you're printing seems to be forming out of thin air.

So, I wanted to do be able to capture these awesome videos myself. I looked around, and it seems that most people are using a Raspberry Pi or some kind of a micro-computer connected to a web app called OctoPrint. It's awesome, it really is. But Rasberry Pi costs over 100$ these days and are pretty hard to find ever since the COVID chip crises started. Honestly, I just wanted to start capturing 3D printing time-lapses today. Also, my 3D printer is working perfectly, and I didn't want to mess with my workflow - I don't want a new micro-computer and I definitely don't want a new software.

In this instructable I'll show you how to start capture 3D printing time-lapses in about 1 hour from now.

All you need is a few basic components you're likely to already have, and a access to the Cura slicer.

Here's a short overview of the instructable:

  • We'll use a smartphone camera to capture the time-lapses.
  • To use a smartphone, we'll need a way to trigger its camera externally.
  • We'll build a simple external trigger using a pair of old earphones, and see how it works.
  • The trigger will be mounted to the 3D printer, and a simple Cura command will tell the printer to press the camera trigger once each printed layer is complete.

Let's get going then :)

I hope you follow along, and let me know if you have any questions or comments!

Supplies

parts.png

Honestly, this reuse challenge was perfect for me, since I collect and reuse as much as I can. However, this kind of positive reinforcement to my little hobby of collecting trash is probably the last thing my wife wanted. So as usual, thanks instructables for being on my side! :) For this project you'll need very few things, all of which are easily salvaged or reused from old electronics.

Materials

  • One pair of old earphones (with 4 terminals, usually the ones with a microphone).
  • One limit switch (I salvaged mine from an old printer).
  • One 220-Ohm resistor.
  • Electronic wires (optional, for extending the earphone wires). These were also salvaged from a dumpster.

Tools

  • Soldering iron and soldering wire.
  • Cutters.

Video Version

4K 3DP Time Lapses With Your Phone | No Mods/OctoPrint/Anything Complicated

For those who want to see a narrated video version the project, feel free to watch the one I made

This is a good point to mention that if you want to support my future projects (for free!) subscribing to my new YouTube channel is the best way to do that! :) Thank you so much!

How Is This Going to Work?

Overview.png
Snapshot.png
Snapshot_1.png
circuit.png

To get everything up an running with the least amount of trouble, I decided to capture images with my smartphone. Many people, including myself, have old smartphone laying around, usually with pretty decent camera.

The idea here is to add an external camera trigger, which we will later mount on the 3D printer. A simple setting in Cura will help us capture images with this trigger (1st image).

The most common way I know of to trigger a camera is a selfie stick. You connect a cable to the audio jack of your smartphone, and when you press the button on it, the smartphone camera is triggered (2nd image). This is exactly the mechanism we need here.

So I pulled out my multimeter and checked what happens when you click the button on the selfie stick. It turns out that when the press the button the only thing that happens is that the 3rd and 4th terminals are connected via a 220-Ohm resistor (3rd image).

So all we need is a a triggering mechanism with a 220-Ohm resistance. I made a simplified circuit diagram to make things clear (4th image).

Prepare the Old Earphones

Snapshot_2.png
Snapshot_3.png
Snapshot_4.png

Say goodbye to your old earphones, and cut them off, leaving the headphone connector and a the wire attached to it.

Expose the electric wires in it. Remove protective cover. I primed the wires using soldering wire to make things go smoothly.

Finally, identify which wires are connected to the 3rd and 4th terminals and cut off the other two.

Add Resistor

Snapshot_6.png
Snapshot_5.png
Snapshot_7.png

Connect a 220-ohm resistor to one of the wires coming from the headphone jack.

If you're adding extension wires like I did, connect one of the extension wires to to other side of the resistor.

Put some electric tape or a heat-shrink cover over the soldered wires to protect them.

Connect to the Limit Switch

Snapshot_8.png
Snapshot_9.png
Snapshot_10.png

Connect the two wires to the limit switch. Most limit switches have 3 terminals. Clicking the switch connects the outer terminals with the middle one. So pick one of the outer terminals, and connect one of the wires to it. Now connect the other wire to the middle terminal.

Test It!

SwitchTest.gif
TriggerTest.gif

At this point you should have the headphone jack on one side, connected to a limit switch on the other side, with a resistor connected to it in series (see the diagram in step 2).

Before we move on, test your wiring and make sure everything works!

Use a multimeter to check that the switch is working properly - it should show 220-Ohm resistance between the 3rd and 4th terminals once the circuit is closed.

Now plug in the audio jack, open a camera app, and make sure it triggers your camera.

** Please note that this method worked with 3/4 phones I tried. I have no idea why it didn't work with the 4th one, but it's something to consider. However, if it doesn't work with your regular camera app, it still might work with the 'Open Camera' app, I mention in Step 8.

Attach to 3D Printer and Find the Right Settings

LimitSwitchMounted.gif
Positioning.gif

In the next step we're going to tell the printer to move to a certain position after each layer is complete, and we want the camera to capture an image at that point. The way that's going to work is by having the print head manually press the limit switch, which will trigger the camera.

Mount the limit switch to your printer at a position you think is best. It should be somewhere that moves with your z-axis (if it moves) but you also need to make sure that it doesn't interfere with your prints. I mounted it at the end of my x-axis rail, so when the print head moves all the way to the right, it press the limit switch. To connect the limit switch, I printed a small custom holder, but you can also use hot glue or something to get the job done**.

To be as precise as possible, follow these steps:

  • Home your printer.
  • Using the printer's interface, slowly move the print head towards the limit switch.
  • Once the limit switch is pressed, write down it's position. You'll need it in the next step. For me, that happened at x = 195mm.


** I would share the file for the limit switch holder, but it's really specific to the limit switch you're using, so I don't think my design could help many people, and I don't want people to print useless parts.

EDIT - due to requests the STL for the holder is now available. Honestly - chances are you'll need a different holder for your print & limit switch.

Cura Settings

Snapshot_12.png
Snapshot_14.png
Snapshot_13.png

Now we're going to use a built-in Cura plugin that'll help us capture the timelapses. It'll tell the printer to repeat a few simple instructions after each layer.

  • Go to in the Extensions tab go to Post Processing -> Modify G-Code.
  • Press Add a script, and look for the 'Time Lapse' script.

How to set it up

  • The 'Park Print Head X', 'Park Print Head Y' will move the print head to these x & y values after each layer. Use the values you measured in the previous step.
  • The 'Pause Length' tells your printer how long it should remain at the parking spot. This depends on your phone's ability to capture images. If it's quick, pauses should be short. I used an old smartphone so it had to stay parked for about 800ms for an image to get captured without getting blurry. However, if you pause for too long, the smartphone may capture multiple images after each layer, which is annoying.
  • Set the Retraction Distance to a value similar to the rest of your print. If you don't do this, your print is going to get a ton of stringing.
  • Finally, I set the 'Z-hop...' to about 2-3mm, which means the print head slightly moves in the Z-direction before each pause (and moves back when it's all done).

Press close, and you're done.

Notice that the modified G-code won't be shown in Cura just yet. You can only see it if you slice the model and re-open the G-Code file in cura instead of the STL file.


Open Camera App

Snapshot_16.png
Snapshot_17.png
Snapshot_15.png

Instead of using my phone's built-in camera app, I used an open source camera app called 'Open Camera'. It's awesome. You can set the focus and exposure manually and keep them locked for the entire video (which is important), and pick whatever resolution you want the images to be (I picked 4K since that makes for a really high resolution video).

Another convinient option is to automatically save the images to a google drive folder, so you can view the print from a distance and see how things are going.

Tips and Tricks for the Perfect Timelapse

BadLighting.gif
2Images.gif

Here are a few extra tips to get you start smoothly

  • Make sure to only use artificial lighting. We're used to people saying that the best images are captured with daylight, and that's true, but when capturing 3DP time lapses you have to remember that a video can last longer than 24 hours. If you don't want your videos to flicker, close the curtains and turn on those LED's. See First GIF for an example.
  • Start small! Test your Cura settings and make sure the X, Y parking spots are perfect and that clear images are taken. I had to find the sweet-spot between capturing 2 images after each layer and capturing blurry images by modifying the pause length. See second GIF for an example.
  • Once the images are all captured, you have to stitch them together into a video using whatever video editor you like. To really have a smooth looking video, make sure you play around 30 frames per second. That's 30 layers per second! So if you have a print with 300 it should last for 10 seconds max.

Capture Your First Timelapse

Timelapse3.gif
Timelapse2.gif

You're all done! It's time to give it a go! Like I said before, you should start small, because things do take some fine-tuning, and you don't want to find out you have something wrong 24 hours into the print.

That's all for today! Hope you enjoyed reading, and if you have any questions - let me know in the comments!

If you like my instructable and want to see more, you're welcome

to visit my instructables page and my website