Tool for VCT (Virtual Cable Test) for QCA switches and others wanted

Many devices containing switches have a cable test function available in the UI of the stock firmware, that leverages VCT functions available in e.g. the AR9331, QCA8337, and other chips.

I tried searching for tool, that I could use on Openwrt to (automatically?) measure cable lengths for all devices/individual_ports, but wasn't successful. Or is this built in, and some SNMP MIB makes this info available, if enabled somewhere?

Does somebody know a way? Or could I cobble (easily?) something together using some command-line MDIO-Write/Read tool?

1 Like

You may be interested in this link[1]. Ethtool has cable-test options. This requires support from the PHY driver :slight_smile:


Yes, ethtool has these options --cable-test & --cable-test-tdr, but I haven't found a device yet, where it works. I usually get something like:

netlink error: PHY driver does not support cable testing
netlink error: Operation not supported

Digging a bit, it seems to be implemented for (some? DSA?) Marvell drivers, and in the rpi4 ( since commit

Testing on Openwrt complains about missing netlink support in ethtool, which doesn't seem to be an explicit option in the build system, but may be included in ethtool-full. I'll try that later today.