summaryrefslogtreecommitdiffstats
path: root/hexled.v
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2003-09-09 07:34:29 +0000
committerH. Peter Anvin <hpa@zytor.com>2003-09-09 07:34:29 +0000
commit2d7483b97fc6d4542fda957f24c7f4cb0d849ba7 (patch)
treea30a00406749010e05cc10b116806e7ba6adc5f1 /hexled.v
parenta579b98814f0bd4eb7cc11915d3f48d8e67f36c3 (diff)
downloadkeyboard-2d7483b97fc6d4542fda957f24c7f4cb0d849ba7.tar.gz
keyboard-2d7483b97fc6d4542fda957f24c7f4cb0d849ba7.tar.xz
keyboard-2d7483b97fc6d4542fda957f24c7f4cb0d849ba7.zip
Fungerar i stort sett; tabeller kan behöva justeras
Diffstat (limited to 'hexled.v')
-rw-r--r--hexled.v34
1 files changed, 17 insertions, 17 deletions
diff --git a/hexled.v b/hexled.v
index 64a6081..f7e32ef 100644
--- a/hexled.v
+++ b/hexled.v
@@ -4,27 +4,27 @@ module hexled (
);
input [3:0] value;
- output [7:0] s7;
+ output [6:0] s7;
always @( value )
begin
case ( value )
- 4'h0: s7 = ~8'b00111111;
- 4'h1: s7 = ~8'b00000110;
- 4'h2: s7 = ~8'b01011011;
- 4'h3: s7 = ~8'b01001111;
- 4'h4: s7 = ~8'b01100110;
- 4'h5: s7 = ~8'b01101101;
- 4'h6: s7 = ~8'b01111101;
- 4'h7: s7 = ~8'b00000111;
- 4'h8: s7 = ~8'b01111111;
- 4'h9: s7 = ~8'b01101111;
- 4'hA: s7 = ~8'b01110111;
- 4'hB: s7 = ~8'b01111100;
- 4'hC: s7 = ~8'b00111001;
- 4'hD: s7 = ~8'b01011110;
- 4'hE: s7 = ~8'b01111001;
- 4'hF: s7 = ~8'b01110001;
+ 4'h0: s7 = ~7'b0111111;
+ 4'h1: s7 = ~7'b0000110;
+ 4'h2: s7 = ~7'b1011011;
+ 4'h3: s7 = ~7'b1001111;
+ 4'h4: s7 = ~7'b1100110;
+ 4'h5: s7 = ~7'b1101101;
+ 4'h6: s7 = ~7'b1111101;
+ 4'h7: s7 = ~7'b0000111;
+ 4'h8: s7 = ~7'b1111111;
+ 4'h9: s7 = ~7'b1101111;
+ 4'hA: s7 = ~7'b1110111;
+ 4'hB: s7 = ~7'b1111100;
+ 4'hC: s7 = ~7'b0111001;
+ 4'hD: s7 = ~7'b1011110;
+ 4'hE: s7 = ~7'b1111001;
+ 4'hF: s7 = ~7'b1110001;
endcase
end
endmodule // hexled