Select Git revision
dp_components_pkg.vhd

Eric Kooistra authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
dp_components_pkg.vhd 2.37 KiB
-------------------------------------------------------------------------------
--
-- Copyright 2022
-- ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
-- P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the License.
-- You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
--
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- Author: E. Kooistra
-- Purpose: Keep parameters of DP components
-- Description:
LIBRARY IEEE, common_lib;
USE IEEE.STD_LOGIC_1164.ALL;
USE IEEE.numeric_std.ALL;
USE common_lib.common_pkg.ALL;
PACKAGE dp_components_pkg IS
CONSTANT c_dp_clk_MHz : NATURAL := 200;
CONSTANT c_dp_sync_timeout : NATURAL := c_dp_clk_MHz*10**6 + c_dp_clk_MHz*10**5; -- 10% margin for nominal 1 s
CONSTANT c_dp_bsn_monitor_v2_reg_adr_w : NATURAL := ceil_log2(7); -- = 3
CONSTANT c_dp_bsn_monitor_v2_reg_adr_span : NATURAL := 2**c_dp_bsn_monitor_v2_reg_adr_w; -- = 8
CONSTANT c_dp_strobe_total_count_reg_nof_words : NATURAL := 15*2 + 2; -- = 32
CONSTANT c_dp_strobe_total_count_reg_adr_w : NATURAL := ceil_log2(c_dp_strobe_total_count_reg_nof_words); -- = 5
CONSTANT c_dp_strobe_total_count_reg_adr_span : NATURAL := 2**c_dp_strobe_total_count_reg_adr_w; -- = 32
CONSTANT c_dp_strobe_total_count_reg_nof_counts_max : NATURAL := 2**c_dp_strobe_total_count_reg_adr_w / 2 - 1; -- = 15
CONSTANT c_dp_strobe_total_count_reg_clear_adr : NATURAL := c_dp_strobe_total_count_reg_nof_counts_max*2; -- after counters in REGMAP
CONSTANT c_dp_strobe_total_count_reg_flush_adr : NATURAL := c_dp_strobe_total_count_reg_nof_counts_max*2 + 1;
END dp_components_pkg;
PACKAGE BODY dp_components_pkg IS
END dp_components_pkg;