[SOLVED] UDP SpeedTest (Echo Client)

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] UDP SpeedTest (Echo Client)

    Hello,

    I am trying to make a speed test using UDP. I know there is a TCP example and it works fine, I tried to modify to open an UDP Socket and easily send data to a server (server using EchoTool). I commented receive part of the example and I send data out. I could open the socket and I receive my data out on the server side but somehow it is really slow. I checked with Wireshark and I reach only 200 packets per second (by TCP I reached 6000). On Debug Terminal I see always Warnings:

    *** Warning *** NET: No packet buffer for packet of 62 bytes --- Discarded
    *** Warning *** NET: No memory or too small buffer config for Rx packet, discarded.

    I tried to change stack size, buffer size, but it is always slow and always with warnings. I tried to start a new project completely empty, only starting socket on the MainTask and using sendTo in my while loop, nothing more, and I get exactly the same problem.

    Can somebody help me? Is there an UDP SpeedTest example from Segger? Has anybody here already worked with an UDP EchoClient?

    Thank you in advance.
    Best Regards.
    Rocha
  • cesar.rocha wrote:

    Hello,

    I am trying to make a speed test using UDP. I know there is a TCP example and it works fine, I tried to modify to open an UDP Socket and easily send data to a server (server using EchoTool). I commented receive part of the example and I send data out. I could open the socket and I receive my data out on the server side but somehow it is really slow. I checked with Wireshark and I reach only 200 packets per second (by TCP I reached 6000). On Debug Terminal I see always Warnings:

    *** Warning *** NET: No packet buffer for packet of 62 bytes --- Discarded
    *** Warning *** NET: No memory or too small buffer config for Rx packet, discarded.

    I tried to change stack size, buffer size, but it is always slow and always with warnings. I tried to start a new project completely empty, only starting socket on the MainTask and using sendTo in my while loop, nothing more, and I get exactly the same problem.

    Can somebody help me? Is there an UDP SpeedTest example from Segger? Has anybody here already worked with an UDP EchoClient?

    Thank you in advance.
    Best Regards.
    Rocha
    Hello Rocha,

    I've attached a UDP Sample for you which shows how to send UDP data. IP_SpeedServer_UDP.c is the SEGGER Application sample for your target and UDPSpeedClient.c runs on your PC. With this example you should be able to reach higher transfer speeds.

    Best regards,
    Jannik
    Files
    • udp_speed.zip

      (7.07 kB, downloaded 26 times, last: )