W5500, SPI ok, Sn_SR always 0x00, TCP
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: W5500, SPI ok, Sn_SR always 0x00, TCP
by hjjeon0608 ·
Did you wait command register is cleared??
Plz, check this out.
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by aomgemalmaz ·
[quote=“hjjeon0608”]Did you wait command register is cleared??
Plz, check this out.[/quote]
I have seen that the Sn_CR is cleared after Open command.
However still I can not see SOCK_INIT status.
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by aomgemalmaz ·
[quote=“midnightcow”]Hi,
You will check the control byte of SPI frame.
I think that the control byte maybe wrong and you did accesse the other device as memory, instead of W5500.
As you mentioned before,
If the socket registers as Sn_MR, Sn_SPORT is normally write & read, OPEN command in Sn_CR regsiter will change the Sn_CR from SOCK_CLOSED to SOCK_INIT.
Plz, Verify block selected bits in the control byte.
Thank you.[/quote]
I have already checked these BSBs. I think there is no problem of SPI frame. Because I can read and write.
For example RTR(retry time register) has default of “0x07D0” which I can read and write via SPI.
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by aomgemalmaz ·
I have solved the problem. The problem was related with my spi_send function.
I arranged again and with the correct addres values.
Thanks for all replies.
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by hjjeon0608 ·
I’m glad to hear you solved problem.
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by mrprice ·
Hi,
I’m facing the exact same problem.
Can you elaborate how did you solve it?
what was the problem with the send function?
thanks
Price
RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by Alka Yadav ·
hi,
my Sn_SR register value always set 0x00, its not change its value from 0x00 to 0x22.
my code:
START:
setMR(Sn_MR_UDP);
setSn_PORT(0, 11000);
setSn_CR(0, Sn_CR_OPEN);
if(getSn_SR(0) !=SOCK_UDP)
{
setSn_CR(0, Sn_CR_CLOSE);
goto START;
}
RE: RE: W5500, SPI ok, Sn_SR always 0x00, TCP
by Eugeny ·
You must set socket’s MR to this value, not common register block’s MR.