Radical Computer Technologies
DSP / entity

raddsp_axis_fft_fingerprint

Documentation version: 0.2.0 / Subpackage: dsp_detection / Source package: raddsp

AXI-stream spectral fingerprint extraction core. Condenses FFT output into compact bin-energy features that can be compared against stored fingerprints.

Use Cases

Block Diagram

raddsp_axis_fft_fingerprint radhdl entity S_AXIS S_AXI clk rst M_AXIS
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

NameTypeDefaultDescription
VENDORstring"xilinx"Selects the vendor-specific implementation path, usually XILINX for DSP48/XPM-backed builds or generic for portable RTL.
DEVICE_FAMILYstring"generic"Identifies the target FPGA family so wrappers can choose the correct primitive or conservative portable behavior.
FFT_DATA_WIDTHpositive16Sets the bit width for FFT DATA WIDTH values carried by this module.
HASH_WIDTHpositive64Sets the bit width for HASH WIDTH values carried by this module.
BIN_INDEX_WIDTHpositive16Sets the bit width for BIN INDEX WIDTH values carried by this module.
AXI_ADDR_WIDTHpositive8Sets the bit width for AXI ADDR WIDTH values carried by this module.
AXI_DATA_WIDTHpositive32Sets the bit width for AXI DATA WIDTH values carried by this module.
DEFAULT_FRAME_BINSpositive1024Configures DEFAULT FRAME BINS for this instance.

Ports

