lecture verilog ii_c
TRANSCRIPT
![Page 1: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/1.jpg)
ECE 287 – Lecture Verilog II
Verilog HDL with Sequential Circuits
![Page 2: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/2.jpg)
Announcements
Next WednesdayExam II – Nov 15th
Last Day to Demo Labs – Nov 14th
Project Oral Proposal - Nov 1st
![Page 3: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/3.jpg)
![Page 4: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/4.jpg)
![Page 5: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/5.jpg)
What you should know how to use in Verilog•The Golden Rule I•Combinational always blocks• If, Case
•Modules instantiated in other modules•? Operator•Groupings•Constants•Conditionals•Logic Operators
If you don’t talk to me…
![Page 6: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/6.jpg)
Sequential Circuits … example
What’s different?
![Page 7: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/7.jpg)
Second Golden Rule!!!• Use “=“ in combinational always blocks
• Use “<=“ in sequential always blocks
![Page 8: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/8.jpg)
Circuit Reset This is how you’ll write most sequential circuits…
Include a reset !!!
![Page 9: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/9.jpg)
Use fully defined if and case structures…
For the following example, what is the value of c?
![Page 10: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/10.jpg)
Parameter
![Page 11: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/11.jpg)
Problem…
Build a circuit that has 2, 8 bit multipliers and 1 32 bit multiplier and stores the result in flip-flops. It needs a reset and clock.
![Page 12: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/12.jpg)
Problem as a group…
Build the ram from last class…
![Page 13: Lecture verilog ii_c](https://reader030.vdocuments.net/reader030/viewer/2022032502/55ba3b83bb61eb9b188b464a/html5/thumbnails/13.jpg)
Problem Set
1. Build Verilog code for a counter that counts from 0 to 259 and then starts over.
2. Build Verilog code that multiplies by 5.