Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player...
Transcript of Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player...
![Page 1: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/1.jpg)
ROCK, PAPER, SCISSORS!Justin Thomson, Rachel Pilarowski, Marwan Oro
![Page 2: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/2.jpg)
RULES
• First player to 3 wins
• 3-2-1 “shoot”
![Page 3: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/3.jpg)
BLOCK DIAGRAM
![Page 4: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/4.jpg)
COMPARATOR
• 6 switches – 3 for each player
• Determines which player won
• Determines “Invalid” input or “Tie”
• Outputs what each player chose
• “r” = rock
• “P” = paper
• “S” = Scissors
• Only processes on “shoot”
• Shoot comes from counter
![Page 5: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/5.jpg)
FSM
• 11 states
• Represent the scores of each player
• Changes state based on which player won the round
• Keeps track of the scores
• Outputs to the multiplexing display
![Page 6: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/6.jpg)
STATE MACHINE
![Page 7: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/7.jpg)
COUNTER
• The main driver of the project
• Controls:
• When to compare two players’ moves
• Controls state changes
• Counts the amount of time to trigger certain processes
![Page 8: Rock, Paper, Scissors! - Oakland UniversityFSM •11 states •Represent the scores of each player •Changes state based on which player won the round •Keeps track of the scores](https://reader033.fdocuments.net/reader033/viewer/2022041711/5e47fcfebd8e0340974b8a1d/html5/thumbnails/8.jpg)
MULTIPLEXING DISPLAY
• Used to determine when individual segments are displayed
• Also determines what is displayed when enabled
• Allows for the user to receive feedback based on the state of the game