- uses ieee_proposed.fixed_pkg
git-svn-id: http://moon:8086/svn/vhdl/trunk@171 cc03376c-175c-47c8-b038-4cd826a8556b
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
|
vmap ieee_proposed ../../../../Common/sim/ieee_proposed
|
||||||
|
|
||||||
vlib work
|
vlib work
|
||||||
vcom -explicit -93 "../../../fixed/fixed_pkg_c.vhd"
|
|
||||||
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
|
vmap ieee_proposed ../../../../Common/sim/ieee_proposed
|
||||||
|
|
||||||
vlib work
|
vlib work
|
||||||
vcom -explicit -93 "../../../fixed/fixed_pkg_c.vhd"
|
|
||||||
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
|
vmap ieee_proposed ../../../../Common/sim/ieee_proposed
|
||||||
|
|
||||||
vlib work
|
vlib work
|
||||||
vcom -explicit -93 "../../../fixed/fixed_pkg_c.vhd"
|
|
||||||
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
vcom -explicit -93 "../../../fixed/fixed_util_pkg.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993.vhd"
|
||||||
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
vcom -explicit -93 "../../../PCK_FIO-2002.7/PCK_FIO_1993_BODY.vhd"
|
||||||
|
|||||||
@@ -21,7 +21,12 @@ library IEEE;
|
|||||||
use IEEE.STD_LOGIC_1164.ALL;
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
use IEEE.MATH_REAL.ALL;
|
use IEEE.MATH_REAL.ALL;
|
||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
|
library work;
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.nco_pkg.all;
|
use work.nco_pkg.all;
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,12 @@ library IEEE;
|
|||||||
use IEEE.STD_LOGIC_1164.ALL;
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
use IEEE.MATH_REAL.ALL;
|
use IEEE.MATH_REAL.ALL;
|
||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
|
library work;
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.nco_pkg.all;
|
use work.nco_pkg.all;
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,12 @@ library IEEE;
|
|||||||
use IEEE.STD_LOGIC_1164.ALL;
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
use ieee.numeric_std.all;
|
use ieee.numeric_std.all;
|
||||||
use IEEE.MATH_REAL.ALL;
|
use IEEE.MATH_REAL.ALL;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
|
library work;
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -17,8 +17,11 @@ use IEEE.MATH_REAL.ALL;
|
|||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use std.textio.all; -- Imports the standard textio package.
|
use std.textio.all; -- Imports the standard textio package.
|
||||||
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
library work;
|
library work;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.cordic_pkg.all;
|
use work.cordic_pkg.all;
|
||||||
use work.PCK_FIO.all;
|
use work.PCK_FIO.all;
|
||||||
|
|||||||
@@ -17,8 +17,11 @@ use IEEE.MATH_REAL.ALL;
|
|||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use std.textio.all; -- Imports the standard textio package.
|
use std.textio.all; -- Imports the standard textio package.
|
||||||
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
library work;
|
library work;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.PCK_FIO.all;
|
use work.PCK_FIO.all;
|
||||||
|
|
||||||
|
|||||||
@@ -17,8 +17,11 @@ use IEEE.MATH_REAL.ALL;
|
|||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use std.textio.all; -- Imports the standard textio package.
|
use std.textio.all; -- Imports the standard textio package.
|
||||||
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
library work;
|
library work;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.nco_pkg.all;
|
use work.nco_pkg.all;
|
||||||
use work.PCK_FIO.all;
|
use work.PCK_FIO.all;
|
||||||
|
|||||||
@@ -21,7 +21,12 @@ library IEEE;
|
|||||||
use IEEE.STD_LOGIC_1164.ALL;
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
use IEEE.MATH_REAL.ALL;
|
use IEEE.MATH_REAL.ALL;
|
||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
|
library work;
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.nco_pkg.all;
|
use work.nco_pkg.all;
|
||||||
|
|
||||||
@@ -188,7 +193,7 @@ proc_out_i: process(clk, wave_i, inv_i, zero_i)
|
|||||||
if z = '0' then
|
if z = '0' then
|
||||||
w := wave_i;
|
w := wave_i;
|
||||||
if inv = '1' then
|
if inv = '1' then
|
||||||
w := resize(-wave_i, w, fixed_truncate, fixed_wrap);
|
w := resize(-wave_i, w, fixed_wrap, fixed_truncate);
|
||||||
end if;
|
end if;
|
||||||
end if;
|
end if;
|
||||||
|
|
||||||
@@ -217,7 +222,7 @@ proc_out_q: process(clk, wave_q, inv_q, zero_q)
|
|||||||
if z = '0' then
|
if z = '0' then
|
||||||
w := wave_q;
|
w := wave_q;
|
||||||
if inv = '1' then
|
if inv = '1' then
|
||||||
w := resize(-wave_q, w, fixed_truncate, fixed_wrap);
|
w := resize(-wave_q, w, fixed_wrap, fixed_truncate);
|
||||||
end if;
|
end if;
|
||||||
end if;
|
end if;
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,12 @@ library IEEE;
|
|||||||
use IEEE.STD_LOGIC_1164.ALL;
|
use IEEE.STD_LOGIC_1164.ALL;
|
||||||
use IEEE.MATH_REAL.ALL;
|
use IEEE.MATH_REAL.ALL;
|
||||||
USE ieee.numeric_std.ALL;
|
USE ieee.numeric_std.ALL;
|
||||||
use work.fixed_pkg.all;
|
|
||||||
|
library ieee_proposed;
|
||||||
|
use ieee_proposed.math_utility_pkg.all;
|
||||||
|
use ieee_proposed.fixed_pkg.all;
|
||||||
|
|
||||||
|
library work;
|
||||||
use work.fixed_util_pkg.all;
|
use work.fixed_util_pkg.all;
|
||||||
use work.nco_pkg.all;
|
use work.nco_pkg.all;
|
||||||
|
|
||||||
@@ -60,7 +65,7 @@ function to_wave_mem(wave_real : real_array_t; len : integer; proto : sfixed) re
|
|||||||
variable res : wave_mem_t;
|
variable res : wave_mem_t;
|
||||||
begin
|
begin
|
||||||
for i in 0 to len-1 loop
|
for i in 0 to len-1 loop
|
||||||
res(i) := to_sfixed(wave_real(i), proto, fixed_round, fixed_saturate);
|
res(i) := to_sfixed(wave_real(i), proto, fixed_saturate, fixed_round);
|
||||||
end loop;
|
end loop;
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
|
|||||||
Reference in New Issue
Block a user