W5300 Server관련 문의
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: W5300 Server관련 문의
by yskim ·
불량 Board 9장중
Case1
Case1
1장은 무한 루프 반복
void setSn_CR(SOCKET s, uint16 com)
{
IINCHIP_WRITE(Sn_CR(s),com);
while(IINCHIP_READ(Sn_CR(s))); // wait until Sn_CR is cleared. <===여기서 무한 루프를 반복하는
}
======================
SHAR : 00:08:dc:00:b7:d9
GWR : 192.168.001.001
SUBR : 255.255.255.000
SIPR : 192.168.001.100
인쇄후에 무한 루프를 반복하고 있음
Case2 – 2장
void Check_tcps(SOCKET s, uint16 port, uint8* buf, uint16 mode)
{
uint32 len;
switch(getSn_SSR(s)) // check SOCKET status
{ // ------------
case SOCK_ESTABLISHED: // ESTABLISHED?
if(Net.SendFlag != 1)
{
if(getSn_IR(s) & Sn_IR_CON) // check Sn_IR_CON bit
{
PrintString(“%d : Connect OK\r\n”,s);
setSn_IR(s,Sn_IR_CON); // clear Sn_IR_CON
}
// CommandCheck(len,Net.Rx_Data);// yskim Add
}
}
else
{
Net.SendFlag = 0;
if(Net.Tx_Length != send(s,Net.Tx_Data,Net.Tx_Length)) // send
{
PrintString(“%d : Send Fail.len=%d\r\n”,s,Net.Tx_Length);
}
}
break;
// ---------------
case SOCK_CLOSE_WAIT: // PASSIVE CLOSED
disconnect(s); // disconnect
PrintString(“SOCK_CLOSE_WAIT\r\n”);
break;
// --------------
case SOCK_CLOSED: // CLOSED
close(s); // close the SOCKET
PrintString(“SOCK_CLOSED\r\n”);
socket(s,Sn_MR_TCP,port,mode); // open the SOCKET
PrintString(“SOCK_OPEN\r\n”);
break;
// ------------------------------
case SOCK_INIT: // The SOCKET opened with TCP mode
listen(s); // listen to any connection request from “TCP CLIENT”
PrintString(“%d : LOOPBACK_TCPS(%d) Started.\r\n”,s,port);
break;
default:
break;
}
}
getSn_SSR(s)의 Return 값이 0x14가 나타남 - 다수의 경우
getSn_SSR(s)가 0x14가 나올수 있나요?
아직 전체적인 파악을 못하고 있습니다.
RE: W5300 Server관련 문의
by yskim ·
W5300 Pin66 /RESET가 정상적으로 Reset되지않아서 발생한 문제들이었습니다.
RESET이 잘되는줄 알았는데 codeing중에 오류가 있었습니다.
답변 감사드립니다.