2016-09-14 06:18 AM
Hello
I have added this code to my project to use printf as command to send USART's datastruct __FILE { int handle;} ;
FILE __stdout;
FILE __stdin;
FILE __stderr;
int fputc(int ch, FILE *f)
{
while(!USART_GetFlagStatus(USART1,USART_FLAG_TXE));
USART_SendData(USART1,ch);
return ch;
}
it works fine.However when I try to use Ethernet this command hang my MCU but if I use
USART_SendData(USART1,ch);
it works fine again.I want to know why this command doesn't work properly after I use cmsis Ethernet library.
I added this library for Ethernet
(RTOS->keil RTX)
(CMSIS Driver->ethernet MAC(API))
(CMSIS Driver->ethernet PHY(API))
Device(GPIO)
Network(core + interface + socket->TCP/UDP)