Trouble with SPI between SAMD21 and W5500

Hello, we’re designing a board with a SPI bus between SAMD21 and W5500 chip.
But for some reason the W5500 chip is not recognized by the SAMD21.
Here are some technical informations of the project:

  • we are using the arduino framework
  • the firmware code was proven to work with a SAMD21 evaluation board and wiz850io module
  • the w5500 ethernet port is connected to a KSZ8995MA switch chip
  • we use a custom UF2 bootloader on the SAMD21 (also proven to work with the eval board and wiz850io)

Here is picture of the schematics:

If anyone spots something weird, or if anyone would need more information please let me know.
Thanks for you help!

Best regards


And here is the assembled board

Chip must be “recognized” even if its PHY is not operating or connected properly. Thus, if you confirm that software reads wrong values from the W5500 registers, then you have problem with digital power, interface (SPI, reset signal) or clocking circuit.

Thanks for your answer. By “not recognized” I mean I receive the following error:
EthernetNoHardware from the following library

Which I find weird because everything was working OK with a samd21 protoype board and a wiz850io.
I checked power lines, interface signals and crystal: everything seems OK.

Any idea ?

I tried with the offical arduino ethernet lib and I have the same error.

You must explicitly and exactly state whgat you checked and how you did it.

Hello Eugeny. Thanks for the follow up.
So here is what I checked:

  • power lines: with a multimeter I checked all VDDs, GNDs, pulled up and pulled down pins.
  • SPI: I checked continuity between w5500 and samd21
  • Crystal: my oscilloscope ain’t fast enough, but I tried various crystal and caps combinations.
  • I also verified the values of resistors and caps around the w5500
    (BTW, the samd21 works well)

Appart checking the crystal with a faster oscilloscope, do you have any ideas ?


So you performed a kind of “visual inspection”.

Then you just miss wokring tools. You must check that it actually oscillates, check voltages with scope to ensure they are continuous and noise-free, and see if activity is going on the SPI line.

When you plug LAN cable, do the LINK/SPD LEDs turn on?

What can I say ? Sorry ? :thinking:

The w5500 ain’t linked to a physical rj45 port, the w5500 is linked to a ksz8995 ethernet switch chip. And yes the leds do turn on.

No, you just borrow it from people who have it.

LEDs attached to W5500 pins 25 and 27?

looking for a DSO5200 right now.


Then power is good, and W5100 is operational. Search for problems in SPI circuitry.

Hello, we finally found the problem.
We are using the Arduino framework to code on the SAMD21. And the variant we compile against (Arduino Zero) doesn’t use the same sercom for the SPI interface. We use sercom1 and Arduino Zero uses sercom4. So we dug a bit and found that sparkfun SAMD21 mini uses the same exact sercom as us for the SPI. And now everything is working as expected.

Thanks for the help Eugeny.


1 Like