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: 
Visitor kcar
Visitor
3,103 Views
Registered: ‎08-10-2016

Integrating reference design for eval board to custom target board

Right now I'm working on integrating parts of a reference design from a 7015-based zedboard over to a custom design meant for an in-house board using the same processor. The reference design utilized QSPI, while this new target board only has NAND available. As such, when I export my hardware from Vivado and import into SDK, it doesn't generate the xqspips.h header file in the bsp that the reference design's SW needs to run. This is completely expected since, like I said, the new target board only has NAND and thus my Vivado build for it uses NAND, however that doesn't change the fact that the SW side of the old reference design is written with QSPI in mind. So now I'm faced with porting the reference design code to use NAND instead of QSPI, however I'm not sure of the scope of how involved/feasible this would be. Here is a snippet from the code from the reference design:

 

#include <xqspips.h>
.
.
.
// ---- Video processor interface ----------------------------------------------
// Associated EPC
#define vid ((volatile uint32_t*)(XPAR_EPC_0_PRH2_BASEADDR))
.
.
.
// ---- Quad SPI flash ---------------------------------------------------------
static XQspiPs spi_inst;
.
.
.
// ---- Initialization of CXP device --------------------------------------------
void cxpd_user_init() {
  cxpd_cfg_t cxpd_cfg;
  XQspiPs_Config *spi_cfg;

  // Base addresses of EPC interfaces
  cxpd_cfg.hal_cbt_epc_ba = XPAR_EPC_0_PRH0_BASEADDR;
  cxpd_cfg.hal_bsr_epc_ba = XPAR_EPC_0_PRH1_BASEADDR;

  // CXP Device Library configuration and initialization
  //...//

  // SPI setup
  spi_cfg = XQspiPs_LookupConfig(XPAR_XQSPIPS_0_DEVICE_ID);

Since it can't find the header at the top, the #define and spi_cfg become invalid and the base addr assignment fails. Would switching over to NAND be as simple as changing "XQspiPs_Config *spi_cfg" to "XNandPs_Config *spi_cfg", or are there more underlying configuration/addressing issues that may need attention? Thank you for any insight

 

0 Kudos