SLUUDO2 September   2026 AM2611 , AM2612 , AM2612-Q1 , AM2631 , AM2631-Q1 , AM2632 , AM2632-Q1 , AM2634 , AM2634-Q1 , AM263P2 , AM263P2-Q1 , AM263P4 , AM263P4-Q1

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1Acronyms
  5. 2Introduction
  6. 3Introduction to CPSWSS and ENET-LLD
    1. 3.1 Hardware
    2. 3.2 Software
    3. 3.3 Application Software
      1. 3.3.1 Board and Peripherals Initialization (SYSCFG)
      2. 3.3.2 CPSW Configuration (ENET-LLD)
      3. 3.3.3 Operating System (FreeRTOS or NoRTOS)
      4. 3.3.4 Middleware Stack (LwIP, Arm® Mbed™ Platform TLS, TSN)
      5. 3.3.5 Application Layer
  7. 4Debugging Hardware and Software
    1. 4.1 Hardware Debugging
      1. 4.1.1 Schematic Review Checklist
        1. 4.1.1.1 Management Data Input/Output (MDIO and MDC)
        2. 4.1.1.2 RGMII Interface
      2. 4.1.2 PHY Debug
        1. 4.1.2.1 PHY Bootstrap Settings
        2. 4.1.2.2 Trace Length
        3. 4.1.2.3 Clock Configuration
        4. 4.1.2.4 Mode Settings
        5. 4.1.2.5 IO MUX and SW Switch Settings
        6. 4.1.2.6 PHY Troubleshooting Guides
        7. 4.1.2.7 Custom Pin MUX Settings
      3. 4.1.3 Test Setup
      4. 4.1.4 Software Debugging
        1. 4.1.4.1 Using GEL Scripts in CCS
          1. 4.1.4.1.1 Statistics Using GEL Scripts
          2. 4.1.4.1.2 Statistics Using Expressions
      5. 4.1.5 Debugging Custom Ethernet Software
        1. 4.1.5.1 Debugging Initialization Sequence
        2. 4.1.5.2 PHY Debugging
        3. 4.1.5.3 MAC Port Debugging
        4. 4.1.5.4 TX Path Debugging
        5. 4.1.5.5 Systematic Debugging Checklist
          1. 4.1.5.5.1 RX Path Debugging
          2. 4.1.5.5.2 Multicast or Broadcast Does Not Work, But Unicast Works
    2. 4.2 Custom Hardware Bring-Up Process
      1. 4.2.1 Example 1: CPSW PHY Loopback
        1. 4.2.1.1 Failure: PHY Not Detected or MDIO Bus Not Alive
        2. 4.2.1.2 Failure: TX Packets Transmitted But RX Count = 0
      2. 4.2.2 Example 2: CPSW MAC Loopback Example
        1. 4.2.2.1 Failure: MAC Loopback Initialization Fails
        2. 4.2.2.2 Failure: TX Packets Increase But RX = 0
        3. 4.2.2.3 Failure: Nonzero Error Counters
      3. 4.2.3 Example 3: Enet_Layer2_CPSW and Enet_Layer2_cpsw_switch
        1. 4.2.3.1 Hardware Setup
        2. 4.2.3.2 Failure: Link Never Comes UP
        3. 4.2.3.3 Failure: Link is Up But No Frames Are Received or Transmitted
        4. 4.2.3.4 Failure: RX and TX Counters Increase But Error Rates Are High
      4. 4.2.4 Example 4: Enet_lwip_cpsw_example
        1. 4.2.4.1 Failure: Link Never Comes Up
        2. 4.2.4.2 Failure: Links Up But No IP Address Is Assigned
        3. 4.2.4.3 Failure: Ping Fails Despite Link and IP Address
    3. 4.3 Debugging Packet Forwarding Issues (ALE and Statistics)
      1. 4.3.1 CPSW Statistics Architecture
        1. 4.3.1.1 What Each Block Measures
        2. 4.3.1.2 Counter Reference Tables
          1. 4.3.1.2.1 MAC Port – RX Counters
          2. 4.3.1.2.2 MAC Port – TX Counters
          3. 4.3.1.2.3 MAC Port and Host Port – ALE and FIFO Drop Counters
          4. 4.3.1.2.4 Host Port – ALE Flood and Overrun Counters
          5. 4.3.1.2.5 MAC Port RX Issues
          6. 4.3.1.2.6 MAC Port TX Issues
          7. 4.3.1.2.7 Host Port RX Issues
          8. 4.3.1.2.8 Host Port TX Issues
    4. 4.4 Custom Board Enablement in SYSCFG
    5. 4.5 LwIP Debug Guide
      1. 4.5.1 LwIP Stack Configuration
      2. 4.5.2 lwip_stats
  8. 5Conclusion
  9. 6References

