Tcp server connected to multiple client via an ethernet switch
Ethernet Chips
No replies yet. Be the first to reply.
Join the discussion.
Ethernet Chips
No replies yet. Be the first to reply.
Join the discussion.
Share projects and connect with makers.
Joined before the site update? first.
New to WIZnet Makers?
We sent a verification link to your address. Open it to activate your account, then log in.
Accounts from this email provider are reviewed by an administrator after verification. Approval usually takes one business day.
Already have an account?
Enter your email address. If it belongs to an account, we'll send a link to set a new password. Members who joined before the site update use this to set their password.
If an account uses that address, we sent a link to set a new password. The link works once and expires in 30 minutes.
Know your password?
Need an account?
RE: Tcp server connected to multiple client via an ethernet switch
by acpie360 ·
If W5300 is similar to W5500, then yes, you need to “establish one socket for each client”. In my application, I allocate 4 sockets for my embedded Web server. Instead of treating each socket individually, I treat them as an array of sockets.
RE: Tcp server connected to multiple client via an ethernet switch
by Peyman.Dp ·
Hi acpie360,
Thanks a lot for your reply.
What do you means by" treat them as an array of sockets"?
At first, i initialize all the sockets simultaneously. But when it comes to check sockets status, don’t know how to react. Especially when only one of them has been stablished.
Could you describe how did you switch between sockets? And when?
I would be grateful if you draw a flowchart.
Thanks in advance.
RE: Tcp server connected to multiple client via an ethernet switch
by acpie360 ·
I use ioLibrary.
I am not sure what you mean by “switch between sockets”. Each socket operates independently. They all have their own “states”, i.e., SOCK_CLOSED, SOCK_INIT, SOCK_LISTEN, SOCK_CLOSE_WAIT, SOCK_SYNRECV and SOCK_FIN_WAIT.