Author Topic: Connecting two computers with USB (USB - USB)  (Read 10970 times)

0 Members and 1 Guest are viewing this topic.

Offline mtbolhaTopic starter

  • Contributor
  • Posts: 22
Connecting two computers with USB (USB - USB)
« on: October 17, 2013, 08:45:04 pm »
Hi,

I have tryed to connect my laptop with my desktop computer by using old usb cables that I have cut and soldered togeather, so that both ends are the same and fit into classic 2.0. USB port, but nothing happens when I connect it.

First time i have soldered the USB cables like this:     +     Data+     Data-      -
after that I have chagled the polarity in data connection:    +       Data-     Data+     -

Nothing happens as I did not even pluged in the cables

I have seen that you can buy allready made cables, that include a chipset in the middle that controles the cable. But what can this chipset do more smarter then some program or driver on both PC cannot do? I'm supprised that this does not work. Or does it work and I'm doing something wrong?
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #1 on: October 17, 2013, 08:58:25 pm »
 :palm: :palm: :palm:
 

Offline r3l3u

  • Newbie
  • Posts: 7
  • Country: ro
  • I don't believe in anything but i count everything
Re: Connecting two computers with USB (USB - USB)
« Reply #2 on: October 17, 2013, 09:00:50 pm »
come on ! are you serious with this ?  :palm:
 

Offline MinK

  • Contributor
  • Posts: 12
Re: Connecting two computers with USB (USB - USB)
« Reply #3 on: October 17, 2013, 09:01:07 pm »
In general it is bad idea to connect two switching power supplys. In your case USB +5 V to other USB +5 V.
« Last Edit: October 17, 2013, 09:04:50 pm by MinK »
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 17815
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Connecting two computers with USB (USB - USB)
« Reply #4 on: October 17, 2013, 09:02:59 pm »
The usb protocol is based on a host/client system. you will find that any device that does both has two separate ports (like a printer). I did here of a new type of protocol for the ports that allows two hosts (computers) to talk but as of yet (10ish years later) nothing has emerged as a standard. You can't do it the way you are trying unless you can rewrite the protocol and/or driver for the usb chip. So the solution was those cables that adapt the signals so that the two can talk.
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #5 on: October 17, 2013, 09:08:12 pm »
I have lost my laptop power supply so I've just cut a cable from the lamp in half, shoved the bare wires into the laptop and it's gone PUFF, smoke, sparks and all. I noticed that there was something inside the original power supply but come on, what could it do anyway? I'm sure the laptop should be smart enough to deal with that, furthermore I've just installed new Windows 8.1 on it today. I have no idea, how this could go wrong?
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #6 on: October 17, 2013, 09:11:30 pm »
The usb protocol is based on a host/client system. you will find that any device that does both has two separate ports (like a printer). I did here of a new type of protocol for the ports that allows two hosts (computers) to talk but as of yet (10ish years later) nothing has emerged as a standard. You can't do it the way you are trying unless you can rewrite the protocol and/or driver for the usb chip. So the solution was those cables that adapt the signals so that the two can talk.

I think the standard you're talking about is USB OTG (On-The-Go). It's already in the wild since some time, that's how many smartphones can act as USB hosts using just an adapter.
 

Offline DavidDLC

  • Frequent Contributor
  • **
  • Posts: 755
  • Country: us
Re: Connecting two computers with USB (USB - USB)
« Reply #7 on: October 17, 2013, 09:14:21 pm »
There are special cables to connect two computers through USB.

Just google how to connect two computers through USB.

David.
 

Offline Simon

  • Global Moderator
  • *****
  • Posts: 17815
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Connecting two computers with USB (USB - USB)
« Reply #8 on: October 17, 2013, 09:16:29 pm »
The usb protocol is based on a host/client system. you will find that any device that does both has two separate ports (like a printer). I did here of a new type of protocol for the ports that allows two hosts (computers) to talk but as of yet (10ish years later) nothing has emerged as a standard. You can't do it the way you are trying unless you can rewrite the protocol and/or driver for the usb chip. So the solution was those cables that adapt the signals so that the two can talk.

I think the standard you're talking about is USB OTG (On-The-Go). It's already in the wild since some time, that's how many smartphones can act as USB hosts using just an adapter.

Yep that is the one.
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #9 on: October 17, 2013, 09:23:34 pm »
Yep that is the one.

Well, it's here and it's real, then. That's how you can connect a USB mouse or flash drive to the Android tablet, among other things. It's fully specified and it uses some nice tricks to detect when to begin to source power.

But back to the point, mtbolha: splicing and soldering random things together is not the way to go. There's a very good reason this cable didn't fit two computers at once originally as there is an equally valid reason that the PC-to-PC USB transfer cable has some circuitry inside. Generally, it makes one computer a "master" (USB host) and the other one a "slave" (USB device). Scratch that, I feel I'm confusing things further and this is not the proper explanation as both PCs are USB hosts technically. Enough to say there's some relatively advanced trickery going on the protocol (not bare wire) level and possibly some supporting software on the OS level as well (unless one PC presents to the other as a Mass Storage Class device).
« Last Edit: October 17, 2013, 09:34:17 pm by Zbig »
 

