It Takes Two

I live in an odd house. I have alluded to that fact in a previous post, but I would like to elaborate and eventually get to an explanation of the title.

Ever wanted a pantry that had a window with a view? My pantry had a  window with a view… of the back of a wall. I spent years of indecision regarding the best use of this area. It seemed like a shame to sheet rock over it. I thought about printing out a scenic picture to place behind it, but the glass was cracked and I couldn’t get to its outside for repairs. I thought about building a refrigeration unit and having cooled storage for the summer when the house gets hot, but that quickly became cost prohibitive. A secret cubby hole? Opening it up to the other room? A big fish tank? I finally decided to remove the window and put in some shelves.

Removing a window must be simple, I thought. There were some screws that looked like they held the window in place. I planned to remove the screws, slide the assembly out, make some shelves, and have have the whole thing together in time for dinner. I thought.

Over the following days, I realized that IT TAKES TWO people to build a house. One person to hold up the pantry window, and the other to build the house around it.

I removed all of the screws I could find, and the frame would wiggle but not slide out. I started piecing away, sawing, and chiseling the window frame from the inside. There were 50% odds they installed the assembly from the inside and I might be lucky. Nope. Oh well, I lost that gamble.

I know the window was installed (100% odds) and it had to go in from either the inside (50% odds) or outside (50% odds). Therefore, it was obviously installed from the outside. I painfully contorted myself to piece away, saw, and chisel the outside of the window frame from the inside. I removed enough material that it should have come free, but it didn’t budge. Apparently, 50% odds +  50% odds doesn’t always add up to 100%. The game was rigged.

I finally got ignorant with hammers, saws, crowbars, and broken glass. Apparently the builder framed the house, installed the window outside of the house’s frame, added some more 2x4s for spacing, then bricked the house. This left the window frame mounted inside of the structure and behind the bricks that are now embedded inside of the wall.. This might be common practice, but it is news to me. Please don’t tell my wife, but it might sometimes be minutely advisable in some extremely rare situations to hire someone who knows what they are doing.

Window out! Now to address the shelves. This is where I discovered that the two guys who built my house were so good that they didn’t need to use a straight edge or square. Building the shelf housing and shelves was like a geometry lesson: it took rhomboids, kites, obtuse trapezoids, and parallelograms… most of the quadrilaterals but oddly no squares or rectangles.

Needless to say, it is done now. It might not be the best solution, but sometimes any solution is better than no solution. AND, sometimes a solution now is better than a better solution down the road.

My advice from this little project?

Sometimes it is best to go ahead with some idea rather than waiting for the best idea.

Sometimes it might be remotely conceivable that occasionally there might be a rare situation when there is some small chance that it could possibly (but probably not) be worth consulting someone who knows what they are doing. I can’t be sure about that, though. It would be best to consult a professional.

Boats and Beer, a PSA

Have you ever heard of Shipwright’s Disease? Though I don’t have a ship (or even a boat) it is something that I have been plagued with my entire life, and I personally consider Shipwright’s Addiction to be more appropriate. I was made aware of the affliction years ago, and I am seeing its effects more and more as I grow older. In lieu of an actual definition, it was explained to me this way:

  • You have a boat with a light bulb that needs changing.
  • You remove the light bulb to discover some corrosion.
  • You figure that if the light bulb is corroded, the rest of the wiring might have issues.
  • To remove the wiring, it is necessary to remove some of the paneling.
  • While the paneling is off, you decided to go ahead and replace it.
  • The new panels make the carpeting look old, so you decide to go ahead and replace that.
  • You realize that you can’t have a boat with new panels and new carpet but an old engine, so you decide to rebuild the engine.
  • If you are already taking apart the engine, why not make a little more power.
  • If you are going to make a little more power, why not make a LOT more power.
  • The inside of this boat with new carpet, paneling, and a more powerful motor is great, but it just doesn’t match that old faded gelcoat on the outside.
  • AND, it goes on. I am sure you get the point.

 

