keil_examples/USBHostLite/UsbHost/Host/usbhost_lpc17xx.c
/*
**************************************************************************************************************
*                                         READ BE 32U
*
* Description: This function is used to read an unsigned integer from a charecter buffer in the platform
*              containing big endian processor
*
* Arguments  : pmem    Pointer to the charecter buffer
*
* Returns    : val     Unsigned integer
*
**************************************************************************************************************
*/
READ BE 32U
Description: This function is used to read an unsigned integer from a charecter buffer in the platform
containing big endian processor

Arguments  : pmem    Pointer to the charecter buffer

Returns    : val     Unsigned integer
READ BE 32U Description : This function is used to read an unsigned integer from a charecter buffer in the platform containing big endian processor Arguments : pmem Pointer to the charecter buffer Returns : val Unsigned integer
uint32_t  ReadBE32U (volatile  uint8_t  *pmem)
{
    uint32_t   val;
    ((uint8_t *)&val)[0] = pmem[3];
    ((uint8_t *)&val)[1] = pmem[2];
    ((uint8_t *)&val)[2] = pmem[1];
    ((uint8_t *)&val)[3] = pmem[0];
    return (val);
}
uint32_t ReadBE32U ( volatile uint8_t * pmem ) { uint32_t val ; ( ( uint8_t * ) & val ) [ 0 ] = pmem [ 3 ] ; ( ( uint8_t * ) & val ) [ 1 ] = pmem [ 2 ] ; ( ( uint8_t * ) & val ) [ 2 ] = pmem [ 1 ] ; ( ( uint8_t * ) & val ) [ 3 ] = pmem [ 0 ] ; return ( val ) ; }
READ BE 32U
Description: This function is used to read an unsigned integer from a charecter buffer in the platform
containing big endian processor
READ BE 32U Description : This function is used to read an unsigned integer from a charecter buffer in the platform containing big endian processor