Hallo zusammen, ich verstehe nicht, warum ModelSim mit beim Compilieren bei diesem Code den unten aufgeführten Fehler ausgibt:
1 | library IEEE; |
2 | use IEEE.STD_LOGIC_1164.ALL; |
3 | use IEEE.STD_LOGIC_ARITH.ALL; |
4 | use IEEE.STD_LOGIC_UNSIGNED.ALL; |
5 | |
6 | ---- Uncomment the following library declaration if instantiating
|
7 | ---- any Xilinx primitives in this code.
|
8 | --library UNISIM;
|
9 | --use UNISIM.VComponents.all;
|
10 | |
11 | entity FULL_ADD is |
12 | |
13 | Port ( A,B,CIN : in bit ; |
14 | SUM,COUT : out bit) ; |
15 | |
16 | end FULL_ADD; |
17 | |
18 | architecture FA of FULL_ADD is |
19 | |
20 | signal YINT1: bit_vector(2 downto 0); |
21 | signal YINT2: bit_vector(1 downto 0); |
22 | |
23 | begin
|
24 | |
25 | YINT1 <= (CIN,B,A); |
26 | |
27 | with YINT1 select |
28 | YINT2 <= "00" when "000", |
29 | "01" when "001", |
30 | "01" when "010", |
31 | "10" when "011", |
32 | "01" when "100", |
33 | "10" when "101", |
34 | "10" when "110", |
35 | "11" when "111", |
36 | |
37 | SUM <= YINT2(0); |
38 | Cout <= YINT2(1); |
39 | |
40 | end FA; |
Und hier die zugehörige Fehlermeldung:
1 | vcom -work work -2002 -explicit {C:/Users/Nico/SkyDrive/Studium/3. Semester/Digitaltechnik/ISE_Projects/DIP1/Volladdierer.vhd} |
2 | Model Technology ModelSim PE Student Edition vcom 10.1c Compiler 2012.07 Jul 28 2012 |
3 | -- Loading package STANDARD |
4 | -- Loading package TEXTIO |
5 | -- Loading package std_logic_1164 |
6 | -- Loading package std_logic_arith |
7 | -- Loading package STD_LOGIC_UNSIGNED |
8 | -- Compiling entity FULL_ADD |
9 | -- Compiling architecture FA of FULL_ADD |
10 | ** Error: C:/Users/Nico/SkyDrive/Studium/3. Semester/Digitaltechnik/ISE_Projects/DIP1/Volladdierer.vhd(46): Type error resolving infix expression "<=" as type std.STANDARD.BIT_VECTOR. |
11 | ** Error: C:/Users/Nico/SkyDrive/Studium/3. Semester/Digitaltechnik/ISE_Projects/DIP1/Volladdierer.vhd(46): Cannot read output "SUM". |
12 | ** Error: C:/Users/Nico/SkyDrive/Studium/3. Semester/Digitaltechnik/ISE_Projects/DIP1/Volladdierer.vhd(46): near ";": expecting WHEN or ',' |
13 | ** Error: C:/Users/Nico/SkyDrive/Studium/3. Semester/Digitaltechnik/ISE_Projects/DIP1/Volladdierer.vhd(49): VHDL Compiler exiting |