QSPI driver with 2 i/o Pins to flash mx25

Hello ,

We are attempting to use the QSPI driver with an MX25 with 2  i/o lines instead of 4, essential SB 10 and 15 on the nrf52840 DK have been cut.  However I am not able to read back data from it that matches the write. Is there something we are missing?

These are the settings we are using:

#ifndef NRFX_QSPI_CONFIG_READOC
#define NRFX_QSPI_CONFIG_READOC 0
#endif

//  NRFX_QSPI_CONFIG_WRITEOC  - Number of data lines and opcode used for writing.
 
// <0=> PP 
// <1=> PP2O 
// <2=> PP4O 
// <3=> PP4IO 

#ifndef NRFX_QSPI_CONFIG_WRITEOC
#define NRFX_QSPI_CONFIG_WRITEOC 0


and changes to init WRSR register values:

    uint8_t temporary = 0x00;
 
    // Switch to qspi mode
    cinstr_cfg.opcode = QSPI_STD_CMD_WRSR;
    cinstr_cfg.length = NRF_QSPI_CINSTR_LEN_2B;
    err_code = nrf_drv_qspi_cinstr_xfer(&cinstr_cfg, &temporary, NULL);
    APP_ERROR_CHECK(err_code);


Thanks,
RJ
  • Hi RJ

    First off, what SDK version are you using in your application? Have you also configured the NRFX_QSPI_CONFIG_READOC config to only use two lines? Is there a specific reason you just want to use two lines for QSPI communication? A lot of the point with a QSPI connection is to use multiple IO lines to transmit more data faster.

    Can you also explain what exactly isn't matching? Is the data you read back looking completely random or just somewhat offset/distorted? I can't see what the issue might be from the snippets you've added here unfortunately.

    Best regards,

    Simon

Related