Week 09

output devices


Tools & Materials

  • Eagle
  • Roland RSM-20
  • PCB
  • Output Device: Solenoid Valve (for pneumatic control)

Overview

This week, I learned how to work with a solenoid valve. For my final project, I’m working on a surface that changes shape, and am considering using either inflatable cells or solenoid actuators to do so. Conveniently, Axel introduced me to pneumatic valves that control flow with a solenoid valve, so I was able to work this week on one board that could work for both output devices.


Designing the board

Since I’ll be testing multiple options over the next few weeks, I redesigned my board from Week 4 to include a header that could allow other boards to connect to the extra pins on the Attiny44. Then, I designed a breakout board to control the solenoid with a button.

pcb

Button

I added a button to the breakout board that would send a High or Low signal to one of the ATTiny pins, depending on whether or not it was pressed.

Power

The solenoid valve I borrowed from Axel was spec’d at 9v, so I’d need more than the 5v that the FTDI supplied. I used the lab’s power supply to provide the 9v.

The lab’s power supply connected to the solenoid valve to test it before connecting to the pcb:

pcb

Mosfet

I used a mosfet to control the current. One pin, the gate, was connected to an open pin on the ATTiny. Depending on whether this value is low or high, it will allow current to flow between the other two pins, the drain and the source.

Diode

A diode prevented current from flowing backward when the solenoid returned to its original position.

Debugging (or, Things I did wrong)

It took three tries and many hours of troubleshooting to get this right.

  • I oriented the diode the wrong way. This was an easy fix–I used the heatgun to take it up and put it back on the right way.
  • I confused the source and drain pins on the mosfet, and originally had them connected the wrong way. This was a pretty complicated fix, involving redisigning and remilling the board:

The mosfet (with the sink and drains confused)

pcb

A remade board with with the sink and drain connected properly)

pcb

  • Some of the header connections between the main board and the breakout board didn’t correspond, so I needed to tangle some of the wires between them to connect the right things.
  • I didn’t connect the grounds between the two boards, which resulted in sporadic results. I addressed this first by connecting them with a wire, but then solved this in the traces when I remilled the boards to fix the mosfet.

A jumper wire to connect the two grounds (with a misguided and later removed resistor): pcb

All in all, I learned a lot this week. It was a challenge to debug with so many new parts that could have been backwards, and I spent a lot of time with the multimeter.

I could see that the correct pins were connected to the button and the mosfet gate using the arduino’s blink program and multimeter, but was confused by some of the voltages I was getting – ultimately the mosfet’s connections were the biggest culprit.

The final setup:

pcb

pcb

The debugged breakout board:

pcb

In the end, it worked. I hooked up one end of a hose to a rubber glove, and tested it with the button:

Down the road, I’ll consider other means of providing a pressure source…


Files