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: 
Observer ppc_mp
Observer
7,334 Views
Registered: ‎09-27-2013

Difficulties using EMIO

Jump to solution

Hello.

I'm working on a custom lab board with a xa7z020-1i.

Using examples, I've created a project for the zc702 and through EMIO controlled one of the LEDs connected to PL-pins. When I try control one LED on the custom board in the same way as on the zc702, there is no output from the PL-pins.

 

I use almost the same Vivado (2013.3)  project for both boards and exactly the same software.

The projects are designed in this way:

Block design with one PS with EMIO GPIO selected with a width of 1. The output signal in the resulting GPIO interface is made to an port. 

Constraints are created for the port with suitable voltage and package pin.

Bitstream generated and all exported to SDK.

 

The software looks like this:

#define EMIO_54 	54
#define LED_DELAY 	200000000

static XGpioPs mio_emio_pmod2;

int main()
{
	XGpioPs_Config *ConfigPtrPS;
	int Delay;
	init_platform();


	ConfigPtrPS = XGpioPs_LookupConfig(0);
	XGpioPs_CfgInitialize(&mio_emio_pmod2, ConfigPtrPS, ConfigPtrPS->BaseAddr);

	XGpioPs_SetDirectionPin(&mio_emio_pmod2, EMIO_54, 1);
	XGpioPs_SetOutputEnablePin(&mio_emio_pmod2, EMIO_54, 1);

	while(1)
	{
		XGpioPs_WritePin(&mio_emio_pmod2, EMIO_54, 0x0);
		for (Delay = 0; Delay < LED_DELAY; Delay++);
		XGpioPs_WritePin(&mio_emio_pmod2, EMIO_54, 0x1);
		for (Delay = 0; Delay < LED_DELAY; Delay++);
	}

	return 0;
}

It works fine on zc702 but not on the custom board. There is no problem controlling the LEDs using an AXI GPIO ip, so there is no obvious HW problem with the LEDs.

I've tried using SPI through EMIO but it seemed as if there was no output there either.

 

What could be wrong and where should  I look?

0 Kudos
1 Solution

Accepted Solutions
Observer ppc_mp
Observer
9,556 Views
Registered: ‎09-27-2013

Re: Difficulties using EMIO

Jump to solution

I eventually found a solution for the problem in my original post.

 

If an AXI-component  was included in the fpga in the Vivado project everything worked fine. It seems that there was some issue with using EMIO with a "empty" (but programmed) fpga.

0 Kudos
7 Replies
Observer saurabhnair
Observer
7,187 Views
Registered: ‎11-12-2013

Re: Difficulties using EMIO

Jump to solution
Hello ppc_mc,

I'm having trouble sending data via EMIO in the ZC702 board. Can you please guide me on how you had performed interfacing using EMIO.

I'm trying to send 32 bit data through EMIO to FMC LPC connector pins.

Waiting for your reply,
Thanks

Saurabh
0 Kudos
Observer saurabhnair
Observer
7,172 Views
Registered: ‎11-12-2013

Re: Difficulties using EMIO

Jump to solution
Sorry for the error in writing your user name ppc_mp
0 Kudos
Observer ppc_mp
Observer
7,166 Views
Registered: ‎09-27-2013

Re: Difficulties using EMIO

Jump to solution

Hi.

I'm not sure what you are asking but I began with reading chapter 2 in UG873 and looking at the training labs.

I guess you could use GPIO and route it through the FPGA using EMIO.

0 Kudos
Observer ppc_mp
Observer
9,557 Views
Registered: ‎09-27-2013

Re: Difficulties using EMIO

Jump to solution

I eventually found a solution for the problem in my original post.

 

If an AXI-component  was included in the fpga in the Vivado project everything worked fine. It seems that there was some issue with using EMIO with a "empty" (but programmed) fpga.

0 Kudos
Highlighted
Observer saurabhnair
Observer
7,154 Views
Registered: ‎11-12-2013

Re: Difficulties using EMIO

Jump to solution

As in the Zynq ctt pdf, I had selected GPIO EMIO, set its width as 32, and made it external port.

 

In the ucf, I gave the location of the LPC FMC connector pins to them.

 

I set GPIO bank 2 as output and the data I receive from CAN interface communication is written to GPIO bank 2.

 

Yet, I receive no data on the LPC FMC connector pins.

 

CAN communication works fine, no doubt about it. But not so sure about EMIO. Maybe you could guide me as to where I could be going wrong.

 

I'm not using any IPs or hardware on the PL side. I'm working on Xilinx PlanAhead.

 

Waiting for your reply and advice/suggestions.

 

Thanks

Saurabh

0 Kudos
Observer ppc_mp
Observer
7,149 Views
Registered: ‎09-27-2013

Re: Difficulties using EMIO

Jump to solution

I had problems when I had no IPs at all in the fpga. The solution was to add an AXI-GPIO IP in the fpga and connect it to a LED on the board. That was sufficient for EMIO to start working.

So my suggestion is that you add some IP to the fpga.

 

 

Observer saurabhnair
Observer
7,118 Views
Registered: ‎11-12-2013

Re: Difficulties using EMIO

Jump to solution

Thanks for the suggestion ppc_mp. I tried using GPIO EMIO the way you had said and it worked. It also worked without using the IP, by creating an .mcs file, using the fsbl, system.bit and .elf file of the code.

 

Till now I had just sent the data to hardware pins, through EMIO without any processing. But if instead of directly sending EMIO data to hardware, I want to process that data in the PL logic and then send the result to hardware, what should be the way forward?

 

I am trying by simply assigning the data in EMIO to the ports defined in VHDL and providing the ucf only for the port in VHDL and not for EMIO. It synthesizes and implements but always gives error in BitGen.

 

Any suggestions regarding it would be great.

 

Thanks

Saurabh

0 Kudos