Smart Turret Sentry Weapon 2
Smart Turret Sentry Weapon 2
Smart Turret Sentry Weapon 2
Patrick Croom
Kevin Neas
Anthony Ogidi
Joleon Pettway
May 5, 2010
Table of Contents
Executive Summary ......................................................................................................... 3
1. Introduction.................................................................................................................. 4
1.1 Objective......................................................................................................... 4
1.2 Motivation...................................................................................................... 5
2. Project Description and Goals ..................................................................................... 6
3. Technical Specification................................................................................................ 7
4. Design Approach and Details
4.1 Design Details .......................................................................................... 9
4.2 Codes and Standards ..................................................................................... 18
5. Schedule, Tasks, and Milestones................................................................................. 18
6. Project Demonstration ................................................................................................ 21
7. Marketing and Cost Analysis ..................................................................................... 24
8. Summary..................................................................................................................... 25
9. References................................................................................................................... 27
Executive Summary
The Turret Trackers design group has successfully developed a fully functional proof-ofconcept prototype Fully Autonomous Sentry Turret system. This system is an autonomous, area
protection, anti-personnel sentry turret with integral Identify Friend/Foe (IFF) capability. The
system prototype uses a standard webcam connected to a notebook computer running custom
software in order to detect and track movement sources within the systems field-of-view. This
data is used to position a pair of servo motors in a dual axis pan and tilt mount in order to aim an
optical laser marker at the moving target. The IFF capability is achieved using two independent
systems. For the first, targets who are attired in the designated safe color scheme will be
allowed to pass unharmed. The second safety uses an IR remote to transmit a safe code to the
turret, allowing safe passage so long as the code keeps transmitting. There is a clear need for
such a system in certain military applications, as no similar product is currently available. The
only other systems capable of fulfilling the same function are of very limited utility and much
more time consuming to set up. Specifically, currently available systems are very ineffective
indoors and are almost entirely indiscriminate in their operation. Both of these failures are
addressed by the FAST system. By using commercial off-the-shelf (COTS) materials as much as
possible, the design team was able to develop the prototype system for only $1893.50.
1.1 Objective
The purpose of this design effort was the development of a viable proof-of-concept
prototype of the Fully Autonomous Sentry Turret (FAST) System. In its simplest form, the
FAST system is composed of a standard web camera connected to a commercial notebook
computer using a custom software package to detect and track sources of movement while
ignoring motion sources designated as friendly. This tracking information will be passed to a
series of servo motors which will align the attached firearm to point and fire at the motion
source. For the prototype, a optical range low power laser was used in place of an actual firearm.
The FAST system is capable of protecting a fixed position from the approach of enemy
combatants from a fixed direction, optimized for use in indoor areas. FAST is also capable of
identifying and not targeting friendlies within its field of vision based on identifying markings.
Authorized personnel can also pass safely through the field-of-fire by transmitting the correct
code with a handheld IR transmitter. In order to accomplish this, FAST employs a computer
vision system to track motion within a fixed field of view and a series of servo motors to orient a
pointing/projectile firing device at the observed motion source. FAST is also able to
differentiate between targets and non-targets based on object size and major identifying
markings. This system is ideally suited for use by military organizations and private security
companies for static defensive purposes. The FAST system has a detection area optimized for
most indoor scenarios and is small enough and light weight enough to be transported and setup
by a single individual.
1.2 Motivation
There exists, among modern military organizations, a distinct lack of available systems
for the purpose of unmanned anti-personnel area denial and/or defense. The only existing
systems, which provide any remotely similar function, are barbed wire and landmines. Both of
these systems are rather dated and generally low-tech. In addition, these existing systems are
entirely indiscriminate in their operation, effectively closing off the position in which they are
emplaced to everyone. These systems are further handicapped by the limitations on the settings
in which they can be employed as well as the time consuming and potentially complicated setup
that is required in order for them to be effective.
The FAST system suffers from none of these inherent limitations. FAST is capable of
discriminating between targets and non-targets in mere fractions of a second. FAST can be
easily emplaced and positioned in less than a minute and can be activated with only a few
keystrokes. This also means that FAST can be employed indoors, something that is generally
impractical for any other system. The FAST system is also superior in many situations to using
human soldiers for the same purpose because FAST cannot become tired or distracted while on
duty. This also means that those same soldiers will be kept out of danger.
However, there were some changes to the more technical aspects of the specifications between
the proposed design and the prototype. The design was originally intended to have an effective
detection range of 50 feet and be able to engage targets within 2.0 seconds of detection. For the
prototype, it was necessary to shorten the detection range to 40 feet, but the prototype achieved a
target acquisition time of less than 1.0 seconds. This much faster acquisition time more than
compensated for the reduce range in terms of overall engagement capability.
3. Technical Specifications
The FAST system was designed to meet both quantitative and qualitative specifications.
The quantitative specifications are shown in Figure 1. The design proposed the ability to track
and acquire a target with 50 feet of the device. The webcam processes a resolution of 352x288,
and the IR receiver is reliable up to 45 feet. Due to the limitations of the webcams quality and
the IR receivers range, the FAST system is limited to a 40 feet range. Originally, the field of
view was limited to 45 in order to reduce costs. However, the code acquires targets within a 65
field of view, with the ability to be calibrated for a range up to 90. Finally, in order to feasibly
track and obtain a target as fast as a human, the system required a minimum acquisition rate of 2
seconds. The final design can track movement faster than 15 frames per second. This allows the
servos to acquire the target in less than 1 second and as little as half of a second.
Table 1. FAST System Quantitative Specifications
Feature
Proposed Specifications
Actual Specifications
Effective Range
50 feet
40 feet
Field of View
45 degrees
65+ degrees
2 seconds
< 1 second
The FAST system was required to meet the following qualitative specifications:
Portable
Successfully engage a target before that target can reach the turret itself
Allow properly designated personnel pass through the area-of-defense without being engaged
All qualitative specifications were determined to be vital components for the success of the
system. However, security concerns with the color recognition system required that an additional
recognition system be implemented into the system. An infrared security system was
implemented which requires authorized personnel to send a predetermined IR signal
continuously while passing through the area-of-defense. The final qualitative specifications met
are:
Portable
Successfully engage a target before that target can reach the turret itself
Allow properly designated personnel pass through the area-of-defense without being engaged
1- HP laptop
1- LED
1- 12 volt battery
As shown in Figure 2, the Arduino board and webcam sent data to the notebook through
USB, which in turn sent data to the Phidget control board. The webcam and Arduino board
received power through USB, while the Phidget control board received a 12 volt, 3 amp power
supply from the external battery.
Interface
The FAST system has been design to be user friendly. Once the code is started,
the user will have two options in the File menu: Open Local Capture Device or Exit.
When Open Local Capture Device is selected, the user will be prompted to choose the
webcam, as seen in Figure 3.
10
Motion Tracking
The motion tracking software is implemented using the AForge.Nets computer vision
library. The library is an open source C# framework designed for developers and researchers in
the fields of Computer Vision [1]. The motion tracking class runs under the motion solution
(the code can be accessed through the website) [3]. This solution has been adopted from Andrew
Kirillovs Motion Detection Algorithms software, which has been posted under the GNU
General Public License [2].
In order to begin tracking motion, the code must first connect to a webcam. The interface
will list all image devices connected to the computer. Once the user has selected the appropriate
webcam, the system receives a live digital video feed through the USB. In order to process the
frames at a high frames per second rate (greater than 15 fps), all image comparisons of the video
stream are done in virtual memory. The frames are compared in bitmap form in the computers
memory and are never saved on the hard drive. This allows for faster computation and
comparison of successive frames.
11
Safe Parameters
After marking a significant source of movement, the system checks for three safe
parameters: a period of no significant sources of movement, the correct infrared signal, or an
instance of the safe color located within the significant source of movement. If any of the three
safe parameters are satisfied, the servo motors will go to their safe position, equivalent to a
12
turret pointing towards the ceiling. This effectively keeps allied personnel from receiving
unnecessary harm in the case of an accidental misfire.
As each frame is analyzed for significant sources of movement, the system will monitor
how many frames do not detect movement. If motion is not detected in five successive frames,
the system assumes any targets have either left the area of interest or have been incapacitated.
The turret will then move to the safe position until movement is detected again.
IFF Color
Whenever a rectangle is displayed on the video, a small square is also placed at the
(height/3, width/2) position, as seen in figure 3. This marks the target area for the turret, as well
as the area to check for the safe color. Once the target is marked, the RGB values of the center
pixel are compared to the safe color. For example, when the safe color is blue, blue is required to
be the dominant color in the pixel. If the blue value (on a range of 0:255) is greater than both the
red and green values, then the target is deemed an authorized personnel. If the RGB values meet
the specified safe range, then the servos are set to the safe position until the safe color is no
longer detected.
IFF IR Receiver
The infrared recognition system consists of three vital components: the Sony blu-ray
remote, the IR receiver connected to the Arduino Duemilanove board, and the SimpleSerial C#
class in the motion solution. The Sony remote sends an IR signal to the IR receiver. As the
signal is received, the Arduino board records the signals and outputs through the serial port to the
SimpleSerial class.
13
All Sony remotes have the same infrared signal protocol. The signal is 12 pulses long and
follows a 2.4ms LOW pulse, as seen in Figure 6 [4]. For the signal, a pulse is considered to be a
LOW point in the signal. The code is sent in binary, so a 1.2 ms pulse is a 1 and a 0.6 ms pulse
is a 0. Each data pulse is separated by a 0.6 ms HIGH signal. The entire signal lasts for 45 ms,
and continuously repeating signals are separated by 40 ms.
14
be found on the website [3]). The Arduino waits for any IR signal to be sent through the IR
receiver. It measures 13 pulses (the initial 2.4 ms pulse, and the subsequent 12 pulses) and
records the length of each pulse in an array. If 13 pulses are not received (the signal is
interrupted), the code will not send partial numbers. Instead, it will send a 0 through the serial
port.
Once the signal is received, the LED will flash, letting the user know a signal has been
received from the remote. Every pulse is converted into binary: a pulse lasting longer than 1 ms
is a 1, a pulse lasting longer than 0.4 ms and less than 1 ms is a 0, and all others are a 2,
signifying invalid signals. The last 12 digits represent an individual button on the remote. For
example, a 1010011101 represents the large center button on the Sony blu-ray remote, as seen
in Figure 8. The Arduino board then converts the binary number into decimal (1010011101
becomes 1341). It prints this number on a new line and sends it through the serial port. As long
as the board is receiving power, it will always search for signals and send them through the serial
port.
15
true. If the user is pushing the incorrect button or is not pushing a button, the code will return
false.
SimpleSerial uses ReadLine( ) to receive the entire decimal number from the Arduino. If
the Arduino board is not sending a number through the serial port, the code will timeout after 10
ms and return false. Next the code compares the incoming number to a preselected safe
number, in this case 1341. If the user is pressing the correct button, SimpleSerial will return
true. If the motion code receives a true, then the servos will move to the safe position.
They will remain at the safe position until an IR signal is no longer received or the user presses
the incorrect button.
16
feet using a conversion ratio. For example, an object 40 feet away has a ratio of 9.5 pixels to 1
foot. To determine the angles for the servos, the tan-1(x/z) and
to move the servos, these angles are then added to the default position of the servo motors. The
default position points the servos at a 90 angle away from the box, in the same direction as the
camera; this position is equivalent to (115, 95) on the servo motors. The calculations for an
object 30 feet away can be seen in Figure 9.
17
18
Est.
Work
Hours Owner
Resources
10
10
21
52
KN, JP
Visual Studio
24
KN,JP
Visual Studio
KN,JP
Visual Studio
JP
Visual Studio
15
KN
Visual Studio
15
PC,AO
7.1
IR Remote code
Order parts for actual
turret
Assemble turret stand and
install servo motors and
power supply
Integrate physical turret
with Turret Tracker
Software
7.2
1.2
1.3
2.1
2.2
2.3
3
4
6.1
18
PC,AO
Servo Motors,laptop,
webcam, stand
materials
PC,KN,AO,JP
Visual Studio
7.3
Calibration
21
Testing
18
6.2
M&S
$340
19
21
22
a success only if the FAST system does not engage the target and instead sets itself to the
safe position while the target is wearing the safe color.
Safe Passage with Proper Color and IR Remote Single target will attempt to
navigate a hallway fitted with the FAST system while wearing the safe and pressing the
correct button on the IR remote. The purpose of this test is to demonstrate that the safety
systems do not interfere with one another. Test deemed a success only if the FAST
system does not engage the target and sets itself to the safe position while the safe button
is pressed on the IR remote and/or the target is wearing the safe color.
Escorting Two targets will attempt to navigate a hallway equipped with the
FAST system while one is pressing the correct safe button on the IR remote and the
other is without any safety. This test is deemed a success if the FAST system does not
engage either target and sets itself to the safe position for so long as the safe button is
pressed on the IR remote.
Results
The FAST system successfully passed all of the target engagement and safety
function tests. In the single target tests the FAST systems successfully detected and
targeted the single subject whether the subject was moving in a linear or erratic path. The
FAST system on average was able to detect and track targets within 1.0 seconds of the
target entering the FAST systems 40ft. range. When faced with multiple targets the
FAST system successfully prioritized targets, engaging the target with the closest
proximity first. In the safety functions tests, the FAST system did not engage friendly
targets after detecting a correct safety parameter (correct color or IR signal) and moved
into safe position. The FAST system also successfully demonstrated the ability to
23
allow multiple targets to be escorted while a safe signal is being emitted from an IR
remote.
24
Estimated
Actual Cost
$45
$45
$500
$50
$200
$20
$30
$140
$7
$3
$1.50
$25
$20
$58000
$720
$59806.50
As can be seen most of the items needed to build the sentry gun are items owned by the
average American and can be bought at any local electronic store.
25
26
9. References
[1] AForge.Net Framework. AForge.Net, 2010. [Online]. Available:
http://www.aforgenet.com/framework/
[2] A. Kirillov. Motion Detection Algorithms. The Code Project, 2007. [Online].
Available: http://www.codeproject.com/KB/audio-video/Motion_Detection.aspx
[3] P. Croom, K. Neas, A. Ogidi, and J. Pettway. Turret Trackers. 2010. [Online].
Available:
http://www.ece.gatech.edu/academic/courses/ece4007/10spring/ECE4007L01/dk6/
[4] D. David. SONY infrared remote protocol. Telenet, 2007. [Online]. Available:
http://users.telenet.be/davshomepage/sony.htm
[5] Drivers. Phidgets, 2010. [Online]. Available: http://www.phidgets.com/drivers.php
[6] Universal Serial Bus Specification, Rev. 3.0, 2008. [Online]. Available:
http://www.usb.org/developers/docsyeah
[7] Phalanx Close-In Weapon System, Raytheon Company, Waltham, MA, 2008.
[Online]. Available:
http://www.raytheon.com/capabilities/rtnwcm/groups/rms/documents/content/rtn_rms
_ps_phalanx_ciws_datash.pdf
27