Skip to content

About

macOS app that tests USB-C cables: reads the e-marker chip, charger PD offer, live watts, and data link speed

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

Cable Tester icon

Cable Tester

Plug a USB‑C cable into your Mac and find out how much power and data it can really carry.

Cable Tester showing a cable's e-marker readout

What it does

Shopping for a 100 W cable? Plug it in between your Mac and a charger (or a drive) and Cable Tester tells you, with evidence:

  • The cable's own ratings. Every USB‑C cable rated above 3 A, and every fast-data C‑to‑C cable, contains an e‑marker chip. macOS reads it over the CC wire; Cable Tester decodes it — max current (3 A / 5 A), max voltage, EPR (240 W) support, data speed class, active/passive, and estimated length.
  • What the charger offers through it. USB Power Delivery chargers only advertise more than 3 A after detecting a 5 A cable, so a 100 W charger that only offers 3 A is being held back by the cable. Every advertised power profile (Fixed, PPS, AVS, EPR) is shown, with the one in use highlighted.
  • What actually flows. Live input watts, volts and amps, read from the SMC once per second.
  • Power stress test. Spins up every CPU core and the GPU so the Mac draws as much as it can (90 W+ on an M1 Pro). A reading above ~62 W physically proves the cable carries more than 3 A.
  • Data link + drive speed test. The negotiated USB / Thunderbolt link speed of whatever's on the other end, plus an uncached sequential read/write benchmark.
  • Cable library. Name and save each cable you test so you can compare them later.

Pick your target (60 / 100 / 140 / 240 W) in the toolbar and every port gets a pass / fail / can't-tell-yet verdict, with a "why we think so" list ranking each piece of evidence.

Limits worth knowing

  • Something must be on the far end of the cable — USB‑C ports stay electrically off until a device is attached.
  • When the Mac is being charged, the charger (not the Mac) usually reads the e‑marker. For a definitive chip readout, connect the cable between the Mac and a USB‑C drive or hub.
  • MacBooks accept roughly 100 W max over USB‑C, so 140 W / 240 W cables can only be confirmed via the e‑marker and the charger's EPR offer, not by measurement.
  • Data speed is capped by the slowest of cable, device and port.
  • The e‑marker is the manufacturer's claim. A measured reading above ~62 W is physical proof; the chip alone is not.

Requirements

  • macOS 27.2 or later, Apple silicon Mac
  • Xcode 27.3+ to build

Building

The Xcode project is generated from project.yml with XcodeGen (the generated project is committed too):

xcodegen generate
xcodebuild -scheme USBcTester -configuration Release -derivedDataPath build/DerivedData build
open "build/DerivedData/Build/Products/Release/Cable Tester.app"

Run the tests with:

xcodebuild -scheme USBcTester -derivedDataPath build/DerivedData test

The app is not sandboxed: it reads the IOKit registry (port controllers, PD state, e‑marker VDOs), the SMC (live power) and runs system_profiler for Thunderbolt link info. It never writes anything except the temporary benchmark file, which is deleted afterwards.

How it works

Source What it provides
AppleHPMDevice → AppleTCControllerType10 → IOPortTransportStateCC → SOP' Cable e‑marker Discover Identity VDOs
AppleSmartBattery → PortControllerInfo Per-port source PDOs, active RDO, max power
AppleSmartBattery → AdapterDetails Charger name, rated watts, contract
SMC keys PDTR, VD0R, ID0R Live DC input power, voltage, current
IOUSBHostDevice → UsbLinkSpeed Negotiated USB link speed
system_profiler SPThunderboltDataType Thunderbolt / USB4 link speed

PDO, RDO and cable VDO decoding follows the USB Power Delivery 3.2 spec — see Sources/Model/USBPD.swift.

License

MIT

About

macOS app that tests USB-C cables: reads the e-marker chip, charger PD offer, live watts, and data link speed

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages