Please enable JavaScript to view this site.

Waijung 2 User Guide

Design overview

AXI stream block appearance in a Simulink model,

AXI stream setup block

Poll mode

zynq_7000_axi_stream_block_1

Interrupt mode

zynq_7000_axi_stream_block_4

AXI stream write block

zynq_7000_axi_stream_block_2

AXI stream read block

zynq_7000_axi_stream_block_3

AXI stream block mask overview,

AXI stream setup block

Poll mode

zynq_7000_axi_stream_block_5

Interrupt mode

zynq_7000_axi_stream_block_6

AXI stream write block

zynq_7000_axi_stream_block_7

AXI stream read block

zynq_7000_axi_stream_block_8

AXI Stream block output interfaces,

AXI stream setup block

Name

Type

Range

Description

IRQ

Function-call

 

This will appear when the interrupt mode is enabled. Multiple interrupts are represented with a single Function-call output port. To split it to separate ports, use Demux block in Simulink.

 

AXI stream write block

Name

Type

Range

Description

Status

uint32

 

 

 

Output status of the write transaction.

XST_SUCCESS: 0

XST_FAILURE: 1

XST_INVALID_PARAM: 15

AXI stream read block

Name

Type

Range

Description

Status

uint32

 

 

 

Output status of the write transaction.

XST_SUCCESS: 0

XST_FAILURE: 1

XST_INVALID_PARAM: 15

Data

double

single

int8

uint8

int16

uint16

int32

uint32

Depends on the data type of the Data port

All the data will be output from this port

 

AXI Stream block input interfaces,

AXI stream write block

Name

Type

Range

Description

Data

double

single

int8

uint8

int16

uint16

int32

uint32

Depends on the data type of the Data port

All the data will be output from this port

 

AXI stream block behavior

AXI stream block consists with three modes; Setup , write and read. It uses the Xilinx AXI DMA Driver to setup, write and read the AXI Stream data through the AXI DMA. This should be configured using Vivado Design Suite in the design stage. AXI DMA IP(s) should be added and configure accordingly.

Poll mode

a.Scatter gather mode is not supported. Only the simple mode is supported (disable Scatter Gather mode in AXI DMA IP)

b.The AXI Stream IP should be connected through AXI DMA IP

Interrupt mode

a.Scatter gather mode is not supported. Only the simple mode is supported (disable Scatter Gather mode in AXI DMA IP)

b.The AXI Stream IP should be connected through AXI DMA IP

c.To support interrupt, mm2s_introut and s2mm_introut should be connected to IRQ_F2P interrupt port using the Concat IP. Before that, IRQ_F2P interrupt port should be enabled in the ZYNQ Processing System IP

zynq_7000_axi_stream_block_9

Note: For more information on Vivado designing for AXI Stream through AXI DMA, regenerate the Vivado hardware design project  using the tcl file in [Folder path to waijung2 folder]\targets\zynq7000\demo\axi_stream_demo\hardware_design\vivado_tcl.

The interrupt signal(s) will be directed through Function-call output port. If multiple interrupts are available, those signals should be separated using Demux Simulink block.

AXI stream block configuration

AXI stream setup block

Configuration Parameter

Selectable Option/Value

Default Value

Description

DEVICE ID

XPAR_AXI_DMA_0_DEVICE_ID

XPAR_AXI_DMA_0_DEVICE_ID

Relevant device id of the AXI DMA IP

AXI DMA mode

Simple

Simple

AXI DMA operating mode

Transfer mode

Poll

Interrupt

Poll

Select the transfer mode

Enable interrupts for transmit

on

off

off

Enable AXI DMA transmit interrupts

Transmit done

on

off

off

Enable AXI DMA transmit done interrupt for transmitting data

Error

on

off

off

Enable AXI DMA error interrupt for transmitting data

Enable interrupts for receive

on

off

off

Enable AXI DMA receive interrupts

Receive done

on

off

off

Enable AXI DMA receive done interrupt for receiving data

Error

on

off

off

Enable AXI DMA error interrupt for receiving data

 

AXI stream write block

Configuration Parameter

Selectable Option/Value

Default Value

Description

DEVICE ID

XPAR_AXI_DMA_0_DEVICE_ID

XPAR_AXI_DMA_0_DEVICE_ID

Relevant device id of the AXI DMA IP

Data type

double

single

int8

uint8

int16

uint16

int32

uint32

int8

Write data type

Array size

 

1

Size of the array to be written

Sample time

 

-1

Specify the sample time

 

AXI stream read block

Configuration Parameter

Selectable Option/Value

Default Value

Description

DEVICE ID

XPAR_AXI_DMA_0_DEVICE_ID

XPAR_AXI_DMA_0_DEVICE_ID

Relevant device id of the AXI DMA IP

Data type

double

single

int8

uint8

int16

uint16

int32

uint32

int8

Read data type

Array size

 

1

Size of the array to be read

Sample time

 

-1

Specify the sample time

 

Typical application

Demo file is provided at:

[<waijung2 installation directory>\waijung2\targets\zynq7000\demo\axi_stream_demo]

To load the model file run the following commands in the Matlab Command Window:

Demo 1: waijung2.openDemoInCurrentFolder('zynq7000', 'axi_stream_demo1')

 

Copyright 2023 Aimagin Co.,Ltd. Rev.869