This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
resources:seven_seg [2019/10/23 09:09] jgoeders [Seven Segment Controller] |
resources:seven_seg [2019/10/23 09:14] (current) jgoeders [Module Description] |
||
---|---|---|---|
Line 39: | Line 39: | ||
The clock we have on the NEXYS 4 board runs at 100 MHz with a clock period of 10 ns. | The clock we have on the NEXYS 4 board runs at 100 MHz with a clock period of 10 ns. | ||
If you use an eight-bit counter to sequence the digits as described above, the top three bits would be used to sequence through each digit and the bottom five bits would be used to count the number of clock cycles to display each digit. Thus, each digit would be displayed for 2<sup>5</sup> x 10 ns = 320 ns. (The module provided below does not use an 8-bit counter, this is just described here as an example). | If you use an eight-bit counter to sequence the digits as described above, the top three bits would be used to sequence through each digit and the bottom five bits would be used to count the number of clock cycles to display each digit. Thus, each digit would be displayed for 2<sup>5</sup> x 10 ns = 320 ns. (The module provided below does not use an 8-bit counter, this is just described here as an example). | ||
+ | |||
+ | The actual module given to you does not use an 8-bit counter, but instead the counter width is parameterizable. Look at the SystemVerilog below to see the default width of the counter. | ||
Line 154: | Line 156: | ||
The controller has the following three important inputs: | The controller has the following three important inputs: | ||
- | * **Data input (32 bits):** Each digit can display 4-bits of data. With eight digits, the seven segment display can display up to 32-bits of data. You provide a 32-bit data input that indicates what data to display on all 8 of the digits. | + | * **''dataIn'' (32 bits):** Each digit can display 4-bits of data. With eight digits, the seven segment display can display up to 32-bits of data. You provide a 32-bit data input that indicates what data to display on all 8 of the digits. |
- | * **Digit Display (8 bits):** The seven segment controller does not need to turn on all eight digits of the display all of the time. In some applications, you may only want to display four of the eight digits (when there is only 16-bits of data to display). The controller can "turn off" or disable individual digits of the display by never asserting their corresponding Anode signals. This digit display input will have one bit for each digit of the display. A '1' in this bit indicates that the controller should turn on the digit, while a '0' turns off the digit. | + | * **''digitDisplay'' (8 bits):** The seven segment controller does not need to turn on all eight digits of the display all of the time. In some applications, you may only want to display four of the eight digits (when there is only 16-bits of data to display). The controller can "turn off" or disable individual digits of the display by never asserting their corresponding Anode signals. This digit display input will have one bit for each digit of the display. A '1' in this bit indicates that the controller should turn on the digit, while a '0' turns off the digit. For example, if you always want all digits to be turned on, you can connect ''8'b11111111'' to the ''digitDisplay'' port. |
- | * **Digit Point (8 bits):** There is one digit point in the bottom right corner of each digit of the seven segment display and there is a corresponding cathode signal for this digit point. This 8-bit input indicates which of the digit points of the display you are to highlight. There is one bit for each of the digits in the display. A '1' indicates that the corresponding digit point should be turned on and a '0' indicates that the corresponding digit point should be turned off. | + | * **''digitPoint'' (8 bits):** There is one digit point in the bottom right corner of each digit of the seven segment display and there is a corresponding cathode signal for this digit point. This 8-bit input indicates which of the digit points of the display you are to highlight. There is one bit for each of the digits in the display. A '1' indicates that the corresponding digit point should be turned on and a '0' indicates that the corresponding digit point should be turned off. For example, if you only want the leftmost digit point lit up, you can connect 8'b10000000 to the ''digitPoint'' port. |
Full list of ports for this module: | Full list of ports for this module: |