Offline hans

  • Super Contributor
  • ***
  • Posts: 1638
  • Country: nl
Re: Connecting two computers with USB (USB - USB)
« Reply #10 on: October 17, 2013, 09:36:42 pm »
First of all, Data pins are bidirectional so there is no need to change to + and - pins. You just made a '0' an 1 and an 1 a '0'.

In USB there always is a master and a slave. The master is for example a PC. The slave is your mouse, USB stick, etc. The master initiates everything, the slave just has to implement the right messages and let the PC know what it's capabilities are.

Moreover, the slave has a pull-up resistor on one of the data pins to let the PC know it has been attached. Depending on the USB speed, this is on DATA+ or DATA-. Without this pull-up, nothing happens as the master isn't notified a device has been attached.

However if you would add this pull-up then both PC's see a device being attached simultaneously. They don't know how to talk the USB OTG as of today (don't think they will implement this anytime soon , neither). So.. this still wouldn't work because one PC isn't going to play master, and the other is going to play as a slave.

If you want 2 computers directly talking to each other, use ethernet crosscable... or your normal network.
« Last Edit: October 17, 2013, 09:38:35 pm by hans »
 

Offline mariush

  • Super Contributor
  • ***
  • Posts: 5024
  • Country: ro
  • .
Re: Connecting two computers with USB (USB - USB)
« Reply #11 on: October 17, 2013, 09:44:15 pm »
There are USB cables that can connect two computers together, but those are not PLAIN usb cables.   

Inside them there's a chip or a couple of chips that work like network cards ... each end of the cable simulates a network card connected to the computer through the USB cable  and both network cards are connected together as if there was a crossover cable between them.

If you just connect two usb cables together, in the first place you're just going to get 5v from both computers "fighting" on the cable ... if one PC outputs 5.1v on the usb jack, and the other PC outputs 4.9v do you think the computers are gonna like what happens?

Just imagine two of these connected together with a virtual network cable (which is directly on the pcb instead of having connectors : http://www.ebay.co.uk/bhp/usb-to-ethernet-adapter
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #12 on: October 17, 2013, 09:49:45 pm »
First of all, Data pins are bidirectional so there is no need to change to + and - pins. You just made a '0' an 1 and an 1 a '0'.

First off all, not really ;) USB uses differential signalling and Data+ and Data- form a differential pair. It's not like "+" is 1 and "-" is 0 or something.

Moreover, the slave has a pull-up resistor on one of the data pins to let the PC know it has been attached. Depending on the USB speed, this is on DATA+ or DATA-. Without this pull-up, nothing happens as the master isn't notified a device has been attached.

I think it's not good to confuse OP with pullup transistors resistors (geez, I think I'll just shut up now and go to sleep), etc. This could only lead him to false assumptions that all he needs now is just some resistor or two. I think at this stage it's enough to say there are multiple abstraction layers in USB implementation and USB in general is infinitely more complex than your garden variety serial interface.
« Last Edit: October 17, 2013, 10:01:39 pm by Zbig »
 

Offline Zbig

  • Frequent Contributor
  • **
  • Posts: 927
  • Country: pl
Re: Connecting two computers with USB (USB - USB)
« Reply #13 on: October 17, 2013, 09:53:14 pm »
There are USB cables that can connect two computers together, but those are not PLAIN usb cables.   

Inside them there's a chip or a couple of chips that work like network cards ... each end of the cable simulates a network card connected to the computer through the USB cable  and both network cards are connected together as if there was a crossover cable between them.

A-ha, so that's how they solved it software-wise. Dzieki ;)
 

Offline hans

  • Super Contributor
  • ***
  • Posts: 1638
  • Country: nl
Re: Connecting two computers with USB (USB - USB)
« Reply #14 on: October 17, 2013, 10:07:42 pm »
First of all, Data pins are bidirectional so there is no need to change to + and - pins. You just made a '0' an 1 and an 1 a '0'.

First off all, not really ;) USB uses differential signaling and Data+ and Data- form a differential pair. It's not like "+" is 1 and "-" is 0 or something.
The differential voltage on the USB pair is applied wrong way around, in which I make the assumption the digital bits are inverted as well.
At any way, it's not intended to be connected this way.

Quote
Moreover, the slave has a pull-up resistor on one of the data pins to let the PC know it has been attached. Depending on the USB speed, this is on DATA+ or DATA-. Without this pull-up, nothing happens as the master isn't notified a device has been attached.

I think it's not good to confuse OP with pullup transistors resistors (geez, I think I'll just shut up now and go to sleep), etc. This could only lead him to false assumptions that all he needs now is just some resistor or two. I think at this stage it's enough to say there are multiple abstraction layers in USB implementation and USB in general is infinitely more complex than your garden variety serial interface.

There are multiple stages of why I see this is failing, and one is because there is no pull-up resistor.
If he did try this a PC would likely say 'enumeration failed' (which can be a protocol error), blow up or do nothing at all.
If I am confusing the OP, I need to try harder at explaining.
 

Offline Noize

  • Regular Contributor
  • *
  • Posts: 183
  • Country: gb
