This project involve coding in verilog. make sure to be familiar with the language before bidding.
esign and implement a simple game on NEXYS 4 DDR FPGA boards. The Boards include eight 7-segments, 16 Switches, 16 Leds, and (5+2) push buttons as below. (CPU RESET and PROG are also push buttons)
Description: In this game you play the role of a police to arrest a thief. Police’s and the thief’s locations are shown with (XP,YP) and (Xt,Yt) coordinates, where all indexes are in range of [0,15] (inclusive).
First you need to initialize the coordinate of police and thief. The thief’s location should be entered via the 8 switches (SW[15:8]) and police’s location is entered by other 8 switches (SW[7:0]).
==> Yt==> XP==> YP
After you set the switches to the desired locations, the locations of police and thief should be shown in the 7-segments as below. The seven segment #7 shows the X index of the thief’s location and 7-segments #6 shows his Y location. The 7-segments #5 and #4 show the police location (Xp,Yp), respectively. All these four 7-segments should show the location in hexadecimal format. For example, if the location of thief and police are (14,9), and (3,10), respectively the number that each 7-segment should show are:
7-segnent #7 ==> E
7-segnent #6 ==> 9
7-segnent #5 ==> 3
7-segnent #4 ==> A
The game starts by pushing reset button (BTNC). The locations should be loaded in appropriate registers in your design after BTNC is pushed. Now you can move the police by pushing BTNU (move up), BTND (move down), BTNR (move right), and BTNL (move left). Each push moves the police one location in the related direction.
The number of steps (moves) the police takes should be counted. To do so, there should be a counter in your design that whenever you push one of the BTNU, BTND, BTNR, and BTNL it counts up by 1. This value of this counter should be shown in 7-segment #1 and #0 (in Fig. 2) in decimal format. For example, if the move buttons have been hit for 15 times totally, the 7-segments should be turned on like this:
o 7-segnent #1 ==> 1o 7-segnent #0 ==> 5
Not that the thief’s location is constant, but the police’s location should be updated whenever each move happens, and so the related seven-segments needs to be updated accordingly. In fact, the thief location doesn’t change but the police location and the number of moves (number of pushed buttons counter) should be updated dynamically and their 7- segment should show the current status.
In each move, the police can go 1 location to left, right, bottom or up using the push buttons. If Police reaches to the thief location, then game is over. However, you need to follow the following rules:
o The aim is that the police arrest the thief using shortest path or near shortest paths, i..e, if shortest path needs N moves (N times pressing push buttons) for police, then if police reaches to the thief location with at most N+5 push, the police wins and all the LES are blinking with 1Hz frequency.
o If the police reaches to the thief’s location with more than N+5 pushes (where N is the shortest path between them), the game is over but with a fail so all LEDs should show turn off.
o If police has not reached to the thief’s location yet but the path so far he moved is more than N+5 then again he fails and all LEDs should turn off.
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.Read more
Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.Read more
Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.Read more
Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.Read more
By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.Read more