Forum Discussion
Ahmed_H_Intel1
Frequent Contributor
6 years agoHi,
There is no certain example of displaying a seven segment display with NIOS but it is a very simple example.
You can create an RTL code to get the value from NIOS and then translate it to 7 segment display. The NIOS can send the seven segment value to the following circuit and the value will be displayed as seven segment.
always @*
begin
case(seven_seg_val)
4'b0000: LED_out = 7'b0000001; // "0"
4'b0001: LED_out = 7'b1001111; // "1"
4'b0010: LED_out = 7'b0010010; // "2"
4'b0011: LED_out = 7'b0000110; // "3"
4'b0100: LED_out = 7'b1001100; // "4"
4'b0101: LED_out = 7'b0100100; // "5"
4'b0110: LED_out = 7'b0100000; // "6"
4'b0111: LED_out = 7'b0001111; // "7"
4'b1000: LED_out = 7'b0000000; // "8"
4'b1001: LED_out = 7'b0000100; // "9"
default: LED_out = 7'b0000001; // "0"
endcase
endanother option is to this into the C/C++ code by using switch case for example to translate the value to 7-seg
There are many examples online you can find like the following:
RPALO3
New Contributor
6 years agoHii sir,
can you send some link which could be helpful for me.
Can you send the process how to proceed . Actually first time working with nios ii. So unable to figure out.
Thank you
Ritu