lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] lwIP performance with FreeRTOS


From: Chris Ponder
Subject: Re: [lwip-users] lwIP performance with FreeRTOS
Date: Fri, 24 Feb 2012 15:05:31 +0000

My code is not currently that clever, we are not really interested in receive 
performance, even the 36 Mbps would be much more than we need there. The metric 
is purely on transmit performance and I am using a straightforward while loop 
to send the data:
        while (1)
        {
                // Create a netbuf to use and allocate ciPayloadSize of buffer 
space
                buf = netbuf_new();
                netbuf_alloc(buf, ciPayloadSize);       // ciPayloadSize = 272

                // Send some data if the buffer created ok
                if (buf!= NULL)
                {
                        netconn_connect(conn, &DestIPAddr, UDP_SERVER_PORT);
                        netconn_send(conn, buf);
                        netbuf_delete(buf);
                }
        }

As you can see I am not even putting any real data in the packet, it is just 
the empty buffer that is being sent.

The thread containing this code is started with:
  sys_thread_new("udpecho_thread", udpecho_thread, NULL, 
DEFAULT_THREAD_STACKSIZE, UDPECHO_THREAD_PRIO );

and 
UDPECHO_THREAD_PRIO  =  tskIDLE_PRIORITY + 3 

Cheers
Chris

-----Original Message-----
From: FreeRTOS Info
Sent: 24 February 2012 14:56
To: Mailing list for lwIP users
Subject: Re: [lwip-users] lwIP performance with FreeRTOS

On 24/02/2012 14:43, Chris Ponder wrote:
> Lol, that is no problem, it is good to have the help J
> 
>  
> 
> Yes that is still a long way from what I had hoped for. I had thought 
> that the drop from standalone+raw to RTOS+netconn would only be 2 or 3 
> Mbps at most, half seems a  little drastic.

How is the network interface signalling that packets have arrived/been 
transmitted?

Normally the MAC interrupt will use a semaphore to signal to a task that new 
data has arrived and needs processing.  The semaphore will unblock the task 
that was waiting for the data, and the task will be prioritised such that it 
runs immediately (just as if all the processing was done in the interrupt 
itself).

Regards,
Richard.

+ http://www.FreeRTOS.org
Designed for Microcontrollers.
More than 7000 downloads per month.





> 
>  
> 
> Thanks again
> 
> Chris
> 
>  
> 
> *From:address@hidden
> *Sent:* 24 February 2012 14:35
> *To:* Mailing list for lwIP users
> *Subject:* Re: [lwip-users] lwIP performance with FreeRTOS
> 
>  
> 
> Chris Ponder wrote:
> 
> Ahh, that helps J
> 
> 
> Hehe, sorry for the confusion. I'm didn't have access to the lwIP 
> sources when writing that.
> 
> 
> Yes the correct macro is LWIP_TCPIP_CORE_LOCKING and increased the 
> speed to 45.3 Mbps, getting better J
> 
> 
> Hmm, that's still only half of what you get with the raw API, is it? I 
> would have expected it to be better...
> 
> Simon
> 
> ********************************************************
> 
> The information transmitted is intended only for the person or entity 
> to which it is addressed and may contain confidential and/or 
> privileged material. If you are not the addressee, any disclosure, 
> reproduction, copying, distribution, or other dissemination or use of 
> this communication is strictly prohibited. If you have received this 
> transmission in error please notify the sender immediately and then 
> delete this e-mail.
> E-mail transmission cannot be guaranteed to be secure or error free as 
> information could be intercepted, corrupted lost, destroyed, arrive 
> late or incomplete, or contain viruses.
> The sender therefore does not accept liability for any errors or 
> omissions in the contents of this message which arise as a result of 
> e-mail transmission. If verification is required please request a hard 
> copy version.
> 
> ********************************************************
> 
> 
> 
> _______________________________________________
> lwip-users mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/lwip-users

_______________________________________________
lwip-users mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/lwip-users
********************************************************

The information transmitted is intended only for the person or entity to
which it is addressed and may contain confidential and/or privileged
material. If you are not the addressee, any disclosure, reproduction,
copying, distribution, or other dissemination or use of this communication is
strictly prohibited. If you have received this transmission in
error please notify the sender immediately and then delete this e-mail.
E-mail transmission cannot be guaranteed to be secure or error free as
information could be intercepted, corrupted lost, destroyed, arrive late or
incomplete, or contain viruses.
The sender therefore does not accept liability for any errors or omissions
in the contents of this message which arise as a result of e-mail
transmission. If verification is required please request a hard copy
version.

********************************************************




reply via email to

[Prev in Thread] Current Thread [Next in Thread]