| BlueNRG-1 Peripherals drivers APIs

- Main Page
- Modules
- Classes
- Files

- File List
- File Members

Classes | Macros | Functions
BlueNRG1_uart.h File Reference

This file contains all the functions prototypes for the UART firmware library. More...

`#include "BlueNRG1.h"`

Go to the source code of this file.

## Classes

struct | UART_InitType
| Structure definition of UART initialization. More...

## Macros

#define | UART_WordLength_5b ((uint8_t)0)
#define | UART_WordLength_6b ((uint8_t)1)
#define | UART_WordLength_7b ((uint8_t)2)
#define | UART_WordLength_8b ((uint8_t)3)
#define | IS_UART_WORD_LENGTH(LENGTH)
#define | UART_StopBits_1 ((uint8_t)0)
#define | UART_StopBits_2 ((uint8_t)1)
#define | IS_UART_STOPBITS(STOPBITS)
#define | UART_Parity_No ((uint8_t)0)
#define | UART_Parity_Even ((uint8_t)1)
#define | UART_Parity_Odd ((uint8_t)2)
#define | IS_UART_PARITY(PARITY)
#define | UART_Mode_Rx ((uint8_t)0x01)
#define | UART_Mode_Tx ((uint8_t)0x02)
#define | IS_UART_MODE(MODE) ( (MODE)<= 3)
#define | UART_HardwareFlowControl_None ((uint8_t)0x00)
#define | UART_HardwareFlowControl_RTS ((uint8_t)0x01)
#define | UART_HardwareFlowControl_CTS ((uint8_t)0x02)
#define | UART_HardwareFlowControl_RTS_CTS ((uint8_t)0x03)
#define | IS_UART_HW_FLOW_CONTROL(CONTROL) ( (CONTROL) <= 3 )
#define | UART_IT_TXFE ((uint16_t)0x1000)
#define | UART_IT_XO ((uint16_t)0x0800)
#define | UART_IT_OE ((uint16_t)0x0400)
#define | UART_IT_BE ((uint16_t)0x0200)
#define | UART_IT_PE ((uint16_t)0x0100)
#define | UART_IT_FE ((uint16_t)0x0080)
#define | UART_IT_RT ((uint16_t)0x0040)
#define | UART_IT_TX ((uint16_t)0x0020)
#define | UART_IT_RX ((uint16_t)0x0010)
#define | UART_IT_CTS ((uint16_t)0x0002)
#define | IS_UART_CONFIG_IT(IT) ((((IT) & (uint16_t)~0x1FF2) == 0x00) && ((IT) != (uint16_t)0x0000))
#define | UART_FLAG_CTS ((uint32_t)0x00000001)
#define | UART_FLAG_BUSY ((uint32_t)0x00000008)
#define | UART_FLAG_RXFE ((uint32_t)0x00000010)
#define | UART_FLAG_TXFF ((uint32_t)0x00000020)
#define | UART_FLAG_RXFF ((uint32_t)0x00000040)
#define | UART_FLAG_TXFE ((uint32_t)0x00000080)
#define | UART_FLAG_FE ((uint32_t)0x80000001)
#define | UART_FLAG_PE ((uint32_t)0x80000002)
#define | UART_FLAG_BE ((uint32_t)0x80000004)
#define | UART_FLAG_OE ((uint32_t)0x80000008)
#define | IS_UART_FLAG(FLAG)
#define | IS_UART_CLEAR_FLAG(FLAG)
#define | IS_UART_BAUDRATE(BAUDRATE) (((BAUDRATE) > 0) && ((BAUDRATE) <= 1000000))
#define | IS_UART_DATA(DATA) ((DATA) <= 0x1FF)
#define | FIFO_LEV_1_8 ((uint8_t)0)
#define | FIFO_LEV_1_4 ((uint8_t)1)
#define | FIFO_LEV_1_2 ((uint8_t)2)
#define | FIFO_LEV_3_4 ((uint8_t)3)
#define | FIFO_LEV_7_8 ((uint8_t)4)
#define | IS_FIFO_LEV(FIFO_LEV)
#define | NO_SW_FLOW_CTRL ((uint8_t)0)
#define | SW_FLOW_CTRL_XON1_XOFF1 ((uint8_t)1)
#define | SW_FLOW_CTRL_XON2_XOFF2 ((uint8_t)2)
#define | SW_FLOW_CTRL_ALL_CHARS ((uint8_t)3)
#define | IS_SW_FLOW_CTRL(SW_FLOW_CTRL)
#define | UART_DMAReq_Tx ((uint8_t)0x02)
#define | UART_DMAReq_Rx ((uint8_t)0x01)
#define | IS_UART_DMAREQ(DMAREQ) (DMAREQ<(uint8_t)4 && DMAREQ!=(uint8_t)0 )
#define | IS_UART_TIMEOUT(VAL) ((VAL) < 0x400000 )

