STM8S/A Standard Peripherals Drivers
|
This file contains all functions prototypes and macros for the UART3 peripheral. More...
#include "stm8s.h"
Go to the source code of this file.
Defines | |
#define | IS_UART3_ADDRESS_OK(Node) ((Node) < UART3_ADDRESS_MAX) |
#define | IS_UART3_AUTOSYNC_OK(AutosyncMode) |
Macro used by the assert_param function in order to check the LIN automatic resynchronization mode. | |
#define | IS_UART3_BAUDRATE_OK(NUM) ((NUM) <= (uint32_t)625000) |
Macro used by the assert_param function in order to check the maximum baudrate value. | |
#define | IS_UART3_CLEAR_FLAG_OK(Flag) |
Macro used by the assert_param function in order to check the different sensitivity values for the FLAGs that can be cleared by writing 0. | |
#define | IS_UART3_CLEAR_IT_OK(ITPendingBit) |
Macro used by the assert function in order to check the different sensitivity values for the pending bit that can be cleared by writing 0. | |
#define | IS_UART3_CONFIG_IT_OK(Interrupt) |
Macro used by the assert_param function in order to check the different sensitivity values for the Interrupts. | |
#define | IS_UART3_DIVUP_OK(DivupMethod) |
Macro used by the assert_param function in order to check the LIN divider update method. | |
#define | IS_UART3_FLAG_OK(Flag) |
Macro used by the assert_param function in order to check the different sensitivity values for the FLAGs. | |
#define | IS_UART3_GET_IT_OK(ITPendingBit) |
Macro used by the assert function in order to check the different sensitivity values for the pending bit. | |
#define | IS_UART3_LINBREAKDETECTIONLENGTH_OK(LINBreakDetectionLengths) |
Macro used by the assert_param function in order to check the different sensitivity values for the LINBreakDetectionLengths. | |
#define | IS_UART3_MODE_OK(Mode) |
Macro used by the assert_param function in order to check the different sensitivity values for the MODEs. | |
#define | IS_UART3_PARITY_OK(Parity) |
Macro used by the assert_param function in order to check the different sensitivity values for the Parity. | |
#define | IS_UART3_SLAVE_OK(Mode) |
Macro used by the assert_param function in order to check the LIN mode. | |
#define | IS_UART3_STOPBITS_OK(StopBit) |
Macro used by the assert_param function in order to check the different sensitivity values for the UART3_StopBits. | |
#define | IS_UART3_WAKEUP_OK(WakeUpMode) |
Macro used by the assert_param function in order to check the different sensitivity values for the WakeUps. | |
#define | IS_UART3_WORDLENGTH_OK(WordLength) |
Macro used by the assert_param function in order to check the different sensitivity values for the WordLengths. | |
#define | UART3_ADDRESS_MAX ((uint8_t)16) |
Macro used by the assert_param function in order to check the address of the UART3 or UART node. | |
Enumerations | |
enum | UART3_Flag_TypeDef { UART3_FLAG_TXE = (uint16_t)0x0080, UART3_FLAG_TC = (uint16_t)0x0040, UART3_FLAG_RXNE = (uint16_t)0x0020, UART3_FLAG_IDLE = (uint16_t)0x0010, UART3_FLAG_OR_LHE = (uint16_t)0x0008, UART3_FLAG_NF = (uint16_t)0x0004, UART3_FLAG_FE = (uint16_t)0x0002, UART3_FLAG_PE = (uint16_t)0x0001, UART3_FLAG_SBK = (uint16_t)0x0101, UART3_FLAG_LBDF = (uint16_t)0x0210, UART3_FLAG_LHDF = (uint16_t)0x0302, UART3_FLAG_LSF = (uint16_t)0x0301 } |
UART3 Flag possible values. More... | |
enum | UART3_IT_TypeDef { UART3_IT_TXE = (uint16_t)0x0277, UART3_IT_TC = (uint16_t)0x0266, UART3_IT_RXNE = (uint16_t)0x0255, UART3_IT_IDLE = (uint16_t)0x0244, UART3_IT_OR = (uint16_t)0x0235, UART3_IT_PE = (uint16_t)0x0100, UART3_IT_LBDF = (uint16_t)0x0346, UART3_IT_LHDF = (uint16_t)0x0412, UART3_IT_RXNE_OR = (uint16_t)0x0205 } |
UART3 Interrupt definition UART3_IT possible values Elements values convention: 0xZYX X: Position of the corresponding Interrupt. More... | |
enum | UART3_LinAutosync_TypeDef { UART3_LIN_AUTOSYNC_DISABLE = (uint8_t)0x00, UART3_LIN_AUTOSYNC_ENABLE = (uint8_t)0x01 } |
UART3 automatic resynchronisation possible values. More... | |
enum | UART3_LINBreakDetectionLength_TypeDef { UART3_LINBREAKDETECTIONLENGTH_10BITS = (uint8_t)0x00, UART3_LINBREAKDETECTIONLENGTH_11BITS = (uint8_t)0x01 } |
UART3 LIN Break detection length possible values. More... | |
enum | UART3_LinDivUp_TypeDef { UART3_LIN_DIVUP_LBRR1 = (uint8_t)0x00, UART3_LIN_DIVUP_NEXTRXNE = (uint8_t)0x01 } |
UART3 Divider Update Method possible values. More... | |
enum | UART3_LinMode_TypeDef { UART3_LIN_MODE_MASTER = (uint8_t)0x00, UART3_LIN_MODE_SLAVE = (uint8_t)0x01 } |
UART3 Mode possible values. More... | |
enum | UART3_Mode_TypeDef { UART3_MODE_RX_ENABLE = (uint8_t)0x08, UART3_MODE_TX_ENABLE = (uint8_t)0x04, UART3_MODE_TX_DISABLE = (uint8_t)0x80, UART3_MODE_RX_DISABLE = (uint8_t)0x40, UART3_MODE_TXRX_ENABLE = (uint8_t)0x0C } |
UART3 Mode Transmit/Receive possible values. More... | |
enum | UART3_Parity_TypeDef { UART3_PARITY_NO = (uint8_t)0x00, UART3_PARITY_EVEN = (uint8_t)0x04, UART3_PARITY_ODD = (uint8_t)0x06 } |
UART3 parity possible values. More... | |
enum | UART3_StopBits_TypeDef { UART3_STOPBITS_1 = (uint8_t)0x00, UART3_STOPBITS_2 = (uint8_t)0x20 } |
UART3 stop bits possible values. More... | |
enum | UART3_WakeUp_TypeDef { UART3_WAKEUP_IDLELINE = (uint8_t)0x00, UART3_WAKEUP_ADDRESSMARK = (uint8_t)0x08 } |
UART3 WakeUP Modes. More... | |
enum | UART3_WordLength_TypeDef { UART3_WORDLENGTH_8D = (uint8_t)0x00, UART3_WORDLENGTH_9D = (uint8_t)0x10 } |
UART3 Word length possible values. More... | |
Functions | |
void | UART3_ClearFlag (UART3_Flag_TypeDef UART3_FLAG) |
Clears the UART3 flags. | |
void | UART3_ClearITPendingBit (UART3_IT_TypeDef UART3_IT) |
Clears the UART3 pending flags. | |
void | UART3_Cmd (FunctionalState NewState) |
Enable the UART1 peripheral. | |
void | UART3_DeInit (void) |
Deinitializes the UART peripheral. | |
FlagStatus | UART3_GetFlagStatus (UART3_Flag_TypeDef UART3_FLAG) |
Checks whether the specified UART3 flag is set or not. | |
ITStatus | UART3_GetITStatus (UART3_IT_TypeDef UART3_IT) |
Checks whether the specified UART3 interrupt has occurred or not. | |
void | UART3_Init (uint32_t BaudRate, UART3_WordLength_TypeDef WordLength, UART3_StopBits_TypeDef StopBits, UART3_Parity_TypeDef Parity, UART3_Mode_TypeDef Mode) |
Initializes the UART3 according to the specified parameters. | |
void | UART3_ITConfig (UART3_IT_TypeDef UART3_IT, FunctionalState NewState) |
Enables or disables the specified UART3 interrupts. | |
void | UART3_LINBreakDetectionConfig (UART3_LINBreakDetectionLength_TypeDef UART3_LINBreakDetectionLength) |
Sets the UART3 LIN Break detection length. | |
void | UART3_LINCmd (FunctionalState NewState) |
Enables or disables the UART3 LIN mode. | |
void | UART3_LINConfig (UART3_LinMode_TypeDef UART3_Mode, UART3_LinAutosync_TypeDef UART3_Autosync, UART3_LinDivUp_TypeDef UART3_DivUp) |
Configure the UART3 peripheral. | |
uint8_t | UART3_ReceiveData8 (void) |
Returns the most recent received data by the UART3 peripheral. | |
uint16_t | UART3_ReceiveData9 (void) |
Returns the most recent received data by the UART3 peripheral. | |
void | UART3_ReceiverWakeUpCmd (FunctionalState NewState) |
Determines if the UART3 is in mute mode or not. | |
void | UART3_SendBreak (void) |
Transmits break characters. | |
void | UART3_SendData8 (uint8_t Data) |
Transmits 8 bit data through the UART3 peripheral. | |
void | UART3_SendData9 (uint16_t Data) |
Transmits 9 bit data through the UART3 peripheral. | |
void | UART3_SetAddress (uint8_t UART3_Address) |
Sets the address of the UART3 node. | |
void | UART3_WakeUpConfig (UART3_WakeUp_TypeDef UART3_WakeUp) |
Selects the UART3 WakeUp method. |
Detailed Description
This file contains all functions prototypes and macros for the UART3 peripheral.
- Attention:
© COPYRIGHT 2014 STMicroelectronics
Licensed under MCD-ST Liberty SW License Agreement V2, (the "License"); You may not use this file except in compliance with the License. You may obtain a copy of the License at:
http://www.st.com/software_license_agreement_liberty_v2
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Definition in file stm8s_uart3.h.