So I explained the boat half of the title. How does it relate to beer? Most recently, Shipwright’s Addiction has surfaced through my whim to brew beer. I decided it would be fun to drink a beer that I made myself, so I wisely bought only the most basic brewing kit… pretty much some buckets, some malt extract, and some yeast.

That’s when things started to go pear shaped.

I didn’t want to heat up the kitchen too much while brewing, so I found a propane burner on Craigslist that came with a mash tun for brewing all grain.

In order to utilize the mash tun, I needed a better way to cool the wort. My Craigslist purchase of a wort chiller came with some more brewing “stuff”. The volume of beer I need to brew to justify the equipment required a way to dispense a larger volume of beer. I went to Craigslist and purchased a kegerator. The kegerator wouldn’t fit the size of keg I had acquired, so I built a bigger kegerater. My bigger kegerator had empty space, so I needed to  more kegs… and CO2 bottles… and a CO2 filling station… and it kept going. It is really not my fault. Craigslist is obviously to blame.

In the end, things went from two buckets, some malt extract, and some yeast to almost everything shown in these pictures, and more. I even had to obtain an extra tool box and make shelves to hold all of the beer paraphernalia.

While I typically try to make  my posts helpful for the DIYer, this one isn’t. It isn’t even about boats or beer. It is a Public Service Announcement for those related to DIYers.

If your loved one is afflicted with Shipwright’s Disease, you can’t fight it. You can’t stop it. The best you can do is to keep them away from hobbies and sources of enjoyment, limit their internet usage and access to Craigslist, and give me all of their stuff when it becomes too much to bear.

Hot Paint On a Cool Chair

After one of my frequent plunges to the depths of the the internet, I returned with a neat idea. It began with the plan to update an outdated couch that my friend (now wife) gave me from her church. While it ended with no changes to that couch, the plunge down that particular rabbit hole yielded a fun project:

  • Started searching for appropriate fabrics to reupholster the couch.
  • Found out that I can have custom fabric printed with my face on it!!!
  • I didn’t want to wait for custom fabric, so I researched the types of ink that they used.
  • Found out fabric paint exists.
  • Decided the fabric paint is too expensive for the size of project I wanted to do.
  • Found something called Textile Medium that changes acrylic paint into fabric paint.
  • Calculated the number of little acrylic paint containers needed for the size of my project and got frustrated.
  • Discovered Latex paint is acrylic paint.
  • Lost interest in the couch and decided I wanted a wing back chair with flames.
  • Purchased a wing back chair (my mom actually got it from Goodwill).
  • Purchased Latex Paint and Textile Medium.
  • “Commissioned” my mother and beautiful wife to paint the chair (my artistic talents are somewhat lacking).
  • Enjoyed my Flaming Chair!!!

I was kind of surprised with how well the chair turned out, so I want to quickly post some things I learned. It might help the next person with some project, but it will definitely help me remember when I will get back to that couch someday.

  1. I am not sure the Textile Medium is necessary. We used it on parts of the chair but not other parts. Next time, I probably won’t mess with it.
  2. The fabric should be lightly sanded with fine grit sandpaper before painting and between coats to improve pliability and adherence.
  3. Latex paint from the hardware store seems to work fine.
  4. Plan on multiple coats.
  5. Plan on it taking a LONG time to dry.
  6. Let it dry between coats as much as your patience will allow.
  7. The final surface of this project is not what I would call “plush” or “soft”. It is not advisable to scrape newborns against the painted fabric surface.
  8. Sanding at the end might offer a softer feel, but it also might dull the colors and require another thin coat to bring them back. Some experimentation is in order.
  9. Due to the non-plush texture of the final product, I am looking at alternate options for my Flaming Underwear project.

As always, please comment if you have any ideas or suggestions. I am always anxious to learn from the experience and ideas of others.

