Demo FreeRTOS+UDP on ML605

roberto-plus wrote on Monday, November 04, 2013:

Hi guys,
I’m trying to make an example of UDP trasmition. After following the tutorial in :
http://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_UDP/FreeRTOS_UDP_IP_Embedded_Ethernet_Tutorial.shtml#adding_udp_to_freertos_project
I have this problem.
https://gist.github.com/anonymous/7303406
The source code organitation is :
http://imageshack.us/photo/my-images/30/mvrf.JPG/
Somebody can help me?
Thanks

rtel wrote on Monday, November 04, 2013:

Assuming the line is from an unmodified V1.0.1 version of NetworkBufferManagement.h then I would guess the compiler does not know what a xNetworkBufferDescriptor_t type is.

Have you #included “FreeRTOS_UDP_IP.h” before #including “NetworkBufferManagement.h”?

See the includes in \FreeRTOS-Plus\Source\FreeRTOS-Plus-UDP\portable\NetworkInterface\SH2A\NetworkInterface.c - which is a very basic exmaple (that does not support zero copy).

Regards.

roberto-plus wrote on Monday, November 04, 2013:

Yes,I put #included “FreeRTOS_UDP_IP.h” before #including “NetworkBufferManagement.h” like \FreeRTOS-Plus\Source\FreeRTOS-Plus-UDP\portable\NetworkInterface\SH2A\NetworkInterface.c

As you sent me, I’m using the file networkInterface.c from SH2A.
Did you see my source code organitation? Is it correct?
http://imageshack.us/photo/my-images/30/mvrf.JPG/

Where can I find the defination of xNetworkBufferDescriptor_t ?
Thanks a lot for the support.

rtel wrote on Monday, November 04, 2013:

Where can I find the defination of xNetworkBufferDescriptor_t ?

Good point - the SH2A driver has not been used since the definition was split into a separate header file. Try adding

#include “FreeRTOS_IP_Private.h”

immediately after including “FreeRTOS_UDP_IP.h”.

Hope that helps. Applications should not include FreeRTOS_IP_Private.h directly, but it is necessary for drivers.

Your files look fine as afar as I can tell from the image.

Regards.

roberto-plus wrote on Monday, November 04, 2013:

Yes maybe it’s little bit better.
Now error is in NetworkInterface.c:127:
https://gist.github.com/anonymous/7304999

My NetworkInterface.c is :
https://gist.github.com/anonymous/7305017

Best regards

rtel wrote on Monday, November 04, 2013:

Yes - it seems it was not such a good plan to start with that driver after all as it is out of date.

From the previous posts you know where to find the xNetworkBufferDecriptor_t structure, from its definition, and from the other drivers in the portable layer, you can see that the name of the structure member was changed from pucBuffer to pucEthernetBuffer.

Regards.

roberto-plus wrote on Monday, November 04, 2013:

Dear Richard, thanks a lot.
Yes, I know where to find the xNetworkBufferDecriptor_t structure. Now, I think is the moment to change its definition and to create driver for my Ethernet.
I’m following this link :
http://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_UDP/Embedded_Ethernet_Porting.shtml
Best regards