Skip to content
Snippets Groups Projects
Commit 5932bf78 authored by Reinier van der Walle's avatar Reinier van der Walle
Browse files

updated generics

parent ee8603a7
No related branches found
No related tags found
1 merge request!313Resolve DIST2-11
Pipeline #45755 passed
...@@ -110,8 +110,12 @@ ARCHITECTURE str OF node_sdp_oversampled_filterbank IS ...@@ -110,8 +110,12 @@ ARCHITECTURE str OF node_sdp_oversampled_filterbank IS
NATURAL'IMAGE(c_sdp_W_sub_weight_fraction) & "f_unit"; NATURAL'IMAGE(c_sdp_W_sub_weight_fraction) & "f_unit";
CONSTANT c_fft : t_fft := func_wpfb_map_wpfb_parameters_to_fft(g_wpfb); CONSTANT c_fft : t_fft := func_wpfb_map_wpfb_parameters_to_fft(g_wpfb);
CONSTANT c_fft_complex : t_fft := func_wpfb_map_wpfb_parameters_to_fft(g_wpfb_complex);
CONSTANT c_subband_raw_dat_w : NATURAL := func_fft_raw_dat_w(c_fft); CONSTANT c_subband_raw_dat_w : NATURAL := func_fft_raw_dat_w(c_fft);
CONSTANT c_subband_raw_fraction_w : NATURAL := func_fft_raw_fraction_w(c_fft); CONSTANT c_subband_raw_fraction_w : NATURAL := func_fft_raw_fraction_w(c_fft);
CONSTANT c_complex_subband_raw_dat_w : NATURAL := func_fft_raw_dat_w(c_fft_complex);
CONSTANT c_complex_subband_raw_fraction_w : NATURAL := func_fft_raw_fraction_w(c_fft_complex);
CONSTANT c_dat_w_diff : INTEGER := c_complex_subband_raw_dat_w - c_subband_raw_dat_w; -- = -1 which is used to shift 1 bit to the left.
CONSTANT c_nof_masters : POSITIVE := 2; CONSTANT c_nof_masters : POSITIVE := 2;
...@@ -191,6 +195,7 @@ ARCHITECTURE str OF node_sdp_oversampled_filterbank IS ...@@ -191,6 +195,7 @@ ARCHITECTURE str OF node_sdp_oversampled_filterbank IS
SIGNAL wpfb_complex_out_fifo_siso_arr : t_dp_siso_arr(c_sdp_S_pn-1 DOWNTO 0) := (OTHERS => c_dp_siso_rst); SIGNAL wpfb_complex_out_fifo_siso_arr : t_dp_siso_arr(c_sdp_S_pn-1 DOWNTO 0) := (OTHERS => c_dp_siso_rst);
SIGNAL wpfb_complex_out_resized_sosi_2arr : t_dp_sosi_2arr_2(c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => (OTHERS => c_dp_sosi_rst)); SIGNAL wpfb_complex_out_resized_sosi_2arr : t_dp_sosi_2arr_2(c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => (OTHERS => c_dp_sosi_rst));
SIGNAL wpfb_complex_out_resized_siso_2arr : t_dp_siso_2arr_2(c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => (OTHERS => c_dp_siso_rst)); SIGNAL wpfb_complex_out_resized_siso_2arr : t_dp_siso_2arr_2(c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => (OTHERS => c_dp_siso_rst));
SIGNAL wpfb_complex_out_interleaved_sosi_arr : t_dp_sosi_arr(c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => c_dp_sosi_rst);
SIGNAL subband_equalizer_in_sosi_arr : t_dp_sosi_arr(c_sdp_R_os * c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => c_dp_sosi_rst); SIGNAL subband_equalizer_in_sosi_arr : t_dp_sosi_arr(c_sdp_R_os * c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => c_dp_sosi_rst);
SIGNAL subband_equalizer_quant_sosi_arr : t_dp_sosi_arr(c_sdp_R_os * c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => c_dp_sosi_rst); SIGNAL subband_equalizer_quant_sosi_arr : t_dp_sosi_arr(c_sdp_R_os * c_sdp_P_pfb-1 DOWNTO 0) := (OTHERS => c_dp_sosi_rst);
...@@ -479,7 +484,7 @@ BEGIN ...@@ -479,7 +484,7 @@ BEGIN
gen_dp_fifo: FOR I IN 0 TO c_sdp_S_pn-1 GENERATE gen_dp_fifo: FOR I IN 0 TO c_sdp_S_pn-1 GENERATE
u_dp_fifo_sc : ENTITY dp_lib.dp_fifo_sc u_dp_fifo_sc : ENTITY dp_lib.dp_fifo_sc
GENERIC MAP( GENERIC MAP(
g_data_w => c_nof_complex * c_subband_raw_dat_w, g_data_w => c_nof_complex * c_complex_subband_raw_dat_w,
g_bsn_w => c_dp_stream_bsn_w, g_bsn_w => c_dp_stream_bsn_w,
g_use_bsn => TRUE, g_use_bsn => TRUE,
g_use_sync => TRUE, g_use_sync => TRUE,
...@@ -503,8 +508,8 @@ BEGIN ...@@ -503,8 +508,8 @@ BEGIN
wpfb_complex_out_fifo_siso_arr(2*I + 1) <= wpfb_complex_out_resized_siso_2arr(I)(1); wpfb_complex_out_fifo_siso_arr(2*I + 1) <= wpfb_complex_out_resized_siso_2arr(I)(1);
END GENERATE; END GENERATE;
gen_align: FOR I IN 0 TO c_sdp_P_pfb-1 GENERATE
-- Interleave 2 to 1 for all S_pn signals. -- Interleave 2 to 1 for all S_pn signals.
gen_interleave: FOR I IN 0 TO c_sdp_P_pfb-1 GENERATE
u_dp_interleave_n_to_one : ENTITY dp_lib.dp_interleave_n_to_one u_dp_interleave_n_to_one : ENTITY dp_lib.dp_interleave_n_to_one
GENERIC MAP( GENERIC MAP(
g_nof_inputs => c_sdp_Q_fft g_nof_inputs => c_sdp_Q_fft
...@@ -514,10 +519,21 @@ BEGIN ...@@ -514,10 +519,21 @@ BEGIN
clk => dp_clk, clk => dp_clk,
snk_in_arr => wpfb_complex_out_resized_sosi_2arr(I), snk_in_arr => wpfb_complex_out_resized_sosi_2arr(I),
snk_out_arr => wpfb_complex_out_resized_siso_2arr(I), snk_out_arr => wpfb_complex_out_resized_siso_2arr(I),
src_out => subband_equalizer_in_sosi_arr(c_sdp_P_pfb + I) src_out => wpfb_complex_out_interleaved_sosi_arr(I)
); );
END GENERATE;
-- Align data width of wpfb_complex output with wpfb_real output as the real wpfb
-- has an extra bit that is used for the FFT seperate function which the complex FFT
-- does not have. Here we add that extra bit to the output of the complex FFT aswell
-- to maintain the same scale and data width.
p_add_bit : PROCESS(wpfb_complex_out_interleaved_sosi_arr)
BEGIN
subband_equalizer_in_sosi_arr(c_sdp_P_pfb + I) <= wpfb_complex_out_interleaved_sosi_arr(I);
subband_equalizer_in_sosi_arr(c_sdp_P_pfb + I).re <= SHIFT_SVEC(wpfb_complex_out_interleaved_sosi_arr(I).re, c_dat_w_diff);
subband_equalizer_in_sosi_arr(c_sdp_P_pfb + I).im <= SHIFT_SVEC(wpfb_complex_out_interleaved_sosi_arr(I).im, c_dat_w_diff);
END PROCESS;
END GENERATE;
-- Pipeline to compensate for longer latency of the complex PFB. -- Pipeline to compensate for longer latency of the complex PFB.
u_dp_pipeline_arr : ENTITY dp_lib.dp_pipeline_arr u_dp_pipeline_arr : ENTITY dp_lib.dp_pipeline_arr
...@@ -580,7 +596,6 @@ BEGIN ...@@ -580,7 +596,6 @@ BEGIN
fsub_quant_sosi_arr <= subband_equalizer_quant_sosi_arr; fsub_quant_sosi_arr <= subband_equalizer_quant_sosi_arr;
fsub_raw_sosi_arr <= subband_equalizer_raw_sosi_arr; fsub_raw_sosi_arr <= subband_equalizer_raw_sosi_arr;
--------------------------------------------------------------- ---------------------------------------------------------------
-- DP REQUANTIZE for SST -- DP REQUANTIZE for SST
--------------------------------------------------------------- ---------------------------------------------------------------
......
...@@ -391,8 +391,8 @@ ARCHITECTURE str OF sdp_station IS ...@@ -391,8 +391,8 @@ ARCHITECTURE str OF sdp_station IS
CONSTANT c_fft_raw_dat_w : NATURAL := func_fft_raw_dat_w(c_fft); CONSTANT c_fft_raw_dat_w : NATURAL := func_fft_raw_dat_w(c_fft);
CONSTANT c_fft_raw_fraction_w : NATURAL := func_fft_raw_fraction_w(c_fft); CONSTANT c_fft_raw_fraction_w : NATURAL := func_fft_raw_fraction_w(c_fft);
CONSTANT c_subband_raw_dat_w : NATURAL := sel_a_b(g_use_oversample, c_sdp_W_subband, c_fft_raw_dat_w); CONSTANT c_subband_raw_dat_w : NATURAL := c_fft_raw_dat_w;
CONSTANT c_subband_raw_fraction_w : NATURAL := sel_a_b(g_use_oversample, 0, c_fft_raw_fraction_w); CONSTANT c_subband_raw_fraction_w : NATURAL := c_fft_raw_fraction_w;
-- Make Tx FIFOs at least c_fifo_tx_fill_margin larger than needed to fit the largest Tx packet -- Make Tx FIFOs at least c_fifo_tx_fill_margin larger than needed to fit the largest Tx packet
CONSTANT c_fifo_tx_fill_margin : NATURAL := 10; -- >= c_fifo_fill_margin = 6 that is used in dp_fifo_fill_eop CONSTANT c_fifo_tx_fill_margin : NATURAL := 10; -- >= c_fifo_fill_margin = 6 that is used in dp_fifo_fill_eop
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment