ETHERNET TESTING INSIGHTS

How to test Auto-Negotiation (AN) & Link Training (LT) in high-speed Ethernet?

Why are Auto‑Negotiation (AN) and Link Training (LT) critical for high-speed Ethernet?

Auto-Negotiation (AN) and Link Training (LT) are critical processes that enable modern high-speed Ethernet links – especially at 112G PAM4 and beyond – to achieve reliable, high-performance operation. AN ensures that connected devices agree on common parameters like speed and Forward Error Correction (FEC), while LT dynamically optimizes transmitter equalization to minimize bit errors across impaired electrical channels.

This article explains how to validate both protocol compliance and real-world performance of AN/LT implementations using advanced Ethernet traffic generators. It covers the key challenges developers face – such as interoperability issues, inconsistent training behavior, and difficult root-cause analysis – and provides practical guidance on structured test methods, including automated and interactive testing workflows.

You’ll learn:

  • What AN and LT do—and why they are essential for 100G, 400G, and 800G Ethernet
  • Which scenarios to test to ensure robustness, consistency, and interoperability
  • How to run AN-only, combined AN+LT, and step-by-step interactive link training tests
  • How to analyze training behavior, equalizer settings, and BER performance

By following these approaches, network equipment vendors and silicon developers can verify compliance, debug interoperability issues, and optimize link performance in next-generation Ethernet environments.

Figure 1: Xena B2400 chassis with Z800 Freya traffic generators

What is the XOA ANLT Utility and how do you use it for AN/LT testing?

Z800 Freya 112G SerDes TGA with ANLT license

The Z800 Freya test modules can generate and analyze stateless Ethernet at 50G PAM4 / 100G PAM4 / 200G PAM4 / 400G PAM4 / 800G PAM4 using 112Gbps SerDes or 56Gbps SerDes based Ethernet. This includes normal (automatic) testing of AN and LT.

An extended license is also available that enables interactive testing of the AN and LT protocols via the XOA ANLT Utility.

XOA ANLT Utility

Purchased separately, the Xena OpenAutomation (XOA) ANLT Utility is a Command Line Interface (CLI) shell application used to configure and run AN/LT test sequences from a client PC on Xena Z800 Freya test modules. Compared to the XenaManager GUI application, the XOA ANLT Utility enables more advanced control and test features of AN/LT. It is purchased desperately

The XOA Utility package is open source and can be downloaded and installed from github here: https://github.com/XenaNetworks. The XOA ANLT Utility works under Windows, Linux and MacOS. Xena also offers other XOA REST APIs for running L2 and L3 test sequences like RFC-2544 as shown on Figure 2.

You can connect to a Xena tester by opening a TCP/IP connection on your PC to the Xena chassis using TCP port 22611.

The XOA Utility builds on the XOA HL-FUNC (High-level functions) which groups several XOA PYTHON API calls into common functions for ease of use.

The XOA PYTHON API can also be used directly in case you want to write your own Python scripts.

The command structure of the XOA Utility looks like the following:

< command > [ < subcommand > ] [ < arguments > ] [ < options > ]

In the following chapters we will describe how to use a few of these commands to perform common AN/LT test cases. A full list of the XOA Utility commands can be found in the Reference Manual built into the software.

How to test ANLT

Figure 2: Structure of the Xena OpenAutomation packages.

Figure 3: General procedure for any test of ANLT requires these steps 

How does the Auto‑Negotiation (AN) protocol work in Ethernet?

The main purpose of Auto Negotiation (AN) is for two connected devices at the end-points of a link to communicate together and agree on a common set of transmission parameters. AN is standardized in IEEE802.3 Clause 73.

For multi lane connections AN is done on lane 0 only and the remaining lanes have their SerDes disabled during AN.

The AN protocol uses 48 bits long Link Code Words (LCWs) for communication and a low bit rate of 156.25 Mbps. The LCW are also called DME pages and the standard defines both a Base Page as well as Next Pages.

During the AN Process each link partner continuously sends the same DME page until the remote link partner has acknowledged the correct receipt of the DME page. If at least one link partner has Next Pages, they exchange those in the same manner until there are no more Next Pages to send.