Re: Connecting two computers with USB (USB - USB)
« Reply #15 on: October 17, 2013, 10:44:18 pm »
I bought a cable years ago to transfer files by usb from one computer to another. It was different from the normal cable, as in crossed over. I'll have to have a look for it, because I don't remember it having larger than norm plugs to hold a chip.
 

Offline fluxcapacitor

  • Frequent Contributor
  • **
  • Posts: 345
  • Country: gb
Re: Connecting two computers with USB (USB - USB)
« Reply #16 on: October 17, 2013, 10:45:01 pm »
Ive got an old usb transfer cable, the main chip is a Prolific PL-25A1 USB Host To Host Bridge Controller .Cutting and splicing old usb cables just isnt going to work .  http://www.datasheetdir.com/PL-25A1+USB

« Last Edit: October 17, 2013, 10:49:27 pm by fluxcapacitor »
 

Offline magnus0re

  • Contributor
  • Posts: 21
Re: Connecting two computers with USB (USB - USB)
« Reply #17 on: October 17, 2013, 10:51:22 pm »
Indeed USB works as a Host <-> device thing, so as everyone has said before me, Host <-> Host does not work  :( ..


Going to use this chance to generally complain about the USB standard. I am not happy, not at all. Does firewire work better ? if so, how?


 

Offline Stonent

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Connecting two computers with USB (USB - USB)
« Reply #18 on: October 17, 2013, 11:05:17 pm »
Hi,

I have tryed to connect my laptop with my desktop computer by using old usb cables that I have cut and soldered togeather, so that both ends are the same and fit into classic 2.0. USB port, but nothing happens when I connect it.

First time i have soldered the USB cables like this:     +     Data+     Data-      -
after that I have chagled the polarity in data connection:    +       Data-     Data+     -

Nothing happens as I did not even pluged in the cables

USB



There's a cable called an easy transfer cable that you can use for moving data from a vista/7/8 computer to another.

But USB is not an RS-232 serial cable so this won't work as you're trying to do it. Neither computer is a "device" so even if the electrical connections were sound, they won't talk.
« Last Edit: October 17, 2013, 11:06:59 pm by Stonent »
The larger the government, the smaller the citizen.
 

Offline echen1024

  • Super Contributor
  • ***
  • Posts: 1660
  • Country: us
  • 15 yo Future EE
Re: Connecting two computers with USB (USB - USB)
« Reply #19 on: October 18, 2013, 01:00:02 am »
Will someone just shoot me.  |O
I'm not saying we should kill all stupid people. I'm just saying that we should remove all product safety labels and let natural selection do its work.

https://www.youtube.com/user/echen1024
 

Offline MauriceS

  • Contributor
  • Posts: 24
  • Country: us
Re: Connecting two computers with USB (USB - USB)
« Reply #20 on: October 18, 2013, 02:27:48 am »
Instead of blowing up stuff   :( there might be a much simpler - and cheaper solution... And that is the use of a regular or crossover ethernet cable. I think a lot of laptops still have ethernet... Which might not be as fast as USB 2.0 if it just is 100BaseT...

When hooking 2 windows machines together - both will get an IP address in the 169.254.x.x range and then can talk together...  Look for network transfer software...

 

Offline echen1024

  • Super Contributor
  • ***
  • Posts: 1660
  • Country: us
  • 15 yo Future EE
Re: Connecting two computers with USB (USB - USB)
« Reply #21 on: October 18, 2013, 02:30:16 am »
You can hook 2 windows machines up together via Ethernet. I have tried before, and the limit is basically the speed of the hard drives if both computers support gigabit.
I'm not saying we should kill all stupid people. I'm just saying that we should remove all product safety labels and let natural selection do its work.

https://www.youtube.com/user/echen1024
 

Offline Stonent

  • Super Contributor
  • ***
  • Posts: 3824
  • Country: us
Re: Connecting two computers with USB (USB - USB)
« Reply #22 on: October 18, 2013, 02:47:40 am »
Yeah if both computers are set to DHCP and there's no DHCP server, they'll pick a random address that will let them talk. Crossover cables can be bought at most computer stores.
The larger the government, the smaller the citizen.
 

Offline Nerull

  • Frequent Contributor
  • **
  • Posts: 694
Re: Connecting two computers with USB (USB - USB)
« Reply #23 on: October 18, 2013, 03:30:20 am »
Any computer from the last several years isn't going to need a crossover cable. Autosense has been around since 1998, and almost everything implements it by now.

It's pretty rare to actually see a crossover cable anymore.
 

Online Monkeh

  • Super Contributor
  • ***
  • Posts: 7992
  • Country: gb
Re: Connecting two computers with USB (USB - USB)
« Reply #24 on: October 18, 2013, 03:35:58 am »
Any computer from the last several years isn't going to need a crossover cable. Autosense has been around since 1998, and almost everything implements it by now.

It's pretty rare to actually see a crossover cable anymore.

There's still stuff with 10/100 NICs, which don't generally do Auto-MDI/MDIX. Then there's the fatal assumption of assuming it'll work even if present.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf