/*****************************************************************************
* Filename:          C:\Users\tseng\Desktop\edk_test\MBZ-509-SMP\drivers/fsl_index_v1_00_a/src/fsl_index_selftest.c
* Version:           1.00.a
* Description:       
* Date:              Fri Sep 27 13:00:03 2013 (by Create and Import Peripheral Wizard)
*****************************************************************************/

#include "xparameters.h"
#include "fsl_index.h"

/* IMPORTANT:
*  In order to run this self test, you need to modify the value of following
*  micros according to the slot ID defined in xparameters.h file. 
*/
#define input_slot_id   XPAR_FSL_FSL_INDEX_0_INPUT_SLOT_ID
#define output_slot_id  XPAR_FSL_FSL_INDEX_0_OUTPUT_SLOT_ID

XStatus FSL_INDEX_SelfTest()
{
	 unsigned int input_0[1];     
	 unsigned int output_0[1];     

	 //Initialize your input data over here: 
	 input_0[0] = 12345;     

	 //Call the macro with instance specific slot IDs
	 fsl_index(
		 input_slot_id,
		 output_slot_id,
		 input_0,      
		 output_0       
		 );

	 if (output_0[0] != 12345)
		 return XST_FAILURE;
	 if (output_0[0] != 12345)
		 return XST_FAILURE;

	 return XST_SUCCESS;
}
