VHDL“流程”:流程使用不正确?

时间:2017-08-25 00:41:00

标签: vhdl quartus

我是VHDL和Quartus设计环境的新手,我正在尝试运行一些textio的模拟,但我必须遗漏一些东西......当我编译下面的代码时(我借用了一些代码片段) OSU VHDL文本指南(http://web.engr.oregonstate.edu/~traylor/ece474/vhdl_lectures/text_io.pdf),我收到错误10533:

  

错误(10533):tio_top.vhd上的VHDL Wait语句错误(36):Wait语句必须包含带有UNTIL关键字的条件子句

在这种情况下适合使用哪种条件?我已经尝试创建一个评估为常量true或false的条件,但这也会产生错误。 也许我对进程的理解是错误的,它需要持续运行? 基本上我只想将变量a输出到文本文件......我是否需要创建一个测试平台?

library ieee;
library std;
use ieee.std_logic_1164.all;
use ieee.std_logic_signed.all;
use ieee.std_logic_unsigned.all;
use ieee.math_real.all;
use ieee.math_complex.all;
use ieee.std_logic_textio.all;
use std.textio.all;

entity tio_top is
end tio_top;

architecture main of tio_top is
begin
-----------------------------------------------------------------------------
  --practice with textio
  file_io: --declare a process for executing file input/output
  process is
    file out_file : text open read_mode is "out_values"; --declare output file name
    variable out_line : line; --declare variable of type line to store values
    variable a : std_logic; --declare other logic varialbes for playing around with     
  begin --put the meet of the textio here

    a := '1';

    write(out_line,a);
    writeline(out_file, out_line);

    wait; --allows simulation to halt!

  end process;

end main;

0 个答案:

没有答案