/* Initializes an SRAM buffer for the IOS FIFO. 
The recommended buffer size for the IOS FIFO is 1024 bytes. */
void am_hal_ios_fifo_buffer_init(uint8_t *pui8Buffer, uint32_t ui32NumBytes)
/* Initializes an SRAM buffer for the IOS FIFO. 
The recommended buffer size for the IOS FIFO is 1024 bytes. */
void am_hal_ios_fifo_buffer_init(uint8_t *pui8Buffer, uint32_t ui32NumBytes)
{
    if ( ui32NumBytes > (1023 - g_ui32HwFifoSize + 1) )
    {
        ui32NumBytes = (1023 - g_ui32HwFifoSize + 1);
    }
    am_hal_ios_buffer_init(&g_sSRAMBuffer, pui8Buffer, ui32NumBytes);
    AM_BFW(IOSLAVE, FIFOCTR, FIFOCTR, 0x0);
    AM_BFW(IOSLAVE, FIFOPTR, FIFOSIZ, 0x0);
    am_hal_ios_fifo_ptr_set(g_ui32FifoBaseOffset);
}