## Functions

void | UART_DeInit (void)
| Deinitializes the UART peripheral registers to their default reset values. More...
void | UART_Init (UART_InitType *UART_InitStruct)
| Initializes the UART peripheral according to the specified parameters in the UART_InitStruct. More...
void | UART_StructInit (UART_InitType *UART_InitStruct)
| Fills each UART_InitStruct member with its default value. More...
void | UART_Cmd (FunctionalState NewState)
| Enables or disables the UART peripheral. More...
void | UART_ITConfig (uint16_t UART_IT, FunctionalState NewState)
| Enables or disables the specified UART interrupts. More...
void | UART_SendData (uint16_t Data)
| Transmits single data through the UART peripheral. More...
uint16_t | UART_ReceiveData (void)
| Returns the most recent received data by the UART peripheral. More...
void | UART_BreakCmd (FunctionalState NewState)
| Enables or disables the break command. More...
void | UART_RequestToSendCmd (FunctionalState NewState)
| Enables or disables the request to send command. More...
FlagStatus | UART_GetFlagStatus (uint32_t UART_FLAG)
| Checks whether the specified UART flag is set or not. More...
void | UART_ClearFlag (uint32_t UART_FLAG)
| Clears the UART pending flags. More...
ITStatus | UART_GetITStatus (uint16_t UART_IT)
| Checks whether the specified UART interrupt has occurred or not. More...
void | UART_ClearITPendingBit (uint16_t UART_IT)
| Clears the UART interrupt pending bits. More...
void | UART_TxFifoIrqLevelConfig (uint8_t UART_TxFifo_Level)
| Sets the UART interrupt FIFO level. More...
void | UART_RxFifoIrqLevelConfig (uint8_t UART_RxFifo_Level)
| Sets the UART interrupt FIFO level. More...
void | UART_TimeoutConfig (uint32_t UART_Timeout)
| UART timeout value for the interrupt. The receive timeout interrupt is asserted when the RX FIFO is not empty and no further data is received over a programmed timeout period. More...
void | UART_SwFlowControl (FunctionalState NewState)
| Enables or disables the UART software flow control. More...
void | UART_RxSwFlowControlMode (uint8_t UART_RxSwFlowCtrlMode)
| Sets the UART flow control mode for reception. More...
void | UART_TxSwFlowControlMode (uint8_t UART_TxSwFlowCtrlMode)
| Sets the UART flow control mode for transmission. More...
void | UART_XonAnyBit (FunctionalState NewState)
| Enables or disables the UART XON any bit. More...
void | UART_SpecialCharDetect (FunctionalState NewState)
| Enables or disables the UART special character detection. More...
void | UART_Xon1Char (uint8_t UART_XonChar)
| Sets the UART flow control mode for transmission. More...
void | UART_Xon2Char (uint8_t UART_XonChar)
| Sets the UART flow control mode for transmission. More...
void | UART_Xoff1Char (uint8_t UART_XoffChar)
| Sets the UART flow control mode for transmission. More...
void | UART_Xoff2Char (uint8_t UART_XoffChar)
| Sets the UART flow control mode for transmission. More...
void | UART_DMACmd (uint8_t UART_DMAReq, FunctionalState NewState)
| Enables or disables the UART DMA interface. More...

## Detailed Description

This file contains all the functions prototypes for the UART firmware library.

Author
  VMA Application Team

Version
  V2.0.0

Date
  21-March-2016

Attention

THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.

##
© COPYRIGHT 2016 STMicroelectronics

Definition in file BlueNRG1_uart.h.