/* Read available data from the read FIFO, as 32-bit data items. */
unsigned long EPINonBlockingReadGet32(unsigned long ulBase, unsigned long ulCount, unsigned long *pulBuf)
/* Read available data from the read FIFO, as 32-bit data items. */
unsigned long EPINonBlockingReadGet32(unsigned long ulBase, unsigned long ulCount, unsigned long *pulBuf)
{
    unsigned long ulCountRead = 0;
    ASSERT(ulBase == EPI0_BASE);
    ASSERT(ulCount < 4096);
    ASSERT(pulBuf);
    while(HWREG(ulBase + EPI_O_RFIFOCNT) && ulCount--)
    {
        *pulBuf = HWREG(ulBase + EPI_O_READFIFO);
        pulBuf++;
        ulCountRead++;
    }
    return(ulCountRead);
}