• 0
doragasu

Zybo getting started: SDK fails building BSP

Question

I'm trying to follow this getting started tutorial for the Zybo board. I'm using Linux OS, and initially I started with Vivado 2015.4, but updated to 2016.2 when the problem appeared. The update didn't fix the problem.

When following the tutorial, everything goes as expected until I reach step 9.4: when I create the new application project with the hello world example, the generated BSP files have 32 errors, so the project cannot build. I googled the error, and found tons of forum posts with similar problems. It looks like most of the times the problems disappear if you launch SDK from the OS menu, instead of doing it from Vivado. But that didn't fix the problem for me.

I have attached a capture showing the errors.

How can I fix this problem?

2016-06-15_13:39:53_1146x820.png

Share this post


Link to post
Share on other sites

6 answers to this question

Recommended Posts

  • 0

I have been digging a bit more, and it looks like these 32 errors are caused by a single line of code in the generated BSP code, in the file ps7_cortexa9_0/libsrc/standalone_v5_5/src/outbyte.c. Line 14 calls XUartPs_SendByte:

void outbyte(char c) {
	 XUartPs_SendByte(STDOUT_BASEADDRESS, c);
}

And this causes an unresolved external when linking:

Invoking: ARM v7 gcc linker
arm-none-eabi-gcc -mcpu=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard -Wl,-build-id=none -specs=Xilinx.spec -Wl,-T -Wl,../src/lscript.ld -L../../ZYBO_getting_started_bsp/ps7_cortexa9_0/lib -o "ZYBO_getting_started.elf"  ./src/helloworld.o ./src/platform.o   -Wl,--start-group,-lxil,-lgcc,-lc,--end-group
../../ZYBO_getting_started_bsp/ps7_cortexa9_0/lib/libxil.a(outbyte.o): In function `outbyte':
outbyte.c:(.text+0xc): undefined reference to `XUartPs_SendByte'
collect2: error: ld returned 1 exit status
make: *** [makefile:41: ZYBO_getting_started.elf] Error 1

If I comment out this line, the project builds and I can turn on/off the leds using the switches as expected. But of course I loose xil_printf functions :(

Am I missing something? Maybe I need to supply my own XUartPs_SendByte() function and it is ommited on the tutorial?

Also, googling "XUartPs_SendByte" shows no results... Am I the only one in the world with this problem?

Share this post


Link to post
Share on other sites
  • 0

A bit more information: I have opened my project on a Windows PC running Vivado 2016.2, and it builds without errors!

It looks like XUartPs_SendByte() function is undefined only when using a Linux host. How can I make it work on Linux?

Share this post


Link to post
Share on other sites
  • 0

Hi doragasu,

I have asked some of our applications engineers about this; they will get back to you here on the forum.

Thanks,
JColvin

Share this post


Link to post
Share on other sites
  • 0

Hi, thanks for help! I'm running latest ArchLinux (kernel 4.5.4).

Although I know ArchLinux is not one of the officially supported Linux distributions, I hope it's possible to make it work.

Share this post


Link to post
Share on other sites
  • 0

Hi doragasu,

Unfortunately we do not have experience with running the Xilinx Suite in ArchLinux. I would suggest to either look into using a supported distro like red hat or ubuntu or to reach out to Xilinx about XUartPs_SendByte() function.

thank you,

Jon    

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now