1

How does such adapter work?

enter image description here

I am using this kind of adapter right now.

It came with a cd with an installable driver.

On windows XP I had to install the driver in order for it to work.

On Linux Mint 19 x64 it did not need the driver, it worked instantly.

New contributor
DonJoe is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

closed as too broad by music2myear, Ramhound, jonsca, fixer1234, Mureinik May 16 at 6:45

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • The same way any other plug and play hardware works. If the OS has a driver readily available, it will use it right away. If the OS doesn't have the driver already stored, you have to get the correct driver to the OS in order for the OS to be able to recognize and use the hardware. – music2myear May 15 at 18:57
  • It works like any other USB device. It identifies itself as a device, in this case, a network adapter and that adapter requires a driver in order to function on Windows. It worked on Linux without a driver since the generic driver was enough. This wasn't the case on Windows XP, which is dangerous to be used if you are connecting it to the internet. – Ramhound May 15 at 18:58
  • Could you explain / show link which explains how the driver "tells" the computer that the adapter is like the actual device? – DonJoe May 15 at 18:59
  • @Ramhound Don't worry about XP. I used it 8 years ago. Just now this question came up to my mind :D – DonJoe May 15 at 19:00
  • @DonJoe: What "actual device"? The adapter is the actual device. – grawity May 15 at 19:00
1

How does such adapter work?

It is an active adapter – it contains a single "USB to Ethernet" chip which acts as a standard USB device on one end, and as a standard Ethernet controller on the other end; it receives Ethernet frames and sends them over USB in a format that the driver will understand, and vice versa. For example, ASIX AX88179 is a popular controller which works well with Linux. Realtek RTL8153 is another one.

Could you explain / show link which explains how the driver "tells" the computer that the adapter is like the actual device? […] How does the driver tell the OS to interpret the data over USB as data over Ethernet

The adapter by itself is the "actual device". It does not emulate anything; the way it works isn't actually different from "normal" PCI Ethernet adapters. Those, too, have an Ethernet controller chip that receives frames over the wire and sends them over PCI to the driver. The OS never gets any "direct" access to the Ethernet cabling.

In both cases, whether it's PCI-Ethernet or USB-Ethernet, it's the adapter's job to send/receive the actual frames, and it's driver's job to tell the OS that it will be providing a "network interface" (e.g. using register_netdev() on Linux) and to convert PCI/USB data to a format understood by the OS.

On windows XP I had to install the driver in order for it to work.

On Linux Mint 19 x64 it did not need the driver, it worked instantly.

The difference between Windows XP and Mint 19 is approximately 17 years. It is quite reasonable to expect that a new OS will automatically support more hardware than a 17-year-old OS.

However, the main difference is that Linux comes with drivers for most hardware that it supports, while Windows has to install most of them as separate packages (either from CD or from Windows Update, but the latter no longer exists for WinXP). For example, Linux has built-in drivers for several ASIX and Realtek "USB Ethernet" chips.

Also, there are a few standard protocols for Ethernet over USB – e.g. CDC-ECM/EEM, which is a standard USB specification, or RNDIS, which has been popularized by Microsoft and is also commonly used for Android USB tethering. It is quite possible that the chip inside your adapter talks one of these standard protocols which Linux already supports without a model-specific driver.

Not the answer you're looking for? Browse other questions tagged or ask your own question.