[W5100] How to check Winsock Close request or disconnected line with w5100?
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: [W5100] How to check Winsock Close request or disconnected line with w5100?
by becky ·
안녕하세요:grinning:
통신으로 주고받는 패킷을 잡아 분석할 수 있게 해주는 Wireshark라는 프로그램이 있습니다.
구글에 검색하시면 쉽게 설치 하실 수 있습니다.
LAN선이 빠진 것이라면 통신과정에서 timeout발생하여 socket이 close 됩니다.
따라서 이 경우에는 Wireshark에서 재전송 패킷이 8개를 확인 하실 수 있을 것입니다.
clinet에서 통신을 끊은 경우는 client가 RST 또는 FIN 패킷을 전송한 경우입니다.
wireshark를 이용하시는 것이 힘드시다면, 펌웨어 상에서 close 명령이 실행되는 경우 printf를 찍어 DEBUG message를 통해 확인하시면 될것 같습니다.
감사합니다.
RE: [W5100] How to check Winsock Close request or disconnected line with w5100?
by jameskim ·
LAN선이 빠졌는지 여부는 자기 장치에 대해서만 확인할 수 있습니다. W5100의 경우에는 PHY LINK LED Pin을 확인해서 LAN선이 빠졌는지를 확인할 수 있습니다. 물론 이 경우에도 종단간의 모두 Ethernet 연결상의 특정 지점의 LAN 선이 빠진 것을 확인할 수는 없습니다.
그리고, Socket Closed 상태값만 가지고는 어떤 이유에 의해서 Socket Closed가 되었는지를 알 수는 없습니다.
아래 Becky가 답변한 것처럼 Wireshark로 패킷을 확인해서 패킷 재전송과 RST 이나 FIN 패킷이 있다면 어느정도는 원인을 파악할 수 있지만 완벽하게 원인을 파악할 수 있는 것은 아닙니다.
감사합니다.