liuliuqiu051 发表于 2012-12-18 16:17

小白求解 MAX PLUS 2运行提示错误。。

library ieee;
use ieee.std_logic_1164.all;
entity lq123 is
port(
   a   : ininteger range 0 to 15;
   din : instd_logic_vector(7 downto 0);
   dout: out std_logic_vector(7 downto 0);
          clk,cs,we,ce:in std_logic    );
end entity lq123;
architecture one of lq123 is
type ram_type is array (0 to 15)of std_logic_vector(7 downto 0);
begin
    process(clk,a,din,cs,we,ce)is
      variable mem:ram_type;
begin
if clk'event and clk ='1'then
      dout <=(others => 'Z');
    if cs ='0'then
      if ce='0'then
      dout <= mem(a);
      elsif we='0'then
      mem(a):=din;
      end if;
    end if;
end if ;
end process;
end one;

liuliuqiu051 发表于 2012-12-20 08:21

自己顶起来

zbhbyc 发表于 2012-12-20 09:32

maxplus II 的孙子Quqrtus II 都到12.0。a的定义问题
页: [1]
查看完整版本: 小白求解 MAX PLUS 2运行提示错误。。