Hello, experts...
Following is my RTCS Setup code.
_RTCSPCB_init = 4; _RTCSPCB_grow = 2; _RTCSPCB_max = 20; _RTCS_msgpool_init = 4; _RTCS_msgpool_grow = 2; _RTCS_msgpool_max = 20; _RTCS_socket_part_init = 4; _RTCS_socket_part_grow = 2; _RTCS_socket_part_max = 20; _UDP_max_queue_size = 3000; _RTCSTASK_priority = 6; _RTCSTASK_stacksize = 10000;... error = RTCS_create(); error = ipcfg_init_device(0, mac); error = ipcfg_bind_staticip(0, &ip_data);...// Each Task call this function for socket binding.// currently, I used 8 UDP sockets.void Bindings( uint_32 *pSock, sockaddr_in *pladdr, uint_32 portNo ){ uint_32 error; pladdr->sin_family = AF_INET; pladdr->sin_port = portNo; pladdr->sin_addr.s_addr = INADDR_ANY; *pSock = socket(PF_INET, SOCK_DGRAM, 0); if( *pSock==RTCS_SOCKET_ERROR ) { printf("error; port=%d\n", portNo); _task_block(); } error = bind(*pSock, pladdr, sizeof(sockaddr_in)); if( error!=RTCS_OK ) { printf("error; bind port=%d, error=0x%lx\n", error); _task_block(); }}// Each Task has infinite while loop.void TASK1( uint_32 initial_data ){ // local variable definition ... Bindings( &sock, &laddr, 20000 ); while( 1 ) { rlen = sizeof(raddr); length = recvfrom(sock, buffer, sizeof(buffer), 0, &raddr, &rlen); printf("received length = %d\n", length);... }}
Abobe code works fine.
However, if frame size is longer than 823 bytes then recvfrom() is never return.
CW7.2 / RTCS / Ethernet Status dialog is shown attached image.
Rx DMA Overrun: 63 --> this counter is exactly matched with my test sending counter.
How can I fix it?
Let me know if I the question isn't very clear.
I would like to know how to modify or check my souce code in order to prevent this Rx DMA Overrun error.
Regards.