W5500 No PHY Link
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 No PHY Link
by Edward ·
Hi.
PHY link is hardware area.
So, you should checking schematic & artwork.
And refer to below two schematic.
WizArduino Schematic is using PoE. please MD1 and RJ-45 checking.
I have a few more question.
What is 21033814802? It is ethernet connector??
please datasheet give me.
Thank you
RE: W5500 No PHY Link
by MexxMe ·
Hi,
Same issue here.
PCB designed according to ref. schematics, produced in factory
Plug in w5500 to Cisco switch, link does not come up
But when I disable Auto-negotiation on Cisco switch, port is UP. This is on 100Mbit port, and on 1Gbit port, I need to disable Auto-negotiation and manually set port speed to 100Mbit.
This is happening on different Cisco switches, 2960 series and SF-300 series
Thing is that I cannot un-solder resistor to disable auto-negotiation on pcb since it is resistor array
Can I disable auto negotiation in code, regardless of resistors connected?
I have red that PHYCFGR should be changed but I am not sure where
This is section from w5500.h:
__GP_REGISTER8 (PHYCFGR, 0x002E); // PHY Configuration register, default value: 0b 1011 1xxx
w5500 datasheet on page 43 states:
PHYCFGR (W5500 PHY Configuration Register) [R/W] [0x002E] [0b10111XXX]
But I am stuck here…
Any assistance is appreciated
Thanks in advance
RE: W5500 No PHY Link
by Eugeny ·
Why not just to try it? Datasheet says that if you set bit 6 into 1, you can override PMODE input pins settings.
For example, for 100MBit no auto-neg you write 0b1_1_011_000 (0xD8) into this register.
RE: W5500 No PHY Link
by MexxMe ·
Thats what I am trying to figure out now… (maybe this post will help some dummy like me…)
According to datasheet and code from w5500.h folowing is set
__GP_REGISTER8 (PHYCFGR, 0x002E); // PHY Configuration register,
Default value: 0b 1011 1000
1 - RST - 7 bit - No Reset (0 RESET)
0 - OPMD - 6 BIT - 0: Configure with the H/W PINs(PMODE[2:0]) 1: Configure with OPMDC[2:0] in PHYCFGR
1 - OPMDC- 5 bit -
1 - OPMDC- 4 bit - 111: All capable, Auto-negotiation enabled
1 - OPMDC- 3 bit -
0 - DPX - 2 bit - Duplex Status [Read Only] -
0 - SPD - 1 bit - Speed Status [Read Only]
0 - LNK - 0 bit - Link Status [Read Only]
I need to set sixth bit to 1 so my settings would be: 0b 1101 1000 (HEX:0xD8 - DEC:216)
1 - RST - 7 bit - No Reset (0 RESET)
1 - OPMD - 6 BIT - 0: Configure with the H/W PINs(PMODE[2:0]) 1: Configure with OPMDC[2:0] in PHYCFGR
0 - OPMDC- 5 bit -
1 - OPMDC- 4 bit - 011: 100BT Full-duplex, Auto-negotiation disabled
1 - OPMDC- 3 bit -
0 - DPX - 2 bit - Duplex Status [Read Only] -
0 - SPD - 1 bit - Speed Status [Read Only]
0 - LNK - 0 bit - Link Status [Read Only]
Now comes the tricky part that I am not sure about, where to write this value?
So far it seems that Ethernet2.cpp could be a good place to put it, when ethernet is initialized:
Declare new variable:
static const uint8_t myPHYCFGR = 0xD8;
void EthernetClass::begin(IPAddress local_ip, IPAddress dns_server, IPAddress gateway, IPAddress subnet)
{
w5500.init();
Set PHY configuration before or after init?
w5500.setPHYCFGR(myPHYCFGR);
w5500.setIPAddress(local_ip.raw_address());
w5500.setGatewayIp(gateway.raw_address());
w5500.setSubnetMask(subnet.raw_address());
_dnsServerAddress = dns_server;
}
Am i looking into right direction?
Thank you in advance
RE: W5500 No PHY Link
by Eugeny ·
I think you should do it after init because this init routine may software-reset chip, and this setting will get reset too. Leave as you have it now for first test.
RE: W5500 No PHY Link
by MexxMe ·
Seems like this doesnt work
Thing is that I am not sure if I am doing it right, if declaration is correct
Tried to edit Ethenet2.cpp
w5500.init();
w5500.setPHYCFGR(0xD8);
w5500.setIPAddress(local_ip.raw_address());
But nothing changes, like I did nothing
Tried also to setPHY before init, same thing
RE: W5500 No PHY Link
by Eugeny ·
To prove that you have this setting effective you can read this register any time and check that it is still 0xD8. Do it just before you start your main code, and make some signal (e.g. turning LED on) if it is not 0xD8. I assume you tried different network cables and cable is not an issue?
RE: W5500 No PHY Link
by MexxMe ·
thx for suggestion, good point
I will try to make function that will return register value to confirm that Im actually changing value
Cables are not an issue. Tried with any combination of straight/crossover, lenghts 1-3m
I have found that some switches have auto-negotiation compatibility issues with some of devices
For example, one of the Cisco switches have big list of devices with compatibility issues:
[url]http://www.cisco.com/c/en/us/support/docs/switches/catalyst-6500-series-switches/17053-46.html[/url]
It describes that “Duplex Mismatch” will sometimes happen when client side is configured in Auto mode.
There are different configurations when issues can happen, AUTO<>100Mbit, 100Mbit<>1000Mbit, etc.
This makes me thinking that DIP switches could be better option for setting link mode instead of soldered resistors?
RE: W5500 No PHY Link
by Eugeny ·
This is good idea if you expect device being used with such switches. However you may also think about having it configured with software, connecting these W5500 configuration pins to MCU’s output pins which are software-configured.
RE: W5500 No PHY Link
by MexxMe ·
Hm,
Again good thinking…
I can store 3-bits into EEPROM and set PHY mode on boot
Anyway I have web page for other unit setting.
Worst case scenario, connect unit directly to PC and configure PHY. Save settings and plug into network switch
Need to test if this works…