fpga: rfnoc: Add SV packages for use with RFNoC

Original-commit: c2b8eb4a88534230ce31dd4d40e4c069644c4d10
This commit is contained in:
Wade Fife
2024-12-17 22:13:42 +01:00
committed by Jörg Hofrichter
parent 48d8e384b6
commit 7e792d4a25
4 changed files with 52 additions and 5 deletions
+2
View File
@@ -15,6 +15,8 @@ ctrlport.vh \
))
RFNOC_CORE_SRCS = $(abspath $(addprefix $(BASE_DIR)/../lib/rfnoc/core/, \
rfnoc_chdr_utils_pkg.sv \
ctrlport_pkg.sv \
axis_ctrl_endpoint.v \
axis_ctrl_master.v \
axis_ctrl_slave.v \
+17
View File
@@ -0,0 +1,17 @@
//
// Copyright 2024 Ettus Research, a National Instruments Brand
//
// SPDX-License-Identifier: LGPL-3.0-or-later
//
// Package: ctrlport_pkg
//
// Description:
//
// Defines constants for the control-port interface.
//
package ctrlport_pkg;
`include "ctrlport.vh"
endpackage : ctrlport_pkg
+11
View File
@@ -57,6 +57,17 @@ localparam [4:0] CHDR_NO_MDATA = 5'd0;
// EPID
localparam [15:0] NULL_EPID = 16'd0;
// CHDR field lengths
localparam CHDR_VC_W = 6;
localparam CHDR_EOB_W = 1;
localparam CHDR_EOV_W = 1;
localparam CHDR_PKT_TYPE_W = 3;
localparam CHDR_NUM_MDATA_W = 5;
localparam CHDR_SEQ_NUM_W = 16;
localparam CHDR_LENGTH_W = 16;
localparam CHDR_DST_EPID_W = 16;
localparam CHDR_TIMESTAMP_W = 64;
// CHDR Getter Functions
//
function [5:0] chdr_get_vc(input [63:0] header);
+17
View File
@@ -0,0 +1,17 @@
//
// Copyright 2024 Ettus Research, a National Instruments Brand
//
// SPDX-License-Identifier: LGPL-3.0-or-later
//
// Module: rfnoc_chdr_utils_pkg
//
// Description:
//
// Package containing constants and functions for working with CHDR.
//
package rfnoc_chdr_utils_pkg;
`include "rfnoc_chdr_utils.vh"
endpackage : rfnoc_chdr_utils_pkg