That does not match in width:
1 | e : in std_logic_vector ;
|
2 |
|
3 | data_in_WCDMA : in std_logic_vector (24 downto 0);
|
And you cannot assign a unconstrained vector (e) to some other vectors
with different widths.
As it it not necessary to multiplex the inputs (just think about that
for half an hour), you must only have an eye on the outputs.
Finally you must input a vector at least the size of the broadest module
vector (here this is 42 bits) and you must select the interesting
result to the output.
1 | LIBRARY ieee ;
|
2 | USE ieee.std_logic_1164.all ;
|
3 | USE ieee.std_logic_arith.all ;
|
4 | ENTITY comp_sc IS
|
5 | port ( e : in std_logic_vector (41 downto 0);
|
6 | Sel : in std_logic_vector (2 downto 0);
|
7 | s : out std_logic_vector (41 downto 0)
|
8 | );
|
9 | END ;
|
10 | ARCHITECTURE arch_comp_sc OF comp_sc IS
|
11 | :
|
12 | :
|
13 | SIGNAL data_in_GPRS : std_logic_vector (6 downto 0); -- the smallest
|
14 | SIGNAL data_out_GPRS : std_logic_vector (6 downto 0);
|
15 | :
|
16 | :
|
17 | SIGNAL data_in_CDMA2000 : std_logic_vector (41 downto 0); -- the broadest
|
18 | SIGNAL data_out_CDMA2000 : std_logic_vector (41 downto 0);
|
19 | :
|
20 | :
|
21 | BEGIN
|
22 | data_in_CDMA2000 <= e;
|
23 | data_in_GPRS <= e(6 downto 0);
|
24 | :
|
25 | :
|
26 | process (data_out_GPR, data_out_CDMA2000, Sel) is
|
27 | begin
|
28 | s <= (others => '0'); -- assign a default value to unused output bits
|
29 | case Sel is
|
30 | when "000" => s <= data_out_CDMA2000;
|
31 | when "001" => s <= data_out_GPRS;
|
32 | when "010" => ...
|
33 | when "011" => ...
|
34 | :
|
35 | end case;
|
36 | end process;
|
37 | :
|
BTW: you did some simple&stupid copy&paste work without thinking. How
much clocks do you have? Ho much resets and enables? Where do the come
from?