cancel
Showing results for 
Search instead for 
Did you mean: 

Cube MX generated LwIP: Binary file uploading crashes the progarm if the network is overloaded

Szabolcs Vass
Associate II
Posted on February 13, 2017 at 09:43

Hello everybody,

I'm working on a webserver application, and I use the lwip 1.4  tcp/ip stack generated from the Cube Mx older version. Unfortunatelly I don't remember which version of Cube Mx because it was a long time ago, when I generated this project.(2015) But I know that version of Cube Mx containes just the Lwip 1.4, while the latest version of Cube Mx already contains the LwIp 1.5. This project is an old project and sometimes I paused to develop other projects, but it's the time when I would like to finish it.

I'm working on STM32F407 device. I implemented the binary file upload, which wasn't implement on the stack in default. Sometimes when I try to upload the files, get TCP retransmission and TCP Dup Ack error on network capture. Sometimes the file upload was succesfully and somtimes wasn't. Can You tell me somebody why it's caused? I didn't find the right solution up to now.

The two captures(one when the upload was succesfully, one when wasn't) I attached in the attachments.

Please use the following filter to see the captures between my PC and my device: ip.addr == 192.168.0.23

I asked this question on the lwip developers forum, but they said, that this stack is a vendor specific stack, and ask from You.

Please help me to find the right solution together.

Kind regards,

Szabolcs

#lwip-1.4 #netwrok-overloaded #cube-mx #binary-file-upload
3 REPLIES 3
Imen.D
ST Employee
Posted on February 13, 2017 at 18:08

Hello

Vass.Szabolcs

‌,

Your issueis reported internally and wecome back to you as soon as possible.

Regards

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Posted on February 23, 2017 at 14:07

Hello IMEN D,

   I wolud like to ask that, did You get the solution for my problem?

Kind regards,

Szabolcs

Posted on March 15, 2017 at 20:44

Hello,

I'm maybe in a similar problem. If not, I'll start the new thread.

I have tested download of dynamically generated file with size about 10MB. This is implemented in HTTP server which comes with LWIP and uses fs_open_custom and fs_read_custom functions for serving the file. My code generate file with content of array with pattern 0x00 to 0xFF. 

Always I downloaded whole generated file with size (10 * 1024 * 1024) bytes. But the content was different. While I used Wireshark for debugging network traffic, I found out that there are several re-transmit which looks correctly based on SEQ numbers. But the content is not the right. It looks that re-transmitted packed has incorrect data from wrong buffer. 

Does Imen D have some solution.?

Best regards

Tomas