jtag2axi

Generate single-beat AXI4 transactions from JTAG scan-chain inputs.

All scan chains share one shift register, captured and shifted on rising TCK, and one update latch loaded on falling TCK; series reads and writes pipeline. AXISeriesCtrl.pipeline_depth programs 0..FIFO_DEPTH, larger values saturate, and the effective depth is pipeline_depth + 1. Every transaction carries ID 0, user 0, one INCR beat, AxCACHE 0b0010 and AxPROT 0b000. A scanned size wider than the bus is taken as one full beat: AxSIZE, the series write strobes, the series address step and the series data length all use the bus width.

The following logic lives in the TCK domain:

  • TAP scan
  • command dispatch
  • AXI master FSM
  • series request/response FIFOs
  • sticky status

The AXI master crosses into ACLK through one axi_cdc_clearable instance. A reset on either trst_ni or arst_ni runs its isolate-and-clear sequence on both sides. An ACLK-domain output stage buffers AW, W and AR, issues AW and W only as a pair, bounds outstanding transactions, and drains responses to requests issued before a CDC clear. When the clear reaches the TCK side, the bridge aborts every operation in flight or queued: the FSM returns to idle and holds there until the clear completes, the series FIFOs and pipeline accounting are flushed, and the status that reports an aborted operation reads DECERR. The sticky series status takes DECERR only while it holds no earlier error. Every other status, and the SERIES_CTRL configuration, is kept.

Parameter constraints:

  • Address and data widths are parametrizable; DATA_WIDTH must be a power of 2 and a multiple of 8.
  • ATOP_WIDTH must be 6 to match the PULP AXI channel typedef layout.
  • ADDR_WIDTH must cover the byte offset within one data beat.

Parameters

Table 1. Parameters
NameTypeDefaultDescription
ADDR_WIDTHint52Address width.
DATA_WIDTHint64Width of AXI read and write data and of the scan-chain data fields; a power of 2 from 8 to 1024.
ID_WIDTHint1AXI ID width; IDs are always driven zero.
USER_WIDTHint1AXI user width; user fields are always driven zero.
FIFO_DEPTHint2Largest programmable AXISeriesCtrl.pipeline_depth; the series request FIFO holds FIFO_DEPTH + 1 entries.
ATOP_WIDTHint6AWATOP width; must be 6 for PULP AXI typedefs.

Ports

Table 2. Ports
NameDirectionTypeDescription
tck_iinputlogicJTAG Test Clock.
trst_niinputlogicJTAG Test Reset (active low); resets all TCK-domain state and the CDC source side.
scan_in_iinputlogicJTAG Scan Data In (TDI).
scan_out_ooutputlogicJTAG Scan Data Out (TDO), bit 0 of the shared shift register.
capture_en_iinputlogicJTAG Capture Enable (Capture-DR state).
shift_en_iinputlogicJTAG Shift Enable (Shift-DR state).
update_en_iinputlogicJTAG Update Enable (Update-DR state).
select_AXISingleOp_iinputlogicSelect AXISingleOp scan chain.
select_AXISeriesCtrl_iinputlogicSelect AXISeriesCtrl scan chain.
select_AXISeriesDataIncr_iinputlogicSelect AXISeriesDataIncr scan chain.
select_AXISeriesDataNoIncr_iinputlogicSelect AXISeriesDataNoIncr scan chain.
select_AXISeriesDataWithErrorStatus_iinputlogicSelect AXISeriesDataWithErrorStatus scan chain.
security_disable_iinputlogicActive-high bridge disable: blocks Update-DR, keeps the AXI FSM idle, and flushes queued requests once the FSM is idle.
aclk_iinputlogicAXI Clock.
arst_niinputlogicAXI Reset (active low), for the CDC destination side and the ACLK output stage.
test_en_iinputlogicDFT test-mode enable, active-high, for the ACLK output stage fall-through registers.
awid_ooutputlogic [ID_WIDTH-1:0]Write-address ID, always zero.
awaddr_ooutputlogic [ADDR_WIDTH-1:0]Write address.
awlen_ooutputlogic [7:0]Write burst length, always zero for a single beat.
awsize_ooutputlogic [2:0]Write beat size: the scanned size, at most the bus width.
awburst_ooutputlogic [1:0]Write burst type, always INCR.
awlock_ooutputlogicWrite lock, always zero.
awcache_ooutputlogic [3:0]Write cache attributes, always 0b0010.
awprot_ooutputlogic [2:0]Write protection attributes, always 0b000.
awqos_ooutputlogic [3:0]Write QoS, always zero.
awregion_ooutputlogic [3:0]Write region, always zero.
awuser_ooutputlogic [USER_WIDTH-1:0]Write-address user, always zero.
awatop_ooutputlogic [ATOP_WIDTH-1:0]Write atomic op (AWATOP), always zero.
awvalid_ooutputlogicWrite-address valid.
awready_iinputlogicWrite-address ready.
wdata_ooutputlogic [DATA_WIDTH-1:0]Write data.
wstrb_ooutputlogic [DATA_WIDTH/8-1:0]Write strobes.
wlast_ooutputlogicWrite last, always high for the single beat.
wuser_ooutputlogic [USER_WIDTH-1:0]Write-data user, always zero.
wvalid_ooutputlogicWrite-data valid.
wready_iinputlogicWrite-data ready.
bid_iinputlogic [ID_WIDTH-1:0]Write-response ID.
bresp_iinputlogic [1:0]Write-response status.
buser_iinputlogic [USER_WIDTH-1:0]Write-response user.
bvalid_iinputlogicWrite-response valid.
bready_ooutputlogicWrite-response ready.
arid_ooutputlogic [ID_WIDTH-1:0]Read-address ID, always zero.
araddr_ooutputlogic [ADDR_WIDTH-1:0]Read address.
arlen_ooutputlogic [7:0]Read burst length, always zero for a single beat.
arsize_ooutputlogic [2:0]Read beat size: the scanned size, at most the bus width.
arburst_ooutputlogic [1:0]Read burst type, always INCR.
arlock_ooutputlogicRead lock, always zero.
arcache_ooutputlogic [3:0]Read cache attributes, always 0b0010.
arprot_ooutputlogic [2:0]Read protection attributes, always 0b000.
arqos_ooutputlogic [3:0]Read QoS, always zero.
arregion_ooutputlogic [3:0]Read region, always zero.
aruser_ooutputlogic [USER_WIDTH-1:0]Read-address user, always zero.
arvalid_ooutputlogicRead-address valid.
arready_iinputlogicRead-address ready.
rid_iinputlogic [ID_WIDTH-1:0]Read-data ID.
rdata_iinputlogic [DATA_WIDTH-1:0]Read data.
rresp_iinputlogic [1:0]Read-response status.
rlast_iinputlogicRead last.
ruser_iinputlogic [USER_WIDTH-1:0]Read-data user.
rvalid_iinputlogicRead-data valid.
rready_ooutputlogicRead-data ready.