@ -102,171 +102,171 @@
/***********************************************************************
* Macro defines for Macro defines for UARTn Receiver Buffer Register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_RBR_MASKBIT ((u8)0xFF) /* UART Received Buffer mask bit (8 bits) */
# define UART_RBR_MASKBIT ((uint 8_t )0xFF) /* UART Received Buffer mask bit (8 bits) */
/***********************************************************************
* Macro defines for Macro defines for UARTn Transmit Holding Register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_THR_MASKBIT ((u8)0xFF) /* UART Transmit Holding mask bit (8 bits) */
# define UART_THR_MASKBIT ((uint 8_t )0xFF) /* UART Transmit Holding mask bit (8 bits) */
/***********************************************************************
* Macro defines for Macro defines for UARTn Divisor Latch LSB register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_LOAD_DLL(div) ((div) & 0xFF) /* Macro for loading least significant halfs of divisors */
# define UART_DLL_MASKBIT ((u8)0xFF) /* Divisor latch LSB bit mask */
# define UART_DLL_MASKBIT ((uint 8_t )0xFF) /* Divisor latch LSB bit mask */
/***********************************************************************
* Macro defines for Macro defines for UARTn Divisor Latch MSB register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_DLM_MASKBIT ((u8)0xFF) /* Divisor latch MSB bit mask */
# define UART_DLM_MASKBIT ((uint 8_t )0xFF) /* Divisor latch MSB bit mask */
# define UART_LOAD_DLM(div) (((div) >> 8) & 0xFF) /* Macro for loading most significant halfs of divisors */
/***********************************************************************
* Macro defines for Macro defines for UART interrupt enable register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_IER_RBRINT_EN ((u32)(BIT0)) /* RBR Interrupt enable*/
# define UART_IER_THREINT_EN ((u32)(BIT1)) /* THR Interrupt enable*/
# define UART_IER_RLSINT_EN ((u32)(BIT2)) /* RX line status interrupt enable*/
# define UART1_IER_MSINT_EN ((u32)(BIT3)) /* Modem status interrupt enable */
# define UART1_IER_CTSINT_EN ((u32)(BIT7)) /* CTS1 signal transition interrupt enable */
# define UART_IER_ABEOINT_EN ((u32)(BIT8)) /* Enables the end of auto-baud interrupt */
# define UART_IER_ABTOINT_EN ((u32)(BIT9)) /* Enables the auto-baud time-out interrupt */
# define UART_IER_BITMASK ((u32)(0x307)) /* UART interrupt enable register bit mask */
# define UART1_IER_BITMASK ((u32)(0x38F)) /* UART1 interrupt enable register bit mask */
# define UART_IER_RBRINT_EN ((uint 32_t )(BIT0)) /* RBR Interrupt enable*/
# define UART_IER_THREINT_EN ((uint 32_t )(BIT1)) /* THR Interrupt enable*/
# define UART_IER_RLSINT_EN ((uint 32_t )(BIT2)) /* RX line status interrupt enable*/
# define UART1_IER_MSINT_EN ((uint 32_t )(BIT3)) /* Modem status interrupt enable */
# define UART1_IER_CTSINT_EN ((uint 32_t )(BIT7)) /* CTS1 signal transition interrupt enable */
# define UART_IER_ABEOINT_EN ((uint 32_t )(BIT8)) /* Enables the end of auto-baud interrupt */
# define UART_IER_ABTOINT_EN ((uint 32_t )(BIT9)) /* Enables the auto-baud time-out interrupt */
# define UART_IER_BITMASK ((uint 32_t )(0x307)) /* UART interrupt enable register bit mask */
# define UART1_IER_BITMASK ((uint 32_t )(0x38F)) /* UART1 interrupt enable register bit mask */
/**********************************************************************
* Macro defines for Macro defines for UART interrupt identification register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_IIR_INTSTAT_PEND ((u32)(BIT0)) /* Interrupt Status - Active low */
# define UART_IIR_INTID_RDA ((u32)(2<<1)) /* Interrupt identification: Receive data available*/
# define UART_IIR_INTID_RLS ((u32)(3<<1)) /* Interrupt identification: Receive line status*/
# define UART_IIR_INTID_CTI ((u32)(6<<1)) /* Interrupt identification: Character time-out indicator*/
# define UART_IIR_INTID_THRE ((u32)(BIT1)) /* Interrupt identification: THRE interrupt*/
# define UART1_IIR_INTID_MODEM ((u32)(0<<1)) /* Interrupt identification: Modem interrupt*/
# define UART_IIR_INTID_MASK ((u32)(7<<1)) /* Interrupt identification: Interrupt ID mask */
# define UART_IIR_FIFO_EN ((u32)(3<<6)) /* These bits are equivalent to UnFCR[0] */
# define UART_IIR_ABEO_INT ((u32)(BIT8)) /* End of auto-baud interrupt */
# define UART_IIR_ABTO_INT ((u32)(BIT9)) /* Auto-baud time-out interrupt */
# define UART_IIR_BITMASK ((u32)(0x3CF)) /* UART interrupt identification register bit mask */
# define UART_IIR_INTSTAT_PEND ((uint 32_t )(BIT0)) /* Interrupt Status - Active low */
# define UART_IIR_INTID_RDA ((uint 32_t )(2<<1)) /* Interrupt identification: Receive data available*/
# define UART_IIR_INTID_RLS ((uint 32_t )(3<<1)) /* Interrupt identification: Receive line status*/
# define UART_IIR_INTID_CTI ((uint 32_t )(6<<1)) /* Interrupt identification: Character time-out indicator*/
# define UART_IIR_INTID_THRE ((uint 32_t )(BIT1)) /* Interrupt identification: THRE interrupt*/
# define UART1_IIR_INTID_MODEM ((uint 32_t )(0<<1)) /* Interrupt identification: Modem interrupt*/
# define UART_IIR_INTID_MASK ((uint 32_t )(7<<1)) /* Interrupt identification: Interrupt ID mask */
# define UART_IIR_FIFO_EN ((uint 32_t )(3<<6)) /* These bits are equivalent to UnFCR[0] */
# define UART_IIR_ABEO_INT ((uint 32_t )(BIT8)) /* End of auto-baud interrupt */
# define UART_IIR_ABTO_INT ((uint 32_t )(BIT9)) /* Auto-baud time-out interrupt */
# define UART_IIR_BITMASK ((uint 32_t )(0x3CF)) /* UART interrupt identification register bit mask */
/**********************************************************************
* Macro defines for Macro defines for UART FIFO control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_FCR_FIFO_EN ((u8)(BIT0)) /* UART FIFO enable */
# define UART_FCR_RX_RS ((u8)(BIT1)) /* UART FIFO RX reset */
# define UART_FCR_TX_RS ((u8)(BIT2)) /* UART FIFO TX reset */
# define UART_FCR_DMAMODE_SEL ((u8)(BIT3)) /* UART DMA mode selection */
# define UART_FCR_TRG_LEV0 ((u8)(0)) /* UART FIFO trigger level 0: 1 character */
# define UART_FCR_TRG_LEV1 ((u8)(BIT6)) /* UART FIFO trigger level 1: 4 character */
# define UART_FCR_TRG_LEV2 ((u8)(2<<6)) /* UART FIFO trigger level 2: 8 character */
# define UART_FCR_TRG_LEV3 ((u8)(3<<6)) /* UART FIFO trigger level 3: 14 character */
# define UART_FCR_BITMASK ((u8)(0xCF)) /* UART FIFO control bit mask */
# define UART_FCR_FIFO_EN ((uint 8_t )(BIT0)) /* UART FIFO enable */
# define UART_FCR_RX_RS ((uint 8_t )(BIT1)) /* UART FIFO RX reset */
# define UART_FCR_TX_RS ((uint 8_t )(BIT2)) /* UART FIFO TX reset */
# define UART_FCR_DMAMODE_SEL ((uint 8_t )(BIT3)) /* UART DMA mode selection */
# define UART_FCR_TRG_LEV0 ((uint 8_t )(0)) /* UART FIFO trigger level 0: 1 character */
# define UART_FCR_TRG_LEV1 ((uint 8_t )(BIT6)) /* UART FIFO trigger level 1: 4 character */
# define UART_FCR_TRG_LEV2 ((uint 8_t )(2<<6)) /* UART FIFO trigger level 2: 8 character */
# define UART_FCR_TRG_LEV3 ((uint 8_t )(3<<6)) /* UART FIFO trigger level 3: 14 character */
# define UART_FCR_BITMASK ((uint 8_t )(0xCF)) /* UART FIFO control bit mask */
# define UART_TX_FIFO_SIZE (16)
/**********************************************************************
* Macro defines for Macro defines for UART line control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_LCR_WLEN5 ((u8)(0)) /* UART 5 bit data mode */
# define UART_LCR_WLEN6 ((u8)(1)) /* UART 6 bit data mode */
# define UART_LCR_WLEN7 ((u8)(2)) /* UART 7 bit data mode */
# define UART_LCR_WLEN8 ((u8)(3)) /* UART 8 bit data mode */
# define UART_LCR_ONE_STOPBIT ((u8)(0)) /* UART One Stop Bits */
# define UART_LCR_TWO_STOPBIT ((u8)(BIT2)) /* UART Two Stop Bits */
# define UART_LCR_NO_PARITY ((u8)(0)) /* UART Parity Disabled / No Parity */
# define UART_LCR_PARITY_EN ((u8)(BIT3)) /* UART Parity Enable */
# define UART_LCR_PARITY_ODD ((u8)(0)) /* UART Odd Parity Select */
# define UART_LCR_PARITY_EVEN ((u8)(BIT4)) /* UART Even Parity Select */
# define UART_LCR_PARITY_SP_1 ((u8)(0x20)) /* UART force 1 stick parity */
# define UART_LCR_PARITY_SP_0 ((u8)(0x30)) /* UART force 0 stick parity */
# define UART_LCR_BREAK_EN ((u8)(BIT6)) /* UART Transmission Break enable */
# define UART_LCR_DLAB_EN ((u8)(BIT7)) /* UART Divisor Latches Access bit enable */
# define UART_LCR_BITMASK ((u8)(0xFF)) /* UART line control bit mask */
# define UART_LCR_WLEN5 ((uint 8_t )(0)) /* UART 5 bit data mode */
# define UART_LCR_WLEN6 ((uint 8_t )(1)) /* UART 6 bit data mode */
# define UART_LCR_WLEN7 ((uint 8_t )(2)) /* UART 7 bit data mode */
# define UART_LCR_WLEN8 ((uint 8_t )(3)) /* UART 8 bit data mode */
# define UART_LCR_ONE_STOPBIT ((uint 8_t )(0)) /* UART One Stop Bits */
# define UART_LCR_TWO_STOPBIT ((uint 8_t )(BIT2)) /* UART Two Stop Bits */
# define UART_LCR_NO_PARITY ((uint 8_t )(0)) /* UART Parity Disabled / No Parity */
# define UART_LCR_PARITY_EN ((uint 8_t )(BIT3)) /* UART Parity Enable */
# define UART_LCR_PARITY_ODD ((uint 8_t )(0)) /* UART Odd Parity Select */
# define UART_LCR_PARITY_EVEN ((uint 8_t )(BIT4)) /* UART Even Parity Select */
# define UART_LCR_PARITY_SP_1 ((uint 8_t )(0x20)) /* UART force 1 stick parity */
# define UART_LCR_PARITY_SP_0 ((uint 8_t )(0x30)) /* UART force 0 stick parity */
# define UART_LCR_BREAK_EN ((uint 8_t )(BIT6)) /* UART Transmission Break enable */
# define UART_LCR_DLAB_EN ((uint 8_t )(BIT7)) /* UART Divisor Latches Access bit enable */
# define UART_LCR_BITMASK ((uint 8_t )(0xFF)) /* UART line control bit mask */
/**********************************************************************
* Macro defines for Macro defines for UART line status register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_LSR_RDR ((u8)(BIT0)) /* Line status register: Receive data ready */
# define UART_LSR_OE ((u8)(BIT1)) /* Line status register: Overrun error */
# define UART_LSR_PE ((u8)(BIT2)) /* Line status register: Parity error */
# define UART_LSR_FE ((u8)(BIT3)) /* Line status register: Framing error */
# define UART_LSR_BI ((u8)(BIT4)) /* Line status register: Break interrupt */
# define UART_LSR_THRE ((u8)(BIT5)) /* Line status register: Transmit holding register empty */
# define UART_LSR_TEMT ((u8)(BIT6)) /* Line status register: Transmitter empty */
# define UART_LSR_RXFE ((u8)(BIT7)) /* Error in RX FIFO */
# define UART_LSR_BITMASK ((u8)(0xFF)) /* UART Line status bit mask */
# define UART_LSR_RDR ((uint 8_t )(BIT0)) /* Line status register: Receive data ready */
# define UART_LSR_OE ((uint 8_t )(BIT1)) /* Line status register: Overrun error */
# define UART_LSR_PE ((uint 8_t )(BIT2)) /* Line status register: Parity error */
# define UART_LSR_FE ((uint 8_t )(BIT3)) /* Line status register: Framing error */
# define UART_LSR_BI ((uint 8_t )(BIT4)) /* Line status register: Break interrupt */
# define UART_LSR_THRE ((uint 8_t )(BIT5)) /* Line status register: Transmit holding register empty */
# define UART_LSR_TEMT ((uint 8_t )(BIT6)) /* Line status register: Transmitter empty */
# define UART_LSR_RXFE ((uint 8_t )(BIT7)) /* Error in RX FIFO */
# define UART_LSR_BITMASK ((uint 8_t )(0xFF)) /* UART Line status bit mask */
# define UART_LSR_ERROR_MASK (UART_LSR_OE|UART_LSR_PE|UART_LSR_FE|UART_LSR_BI|UART_LSR_RXFE)
/**********************************************************************
* Macro defines for Macro defines for UART Scratch Pad Register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_SCR_BIMASK ((u8)(0xFF)) /* UART Scratch Pad bit mask */
# define UART_SCR_BIMASK ((uint 8_t )(0xFF)) /* UART Scratch Pad bit mask */
/***********************************************************************
* Macro defines for Macro defines for UART Auto baudrate control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_ACR_START ((u32)(BIT0)) /* UART Auto-baud start */
# define UART_ACR_MODE ((u32)(BIT1)) /* UART Auto baudrate Mode 1 */
# define UART_ACR_AUTO_RESTART ((u32)(BIT2)) /* UART Auto baudrate restart */
# define UART_ACR_ABEOINT_CLR ((u32)(BIT8)) /* UART End of auto-baud interrupt clear */
# define UART_ACR_ABTOINT_CLR ((u32)(BIT9)) /* UART Auto-baud time-out interrupt clear */
# define UART_ACR_BITMASK ((u32)(0x307)) /* UART Auto Baudrate register bit mask */
# define UART_ACR_START ((uint 32_t )(BIT0)) /* UART Auto-baud start */
# define UART_ACR_MODE ((uint 32_t )(BIT1)) /* UART Auto baudrate Mode 1 */
# define UART_ACR_AUTO_RESTART ((uint 32_t )(BIT2)) /* UART Auto baudrate restart */
# define UART_ACR_ABEOINT_CLR ((uint 32_t )(BIT8)) /* UART End of auto-baud interrupt clear */
# define UART_ACR_ABTOINT_CLR ((uint 32_t )(BIT9)) /* UART Auto-baud time-out interrupt clear */
# define UART_ACR_BITMASK ((uint 32_t )(0x307)) /* UART Auto Baudrate register bit mask */
/*********************************************************************
* Macro defines for Macro defines for UART IrDA control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_ICR_IRDAEN ((u32)(BIT0)) /* IrDA mode enable */
# define UART_ICR_IRDAINV ((u32)(BIT1)) /* IrDA serial input inverted */
# define UART_ICR_FIXPULSE_EN ((u32)(BIT2)) /* IrDA fixed pulse width mode */
# define UART_ICR_PULSEDIV(n) ((u32)((n&0x07)<<3)) /* PulseDiv - Configures the pulse when FixPulseEn = 1 */
# define UART_ICR_BITMASK ((u32)(0x3F)) /* UART IRDA bit mask */
# define UART_ICR_IRDAEN ((uint 32_t )(BIT0)) /* IrDA mode enable */
# define UART_ICR_IRDAINV ((uint 32_t )(BIT1)) /* IrDA serial input inverted */
# define UART_ICR_FIXPULSE_EN ((uint 32_t )(BIT2)) /* IrDA fixed pulse width mode */
# define UART_ICR_PULSEDIV(n) ((uint 32_t )((n&0x07)<<3)) /* PulseDiv - Configures the pulse when FixPulseEn = 1 */
# define UART_ICR_BITMASK ((uint 32_t )(0x3F)) /* UART IRDA bit mask */
/**********************************************************************
* Macro defines for Macro defines for UART half duplex register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_HDEN_HDEN ((u32)(BIT0)) /* enable half-duplex mode*/
# define UART_HDEN_HDEN ((uint 32_t )(BIT0)) /* enable half-duplex mode*/
/**********************************************************************
* Macro defines for Macro defines for UART smart card interface control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_SCICTRL_SCIEN ((u32)(BIT0)) /* enable asynchronous half-duplex smart card interface*/
# define UART_SCICTRL_NACKDIS ((u32)(BIT1)) /* NACK response is inhibited*/
# define UART_SCICTRL_PROTSEL_T1 ((u32)(BIT2)) /* ISO7816-3 protocol T1 is selected*/
# define UART_SCICTRL_TXRETRY(n) ((u32)((n&0x07)<<5)) /* number of retransmission*/
# define UART_SCICTRL_GUARDTIME(n) ((u32)((n&0xFF)<<8)) /* Extra guard time*/
# define UART_SCICTRL_SCIEN ((uint 32_t )(BIT0)) /* enable asynchronous half-duplex smart card interface*/
# define UART_SCICTRL_NACKDIS ((uint 32_t )(BIT1)) /* NACK response is inhibited*/
# define UART_SCICTRL_PROTSEL_T1 ((uint 32_t )(BIT2)) /* ISO7816-3 protocol T1 is selected*/
# define UART_SCICTRL_TXRETRY(n) ((uint 32_t )((n&0x07)<<5)) /* number of retransmission*/
# define UART_SCICTRL_GUARDTIME(n) ((uint 32_t )((n&0xFF)<<8)) /* Extra guard time*/
/*********************************************************************
* Macro defines for Macro defines for UART synchronous control register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_SYNCCTRL_SYNC ((u32)(BIT0)) /* enable synchronous mode*/
# define UART_SYNCCTRL_CSRC_MASTER ((u32)(BIT1)) /* synchronous master mode*/
# define UART_SYNCCTRL_FES ((u32)(BIT2)) /* sample on falling edge*/
# define UART_SYNCCTRL_TSBYPASS ((u32)(BIT3)) /* to be defined*/
# define UART_SYNCCTRL_CSCEN ((u32)(BIT4)) /* continuous running clock enable (master mode only) */
# define UART_SYNCCTRL_NOSTARTSTOP ((u32)(BIT5)) /* Do not send start/stop bit */
# define UART_SYNCCTRL_CCCLR ((u32)(BIT6)) /* stop continuous clock */
# define UART_SYNCCTRL_SYNC ((uint 32_t )(BIT0)) /* enable synchronous mode*/
# define UART_SYNCCTRL_CSRC_MASTER ((uint 32_t )(BIT1)) /* synchronous master mode*/
# define UART_SYNCCTRL_FES ((uint 32_t )(BIT2)) /* sample on falling edge*/
# define UART_SYNCCTRL_TSBYPASS ((uint 32_t )(BIT3)) /* to be defined*/
# define UART_SYNCCTRL_CSCEN ((uint 32_t )(BIT4)) /* continuous running clock enable (master mode only) */
# define UART_SYNCCTRL_NOSTARTSTOP ((uint 32_t )(BIT5)) /* Do not send start/stop bit */
# define UART_SYNCCTRL_CCCLR ((uint 32_t )(BIT6)) /* stop continuous clock */
/*********************************************************************
* Macro defines for Macro defines for UART Fractional divider register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_FDR_DIVADDVAL(n) ((u32)(n&0x0F)) /* Baud-rate generation pre-scaler divisor */
# define UART_FDR_MULVAL(n) ((u32)((n<<4)&0xF0)) /* Baud-rate pre-scaler multiplier value */
# define UART_FDR_BITMASK ((u32)(0xFF)) /* UART Fractional Divider register bit mask */
# define UART_FDR_DIVADDVAL(n) ((uint 32_t )(n&0x0F)) /* Baud-rate generation pre-scaler divisor */
# define UART_FDR_MULVAL(n) ((uint 32_t )((n<<4)&0xF0)) /* Baud-rate pre-scaler multiplier value */
# define UART_FDR_BITMASK ((uint 32_t )(0xFF)) /* UART Fractional Divider register bit mask */
/*********************************************************************
* Macro defines for Macro defines for UART Tx Enable register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART1_TER_TXEN ((u8)(BIT7)) /* Transmit enable bit */
# define UART1_TER_BITMASK ((u8)(0x80)) /* UART Transmit Enable Register bit mask */
# define UART1_TER_TXEN ((uint 8_t )(BIT7)) /* Transmit enable bit */
# define UART1_TER_BITMASK ((uint 8_t )(0x80)) /* UART Transmit Enable Register bit mask */
# define UART0_2_3_TER_TXEN ((u8)(BIT0)) /* Transmit enable bit */
# define UART0_2_3_TER_BITMASK ((u8)(0x01)) /* UART Transmit Enable Register bit mask */
# define UART0_2_3_TER_TXEN ((uint 8_t )(BIT0)) /* Transmit enable bit */
# define UART0_2_3_TER_BITMASK ((uint 8_t )(0x01)) /* UART Transmit Enable Register bit mask */
/**********************************************************************
* Macro defines for Macro defines for UART FIFO Level register
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
# define UART_FIFOLVL_RX(n) ((u32)(n&0x0F)) /* Reflects the current level of the UART receiver FIFO */
# define UART_FIFOLVL_TX(n) ((u32)((n>>8)&0x0F)) /* Reflects the current level of the UART transmitter FIFO */
# define UART_FIFOLVL_BITMASK ((u32)(0x0F0F)) /* UART FIFO Level Register bit mask */
# define UART_FIFOLVL_RX(n) ((uint 32_t )(n&0x0F)) /* Reflects the current level of the UART receiver FIFO */
# define UART_FIFOLVL_TX(n) ((uint 32_t )((n>>8)&0x0F)) /* Reflects the current level of the UART transmitter FIFO */
# define UART_FIFOLVL_BITMASK ((uint 32_t )(0x0F0F)) /* UART FIFO Level Register bit mask */
/*********************************************************************
* UART enum
@ -328,17 +328,17 @@ void uart_init(uart_num_t uart_num,
uart_databit_t data_nb_bits ,
uart_stopbit_t data_nb_stop ,
uart_parity_t data_parity ,
u16 uart_divisor ,
u8 uart_divaddval ,
u8 uart_mulval ) ;
uint16_t uart_divisor ,
uint8_t uart_divaddval ,
uint8_t uart_mulval ) ;
uart_rx_data_ready_t uart_rx_data_ready ( uart_num_t uart_num ) ;
u8 uart_read ( uart_num_t uart_num ) ;
uint8_t uart_read ( uart_num_t uart_num ) ;
u8 uart_read_timeout ( uart_num_t uart_num , u32 rx_timeout_nb_cycles , uart_error_t * error ) ;
uint8_t uart_read_timeout ( uart_num_t uart_num , uint32_t rx_timeout_nb_cycles , uart_error_t * error ) ;
void uart_write ( uart_num_t uart_num , u8 data ) ;
void uart_write ( uart_num_t uart_num , uint8_t data ) ;
END_DECLS