Functions | |
| static bool | jl1111_check_id (ENET_Type *ptr, uint32_t phy_addr) |
| bool | jl1111_reset (ENET_Type *ptr, uint32_t phy_addr) |
| Reset JL1111 PHY chip. More... | |
| void | jl1111_basic_mode_default_config (ENET_Type *ptr, jl1111_config_t *config) |
| Set default configuration for JL1111 PHY basic mode. More... | |
| bool | jl1111_basic_mode_init (ENET_Type *ptr, uint32_t phy_addr, jl1111_config_t *config) |
| Initialize JL1111 PHY chip in basic mode. More... | |
| void | jl1111_get_phy_status (ENET_Type *ptr, uint32_t phy_addr, enet_phy_status_t *status) |
| Get JL1111 PHY status. More... | |
| void | jl1111_set_itf (ENET_Type *ptr, uint32_t phy_addr, uint8_t itf) |
| Set interface mode for JL1111 PHY. More... | |
| void | jl1111_set_rmii_refclk_direction (ENET_Type *ptr, uint32_t phy_addr, uint8_t dir) |
| Set RMII reference clock direction for JL1111 PHY. More... | |
| void | jl1111_set_rmii_skew (ENET_Type *ptr, uint32_t phy_addr, uint8_t tx_skew, uint8_t rx_skew) |
| Set RMII skew timing for JL1111 PHY. More... | |
| void | jl1111_disable_broadcast_response (ENET_Type *ptr, uint32_t phy_addr) |
| Disable broadcast response for JL1111 PHY. More... | |
| void jl1111_basic_mode_default_config | ( | ENET_Type * | ptr, |
| jl1111_config_t * | config | ||
| ) |
Set default configuration for JL1111 PHY basic mode.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [out] | config | Pointer to the configuration structure to be initialized |
This function initializes the configuration structure with default values:
| bool jl1111_basic_mode_init | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr, | ||
| jl1111_config_t * | config | ||
| ) |
Initialize JL1111 PHY chip in basic mode.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| [in] | config | Pointer to the PHY configuration structure |
| true | Initialization completed successfully |
| false | Initialization failed (PHY ID check failed) |
This function performs the following operations:
|
static |
| void jl1111_disable_broadcast_response | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr | ||
| ) |
Disable broadcast response for JL1111 PHY.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
This function disables the PHY's response to broadcast frames.
| void jl1111_get_phy_status | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr, | ||
| enet_phy_status_t * | status | ||
| ) |
Get JL1111 PHY status.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| [out] | status | Pointer to the status structure to store PHY status |
This function reads the PHY status register and extracts:
| bool jl1111_reset | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr | ||
| ) |
Reset JL1111 PHY chip.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| true | Reset operation completed successfully |
| false | Reset operation failed (timeout) |
| void jl1111_set_itf | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr, | ||
| uint8_t | itf | ||
| ) |
Set interface mode for JL1111 PHY.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| [in] | itf | Interface mode: jl1111_config_interface_t |
This function configures the PHY interface mode (MII or RMII).
| void jl1111_set_rmii_refclk_direction | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr, | ||
| uint8_t | dir | ||
| ) |
Set RMII reference clock direction for JL1111 PHY.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| [in] | dir | Reference clock direction: jl1111_config_refclk_direction_t |
This function configures the RMII reference clock direction (input or output).
| void jl1111_set_rmii_skew | ( | ENET_Type * | ptr, |
| uint32_t | phy_addr, | ||
| uint8_t | tx_skew, | ||
| uint8_t | rx_skew | ||
| ) |
Set RMII skew timing for JL1111 PHY.
| [in] | ptr | Pointer to the ENET peripheral base address |
| [in] | phy_addr | PHY address |
| [in] | tx_skew | TX skew value |
| [in] | rx_skew | RX skew value |
This function configures the RMII TX and RX skew timing values for signal alignment.