A robust turret with automatic tracking
Youtuber & maker Randomn has created a sleek tracking sentry turret.

A tripod base holds a rotating platform on which the firing mechanism and an ammo box with the electronics sit. The firing mechanism comes from a cheap mini AEG, and is mounted inside a 3D printed chassis. The gun rotates around two axes with NEMA stepper motors.
Inside the ammo box, a Raspberry Pi with OpenCV installed and running. Apart from tracking objects, the Raspberry also controls the stepper motors and the trigger mechanism through a stepper motor shield and a relay, respectively.
The webcam is static and mounted on the base. This provides a stable background image no matter where the gun is pointing. However, the gun can potentially work in manual mode, meaning a player could connect to it remotely and control where it shoots. Ideally, the webcam would then be mounted on the nozzle.
The power management is currently rather messy. Right now, the system has:
- A 12V battery for the stepper motors and a cooling fan.
- A 5V battery bank (with a solar cell) for the Raspberry Pi and webcam.
- What looks like 4xAA cells for the firing mechanism, since this is what it originally used. This 1.5×4=6V theoretically, but closer to 5V in reality.
As someone who’s had recurrent nightmares involving dead batteries just before matches, I say the fewer batteries the better. A possible solution would be to power everything from the 12V battery, providing a step down converter to 5V for the Raspberry and the gun. The 5V circuit would then need beefy capacitors to sustain the voltage so that the Raspberry doesn’t reset every time the gun shoots.
So how well does it perform?
Well, it has some limitations due to the image recognition. For example, unless the background is pretty uniform, it easily gets confused by patterns that mimic the target. Another issue is that the movement is a little bit jerky, which might be solved with stronger stepper motors. A good thing about NEMA motors is that for the same form factor there’s a wide range of available torques if you’ve got the money.
Overall, it’s one of the best looking turrets I’ve seen, and with some extra work it would be robust and user friendly enough for deploying it on matches constantly and reliably.