http://mss6974 virtual target practice 0306-657-01 marc jabbour - [email protected] mike swanson –...

19
http://www.rit.edu/~mss6974 http://www.rit.edu/~mss6974 Virtual Target Virtual Target Practice Practice 0306-657-01 0306-657-01 Marc Jabbour - Marc Jabbour - [email protected] [email protected] Mike Swanson – Mike Swanson – [email protected] [email protected] Joe Tucci – [email protected] Joe Tucci – [email protected]

Post on 21-Dec-2015

215 views

Category:

Documents


0 download

TRANSCRIPT

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Virtual Target PracticeVirtual Target Practice0306-657-010306-657-01

Marc Jabbour - [email protected] Jabbour - [email protected] Swanson – [email protected] Swanson – [email protected]

Joe Tucci – [email protected] Tucci – [email protected]

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

OutlineOutline

OverviewOverview Operating RangeOperating Range Wireless Gun DesignWireless Gun Design Image ProcessingImage Processing User InterfaceUser Interface System ProceduresSystem Procedures BudgetBudget

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Laser pointer

Trigger mechanism

Battery

RF transmitter

camera

RF reciever

DSP

Video Game

projector

PC

PIC16F688

OverviewOverview

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

System DiagramSystem Diagram

UpdateGameProcess Image

Capture Image

Ready to shoot

Laser off

Shot firedLaser on

Wait for trigger release

Laser off

ReloadLaser off

Trigger=1

GunOn=0

GunReload=0

Trigger=0

GunOn=1

GunReload=1

Trigger=1

Trigger=0

Trigger=1

imageCaputred=1imageProcessed=1

imageCapture=0imageProcessed=0Computer Portion

Gun Portion

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Operating RangeOperating Range

We assume that the shooter stands We assume that the shooter stands no further than 20 ft from the screen.no further than 20 ft from the screen.

The projector will be located The projector will be located approximately 5 ft from the projector approximately 5 ft from the projector screen.screen.

The primary concern with this entire The primary concern with this entire project is speed.project is speed.

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Wireless Gun DesignWireless Gun Design

Laser pointerLaser pointer– Class IIIa laser (<5mW)Class IIIa laser (<5mW)

Wireless TransmitterWireless Transmitter– Operates at 433.92MHz rangeOperates at 433.92MHz range– 8kbps using 10mW8kbps using 10mW

Wireless ReceiverWireless Receiver– Baud rates 1200, 2400, and 9600Baud rates 1200, 2400, and 9600

‘A’

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

PIC16F688 Micro-controllerPIC16F688 Micro-controller

256 Bytes of EEPROM256 Bytes of EEPROM 256 Bytes of RAM256 Bytes of RAM Clock speed: 31kHz to 8MHzClock speed: 31kHz to 8MHz EUSART which handles EUSART which handles

communication to a serial portcommunication to a serial port Dimensions: 9mm by 20mmDimensions: 9mm by 20mm

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Image ProcessingImage Processing

Philips Philips CCD PC Camera Pixel PlusCCD PC Camera Pixel Plus– Captures video at 640x480Captures video at 640x480– 90 fps90 fps

Captures image from the projector Captures image from the projector screen when trigger is pressedscreen when trigger is pressed

Using Microsoft Visual Studio and Using Microsoft Visual Studio and Intel Open Source Computer VisionIntel Open Source Computer Vision

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Image ProcessingImage Processing

Image of laser point Image of laser point displays white center displays white center when capturedwhen captured

Current algorithm looks Current algorithm looks for red edgesfor red edges

Potential also exists to Potential also exists to look for the white center look for the white center of the laserof the laser

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Image ProcessingImage Processing

Image analyzed as three-dimensional Image analyzed as three-dimensional array of integersarray of integers– [Row][Column][Value][Row][Column][Value]– Value contains {alpha, red, green, blue}Value contains {alpha, red, green, blue}

Use these values to determine colorUse these values to determine color– For example, those four values over 200 For example, those four values over 200

represents a light colorrepresents a light color

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

User InterfaceUser Interface

The system consists of two user The system consists of two user interfacesinterfaces– The wireless gun will have a trigger The wireless gun will have a trigger

which the user can pull to shootwhich the user can pull to shoot– The screen will consist of a game The screen will consist of a game

designed to work entirely with the gundesigned to work entirely with the gun

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

User Interface (Wireless Gun)User Interface (Wireless Gun)

The gun has a single trigger to fire a The gun has a single trigger to fire a shot.shot.

The user just needs to aim the gun at The user just needs to aim the gun at the screen before taking a shot.the screen before taking a shot.

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

User Interface (Game)User Interface (Game)

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

User Interface (Game)User Interface (Game)

Written in C++ using the Microsoft Written in C++ using the Microsoft Direct X 9.0 SDKDirect X 9.0 SDK

Designed to run on a Windows XP Designed to run on a Windows XP Computer capable of DirectX 9.0 Computer capable of DirectX 9.0 graphicsgraphics

Features several flying targets, Features several flying targets, varying in size, shape, and colorvarying in size, shape, and color

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

System Initialization- System Initialization- Crash/Recovery ProcedureCrash/Recovery Procedure

If the gun fails to communicate with If the gun fails to communicate with the computer, the gun can be the computer, the gun can be restarted.restarted.

The computer game can be shut The computer game can be shut down using the mouse if the gun is down using the mouse if the gun is unavailable.unavailable.

If the game fails, it can be restarted If the game fails, it can be restarted without any other user intervention.without any other user intervention.

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

System IntegrationSystem Integration

This project was designed to have This project was designed to have three distinct elementsthree distinct elements

Any combination of two elements in Any combination of two elements in the system can be integrated before the system can be integrated before the third.the third.– This allows for early integration, if one This allows for early integration, if one

element is taking longer to completeelement is taking longer to complete We will be testing the entire project We will be testing the entire project

incrementallyincrementally

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

BudgetBudget

Batteries For Gun:Batteries For Gun: ~ $30~ $30 Plastic Gun:Plastic Gun: ~ $15~ $15 Webcam:Webcam: $84.36$84.36 RF Data Link with Serial OutputRF Data Link with Serial Output $44.99$44.99 RF Data Link TransmitterRF Data Link Transmitter $14.99$14.99 3 PIC16F688 chips3 PIC16F688 chips $3.07$3.07 PIC 2 Start KitPIC 2 Start Kit $49.99$49.99

APPROX TOTAL:APPROX TOTAL: $242.40$242.40

Laser Pointer, Computer, Projector, Projector Laser Pointer, Computer, Projector, Projector Screen will all be provided by group membersScreen will all be provided by group members

http://www.rit.edu/~mss6974http://www.rit.edu/~mss6974

Any Questions?Any Questions?