Yes, a file full of zero bits transfers faster over USB2.0 than a file full of one bits.
I've known this forever but it still feels ridiculous when you actually test it and it's true!
USB truly is cursed.
Yes, a file full of zero bits transfers faster over USB2.0 than a file full of one bits.
I've known this forever but it still feels ridiculous when you actually test it and it's true!
USB truly is cursed.
@lina Few people know it but the reason for this is very simple. While zeroes are round, a 1 has a sharp corner and a hook that could get stuck and damage the insulation around the copper if you would completely fill the line with ones. Instead, sending some zeroes every now and then to flush any stuck „1“ before a clog can develop.
A 0 can be neatly pushed through the copper at high pressure without damaging the cable.
Now you know!
@kaustcvantas @lina @uint8_t@chaos.social
I think people tend to forget that ironic shitposting is still shitposting.
@Qbitzerre @uint8_t @lina Usual line coding is NRZ, which encodes bits in levels. 1 high 0 low, simple.
But USB is NRZI-S, it encodes bits in level *changes* : https://en.wikipedia.org/wiki/Non-return-to-zero#Non-return-to-zero_inverted
This means a zero is encoded by a level change and a one is encoded by no change. You need bit suffing because USB does not transmit the associated clock, and with no transition in long strings of ones, the receiver would loose sync.