The two link partners will compare their technology abilities (like transmission speed) and choose the highest common denominator based on a priority resolution table as defined in 802.3.

As part of the AN process a number of time-outs are defined to avoid the two link partners sending DME pages endlessly.

How does the Link Training (LT) protocol optimize Ethernet link performance?

Link Training (LT) is a process defined in IEEE802.3 for Ethernet over electrical cables whereby two end points communicate together to tune the settings of their respective transmitter equalizers for optimum transmission.

During LT, it is the weights of the coefficients (for instance c(-3), c(-2), c(-1), c(0) and c(1)) of the transmitter equalizer at each link partner that are being adjusted. In contrast to AN, the LT protocol operates at the actual speed on the cable.

The standard also defines several preset Tx equalizer settings which can be used to establish a well-defined basis for LT.

The link partners use Training Frames to communicate during LT. A training frame consists of control information as well as training data. The control words exchange information about equalizer settings and the training pattern is used to test the performance of a given equalizer setting. The performance is evaluated by the Bit Error Rate (BER).

The Training Frames are sent independently on all lanes of multilane connections.

What should you test when validating AN/LT protocols and performance?

The key purposes of testing the AN and LT protocols are:

  • Ensure compatibility with 3rd party vendors
  • Test resilience against corner case scenarios
  • Test of consistency
  • Prove compliance

Using XenaManager, the Z800 Freya traffic generators can be configured to run the protocols in the following 4 modes:

  • AN/LT disabled: The tester will not run AN and LT
  • AN only: runs the AN protocol only
  • AN and LT in automatic mode: Runs AN followed by LT in automatic (normal) mode
  • AN and LT in interactive mode: Runs the AN followed by LT interactive mode that lets you step through the LT protocol one command at a time and analyze the responses per command (requires additional XOA ANLT Utility License)

The general procedure for any test of ANLT requires the steps displayed on Figure 3.

App Note ANLT test setup

Figure 4: Test set up

What are typical test cases for AN/LT validation?

In this section we provide examples of how the XOA utility can be used to define and runs various useful tests of the AN/LT protocols.

How do you set up a test environment for AN/LT testing?

The test set-up used for all test examples is shown on Figure 4. It includes a Z800 Freya traffic generator (shown here installed in a Compact chassis) – with a XOA ANLT Utility license – connected via TCP to a laptop running the XOA application. One of the ports on the Z800 Freya is connected via an electrical cable to one of the ports on the Device Under Test (DUT).

The following steps will set up the port on the tester for the subsequent tests.

1.     Connect to a tester

First, you need to connect to your tester using the command connect and the IP address xx.xx.xx.xx of the tester.

If you don’t know which ports you will use at the time of connecting to the port, just leave the option –ports empty as the example shows below. You can reserve ports later.

xoa_util$ connect xx.xx.xx.xx xoa_anlt

2.     Reserve a port

Then, reserve a port on the tester using the command port, as shown in the example below.

xoa_util$ port 0/0 –reset –force

3.     Disable link recovery

Before doing ANLT testing, remember to disable link recovery on the port using command recovery.

This is because the port always tries to re-do ANLT command sequence every five seconds if it detects no sync on the port.

This will disturb your manual link training procedure if you do not disable it prior to your interactive test.

xoa_util[port 0/0]$ recovery  –off

How do you test Auto‑Negotiation (AN) independently of Link Training?

This example tests if the DUT can complete the AN process on the link (no-loopback) with-out starting LT and lets you analyze the log afterwards. The steps in the test are the following

1.     Reset port

Reset the port with the command port  –reset to ensure you are starting from a well-defined state of the port.

xoa_util[port0/0]$ port 0/0 –reset

2.     Configure ANLT

Both ANLT and LT need to be configured using the commands an config and lt config

xoa_util[port0/0]$ an config –on –no-loopback

xoa_util[port0/0]$ lt config –off

3.     Write the log

To display the log of the AN process on the screen and write it into the file use the command an log

xoa_util[port0/0]$ an log ”anlog1.txt”

4.     Run ANLT

The configured test sequence is started with the command do anlt

xoa_util[port0/0]$ do anlt

5.     Check status of AN

The status of the AN run can be checked with the command an status

