/* This function returns the number of samples of averaging configured for all the channels in the Configuration Register 0. */
u8 XAdcPs_GetAvg(XAdcPs *InstancePtr)
/* This function returns the number of samples of averaging configured for all the channels in the Configuration Register 0. */
u8 XAdcPs_GetAvg(XAdcPs *InstancePtr)
{
	u32 Average;
	Xil_AssertNonvoid(InstancePtr != NULL);
	Xil_AssertNonvoid(InstancePtr->IsReady == XIL_COMPONENT_IS_READY);
	Average = XAdcPs_ReadInternalReg(InstancePtr,
			XADCPS_CFR0_OFFSET) & XADCPS_CFR0_AVG_VALID_MASK;
	return ((u8) (Average >> XADCPS_CFR0_AVG_SHIFT));
}