Denny%20Yang99373:
可以在TCP失败后把串口相关的寄存器和中断相关的寄存器都打印出来,对比一下正常状态的寄存器
Dashan Du:
回复 Denny%20Yang99373:
//正常时
UART1_RBR = 0x( 39)UART1_THR = 0x( 39)UART1_IER = 0x( 5) //ERBI=1UART1_IIR = 0x( c1)UART1_FCR = 0x( c1)UART1_LCR = 0x( 3)UART1_MCR = 0x( 0)UART1_LSR = 0x( 60)UART1_MSR = 0x( 0)UART1_SCR = 0x( 0)UART1_DLL = 0x( 7b)UART1_DLH = 0x( 0)UART1_REVID1 = 0x(44141102)UART1_REVID2 = 0x( 0)UART1_PWREMU_MGMT = 0x(6003)
//进入TCP失败UART1_RBR = 0x( 39)UART1_THR = 0x( 39)UART1_IER = 0x( 5) //ERBI=1UART1_IIR = 0x( c4) //Receiver data available (priority 2)UART1_FCR = 0x( c4) //FIFOENUART1_LCR = 0x( 3)UART1_MCR = 0x( 0)UART1_LSR = 0x( 61) //data is readyUART1_MSR = 0x( 0)UART1_SCR = 0x( 0)UART1_DLL = 0x( 7b)UART1_DLH = 0x( 0)UART1_REVID1 = 0x(44141102)UART1_REVID2 = 0x( 0)UART1_PWREMU_MGMT = 0x(6003)UART1_MDR = 0x( 0)
failed connect (6)
上面对比也看不出什么啊