NameDirectionTypeDescription
m_axis_tvalidoutstd_logicOutput AXI-stream valid qualifier for the current result beat.
m_axis_treadyinstd_logicOutput AXI-stream ready input from the downstream block.
m_axis_tdataoutstd_logic_vector(HASH_WIDTH + 64 - 1 downto 0)Output AXI-stream payload containing packed processed result lanes.
m_axis_tlastoutstd_logicOutput AXI-stream frame marker aligned with the processed result beat.
s_axis_tvalidinstd_logicInput AXI-stream valid qualifier for the current sample beat.
s_axis_treadyoutstd_logicInput AXI-stream ready response indicating this block can accept a beat.
s_axis_tdatainstd_logic_vector((2 * FFT_DATA_WIDTH) - 1 downto 0)Input AXI-stream payload containing packed sample or feature lanes.
s_axis_tlastinstd_logicInput AXI-stream frame marker for the final beat of a frame.
s_axi_awaddrinstd_logic_vector(AXI_ADDR_WIDTH - 1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_awprotinstd_logic_vector(2 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_awvalidinstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_awreadyoutstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_wdatainstd_logic_vector(AXI_DATA_WIDTH - 1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_wstrbinstd_logic_vector((AXI_DATA_WIDTH / 8) - 1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_wvalidinstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_wreadyoutstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_brespoutstd_logic_vector(1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_bvalidoutstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_breadyinstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_araddrinstd_logic_vector(AXI_ADDR_WIDTH - 1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_arprotinstd_logic_vector(2 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_arvalidinstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_arreadyoutstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_rdataoutstd_logic_vector(AXI_DATA_WIDTH - 1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_rrespoutstd_logic_vector(1 downto 0)AXI4-Lite slave-channel signal used for host register access.
s_axi_rvalidoutstd_logicAXI4-Lite slave-channel signal used for host register access.
s_axi_rreadyinstd_logicAXI4-Lite slave-channel signal used for host register access.
clkinstd_logicClock for the associated synchronous logic and handshake domain.
rstinstd_logicActive-high synchronous reset for this clock domain.

Register Interfaces

Static register maps are rendered below for this module.

InterfaceDirectionsSignalsRepresentative ports
M_AXISin, out4m_axis_tvalid, m_axis_tready, m_axis_tdata, m_axis_tlast
S_AXIin, out19s_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_AXISin, out4s_axis_tvalid, s_axis_tready, s_axis_tdata, s_axis_tlast

Register Maps

raddsp_axis_fft_fingerprint_inferred

Source: dsp/hdl/raddsp/src/raddsp_axis_fft_fingerprint.vhd

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.

RegisterOffsetAccessResetDescription
ctrl0x00rwControl register used to configure and control this block.
frame_bins0x04rwConfiguration or measurement register used by the software-visible control interface.
bin_offset0x08rwRegister inferred from the module's VHDL register constant declarations.
bin_stride0x0CrwConfiguration or measurement register used by the software-visible control interface.
mag_shift0x10rwConfiguration or measurement register used by the software-visible control interface.
hash_seed_lo0x14rwData or comparison value register used by the software-visible control interface.
hash_seed_hi0x18rwData or comparison value register used by the software-visible control interface.
status0x1CrwStatus register exposing current hardware state and latched conditions.
last_hash_lo0x20rwData or comparison value register used by the software-visible control interface.
last_hash_hi0x24rwData or comparison value register used by the software-visible control interface.
last_peak_bin0x28rwRegister inferred from the module's VHDL register constant declarations.
last_peak_mag0x2CrwRegister inferred from the module's VHDL register constant declarations.
last_selected0x30rwData or comparison value register used by the software-visible control interface.
frame_count0x34rwConfiguration or measurement register used by the software-visible control interface.
pair_gap0x38rwConfiguration or measurement register used by the software-visible control interface.
last_delta0x3CrwConfiguration or measurement register used by the software-visible control interface.

ctrl

Offset 0x00 / Access rw

Control register used to configure and control this block.

Ctrl[15:0]
1514131211109876543210
VALUE [15:0]
Ctrl[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUECtrl[31:0]Full register value.

frame_bins

Offset 0x04 / Access rw

Configuration or measurement register used by the software-visible control interface.

FrameBins[15:0]
1514131211109876543210
VALUE [15:0]
FrameBins[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEFrameBins[31:0]Full register value.

bin_offset

Offset 0x08 / Access rw

Register inferred from the module's VHDL register constant declarations.

BinOffset[15:0]
1514131211109876543210
VALUE [15:0]
BinOffset[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEBinOffset[31:0]Full register value.

bin_stride

Offset 0x0C / Access rw

Configuration or measurement register used by the software-visible control interface.

BinStride[15:0]
1514131211109876543210
VALUE [15:0]
BinStride[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEBinStride[31:0]Full register value.

mag_shift

Offset 0x10 / Access rw

Configuration or measurement register used by the software-visible control interface.

MagShift[15:0]
1514131211109876543210
VALUE [15:0]
MagShift[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEMagShift[31:0]Full register value.

hash_seed_lo

Offset 0x14 / Access rw

Data or comparison value register used by the software-visible control interface.

HashSeedLo[15:0]
1514131211109876543210
VALUE [15:0]
HashSeedLo[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEHashSeedLo[31:0]Full register value.

hash_seed_hi

Offset 0x18 / Access rw

Data or comparison value register used by the software-visible control interface.

HashSeedHi[15:0]
1514131211109876543210
VALUE [15:0]
HashSeedHi[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEHashSeedHi[31:0]Full register value.

status

Offset 0x1C / Access rw

Status register exposing current hardware state and latched conditions.

Status[15:0]
1514131211109876543210
VALUE [15:0]
Status[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEStatus[31:0]Full register value.

last_hash_lo

Offset 0x20 / Access rw

Data or comparison value register used by the software-visible control interface.

LastHashLo[15:0]
1514131211109876543210
VALUE [15:0]
LastHashLo[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastHashLo[31:0]Full register value.

last_hash_hi

Offset 0x24 / Access rw

Data or comparison value register used by the software-visible control interface.

LastHashHi[15:0]
1514131211109876543210
VALUE [15:0]
LastHashHi[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastHashHi[31:0]Full register value.

last_peak_bin

Offset 0x28 / Access rw

Register inferred from the module's VHDL register constant declarations.

LastPeakBin[15:0]
1514131211109876543210
VALUE [15:0]
LastPeakBin[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastPeakBin[31:0]Full register value.

last_peak_mag

Offset 0x2C / Access rw

Register inferred from the module's VHDL register constant declarations.

LastPeakMag[15:0]
1514131211109876543210
VALUE [15:0]
LastPeakMag[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastPeakMag[31:0]Full register value.

last_selected

Offset 0x30 / Access rw

Data or comparison value register used by the software-visible control interface.

LastSelected[15:0]
1514131211109876543210
VALUE [15:0]
LastSelected[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastSelected[31:0]Full register value.

frame_count

Offset 0x34 / Access rw

Configuration or measurement register used by the software-visible control interface.

FrameCount[15:0]
1514131211109876543210
VALUE [15:0]
FrameCount[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEFrameCount[31:0]Full register value.

pair_gap

Offset 0x38 / Access rw

Configuration or measurement register used by the software-visible control interface.

PairGap[15:0]
1514131211109876543210
VALUE [15:0]
PairGap[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUEPairGap[31:0]Full register value.

last_delta

Offset 0x3C / Access rw

Configuration or measurement register used by the software-visible control interface.

LastDelta[15:0]
1514131211109876543210
VALUE [15:0]
LastDelta[31:16]
31302928272625242322212019181716
VALUE [31:16]
NameRegister bit(s)Description
VALUELastDelta[31:0]Full register value.

Testbenches

tb_raddsp_axis_fingerprint interface timing diagram

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint.vhd

Self-checking or stimulus-focused testbench for axis fingerprint. Exercises representative handshakes, reset behavior, frame boundaries, and numeric corner cases for regression runs.

Interface Timing Diagram

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint.vhd

clk
rst
M_AXIS
S_AXI
S_AXIS
M_AXIS interface signals

M_AXIS Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint.vhd

m_axis_tlast
m_axis_tready
m_axis_tvalid
m_axis_tdata
S_AXI interface signals

S_AXI Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint.vhd

s_axi_arready
s_axi_arvalid
s_axi_awready
s_axi_awvalid
s_axi_bready
s_axi_bvalid
s_axi_rready
s_axi_rvalid
s_axi_wready
s_axi_wvalid
s_axi_araddr
s_axi_awaddr
s_axi_rdata
s_axi_wdata
s_axi_arprot
s_axi_awprot
s_axi_bresp
s_axi_rresp
s_axi_wstrb
S_AXIS interface signals

S_AXIS Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint.vhd

s_axis_tlast
s_axis_tready
s_axis_tvalid
s_axis_tdata
tb_raddsp_axis_fingerprint_audio interface timing diagram

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint_audio.vhd

Self-checking or stimulus-focused testbench for axis fingerprint audio. Exercises representative handshakes, reset behavior, frame boundaries, and numeric corner cases for regression runs.

Interface Timing Diagram

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint_audio.vhd

clk
rst
M_AXIS
S_AXI
S_AXIS
M_AXIS interface signals

M_AXIS Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint_audio.vhd

m_axis_tlast
m_axis_tready
m_axis_tvalid
m_axis_tdata
S_AXI interface signals

S_AXI Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint_audio.vhd

s_axi_arready
s_axi_arvalid
s_axi_awready
s_axi_awvalid
s_axi_bready
s_axi_bvalid
s_axi_rready
s_axi_rvalid
s_axi_wready
s_axi_wvalid
s_axi_araddr
s_axi_awaddr
s_axi_rdata
s_axi_wdata
s_axi_arprot
s_axi_awprot
s_axi_bresp
s_axi_rresp
s_axi_wstrb
S_AXIS interface signals

S_AXIS Interface Waveform

Source: dsp/hdl/testbenches/tb_raddsp_axis_fingerprint_audio.vhd

s_axis_tlast
s_axis_tready
s_axis_tvalid
s_axis_tdata

Sources