Line 16... |
Line 16... |
--!TBXEND
|
--!TBXEND
|
--!TBXSTART:ADD_BUS
|
--!TBXSTART:ADD_BUS
|
signal sadd : std_logic_vector(12 downto 0);
|
signal sadd : std_logic_vector(12 downto 0);
|
--!TBXEND
|
--!TBXEND
|
--!TBXSTART:DATA_BUS
|
--!TBXSTART:DATA_BUS
|
signal sd,sq : std_logic_vector(31 downto 0);
|
signal sd,sq : xfloat32;
|
--!TBXEND
|
--!TBXEND
|
--!TBXSTART:INT_BUS
|
--!TXBXSTART:INT_BUS
|
signal sint : std_logic_vector(7 downto 0);
|
signal sint : std_logic_vector(7 downto 0);
|
--!TBXEND
|
--!TBXEND
|
|
|
begin
|
begin
|
|
|
Line 31... |
Line 31... |
srst <= not(rstMasterValue);
|
srst <= not(rstMasterValue);
|
wait for 1 ns;
|
wait for 1 ns;
|
srst <= rstMasterValue;
|
srst <= rstMasterValue;
|
wait for 52 ns;
|
wait for 52 ns;
|
srst <= not(rstMasterValue);
|
srst <= not(rstMasterValue);
|
|
wait;
|
end process reset_p;
|
end process reset_p;
|
|
|
|
|
clock_p : process
|
clock_p : process
|
begin
|
begin
|
Line 114... |
Line 115... |
elsif count=256*3 then
|
elsif count=256*3 then
|
--! Escribir la instrucción de normalización.
|
--! Escribir la instrucción de normalización.
|
swr <= '1';
|
swr <= '1';
|
--! La dirección por defecto para escribir en la cola de instrucciones es 0x0600
|
--! La dirección por defecto para escribir en la cola de instrucciones es 0x0600
|
-- add <= "0 0110 0000 0000";
|
-- add <= "0 0110 0000 0000";
|
sadd <= x"0600";
|
sadd <= '0'&x"600";
|
sd <= ap_format_instruction(string'("nrm"),"00000","01111","00000","00000",'0');
|
sd <= ap_format_instruction(string'("nrm"),"00000","01111","00000","00000",'0');
|
count:=count+1;
|
count:=count+1;
|
else
|
else
|
--! Parar la escritura de datos.
|
--! Parar la escritura de datos.
|
swr <= '0';
|
swr <= '0';
|
Line 137... |
Line 138... |
write(l,string'("#RAYTRAC TESTBENCH OUTPUT FILE"));
|
write(l,string'("#RAYTRAC TESTBENCH OUTPUT FILE"));
|
writeline(f,l);
|
writeline(f,l);
|
write(l,string'("#This file is automatically generated by tb_compiler script, by Julian Andres Guarin Reyes"));
|
write(l,string'("#This file is automatically generated by tb_compiler script, by Julian Andres Guarin Reyes"));
|
writeline(f,l);
|
writeline(f,l);
|
wait for 5 ns;
|
wait for 5 ns;
|
wait until srst=not(rstMasterValue);
|
--wait until srst=not(rstMasterValue);
|
wait until sclk='1';
|
wait until sclk='1';
|
wait for tclk_2+tclk_4;
|
wait for tclk_2+tclk_4;
|
|
|
|
|
--! from here on, tb_compiler writes the data to be displayed
|
--! from here on, tb_compiler writes the data to be displayed
|
--! tb_compiler: the following line MUST go here
|
--! tb_compiler: the following line MUST go here
|
|
--!TBXDISPTOPLINE
|
disp_loop:loop
|
disp_loop:loop
|
|
--! tb_compiler: the following line MUST go here
|
--!TBXDISPLAYOPERATION
|
--!TBXDISPLAYOPERATION
|
wait for tclk;
|
wait for tclk;
|
|
|
end loop;
|
end loop;
|
|
|