News:

Attention: For security reasons,please choose a user name *different* from your login name.
Also make sure to choose a secure password and change it regularly.

Main Menu

TE0803 + TE0808 SPI causes hang?

Started by johnabel, February 11, 2020, 10:29:29 AM

Previous topic - Next topic

johnabel


I have a TE0803 on a TE0808 and I enabled the SPI0 on MIO26..MIO29. what I notice is when the software boots it only prints:

Xilinx Zynq MP Firs

and hangs. I rebuilt both the hardware and software a number of times and I cannot see the reason. Other similar pieces of bare metal software with only the PS don't cause this problem so I'm starting to think it's because of the SPI enabled. It cannot be the application I guess because that text comes from the FSBL, that is the standard one, no customized.
Is there anything to care about when using the SPI on those pins?

johnabel

Just an update: The MIO lines I plan to use go to the CPLDs on the TEBF0808 that I plan to route them to PD but I haven't changed yet their configuration (so they have the original config for the TEBF0808) - I'm just thinking there could be some kind of clash there...

JH

Hi,
Did you setup DDR correctly?
We provide board part files in 2 variants, one for TEBF0808 and one very simple with DDR QSPI and UART enabled. The simple one is to start with custom board with other MIO configuration
Start with our test board project, which use the simple one. Set correct uart (default it'S configured like on tebf0808 mio)
https://wiki.trenz-electronic.de/display/PD/TE0803+Reference+Designs
  -->https://wiki.trenz-electronic.de/display/PD/TE0803+Test+Board

For TEBF0808 you can also use Starterkit design (put Boot.bin and image.ub from your variant on SD and boot from SD)

br
John

johnabel

It's bare metal, no penguins there. Otherwise, the project is set up for the board and when I drop the Zynq PS on the block diagram I run the 'Block Configuration' to set it up (I've done that for other projects without trouble). In that case, the only tweak was to enable the SPI0

JH

Hi,
what did you connect on SPI0 on MIO26..MIO29?
And does it boot without SPI0 enabled?


br
John

johnabel

#5
I want to route SCK, SS and MOSI to P2 via the CPLD. One of the signals go to the other CPLD but they share signals so I send one of them across both CPLDs (hopefully that works...)
I haven't tried knocking off the SPI - good point!

johnabel

Nope... disabling the SPI0 doesn't fix the problem. Weird. I just tested a similar project (only PS, bare metal, standard FSBL and simple app) and everything is fine. Same board.

JH

Download again the reference design and use prebuilt files. they should work. Maybe you project is corrupted
br
John

johnabel

Yes, cosmic radiation is very bad, always there to provide a reason...
It might as well be, I've seen lots of things with Xilinx. I found this when re-creating the project from and exported TCL so, in theory, it should be fresh.

I created a new vivado project from scratch, set up for the current board, added Zynq PS to a BD, configured with board presets, synthesized, exported to SDK, made a FSBL and a Hello World... no problems.

Now, I dropped my app source files into the project, it fails because they include some SPI header file it can't find because the SPI is not enabled (I didn't know SDK was that pedantically smart)

So I went back to Vivado and enabled SPI0 for MIO26 ... MIO29. Red flag, it clashes with other peripherals, so I disabled all I'm not using (GEM, USB, Display Port, CAN... a good clean up). One of my principles: the simpler, the less space for problems.

Synthesis again and export. SDK detects the hw spec changed. Accepted. After some tweaks, it works... (!?!?!?)

One of those situations embarrassing to explain. Let's say an angry neutron from a faraway galaxy... Thanks for your help, John

JH

QuoteLet's say an angry neutron from a faraway galaxy...
I must remember that.  :-)

PS: Pay attention with hdf/xsa refresh on SDK Project, this can make trouble and you should always clear a builds.  If something is strange, create a new SDK project and import only your applications. In the most cases I create a newSDK project when I change Hardware Definition.

br
John

johnabel

I've bitten by that... The Vivado - SDK interface is randomly flaky. My technique is to have SDK open when re-exporrting hw. If it doesn't warn of the changes... missile launch!