Trace Length

Trace length in Ethernet PHY design refers to the physical length of the copper tracks on a PCB connecting the Ethernet PHY (physical layer) chip to the magnetic modules (transformers) and the RJ45 jack, or to the MAC (media access control) chip. The RGMII specification operates at a clock frequency of 125MHz. Since RGMII utilizes double data rate (DDR) signaling, data is sampled on both the rising and falling edges of the clock. This DDR signaling creates a narrow 4.0ns data window.

To attain clean data latching and maximum setup and hold margins, the clock signal must arrive exactly in the center of this data window (a center-aligned clock, requiring a 1.5ns to 2.0ns delay relative to the data).

Depending on the hardware architecture, this timing alignment can be achieved using one of two methods:

  1. RGMII v1.3 (physical trace delay): The transmitting device outputs clock and data signals edge-aligned (arriving at the same time). To achieve the required 1.5–2.0ns center alignment, the hardware engineer must manually add the physical trace length to the clock line on the PCB. This method is deprecated and not recommended for modern layouts.
  2. RGMII v2.0 / RGMII-ID (internal delay): The internal delay feature compensates for RGMII trace length mismatches on the PCB. RGMII uses source-synchronous clocking where the clock and data must arrive at the receiver within a tight timing window (typically ±0.5ns). When the PCB traces clock and data have different lengths, this difference introduces skew that can violate the setup and hold margins of the receiver. CPSW_CONTROL.RGMII*_ID_MODE, when set to 1, enables the internal delay mode for the transmit path of the corresponding RGMII port. This mode provides a phase shift of a quarter cycle between clock and data.

For AM26x devices, internal delay can be enabled using SYSCFG.

AM2612 AM2611 AM2634 AM2632 AM2631 AM263P4 AM263P2 AM263P4-Q1 AM263P2-Q1 AM2612-Q1 AM2634-Q1 AM2632 SYSCFG RGMII Delays Figure 4-3 SYSCFG RGMII Delays

Writing 1'b1 disables the internal clock delays, and those delays must be handled onboard.

A similar internal delay feature is also available from a PHY perspective. There are timing path operating modes. Timing paths can operate in either aligned mode or shift mode. Aligned mode introduces zero clock skew. Shift mode allows clock skew adjustments in ≅0.25ns increments through the register settings. Configure these modes using the RGMII control register (RGMIICTL) at 0x0032. If using shift mode, adjust the specific clock skew values using the RGMII delay control register (RGMIIDCTL) at address 0x0086. This entirely depends on the PHY being used. Please refer to the PHY datasheet for more details.

The ENET-LLD PHY drivers provide support for these extended configurations. Extended configurations are PHY specific configurations. For example, the dp83867 PHY supports such features. This can be utilized by configuring the extended configuration data structure.

typedef struct Dp83867_Cfg_s
 {
 /*! Enable TX clock shift */
 bool txClkShiftEn;
 /*! Enable RX clock shift */
 bool rxClkShiftEn;
 /*! TX delay value */
 uint32_t txDelayInPs;
 /*! RX delay value */
 uint32_t rxDelayInPs;
 /*! ...other fields */
 } Dp83867_Cfg;

There is provision for configuring extended configurations in SYSCFG for AM26x devices.

AM2612 AM2611 AM2634 AM2632 AM2631 AM263P4 AM263P2 AM263P4-Q1 AM263P2-Q1 AM2612-Q1 AM2634-Q1 AM2632 PHY Extended
                    Configuration Figure 4-4 PHY Extended Configuration

Users can also check the Timing Requirements section in the PHY datasheet and verify that the board design adheres to the same timing requirements.