UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Explorer
Explorer
879 Views
Registered: ‎02-18-2013

Zybo AXI VDMA doesn´t work

Jump to solution

Hello,

I want to use VGA on my Zybo. So I decide to use the AXI VDMA and the Video Timing Generator. My block diagram looks like this.VGA.png

And my code is this

#include "xaxivdma.h"
#include "xparameters.h"

XAxiVdma* InstancePtr;

int main()
{
	xil_printf("Configure VDMA...\n\r");
	XAxiVdma_Config *Config;

	Config = XAxiVdma_LookupConfig(XPAR_AXI_VDMA_0_DEVICE_ID);
	if (!Config) {
		xil_printf("No video DMA found for ID %d\r\n", XPAR_AXI_VDMA_0_DEVICE_ID);
		return XST_FAILURE;
	}

	/* Initialize DMA engine */
	u32 status = XAxiVdma_CfgInitialize(InstancePtr, Config, Config->BaseAddress);
	if (status != XST_SUCCESS)
	{
		xil_printf("Configuration Initialization failed, status: 0x%X\r\n", status);
		return status;
	}

	xil_printf("Start...\n\r");

	while(1)
	{
	}

	return 0;
}

But this program stucks at this line

u32 status = XAxiVdma_CfgInitialize(InstancePtr, Config, Config->BaseAddress);

So what´s wrong with this?

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
Explorer
Explorer
706 Views
Registered: ‎02-18-2013

Re: Zybo AXI VDMA doesn´t work

Jump to solution

I found the error. The XAxiVdma-Pointer is initialized with NULL, so the Assert in the VDMA-Driver got triggered. I changed it from

XAxiVdma* Pointer;
XAxiVdma_CfgInitialize(Pointer, Config, Config->BaseAddress);

to

XAxiVdma Instance;
XAxiVdma_CfgInitialize(&Instance, Config, Config->BaseAddress);

It works now...

Next step is a VGA image :)

View solution in original post

0 Kudos
5 Replies
Mentor watari
Mentor
820 Views
Registered: ‎06-16-2013

Re: Zybo AXI VDMA doesn´t work

Jump to solution

Hi @kampi 

 

I suggest you to make sure input floating, ex. Intterrupt and Video Timing modules, and the polarity of Reset.

 

Would you try it ?

 

Best regards,

0 Kudos
Moderator
Moderator
779 Views
Registered: ‎11-09-2015

Re: Zybo AXI VDMA doesn´t work

Jump to solution

Hi @kampi ,

I would agree with @watari . The first thing to check is looking at the reset. The IP might be held in reset.

I would also try do debug step by step your application and see exactly when it is failing inside the function XAxiVdma_CfgInitialize.

Also, you might want to check my video series 24 for an example using the VDMA. I am not using the VDMA driver's APIs but you can refer the design as an example.

Regards,


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Explorer
Explorer
741 Views
Registered: ‎02-18-2013

Re: Zybo AXI VDMA doesn´t work

Jump to solution

Hello,

thank you for your answer. I will test it :)

0 Kudos
Explorer
Explorer
707 Views
Registered: ‎02-18-2013

Re: Zybo AXI VDMA doesn´t work

Jump to solution

I found the error. The XAxiVdma-Pointer is initialized with NULL, so the Assert in the VDMA-Driver got triggered. I changed it from

XAxiVdma* Pointer;
XAxiVdma_CfgInitialize(Pointer, Config, Config->BaseAddress);

to

XAxiVdma Instance;
XAxiVdma_CfgInitialize(&Instance, Config, Config->BaseAddress);

It works now...

Next step is a VGA image :)

View solution in original post

0 Kudos
Moderator
Moderator
689 Views
Registered: ‎11-09-2015

Re: Zybo AXI VDMA doesn´t work

Jump to solution

Hi @kampi ,

Good to know that you were able to solve your issue.

Could you kindly mark your previous reply as accepted solution (click on the accepet as solution button while logged in).

Kind Regards,


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos