| 数据搜索系统,热门电子元器件搜索 |
|
STR720 数据表(PDF) 176 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
STR720 数据表(HTML) 176 Page - STMicroelectronics |
|
176 / 401 page ![]() STR720 - UART 176/401 16.3.7 Using the ASC interrupts when fifos are disabled When fifos are disabled, the ASC provides three interrupt requests to control data exchange via the serial channel: • TxHalfEmpty is activated when data is moved from ASCTxBuffer to the txshift register. • TxEmpty is activated before the stop bit is transmitted. • RxBufNotEmpty is activated when the received frame is moved to ASCRxBuffer. For single transfers it is sufficient to use the transmitter interrupt (TxEmpty), which indicates that the previously loaded data has been transmitted, except for the stop bit. For multiple back-to-back transfers using TxEmpty would leave just one stop bit time for the handler to respond to the interrupt and initiate another transmission. Using the transmit buffer interrupt (TxHalfEmpty) to reload transmit data allows the time to transmit a complete frame for the service routine, as ASCTxBuffer may be reloaded while the previous data is still being transmitted. TxHalfEmpty is an early trigger for the reload routine, while TxEmpty indicates the completed transmission of the data field of the frame. Therefore, software using handshake should rely on TxEmpty at the end of a data block to make sure that all data has really been transmitted. 16.3.8 Using the ASC interrupts when fifos are enabled To transmit a large number of characters back to back, the driver routine would write 16 characters to ASCTxBuffer, then every time a TxHalfEmpty interrupt fired, it would write 8 more. When it had nothing more to send, a TxEmpty interrupt would tell it when everything has been transmitted. When receiving, the driver could use RxBufNotEmpty to interrupt every time a character came in. Alternatively, if data is coming in back-to-back, it could use RxHalfFull to interrupt it when there was at least 8 characters in the rxfifo to read. It would have as long as it takes to receive 8 characters to respond to this interrupt before data would overrun. If less than eight character streamed in, and no more were received for at least a timeout period, the driver could be woken up by one of the two timeout interrupts, TimeoutNotEmpty or TimeoutIdle. 1 |
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |