诸如 LCR DLL DLH IER等寄存器,我都能写进去,再读出来,可FCR就是不行, 我把代码写在下面,哪位兄弟姐妹指导一下 //定义相关宏 #define UART_BASE_ADDR (0x20300000
#define C554_CH1_FCR (UART_BASE_ADDR+4)
#ifndef C554_REG_READ #define C554_REG_READ(C554_reg, result) result = (*(volatile unsigned short *)(C554_reg)) #endif
#ifndef C554_REG_WRITE #define C554_REG_WRITE(C554_reg, data) (*(volatile unsigned short *)(C554_reg)) = (data) #endif
//写FCR寄存器 C554_REG_WRITE(C554_CH1_FCR, 0,0x1);// FCR0置1
C554_REG_WRITE(C554_CH1_FCR, 0,0x8f);// 向FCR寄存器写值 |