W6100 read/write MAC

Hello!

When on startup I try to write MAC address I use the following SPI command:

41 20 04 01 02 03 04 05 06

And I get response:
01 02 03 00 00 00 00 00 00

But then I try to read it with:
41 20 00 00 00 00 00 00 00
And get the reply:
01 02 03 00 00 00 00 00 00

My SPI comms work as I get 01 02 03 at the start. But why the register is empty?

Hello

There’s no address inside the chip.
You have to buy it separately and add address.

Thank you

Hello louis,
I am facing same type of problem in my project where I am using valid MAC value “0x0013E1170001”.
Steps are:
41 20 04 00 13 E1 17 00 01

And I get response:
01 02 03 00 00 00 00 00 00

But then I try to read it with:
41 20 00 00 00 00 00 00 00
And get the reply:
01 02 03 00 00 00 00 00 00

Please let me know what can be the issue?

Thanks,
Himmat

Hi,

your SPI stream is correct. You address 0x4120 (first byte of SHAR), Bank 0 (common registers) and you try writing variable length (0x04) and then reading variable length (0x00).

I had issues with my breadbord wirings, where i thought, it was software (read my thread about this). Try reading the CIDR and VER registers to verify your SPI is working properly.

What is your SPI speed?