I’m building a weather sensor suite for a small privately-owned airport, and I’m wondering how to safely and compliantly get power into one of the enclosures. My concerns are safety and code-compliance (understanding that “legal” does not always mean “safe”). This is in the United States.

This unit is for the wind sensors, which have to be installed 30 feet above ground, away from buildings. The best site for this is an existing lamp post (ours, not public/utility) that has three-wire single-phase AC. There are no power receptacles; there are simply three wires running up the inside of the post from buried conduit.

The electronics in the enclosure are all 5V and 12V DC. The enclosure is fully gasketed and is UL-listed. I drilled holes in the bottom and installed listed, waterproof glands for cable entry.

What’s the best way to get power into the box? Two options I’ve considered are:

  1. Running the hot and neutral AC lines into the enclosure and installing a power supply in there. Didn’t like this idea because I don’t know how to deal with mains power inside my own enclosure.

  2. Purchasing a listed, IP-rated, constant-voltage LED driver designed for permanent connection to mains, and that outputs 12V. Fasten it outside the enclosure, run the DC leads up through one of the glands, and use a DC stepdown converter to create the 5V circuit.

Neither of these address the safety ground. The enclosure is plastic but the frame is metal (aluminum).

weather sensor package with plastic electronics enclosure

  • 1
    \$\begingroup\$ Concerned about code, then why didn't you mention the continent where the proposed installation is located? \$\endgroup\$
    – user80875
    Oct 12, 2020 at 18:27
  • \$\begingroup\$ D’oh, thank you - terribly “Americentric” of me! \$\endgroup\$
    – danavee
    Oct 12, 2020 at 19:23
  • 1
    \$\begingroup\$ Maybe easiest to have two outdoor rated enclosures. The second one could house the AC to DC converter. You would need to run conduit from inside your house to the enclosure to convey the AC power. Another option is to install solar panels and a battery and keep the whole thing low-voltage and independent from the grid. \$\endgroup\$
    – user57037
    Oct 12, 2020 at 19:32
  • 1
    \$\begingroup\$ I don't know if this kind of work is on topic there but Home Improvement Stackexchange tends to know more about electric code than we do. \$\endgroup\$
    – The Photon
    Oct 12, 2020 at 20:11
  • 1
    \$\begingroup\$ I looked over the picture. Seems like you have done a pretty good job so far. Far better than most people's first effort would be. \$\endgroup\$
    – user57037
    Oct 12, 2020 at 21:34

1 Answer 1


In the USA, all 120 volt branch circuits need to be run to listed boxes. The boxes must contain only listed receptacles, switches etc. You can buy boxes that are rated for outdoor use. They are equipped with covers that are large enough to plug in cords under the cover and have the cord exit the bottom with the cover closed. You can probably get away with running an extension cord from the receptacle to another box that houses the power supply. The 120 V conductors for the light can be attached to the back of the receptacle. You need to get wires out of the lamp post directly into the 120 V box or through a short piece of conduit.

What I am suggesting is to install a code compliant receptacle at a convenient location. Buy listed plug-in converters to supply the needed 5V and 12V. Enclose those in an enclosure that is large enough so that it won't overheat. Run an extension cord from that to the receptacle. Cut the molded receptacle from the end of the cord and replace it with a receptacle that screws together so that you can get the cord into the box through the entry gland. The DIY part will be a plug-in "appliance." I don't think that electrical codes really regulate plug-in appliances. People are strongly encouraged to buy only appliances that are listed by a nationally recognized independent testing laboratory such as UL or ETL, but I don't think there is any way to enforce that. Packaging up some listed products is not equivalent to having the package listed, but there is no reasonable way to accomplish that. If you do a good job, it should be safe and not likely to generate any complaint.

The circuit going out to the lamp post needs to be GFI protected. You can use a GFI circuit breaker or make sure it is an extension of a GFI circuit or other outdoor receptacles.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.