| công cụ tìm kiếm bảng dữ liệu linh kiện điện tử |
|
PIC16F15213T-I/ST bảng dữ liệu(PDF) 238 Page - Microchip Technology |
|
|
|||||||||||||||||||||||||||||
PIC16F15213T-I/ST bảng dữ liệu(HTML) 238 Page - Microchip Technology |
|
238 / 439 page ![]() 24.4.1.7 Receive Overrun Error The receive FIFO buffer can hold two characters. An overrun error will be generated if a third character, in its entirety, is received before the FIFO is accessed. When this happens the Overrun Error (OERR) bit is set. The characters already in the FIFO buffer can be read but no additional characters will be received until the error is cleared. The error must be cleared by either clearing the CREN bit or by resetting the EUSART by clearing the SPEN bit. 24.4.1.8 Receiving 9-Bit Characters The EUSART supports 9-bit character reception. When the 9-Bit Receive Enable (RX9) bit is set, the EUSART will shift nine bits into the RSR for each character received. The RX9D bit is the ninth and Most Significant data bit of the top unread character in the receive FIFO. When reading 9-bit data from the receive FIFO buffer, the RX9D data bit must be read before reading the eight Least Significant bits from the RCxREG register. 24.4.1.9 Synchronous Host Reception Setup 1. Initialize the SPxBRGH:SPxBRGL register pair and set or clear the BRG16 bit, as required, to achieve the desired baud rate. 2. Select the receive input pin by writing the appropriate values to the RxyPPS and RXxPPS registers. Both selections may enable the same pin. 3. Select the clock output pin by writing the appropriate values to the RxyPPS and TXxPPS registers. Both selections may enable the same pin. 4. Clear the ANSEL bit for the RXx pin (if applicable). 5. Enable the synchronous host serial port by setting the SYNC, SPEN and CSRC bits. 6. Ensure that the CREN and SREN bits are cleared. 7. If interrupts are desired, set the RCxIE bit of the PIEx register and the GIE and PEIE bits of the INTCON register. 8. If 9-bit reception is desired, set the RX9 bit. 9. Start reception by setting the SREN bit, or for continuous reception set the CREN bit. 10. The RCxIF Interrupt Flag bit will be set when reception of a character is complete. An interrupt will be generated if the RCxIE enable bit was set. 11. Read the RCxSTA register to get the ninth bit (if enabled) and determine if any error occurred during reception. 12. Read the 8-bit received data by reading the RCxREG register. 13. If an overrun error occurs, clear the error by either clearing the CREN bit or by clearing the SPEN bit which resets the EUSART. Figure 24-11. Synchronous Reception (Host Mode, SREN) Rev. 10-000 121A 2/13/201 7 RXx/DTx pin bit 0 TXx/CKx pin SCKP = 0 TXx/CKx pin SCKP = 1 bit 1 bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 Write to SREN SREN bit CREN bit ‘ 0’ RCxIF ( Interrupt) Read RCxREG ‘ 0’ PIC16F15213/14/23/24/43/44 EUSART - Enhanced Universal Synchronous Asyn... © 2020-2022 Microchip Technology Inc. and its subsidiaries Data Sheet DS40002195E-page 238 |
|
Link URL |
| Cho đến nay ALLDATASHEET có giúp ích cho doanh nghiệp của bạn hay không? [ DONATE ] |
Alldatasheet là | Quảng cáo | Liên lạc với chúng tôi | Chính sách bảo mật | Liên kết đến bảng dữ liệu | Trao đổi link | Tìm kiếm theo nhà sản xuất 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 |