Archive for November, 2015

Pneumatic Controller: FINAL PART (9)

Well here we are again. It’s always such a pleasure.

This is the thrilling conclusion to a long and varied adventure. There were lots of bumps along the way, but I’ve enjoyed the experience immensely. It’s a bit sentimental so forgive me. On the other hand, lots of pictures.

Part 1 Part 2 Part 3 Part 4 Part 5 Part 6 Part 7 Part 8

Onward!

After replacing my cowardly and broken Arduino,

Coward

Coward

I decided that I would also like to be able have an actual on/off switch that wasn’t locked inside the Box. I had two pieces the Box came with: the visible dial and the actual switch.

DSCN2347

DSCN2348

It had several powerful springs inside that made it very hard to turn, so I broke it open and removed those.

DSCN2350

Then I attached mounting pieces to some scrap wood to hold the switch in place.

DSCN2363

I don’t think I’ve ever used those metal things for actual picture hanging

DSCN2365 DSCN2366

DSCN2386

With some more on top to hold it down

DSCN2387

Holes drilled in the lid

DSCN2388

Bolted in place

DSCN2400

Wired

DSCN2401

This is what was sticking out from the switch

DSCN2402

The fit was a bit wobbly so I used a lot of glue for support

DSCN2403 DSCN2404

DSCN2405

Ta-da!

Now the entire face was used. Hooray!

Gorgeous

Gorgeous

You may remember from last time about my sensor interrupt troubles. As a quick recap, the smaller pistons were moving too fast for the program to catch their sensors, so I tried wiring them to an interrupt pin (which would make the program pay attention regardless of what it had been doing) so that every time a sensor was hit, the program would know. This time around I was able to test it with multiple sensors through a common interrupt pin.

The problem I ran into was that the interrupt would only trigger when the signal went from low to high. But if a piston stopped on a sensor for a while (like if it was done cycling), it would stay high and no other sensors could trigger it. What I needed was a way for the signal to start out as high, then drop quickly automatically. That way each sensor could trigger the interrupt no matter what else was happening.

My brother-in-law suggested using capacitors, which would change their voltage over time. I figured out a simple circuit of just a capacitor in series with a resistor, then measuring the voltage over the resistor. Using a diode as well meant that the signal wouldn’t also go back through the circuit and give a false positive reading for all the other sensors.

I added another resistor in parallel to the capacitor to allow it to discharge after the sensor reading went low (the diode prevented it from discharging through the normal circuit). The resistor values were found using science (below) and guessing and checking.

Science

The capacitor value was found using the age-old engineering method of it being the only one available.

Testing

It works!

A little bit of tweaking and voilà! Newer, nicer circuits. Just look at all the color!

new cap circuit

First and second (final) version of capacitor diagram

DSCN2622

I’m really liking all the color. The old PLC system was grey and dull.

To make some of the power wiring a bit easier, I also cut a piece of an unused breadboard and glued it onto the Arduino.

DSCN2603

Glued on

DSCN2604

Wired to power/ground

Then I had to wire everything back to the Arduino for the first time in several weeks, which was not terrifying at all. I totally remembered where everything went and didn’t have to triple check each step.

DSCN2606 DSCN2607 DSCN2608 DSCN2609 DSCN2610 DSCN2611 DSCN2612 DSCN2613 DSCN2614 DSCN2615

DSCN2615 (1)

A bit of a technicolor bird’s nest but no one ever needs to see it

And that’s it. It’s done. After months of design, coding, building, and fixing, it is completed. It has been a wild and exceptionally fun ride. To give some idea of how much the design has changed, here are the original and final circuit diagrams side by side:

comparison

Oh, Ari From The Past. So naive.

Also, I’ve gotten a lot of questions of what cycle testing is actually used for, so here is an example I set up for the “Demo mode” when we have tours through the department:

I have loved working on this project so much. This has easily been the biggest and most complex project I’ve tackled on my own and I’m very happy that I was given that chance. I’ve learned a lot while working on it, from technical stuff like how to use keypads and pistons, as well as more general things, like buying extra small, cheap components in case some break (they will) and assuming the project will take longer than you originally plan (it will).

Once again, I am so thankful that I was given this opportunity to improve my skills, learn new things, and work on a larger scale project. I’m also happy to have been able to share it with all of you.

Hopefully I will return shortly with a new project to document.

Until next time,

Ari

yeah

(Unfortunately I cannot find where I found this)

Advertisements