Listing 1 for DI#2281: library ieee; use ieee.std_logic_1164.all; use ieee.std_logic_unsigned.all; use std.textio.all; ----------------------------------------- entity READ_FILE is end READ_FILE; ----------------------------------------- architecture JB of READ_FILE is signal READ_FILE_ENDED : std_logic := '0'; signal FILENAME : string(1 to 80) := (others => ' '); signal FILENAME_LEN : integer; signal SINT : integer; signal READ_NEW_INT : std_logic := '0'; begin --------------------------- MAIN: process file Fname : text is in "name.cmd"; --script file variable VLINE : line; variable VSTR : string(1 to 80) := (others => ' '); variable VSUM : integer := 0; begin readline(Fname, VLINE); FILENAME_LEN <= VLINE'length; read(VLINE, VSTR(1 to VLINE'length)); FILENAME <= VSTR; --filename to process while (READ_FILE_ENDED /= '1') loop READ_NEW_INT <= not READ_NEW_INT; --get new read wait for 10 ns; --set the read cycle time VSUM := VSUM + SINT; --sum numbers read as an example end loop; wait; end process MAIN; end JB; ------------------------ -- configuration ------------------------ configuration CFG_READ_FILE of READ_FILE is for JB end for; end CFG_READ_FILE;