mimxrt/network: Rename the argument clock_mode to ref_clk_mode.

The definitions for LAN.IN and LAN.OUT are kept, but in the code Pin.IN
and Pin.OUT can be used as well as values for the ref_clk_mode argument.
This commit is contained in:
robert-hh
2022-11-15 15:55:27 +01:00
parent 2a4825848c
commit 3459a4fa3d
2 changed files with 11 additions and 9 deletions

View File

@@ -19,7 +19,7 @@ Example usage::
Constructors
------------
.. class:: LAN(id, *, phy_type=<board_default>, phy_addr=<board_default>, phy_clock=<board_default>)
.. class:: LAN(id, *, phy_type=<board_default>, phy_addr=<board_default>, ref_clk_mode=<board_default>)
Create a LAN driver object, initialise the LAN module using the given
PHY driver name, and return the LAN object.
@@ -31,13 +31,15 @@ Constructors
is the default. Suitable values are port specific.
- *phy_addr* specifies the address of the PHY interface. As with *phy_type*, the hardwired value has
to be used for most boards and that value is the default.
- *phy_clock* specifies, whether the data clock is provided by the Ethernet controller or the PYH interface.
The default value is the one that matches the board. If set to ``True``, the clock is driven by the
Ethernet controller, otherwise by the PHY interface.
- *ref_clk_mode* specifies, whether the data clock is provided by the Ethernet controller or
the PYH interface.
The default value is the one that matches the board. If set to ``LAN.OUT`` or ``Pin.OUT``
or ``True``, the clock is driven by the Ethernet controller, if set to ``LAN.IN``
or ``Pin.IN`` or ``False``, the clock is driven by the PHY interface.
For example, with the Seeed Arch Mix board you can use::
nic = LAN(0, phy_type=LAN.PHY_LAN8720, phy_addr=2, phy_clock=False)
nic = LAN(0, phy_type=LAN.PHY_LAN8720, phy_addr=1, ref_clk_mode=Pin.IN)
Methods
-------