【RT1176 ENET】The speed of the 100M Ethernet port cannot reach the ideal speed in RTOS

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

【RT1176 ENET】The speed of the 100M Ethernet port cannot reach the ideal speed in RTOS

2,272 Views
13692631114
Contributor I

Hi

        We encountered some strange phenomena when testing the speed of RT1176 ENET100, hope it can help to take a look.

        The attachment is our test code. The code is based on lwip ping freertos cm7 and adds iperf code. After power-on, the speed measurement server is automatically opened, and the computer is used as the device test.

        The test phenomenon is as follows:

        1. The default TCP_WND in lwipopts.h is (2 * TCP_MSS), and the test speed is about 40Mbits/s;

        2. Modify the TCP_WND in lwipopts.h to (8 * TCP_MSS), and the test speed should be ≤ 1Mbits/s;

        Our question is why increasing the TCP_WND will reduce the speed, but the iperf bm routine is fine. The same rtos lwip iperf test we tried on RT1052 is no problem, it can reach 94Mbits/s.

        Note: 1. The project configuration selects flexspi nor sdram debug. 2. The hardware uses EVK 100M network port.

        Thanks.

 

Labels (1)
0 Kudos
12 Replies

2,210 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @13692631114 ,

   Thanks you for your interest in the NXP MIMXRT product, I would like to provide service for you.

  Please help to confirm the following points:

1. Which EVK board and version you are using?

  Seems you are using the MIMXRT1170-EVK board, but I also need the version number.

 

2. Which SDK version you are using now?

 

3. Can you reproduce the issues directly on the MIMXRT1170-EVK+SDK_2_12_0_MIMXRT1170-EVK?

I mean this code:

SDK_2_12_0_MIMXRT1170-EVK\boards\evkmimxrt1170\lwip_examples\lwip_ping\freertos\cm7

4. how do you test the speed?

Please also share some screen shot about it,  as I need to reproduce your issues at first, it's better based on the NXP SDK and the EVK board directly, then if I meet any issues, I can also ask internal expert's help!

 

Best Regards,

Kerry

 

0 Kudos

2,201 Views
13692631114
Contributor I

Hi Kerry,

Answer your questions below:

1. I'm using the MIMXRT1170-EVK, I'm not sure what the version number is, you can check the photo of the board in the attachment.

2. I am using SDK_2.12.0_MIMXRT1170-EVK.

3. The environment I tested is MIMXRT1170-EVK+SDK_2_12_0_MIMXRT1170-EVK. And I test iperf in SDK_2_12_0_MIMXRT1170-EVK\boards\evkmimxrt1170\lwip_examples\lwip_ping\freertos\cm7.

4. Tested with jperf-2.0.2 tools. MIMXRT1170-EVK is the server and the computer is the client. The screenshot of the test process is in the attachment.

Best Regards,

Jaydon

0 Kudos

2,194 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @13692631114 ,

  Thanks for your information.

   Your board is C2 version, the same as my C1 version.

   You are using the J3 ENET port, right?

   And, I can reproduce your issues with your attached project (MIMXRT1170-EVK-lwip_ping_freertos_cm7.7z) directly?

  Please also share your PC IP configuration, I mean this one:

kerryzhou_0-1661857408258.png

 

I will help you do the testing on my side.  My Jpef is 2.0.0, please also share your jperf-2.0.2  download link, I will use the same version as you.

BTW,  if you work this issues for the company, it's better to use your company email to create the case instead of 3rd part email, then we can put more working time on it, otherwise, the 163 email will have a low support priority, and working time assignment is limit.  This question which need the testing normally need more working time, thanks a lot for your understanding.

 

Best Regards,

Kerry

 

 

0 Kudos

2,186 Views
13692631114
Contributor I

Hi Kerry,

Yes, I use the J3 ENET port. And You can reproduce it directly on my attached project. Computer IP configuration and iperf tool see the attachment.

BTW, Can you provide your email address? I send it to you using company mail.

Best Regards,

Jaydon

0 Kudos

2,169 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @13692631114 

  I have tested your project on my side.

  But some difference with you.

