This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

OSPI_norFlashWrite( )



Hi,

I'm using am2432ALV CPU with GD25q64e qspi flash device.

I can read and erase the device using  OSPI_norFlashRead(..  and   OSPI_norFlashErase(..

but I cannot write page here is my function:

void FlashWrite(uint32_t Address)
{
 NorSpi_SfdpGenericDefines gNorSpiDevDefines; 
OSPI_Handle ospiHandle = OSPI_getHandle(CONFIG_OSPI0);
 memset(&gNorSpiDevDefines, 0, sizeof(gNorSpiDevDefines));
 OSPI_clearDualOpCodeMode(ospiHandle);
 OSPI_norFlashSetCmds(0x6B, 0x32, 0xD8);
 OSPI_setProtocol(ospiHandle, OSPI_NOR_PROTOCOL(1,1,4,0));

 uint8_t buf[256]={0x17};
 OSPI_norFlashWrite(ospiHandle, ul_block_num, buf,250);
}//FlashWrite

tried using

OSPI_norFlashSetCmds(0x03, 0x02, 0xD8);
OSPI_norFlashInit1s1s1s(...); 

but stil OSPI_norFlashWrite(.. returnes -1

What am I missing here ?

Thanks,

Eli