DCPPTSS CDR

advertisement
DCPPTSS CDR
Group 6
Christian "The Muscle" Braun (CpE)
Rashon "The Wildcard" Hogan (EE)
Jelani "The Brains" Jackson (CpE)
Donald "The Looks" Thomson (CpE)
The DCPPTSS
The Digital Competitive Precision Projectile Table Support
Structure is an embedded system designed to function as an
aid for the widely popular recreational beer drinking activity
known as
BEER PONG
Motivation
Beer pong is like bowling, a precision game which incorporates
alcohol. If bowling can be automated, why not beer pong?
● Game rules vary from location to location
● Keeping track of who plays next always causes problems
● Most inebriated people stop caring about hygiene
● Have fun during senior design
● Gain experience with embedded systems and peripheral
communication.
Project Goals
● Demonstrate concepts needed for an electronic beer pong
table
● User friendly
● Simple design
● Keep game score
● Detect presence of cups
● Detect made from missed shots
● Provide a reliable beer pong table
● Provide a ball sanitation system
● Use only generic equipment
○ i.e. special balls/cups
Specifications
● Table Dimensions: 8'L x 2'W x 36"H
● Run on mains power (120v @ 60Hz)
● Be able to play 10+ consecutive games
● Distinguish between 12 different cups
● Display at least 6 different colors
● Creates 4+ distinguishable animations
● Demonstrate Communication between 2 different
transmitting modules
Block Diagram
Table Layout
Table Structure
Cup Sensors
● Two cup sensor arrays
○ One for each side of
the table
● Each array consists of 6
sensors
○ One sensor for each
cup
● Each sensor consists of:
○ 1 TI Capacitive Touch
Unit
○ 5 RGB LEDs
● Each array controlled via
a MSP430G2553 MCU
MSP430G2553
Originally, was using MSP430G2452
● MCU came stock with TI Cap Touch Booster Pack
● Only a single Timer_A module
● PITA with so much IO
○ TAR
Chose the MSP430G2553
● Needed at least two Timer_A modules
● Needed Capacitive Touch capability
● TI E2E community
● Giant crap shoot choosing between parts matching the
specs
Presence of Liquid
Basic Idea
● Capacitive Touch Sensor
● Presence of liquid displaces air
○ Changes the permitivity of space above sensor
○ Changes RC time constant
Material
Dielectric
Constant
Vacuum
1
Air
1.00059
Plexiglas 3.40
Water
80.4
Presence of Liquid
Methods of Detection
● Relaxed Oscillator (RO)
○ Counts charge/discharge
cycles
● RC Time Constant (RC)
○ Measures rise/fall time
Driving the LEDs
Multiple Options
1. Drive each LED with a single pin of a MCU
2. Multiplex/Charlieplex the LEDs
3. Drive each LED with a proprietary LED Driver
Driving with MCU
● Would require MCU with > 90 pins (3pins x 5LEDs x 6units)
for each side
● Would require a transistor as pin Imax = +/- 2mA
Multi/Charlieplexing
● To drive all LEDs, must refresh faster than the "flicker
threshold"
● Average current can reach above LED specifications
Driving the LEDs
Chose to use the TI TLC5940NT LED driver
● Dot Correction
○ Current control
○ Imax set by single external resistor for all 16 channels
○ 64 divisions 0 to Imax
● Grayscale
○ On/off control
● Serial communication
○ 2 pins from MSP for data for 30 RGB LEDs
● Total of 7 pins used from MSP for LEDs
Light Barriers
Problem
● Ping Pong balls are not detected by capacitive sensors
● Wanted to use standard beer pong equipment
Multiple Designs
● Single Sided
○ Detects reflection
● Dual Sided
○ Detects beam break
● Discretizing
○ Laser Array above cups
○ Detect beam break
Single Sided
● Detect reflection
● Emitters and Detectors in same plane
● AC vs DC source
● Problems
○ Balls diffuse light
○ Light reflected at angle different from angle of incidence
○ Ceiling height
Dual Sided
● Detect beam break
● Emitters and detectors
opposite
Problems
● Rails create
obstructions to game
play
Discretizing Laser Array
● 650nm wavelength
● 5mW @ 3.3V
● Adjustable columnating lens.
● Detect beam break
● Discretize the area above the cups
● Creates coordinate grid
LED Table Animation
● Consist of 1 micro-controller communicating using I2C to
MSP430G2553 main processor
● 5 output pins will control diodes through decoders
● Decoders will output to base nodes of BJTs driving LEDs.
LED Table Animation
Sanitation
Implemented for eradicating pathogens, germs, viruses in water
circulation system to minimize transfer of sickness.
Means Chosen: Ultra Violet - destroys Nucleic Acids; extremely
effective, minimal maintenance required.
Sterilization
● 120VAC 60Hz Power Input
● Pump rated for 180 Gallons per
hour
● Connected via Vinyl Tubing for
flexible routing
● 245nm UV Sterilizer rated for 180
gallon total volume & 1800Gph
● 99% Effective
● Better performance versus
pasteurization or chemical dosing.
● Pasteurization has dangerous
amounts of heat.
● Chemical Dosing presents a
potential health hazards as
well as added weight for chemicals
and high maintenance.
User Interface
● Handle up to 4 different functions that the table is unable to
handle automatically
○ MISS
○ FORFEIT
○ SKIP TURN
○ RERACK
● Display 3 pieces of information for the current game
○ Team Number
○ Cups Left (on current side)
○ Reracks Left
● Handle queue tracking of 10+ different teams
User Interface - Components
● Information Display
○ One module for both teams
● User Input
○ Buttons
■ Arcade-style - big, easy to use
○ 1 Button per Function vs. Menu Navigation
■ Menu navigation - cheap, more coding
■ 1 button per function - easier to implement in code,
requires more table space, pricier
● Team Tracking
○ Winning team stays on to play
○ Losing team number incremented to next-up team
User Interface - Components
● NHD-0216K3Z-FL-GBW - 16x2 Character LCD
○ Backlit - usable in low-light environments
○ Support for RS232, SPI, I2C
○ 64.5mm x 16.4mm - unobtrusive
● OBSF-30
○ Chosen using different criteria
○ Price and availability most important
User Interface - Layout
● Constructed as a single module
○ Mounted to side of the table
■ One MSP430G2553
■ Three Arcade-style buttons
■ One 16x2 character LCD
User Interface - Block Diagram
User Interface - Schematic
User Interface - Menu Flow
Central Control Options
Central Control
Options
Stellaris EKSLM3S8962
Communication UART, SSI, I2C
Options
ATMEL
AT91SAM
OKI ML674000
UART, SSC,
SPI
UART
Programming
Language
C
C
C
Price
FREE
$79.00
$89.00
Central Control - Choice
MSP430G2553 microcontroller
● Uses I2C - which is used to communicate with external
systems
● Complications with the Stellaris EKS-LM3S8962
● The complication of programming the Stellaris
● Inexpensive
Central Control - Requirements
● Communicate with external systems
○ Descretized laser subsystem
■ determines if ball was thrown
■ determines if ball was made/missed
○ Capacitive touch system
■ determines which cup the ball was thrown in
○ User Interface
○ LED pattern
● Maintain score count, player turn, cups remaining, and
throws per turn
Central Control - Functions
● void LEDpattern(char) - Starts LED pattern about player
areas
● void playerInitialization() - Initializes player members
● void selectedPlayer(int) - Selects which player goes first
● int isBallDetected() - Was the ball detected
● int isBallMade() - Was the ball made
● struct Player currentTurn() - Returns whose turn it is
Central Control - Functions
● void decrementThrows() - Decrement throws for turn
● void decrementCups() - Decrement cups remaining
● void cupsPerPlayer() - Shows cups per player
● void changeTurn() - Change turn of player
● void isWinner() - Check to see if there's a winner
User Interface - Functions
● void initUI(int playerNum, int teamNum) - initializes UI to
default state
● int getTeamNum(int playerNum) - gets team number from
team queue
● void setNextTeam() - set next team number in queue
● void miss(int playerNum) - set last throw as MISS
● void rerack(int playerNum) - perform RERACK
● void skipTurn(int playerNum) - SKIP TURN/MULLIGAN
User Interface - Functions
● void forfeit(int playerNum) - end game with loss
● struct Button buttonPressed() - returns which button is
pressed for navigation
Power
● Antec Basic Series ATX Computer Supply
● 350 Watt
● Reliable, Clean electricity, Multiple levels of power.
● 12, -12, 3.3, 5v available.
● No testing required
● Equipped with over current protection.
Work Distribution
Budget and Financing
Total Budget: $800
Self-funded: $200 per person
Challenges Overcome
● Procuring TI Cap Touch Units (Classmates)
● IR Barrier (Laser Grid)
● Laser Alignment (SteelStik & Cottonballs)
● I2C Communication (self condemnation)
● Brown Out from TLC surge (capacitor)
● User Error (testing)
● Equipment Failure (revise code)
Thank You!
Questions?
Download