You mentioned:

        1. The default TCP_WND in lwipopts.h is (2 * TCP_MSS), and the test speed is about 40Mbits/s;

        2. Modify the TCP_WND in lwipopts.h to (8 * TCP_MSS), and the test speed should be ≤ 1Mbits/s;

But my test result:

1. TCP_WND in lwipopts.h is (2 * TCP_MSS)

kerryzhou_0-1661943260215.png

 

2. TCP_WND in lwipopts.h to (8 * TCP_MSS)

kerryzhou_1-1661943273696.png

 

Just check the speed, my side seems still (8 * TCP_MSS) more quick than  (2 * TCP_MSS).

So, could you please share your two situation picture again?

In fact, I just test your project directly, only modify lwipopts.h like you mentioned.

Best Regards,

Kerry

 

0 Kudos

2,165 Views
13692631114
Contributor I

Hi Kerry,

Our test results seem to be different, but your test results are far from the expected 94MBits/sec. Because set TCP_WND to (8 * TCP_MSS) on lwip_iperf_bm_cm7, the speed can reach 94MBits/sec. And on RT1052 platform, lwip_iperf_freeRTOS can also reach 94MBits/sec.

I remember your side is the C1 version, so I also tested on the C1 version, the project is the same as the one sent to you. Here are the test results:

1. TCP_WND in lwipopts.h is (2 * TCP_MSS)

13692631114_0-1661997578829.png

 

2. TCP_WND in lwipopts.h to (8 * TCP_MSS)

13692631114_1-1661997613896.png

 

3.MIMXRT1170-EVR C1

13692631114_2-1661997672797.jpeg

BTW, I am an employee of ZLG Technology Corp., Ltd., if it is convenient for you, you can reply me by the following email:
zhangyunfeng@zlgmcu.com

Best Regards,

Jaydon

 

0 Kudos

2,161 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @13692631114 ,

    So, you mean, when you run this code on MIMXRT1170-EVK C1:

SDK_2_12_0_MIMXRT1170-EVK\boards\evkmimxrt1170\lwip_examples\lwip_iperf\bm\cm7

  The iperf can upto 94MBits/sec.

  But, when you add the iperf code to this code:

SDK_2_12_0_MIMXRT1170-EVK\boards\evkmimxrt1170\lwip_examples\lwip_ping\freertos\cm7

Then, the speed can't up.

Do you try to comment the ping code, just add the iperf related code in the freertos project, whether still the same? Seems you already comment the ping code.

So, now the main issue is the freertos+iperf can't get the high speed, right?

I checked SDK_2_12_0_EVKB-IMXRT1050\boards\evkbimxrt1050\lwip_examples\lwip_iperf, also no freertos version now.

You can delete your email in the public side, I mean, you use your company email create the case, then the case level will be high, support level will also be higher, now the 163 email have low support level.

 

0 Kudos

2,182 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @13692631114 ,

   If you want to use the private method, you can create the case with your company email, the flow is:

1. Open below SUPPORT site, click blue "Go to Tickets" in the middle.
http://www.nxp.com/support/support:SUPPORTHOME

2.Then you will be requested to Login, if you have no an account, please first Register with your business email.

3.After login, please "Create New Cases" button in the middle, then you can submit your question.

We also support the Chinese language, so you even can write Chinese directly in the above case.

Anyway, I will help you do the testing now, if you are convenient, you can create a private case, then, if we meet any issues, we need your company information to check with our internal expert, thanks.

Best Regards,

kerry

0 Kudos

2,241 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

We would recommend customer to refer below link about how to config LwIP to get better Ethernet throughput:

https://lwip.fandom.com/wiki/Maximizing_throughput

Wish it helps.

Mike

0 Kudos

2,244 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

I am checking this issue and will let you know when I have any updated info.

Thank you for the patience.

Mike

0 Kudos

2,230 Views
13692631114
Contributor I

Hi Mike,

Do you have any recurrence of this phenomenon?

Jaydon

0 Kudos

2,211 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Jaydon,

I have no license for Keil IDE and just in progress to applied for one.

My colleague Kerry will continue to support this thread.

Thanks for the patience.

Mike

0 Kudos