xoa_util[port0/0]$ an status

How do you test AN followed by LT in automatic mode?

This example tests if the DUT can complete the AN and LT process automatically and lets you analyze the log afterwards. The steps in the test are:

1.     Reset port

Reset the port with the command port  –reset to ensure you are starting from a well-defined state of the port.

xoa_util[port0/0]$ port 0/0 –reset

2.     Configure ANLT

Configured AN and LT using the commands an config and lt config

xoa_util[port0/0]$ an config –on –no-loopback

xoa_util[port0/0]$ lt config –on –mode=automatic

3.     Write the logs to file

To display the log of the AN process on the screen and write it into the file “log1.txt” use the command an log

xoa_util[port0/0]$ an_log ”log1.txt”

To display the log of the LT process for lane 0 on the screen and write it into the file “ltlog0.txt” use the command lt log

xoa_util[port0/0]$ lt log 0 ”ltlog0.txt”

4.     Run ANLT

The configured test sequence is started with the command do anlt

xoa_util[port0/0]$ do anlt

5.     Check status of AN and LT

The status of the AN run can be checked with the command an status

xoa_util[port0/0]$ an status

The status of the LT run can be checked with the command lt status

xoa_util[port0/0]$ lt status

How do you verify consistency in the Link Training protocol?

To test the consistency of the LT protocol the AN and LT in automatic mode should be repeated several times starting from the same initial setting of Tx equalizers. If the equalizers on all lanes complete with identical settings for the taps, the protocol has been verified to be consistent.

How do you test Link Training in interactive mode?

This example shows how to enable interactive mode for LT and send a few interactive commands to the DUT:

  • Ask remote port to use a specific preset
  • Ask remote port to change one of it’s taps
  • Ask remote port to use a specific coding in the training pattern
  • Tell the remote port that a specific lane has been trained

This example tests if the DUT can complete the AN and LT process automatically and lets you analyze the log afterwards. The steps in the test are the following

1.     Reset port

Reset the port with the command port  –reset to ensure you are starting from a well-defined state of the port.

xoa_util[port0/0]$ port 0/0 –reset

2.     Configure ANLT

Configured AN and LT using the commands an config and lt config

xoa_util[port0/0]$ an config –off

xoa_util[port0/0]$ lt config –on –mode=interactive

3.     Write the logs to file

To display the log of the LT process for lane 0 on the screen and write it into the file use the command lt log

xoa_util[port0/0]$ lt log 0 ”ltlog0.txt”

4.     Run ANLT

The configured test sequence is started with the command do anlt

xoa_util[port0/0]$ do anlt

The tester is now in interactive LT mode and waiting for you to enter a command.

5.     Ask remote port to use a specific preset on a specific lane

The command lt preset instructs the DUT to use a specific preset on the Tx equalizer on a specific lane. The following command sets preset to preset1 on lane 0.

xoa_util[port0/0]$ 0 1

6.     Ask remote port to increment a specific tap on a specific lane

The command lt inc instructs the DUT to increment a specific tap (emphasis) on the Tx equalizer on a specific lane. Increments can only be done by 1 step at a time. The following command increments c(0) (main) on lane 0.

xoa_util[port0/0]$ lt inc 0 main

7.     Ask remote port to us a specific coding in the training pattern on a specific lane

The command lt encoding instructs the DUT to use a specific encoding in the training pattern on the Tx equalizer on a specific lane. The following set the encoding the PAM4 with precoding on lane 0.

xoa_util[port0/0]$ lt encoding 0 pam4pre

8.     Tell the remote port that a specific lane has been trained

The following tells that LT has completed on lane 0.

xoa_util[port0/0]$ lt trained 0

Where can you find tools, documentation, and resources for AN/LT testing?

Try Our Live Demo

You can try the Xena platform – right now! – using a PC (running min. Windows XP) and our Live Demo system. Click here to start.

Learn More on Our Website

Visit these pages on our website to learn more about the products mentioned in this Application Note:

Pricing Information

For pricing details, please contact [email protected]

Book a Discovery Call

Set up a quick call with a Xena tech expert to see if the Xena Ethernet Test Platform is the right solution for your needs: https://xenanetworks.com/discovery-call-booking/