3
\$\begingroup\$

It is common to find microcontrollers with an integrated 10/100 Ethernet MAC and PHY. Some microcontrollers, such as the Texas Instruments TM4C129x series, offer both an integrated PHY and RGMII interface for external PHYs, shown in the figures below:

enter image description here enter image description here

(c.f. this datasheet (PDF))

The external PHY would then be something like a Micrel KSZ9021RL (PDF) or Realtek RTL8201. The internal PHY would just be connected to magnetics and a jack.

What benefits are there to using an external PHY over an internal one if both are available? It seems like using the internal PHY saves on BOM and significantly on PCB routing.

\$\endgroup\$
  • 2
    \$\begingroup\$ The same can be asked about nearly any peripheral that can be external or integrated. Flexibility in the specs/manufacturer/layout/cost/power consumption and options. \$\endgroup\$ – Eugene Sh. Feb 15 '17 at 16:29
  • \$\begingroup\$ Especially if the functionality is achieved with a multi-die package the cost may be lower and/or you may get more flexibility by using an external PHY. The analog functionality in a PHY may not be all that well suited to integration with a modern MCU. \$\endgroup\$ – Spehro Pefhany Feb 15 '17 at 16:40
  • 1
    \$\begingroup\$ There are lots of options for a PHY: auto-MDI/MDIX, diagnostics (cable fault detection), some PHY allow support for fiber, some PHY are actually three-port ethernet switches, so you can put two RJ-45 jacks... And there are a lot of parameters that can make them more appropriate than a basic builtin PHY: clocking options, power consumption (which greatly varies from product to product, and which has become an important factor)... and, of course, cost. \$\endgroup\$ – dim Feb 15 '17 at 20:04
  • 1
    \$\begingroup\$ There are other types of PHY. It would seem unusual to use other types of 100mbps PHY, but as an example, perhaps in a big noisy factory floor, a fiber-optic PHY is required. \$\endgroup\$ – rioraxe Feb 15 '17 at 22:13
1
\$\begingroup\$

If your MCU has an ethernet PHY built in, you would normally use that. But many MCUs do not have that available. Even so, here are several reasons I can think of why you might not want to use an internal PHY.

1) Design reuse. If you have a previous design that used an external PHY (perhaps on an earlier MCU that didn't support an internal PHY), you may save on development time by using the same design and code.

2) Physical separation. You typically want to put the PHY as close as possible to the magjack. If your MCU has to be far from the jack, it may make sense to run the MII signals across the board.

3) Different physical medium: you might want to use a fiber optic PHY, either as standard or an option.

4) No PHY: For short-range communication (say between modules in a single chassis), you can even skip the PHY entirely and connect the RMII signals directly. In particular, if you are making something like a SOHO router, the on-board MCU might connect to the switch this way, avoiding going through two PHYs.

\$\endgroup\$
0
\$\begingroup\$

What benefits are there to using an external PHY over an internal one if both are available? It seems like using the internal PHY saves on BOM and significantly on PCB routing.

Look at the speeds of most GPIO's on microprocessors, there around 50Mhz or lower. Ethernet 100Mbps runs at 100Mhz, and uses differential transceivers which also adds more to cost if your not using it. So most microprocessors have the transceivers on the outside of the microprocessor.

These Media Independent Interfaces allow a slower microprocessor to use ethernet, by using a parallel interface (some use 4 parallel lines and some 8). The phy chips also handle the physical layer of the ethernet stack, like detecting if a cable has been connected.

There is no benefit of using one over the other except for cost savings, saving on pcb area and routing.

\$\endgroup\$
-1
\$\begingroup\$

Inserting comments from the commenters who should know better and post actual answers:

The same can be asked about nearly any peripheral that can be external or integrated: Flexibility in the specs, manufacturer, layout, cost, power consumption and options. - from comment by Eugene Sh.

Especially if the functionality is achieved with a multi-die package, the cost may be lower and/or you may get more flexibility by using an external PHY. The analog functionality in a PHY may not be all that well suited to integration with a modern MCU. - from comment by Spehro Pefhany

There are also lots of options for a PHY: auto-MDI/MDIX, diagnostics (cable fault detection), some PHY allow support for fiber, some PHY are actually three-port Ethernet switches, so you can put two RJ-45 jacks. And there are a lot of parameters that can make them more appropriate than a basic integrated PHY: clocking options, power consumption (which greatly varies from product to product, and which has become an important factor) and, of course, cost. - from comment by dim

\$\endgroup\$
  • \$\begingroup\$ This is not "summarizing". It is pure plagiarism. It's ok to base an answer on someone else's comment if you give them credit, but it is not ok to post an answer with zero contribution of your own. \$\endgroup\$ – Ben Voigt May 6 '17 at 2:04
  • \$\begingroup\$ @BenVoigt Fair point, added explicit references to all the comments. I disagree with your comment about zero contribution. My answer makes it possible to use this website as intended - the question can now be marked as solved. Something that is not possible as long as people answer in the comment section. \$\endgroup\$ – pipe May 6 '17 at 2:13
  • \$\begingroup\$ Make it a community wiki then \$\endgroup\$ – pericynthion May 6 '17 at 2:14
  • \$\begingroup\$ No this is weird, why would you repost the comments in the answers section? \$\endgroup\$ – laptop2d May 6 '17 at 2:20
  • \$\begingroup\$ @laptop2d Because they are great answers and deserves to be treated as such. Everything written in the post answers the question. Comments can be removed "at will", and should not be relied on to keep things here for all eternity. \$\endgroup\$ – pipe May 6 '17 at 2:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.