Arduino Nerf sentry gun build: Primary Arduino enclosure

Arduino Technology
Arduino Nerf sentry gun build: Primary Arduino enclosure

sentryArdABox03.jpg

Next up in my Arduino Nerf sentry gun build, enclosures for the electronics. I’m using two Arduino microcontrollers, and each one has a shield and set of ScrewShields for wiring. I decided to use two Arduinos because the 7-Segment shield and MotorShield each consume a lot of pins. It would be possible to reroute some of those and adjust the libraries and code, but I’m running out of time. I’m bringing this project to Maker Faire next weekend, and I’d rather avoid explaining things to the TSA, so it needs to be in a box for shipping pretty soon!

I’ll post a full system diagram soon, but here’s the quick version: Primary Arduino reads PING))) sensor distance data, drives the 7-Segment shield for display, triggers the relay firing circuit, and sends commands to the secondary Arduino. The secondary Arduino drives the MotorShield to sweep the gun left and right, reads the two bump switches to know when to change direction, and listens to the primary Arduino to know when to stop rotating when a target has been acquired.

sentryArdABox02.jpg

For the primary Arduino enclosure, I started with a cast aluminum project box. It has a few holes in it from a previous project, but that’s alright, consider it ventilation. I marked and drilled holes for screwing the Arduino in place, as well as three large holes on the side for wiring, USB access and power plug access. Standoffs would have been nice, especially if I’d tapped screw holes for them, but I went low-tech and used adhesive rubber bumpers to hold the board away from the case.

sentryArdABox01.jpg

Once I’d screwed the Arduino in place with some 4/40 screws and nuts, I stacked on the 7-Segment shield and a ScrewShield for wiring (full disclosure, I’m one of the WingShield Industries guys who makes the ScrewShield). I also mounted the relay circuit board to the inside wall of the case. I ran all the wiring through the hole, and can now mount it onto the gun’s stand.

In the Maker Shed:

Makershedsmall

arduino_duemilanove_cropped.jpg

Arduino Duemilanove

screwShieldASmall.jpg

WingShield Industries ScrewShield

Discuss this article with the rest of the community on our Discord server!
Tagged

John Edgar Park likes to make things and tell people about it. He builds project for Adafruit Industries. You can find him at jpixl.net and twitter/IG @johnedgarpark

View more articles by John Edgar Park

ADVERTISEMENT

Maker Faire Bay Area 2023 - Mare Island, CA

Escape to an island of imagination + innovation as Maker Faire Bay Area returns for its 15th iteration!

Buy Tickets today! SAVE 15% and lock-in your preferred date(s).

FEEDBACK