Z
ZHIQUAN
Guest
type B_Matrix is array (0 to 3) of std_logic_vector(15 downto 0);
signal MatrixB : B_Matrix :=(others =>(others=>'0'));
For example MatrixB has some values {"1000001010101010",
"1000001010111010",..........}
Now I want to get the first bit of MatrixB(2) to give variable ad like
that: ad := MatrixB(2, 15); It doesn't work. Sounds like I use the
wrong grammar. Does anybody know how to do that.
One more thing, Can I do the operation like :
d2Rkk is signed(17 downto 0):= (others=>'0');
d2Rkk (12 downto 0) :=signed(MatrixR(2, 15 downto 3));
It looks like if the variable is an array type, the element of the
array cannot do the normal operation as if they are independent ones. I
mean if MatrixR is std_logic_vector (15 downto 3), I can just do d2Rkk
(12 downto 0) :=signed(MatrixR( 15 downto 3)); Where I can find some
examples for array operations ? Thanks.
signal MatrixB : B_Matrix :=(others =>(others=>'0'));
For example MatrixB has some values {"1000001010101010",
"1000001010111010",..........}
Now I want to get the first bit of MatrixB(2) to give variable ad like
that: ad := MatrixB(2, 15); It doesn't work. Sounds like I use the
wrong grammar. Does anybody know how to do that.
One more thing, Can I do the operation like :
d2Rkk is signed(17 downto 0):= (others=>'0');
d2Rkk (12 downto 0) :=signed(MatrixR(2, 15 downto 3));
It looks like if the variable is an array type, the element of the
array cannot do the normal operation as if they are independent ones. I
mean if MatrixR is std_logic_vector (15 downto 3), I can just do d2Rkk
(12 downto 0) :=signed(MatrixR( 15 downto 3)); Where I can find some
examples for array operations ? Thanks.