Introduction: Weatherproof Arduino
I have an arduino controlled garden irrigation system (the details of which will be published in a future instructable.)
Its requirements are:
- Inexpensive, easy to find parts.
- Summer weather proof. Must handle sun, rain, wind, hail, etc.
- Room enough for all necessary electronics.
- Uninterruptable 120v power (detailed here).
- Clear, so I can see the diagnostic led blinking from inside my house.
- Easily disconnectable, so it can be brought inside for programming.
Two copies of this project has been field-tested for one summer. It has given me zero issues.
Step 1: Parts Needed:
These are the major parts needed (plus a bunch of unspecific screws and stuff.)
- An arduino, of course (I used a funduino.)
- An AC adaptor (wall wart). I absconded this from my pile of them. Its output must be rated 12vdc. Mine came with the correct adaptor to plug into the arduino, so I absconded it for that purpose.
- A 6 AA battery holder with batteries. This outputs 9v. You could also use a 9v cell, but I found that it didn't last long enough for my needs. (I have power stability problems, ok?)
- 2 diodes (1N4001 or similar).
- Some plumber's strapping.
- Some hollow tubing (I used a piece from a rainbird sprinkler riser, it worked great!)
- A few 1" #6 screws.
- Some longish (1 1/2") bolts, I used #8, with a lot of matching nuts and washers.
- A case. I used one of those plastic shoebox sized cases.
- A board that is smaller than the lid of the case. For my case, I needed an 11" 1 x 6.
Step 2: The Power Supply
How it works: The diodes make sure that power only comes out of power sources, not in. The wall wart, outputting 12v, will supply the power if it is working. If it isn't working, the voltage into the arduino will drop to 9v, because the battery will supply it. The arduino's on-board voltage regulator will smooth it all out.
Using the plumber's strap, I mounted the wall wart with power prods up, and the battery case to the board.
I drilled 4 holes to hold some heavy wire, then glued the heavy wire into the holes. I used carpenter's glue which worked really badly as it melted when I soldered to the wire posts. I think that silicone glue might work better, as it is rather heat tolerant.
One of the four posts is the ground post. I soldered the black wire of the battery case to it. One lead of the pair of wires from the wall wart is marked with a white stripe, or white dotted line or sometimes a few ridges. That is the positive lead. (You can also test with a meter. I soldered the negative lead (the one without the stripe) to the ground as well. I then soldered the all-black lead from the plug for the arduino (which I had absconded from the wall wart) onto the negative as well.
A second post is the uninterruptable power post. I soldered both diodes to it, the lead at the end with the white stripe. I soldered the positive (white stripe) lead of the arduino plug in to it.
A third post is the 9v "battery in" post. I soldered the red lead of the battery to this post, and I soldered one of the diodes to this post.
The fourth post is the the 12v "wall power" post (Or whatever you want to call it.) I soldered the lead with the white stripe from the wall wart to it. I also soldered the other diode to it.
A little trick: I also need 12v out of my box to control my water flow valves. By wiring them to the "wall power" post, rather than to the uninterruptible power post, they become interruptible. The valves require quite a lot of current, so I wouldn't want to drive them with a battery, and, as they only come on twice a day, having them not work during a power failure will be no big deal.
Step 3: Mounting the Arduino
As mentioned in the parts list, I needed some risers to elevate the arduino about 3/8". (If you screw the arduino straight to the board, you stand a chance of dirt getting in there and producing alternative circuits.) As I am working on a drip irrigation system, I had low pressure sprinkler risers (from rainbird) floating around, so I cut off 3 3/8" pieces. I placed these pieces under the arduino at the mounting holes, and mounted the the arduino with #6 screws.
Step 4: External Wire Posts
My project has a number of external wires (for sensors and flow control valves.) In my desire to make the box removable, I wanted an easy way to disconnect these external wires. I did so by creating mounting posts as follows:
- I drilled through the board, and ran a bolt up from the bottom.
- I then placed a nut on the top, and tightened it down good. This makes a nice clean mounting post.
- I placed a washer on top of that, and put the wire that connects to my internal circuits onto it.
- I capped that with another washer and nut. At this point I could put in some thread-lock, as these parts are not intended to move.
- I created the mounting point for external wires with two washers and a top nut. I use a nut driver to access this, but the top nut could be a wing-nut so that no tools would be required. The external wire, when mounted, is placed between these two washers.
Step 5: Putting It All Together
- The board is screwed down to two legs (2 x 4s pictured on the parts page) with the upside down lid of the plastic box sandwiched in between. If your box is like mine, it has a ridge all around, which shows up as a small gutter all around when inverted. The board should not interfere with this gutter.
- Largish holes are drilled in the gutter at each corner of the box lid for drainage. (I used 3/8").
- More holes are drilled into the gutters of the box lid for access points for external wires. I use one to hold the power cord, and another to hold the wires for stuff mounted to the mounting posts.
- If necessary, a slit can be put between the holes and the outside of the lid so that wires can be slipped in and out rather than threaded through. With my configuration, this is absolutely necessary for the extension cord coming in.
You notice other items mounted to this board than what has been discussed. These are parts required for my specific project -- garden irrigation management.
We have a be nice policy.
Please be positive and constructive.