Skip to content
Snippets Groups Projects
Commit 6bb01fce authored by Eric Kooistra's avatar Eric Kooistra
Browse files

Add subtypes. Rename c_sdp_cep_nof_beamlets_per_longword into c_sdp_nof_beamlets_per_longword.

parent dfbd8a3c
No related branches found
No related tags found
1 merge request!348Use use_bdo_transpose = true in c_bf revision. Test use_bdo_transpose = false...
...@@ -137,11 +137,23 @@ package sdp_pkg is ...@@ -137,11 +137,23 @@ package sdp_pkg is
constant c_sdp_N_beamlets_sdp : natural := c_sdp_N_beamsets * c_sdp_S_sub_bf; -- = 976 constant c_sdp_N_beamlets_sdp : natural := c_sdp_N_beamsets * c_sdp_S_sub_bf; -- = 976
constant c_sdp_W_dual_pol_beamlet : natural := c_sdp_N_pol_bf * c_nof_complex * c_sdp_W_beamlet; -- 2 * 2 * 8 = 32b constant c_sdp_W_dual_pol_beamlet : natural := c_sdp_N_pol_bf * c_nof_complex * c_sdp_W_beamlet; -- 2 * 2 * 8 = 32b
constant c_sdp_nof_beamlets_per_longword : natural := 2; -- 2 dual pol, complex, 8bit beamlets fit in 1 64bit longword
-- . unit weights -- . unit weights
constant c_sdp_unit_sub_weight : natural := 2**c_sdp_W_sub_weight_fraction; -- 2**13, so range +-4.0 for 16 bit signed weight constant c_sdp_unit_sub_weight : natural := 2**c_sdp_W_sub_weight_fraction; -- 2**13, so range +-4.0 for 16 bit signed weight
constant c_sdp_unit_bf_weight : natural := 2**c_sdp_W_bf_weight_fraction; -- 2**14, so range +-2.0 for 16 bit signed weight constant c_sdp_unit_bf_weight : natural := 2**c_sdp_W_bf_weight_fraction; -- 2**14, so range +-2.0 for 16 bit signed weight
constant c_sdp_unit_beamlet_scale : natural := 2**c_sdp_W_beamlet_scale_fraction; -- 2**15, so range +-1.0 for 16 bit signed weight constant c_sdp_unit_beamlet_scale : natural := 2**c_sdp_W_beamlet_scale_fraction; -- 2**15, so range +-1.0 for 16 bit signed weight
-- One dual polarization beamlet fits in a 32b word:
-- [0:3] = [Xre, Xim, Yre, Yim] parts of c_sdp_W_beamlet = 8 bit, so
-- c_sdp_N_pol_bf * c_nof_complex * c_sdp_W_beamlet = 2 * 2 = 4 octets
subtype t_sdp_dual_pol_beamlet_in_word is t_slv_8_arr(0 to 3);
-- Two dual polarization beamlets fit in a 64b longword:
-- [0:7] = [0:3,4:7] = [Xre, Xim, Yre, Yim, Xre, Xim, Yre, Yim], so
-- c_sdp_nof_beamlets_per_longword * c_sdp_N_pol_bf * c_nof_complex = 2 * 2 * 2 = 8 octets
subtype t_sdp_dual_pol_beamlet_in_longword is t_slv_8_arr(0 to 7);
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
-- PFB -- PFB
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
...@@ -409,8 +421,7 @@ package sdp_pkg is ...@@ -409,8 +421,7 @@ package sdp_pkg is
constant c_sdp_cep_nof_blocks_per_packet : natural := 4; -- number of time blocks of beamlets per output packet constant c_sdp_cep_nof_blocks_per_packet : natural := 4; -- number of time blocks of beamlets per output packet
constant c_sdp_cep_nof_beamlets_per_block : natural := c_sdp_S_sub_bf; -- number of dual pol beamlets (c_sdp_N_pol_bf = 2) constant c_sdp_cep_nof_beamlets_per_block : natural := c_sdp_S_sub_bf; -- number of dual pol beamlets (c_sdp_N_pol_bf = 2)
constant c_sdp_cep_nof_beamlets_per_packet : natural := c_sdp_cep_nof_blocks_per_packet * c_sdp_cep_nof_beamlets_per_block; constant c_sdp_cep_nof_beamlets_per_packet : natural := c_sdp_cep_nof_blocks_per_packet * c_sdp_cep_nof_beamlets_per_block;
constant c_sdp_cep_nof_beamlets_per_longword : natural := 2; -- 2 dual pol, complex, 8bit beamlets fit in 1 64bit longword constant c_sdp_cep_payload_nof_longwords : natural := c_sdp_cep_nof_beamlets_per_packet / c_sdp_nof_beamlets_per_longword; -- = 976
constant c_sdp_cep_payload_nof_longwords : natural := c_sdp_cep_nof_beamlets_per_packet / c_sdp_cep_nof_beamlets_per_longword; -- = 976
constant c_sdp_cep_packet_nof_longwords : natural := ceil_div(c_sdp_cep_header_len, c_longword_sz) + c_sdp_cep_payload_nof_longwords; -- without tail CRC, the CRC is applied by 10GbE MAC constant c_sdp_cep_packet_nof_longwords : natural := ceil_div(c_sdp_cep_header_len, c_longword_sz) + c_sdp_cep_payload_nof_longwords; -- without tail CRC, the CRC is applied by 10GbE MAC
constant c_sdp_cep_nof_hdr_fields : natural := 3 + 12 + 4 + 4 + 9 + 6 + 1; -- = 39 fields constant c_sdp_cep_nof_hdr_fields : natural := 3 + 12 + 4 + 4 + 9 + 6 + 1; -- = 39 fields
......
...@@ -109,9 +109,10 @@ package tb_sdp_pkg is ...@@ -109,9 +109,10 @@ package tb_sdp_pkg is
-- Beamlet output packet -- Beamlet output packet
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
-- beamlet part index [0 : 3] of X, Y, X, Y in network longword: -- beamlet part index [0 : 3] of X, Y, X, Y in network longword:
-- . re[0 : 3] at 0, 2, 4, 6 in longword -- - use separate array for re and for im:
-- . im[0 : 3] at 1, 3, 5, 7 in longword -- . re[0 : 3] at 0, 2, 4, 6 in longword
subtype t_sdp_beamlet_part_arr is t_slv_8_arr(0 to c_sdp_cep_nof_beamlets_per_longword * c_sdp_N_pol_bf - 1); -- . im[0 : 3] at 1, 3, 5, 7 in longword
subtype t_sdp_beamlet_part_arr is t_slv_8_arr(0 to c_sdp_nof_beamlets_per_longword * c_sdp_N_pol_bf - 1);
-- beamlet part index in packet with 4 blocks [0 : 4 * 488 * 2 - 1] = [0 : 3903] -- beamlet part index in packet with 4 blocks [0 : 4 * 488 * 2 - 1] = [0 : 3903]
-- . use separate list for re and for im -- . use separate list for re and for im
...@@ -500,7 +501,8 @@ package body tb_sdp_pkg is ...@@ -500,7 +501,8 @@ package body tb_sdp_pkg is
-- v_out = func_sdp_bdo_transpose_packet(4, 488, v_in) yields the expected v_out. -- v_out = func_sdp_bdo_transpose_packet(4, 488, v_in) yields the expected v_out.
-- . See data repacking section in: -- . See data repacking section in:
-- https://support.astron.nl/confluence/pages/viewpage.action?spaceKey=L2M&title=L4+SDPFW+Decision%3A+Multiple+beamlet+output+destinations -- https://support.astron.nl/confluence/pages/viewpage.action?spaceKey=L2M&title=L4+SDPFW+Decision%3A+Multiple+beamlet+output+destinations
-- . Use separate packet_list for re and im -- . Use separate packet_list for re and im. The list contain 4 * 488 * 2 = 3904
-- beamlet part octet values.
-- input packet_list: -- input packet_list:
-- . blk 0, 1, 2, 3, for nof_blocks_per_packet = 4 -- . blk 0, 1, 2, 3, for nof_blocks_per_packet = 4
-- . blet 0, ... 487, 0, ... 487, 0, ... 487, 0, ... 487, for nof_beamlets_per_block = 488 -- . blet 0, ... 487, 0, ... 487, 0, ... 487, 0, ... 487, for nof_beamlets_per_block = 488
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment