Use Cases
- AXI-Stream datapath integration where module boundaries need explicit ready/valid behavior.
- Reusable FPGA DSP pipelines that need fixed-point, timing-aware implementation.
- Memory-mapped control/status integration with software-visible register maps.
Block Diagram
VHDL Include And Instantiation Template
File Header
library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
library radhdl;
-- Direct entity instantiation below does not require importing the entity name.
use radhdl.dsp.all;
-- Narrower alternative: use radhdl.dsp_detection.all;Component Declaration
component raddsp_axis_fft_fingerprint is
generic (
VENDOR : string := "xilinx";
DEVICE_FAMILY : string := "generic";
FFT_DATA_WIDTH : positive := 16;
HASH_WIDTH : positive := 64;
BIN_INDEX_WIDTH : positive := 16;
AXI_ADDR_WIDTH : positive := 8;
AXI_DATA_WIDTH : positive := 32;
DEFAULT_FRAME_BINS : positive := 1024
);
port (
m_axis_tvalid : out std_logic;
m_axis_tready : in std_logic;
m_axis_tdata : out std_logic_vector(HASH_WIDTH + 64 - 1 downto 0);
m_axis_tlast : out std_logic;
s_axis_tvalid : in std_logic;
s_axis_tready : out std_logic;
s_axis_tdata : in std_logic_vector((2 * FFT_DATA_WIDTH) - 1 downto 0);
s_axis_tlast : in std_logic;
s_axi_awaddr : in std_logic_vector(AXI_ADDR_WIDTH - 1 downto 0);
s_axi_awprot : in std_logic_vector(2 downto 0);
s_axi_awvalid : in std_logic;
s_axi_awready : out std_logic;
s_axi_wdata : in std_logic_vector(AXI_DATA_WIDTH - 1 downto 0);
s_axi_wstrb : in std_logic_vector((AXI_DATA_WIDTH / 8) - 1 downto 0);
s_axi_wvalid : in std_logic;
s_axi_wready : out std_logic;
s_axi_bresp : out std_logic_vector(1 downto 0);
s_axi_bvalid : out std_logic;
s_axi_bready : in std_logic;
s_axi_araddr : in std_logic_vector(AXI_ADDR_WIDTH - 1 downto 0);
s_axi_arprot : in std_logic_vector(2 downto 0);
s_axi_arvalid : in std_logic;
s_axi_arready : out std_logic;
s_axi_rdata : out std_logic_vector(AXI_DATA_WIDTH - 1 downto 0);
s_axi_rresp : out std_logic_vector(1 downto 0);
s_axi_rvalid : out std_logic;
s_axi_rready : in std_logic;
clk : in std_logic;
rst : in std_logic
);
end component;Direct Entity Instantiation
u_raddsp_axis_fft_fingerprint : entity radhdl.raddsp_axis_fft_fingerprint
generic map (
VENDOR => "xilinx",
DEVICE_FAMILY => "generic",
FFT_DATA_WIDTH => 16,
HASH_WIDTH => 64,
BIN_INDEX_WIDTH => 16,
AXI_ADDR_WIDTH => 8,
AXI_DATA_WIDTH => 32,
DEFAULT_FRAME_BINS => 1024
)
port map (
m_axis_tvalid => <m_axis_tvalid_signal>,
m_axis_tready => <m_axis_tready_signal>,
m_axis_tdata => <m_axis_tdata_signal>,
m_axis_tlast => <m_axis_tlast_signal>,
s_axis_tvalid => <s_axis_tvalid_signal>,
s_axis_tready => <s_axis_tready_signal>,
s_axis_tdata => <s_axis_tdata_signal>,
s_axis_tlast => <s_axis_tlast_signal>,
s_axi_awaddr => <s_axi_awaddr_signal>,
s_axi_awprot => <s_axi_awprot_signal>,
s_axi_awvalid => <s_axi_awvalid_signal>,
s_axi_awready => <s_axi_awready_signal>,
s_axi_wdata => <s_axi_wdata_signal>,
s_axi_wstrb => <s_axi_wstrb_signal>,
s_axi_wvalid => <s_axi_wvalid_signal>,
s_axi_wready => <s_axi_wready_signal>,
s_axi_bresp => <s_axi_bresp_signal>,
s_axi_bvalid => <s_axi_bvalid_signal>,
s_axi_bready => <s_axi_bready_signal>,
s_axi_araddr => <s_axi_araddr_signal>,
s_axi_arprot => <s_axi_arprot_signal>,
s_axi_arvalid => <s_axi_arvalid_signal>,
s_axi_arready => <s_axi_arready_signal>,
s_axi_rdata => <s_axi_rdata_signal>,
s_axi_rresp => <s_axi_rresp_signal>,
s_axi_rvalid => <s_axi_rvalid_signal>,
s_axi_rready => <s_axi_rready_signal>,
clk => <clk_signal>,
rst => <rst_signal>
);Generics
| Name | Type | Default | Description |
|---|---|---|---|
| VENDOR | string | "xilinx" | Selects the vendor-specific implementation path, usually XILINX for DSP48/XPM-backed builds or generic for portable RTL. |
| DEVICE_FAMILY | string | "generic" | Identifies the target FPGA family so wrappers can choose the correct primitive or conservative portable behavior. |
| FFT_DATA_WIDTH | positive | 16 | Sets the bit width for FFT DATA WIDTH values carried by this module. |
| HASH_WIDTH | positive | 64 | Sets the bit width for HASH WIDTH values carried by this module. |
| BIN_INDEX_WIDTH | positive | 16 | Sets the bit width for BIN INDEX WIDTH values carried by this module. |
| AXI_ADDR_WIDTH | positive | 8 | Sets the bit width for AXI ADDR WIDTH values carried by this module. |
| AXI_DATA_WIDTH | positive | 32 | Sets the bit width for AXI DATA WIDTH values carried by this module. |
| DEFAULT_FRAME_BINS | positive | 1024 | Configures DEFAULT FRAME BINS for this instance. |
Ports
| Name | Direction | Type | Description |
|---|---|---|---|
| m_axis_tvalid | out | std_logic | Output AXI-stream valid qualifier for the current result beat. |
| m_axis_tready | in | std_logic | Output AXI-stream ready input from the downstream block. |
| m_axis_tdata | out | std_logic_vector(HASH_WIDTH + 64 - 1 downto 0) | Output AXI-stream payload containing packed processed result lanes. |
| m_axis_tlast | out | std_logic | Output AXI-stream frame marker aligned with the processed result beat. |
| s_axis_tvalid | in | std_logic | Input AXI-stream valid qualifier for the current sample beat. |
| s_axis_tready | out | std_logic | Input AXI-stream ready response indicating this block can accept a beat. |
| s_axis_tdata | in | std_logic_vector((2 * FFT_DATA_WIDTH) - 1 downto 0) | Input AXI-stream payload containing packed sample or feature lanes. |
| s_axis_tlast | in | std_logic | Input AXI-stream frame marker for the final beat of a frame. |
| s_axi_awaddr | in | std_logic_vector(AXI_ADDR_WIDTH - 1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_awprot | in | std_logic_vector(2 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_awvalid | in | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_awready | out | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_wdata | in | std_logic_vector(AXI_DATA_WIDTH - 1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_wstrb | in | std_logic_vector((AXI_DATA_WIDTH / 8) - 1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_wvalid | in | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_wready | out | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_bresp | out | std_logic_vector(1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_bvalid | out | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_bready | in | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_araddr | in | std_logic_vector(AXI_ADDR_WIDTH - 1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_arprot | in | std_logic_vector(2 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_arvalid | in | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_arready | out | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_rdata | out | std_logic_vector(AXI_DATA_WIDTH - 1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_rresp | out | std_logic_vector(1 downto 0) | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_rvalid | out | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| s_axi_rready | in | std_logic | AXI4-Lite slave-channel signal used for host register access. |
| clk | in | std_logic | Clock for the associated synchronous logic and handshake domain. |
| rst | in | std_logic | Active-high synchronous reset for this clock domain. |
Register Interfaces
Static register maps are rendered below for this module.
| Interface | Directions | Signals | Representative ports |
|---|---|---|---|
| M_AXIS | in, out | 4 | m_axis_tvalid, m_axis_tready, m_axis_tdata, m_axis_tlast |
| S_AXI | in, out | 19 | s_axi_awaddr, s_axi_awprot, s_axi_awvalid, s_axi_awready, s_axi_wdata, s_axi_wstrb, s_axi_wvalid, s_axi_wready, +11 more |
| S_AXIS | in, out | 4 | s_axis_tvalid, s_axis_tready, s_axis_tdata, s_axis_tlast |
Register Maps
raddsp_axis_fft_fingerprint_inferred
Register map inferred from C_REG_* constants in the VHDL source. Use this as a software-visible register index until a hand-authored map adds per-bit access details.
| Register | Offset | Access | Reset | Description |
|---|---|---|---|---|
| ctrl | 0x00 | rw | Control register used to configure and control this block. | |
| frame_bins | 0x04 | rw | Configuration or measurement register used by the software-visible control interface. | |
| bin_offset | 0x08 | rw | Register inferred from the module's VHDL register constant declarations. | |
| bin_stride | 0x0C | rw | Configuration or measurement register used by the software-visible control interface. | |
| mag_shift | 0x10 | rw | Configuration or measurement register used by the software-visible control interface. | |
| hash_seed_lo | 0x14 | rw | Data or comparison value register used by the software-visible control interface. | |
| hash_seed_hi | 0x18 | rw | Data or comparison value register used by the software-visible control interface. | |
| status | 0x1C | rw | Status register exposing current hardware state and latched conditions. | |
| last_hash_lo | 0x20 | rw | Data or comparison value register used by the software-visible control interface. | |
| last_hash_hi | 0x24 | rw | Data or comparison value register used by the software-visible control interface. | |
| last_peak_bin | 0x28 | rw | Register inferred from the module's VHDL register constant declarations. | |
| last_peak_mag | 0x2C | rw | Register inferred from the module's VHDL register constant declarations. | |
| last_selected | 0x30 | rw | Data or comparison value register used by the software-visible control interface. | |
| frame_count | 0x34 | rw | Configuration or measurement register used by the software-visible control interface. | |
| pair_gap | 0x38 | rw | Configuration or measurement register used by the software-visible control interface. | |
| last_delta | 0x3C | rw | Configuration or measurement register used by the software-visible control interface. |
ctrl
Control register used to configure and control this block.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | Ctrl[31:0] | Full register value. |
frame_bins
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | FrameBins[31:0] | Full register value. |
bin_offset
Register inferred from the module's VHDL register constant declarations.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | BinOffset[31:0] | Full register value. |
bin_stride
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | BinStride[31:0] | Full register value. |
mag_shift
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | MagShift[31:0] | Full register value. |
hash_seed_lo
Data or comparison value register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | HashSeedLo[31:0] | Full register value. |
hash_seed_hi
Data or comparison value register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | HashSeedHi[31:0] | Full register value. |
status
Status register exposing current hardware state and latched conditions.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | Status[31:0] | Full register value. |
last_hash_lo
Data or comparison value register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastHashLo[31:0] | Full register value. |
last_hash_hi
Data or comparison value register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastHashHi[31:0] | Full register value. |
last_peak_bin
Register inferred from the module's VHDL register constant declarations.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastPeakBin[31:0] | Full register value. |
last_peak_mag
Register inferred from the module's VHDL register constant declarations.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastPeakMag[31:0] | Full register value. |
last_selected
Data or comparison value register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastSelected[31:0] | Full register value. |
frame_count
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | FrameCount[31:0] | Full register value. |
pair_gap
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | PairGap[31:0] | Full register value. |
last_delta
Configuration or measurement register used by the software-visible control interface.
| Name | Register bit(s) | Description |
|---|---|---|
| VALUE | LastDelta[31:0] | Full register value. |
Testbenches
tb_raddsp_axis_fingerprint
Self-checking or stimulus-focused testbench for axis fingerprint. Exercises representative handshakes, reset behavior, frame boundaries, and numeric corner cases for regression runs.
Data Plots
FFT Fingerprint Peak Tracking
Selected bin index and running peak magnitude during fingerprint extraction.
Fingerprint Match Count
Matcher-side count of accepted fingerprint hits in the small directed table.
Captured GHDL Waveform
M_AXIS interface signals
M_AXIS Interface Waveform
S_AXI interface signals
S_AXI Interface Waveform
S_AXIS interface signals
S_AXIS Interface Waveform
Sources
- dsp/hdl/raddsp/src/raddsp_axis_fft_fingerprint.vhd
