Live data from Hacker News

A macOS terminal command that tells you if your USB-C cable is bad

kau.sh

131–140 of 197 posts

Re: A macOS terminal command that tells you if your USB-C cable is bad

#131

Earlier quoted context omitted.

The audio community love this sort of thing and will pay top dollar for unidirectional cables. Reproducible data proving the claims could be worth millions.

well, if you listen to audio you would not want the audio to accidentally get confused and head back to where it came from halfway down the cable right?

[deleted]

Re: A macOS terminal command that tells you if your USB-C cable is bad

#133
post #78
post #14

Earlier quoted context omitted.

Wait what. I thought half the point of usb c was to not rely on orientation. Is there any way to check this other than experiment? My "solution" so far has been to not buy cheap cables and just hope I get quality in return.

I believe USB C cables actually do have an orientation - it's just that the negotiation both ends do usually makes that orientation irrelevant. Maybe the negotiation can fail & the plugged in orientation is then the only one that works?

USB-C only has an "intrinsic" orientation because we call one set of pins "1" and the other "2". Electrically there should be no difference.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#134

Vibe coding. Producing code without considering how we should approach the problem. Without thinking where exactly is the problem. This is like Electron, all over again. Of course I don't have any problems with the author writing the tool, because everyone should write what the heck they want and how they want it. But seeing it gets popular tells me that people have no idea what's going on.

And why should they care what's going on ? Do you care about your binary code inside your application, or what exactly happen, in silicon level, when you write "printf("Hello World")" ?

Yes.

I verify dynamic linking, ensure no superfluous dylibs are required. I verify ABI requirements and ensure a specific version of glibc is needed to run the executable. I double-check if the functions I care about are inlined. I consider if I use stable public or unstable private API.

But I don't mean that the author doesn't know what's going on in his snippet of code. I'm sure he knows what's going on there.

I mean that upvoters have no idea what's going on, by boosting vibe coding. People who upvote this are the reason of global software quality decline in near future.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#135
post #5

It's more complicated than "this cable is good/bad". I had a suspicion about one of my cables for months, but just last week I confirmed it with a device that shows the volts/amps/watts/total kwh passing through it: I have a USB-C cable with orientation. Plugged in one way it transfers about 5x more power than the other way, and in the lower orientation it's low enough for the earbud case I use it with to not charge.

Thats so weird, did you wind up coloring one end or something? I still wish we would add color to USB C wires like USB 3 has to emphasize features and expected uses. USB C was a much needed change from USB3 and 2 in terms of being reversible and superior but every manufacturer implements the cables differently and its confusing and hard to figure out which cable is best for what.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#136
post #81
post #35

Earlier quoted context omitted.

My guess would be they used a one-sided pcb to connect the cable to and used half the wires. Some sockets internally link the power and ground pins, so it works both ways, but you get no resistor network and thus only standard 5v which gives you 500ma max (at best). With the resistors connected by the cable it's about 900ma to 3a which is probably what happens plugged in "correctly". Or some other magic happens on on…

Shouldn't a compliant USB-C DFP not supply Vbus without the resistor network, though, so there should be no charging at all? (Not that all DFPs necessarily do the correct thing, of course.)

Correct, which is probably why it won't even charge their earbuds in the broken orientation.

Re: A macOS terminal command that tells you if your USB-C cable is bad

#137
post #58

Why does it mention USB 3.2 (i.e. 20 Gbps) at all if it's for Macs? I thought Macs only support 10 Gbps and 40 Gbps, but nothing inbetween? (which is inconvenient because USB 3.2 Gen 2x2 20 Gbps external SSD cases are much cheaper than USB 4 cases for now). Also, he is calling a binary a script, which i find suspicious. This task looks like it should have been a script.

One of my pet peeves is when people call a binary a script

Re: A macOS terminal command that tells you if your USB-C cable is bad

#138

Earlier quoted context omitted.

is it worth it for everything? if you need a bash script that takes some input and produces some output. Does it matter if it's from an AI? It has to get through code review, the person who made it has to read through it before code review so they don't look like an ass.

yeah recently I needed a script to ingest individual json files into an sqlite db. I could have spent half the day writing, or asked an AI to write it and spend 10 minutes checking the data in the DB is correct. There are plenty of non critical aspects that can be drastically accelerated, but also plenty of places where I know I don't want to use today's models to do the work.

I worked with contractor for a contractor who had AI write a script to update a repository (essentially doing a git pull). But for some strange reason it was using the GitHub API instead of git. The best part is if the token wasn't set up properly it overwrote every file (including itself) with 404s.

Ingesting json files into sqlite should only take half a day if you're doing it in C or Fortran for some reason (maybe there is a good reason). In a high level language or shouldn't take much more than 10 minutes in most cases, I would think?

Re: A macOS terminal command that tells you if your USB-C cable is bad

#139
post #5

It's more complicated than "this cable is good/bad". I had a suspicion about one of my cables for months, but just last week I confirmed it with a device that shows the volts/amps/watts/total kwh passing through it: I have a USB-C cable with orientation. Plugged in one way it transfers about 5x more power than the other way, and in the lower orientation it's low enough for the earbud case I use it with to not charge.

The audio community love this sort of thing and will pay top dollar for unidirectional cables. Reproducible data proving the claims could be worth millions.

“This cut signal reflections, yielding brighter high hats without the brassiness of two-directional cabling. Bass was particularly clear and rumbly without the muddiness we heard from Monoprice cords.”
Post reply on HN