I want to connect a 3 port switch from Micrel to my NS9750 development board. The switch has two PHY ports and the third port is an MII port. The idea is to connect the third port (MII) to the MII connector on the NS9750 development board. The communication will be MAC to MAC and no PHY will be involved. The question is, do I have to write a MII driver for the Micrel switch, like I would have to do when using a PHY not supported by the NetSilicon drivers?
I am using a Micrel switch (KS8993) together with a NS7520. You don’t have to write a new driver but you have to add some support for the device. The MII is standars but the BSP have routines for reading the speed and the duplex which is different from device to device. This is actually not that interesting when you have a switch device since you can always communicate with full duplex and 100Mb/s and the device will solve is so when the device found is KS8993 I always return full duplex and 100Mb/s. Note!! The BSP does not actually support 2 MII “ports” and it will only configure the first one found. You could modify the driver to handle that but in my case it was not needed. The KS8993 does not need to be configured since all the configurations can be controlled by bootstrap so I have modified MII.c so that when the found phy is KS8993 it does not wait for tha link to be up (since the first port may not be connected) and does not reset the configuration and so on. This works without any problems. Hope this answers your question. Regards, Jesper
Hallo Jesper, to read link and speed of the KS8993 via MII I need the registeraddress(es) and the bits where the informations are stored. Do you have the addresses of these register or a plot of the registerset of the KS8993 which you can post me? Many thanks in advance, Jens