完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
扫一扫,分享给好友
官方TRM中提到NUC230/240的UART0有提供到64 Bytes的接收缓冲区,UART1及UART2只提供了16Bytes的接收缓冲区,但uart.h文件中RFITL设定仅供到14 Bytes
想问如果想使用64 Bytes FIFO该如何设定,谢谢 /*---------------------------------------------------------------------------------------------------------*/ /* UART FIFO size constants definitions */ /*---------------------------------------------------------------------------------------------------------*/ #define UART0_FIFO_SIZE 64 /*!< UART0 supports separated receive/transmit 64/64 bytes entry FIFO */ #define UART1_FIFO_SIZE 16 /*!< UART1 supports separated receive/transmit 16/16 bytes entry FIFO */ #define UART2_FIFO_SIZE 16 /*!< UART2 supports separated receive/transmit 16/16 bytes entry FIFO */ /*---------------------------------------------------------------------------------------------------------*/ /* UA_FCR constants definitions */ /*---------------------------------------------------------------------------------------------------------*/ #define UART_FCR_RFITL_1BYTE (0x0 << UART_FCR_RFITL_Pos) /*!< UA_FCR setting to set RX FIFO Trigger Level to 1 bit */ #define UART_FCR_RFITL_4BYTES (0x1 << UART_FCR_RFITL_Pos) /*!< UA_FCR setting to set RX FIFO Trigger Level to 4 bits */ #define UART_FCR_RFITL_8BYTES (0x2 << UART_FCR_RFITL_Pos) /*!< UA_FCR setting to set RX FIFO Trigger Level to 8 bits */ #define UART_FCR_RFITL_14BYTES (0x3 << UART_FCR_RFITL_Pos) /*!< UA_FCR setting to set RX FIFO Trigger Level to 14 bits */ #define UART_FCR_RTS_TRI_LEV_1BYTE (0x0 << UART_FCR_RTS_TRI_LEV_Pos) /*!< UA_FCR setting to set RTS Trigger Level to 1 bit */ #define UART_FCR_RTS_TRI_LEV_4BYTES (0x1 << UART_FCR_RTS_TRI_LEV_Pos) /*!< UA_FCR setting to set RTS Trigger Level to 4 bits */ #define UART_FCR_RTS_TRI_LEV_8BYTES (0x2 << UART_FCR_RTS_TRI_LEV_Pos) /*!< UA_FCR setting to set RTS Trigger Level to 8 bits */ #define UART_FCR_RTS_TRI_LEV_14BYTES (0x3 << UART_FCR_RTS_TRI_LEV_Pos) /*!< UA_FCR setting to set RTS Trigger Level to 14 bits */ |
|
相关推荐
1个回答
|
|
nbsp; */#define UART_FIFO_1BYTES (0x0ul << UART_FCR_RFITL_Pos) /*!< UART_FIFO_DEPTH = 1 byte */#define UART_FIFO_4BYTES (0x1ul << UART_FCR_RFITL_Pos) /*!< UART_FIFO_DEPTH = 4 bytes */#define UART_FIFO_8BYTES (0x2ul << UART_FCR_RFITL_Pos) /*!< UART_FIFO_DEPTH = 8 bytes */#define UART_FIFO_14BYTES (0x3ul << UART_FCR_RFITL_Pos) /*!< UART_FIFO_DEPTH = 14 bytes *//*---------------------------------------------------------------------------------------------------------*/根据uart.h文件中的定义,NUC230/240的UART0最大接收缓冲区为14 Bytes,而未提供64 Bytes的选项。因此,需要针对该功能进行特殊编程,或使用别的方式实现所需的64 Bytes缓冲区。
|
|
|
|
只有小组成员才能发言,加入小组>>
3309 浏览 9 评论
2988 浏览 16 评论
3490 浏览 1 评论
9050 浏览 16 评论
4085 浏览 18 评论
1171浏览 3评论
602浏览 2评论
const uint16_t Tab[10]={0}; const uint16_t *p; p = Tab;//报错是怎么回事?
594浏览 2评论
用NUC131单片机UART3作为打印口,但printf没有输出东西是什么原因?
2331浏览 2评论
NUC980DK61YC启动随机性出现Err-DDR是为什么?
1894浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-20 11:41 , Processed in 1.087537 second(s), Total 77, Slave 58 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号