Introduction: Embedded Affordances

I spend time thinking of ways to make product design more accessible. What if, instead of by a professional electronics engineer, tomorrow's technologies could be designed by an artist? What if products could be functionally designed and tested, right from the comfort of a CAD tool? This would eliminate all the soldering, head-scratching, and expensive contracts of modern products, leaving room for more ideas and ambition. Obviously, we aren't there yet. However, this instructable shows a half-product-half-dream of how to get there.

Embedded Affordances are tiny battery-powered circuit-boards designed to be 'embedded' into 3D printed models, i.e. placed into the model by hand and completely enclosed by the plastic. The embedded affordance can have lights, sensors, actuators, or wireless communication, bringing your creations to life!

For this instructable, we'll be making our own embedded affordance from scratch. That means a little bit of soldering and circuit design. Hopefully this project will give you an idea of how embedded affordances might work, and make you want to get involved.

Software:

  • SolidWorks
  • MeshLab (free)
  • NetFabb (free)

Printer:

  • An FDM 3D-printer (I used the MakerBot Replicator 2)
  • Transparent or translucent filament (I used transparent 'black' PLA)

Circuit

  • Microcontroller. I chose the AVR ATTiny85 because it's low power and you can program it with arduino
  • SparkFun Tiny AVR Programmer (to flash the MCU)
  • CR 2032 coin-cell battery. This tiny battery holds 240 mAh! That's more than enough for a couple hundred taps and shakes
  • White LEDs (2). Most any kind will work.
  • Piezo, which allows our model to register vibrations
  • 200K Ohm Resistor (Anything between 100K and 1M works)
  • Perf Board
  • Solder
  • 8-Pin MCU holder for ATTiny85

Step 1: Design Your Affordance (and Circuit)

What do you want to create? Do you want something that chirps, lights up, vibrates, or does something when its tapped or shaken? The space of design is totally open, and there are many possibilities. I decided that I wanted to make a lightbulb model that lights up when its tapped.

We are going to dead-bug this circuit because it's extremely simple. You mark out a 4x4 place on the perfboard, and you connect the two LEDs and resister as shown in the hand-drawn diagram. Make sure you are on the metallic side. After that, attach the MCU holder, then the piezo wires. Lastly, we're going to connect a wire from the battery + side to the circuit, and then we can cut out our board! The circuit turns on when the piezo's - side touches the - side of the battery (completing the circuit).

Step 2: Program Your ATTiny85

We're going to program our ATTiny to take a reading from the piezo and brighten the LEDs if it detects a vibration. The only complicated part is that we brighten or darken the LED using exponential decay, because our eyes don't perceive brightness linearly. Otherwise the code is fairly straightforward.

So then we flash the arduino code to the ATTiny. You can use this tutorial if you have never done that before.

Step 3: Design Your 3D Model

Now that we have our little embedded device, we need to design our 3D model. For this project, I wanted to make a light bulb. I used this thingverse model. Since the model had too many polygons for Solidworks to open it, I had to reduce the number of polygons and repair some broken edges. Please use this awesome tutorial for more information on cleaning up your model.

I saved the model as an STL and opened it in Solidworks as a 'solid'. If your model successfully opens, then congratulations! You have escaped the vortex of 3D model repairs.

Using the measurements of our embedded device, we first create a "cavity" object in SolidWorks. For the device I made, a simple cylinder shape works. Bonus points if you 3D scan your device and make a form-fitting cavity. Just make sure that it is flat at the top so that you have space to insert your model.

Then, in your object model, import the cavity part, and use add a 'move' feature to move the cavity into place. Then, use the 'combine' feature to subtract the cavity from the object model.

Congrats, you now have a printable object!

Step 4: Start Printing!

I used a MakerBot for this model. Unfortunately, the MakerBot doesn't have very intelligent settings for supports, so you have to disable them entirely. Otherwise, MakerBot will create supports inside your cavity. With other programs such as Cura, you can choose to enable supports that only touch the print bed.

As for other settings, most anything will work. I used a 20% hexagonal infill.

After you set up your print, start printing!

Step 5: Pause, Insert Your Circuit, Then Complete the Model

In order to place our affordance, we have to pause the print. In MakerBot, a regular pause doesn't work because the print head doesn't move. We have to do a sleep (cold pause) so the head moves out of the way. Then, we can drop in our affordance! After that, resume the print, and see the cavity get covered up.

Step 6: Enjoy Your New Toy!

You now have a fully functional prototype! Tap the lightbulb and see it light up. This model is also waterproof now, so feel free to throw it around or sink it underwater.