lib/sw_services/xilisf/examples/xilisf_qspips_stm_intr_example.c
int FlashWrite(XIsf *InstancePtr, u32 Address, u32 ByteCount, u8 Command)
{
	XIsf_WriteParam WriteParam;

	int Status = XST_FAILURE;

	WriteParam.Address = Address;
	WriteParam.NumBytes = ByteCount;
	WriteParam.WritePtr = WriteBuffer;
	/*
	 * Perform the Write operation.
	 */
	TransferInProgress = TRUE;
	Status = XIsf_Write(&Isf, Command, (void*) &WriteParam);
	if(Status != XST_SUCCESS) {
		return XST_FAILURE;
	}

	/*
	 * Wait till the Transfer is complete and check if there are any errors
	 * in the transaction.
	 */
	while(TransferInProgress);
	if(ErrorCount != 0) {
		return XST_FAILURE;
	}

	return XST_SUCCESS;
}
/*****************************************************************************/
/**
*
* This function writes to the  serial FLASH connected to the QSPI interface.
* The FLASH contains a 256 byte write buffer which can be filled and then a
* write is automatically performed by the device.  All the data put into the
* buffer must be in the same page of the device with page boundaries being on
* 256 byte boundaries.
*
* @param	InstancePtr is a pointer to the XIsf component to use.
* @param	Address contains the address to write data to in the FLASH.
* @param	ByteCount contains the number of bytes to write.
* @param	Command is the command used to write data to the flash.
*
* @return	None.
*
* @note		None.
*
******************************************************************************/
This function writes to the  serial FLASH connected to the QSPI interface.
The FLASH contains a 256 byte write buffer which can be filled and then a
write is automatically performed by the device.  All the data put into the
buffer must be in the same page of the device with page boundaries being on
256 byte boundaries.
This function writes to the serial FLASH connected to the QSPI interface . The FLASH contains a 256 byte write buffer which can be filled and then a write is automatically performed by the device . All the data put into the buffer must be in the same page of the device with page boundaries being on 256 byte boundaries .
int FlashWrite(XIsf *InstancePtr, u32 Address, u32 ByteCount, u8 Command)
{
	XIsf_WriteParam WriteParam;
	int Status = XST_FAILURE;
	WriteParam.Address = Address;
	WriteParam.NumBytes = ByteCount;
	WriteParam.WritePtr = WriteBuffer;
	TransferInProgress = TRUE;
	Status = XIsf_Write(&Isf, Command, (void*) &WriteParam);
	if(Status != XST_SUCCESS) {
		return XST_FAILURE;
	}
	while(TransferInProgress);
	if(ErrorCount != 0) {
		return XST_FAILURE;
	}
	return XST_SUCCESS;
}
int FlashWrite ( XIsf * InstancePtr , u32 Address , u32 ByteCount , u8 Command ) { XIsf_WriteParam WriteParam ; int Status = XST_FAILURE ; WriteParam . Address = Address ; WriteParam . NumBytes = ByteCount ; WriteParam . WritePtr = WriteBuffer ; TransferInProgress = TRUE ; Status = XIsf_Write ( & Isf , Command , ( void * ) & WriteParam ) ; if ( Status != XST_SUCCESS ) { return XST_FAILURE ; } while ( TransferInProgress ) ; if ( ErrorCount != 0 ) { return XST_FAILURE ; } return XST_SUCCESS ; }
This function writes to the  serial FLASH connected to the QSPI interface.
This function writes to the serial FLASH connected to the QSPI interface .
/*
	 * Perform the Write operation.
	 */ /*
	 * Wait till the Transfer is complete and check if there are any errors
	 * in the transaction.
	 */