Trenz Electronic GmbH Support Forum

Trenz Electronic Products => Trenz Electronic FPGA Modules => Topic started by: Woody242 on July 07, 2015, 06:50:35 PM

Title: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 07, 2015, 06:50:35 PM
I have created a simple FPGA image with a bare metal application that has a console interface providing dimmer control for D3 and D4 on the 703 carrier module with the TE07020.  This image runs fine when I test with JTAG, it also runs fine when I create an mcs file and program in the QSPI.  I hangs when I try to bppt from the SD card. 

I have successully booted the linux GPIO test image from the SD card so I know that the card is working. 

I generated all SW in the SDK.  Using Version 2014.4.

My boot.bin includes, the FSBL, bitstream and my simple dimmer app.

Any ideas why this might not run.

Thanks,
Woody
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 07, 2015, 06:54:02 PM
Sorry, Just noticed a very similar thread below.  I will try that and see if it addresses my issue.
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 08, 2015, 05:10:52 AM
Applied the changes as documented on the previous thread.

SDIO enabled with all pull-ups disabled.
50 MHz Clock
Verified R43 is DNP on my module
CD/WP EMIO
Power not checked
SD0 set to pins MIO40 through 45

My module still does not boot when using my app but fine with reference Linux FSBL/U-Boot/linux.

What else might I be missing?

Thanks,
Woody
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Antti Lukats on July 08, 2015, 11:59:24 AM
did you check there also:
https://wiki.trenz-electronic.de/display/PD/Zynq+Troubleshooting+Guide
?

FSBL is quiet by default and gives no printout if something is wrong, no matter what is.
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 08, 2015, 02:02:49 PM

I got an Illegal bootmode
Status = 0xA000

Have you seen this before?

Thanks,
Woody
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Antti Lukats on July 08, 2015, 04:29:30 PM
no not that I recall, but we also not always have debug enabled, so it may have happened without us seeing it.

its a hint at least, I can check a bit what the reason could be
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 09, 2015, 04:11:41 AM
Ok so, the SD card must be enabled since I am running the FSBL.  After inspecting the code, I can see where the boot loader is failing and why.

According to the SDK neither of these are defined which disables the SD boot code and this results in falling to the default statement of an illegal boot mode.
It would appear that at least one of these should be enabled when I regenerate my standalone bsp.  Since I did not initially have the SD enabled something must not be in sync.

#if defined(XPAR_PS7_SD_0_S_AXI_BASEADDR) || defined(XPAR_XSDPS_0_BASEADDR)

John
Title: Re: Simple App boots from QSPI but not SD Card TE07020/703
Post by: Woody242 on July 09, 2015, 04:45:18 AM
Got it working, not sure exactly what is going on but one of those two macros was defined.  I added some instrumentation to print the boot mode just to see if it would enter the boot mode for SD if the code was enabled.  When I added that the code started working.  I disabled the instrumentation and it stopped working again.  I did this a couple time and then looking closely at the code tried removing some extra white lines between the else and the if in the conditional for the SD Mode.  Because of the precompiled checks the else does not have a brace so maybe an extra white line was causing this to build wrong. 
I will play with it a bit more but it seems to be working in SD mode and QSPI mode so I think all the board / hardware issues are resolved.


Thanks,
John