UDP iperf_server hints

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

UDP iperf_server hints

antonio
Hi all,
Any hints how to add UDP functionality (I am thinking more about server. I
can add a client later)?

I have a basic idea.

iperf_udpserver_init()
1. create a UDP PCB
2. Bind UDP PCP
2.1 create/alloc a iperf_state
3. set UDP PCB recv function -> pass recv_fn and iperf_state

On upd_recv_fun
1. if pbuf is not NULL, read number of bytes (p->tot_len), free pbuf.
2. if pbuf is NULL client is gone.

Any hints are welcome.

Thanks in advance.



--
Sent from: http://lwip.100.n7.nabble.com/lwip-devel-f11621.html

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

Re: UDP iperf_server hints

Dirk Ziegelmeier-2

On Fri, Sep 21, 2018 at 4:21 PM antonio <[hidden email]> wrote:
Hi all,
Any hints how to add UDP functionality (I am thinking more about server. I
can add a client later)?

I have a basic idea.

iperf_udpserver_init()
1. create a UDP PCB
2. Bind UDP PCP
2.1 create/alloc a iperf_state
3. set UDP PCB recv function -> pass recv_fn and iperf_state

On upd_recv_fun
1. if pbuf is not NULL, read number of bytes (p->tot_len), free pbuf.
2. if pbuf is NULL client is gone.

Any hints are welcome.

Thanks in advance.



--
Sent from: http://lwip.100.n7.nabble.com/lwip-devel-f11621.html

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

Re: UDP iperf_server hints

antonio
Thanks

br,
/Antonio



--
Sent from: http://lwip.100.n7.nabble.com/lwip-devel-f11621.html

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel