OpenCores
URL https://opencores.org/ocsvn/astron_diagnostics/astron_diagnostics/trunk

Subversion Repositories astron_diagnostics

[/] [astron_diagnostics/] [trunk/] [mms_diag_block_gen.vhd] - Diff between revs 3 and 4

Show entire file | Details | Blame | View Log

Rev 3 Rev 4
Line 90... Line 90...
-- . A nice new feature would be to support BG data width > 32b, similar as in
-- . A nice new feature would be to support BG data width > 32b, similar as in
--   the DB mms_diag_data_buffer.vhd.
--   the DB mms_diag_data_buffer.vhd.
-- . A nice new feature would be to support a BG burst of N blocks.
-- . A nice new feature would be to support a BG burst of N blocks.
 
 
 
 
LIBRARY IEEE, common_pkg_lib, common_ram_lib, technology_lib, dp_pkg_lib, dp_components_lib, dp_mux_lib, mm_lib;
LIBRARY IEEE, common_pkg_lib, astron_ram_lib, dp_pkg_lib, dp_components_lib, astron_multiplexer_lib, astron_mm_lib;
USE IEEE.STD_LOGIC_1164.ALL;
USE IEEE.STD_LOGIC_1164.ALL;
USE IEEE.NUMERIC_STD.ALL;
USE IEEE.NUMERIC_STD.ALL;
USE common_pkg_lib.common_pkg.ALL;
USE common_pkg_lib.common_pkg.ALL;
USE common_ram_lib.common_ram_pkg.ALL;
USE astron_ram_lib.common_ram_pkg.ALL;
USE dp_pkg_lib.dp_stream_pkg.ALL;
USE dp_pkg_lib.dp_stream_pkg.ALL;
USE work.diag_pkg.ALL;
USE work.diag_pkg.ALL;
USE technology_lib.technology_select_pkg.ALL;
--USE technology_lib.technology_select_pkg.ALL;
 
 
ENTITY mms_diag_block_gen IS
ENTITY mms_diag_block_gen IS
  GENERIC (
  GENERIC (
    g_technology         : NATURAL := c_tech_select_default;
    g_technology         : NATURAL := 0;
    -- Generate configurations
    -- Generate configurations
    g_use_usr_input      : BOOLEAN := FALSE;
    g_use_usr_input      : BOOLEAN := FALSE;
    g_use_bg             : BOOLEAN := TRUE;
    g_use_bg             : BOOLEAN := TRUE;
    g_use_tx_seq         : BOOLEAN := FALSE;
    g_use_tx_seq         : BOOLEAN := FALSE;
    -- General
    -- General
Line 216... Line 216...
      mm_miso => reg_bg_ctrl_miso,
      mm_miso => reg_bg_ctrl_miso,
      bg_ctrl => bg_ctrl
      bg_ctrl => bg_ctrl
    );
    );
 
 
    -- Combine the internal array of mm interfaces for the bg_data to one array that is connected to the port of the MM bus
    -- Combine the internal array of mm interfaces for the bg_data to one array that is connected to the port of the MM bus
    u_mem_mux_bg_data : ENTITY mm_lib.common_mem_mux
    u_mem_mux_bg_data : ENTITY astron_mm_lib.common_mem_mux
    GENERIC MAP (
    GENERIC MAP (
      g_nof_mosi    => g_nof_streams,
      g_nof_mosi    => g_nof_streams,
      g_mult_addr_w => g_buf_addr_w
      g_mult_addr_w => g_buf_addr_w
    )
    )
    PORT MAP (
    PORT MAP (
Line 238... Line 238...
        st_rdval_arr(I)  <=             st_rd_arr(I)                 WHEN rising_edge(dp_clk);
        st_rdval_arr(I)  <=             st_rd_arr(I)                 WHEN rising_edge(dp_clk);
        st_rddata_arr(I) <= RESIZE_UVEC(st_addr_arr(I), g_buf_dat_w) WHEN rising_edge(dp_clk);
        st_rddata_arr(I) <= RESIZE_UVEC(st_addr_arr(I), g_buf_dat_w) WHEN rising_edge(dp_clk);
      END GENERATE;
      END GENERATE;
 
 
      gen_buffer_ram : IF g_use_bg_buffer_ram=TRUE GENERATE
      gen_buffer_ram : IF g_use_bg_buffer_ram=TRUE GENERATE
        u_buffer_ram : ENTITY common_ram_lib.common_ram_crw_crw
        u_buffer_ram : ENTITY astron_ram_lib.common_ram_crw_crw
        GENERIC MAP (
        GENERIC MAP (
          g_technology => g_technology,
          g_technology => g_technology,
          g_ram        => c_buf,
          g_ram        => c_buf,
          -- Sequence number and ".hex" extension are added to the relative path in case a ram file is provided. 
          -- Sequence number and ".hex" extension are added to the relative path in case a ram file is provided. 
          g_init_file  => sel_a_b(g_file_name_prefix = "UNUSED", g_file_name_prefix, g_file_name_prefix & "_" & NATURAL'IMAGE(g_file_index_arr(I)) & c_post_buf_file)
          g_init_file  => sel_a_b(g_file_name_prefix = "UNUSED", g_file_name_prefix, g_file_name_prefix & "_" & NATURAL'IMAGE(g_file_index_arr(I)) & c_post_buf_file)
Line 334... Line 334...
      bg_src_in_arr(I)        <= mux_snk_out_2arr_2(I)(1);
      bg_src_in_arr(I)        <= mux_snk_out_2arr_2(I)(1);
 
 
      mux_snk_in_2arr_2(I)(0) <= usr_xflow_src_out_arr(I);
      mux_snk_in_2arr_2(I)(0) <= usr_xflow_src_out_arr(I);
      mux_snk_in_2arr_2(I)(1) <= bg_src_out_arr(I);
      mux_snk_in_2arr_2(I)(1) <= bg_src_out_arr(I);
 
 
      u_dp_mux : ENTITY dp_mux_lib.dp_mux
      u_dp_mux : ENTITY astron_multiplexer_lib.dp_mux
      GENERIC MAP (
      GENERIC MAP (
        g_technology        => g_technology,
        g_technology        => g_technology,
        -- MUX
        -- MUX
        g_mode              => 4,                                 -- g_mode=4 for framed input select via sel_ctrl
        g_mode              => 4,                                 -- g_mode=4 for framed input select via sel_ctrl
        g_nof_input         => c_mux_nof_input,                   -- >= 1
        g_nof_input         => c_mux_nof_input,                   -- >= 1

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.