A Cool Trick for Working On AC Systems

Last week was Mechanic Week for me. I knew I was going to put a new clutch in my wife’s little car, but I was also provided the surprise opportunity to replace the locked up AC compressor on Red Truck. With about 200k miles, I am kind of proud that it made it this long.

Everything is really easy to get to and the truck has high mileage, so I decided to do it right: new compressor, flush everything, new dryer, new orifice tube, pull vacuum for an hour, etc. With everything out in the open, I figured I might as well. I was able to replace the compressor and dryer in about 30 minutes. Then I got the orifice tube.

If you are not familiar with AC systems, the orifice tube is a small nozzle that allows the freon to expand from liquid to gas. Cooled gaseous freon subsequently goes through a heat exchanger to cool the car. The orifice tube is a small 1-piece device that simply slides into the high side freon tube before the evaporator. The orifice tube has an integral tang at the top for easy removal. Pull on the integral tang, and the whole device slides out of the freon tube. It would make sense to place that tang near the opening of said freon tube. Ford thought otherwise (shown to the right).

It turns out that needle nose pliers can be modified to reach the tang of the orifice tube. Modified needle nose pliers are very good for un-integral-ing the integral tang from the 1-piece orifice tube, leaving nothing to grab. Luckily, Al Gore loaned me his internet so that I could find a solution.

This seems to be a fairly common problem. I found that the “old guys” get a long wood screw, wrap tape around it as a guide, screw it into the top of the orifice tube, and yank on it with unmodified pliers and all of their might. Despite Ford’s best efforts, I had it out in minutes. Does this mean I am now an “old guy”?

While I am talking about Ford A/C systems, I would like to complain about something else they did. Some engineer somewhere decided to use a rubber ball instead of a shrader valve on their high side service ports. It might have saved a penny at some point, but I’ve never met one that didn’t leak. I’ve also met very few high side couplings that will reliably press the rubber ball enough to get a consistent reading. Why, Ford? Why?

Pulling all of this together, I wish someone would take Ford’s high side service port design and shove it up the engineer’s orifice tube. Also, try using a wood screw and some tape to remove your orifice tube if you (or it) are in a bind.

 

Needless to say, the gallant steed is all back together and on the road. Hopefully the AC system in Red Truck will keep together for another 200k miles.

Laziness or Chicken Coop Automation Part 2: Door Control Algorithm

Don’t understand the title? Read “It’s Hard Work Being Lazy or Chicken Coop Automation Part 1: Door Hardware” to elucidate the title and offer some background.

How hard can it be to control a chicken coop door with a microcontroller and DC motor? Just send a voltage to the door’s motive source to open it and reverse the voltage to close it. Right? You’d think so before delving in, but things quickly get more complex.

To explain, let’s use an example to show how the complexity grows :

  • You have a DC motor you want to use for control of a chicken coop door. you also have a microcontroller with plenty of output pins, each of which can be programmed to 5 volts or ground. Great. Wire each of the two wires from the motor to an output pin. Program one pint to be +5 V, the other to be ground, and the motor rotates. Reverse the +5 V and the ground, and the motor reverses. Now put a load on the motor. The motor quits rotating and and the microcontroller releases its smoke. It couldn’t supply enough current.
  • Put the smoke back into the microcontroller and get a proper power supply. Hook it up to the motor, put a load on the motor, power it up, and the motor rotates. Unfortunately, you are only able to rotate the motor one way. You need a way to reverse the motor polarity.
  • Now get an H-Bridge or series of relays to revere the polarity to the motor. Wire it up, program the microcontroller to control the H-Bridge or relays, and you have a reversing DC motor.
  • You hook everything up to automate the chicken coop, but now the microcontroller needs to know when the door reaches the end of its travel. You need sensors. Limit switches? Eddy current sensors? Reed switches and magnets?
  • Limit switches installed. Now, how does the microcontroller know when to open or close the door? Light Sensor? Timer? If using a timer, what about the changes in sunrise and sunset?
  • Do you need any manual external controls to give commands to the microcontroller? Like buttons?

Once you get all of that sorted, you also need to think about the algorithm the microcontroller will use to make its decisions. Most of the things listed above relate to specific motive sources and configurations, so I will not go into details. Each of my coops are set up totally differently, and what applies to one does not apply to the other. The control algorithm is common between the two, and I will elaborate on that.

Algorithm Considerations:

I wanted a couple features integrated into the control methodology:

  1. External inputs to adjust opening modes (do not open in the morning, open now, close now, etc)
  2. Decisions can be made mid movement (you can command the door to close while it is opening or vice versa)
  3. Controlled by a timer
  4. Account for changes of season
  5. Account for daylight savings

The first feature was to override the automatic controls. For instance: the yard crew is coming the next day and I want the chickens locked in their desolate little cells.

The second feature was mainly needed due to the speed of the actuator. One of the doors moves very v-e-r-y   s–l–o–w–l–y, and I didn’t want to wait for the door to move all the way before making another command. It would be like a windows update… me standing there helplessly slack jawed and gawking at something with no apparent progress. I would like to mention that even moving at a snails pace, the coop managed to capture the pictured cat. I came home one night heard one of the chickens meowing, and found the cat in there.

As far is the third feature goes, I thought about using a light sensor versus a timer. I opted for the timer because I didn’t know how well a light sensor would handle inclement weather and eclipses… I didn’t want a hen squished in the door when she was trying to rush out with her pinhole projector.

I wanted the fourth feature to account for the changes in sunrise and sunset between seasons.

I intentionally did not include the fifth feature because daylight savings is an annoyance, the microcontroller doesn’t know what it is, it stresses out the chickens, and I don’t think it should exist. In fact, it didn’t enter into consideration. I made reference to daylight savings to tell a quick story. I once knew of a man convinced daylight savings causes it to cool in the winter because it takes an hour of afternoon sun away. “That hour of sunlight is just added to the morning,” one might protest. He had already thought about that. “The hour is taken from the hot part of the day and added to the cool part of the day.” Sounds legit.

Control Algorithm: State Machine

The initial consideration for controlling the given example might be to simply apply voltage to the DC motor and wait for the door to trigger the limit switch at the end of its travel. However, what if a particularly stupid chicken is in the way and the door cannot finish its travel? Do you keep applying power and burn up the motor? What if the motor overheats, catches fire, and the other chickens attempt to save the burning, squished chicken? Do you want to risk losing the whole flock? I think not.

Taking all of the mentioned features into account, the algorithm I used was that of a state machine.

This state machine essentially:

  • Reads all inputs (user input, current time vs sunrise/sunset, reached limit of travel, timed out)
  • Interprets inputs to determine the desired state
  • Looks at the current state(door position or door movement)
  • Commands new state (or leaves it alone)
  • Repeats

Rather than telling the motor to do something and waiting for it to happen, the microcontroller continually polls its inputs, makes a decision, makes a command based on the current state, and goes back to polling its inputs. It does not make a command and lock everything up while it waits for verification. It goes back to work looking for inputs and making decisions. Practically, the processor can take new input,  process new information, make commands, and squish a chicken at the same time.

Calculating Sunrise and Sunset:

One of the “inputs” mentioned above is not what one might think of as an input. The processor calculates sunrise and sunset times on a daily basis and uses them to decide when to open and close the chicken squisher. The internet machine told me that sunrise and sunset times roughly follow a sine wave. Therefore, the algorithm estimates sunrise and sunset using a sine wave with periods, amplitudes, and offsets to match the peaks at the summer and winter solstices. I am including the snippet code so nobody else has to look for it. I hope that my comments are clear to others.

If you use this, you will have to match the times to your particular latitude, longitude, and time zone. If it is not clear, feel free to comment and I can provide more info.