1 /**************************************************************************//** 2 * @file uart_reg.h 3 * @version V1.00 4 * @brief UART register definition header file 5 * 6 * SPDX-License-Identifier: Apache-2.0 7 * @copyright (C) 2017-2020 Nuvoton Technology Corp. All rights reserved. 8 *****************************************************************************/ 9 #ifndef __UART_REG_H__ 10 #define __UART_REG_H__ 11 12 #if defined ( __CC_ARM ) 13 #pragma anon_unions 14 #endif 15 16 /** 17 @addtogroup REGISTER Control Register 18 @{ 19 */ 20 21 /** 22 @addtogroup UART Universal Asynchronous Receiver/Transmitter Controller(UART) 23 Memory Mapped Structure for UART Controller 24 @{ */ 25 26 typedef struct 27 { 28 29 30 /** 31 * @var UART_T::DAT 32 * Offset: 0x00 UART Receive/Transmit Buffer Register 33 * --------------------------------------------------------------------------------------------------- 34 * |Bits |Field |Descriptions 35 * | :----: | :----: | :---- | 36 * |[7:0] |DAT |Data Receive/Transmit Buffer 37 * | | |Write Operation: 38 * | | |By writing one byte to this register, the data byte will be stored in transmitter FIFO 39 * | | |The UART controller will send out the data stored in transmitter FIFO top location through the UART_TXD. 40 * | | |Read Operation: 41 * | | |By reading this register, the UART controller will return an 8-bit data received from receiver FIFO. 42 * |[8] |PARITY |Parity Bit Receive/Transmit Buffer 43 * | | |Write Operation: 44 * | | |By writing to this bit, the parity bit will be stored in transmitter FIFO 45 * | | |If PBE (UART_LINE[3]) and PSS (UART_LINE[7]) are set, 46 * | | |the UART controller will send out this bit follow the DAT (UART_DAT[7:0]) through the UART_TXD. 47 * | | |Read Operation: 48 * | | |If PBE (UART_LINE[3]) and PSS (UART_LINE[7]) are enabled, the parity bit can be read by this bit. 49 * | | |Note: This bit has effect only when PBE (UART_LINE[3]) and PSS (UART_LINE[7]) are set. 50 * @var UART_T::INTEN 51 * Offset: 0x04 UART Interrupt Enable Register 52 * --------------------------------------------------------------------------------------------------- 53 * |Bits |Field |Descriptions 54 * | :----: | :----: | :---- | 55 * |[0] |RDAIEN |Receive Data Available Interrupt Enable Bit 56 * | | |0 = Receive data available interrupt Disabled. 57 * | | |1 = Receive data available interrupt Enabled. 58 * |[1] |THREIEN |Transmit Holding Register Empty Interrupt Enable Bit 59 * | | |0 = Transmit holding register empty interrupt Disabled. 60 * | | |1 = Transmit holding register empty interrupt Enabled. 61 * |[2] |RLSIEN |Receive Line Status Interrupt Enable Bit 62 * | | |0 = Receive Line Status interrupt Disabled. 63 * | | |1 = Receive Line Status interrupt Enabled. 64 * |[3] |MODEMIEN |Modem Status Interrupt Enable Bit 65 * | | |0 = Modem status interrupt Disabled. 66 * | | |1 = Modem status interrupt Enabled. 67 * |[4] |RXTOIEN |RX Time-out Interrupt Enable Bit 68 * | | |0 = RX time-out interrupt Disabled. 69 * | | |1 = RX time-out interrupt Enabled. 70 * |[5] |BUFERRIEN |Buffer Error Interrupt Enable Bit 71 * | | |0 = Buffer error interrupt Disabled. 72 * | | |1 = Buffer error interrupt Enabled. 73 * |[6] |WKIEN |Wake-up Interrupt Enable Bit 74 * | | |0 = Wake-up Interrupt Disabled. 75 * | | |1 = Wake-up Interrupt Enabled. 76 * |[8] |LINIEN |LIN Bus Interrupt Enable Bit 77 * | | |0 = LIN bus interrupt Disabled. 78 * | | |1 = LIN bus interrupt Enabled. 79 * | | |Note: This bit is used for LIN function mode. 80 * |[11] |TOCNTEN |Receive Buffer Time-out Counter Enable Bit 81 * | | |0 = Receive Buffer Time-out counter Disabled. 82 * | | |1 = Receive Buffer Time-out counter Enabled. 83 * |[12] |ATORTSEN |nRTS Auto-flow Control Enable Bit 84 * | | |0 = nRTS auto-flow control Disabled. 85 * | | |1 = nRTS auto-flow control Enabled. 86 * | | |Note: When nRTS auto-flow is enabled, if the number of bytes in the RX FIFO equals the RTSTRGLV (UART_FIFO[19:16]), the UART will de-assert nRTS signal. 87 * |[13] |ATOCTSEN |nCTS Auto-flow Control Enable Bit 88 * | | |0 = nCTS auto-flow control Disabled. 89 * | | |1 = nCTS auto-flow control Enabled. 90 * | | |Note: When nCTS auto-flow is enabled, the UART will send data to external device if nCTS input assert (UART will not send data to device until nCTS is asserted). 91 * |[14] |TXPDMAEN |TX PDMA Enable Bit 92 * | | |This bit can enable or disable TX PDMA service. 93 * | | |0 = TX PDMA Disabled. 94 * | | |1 = TX PDMA Enabled. 95 * | | |Note: If RLSIEN (UART_INTEN[2]) is enabled and HWRLSINT (UART_INTSTS[26]) is set to 1, the RLS (Receive Line Status) Interrupt is caused 96 * | | |If RLS interrupt is caused by Break Error Flag BIF(UART_FIFOSTS[6]), Frame Error Flag FEF(UART_FIFO[5]) or Parity Error Flag PEF(UART_FIFOSTS[4]) , UART PDMA transmit request operation is stop 97 * | | |Clear Break Error Flag BIF or Frame Error Flag FEF or Parity Error Flag PEF by writing '1' to corresponding BIF, FEF and PEF to make UART PDMA transmit request operation continue. 98 * |[15] |RXPDMAEN |RX PDMA Enable Bit 99 * | | |This bit can enable or disable RX PDMA service. 100 * | | |0 = RX PDMA Disabled. 101 * | | |1 = RX PDMA Enabled. 102 * | | |Note: If RLSIEN (UART_INTEN[2]) is enabled and HWRLSINT (UART_INTSTS[26]) is set to 1, the RLS (Receive Line Status) Interrupt is caused 103 * | | |If RLS interrupt is caused by Break Error Flag BIF(UART_FIFOSTS[6]), Frame Error Flag FEF(UART_FIFO[5]) or Parity Error Flag PEF(UART_FIFOSTS[4]) , UART PDMA receive request operation is stop 104 * | | |Clear Break Error Flag BIF or Frame Error Flag FEF or Parity Error Flag PEF by writing '1' to corresponding BIF, FEF and PEF to make UART PDMA receive request operation continue. 105 * |[18] |ABRIEN |Auto-baud Rate Interrupt Enable Bit 106 * | | |0 = Auto-baud rate interrupt Disabled. 107 * | | |1 = Auto-baud rate interrupt Enabled. 108 * |[22] |TXENDIEN |Transmitter Empty Interrupt Enable Bit 109 * | | |If TXENDIEN (UART_INTEN[22]) is enabled, the Transmitter Empty interrupt TXENDINT (UART_INTSTS[30]) will be generated when TXENDIF (UART_INTSTS[22]) is set (TX FIFO (UART_DAT) is empty and the STOP bit of the last byte has been transmitted). 110 * | | |0 = Transmitter empty interrupt Disabled. 111 * | | |1 = Transmitter empty interrupt Enabled. 112 * @var UART_T::FIFO 113 * Offset: 0x08 UART FIFO Control Register 114 * --------------------------------------------------------------------------------------------------- 115 * |Bits |Field |Descriptions 116 * | :----: | :----: | :---- | 117 * |[1] |RXRST |RX Field Software Reset 118 * | | |When RXRST (UART_FIFO[1]) is set, all the byte in the receiver FIFO and RX internal state machine are cleared. 119 * | | |0 = No effect. 120 * | | |1 = Reset the RX internal state machine and pointers. 121 * | | |Note1: This bit will automatically clear at least 3 UART peripheral clock cycles. 122 * | | |Note2: Before setting this bit, it should wait for the RXIDLE (UART_FIFOSTS[29]) be set. 123 * |[2] |TXRST |TX Field Software Reset 124 * | | |When TXRST (UART_FIFO[2]) is set, all the byte in the transmit FIFO and TX internal state machine are cleared. 125 * | | |0 = No effect. 126 * | | |1 = Reset the TX internal state machine and pointers. 127 * | | |Note1: This bit will automatically clear at least 3 UART peripheral clock cycles. 128 * | | |Note2: Before setting this bit, it should wait for the TXEMPTYF (UART_FIFOSTS[28]) be set. 129 * |[7:4] |RFITL |RX FIFO Interrupt Trigger Level 130 * | | |When the number of bytes in the receive FIFO equals the RFITL, the RDAIF (UART_INTSTS[0]) will be set (if RDAIEN (UART_INTEN [0]) enabled, and an interrupt will be generated). 131 * | | |0000 = RX FIFO Interrupt Trigger Level is 1 byte. 132 * | | |0001 = RX FIFO Interrupt Trigger Level is 4 bytes. 133 * | | |0010 = RX FIFO Interrupt Trigger Level is 8 bytes. 134 * | | |0011 = RX FIFO Interrupt Trigger Level is 14 bytes. 135 * | | |Others = Reserved. 136 * |[8] |RXOFF |Receiver Disable Bit 137 * | | |The receiver is disabled or not (set 1 to disable receiver). 138 * | | |0 = Receiver Enabled. 139 * | | |1 = Receiver Disabled. 140 * | | |Note: This bit is used for RS-485 Normal Multi-drop mode 141 * | | |It should be programmed before RS485NMM (UART_ALTCTL [8]) is programmed. 142 * |[19:16] |RTSTRGLV |nRTS Trigger Level for Auto-flow Control Use 143 * | | |0000 = nRTS Trigger Level is 1 byte. 144 * | | |0001 = nRTS Trigger Level is 4 bytes. 145 * | | |0010 = nRTS Trigger Level is 8 bytes. 146 * | | |0011 = nRTS Trigger Level is 14 bytes. 147 * | | |Others = Reserved. 148 * | | |Note: This field is used for auto nRTS flow control. 149 * @var UART_T::LINE 150 * Offset: 0x0C UART Line Control Register 151 * --------------------------------------------------------------------------------------------------- 152 * |Bits |Field |Descriptions 153 * | :----: | :----: | :---- | 154 * |[1:0] |WLS |Word Length Selection 155 * | | |This field sets UART word length. 156 * | | |00 = 5 bits. 157 * | | |01 = 6 bits. 158 * | | |10 = 7 bits. 159 * | | |11 = 8 bits. 160 * |[2] |NSB |Number of 'STOP Bit' 161 * | | |0 = One 'STOP bit' is generated in the transmitted data. 162 * | | |1 = When select 5-bit word length, 1.5 'STOP bit' is generated in the transmitted data 163 * | | |When select 6-, 7- and 8-bit word length, 2 'STOP bit' is generated in the transmitted data. 164 * |[3] |PBE |Parity Bit Enable Bit 165 * | | |0 = Parity bit generated Disabled. 166 * | | |1 = Parity bit generated Enabled. 167 * | | |Note: Parity bit is generated on each outgoing character and is checked on each incoming data. 168 * |[4] |EPE |Even Parity Enable Bit 169 * | | |0 = Odd number of logic '1's is transmitted and checked in each word. 170 * | | |1 = Even number of logic '1's is transmitted and checked in each word. 171 * | | |Note: This bit has effect only when PBE (UART_LINE[3]) is set. 172 * |[5] |SPE |Stick Parity Enable Bit 173 * | | |0 = Stick parity Disabled. 174 * | | |1 = Stick parity Enabled. 175 * | | |Note: If PBE (UART_LINE[3]) and EPE (UART_LINE[4]) are logic 1, the parity bit is transmitted and checked as logic 0 176 * | | |If PBE (UART_LINE[3]) is 1 and EPE (UART_LINE[4]) is 0 then the parity bit is transmitted and checked as 1. 177 * |[6] |BCB |Break Control Bit 178 * | | |0 = Break Control Disabled. 179 * | | |1 = Break Control Enabled. 180 * | | |Note: When this bit is set to logic 1, the transmitted serial data output (TX) is forced to the Spacing State (logic 0) 181 * | | |This bit acts only on TX line and has no effect on the transmitter logic. 182 * |[7] |PSS |Parity Bit Source Selection 183 * | | |The parity bit can be selected to be generated and checked automatically or by software. 184 * | | |0 = Parity bit is generated by EPE (UART_LINE[4]) and SPE (UART_LINE[5]) setting and checked automatically. 185 * | | |1 = Parity bit generated and checked by software. 186 * | | |Note1: This bit has effect only when PBE (UART_LINE[3]) is set. 187 * | | |Note2: If PSS is 0, the parity bit is transmitted and checked automatically 188 * | | |If PSS is 1, the transmitted parity bit value can be determined by writing PARITY (UART_DAT[8]) and the parity bit can be read by reading PARITY (UART_DAT[8]). 189 * |[8] |TXDINV |TX Data Inverted 190 * | | |0 = Transmitted data signal inverted Disabled. 191 * | | |1 = Transmitted data signal inverted Enabled. 192 * | | |Note1: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 193 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 194 * | | |Note2: This bit is valid when FUNCSEL (UART_FUNCSEL[1:0]) is select UART, LIN or RS485 function. 195 * |[9] |RXDINV |RX Data Inverted 196 * | | |0 = Received data signal inverted Disabled. 197 * | | |1 = Received data signal inverted Enabled. 198 * | | |Note1: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 199 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 200 * | | |Note2: This bit is valid when FUNCSEL (UART_FUNCSEL[1:0]) is select UART, LIN or RS485 function. 201 * @var UART_T::MODEM 202 * Offset: 0x10 UART Modem Control Register 203 * --------------------------------------------------------------------------------------------------- 204 * |Bits |Field |Descriptions 205 * | :----: | :----: | :---- | 206 * |[1] |RTS |nRTS (Request-to-send) Signal Control 207 * | | |This bit is direct control internal nRTS signal active or not, and then drive the nRTS pin output with RTSACTLV bit configuration. 208 * | | |0 = nRTS signal is active. 209 * | | |1 = nRTS signal is inactive. 210 * | | |Note1: This nRTS signal control bit is not effective when nRTS auto-flow control is enabled in UART function mode. 211 * | | |Note2: This nRTS signal control bit is not effective when RS-485 auto direction mode (AUD) is enabled in RS-485 function mode. 212 * |[9] |RTSACTLV |nRTS Pin Active Level 213 * | | |This bit defines the active level state of nRTS pin output. 214 * | | |0 = nRTS pin output is high level active. 215 * | | |1 = nRTS pin output is low level active. (Default) 216 * | | |Note1: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 217 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 218 * |[13] |RTSSTS |nRTS Pin Status (Read Only) 219 * | | |This bit mirror from nRTS pin output of voltage logic status. 220 * | | |0 = nRTS pin output is low level voltage logic state. 221 * | | |1 = nRTS pin output is high level voltage logic state. 222 * @var UART_T::MODEMSTS 223 * Offset: 0x14 UART Modem Status Register 224 * --------------------------------------------------------------------------------------------------- 225 * |Bits |Field |Descriptions 226 * | :----: | :----: | :---- | 227 * |[0] |CTSDETF |Detect nCTS State Change Flag 228 * | | |This bit is set whenever nCTS input has change state, and it will generate Modem interrupt to CPU when MODEMIEN (UART_INTEN [3]) is set to 1. 229 * | | |0 = nCTS input has not change state. 230 * | | |1 = nCTS input has change state. 231 * | | |Note: This bit can be cleared by writing '1' to it. 232 * |[4] |CTSSTS |nCTS Pin Status (Read Only) 233 * | | |This bit mirror from nCTS pin input of voltage logic status. 234 * | | |0 = nCTS pin input is low level voltage logic state. 235 * | | |1 = nCTS pin input is high level voltage logic state. 236 * | | |Note: This bit echoes when UART controller peripheral clock is enabled, and nCTS multi-function port is selected. 237 * |[8] |CTSACTLV |nCTS Pin Active Level 238 * | | |This bit defines the active level state of nCTS pin input. 239 * | | |0 = nCTS pin input is high level active. 240 * | | |1 = nCTS pin input is low level active. (Default) 241 * | | |Note: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 242 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 243 * @var UART_T::FIFOSTS 244 * Offset: 0x18 UART FIFO Status Register 245 * --------------------------------------------------------------------------------------------------- 246 * |Bits |Field |Descriptions 247 * | :----: | :----: | :---- | 248 * |[0] |RXOVIF |RX Overflow Error Interrupt Flag 249 * | | |This bit is set when RX FIFO overflow. 250 * | | |If the number of bytes of received data is greater than RX_FIFO (UART_DAT) size 16 bytes, this bit will be set. 251 * | | |0 = RX FIFO is not overflow. 252 * | | |1 = RX FIFO is overflow. 253 * | | |Note: This bit can be cleared by writing '1' to it. 254 * |[1] |ABRDIF |Auto-baud Rate Detect Interrupt Flag 255 * | | |This bit is set to logic '1' when auto-baud rate detect function is finished. 256 * | | |0 = Auto-baud rate detect function is not finished. 257 * | | |1 = Auto-baud rate detect function is finished. 258 * | | |Note: This bit can be cleared by writing '1' to it. 259 * |[2] |ABRDTOIF |Auto-baud Rate Detect Time-out Interrupt Flag 260 * | | |This bit is set to logic '1' in Auto-baud Rate Detect mode when the baud rate counter is overflow. 261 * | | |0 = Auto-baud rate counter is underflow. 262 * | | |1 = Auto-baud rate counter is overflow. 263 * | | |Note: This bit can be cleared by writing '1' to it. 264 * |[3] |ADDRDETF |RS-485 Address Byte Detect Flag 265 * | | |0 = Receiver detects a data that is not an address bit (bit 9 ='0'). 266 * | | |1 = Receiver detects a data that is an address bit (bit 9 ='1'). 267 * | | |Note1: This field is used for RS-485 function mode and ADDRDEN (UART_ALTCTL[15]) is set to 1 to enable Address detection mode. 268 * | | |Note2: This bit can be cleared by writing '1' to it. 269 * |[4] |PEF |Parity Error Flag 270 * | | |This bit is set to logic 1 whenever the received character does not have a valid 'parity bit'. 271 * | | |0 = No parity error is generated. 272 * | | |1 = Parity error is generated. 273 * | | |Note: This bit can be cleared by writing '1' to it. 274 * |[5] |FEF |Framing Error Flag 275 * | | |This bit is set to logic 1 whenever the received character does not have a valid 'stop bit' 276 * | | |(that is, the stop bit following the last data bit or parity bit is detected as logic 0). 277 * | | |0 = No framing error is generated. 278 * | | |1 = Framing error is generated. 279 * | | |Note: This bit can be cleared by writing '1' to it. 280 * |[6] |BIF |Break Interrupt Flag 281 * | | |This bit is set to logic 1 whenever the received data input (RX) is held in the 'spacing state' (logic 0) 282 * | | |for longer than a full word transmission time (that is, the total time of start bit + data bits + parity + stop bits). 283 * | | |0 = No Break interrupt is generated. 284 * | | |1 = Break interrupt is generated. 285 * | | |Note: This bit can be cleared by writing '1' to it. 286 * |[13:8] |RXPTR |RX FIFO Pointer (Read Only) 287 * | | |This field indicates the RX FIFO Buffer Pointer 288 * | | |When UART receives one byte from external device, RXPTR increases one 289 * | | |When one byte of RX FIFO is read by CPU, RXPTR decreases one. 290 * | | |The Maximum value shown in RXPTR is 15 291 * | | |When the using level of RX FIFO Buffer equal to 16, the RXFULL bit is set to 1 and RXPTR will show 0 292 * | | |As one byte of RX FIFO is read by CPU, the RXFULL bit is cleared to 0 and RXPTR will show 15 293 * |[14] |RXEMPTY |Receiver FIFO Empty (Read Only) 294 * | | |This bit initiate RX FIFO empty or not. 295 * | | |0 = RX FIFO is not empty. 296 * | | |1 = RX FIFO is empty. 297 * | | |Note: When the last byte of RX FIFO has been read by CPU, hardware sets this bit high 298 * | | |It will be cleared when UART receives any new data. 299 * |[15] |RXFULL |Receiver FIFO Full (Read Only) 300 * | | |This bit initiates RX FIFO full or not. 301 * | | |0 = RX FIFO is not full. 302 * | | |1 = RX FIFO is full. 303 * | | |Note: This bit is set when the number of usage in RX FIFO Buffer is equal to 16, otherwise it is cleared by hardware. 304 * |[21:16] |TXPTR |TX FIFO Pointer (Read Only) 305 * | | |This field indicates the TX FIFO Buffer Pointer 306 * | | |When CPU writes one byte into UART_DAT, TXPTR increases one 307 * | | |When one byte of TX FIFO is transferred to Transmitter Shift Register, TXPTR decreases one. 308 * | | |The Maximum value shown in TXPTR is 15 309 * | | |When the using level of TX FIFO Buffer equal to 16, the TXFULL bit is set to 1 and TXPTR will show 0 310 * | | |As one byte of TX FIFO is transferred to Transmitter Shift Register, the TXFULL bit is cleared to 0 and TXPTR will show 15 311 * |[22] |TXEMPTY |Transmitter FIFO Empty (Read Only) 312 * | | |This bit indicates TX FIFO empty or not. 313 * | | |0 = TX FIFO is not empty. 314 * | | |1 = TX FIFO is empty. 315 * | | |Note: When the last byte of TX FIFO has been transferred to Transmitter Shift Register, hardware sets this bit high 316 * | | |It will be cleared when writing data into UART_DAT (TX FIFO not empty). 317 * |[23] |TXFULL |Transmitter FIFO Full (Read Only) 318 * | | |This bit indicates TX FIFO full or not. 319 * | | |0 = TX FIFO is not full. 320 * | | |1 = TX FIFO is full. 321 * | | |Note: This bit is set when the number of usage in TX FIFO Buffer is equal to 16, otherwise it is cleared by hardware. 322 * |[24] |TXOVIF |TX Overflow Error Interrupt Flag 323 * | | |If TX FIFO (UART_DAT) is full, an additional write to UART_DAT will cause this bit to logic 1. 324 * | | |0 = TX FIFO is not overflow. 325 * | | |1 = TX FIFO is overflow. 326 * | | |Note: This bit can be cleared by writing '1' to it. 327 * |[28] |TXEMPTYF |Transmitter Empty Flag (Read Only) 328 * | | |This bit is set by hardware when TX FIFO (UART_DAT) is empty and the STOP bit of the last byte has been transmitted. 329 * | | |0 = TX FIFO is not empty or the STOP bit of the last byte has been not transmitted. 330 * | | |1 = TX FIFO is empty and the STOP bit of the last byte has been transmitted. 331 * | | |Note: This bit is cleared automatically when TX FIFO is not empty or the last byte transmission has not completed. 332 * |[29] |RXIDLE |RX Idle Status (Read Only) 333 * | | |This bit is set by hardware when RX is idle. 334 * | | |0 = RX is busy. 335 * | | |1 = RX is idle. (Default) 336 * |[31] |TXRXACT |TX and RX Active Status (Read Only) 337 * | | |This bit indicates TX and RX are active or inactive. 338 * | | |0 = TX and RX are inactive. 339 * | | |1 = TX and RX are active. (Default) 340 * | | |Note: When TXRXDIS (UART_FUNCSEL[3]) is set and both TX and RX are in idle state, this bit is cleared 341 * | | |The UART controller can not transmit or receive data at this moment 342 * | | |Otherwise this bit is set. 343 * @var UART_T::INTSTS 344 * Offset: 0x1C UART Interrupt Status Register 345 * --------------------------------------------------------------------------------------------------- 346 * |Bits |Field |Descriptions 347 * | :----: | :----: | :---- | 348 * |[0] |RDAIF |Receive Data Available Interrupt Flag 349 * | | |When the number of bytes in the RX FIFO equals the RFITL then the RDAIF(UART_INTSTS[0]) will be set 350 * | | |If RDAIEN (UART_INTEN [0]) is enabled, the RDA interrupt will be generated. 351 * | | |0 = No RDA interrupt flag is generated. 352 * | | |1 = RDA interrupt flag is generated. 353 * | | |Note: This bit is read only and it will be cleared when the number of unread bytes of RX FIFO drops below the threshold level (RFITL(UART_FIFO[7:4]). 354 * |[1] |THREIF |Transmit Holding Register Empty Interrupt Flag 355 * | | |This bit is set when the last data of TX FIFO is transferred to Transmitter Shift Register 356 * | | |If THREIEN (UART_INTEN[1]) is enabled, the THRE interrupt will be generated. 357 * | | |0 = No THRE interrupt flag is generated. 358 * | | |1 = THRE interrupt flag is generated. 359 * | | |Note: This bit is read only and it will be cleared when writing data into UART_DAT (TX FIFO not empty). 360 * |[2] |RLSIF |Receive Line Interrupt Flag (Read Only) 361 * | | |This bit is set when the RX receive data have parity error, frame error or break error (at least one of 3 bits, BIF(UART_FIFOSTS[6]), FEF(UART_FIFOSTS[5]) and PEF(UART_FIFOSTS[4]), is set) 362 * | | |If RLSIEN (UART_INTEN [2]) is enabled, the RLS interrupt will be generated. 363 * | | |0 = No RLS interrupt flag is generated. 364 * | | |1 = RLS interrupt flag is generated. 365 * | | |Note1: In RS-485 function mode, this field is set include "receiver detect and received address byte character (bit9 = '1') bit" 366 * | | |At the same time, the bit of ADDRDETF (UART_FIFOSTS[3]) is also set. 367 * | | |Note2: This bit is read only and reset to 0 when all bits of BIF (UART_FIFOSTS[6]), FEF(UART_FIFOSTS[5]) and PEF(UART_FIFOSTS[4]) are cleared. 368 * | | |Note3: In RS-485 function mode, this bit is read only and reset to 0 when all bits of BIF (UART_FIFOSTS[6]) , FEF(UART_FIFOSTS[5]), PEF(UART_FIFOSTS[4]) and ADDRDETF (UART_FIFOSTS[3]) are cleared. 369 * |[3] |MODEMIF |MODEM Interrupt Flag (Read Only) 370 * | | |This bit is set when the nCTS pin has state change (CTSDETF (UART_MODEMSTS[0]) = 1) 371 * | | |If MODEMIEN (UART_INTEN [3]) is enabled, the Modem interrupt will be generated. 372 * | | |0 = No Modem interrupt flag is generated. 373 * | | |1 = Modem interrupt flag is generated. 374 * | | |Note: This bit is read only and reset to 0 when bit CTSDETF is cleared by a write 1 on CTSDETF(UART_MODEMSTS[0]). 375 * |[4] |RXTOIF |RX Time-out Interrupt Flag (Read Only) 376 * | | |This bit is set when the RX FIFO is not empty and no activities occurred in the RX FIFO and the time-out counter equal to TOIC (UART_TOUT[7:0]) 377 * | | |If RXTOIEN (UART_INTEN [4]) is enabled, the RX time-out interrupt will be generated. 378 * | | |0 = No RX time-out interrupt flag is generated. 379 * | | |1 = RX time-out interrupt flag is generated. 380 * | | |Note: This bit is read only and user can read UART_DAT (RX is in active) to clear it. 381 * |[5] |BUFERRIF |Buffer Error Interrupt Flag (Read Only) 382 * | | |This bit is set when the TX FIFO or RX FIFO overflows (TXOVIF (UART_FIFOSTS[24]) or RXOVIF (UART_FIFOSTS[0]) is set) 383 * | | |When BUFERRIF (UART_INTSTS[5]) is set, the transfer is not correct 384 * | | |If BUFERRIEN (UART_INTEN [5]) is enabled, the buffer error interrupt will be generated. 385 * | | |0 = No buffer error interrupt flag is generated. 386 * | | |1 = Buffer error interrupt flag is generated. 387 * | | |Note: This bit is cleared if both of RXOVIF(UART_FIFOSTS[0]) and TXOVIF(UART_FIFOSTS[24]) are cleared to 0 by writing 1 to RXOVIF(UART_FIFOSTS[0]) and TXOVIF(UART_FIFOSTS[24]). 388 * |[6] |WKIF |UART Wake-up Interrupt Flag (Read Only) 389 * | | |This bit is set when TOUTWKF (UART_WKSTS[4]), RS485WKF (UART_WKSTS[3]), RFRTWKF (UART_WKSTS[2]), DATWKF (UART_WKSTS[1]) or CTSWKF(UART_WKSTS[0]) is set to 1. 390 * | | |0 = No UART wake-up interrupt flag is generated. 391 * | | |1 = UART wake-up interrupt flag is generated. 392 * | | |Note: This bit is cleared if all of TOUTWKF, RS485WKF, RFRTWKF, DATWKF and CTSWKF are cleared to 0 by writing 1 to the corresponding interrupt flag. 393 * |[7] |LINIF |LIN Bus Interrupt Flag 394 * | | |This bit is set when LIN slave header detect (SLVHDETF (UART_LINSTS[0] = 1)), LIN break detect (BRKDETF(UART_LINSTS[8]=1)), bit error detect (BITEF(UART_LINSTS[9]=1)), LIN slave ID parity error (SLVIDPEF(UART_LINSTS[2] = 1)) or LIN slave header error detect (SLVHEF (UART_LINSTS[1])) 395 * | | |If LINIEN (UART_INTEN [8]) is enabled the LIN interrupt will be generated. 396 * | | |0 = None of SLVHDETF, BRKDETF, BITEF, SLVIDPEF and SLVHEF is generated. 397 * | | |1 = At least one of SLVHDETF, BRKDETF, BITEF, SLVIDPEF and SLVHEF is generated. 398 * | | |Note: This bit is cleared when SLVHDETF(UART_LINSTS[0]), BRKDETF(UART_LINSTS[8]), BITEF(UART_LINSTS[9]), SLVIDPEF (UART_LINSTS[2]) and SLVHEF(UART_LINSTS[1]) all are cleared and software writing '1' to LINIF(UART_INTSTS[7]). 399 * |[8] |RDAINT |Receive Data Available Interrupt Indicator (Read Only) 400 * | | |This bit is set if RDAIEN (UART_INTEN[0]) and RDAIF (UART_INTSTS[0]) are both set to 1. 401 * | | |0 = No RDA interrupt is generated. 402 * | | |1 = RDA interrupt is generated. 403 * |[9] |THREINT |Transmit Holding Register Empty Interrupt Indicator (Read Only) 404 * | | |This bit is set if THREIEN (UART_INTEN[1]) and THREIF(UART_INTSTS[1]) are both set to 1. 405 * | | |0 = No THRE interrupt is generated. 406 * | | |1 = THRE interrupt is generated. 407 * |[10] |RLSINT |Receive Line Status Interrupt Indicator (Read Only) 408 * | | |This bit is set if RLSIEN (UART_INTEN[2]) and RLSIF(UART_INTSTS[2]) are both set to 1. 409 * | | |0 = No RLS interrupt is generated. 410 * | | |1 = RLS interrupt is generated. 411 * |[11] |MODEMINT |MODEM Status Interrupt Indicator (Read Only) 412 * | | |This bit is set if MODEMIEN(UART_INTEN[3]) and MODEMIF(UART_INTSTS[3]) are both set to 1 413 * | | |0 = No Modem interrupt is generated. 414 * | | |1 = Modem interrupt is generated. 415 * |[12] |RXTOINT |RX Time-out Interrupt Indicator (Read Only) 416 * | | |This bit is set if RXTOIEN (UART_INTEN[4]) and RXTOIF(UART_INTSTS[4]) are both set to 1. 417 * | | |0 = No RX time-out interrupt is generated. 418 * | | |1 = RX time-out interrupt is generated. 419 * |[13] |BUFERRINT |Buffer Error Interrupt Indicator (Read Only) 420 * | | |This bit is set if BUFERRIEN(UART_INTEN[5]) and BUFERRIF(UART_ INTSTS[5]) are both set to 1. 421 * | | |0 = No buffer error interrupt is generated. 422 * | | |1 = Buffer error interrupt is generated. 423 * |[14] |WKINT |UART Wake-up Interrupt Indicator (Read Only) 424 * | | |This bit is set if WKIEN (UART_INTEN[6]) and WKIF (UART_INTSTS[6]) are both set to 1. 425 * | | |0 = No UART wake-up interrupt is generated. 426 * | | |1 = UART wake-up interrupt is generated. 427 * |[15] |LININT |LIN Bus Interrupt Indicator (Read Only) 428 * | | |This bit is set if LINIEN (UART_INTEN[8]) and LINIF(UART_INTSTS[7]) are both set to 1. 429 * | | |0 = No LIN Bus interrupt is generated. 430 * | | |1 = The LIN Bus interrupt is generated. 431 * |[18] |HWRLSIF |PDMA Mode Receive Line Status Flag (Read Only) 432 * | | |This bit is set when the RX receive data have parity error, frame error or break error (at least one of 3 bits, BIF (UART_FIFOSTS[6]), FEF (UART_FIFOSTS[5]) and PEF (UART_FIFOSTS[4]) is set) 433 * | | |If RLSIEN (UART_INTEN [2]) is enabled, the RLS interrupt will be generated. 434 * | | |0 = No RLS interrupt flag is generated in PDMA mode. 435 * | | |1 = RLS interrupt flag is generated in PDMA mode. 436 * | | |Note1: In RS-485 function mode, this field include "receiver detect any address byte received address byte character (bit9 = '1') bit". 437 * | | |Note2: In UART function mode, this bit is read only and reset to 0 when all bits of BIF(UART_FIFOSTS[6]) , FEF(UART_FIFOSTS[5]) and PEF(UART_FIFOSTS[4]) are cleared. 438 * | | |Note3: In RS-485 function mode, this bit is read only and reset to 0 when all bits of BIF(UART_FIFOSTS[6]), FEF(UART_FIFOSTS[5]), PEF(UART_FIFOSTS[4]) and ADDRDETF (UART_FIFOSTS[3]) are cleared 439 * |[19] |HWMODIF |PDMA Mode MODEM Interrupt Flag (Read Only) 440 * | | |This bit is set when the nCTS pin has state change (CTSDETF (UART_MODEMSTS [0] =1)) 441 * | | |If MODEMIEN (UART_INTEN [3]) is enabled, the Modem interrupt will be generated. 442 * | | |0 = No Modem interrupt flag is generated in PDMA mode. 443 * | | |1 = Modem interrupt flag is generated in PDMA mode. 444 * | | |Note: This bit is read only and reset to 0 when the bit CTSDETF (UART_MODEMSTS[0]) is cleared by writing 1 on CTSDETF (UART_MODEMSTS [0]). 445 * |[20] |HWTOIF |PDMA Mode RX Time-out Interrupt Flag (Read Only) 446 * | | |This bit is set when the RX FIFO is not empty and no activities occurred in the RX FIFO and the time-out counter equal to TOIC (UART_TOUT[7:0]) 447 * | | |If RXTOIEN (UART_INTEN [4]) is enabled, the RX time-out interrupt will be generated . 448 * | | |0 = No RX time-out interrupt flag is generated in PDMA mode. 449 * | | |1 = RX time-out interrupt flag is generated in PDMA mode. 450 * | | |Note: This bit is read only and user can read UART_DAT (RX is in active) to clear it. 451 * |[21] |HWBUFEIF |PDMA Mode Buffer Error Interrupt Flag (Read Only) 452 * | | |This bit is set when the TX or RX FIFO overflows (TXOVIF (UART_FIFOSTS [24]) or RXOVIF (UART_FIFOSTS[0]) is set) 453 * | | |When BUFERRIF (UART_INTSTS[5]) is set, the transfer maybe is not correct 454 * | | |If BUFERRIEN (UART_INTEN [5]) is enabled, the buffer error interrupt will be generated. 455 * | | |0 = No buffer error interrupt flag is generated in PDMA mode. 456 * | | |1 = Buffer error interrupt flag is generated in PDMA mode. 457 * | | |Note: This bit is cleared when both TXOVIF (UART_FIFOSTS[24]]) and RXOVIF (UART_FIFOSTS[0]) are cleared. 458 * |[22] |TXENDIF |Transmitter Empty Interrupt Flag 459 * | | |This bit is set when TX FIFO (UART_DAT) is empty and the STOP bit of the last byte has been transmitted (TXEMPTYF (UART_FIFOSTS[28]) is set) 460 * | | |If TXENDIEN (UART_INTEN[22]) is enabled, the Transmitter Empty interrupt will be generated. 461 * | | |0 = No transmitter empty interrupt flag is generated. 462 * | | |1 = Transmitter empty interrupt flag is generated. 463 * | | |Note: This bit is cleared automatically when TX FIFO is not empty or the last byte transmission has not completed. 464 * |[26] |HWRLSINT |PDMA Mode Receive Line Status Interrupt Indicator (Read Only) 465 * | | |This bit is set if RLSIEN (UART_INTEN[2]) and HWRLSIF(UART_INTSTS[18]) are both set to 1. 466 * | | |0 = No RLS interrupt is generated in PDMA mode. 467 * | | |1 = RLS interrupt is generated in PDMA mode. 468 * |[27] |HWMODINT |PDMA Mode MODEM Status Interrupt Indicator (Read Only) 469 * | | |This bit is set if MODEMIEN (UART_INTEN[3]) and HWMODIF(UART_INTSTS[19]) are both set to 1. 470 * | | |0 = No Modem interrupt is generated in PDMA mode. 471 * | | |1 = Modem interrupt is generated in PDMA mode. 472 * |[28] |HWTOINT |PDMA Mode RX Time-out Interrupt Indicator (Read Only) 473 * | | |This bit is set if RXTOIEN (UART_INTEN[4]) and HWTOIF(UART_INTSTS[20]) are both set to 1. 474 * | | |0 = No RX time-out interrupt is generated in PDMA mode. 475 * | | |1 = RX time-out interrupt is generated in PDMA mode. 476 * |[29] |HWBUFEINT |PDMA Mode Buffer Error Interrupt Indicator (Read Only) 477 * | | |This bit is set if BUFERRIEN (UART_INTEN[5]) and HWBUFEIF (UART_INTSTS[21]) are both set to 1. 478 * | | |0 = No buffer error interrupt is generated in PDMA mode. 479 * | | |1 = Buffer error interrupt is generated in PDMA mode. 480 * |[30] |TXENDINT |Transmitter Empty Interrupt Indicator (Read Only) 481 * | | |This bit is set if TXENDIEN (UART_INTEN[22]) and TXENDIF(UART_INTSTS[22]) are both set to 1. 482 * | | |0 = No Transmitter Empty interrupt is generated. 483 * | | |1 = Transmitter Empty interrupt is generated. 484 * |[31] |ABRINT |Auto-baud Rate Interrupt Indicator (Read Only) 485 * | | |This bit is set if ABRIEN (UART_INTEN[18]) and ABRIF (UART_ALTCTL[17]) are both set to 1. 486 * | | |0 = No Auto-baud Rate interrupt is generated. 487 * | | |1 = The Auto-baud Rate interrupt is generated. 488 * @var UART_T::TOUT 489 * Offset: 0x20 UART Time-out Register 490 * --------------------------------------------------------------------------------------------------- 491 * |Bits |Field |Descriptions 492 * | :----: | :----: | :---- | 493 * |[7:0] |TOIC |Time-out Interrupt Comparator 494 * | | |The time-out counter resets and starts counting (the counting clock = baud rate) whenever the RX FIFO receives a new data word if time out counter is enabled by setting TOCNTEN (UART_INTEN[11]) 495 * | | |Once the content of time-out counter is equal to that of time-out interrupt comparator (TOIC (UART_TOUT[7:0])), a receiver time-out interrupt (RXTOINT(UART_INTSTS[12])) is generated if RXTOIEN (UART_INTEN [4]) enabled 496 * | | |A new incoming data word or RX FIFO empty will clear RXTOIF (UART_INTSTS[4]) 497 * | | |In order to avoid receiver time-out interrupt generation immediately during one character is being received, TOIC value should be set between 40 and 255 498 * | | |So, for example, if TOIC is set with 40, the time-out interrupt is generated after four characters are not received when 1 stop bit and no parity check is set for UART transfer. 499 * |[15:8] |DLY |TX Delay Time Value 500 * | | |This field is used to programming the transfer delay time between the last stop bit and next start bit 501 * | | |The unit is bit time. 502 * @var UART_T::BAUD 503 * Offset: 0x24 UART Baud Rate Divider Register 504 * --------------------------------------------------------------------------------------------------- 505 * |Bits |Field |Descriptions 506 * | :----: | :----: | :---- | 507 * |[15:0] |BRD |Baud Rate Divider 508 * | | |The field indicates the baud rate divider 509 * | | |This filed is used in baud rate calculation 510 * | | |The detail description is shown in Table 7.15-4. 511 * |[27:24] |EDIVM1 |Extra Divider for BAUD Rate Mode 1 512 * | | |This field is used for baud rate calculation in mode 1 and has no effect for baud rate calculation in mode 0 and mode 2 513 * | | |The detail description is shown in Table 7.15-4 514 * |[28] |BAUDM0 |BAUD Rate Mode Selection Bit 0 515 * | | |This bit is baud rate mode selection bit 0 516 * | | |UART provides three baud rate calculation modes 517 * | | |This bit combines with BAUDM1 (UART_BAUD[29]) to select baud rate calculation mode 518 * | | |The detail description is shown in Table 7.15-4. 519 * |[29] |BAUDM1 |BAUD Rate Mode Selection Bit 1 520 * | | |This bit is baud rate mode selection bit 1 521 * | | |UART provides three baud rate calculation modes 522 * | | |This bit combines with BAUDM0 (UART_BAUD[28]) to select baud rate calculation mode 523 * | | |The detail description is shown in Table 7.15-4. 524 * | | |Note: In IrDA mode must be operated in mode 0. 525 * @var UART_T::IRDA 526 * Offset: 0x28 UART IrDA Control Register 527 * --------------------------------------------------------------------------------------------------- 528 * |Bits |Field |Descriptions 529 * | :----: | :----: | :---- | 530 * |[1] |TXEN |IrDA Receiver/Transmitter Selection Enable Bit 531 * | | |0 = IrDA Transmitter Disabled and Receiver Enabled. (Default) 532 * | | |1 = IrDA Transmitter Enabled and Receiver Disabled. 533 * |[5] |TXINV |IrDA Inverse Transmitting Output Signal 534 * | | |0 = None inverse transmitting signal. (Default). 535 * | | |1 = Inverse transmitting output signal. 536 * | | |Note1: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 537 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 538 * | | |Note2: This bit is valid when FUNCSEL (UART_FUNCSEL[1:0]) is select IrDA function. 539 * |[6] |RXINV |IrDA Inverse Receive Input Signal 540 * | | |0 = None inverse receiving input signal. 541 * | | |1 = Inverse receiving input signal. (Default) 542 * | | |Note1: Before setting this bit, TXRXDIS (UART_FUNCSEL[3]) should be set then waited for TXRXACT (UART_FIFOSTS[31]) is cleared 543 * | | |When the configuration is done, cleared TXRXDIS (UART_FUNCSEL[3]) to activate UART controller. 544 * | | |Note2: This bit is valid when FUNCSEL (UART_FUNCSEL[1:0]) is select IrDA function. 545 * @var UART_T::ALTCTL 546 * Offset: 0x2C UART Alternate Control/Status Register 547 * --------------------------------------------------------------------------------------------------- 548 * |Bits |Field |Descriptions 549 * | :----: | :----: | :---- | 550 * |[3:0] |BRKFL |UART LIN Break Field Length 551 * | | |This field indicates a 4-bit LIN TX break field count. 552 * | | |Note1: This break field length is BRKFL + 1. 553 * | | |Note2: According to LIN spec, the reset value is 0xC (break field length = 13). 554 * |[6] |LINRXEN |LIN RX Enable Bit 555 * | | |0 = LIN RX mode Disabled. 556 * | | |1 = LIN RX mode Enabled. 557 * |[7] |LINTXEN |LIN TX Break Mode Enable Bit 558 * | | |0 = LIN TX Break mode Disabled. 559 * | | |1 = LIN TX Break mode Enabled. 560 * | | |Note: When TX break field transfer operation finished, this bit will be cleared automatically. 561 * |[8] |RS485NMM |RS-485 Normal Multi-drop Operation Mode (NMM) 562 * | | |0 = RS-485 Normal Multi-drop Operation mode (NMM) Disabled. 563 * | | |1 = RS-485 Normal Multi-drop Operation mode (NMM) Enabled. 564 * | | |Note: It cannot be active with RS-485_AAD operation mode. 565 * |[9] |RS485AAD |RS-485 Auto Address Detection Operation Mode (AAD) 566 * | | |0 = RS-485 Auto Address Detection Operation mode (AAD) Disabled. 567 * | | |1 = RS-485 Auto Address Detection Operation mode (AAD) Enabled. 568 * | | |Note: It cannot be active with RS-485_NMM operation mode. 569 * |[10] |RS485AUD |RS-485 Auto Direction Function (AUD) 570 * | | |0 = RS-485 Auto Direction Operation function (AUD) Disabled. 571 * | | |1 = RS-485 Auto Direction Operation function (AUD) Enabled. 572 * | | |Note: It can be active with RS-485_AAD or RS-485_NMM operation mode. 573 * |[15] |ADDRDEN |RS-485 Address Detection Enable Bit 574 * | | |This bit is used to enable RS-485 Address Detection mode. 575 * | | |0 = Address detection mode Disabled. 576 * | | |1 = Address detection mode Enabled. 577 * | | |Note: This bit is used for RS-485 any operation mode. 578 * |[17] |ABRIF |Auto-baud Rate Interrupt Flag (Read Only) 579 * | | |This bit is set when auto-baud rate detection function finished or the auto-baud rate counter was overflow and if ABRIEN(UART_INTEN [18]) is set then the auto-baud rate interrupt will be generated. 580 * | | |0 = No auto-baud rate interrupt flag is generated. 581 * | | |1 = Auto-baud rate interrupt flag is generated. 582 * | | |Note: This bit is read only, but it can be cleared by writing '1' to ABRDTOIF (UART_FIFOSTS[2]) and ABRDIF(UART_FIFOSTS[1]) 583 * |[18] |ABRDEN |Auto-baud Rate Detect Enable Bit 584 * | | |0 = Auto-baud rate detect function Disabled. 585 * | | |1 = Auto-baud rate detect function Enabled. 586 * | | |Note : This bit is cleared automatically after auto-baud detection is finished. 587 * |[20:19] |ABRDBITS |Auto-baud Rate Detect Bit Length 588 * | | |00 = 1-bit time from Start bit to the 1st rising edge. The input pattern shall be 0x01. 589 * | | |01 = 2-bit time from Start bit to the 1st rising edge. The input pattern shall be 0x02. 590 * | | |10 = 4-bit time from Start bit to the 1st rising edge. The input pattern shall be 0x08. 591 * | | |11 = 8-bit time from Start bit to the 1st rising edge. The input pattern shall be 0x80. 592 * | | |Note : The calculation of bit number includes the START bit. 593 * |[31:24] |ADDRMV |Address Match Value 594 * | | |This field contains the RS-485 address match values. 595 * | | |Note: This field is used for RS-485 auto address detection mode. 596 * @var UART_T::FUNCSEL 597 * Offset: 0x30 UART Function Select Register 598 * --------------------------------------------------------------------------------------------------- 599 * |Bits |Field |Descriptions 600 * | :----: | :----: | :---- | 601 * |[1:0] |FUNCSEL |Function Select 602 * | | |00 = UART function. 603 * | | |01 = LIN function. 604 * | | |10 = IrDA function. 605 * | | |11 = RS-485 function. 606 * |[3] |TXRXDIS |TX and RX Disable Bit 607 * | | |Setting this bit can disable TX and RX. 608 * | | |0 = TX and RX Enabled. 609 * | | |1 = TX and RX Disabled. 610 * | | |Note: The TX and RX will not disable immediately when this bit is set 611 * | | |The TX and RX complete current task before disable TX and RX 612 * | | |When TX and RX disable, the TXRXACT (UART_FIFOSTS[31]) is cleared. 613 * @var UART_T::LINCTL 614 * Offset: 0x34 UART LIN Control Register 615 * --------------------------------------------------------------------------------------------------- 616 * |Bits |Field |Descriptions 617 * | :----: | :----: | :---- | 618 * |[0] |SLVEN |LIN Slave Mode Enable Bit 619 * | | |0 = LIN slave mode Disabled. 620 * | | |1 = LIN slave mode Enabled. 621 * |[1] |SLVHDEN |LIN Slave Header Detection Enable Bit 622 * | | |0 = LIN slave header detection Disabled. 623 * | | |1 = LIN slave header detection Enabled. 624 * | | |Note1: This bit only valid when in LIN slave mode (SLVEN (UART_LINCTL[0]) = 1). 625 * | | |Note2: In LIN function mode, when detect header field (break + sync + frame ID), SLVHDETF (UART_LINSTS [0]) flag will be asserted 626 * | | |If the LINIEN (UART_INTEN[8]) = 1, an interrupt will be generated. 627 * |[2] |SLVAREN |LIN Slave Automatic Resynchronization Mode Enable Bit 628 * | | |0 = LIN automatic resynchronization Disabled. 629 * | | |1 = LIN automatic resynchronization Enabled. 630 * | | |Note1: This bit only valid when in LIN slave mode (SLVEN (UART_LINCTL[0]) = 1). 631 * | | |Note2: When operation in Automatic Resynchronization mode, the baud rate setting must be mode2 (BAUDM1 (UART_BAUD [29]) and BAUDM0 (UART_BAUD [28]) must be 1). 632 * | | |Note3: The control and interactions of this field are explained in 7.15.5.9 (Slave mode with automatic resynchronization). 633 * |[3] |SLVDUEN |LIN Slave Divider Update Method Enable Bit 634 * | | |0 = UART_BAUD updated is written by software (if no automatic resynchronization update occurs at the same time). 635 * | | |1 = UART_BAUD is updated at the next received character 636 * | | |User must set the bit before checksum reception. 637 * | | |Note1: This bit only valid when in LIN slave mode (SLVEN (UART_LINCTL[0]) = 1). 638 * | | |Note2: This bit used for LIN Slave Automatic Resynchronization mode 639 * | | |(for Non-Automatic Resynchronization mode, this bit should be kept cleared) 640 * | | |Note3: The control and interactions of this field are explained in 7.15.5.9 (Slave mode with automatic resynchronization). 641 * |[4] |MUTE |LIN Mute Mode Enable Bit 642 * | | |0 = LIN mute mode Disabled. 643 * | | |1 = LIN mute mode Enabled. 644 * | | |Note: The exit from mute mode condition and each control and interactions of this field are explained in 7.15.5.9 (LIN slave mode). 645 * |[8] |SENDH |LIN TX Send Header Enable Bit 646 * | | |The LIN TX header can be break field or 'break and sync field' or 'break, sync and frame ID field', it is depend on setting HSEL (UART_LINCTL[23:22]). 647 * | | |0 = Send LIN TX header Disabled. 648 * | | |1 = Send LIN TX header Enabled. 649 * | | |Note1: This bit is shadow bit of LINTXEN (UART_ALTCTL [7]); user can read/write it by setting LINTXEN (UART_ALTCTL [7]) or SENDH (UART_LINCTL [8]). 650 * | | |Note2: When transmitter header field (it may be 'break' or 'break + sync' or 'break + sync + frame ID' selected by HSEL (UART_LINCTL[23:22]) field) transfer operation finished, this bit will be cleared automatically. 651 * |[9] |IDPEN |LIN ID Parity Enable Bit 652 * | | |0 = LIN frame ID parity Disabled. 653 * | | |1 = LIN frame ID parity Enabled. 654 * | | |Note1: This bit can be used for LIN master to sending header field (SENDH (UART_LINCTL[8])) = 1 and HSEL (UART_LINCTL[23:22]) = 10 or be used for enable LIN slave received frame ID parity checked. 655 * | | |Note2: This bit is only used when the operation header transmitter is in HSEL (UART_LINCTL[23:22]) = 10 656 * |[10] |BRKDETEN |LIN Break Detection Enable Bit 657 * | | |When detect consecutive dominant greater than 11 bits, and are followed by a delimiter character, the BRKDETF (UART_LINSTS[8]) flag is set at the end of break field 658 * | | |If the LINIEN (UART_INTEN [8])=1, an interrupt will be generated. 659 * | | |0 = LIN break detection Disabled . 660 * | | |1 = LIN break detection Enabled. 661 * |[11] |LINRXOFF |LIN Receiver Disable Bit 662 * | | |If the receiver is enabled (LINRXOFF (UART_LINCTL[11] ) = 0), all received byte data will be accepted and stored in the RX FIFO, and if the receiver is disabled (LINRXOFF (UART_LINCTL[11] = 1), all received byte data will be ignore. 663 * | | |0 = LIN receiver Enabled. 664 * | | |1 = LIN receiver Disabled. 665 * | | |Note: This bit is only valid when operating in LIN function mode (FUNCSEL (UART_FUNCSEL[1:0]) = 01). 666 * |[12] |BITERREN |Bit Error Detect Enable Bit 667 * | | |0 = Bit error detection function Disabled. 668 * | | |1 = Bit error detection function Enabled. 669 * | | |Note: In LIN function mode, when occur bit error, the BITEF (UART_LINSTS[9]) flag will be asserted 670 * | | |If the LINIEN (UART_INTEN[8]) = 1, an interrupt will be generated. 671 * |[19:16] |BRKFL |LIN Break Field Length 672 * | | |This field indicates a 4-bit LIN TX break field count. 673 * | | |Note1: These registers are shadow registers of BRKFL (UART_ALTCTL[3:0]), User can read/write it by setting BRKFL (UART_ALTCTL[3:0]) or BRKFL (UART_LINCTL[19:16]). 674 * | | |Note2: This break field length is BRKFL + 1. 675 * | | |Note3: According to LIN spec, the reset value is 12 (break field length = 13). 676 * |[21:20] |BSL |LIN Break/Sync Delimiter Length 677 * | | |00 = The LIN break/sync delimiter length is 1-bit time. 678 * | | |01 = The LIN break/sync delimiter length is 2-bit time. 679 * | | |10 = The LIN break/sync delimiter length is 3-bit time. 680 * | | |11 = The LIN break/sync delimiter length is 4-bit time. 681 * | | |Note: This bit used for LIN master to sending header field. 682 * |[23:22] |HSEL |LIN Header Select 683 * | | |00 = The LIN header includes 'break field'. 684 * | | |01 = The LIN header includes 'break field' and 'sync field'. 685 * | | |10 = The LIN header includes 'break field', 'sync field' and 'frame ID field'. 686 * | | |11 = Reserved. 687 * | | |Note: This bit is used to master mode for LIN to send header field (SENDH (UART_LINCTL [8]) = 1) or used to slave to indicates exit from mute mode condition (MUTE (UART_LINCTL[4] = 1). 688 * |[31:24] |PID |LIN PID Bits 689 * | | |This field contains the LIN frame ID value when in LIN function mode, the frame ID parity can be generated by software or hardware depends on IDPEN (UART_LINCTL[9]) = 1. 690 * | | |If the parity generated by hardware, user fill ID0~ID5 (PID [29:24] ), hardware will calculate P0 (PID[30]) and P1 (PID[31]), otherwise user must filled frame ID and parity in this field. 691 * | | |Note1: User can fill any 8-bit value to this field and the bit 24 indicates ID0 (LSB first). 692 * | | |Note2: This field can be used for LIN master mode or slave mode. 693 * @var UART_T::LINSTS 694 * Offset: 0x38 UART LIN Status Register 695 * --------------------------------------------------------------------------------------------------- 696 * |Bits |Field |Descriptions 697 * | :----: | :----: | :---- | 698 * |[0] |SLVHDETF |LIN Slave Header Detection Flag 699 * | | |This bit is set by hardware when a LIN header is detected in LIN slave mode and be cleared by writing 1 to it. 700 * | | |0 = LIN header not detected. 701 * | | |1 = LIN header detected (break + sync + frame ID). 702 * | | |Note1: This bit can be cleared by writing 1 to it. 703 * | | |Note2: This bit is only valid when in LIN slave mode (SLVEN (UART_LINCTL [0]) = 1) and enable LIN slave header detection function (SLVHDEN (UART_LINCTL [1])). 704 * | | |Note3: When enable ID parity check IDPEN (UART_LINCTL [9]), if hardware detect complete header ('break + sync + frame ID'), the SLVHDETF will be set whether the frame ID correct or not. 705 * |[1] |SLVHEF |LIN Slave Header Error Flag 706 * | | |This bit is set by hardware when a LIN header error is detected in LIN slave mode and be cleared by writing 1 to it 707 * | | |The header errors include 'break delimiter is too short (less than 0.5 bit time)', 'frame error in sync field or Identifier field', 708 * | | |'sync field data is not 0x55 in Non-Automatic Resynchronization mode', 'sync field deviation error with Automatic Resynchronization mode', 709 * | | |'sync field measure time-out with Automatic Resynchronization mode' and 'LIN header reception time-out'. 710 * | | |0 = LIN header error not detected. 711 * | | |1 = LIN header error detected. 712 * | | |Note1: This bit can be cleared by writing 1 to it. 713 * | | |Note2: This bit is only valid when UART is operated in LIN slave mode (SLVEN (UART_LINCTL [0]) = 1) and 714 * | | |enables LIN slave header detection function (SLVHDEN (UART_LINCTL [1])). 715 * |[2] |SLVIDPEF |LIN Slave ID Parity Error Flag 716 * | | |This bit is set by hardware when receipted frame ID parity is not correct. 717 * | | |0 = No active. 718 * | | |1 = Receipted frame ID parity is not correct. 719 * | | |Note1: This bit can be cleared by writing 1 to it. 720 * | | |Note2: This bit is only valid when in LIN slave mode (SLVEN (UART_LINCTL [0])= 1) and enable LIN frame ID parity check function IDPEN (UART_LINCTL [9]). 721 * |[3] |SLVSYNCF |LIN Slave Sync Field 722 * | | |This bit indicates that the LIN sync field is being analyzed in Automatic Resynchronization mode 723 * | | |When the receiver header have some error been detect, user must reset the internal circuit to re-search new frame header by writing 1 to this bit. 724 * | | |0 = The current character is not at LIN sync state. 725 * | | |1 = The current character is at LIN sync state. 726 * | | |Note1: This bit is only valid when in LIN Slave mode (SLVEN(UART_LINCTL[0]) = 1). 727 * | | |Note2: This bit can be cleared by writing 1 to it. 728 * | | |Note3: When writing 1 to it, hardware will reload the initial baud rate and re-search a new frame header. 729 * |[8] |BRKDETF |LIN Break Detection Flag 730 * | | |This bit is set by hardware when a break is detected and be cleared by writing 1 to it through software. 731 * | | |0 = LIN break not detected. 732 * | | |1 = LIN break detected. 733 * | | |Note1: This bit can be cleared by writing 1 to it. 734 * | | |Note2: This bit is only valid when LIN break detection function is enabled (BRKDETEN (UART_LINCTL[10]) =1). 735 * |[9] |BITEF |Bit Error Detect Status Flag 736 * | | |At TX transfer state, hardware will monitor the bus state, if the input pin (UART_RXD) state not equals to the output pin (UART_TXD) state, BITEF (UART_LINSTS[9]) will be set. 737 * | | |When occur bit error, if the LINIEN (UART_INTEN[8]) = 1, an interrupt will be generated. 738 * | | |0 = Bit error not detected. 739 * | | |1 = Bit error detected. 740 * | | |Note1: This bit can be cleared by writing 1 to it. 741 * | | |Note2: This bit is only valid when enable bit error detection function (BITERREN (UART_LINCTL [12]) = 1). 742 * @var UART_T::BRCOMP 743 * Offset: 0x3C UART Baud Rate Compensation Register 744 * --------------------------------------------------------------------------------------------------- 745 * |Bits |Field |Descriptions 746 * | :----: | :----: | :---- | 747 * |[8:0] |BRCOMP |Baud Rate Compensation Patten 748 * | | |These 9-bits are used to define the relative bit is compensated or not. 749 * | | |BRCOMP[7:0] is used to define the compensation of UART_DAT[7:0] and BRCOM[8] is used to define the parity bit. 750 * |[31] |BRCOMPDEC |Baud Rate Compensation Decrease 751 * | | |0 = Positive (increase one module clock) compensation for each compensated bit. 752 * | | |1 = Negative (decrease one module clock) compensation for each compensated bit. 753 * @var UART_T::WKCTL 754 * Offset: 0x40 UART Wake-up Control Register 755 * --------------------------------------------------------------------------------------------------- 756 * |Bits |Field |Descriptions 757 * | :----: | :----: | :---- | 758 * |[0] |WKCTSEN |nCTS Wake-up Enable Bit 759 * | | |0 = nCTS Wake-up system function Disabled. 760 * | | |1 = nCTS Wake-up system function Enabled, when the system is in Power-down mode, an external. 761 * | | |nCTS change will wake-up system from Power-down mode. 762 * |[1] |WKDATEN |Incoming Data Wake-up Enable Bit 763 * | | |0 = Incoming data wake-up system function Disabled. 764 * | | |1 = Incoming data wake-up system function Enabled, when the system is in Power-down mode,. 765 * | | |incoming data will wake-up system from Power-down mode. 766 * |[2] |WKRFRTEN |Received Data FIFO Reached Threshold Wake-up Enable Bit 767 * | | |0 = Received Data FIFO reached threshold wake-up system function Disabled. 768 * | | |1 = Received Data FIFO reached threshold wake-up system function Enabled, when the system is. 769 * | | |in Power-down mode, Received Data FIFO reached threshold will wake-up system from 770 * | | |Power-down mode. 771 * |[3] |WKRS485EN |RS-485 Address Match (AAD Mode) Wake-up Enable Bit 772 * | | |0 = RS-485 Address Match (AAD mode) wake-up system function Disabled. 773 * | | |1 = RS-485 Address Match (AAD mode) wake-up system function Enabled, when the system is in. 774 * | | |Power-down mode, RS-485 Address Match will wake-up system from Power-down mode. 775 * | | |Note: This bit is used for RS-485 Auto Address Detection (AAD) mode in RS-485 function mode 776 * | | |and ADDRDEN (UART_ALTCTL[15]) is set to 1. 777 * |[4] |WKTOUTEN |Received Data FIFO Reached Threshold Time-out Wake-up Enable Bit 778 * | | |0 = Received Data FIFO reached threshold time-out wake-up system function Disabled. 779 * | | |1 = Received Data FIFO reached threshold time-out wake-up system function Enabled, when the. 780 * | | |system is in Power-down mode, Received Data FIFO reached threshold time-out will wake-up 781 * | | |system from Power-down mode. 782 * | | |Note: It is suggest the function is enabled when the WKRFRTEN (UART_WKCTL[2]) is set to 1. 783 * @var UART_T::WKSTS 784 * Offset: 0x44 UART Wake-up Status Register 785 * --------------------------------------------------------------------------------------------------- 786 * |Bits |Field |Descriptions 787 * | :----: | :----: | :---- | 788 * |[0] |CTSWKF |nCTS Wake-up Flag 789 * | | |This bit is set if chip wake-up from power-down state by nCTS wake-up. 790 * | | |0 = Chip stays in power-down state. 791 * | | |1 = Chip wake-up from power-down state by nCTS wake-up. 792 * | | |Note1: If WKCTSEN (UART_WKCTL[0]) is enabled, the nCTS wake-up cause this bit is set to '1'. 793 * | | |Note2: This bit can be cleared by writing '1' to it. 794 * |[1] |DATWKF |Incoming Data Wake-up Flag 795 * | | |This bit is set if chip wake-up from power-down state by data wake-up. 796 * | | |0 = Chip stays in power-down state. 797 * | | |1 = Chip wake-up from power-down state by Incoming Data wake-up. 798 * | | |Note1: If WKDATEN (UART_WKCTL[1]) is enabled, the Incoming Data wake-up cause this bit is set to '1'. 799 * | | |Note2: This bit can be cleared by writing '1' to it. 800 * |[2] |RFRTWKF |Received Data FIFO Reached Threshold Wake-up Flag 801 * | | |This bit is set if chip wake-up from power-down state by Received Data FIFO reached threshold 802 * | | |wake-up . 803 * | | |0 = Chip stays in power-down state. 804 * | | |1 = Chip wake-up from power-down state by Received Data FIFO Reached Threshold wake-up. 805 * | | |Note1: If WKRFRTEN (UART_WKCTL[2]) is enabled, the Received Data FIFO Reached Threshold wake-up cause this bit is set to '1'. 806 * | | |Note2: This bit can be cleared by writing '1' to it. 807 * |[3] |RS485WKF |RS-485 Address Match (AAD Mode) Wake-up Flag 808 * | | |This bit is set if chip wake-up from power-down state by RS-485 Address Match (AAD mode). 809 * | | |0 = Chip stays in power-down state. 810 * | | |1 = Chip wake-up from power-down state by RS-485 Address Match (AAD mode) wake-up. 811 * | | |Note1: If WKRS485EN (UART_WKCTL[3]) is enabled, the RS-485 Address Match (AAD mode) wake-up cause this bit is set to '1'. 812 * | | |Note2: This bit can be cleared by writing '1' to it. 813 * |[4] |TOUTWKF |Received Data FIFO Threshold Time-out Wake-up Flag 814 * | | |This bit is set if chip wake-up from power-down state by Received Data FIFO Threshold Time-out 815 * | | |wake-up. 816 * | | |0 = Chip stays in power-down state. 817 * | | |1 = Chip wake-up from power-down state by Received Data FIFO reached threshold time-out. 818 * | | |wake-up. 819 * | | |Note1: If WKTOUTEN (UART_WKCTL[4]) is enabled, the Received Data FIFO reached threshold time-out wake-up cause this bit is set to '1'. 820 * | | |Note2: This bit can be cleared by writing '1' to it. 821 * @var UART_T::DWKCOMP 822 * Offset: 0x48 UART Incoming Data Wake-up Compensation Register 823 * --------------------------------------------------------------------------------------------------- 824 * |Bits |Field |Descriptions 825 * | :----: | :----: | :---- | 826 * |[15:0] |STCOMP |Start Bit Compensation Value 827 * | | |These bits field indicate how many clock cycle selected by UART_CLK do the UART controller can get the 1st bit (start bit) when the device is wake-up from power-down mode. 828 * | | |Note: It is valid only when WKDATEN (UART_WKCTL[1]) is set. 829 */ 830 __IO uint32_t DAT; /*!< [0x0000] UART Receive/Transmit Buffer Register */ 831 __IO uint32_t INTEN; /*!< [0x0004] UART Interrupt Enable Register */ 832 __IO uint32_t FIFO; /*!< [0x0008] UART FIFO Control Register */ 833 __IO uint32_t LINE; /*!< [0x000c] UART Line Control Register */ 834 __IO uint32_t MODEM; /*!< [0x0010] UART Modem Control Register */ 835 __IO uint32_t MODEMSTS; /*!< [0x0014] UART Modem Status Register */ 836 __IO uint32_t FIFOSTS; /*!< [0x0018] UART FIFO Status Register */ 837 __IO uint32_t INTSTS; /*!< [0x001c] UART Interrupt Status Register */ 838 __IO uint32_t TOUT; /*!< [0x0020] UART Time-out Register */ 839 __IO uint32_t BAUD; /*!< [0x0024] UART Baud Rate Divider Register */ 840 __IO uint32_t IRDA; /*!< [0x0028] UART IrDA Control Register */ 841 __IO uint32_t ALTCTL; /*!< [0x002c] UART Alternate Control/Status Register */ 842 __IO uint32_t FUNCSEL; /*!< [0x0030] UART Function Select Register */ 843 __IO uint32_t LINCTL; /*!< [0x0034] UART LIN Control Register */ 844 __IO uint32_t LINSTS; /*!< [0x0038] UART LIN Status Register */ 845 __IO uint32_t BRCOMP; /*!< [0x003c] UART Baud Rate Compensation Register */ 846 __IO uint32_t WKCTL; /*!< [0x0040] UART Wake-up Control Register */ 847 __IO uint32_t WKSTS; /*!< [0x0044] UART Wake-up Status Register */ 848 __IO uint32_t DWKCOMP; /*!< [0x0048] UART Incoming Data Wake-up Compensation Register */ 849 850 } UART_T; 851 852 /** 853 @addtogroup UART_CONST UART Bit Field Definition 854 Constant Definitions for UART Controller 855 @{ */ 856 857 #define UART_DAT_DAT_Pos (0) /*!< UART_T::DAT: DAT Position */ 858 #define UART_DAT_DAT_Msk (0xfful << UART_DAT_DAT_Pos) /*!< UART_T::DAT: DAT Mask */ 859 860 #define UART_DAT_PARITY_Pos (8) /*!< UART_T::DAT: PARITY Position */ 861 #define UART_DAT_PARITY_Msk (0x1ul << UART_DAT_PARITY_Pos) /*!< UART_T::DAT: PARITY Mask */ 862 863 #define UART_INTEN_RDAIEN_Pos (0) /*!< UART_T::INTEN: RDAIEN Position */ 864 #define UART_INTEN_RDAIEN_Msk (0x1ul << UART_INTEN_RDAIEN_Pos) /*!< UART_T::INTEN: RDAIEN Mask */ 865 866 #define UART_INTEN_THREIEN_Pos (1) /*!< UART_T::INTEN: THREIEN Position */ 867 #define UART_INTEN_THREIEN_Msk (0x1ul << UART_INTEN_THREIEN_Pos) /*!< UART_T::INTEN: THREIEN Mask */ 868 869 #define UART_INTEN_RLSIEN_Pos (2) /*!< UART_T::INTEN: RLSIEN Position */ 870 #define UART_INTEN_RLSIEN_Msk (0x1ul << UART_INTEN_RLSIEN_Pos) /*!< UART_T::INTEN: RLSIEN Mask */ 871 872 #define UART_INTEN_MODEMIEN_Pos (3) /*!< UART_T::INTEN: MODEMIEN Position */ 873 #define UART_INTEN_MODEMIEN_Msk (0x1ul << UART_INTEN_MODEMIEN_Pos) /*!< UART_T::INTEN: MODEMIEN Mask */ 874 875 #define UART_INTEN_RXTOIEN_Pos (4) /*!< UART_T::INTEN: RXTOIEN Position */ 876 #define UART_INTEN_RXTOIEN_Msk (0x1ul << UART_INTEN_RXTOIEN_Pos) /*!< UART_T::INTEN: RXTOIEN Mask */ 877 878 #define UART_INTEN_BUFERRIEN_Pos (5) /*!< UART_T::INTEN: BUFERRIEN Position */ 879 #define UART_INTEN_BUFERRIEN_Msk (0x1ul << UART_INTEN_BUFERRIEN_Pos) /*!< UART_T::INTEN: BUFERRIEN Mask */ 880 881 #define UART_INTEN_WKIEN_Pos (6) /*!< UART_T::INTEN: WKIEN Position */ 882 #define UART_INTEN_WKIEN_Msk (0x1ul << UART_INTEN_WKIEN_Pos) /*!< UART_T::INTEN: WKIEN Mask */ 883 884 #define UART_INTEN_LINIEN_Pos (8) /*!< UART_T::INTEN: LINIEN Position */ 885 #define UART_INTEN_LINIEN_Msk (0x1ul << UART_INTEN_LINIEN_Pos) /*!< UART_T::INTEN: LINIEN Mask */ 886 887 #define UART_INTEN_TOCNTEN_Pos (11) /*!< UART_T::INTEN: TOCNTEN Position */ 888 #define UART_INTEN_TOCNTEN_Msk (0x1ul << UART_INTEN_TOCNTEN_Pos) /*!< UART_T::INTEN: TOCNTEN Mask */ 889 890 #define UART_INTEN_ATORTSEN_Pos (12) /*!< UART_T::INTEN: ATORTSEN Position */ 891 #define UART_INTEN_ATORTSEN_Msk (0x1ul << UART_INTEN_ATORTSEN_Pos) /*!< UART_T::INTEN: ATORTSEN Mask */ 892 893 #define UART_INTEN_ATOCTSEN_Pos (13) /*!< UART_T::INTEN: ATOCTSEN Position */ 894 #define UART_INTEN_ATOCTSEN_Msk (0x1ul << UART_INTEN_ATOCTSEN_Pos) /*!< UART_T::INTEN: ATOCTSEN Mask */ 895 896 #define UART_INTEN_TXPDMAEN_Pos (14) /*!< UART_T::INTEN: TXPDMAEN Position */ 897 #define UART_INTEN_TXPDMAEN_Msk (0x1ul << UART_INTEN_TXPDMAEN_Pos) /*!< UART_T::INTEN: TXPDMAEN Mask */ 898 899 #define UART_INTEN_RXPDMAEN_Pos (15) /*!< UART_T::INTEN: RXPDMAEN Position */ 900 #define UART_INTEN_RXPDMAEN_Msk (0x1ul << UART_INTEN_RXPDMAEN_Pos) /*!< UART_T::INTEN: RXPDMAEN Mask */ 901 902 #define UART_INTEN_ABRIEN_Pos (18) /*!< UART_T::INTEN: ABRIEN Position */ 903 #define UART_INTEN_ABRIEN_Msk (0x1ul << UART_INTEN_ABRIEN_Pos) /*!< UART_T::INTEN: ABRIEN Mask */ 904 905 #define UART_INTEN_TXENDIEN_Pos (22) /*!< UART_T::INTEN: TXENDIEN Position */ 906 #define UART_INTEN_TXENDIEN_Msk (0x1ul << UART_INTEN_TXENDIEN_Pos) /*!< UART_T::INTEN: TXENDIEN Mask */ 907 908 #define UART_FIFO_RXRST_Pos (1) /*!< UART_T::FIFO: RXRST Position */ 909 #define UART_FIFO_RXRST_Msk (0x1ul << UART_FIFO_RXRST_Pos) /*!< UART_T::FIFO: RXRST Mask */ 910 911 #define UART_FIFO_TXRST_Pos (2) /*!< UART_T::FIFO: TXRST Position */ 912 #define UART_FIFO_TXRST_Msk (0x1ul << UART_FIFO_TXRST_Pos) /*!< UART_T::FIFO: TXRST Mask */ 913 914 #define UART_FIFO_RFITL_Pos (4) /*!< UART_T::FIFO: RFITL Position */ 915 #define UART_FIFO_RFITL_Msk (0xful << UART_FIFO_RFITL_Pos) /*!< UART_T::FIFO: RFITL Mask */ 916 917 #define UART_FIFO_RXOFF_Pos (8) /*!< UART_T::FIFO: RXOFF Position */ 918 #define UART_FIFO_RXOFF_Msk (0x1ul << UART_FIFO_RXOFF_Pos) /*!< UART_T::FIFO: RXOFF Mask */ 919 920 #define UART_FIFO_RTSTRGLV_Pos (16) /*!< UART_T::FIFO: RTSTRGLV Position */ 921 #define UART_FIFO_RTSTRGLV_Msk (0xful << UART_FIFO_RTSTRGLV_Pos) /*!< UART_T::FIFO: RTSTRGLV Mask */ 922 923 #define UART_LINE_WLS_Pos (0) /*!< UART_T::LINE: WLS Position */ 924 #define UART_LINE_WLS_Msk (0x3ul << UART_LINE_WLS_Pos) /*!< UART_T::LINE: WLS Mask */ 925 926 #define UART_LINE_NSB_Pos (2) /*!< UART_T::LINE: NSB Position */ 927 #define UART_LINE_NSB_Msk (0x1ul << UART_LINE_NSB_Pos) /*!< UART_T::LINE: NSB Mask */ 928 929 #define UART_LINE_PBE_Pos (3) /*!< UART_T::LINE: PBE Position */ 930 #define UART_LINE_PBE_Msk (0x1ul << UART_LINE_PBE_Pos) /*!< UART_T::LINE: PBE Mask */ 931 932 #define UART_LINE_EPE_Pos (4) /*!< UART_T::LINE: EPE Position */ 933 #define UART_LINE_EPE_Msk (0x1ul << UART_LINE_EPE_Pos) /*!< UART_T::LINE: EPE Mask */ 934 935 #define UART_LINE_SPE_Pos (5) /*!< UART_T::LINE: SPE Position */ 936 #define UART_LINE_SPE_Msk (0x1ul << UART_LINE_SPE_Pos) /*!< UART_T::LINE: SPE Mask */ 937 938 #define UART_LINE_BCB_Pos (6) /*!< UART_T::LINE: BCB Position */ 939 #define UART_LINE_BCB_Msk (0x1ul << UART_LINE_BCB_Pos) /*!< UART_T::LINE: BCB Mask */ 940 941 #define UART_LINE_PSS_Pos (7) /*!< UART_T::LINE: PSS Position */ 942 #define UART_LINE_PSS_Msk (0x1ul << UART_LINE_PSS_Pos) /*!< UART_T::LINE: PSS Mask */ 943 944 #define UART_LINE_TXDINV_Pos (8) /*!< UART_T::LINE: TXDINV Position */ 945 #define UART_LINE_TXDINV_Msk (0x1ul << UART_LINE_TXDINV_Pos) /*!< UART_T::LINE: TXDINV Mask */ 946 947 #define UART_LINE_RXDINV_Pos (9) /*!< UART_T::LINE: RXDINV Position */ 948 #define UART_LINE_RXDINV_Msk (0x1ul << UART_LINE_RXDINV_Pos) /*!< UART_T::LINE: RXDINV Mask */ 949 950 #define UART_MODEM_RTS_Pos (1) /*!< UART_T::MODEM: RTS Position */ 951 #define UART_MODEM_RTS_Msk (0x1ul << UART_MODEM_RTS_Pos) /*!< UART_T::MODEM: RTS Mask */ 952 953 #define UART_MODEM_RTSACTLV_Pos (9) /*!< UART_T::MODEM: RTSACTLV Position */ 954 #define UART_MODEM_RTSACTLV_Msk (0x1ul << UART_MODEM_RTSACTLV_Pos) /*!< UART_T::MODEM: RTSACTLV Mask */ 955 956 #define UART_MODEM_RTSSTS_Pos (13) /*!< UART_T::MODEM: RTSSTS Position */ 957 #define UART_MODEM_RTSSTS_Msk (0x1ul << UART_MODEM_RTSSTS_Pos) /*!< UART_T::MODEM: RTSSTS Mask */ 958 959 #define UART_MODEMSTS_CTSDETF_Pos (0) /*!< UART_T::MODEMSTS: CTSDETF Position */ 960 #define UART_MODEMSTS_CTSDETF_Msk (0x1ul << UART_MODEMSTS_CTSDETF_Pos) /*!< UART_T::MODEMSTS: CTSDETF Mask */ 961 962 #define UART_MODEMSTS_CTSSTS_Pos (4) /*!< UART_T::MODEMSTS: CTSSTS Position */ 963 #define UART_MODEMSTS_CTSSTS_Msk (0x1ul << UART_MODEMSTS_CTSSTS_Pos) /*!< UART_T::MODEMSTS: CTSSTS Mask */ 964 965 #define UART_MODEMSTS_CTSACTLV_Pos (8) /*!< UART_T::MODEMSTS: CTSACTLV Position */ 966 #define UART_MODEMSTS_CTSACTLV_Msk (0x1ul << UART_MODEMSTS_CTSACTLV_Pos) /*!< UART_T::MODEMSTS: CTSACTLV Mask */ 967 968 #define UART_FIFOSTS_RXOVIF_Pos (0) /*!< UART_T::FIFOSTS: RXOVIF Position */ 969 #define UART_FIFOSTS_RXOVIF_Msk (0x1ul << UART_FIFOSTS_RXOVIF_Pos) /*!< UART_T::FIFOSTS: RXOVIF Mask */ 970 971 #define UART_FIFOSTS_ABRDIF_Pos (1) /*!< UART_T::FIFOSTS: ABRDIF Position */ 972 #define UART_FIFOSTS_ABRDIF_Msk (0x1ul << UART_FIFOSTS_ABRDIF_Pos) /*!< UART_T::FIFOSTS: ABRDIF Mask */ 973 974 #define UART_FIFOSTS_ABRDTOIF_Pos (2) /*!< UART_T::FIFOSTS: ABRDTOIF Position */ 975 #define UART_FIFOSTS_ABRDTOIF_Msk (0x1ul << UART_FIFOSTS_ABRDTOIF_Pos) /*!< UART_T::FIFOSTS: ABRDTOIF Mask */ 976 977 #define UART_FIFOSTS_ADDRDETF_Pos (3) /*!< UART_T::FIFOSTS: ADDRDETF Position */ 978 #define UART_FIFOSTS_ADDRDETF_Msk (0x1ul << UART_FIFOSTS_ADDRDETF_Pos) /*!< UART_T::FIFOSTS: ADDRDETF Mask */ 979 980 #define UART_FIFOSTS_PEF_Pos (4) /*!< UART_T::FIFOSTS: PEF Position */ 981 #define UART_FIFOSTS_PEF_Msk (0x1ul << UART_FIFOSTS_PEF_Pos) /*!< UART_T::FIFOSTS: PEF Mask */ 982 983 #define UART_FIFOSTS_FEF_Pos (5) /*!< UART_T::FIFOSTS: FEF Position */ 984 #define UART_FIFOSTS_FEF_Msk (0x1ul << UART_FIFOSTS_FEF_Pos) /*!< UART_T::FIFOSTS: FEF Mask */ 985 986 #define UART_FIFOSTS_BIF_Pos (6) /*!< UART_T::FIFOSTS: BIF Position */ 987 #define UART_FIFOSTS_BIF_Msk (0x1ul << UART_FIFOSTS_BIF_Pos) /*!< UART_T::FIFOSTS: BIF Mask */ 988 989 #define UART_FIFOSTS_RXPTR_Pos (8) /*!< UART_T::FIFOSTS: RXPTR Position */ 990 #define UART_FIFOSTS_RXPTR_Msk (0x3ful << UART_FIFOSTS_RXPTR_Pos) /*!< UART_T::FIFOSTS: RXPTR Mask */ 991 992 #define UART_FIFOSTS_RXEMPTY_Pos (14) /*!< UART_T::FIFOSTS: RXEMPTY Position */ 993 #define UART_FIFOSTS_RXEMPTY_Msk (0x1ul << UART_FIFOSTS_RXEMPTY_Pos) /*!< UART_T::FIFOSTS: RXEMPTY Mask */ 994 995 #define UART_FIFOSTS_RXFULL_Pos (15) /*!< UART_T::FIFOSTS: RXFULL Position */ 996 #define UART_FIFOSTS_RXFULL_Msk (0x1ul << UART_FIFOSTS_RXFULL_Pos) /*!< UART_T::FIFOSTS: RXFULL Mask */ 997 998 #define UART_FIFOSTS_TXPTR_Pos (16) /*!< UART_T::FIFOSTS: TXPTR Position */ 999 #define UART_FIFOSTS_TXPTR_Msk (0x3ful << UART_FIFOSTS_TXPTR_Pos) /*!< UART_T::FIFOSTS: TXPTR Mask */ 1000 1001 #define UART_FIFOSTS_TXEMPTY_Pos (22) /*!< UART_T::FIFOSTS: TXEMPTY Position */ 1002 #define UART_FIFOSTS_TXEMPTY_Msk (0x1ul << UART_FIFOSTS_TXEMPTY_Pos) /*!< UART_T::FIFOSTS: TXEMPTY Mask */ 1003 1004 #define UART_FIFOSTS_TXFULL_Pos (23) /*!< UART_T::FIFOSTS: TXFULL Position */ 1005 #define UART_FIFOSTS_TXFULL_Msk (0x1ul << UART_FIFOSTS_TXFULL_Pos) /*!< UART_T::FIFOSTS: TXFULL Mask */ 1006 1007 #define UART_FIFOSTS_TXOVIF_Pos (24) /*!< UART_T::FIFOSTS: TXOVIF Position */ 1008 #define UART_FIFOSTS_TXOVIF_Msk (0x1ul << UART_FIFOSTS_TXOVIF_Pos) /*!< UART_T::FIFOSTS: TXOVIF Mask */ 1009 1010 #define UART_FIFOSTS_TXEMPTYF_Pos (28) /*!< UART_T::FIFOSTS: TXEMPTYF Position */ 1011 #define UART_FIFOSTS_TXEMPTYF_Msk (0x1ul << UART_FIFOSTS_TXEMPTYF_Pos) /*!< UART_T::FIFOSTS: TXEMPTYF Mask */ 1012 1013 #define UART_FIFOSTS_RXIDLE_Pos (29) /*!< UART_T::FIFOSTS: RXIDLE Position */ 1014 #define UART_FIFOSTS_RXIDLE_Msk (0x1ul << UART_FIFOSTS_RXIDLE_Pos) /*!< UART_T::FIFOSTS: RXIDLE Mask */ 1015 1016 #define UART_FIFOSTS_TXRXACT_Pos (31) /*!< UART_T::FIFOSTS: TXRXACT Position */ 1017 #define UART_FIFOSTS_TXRXACT_Msk (0x1ul << UART_FIFOSTS_TXRXACT_Pos) /*!< UART_T::FIFOSTS: TXRXACT Mask */ 1018 1019 #define UART_INTSTS_RDAIF_Pos (0) /*!< UART_T::INTSTS: RDAIF Position */ 1020 #define UART_INTSTS_RDAIF_Msk (0x1ul << UART_INTSTS_RDAIF_Pos) /*!< UART_T::INTSTS: RDAIF Mask */ 1021 1022 #define UART_INTSTS_THREIF_Pos (1) /*!< UART_T::INTSTS: THREIF Position */ 1023 #define UART_INTSTS_THREIF_Msk (0x1ul << UART_INTSTS_THREIF_Pos) /*!< UART_T::INTSTS: THREIF Mask */ 1024 1025 #define UART_INTSTS_RLSIF_Pos (2) /*!< UART_T::INTSTS: RLSIF Position */ 1026 #define UART_INTSTS_RLSIF_Msk (0x1ul << UART_INTSTS_RLSIF_Pos) /*!< UART_T::INTSTS: RLSIF Mask */ 1027 1028 #define UART_INTSTS_MODEMIF_Pos (3) /*!< UART_T::INTSTS: MODEMIF Position */ 1029 #define UART_INTSTS_MODEMIF_Msk (0x1ul << UART_INTSTS_MODEMIF_Pos) /*!< UART_T::INTSTS: MODEMIF Mask */ 1030 1031 #define UART_INTSTS_RXTOIF_Pos (4) /*!< UART_T::INTSTS: RXTOIF Position */ 1032 #define UART_INTSTS_RXTOIF_Msk (0x1ul << UART_INTSTS_RXTOIF_Pos) /*!< UART_T::INTSTS: RXTOIF Mask */ 1033 1034 #define UART_INTSTS_BUFERRIF_Pos (5) /*!< UART_T::INTSTS: BUFERRIF Position */ 1035 #define UART_INTSTS_BUFERRIF_Msk (0x1ul << UART_INTSTS_BUFERRIF_Pos) /*!< UART_T::INTSTS: BUFERRIF Mask */ 1036 1037 #define UART_INTSTS_WKIF_Pos (6) /*!< UART_T::INTSTS: WKIF Position */ 1038 #define UART_INTSTS_WKIF_Msk (0x1ul << UART_INTSTS_WKIF_Pos) /*!< UART_T::INTSTS: WKIF Mask */ 1039 1040 #define UART_INTSTS_LINIF_Pos (7) /*!< UART_T::INTSTS: LINIF Position */ 1041 #define UART_INTSTS_LINIF_Msk (0x1ul << UART_INTSTS_LINIF_Pos) /*!< UART_T::INTSTS: LINIF Mask */ 1042 1043 #define UART_INTSTS_RDAINT_Pos (8) /*!< UART_T::INTSTS: RDAINT Position */ 1044 #define UART_INTSTS_RDAINT_Msk (0x1ul << UART_INTSTS_RDAINT_Pos) /*!< UART_T::INTSTS: RDAINT Mask */ 1045 1046 #define UART_INTSTS_THREINT_Pos (9) /*!< UART_T::INTSTS: THREINT Position */ 1047 #define UART_INTSTS_THREINT_Msk (0x1ul << UART_INTSTS_THREINT_Pos) /*!< UART_T::INTSTS: THREINT Mask */ 1048 1049 #define UART_INTSTS_RLSINT_Pos (10) /*!< UART_T::INTSTS: RLSINT Position */ 1050 #define UART_INTSTS_RLSINT_Msk (0x1ul << UART_INTSTS_RLSINT_Pos) /*!< UART_T::INTSTS: RLSINT Mask */ 1051 1052 #define UART_INTSTS_MODEMINT_Pos (11) /*!< UART_T::INTSTS: MODEMINT Position */ 1053 #define UART_INTSTS_MODEMINT_Msk (0x1ul << UART_INTSTS_MODEMINT_Pos) /*!< UART_T::INTSTS: MODEMINT Mask */ 1054 1055 #define UART_INTSTS_RXTOINT_Pos (12) /*!< UART_T::INTSTS: RXTOINT Position */ 1056 #define UART_INTSTS_RXTOINT_Msk (0x1ul << UART_INTSTS_RXTOINT_Pos) /*!< UART_T::INTSTS: RXTOINT Mask */ 1057 1058 #define UART_INTSTS_BUFERRINT_Pos (13) /*!< UART_T::INTSTS: BUFERRINT Position */ 1059 #define UART_INTSTS_BUFERRINT_Msk (0x1ul << UART_INTSTS_BUFERRINT_Pos) /*!< UART_T::INTSTS: BUFERRINT Mask */ 1060 1061 #define UART_INTSTS_WKINT_Pos (14) /*!< UART_T::INTSTS: WKINT Position */ 1062 #define UART_INTSTS_WKINT_Msk (0x1ul << UART_INTSTS_WKINT_Pos) /*!< UART_T::INTSTS: WKINT Mask */ 1063 1064 #define UART_INTSTS_LININT_Pos (15) /*!< UART_T::INTSTS: LININT Position */ 1065 #define UART_INTSTS_LININT_Msk (0x1ul << UART_INTSTS_LININT_Pos) /*!< UART_T::INTSTS: LININT Mask */ 1066 1067 #define UART_INTSTS_HWRLSIF_Pos (18) /*!< UART_T::INTSTS: HWRLSIF Position */ 1068 #define UART_INTSTS_HWRLSIF_Msk (0x1ul << UART_INTSTS_HWRLSIF_Pos) /*!< UART_T::INTSTS: HWRLSIF Mask */ 1069 1070 #define UART_INTSTS_HWMODIF_Pos (19) /*!< UART_T::INTSTS: HWMODIF Position */ 1071 #define UART_INTSTS_HWMODIF_Msk (0x1ul << UART_INTSTS_HWMODIF_Pos) /*!< UART_T::INTSTS: HWMODIF Mask */ 1072 1073 #define UART_INTSTS_HWTOIF_Pos (20) /*!< UART_T::INTSTS: HWTOIF Position */ 1074 #define UART_INTSTS_HWTOIF_Msk (0x1ul << UART_INTSTS_HWTOIF_Pos) /*!< UART_T::INTSTS: HWTOIF Mask */ 1075 1076 #define UART_INTSTS_HWBUFEIF_Pos (21) /*!< UART_T::INTSTS: HWBUFEIF Position */ 1077 #define UART_INTSTS_HWBUFEIF_Msk (0x1ul << UART_INTSTS_HWBUFEIF_Pos) /*!< UART_T::INTSTS: HWBUFEIF Mask */ 1078 1079 #define UART_INTSTS_TXENDIF_Pos (22) /*!< UART_T::INTSTS: TXENDIF Position */ 1080 #define UART_INTSTS_TXENDIF_Msk (0x1ul << UART_INTSTS_TXENDIF_Pos) /*!< UART_T::INTSTS: TXENDIF Mask */ 1081 1082 #define UART_INTSTS_HWRLSINT_Pos (26) /*!< UART_T::INTSTS: HWRLSINT Position */ 1083 #define UART_INTSTS_HWRLSINT_Msk (0x1ul << UART_INTSTS_HWRLSINT_Pos) /*!< UART_T::INTSTS: HWRLSINT Mask */ 1084 1085 #define UART_INTSTS_HWMODINT_Pos (27) /*!< UART_T::INTSTS: HWMODINT Position */ 1086 #define UART_INTSTS_HWMODINT_Msk (0x1ul << UART_INTSTS_HWMODINT_Pos) /*!< UART_T::INTSTS: HWMODINT Mask */ 1087 1088 #define UART_INTSTS_HWTOINT_Pos (28) /*!< UART_T::INTSTS: HWTOINT Position */ 1089 #define UART_INTSTS_HWTOINT_Msk (0x1ul << UART_INTSTS_HWTOINT_Pos) /*!< UART_T::INTSTS: HWTOINT Mask */ 1090 1091 #define UART_INTSTS_HWBUFEINT_Pos (29) /*!< UART_T::INTSTS: HWBUFEINT Position */ 1092 #define UART_INTSTS_HWBUFEINT_Msk (0x1ul << UART_INTSTS_HWBUFEINT_Pos) /*!< UART_T::INTSTS: HWBUFEINT Mask */ 1093 1094 #define UART_INTSTS_TXENDINT_Pos (30) /*!< UART_T::INTSTS: TXENDINT Position */ 1095 #define UART_INTSTS_TXENDINT_Msk (0x1ul << UART_INTSTS_TXENDINT_Pos) /*!< UART_T::INTSTS: TXENDINT Mask */ 1096 1097 #define UART_INTSTS_ABRINT_Pos (31) /*!< UART_T::INTSTS: ABRINT Position */ 1098 #define UART_INTSTS_ABRINT_Msk (0x1ul << UART_INTSTS_ABRINT_Pos) /*!< UART_T::INTSTS: ABRINT Mask */ 1099 1100 #define UART_TOUT_TOIC_Pos (0) /*!< UART_T::TOUT: TOIC Position */ 1101 #define UART_TOUT_TOIC_Msk (0xfful << UART_TOUT_TOIC_Pos) /*!< UART_T::TOUT: TOIC Mask */ 1102 1103 #define UART_TOUT_DLY_Pos (8) /*!< UART_T::TOUT: DLY Position */ 1104 #define UART_TOUT_DLY_Msk (0xfful << UART_TOUT_DLY_Pos) /*!< UART_T::TOUT: DLY Mask */ 1105 1106 #define UART_BAUD_BRD_Pos (0) /*!< UART_T::BAUD: BRD Position */ 1107 #define UART_BAUD_BRD_Msk (0xfffful << UART_BAUD_BRD_Pos) /*!< UART_T::BAUD: BRD Mask */ 1108 1109 #define UART_BAUD_EDIVM1_Pos (24) /*!< UART_T::BAUD: EDIVM1 Position */ 1110 #define UART_BAUD_EDIVM1_Msk (0xful << UART_BAUD_EDIVM1_Pos) /*!< UART_T::BAUD: EDIVM1 Mask */ 1111 1112 #define UART_BAUD_BAUDM0_Pos (28) /*!< UART_T::BAUD: BAUDM0 Position */ 1113 #define UART_BAUD_BAUDM0_Msk (0x1ul << UART_BAUD_BAUDM0_Pos) /*!< UART_T::BAUD: BAUDM0 Mask */ 1114 1115 #define UART_BAUD_BAUDM1_Pos (29) /*!< UART_T::BAUD: BAUDM1 Position */ 1116 #define UART_BAUD_BAUDM1_Msk (0x1ul << UART_BAUD_BAUDM1_Pos) /*!< UART_T::BAUD: BAUDM1 Mask */ 1117 1118 #define UART_IRDA_TXEN_Pos (1) /*!< UART_T::IRDA: TXEN Position */ 1119 #define UART_IRDA_TXEN_Msk (0x1ul << UART_IRDA_TXEN_Pos) /*!< UART_T::IRDA: TXEN Mask */ 1120 1121 #define UART_IRDA_TXINV_Pos (5) /*!< UART_T::IRDA: TXINV Position */ 1122 #define UART_IRDA_TXINV_Msk (0x1ul << UART_IRDA_TXINV_Pos) /*!< UART_T::IRDA: TXINV Mask */ 1123 1124 #define UART_IRDA_RXINV_Pos (6) /*!< UART_T::IRDA: RXINV Position */ 1125 #define UART_IRDA_RXINV_Msk (0x1ul << UART_IRDA_RXINV_Pos) /*!< UART_T::IRDA: RXINV Mask */ 1126 1127 #define UART_ALTCTL_BRKFL_Pos (0) /*!< UART_T::ALTCTL: BRKFL Position */ 1128 #define UART_ALTCTL_BRKFL_Msk (0xful << UART_ALTCTL_BRKFL_Pos) /*!< UART_T::ALTCTL: BRKFL Mask */ 1129 1130 #define UART_ALTCTL_LINRXEN_Pos (6) /*!< UART_T::ALTCTL: LINRXEN Position */ 1131 #define UART_ALTCTL_LINRXEN_Msk (0x1ul << UART_ALTCTL_LINRXEN_Pos) /*!< UART_T::ALTCTL: LINRXEN Mask */ 1132 1133 #define UART_ALTCTL_LINTXEN_Pos (7) /*!< UART_T::ALTCTL: LINTXEN Position */ 1134 #define UART_ALTCTL_LINTXEN_Msk (0x1ul << UART_ALTCTL_LINTXEN_Pos) /*!< UART_T::ALTCTL: LINTXEN Mask */ 1135 1136 #define UART_ALTCTL_RS485NMM_Pos (8) /*!< UART_T::ALTCTL: RS485NMM Position */ 1137 #define UART_ALTCTL_RS485NMM_Msk (0x1ul << UART_ALTCTL_RS485NMM_Pos) /*!< UART_T::ALTCTL: RS485NMM Mask */ 1138 1139 #define UART_ALTCTL_RS485AAD_Pos (9) /*!< UART_T::ALTCTL: RS485AAD Position */ 1140 #define UART_ALTCTL_RS485AAD_Msk (0x1ul << UART_ALTCTL_RS485AAD_Pos) /*!< UART_T::ALTCTL: RS485AAD Mask */ 1141 1142 #define UART_ALTCTL_RS485AUD_Pos (10) /*!< UART_T::ALTCTL: RS485AUD Position */ 1143 #define UART_ALTCTL_RS485AUD_Msk (0x1ul << UART_ALTCTL_RS485AUD_Pos) /*!< UART_T::ALTCTL: RS485AUD Mask */ 1144 1145 #define UART_ALTCTL_ADDRDEN_Pos (15) /*!< UART_T::ALTCTL: ADDRDEN Position */ 1146 #define UART_ALTCTL_ADDRDEN_Msk (0x1ul << UART_ALTCTL_ADDRDEN_Pos) /*!< UART_T::ALTCTL: ADDRDEN Mask */ 1147 1148 #define UART_ALTCTL_ABRIF_Pos (17) /*!< UART_T::ALTCTL: ABRIF Position */ 1149 #define UART_ALTCTL_ABRIF_Msk (0x1ul << UART_ALTCTL_ABRIF_Pos) /*!< UART_T::ALTCTL: ABRIF Mask */ 1150 1151 #define UART_ALTCTL_ABRDEN_Pos (18) /*!< UART_T::ALTCTL: ABRDEN Position */ 1152 #define UART_ALTCTL_ABRDEN_Msk (0x1ul << UART_ALTCTL_ABRDEN_Pos) /*!< UART_T::ALTCTL: ABRDEN Mask */ 1153 1154 #define UART_ALTCTL_ABRDBITS_Pos (19) /*!< UART_T::ALTCTL: ABRDBITS Position */ 1155 #define UART_ALTCTL_ABRDBITS_Msk (0x3ul << UART_ALTCTL_ABRDBITS_Pos) /*!< UART_T::ALTCTL: ABRDBITS Mask */ 1156 1157 #define UART_ALTCTL_ADDRMV_Pos (24) /*!< UART_T::ALTCTL: ADDRMV Position */ 1158 #define UART_ALTCTL_ADDRMV_Msk (0xfful << UART_ALTCTL_ADDRMV_Pos) /*!< UART_T::ALTCTL: ADDRMV Mask */ 1159 1160 #define UART_FUNCSEL_FUNCSEL_Pos (0) /*!< UART_T::FUNCSEL: FUNCSEL Position */ 1161 #define UART_FUNCSEL_FUNCSEL_Msk (0x3ul << UART_FUNCSEL_FUNCSEL_Pos) /*!< UART_T::FUNCSEL: FUNCSEL Mask */ 1162 1163 #define UART_FUNCSEL_TXRXDIS_Pos (3) /*!< UART_T::FUNCSEL: TXRXDIS Position */ 1164 #define UART_FUNCSEL_TXRXDIS_Msk (0x1ul << UART_FUNCSEL_TXRXDIS_Pos) /*!< UART_T::FUNCSEL: TXRXDIS Mask */ 1165 1166 #define UART_LINCTL_SLVEN_Pos (0) /*!< UART_T::LINCTL: SLVEN Position */ 1167 #define UART_LINCTL_SLVEN_Msk (0x1ul << UART_LINCTL_SLVEN_Pos) /*!< UART_T::LINCTL: SLVEN Mask */ 1168 1169 #define UART_LINCTL_SLVHDEN_Pos (1) /*!< UART_T::LINCTL: SLVHDEN Position */ 1170 #define UART_LINCTL_SLVHDEN_Msk (0x1ul << UART_LINCTL_SLVHDEN_Pos) /*!< UART_T::LINCTL: SLVHDEN Mask */ 1171 1172 #define UART_LINCTL_SLVAREN_Pos (2) /*!< UART_T::LINCTL: SLVAREN Position */ 1173 #define UART_LINCTL_SLVAREN_Msk (0x1ul << UART_LINCTL_SLVAREN_Pos) /*!< UART_T::LINCTL: SLVAREN Mask */ 1174 1175 #define UART_LINCTL_SLVDUEN_Pos (3) /*!< UART_T::LINCTL: SLVDUEN Position */ 1176 #define UART_LINCTL_SLVDUEN_Msk (0x1ul << UART_LINCTL_SLVDUEN_Pos) /*!< UART_T::LINCTL: SLVDUEN Mask */ 1177 1178 #define UART_LINCTL_MUTE_Pos (4) /*!< UART_T::LINCTL: MUTE Position */ 1179 #define UART_LINCTL_MUTE_Msk (0x1ul << UART_LINCTL_MUTE_Pos) /*!< UART_T::LINCTL: MUTE Mask */ 1180 1181 #define UART_LINCTL_SENDH_Pos (8) /*!< UART_T::LINCTL: SENDH Position */ 1182 #define UART_LINCTL_SENDH_Msk (0x1ul << UART_LINCTL_SENDH_Pos) /*!< UART_T::LINCTL: SENDH Mask */ 1183 1184 #define UART_LINCTL_IDPEN_Pos (9) /*!< UART_T::LINCTL: IDPEN Position */ 1185 #define UART_LINCTL_IDPEN_Msk (0x1ul << UART_LINCTL_IDPEN_Pos) /*!< UART_T::LINCTL: IDPEN Mask */ 1186 1187 #define UART_LINCTL_BRKDETEN_Pos (10) /*!< UART_T::LINCTL: BRKDETEN Position */ 1188 #define UART_LINCTL_BRKDETEN_Msk (0x1ul << UART_LINCTL_BRKDETEN_Pos) /*!< UART_T::LINCTL: BRKDETEN Mask */ 1189 1190 #define UART_LINCTL_LINRXOFF_Pos (11) /*!< UART_T::LINCTL: LINRXOFF Position */ 1191 #define UART_LINCTL_LINRXOFF_Msk (0x1ul << UART_LINCTL_LINRXOFF_Pos) /*!< UART_T::LINCTL: LINRXOFF Mask */ 1192 1193 #define UART_LINCTL_BITERREN_Pos (12) /*!< UART_T::LINCTL: BITERREN Position */ 1194 #define UART_LINCTL_BITERREN_Msk (0x1ul << UART_LINCTL_BITERREN_Pos) /*!< UART_T::LINCTL: BITERREN Mask */ 1195 1196 #define UART_LINCTL_BRKFL_Pos (16) /*!< UART_T::LINCTL: BRKFL Position */ 1197 #define UART_LINCTL_BRKFL_Msk (0xful << UART_LINCTL_BRKFL_Pos) /*!< UART_T::LINCTL: BRKFL Mask */ 1198 1199 #define UART_LINCTL_BSL_Pos (20) /*!< UART_T::LINCTL: BSL Position */ 1200 #define UART_LINCTL_BSL_Msk (0x3ul << UART_LINCTL_BSL_Pos) /*!< UART_T::LINCTL: BSL Mask */ 1201 1202 #define UART_LINCTL_HSEL_Pos (22) /*!< UART_T::LINCTL: HSEL Position */ 1203 #define UART_LINCTL_HSEL_Msk (0x3ul << UART_LINCTL_HSEL_Pos) /*!< UART_T::LINCTL: HSEL Mask */ 1204 1205 #define UART_LINCTL_PID_Pos (24) /*!< UART_T::LINCTL: PID Position */ 1206 #define UART_LINCTL_PID_Msk (0xfful << UART_LINCTL_PID_Pos) /*!< UART_T::LINCTL: PID Mask */ 1207 1208 #define UART_LINSTS_SLVHDETF_Pos (0) /*!< UART_T::LINSTS: SLVHDETF Position */ 1209 #define UART_LINSTS_SLVHDETF_Msk (0x1ul << UART_LINSTS_SLVHDETF_Pos) /*!< UART_T::LINSTS: SLVHDETF Mask */ 1210 1211 #define UART_LINSTS_SLVHEF_Pos (1) /*!< UART_T::LINSTS: SLVHEF Position */ 1212 #define UART_LINSTS_SLVHEF_Msk (0x1ul << UART_LINSTS_SLVHEF_Pos) /*!< UART_T::LINSTS: SLVHEF Mask */ 1213 1214 #define UART_LINSTS_SLVIDPEF_Pos (2) /*!< UART_T::LINSTS: SLVIDPEF Position */ 1215 #define UART_LINSTS_SLVIDPEF_Msk (0x1ul << UART_LINSTS_SLVIDPEF_Pos) /*!< UART_T::LINSTS: SLVIDPEF Mask */ 1216 1217 #define UART_LINSTS_SLVSYNCF_Pos (3) /*!< UART_T::LINSTS: SLVSYNCF Position */ 1218 #define UART_LINSTS_SLVSYNCF_Msk (0x1ul << UART_LINSTS_SLVSYNCF_Pos) /*!< UART_T::LINSTS: SLVSYNCF Mask */ 1219 1220 #define UART_LINSTS_BRKDETF_Pos (8) /*!< UART_T::LINSTS: BRKDETF Position */ 1221 #define UART_LINSTS_BRKDETF_Msk (0x1ul << UART_LINSTS_BRKDETF_Pos) /*!< UART_T::LINSTS: BRKDETF Mask */ 1222 1223 #define UART_LINSTS_BITEF_Pos (9) /*!< UART_T::LINSTS: BITEF Position */ 1224 #define UART_LINSTS_BITEF_Msk (0x1ul << UART_LINSTS_BITEF_Pos) /*!< UART_T::LINSTS: BITEF Mask */ 1225 1226 #define UART_BRCOMP_BRCOMP_Pos (0) /*!< UART_T::BRCOMP: BRCOMP Position */ 1227 #define UART_BRCOMP_BRCOMP_Msk (0x1fful << UART_BRCOMP_BRCOMP_Pos) /*!< UART_T::BRCOMP: BRCOMP Mask */ 1228 1229 #define UART_BRCOMP_BRCOMPDEC_Pos (31) /*!< UART_T::BRCOMP: BRCOMPDEC Position */ 1230 #define UART_BRCOMP_BRCOMPDEC_Msk (0x1ul << UART_BRCOMP_BRCOMPDEC_Pos) /*!< UART_T::BRCOMP: BRCOMPDEC Mask */ 1231 1232 #define UART_WKCTL_WKCTSEN_Pos (0) /*!< UART_T::WKCTL: WKCTSEN Position */ 1233 #define UART_WKCTL_WKCTSEN_Msk (0x1ul << UART_WKCTL_WKCTSEN_Pos) /*!< UART_T::WKCTL: WKCTSEN Mask */ 1234 1235 #define UART_WKCTL_WKDATEN_Pos (1) /*!< UART_T::WKCTL: WKDATEN Position */ 1236 #define UART_WKCTL_WKDATEN_Msk (0x1ul << UART_WKCTL_WKDATEN_Pos) /*!< UART_T::WKCTL: WKDATEN Mask */ 1237 1238 #define UART_WKCTL_WKRFRTEN_Pos (2) /*!< UART_T::WKCTL: WKRFRTEN Position */ 1239 #define UART_WKCTL_WKRFRTEN_Msk (0x1ul << UART_WKCTL_WKRFRTEN_Pos) /*!< UART_T::WKCTL: WKRFRTEN Mask */ 1240 1241 #define UART_WKCTL_WKRS485EN_Pos (3) /*!< UART_T::WKCTL: WKRS485EN Position */ 1242 #define UART_WKCTL_WKRS485EN_Msk (0x1ul << UART_WKCTL_WKRS485EN_Pos) /*!< UART_T::WKCTL: WKRS485EN Mask */ 1243 1244 #define UART_WKCTL_WKTOUTEN_Pos (4) /*!< UART_T::WKCTL: WKTOUTEN Position */ 1245 #define UART_WKCTL_WKTOUTEN_Msk (0x1ul << UART_WKCTL_WKTOUTEN_Pos) /*!< UART_T::WKCTL: WKTOUTEN Mask */ 1246 1247 #define UART_WKSTS_CTSWKF_Pos (0) /*!< UART_T::WKSTS: CTSWKF Position */ 1248 #define UART_WKSTS_CTSWKF_Msk (0x1ul << UART_WKSTS_CTSWKF_Pos) /*!< UART_T::WKSTS: CTSWKF Mask */ 1249 1250 #define UART_WKSTS_DATWKF_Pos (1) /*!< UART_T::WKSTS: DATWKF Position */ 1251 #define UART_WKSTS_DATWKF_Msk (0x1ul << UART_WKSTS_DATWKF_Pos) /*!< UART_T::WKSTS: DATWKF Mask */ 1252 1253 #define UART_WKSTS_RFRTWKF_Pos (2) /*!< UART_T::WKSTS: RFRTWKF Position */ 1254 #define UART_WKSTS_RFRTWKF_Msk (0x1ul << UART_WKSTS_RFRTWKF_Pos) /*!< UART_T::WKSTS: RFRTWKF Mask */ 1255 1256 #define UART_WKSTS_RS485WKF_Pos (3) /*!< UART_T::WKSTS: RS485WKF Position */ 1257 #define UART_WKSTS_RS485WKF_Msk (0x1ul << UART_WKSTS_RS485WKF_Pos) /*!< UART_T::WKSTS: RS485WKF Mask */ 1258 1259 #define UART_WKSTS_TOUTWKF_Pos (4) /*!< UART_T::WKSTS: TOUTWKF Position */ 1260 #define UART_WKSTS_TOUTWKF_Msk (0x1ul << UART_WKSTS_TOUTWKF_Pos) /*!< UART_T::WKSTS: TOUTWKF Mask */ 1261 1262 #define UART_DWKCOMP_STCOMP_Pos (0) /*!< UART_T::DWKCOMP: STCOMP Position */ 1263 #define UART_DWKCOMP_STCOMP_Msk (0xfffful << UART_DWKCOMP_STCOMP_Pos) /*!< UART_T::DWKCOMP: STCOMP Mask */ 1264 1265 /**@}*/ /* UART_CONST */ 1266 /**@}*/ /* end of UART register group */ 1267 /**@}*/ /* end of REGISTER group */ 1268 1269 #if defined ( __CC_ARM ) 1270 #pragma no_anon_unions 1271 #endif 1272 1273 #endif /* __UART_REG_H__ */ 1274