XilinxProcessorIPLib/drivers/mbox/examples/xmbox_tapp_example.c
static int MailboxExample_Send(XMbox *MboxInstancePtr, int CPU_Id)
{
	int Status;
	u32 Nbytes;
	u32 BytesSent;

	Nbytes = 0;

	while (Nbytes != HELLO_SIZE) {
		/* Write a message to the mbox */
		Status = XMbox_Write(MboxInstancePtr,
					(u32 *)((u8 *)ProducerHello + Nbytes),
					HELLO_SIZE - Nbytes,
					&BytesSent);

		if (Status == XST_SUCCESS)
			Nbytes += BytesSent;
	}

	return XST_SUCCESS;
}
/*****************************************************************************/
/**
*
* This function sends the hello message to the other processor.
*
* @param	MboxInstancePtr is the instance pointer for the XMbox.
* @param	CPU_Id is the CPU ID for the program that is running on.
*
* @return	- XST_SUCCESS if the send succeeds.
*		- XST_FAILURE if the send fails.
*
* @note		None.
*
******************************************************************************/
This function sends the hello message to the other processor.
This function sends the hello message to the other processor .
static int MailboxExample_Send(XMbox *MboxInstancePtr, int CPU_Id)
{
	int Status;
	u32 Nbytes;
	u32 BytesSent;
	Nbytes = 0;
	while (Nbytes != HELLO_SIZE) {
		Status = XMbox_Write(MboxInstancePtr,
					(u32 *)((u8 *)ProducerHello + Nbytes),
					HELLO_SIZE - Nbytes,
					&BytesSent);
		if (Status == XST_SUCCESS)
			Nbytes += BytesSent;
	}
	return XST_SUCCESS;
}
static int MailboxExample_Send ( XMbox * MboxInstancePtr , int CPU_Id ) { int Status ; u32 Nbytes ; u32 BytesSent ; Nbytes = 0 ; while ( Nbytes != HELLO_SIZE ) { Status = XMbox_Write ( MboxInstancePtr , ( u32 * ) ( ( u8 * ) ProducerHello + Nbytes ) , HELLO_SIZE - Nbytes , & BytesSent ) ; if ( Status == XST_SUCCESS ) Nbytes += BytesSent ; } return XST_SUCCESS ; }
This function sends the hello message to the other processor.
This function sends the hello message to the other processor .
/* Write a message to the mbox */