Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 2 of 2

Thread: PC-connected Teensy(s) for 30+ feet - connection, power, signal ?

  1. #1

    PC-connected Teensy(s) for 30+ feet - connection, power, signal ?

    I am trying to find a good solution to connect several - possibly a dozen - Teensy nodes to a PC host.
    The simplest approach would be to just connect them wired, to a USB hub, and run both power and serial.

    However, eventually I will have to run wire lengths up to 10m and possibly beyond.
    Is this even possible with stock USB2 cables (I found 25' max so far)? For power, data, both?

    I might also have to add a power supply to each node (either because I can't run USB 5V that far, or because each nodes needs more than what the Teensy 3V3 regulator can supply anyway).

    Does this still apply - mechanical modification of USB cable (cut red 5V) or Teensy (pads) is necessary?
    For Teensy LC and Teensy 3.5/3.6 ?

    I looked for data-only USB cables, all I found was:

    Is there any retail or DIY solution for "networking" a bunch of Teensies, or putting them on a bus?

    Is there a better than "Serial" connection between PC and Teensy, over USB? Or would it make sense to investigate actual RS232 solutions?

  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    10 meters is pushing the limits for USB, but can work. The USB spec defines a maximum delay, which translates into 5 meter cables between the maximum number of hubs. Longer cables tend to work, as long as you're not also using many hubs chained together.

    I have personally used a 30 foot extender. It's similar to this one, but I couldn't find a link to the exact one I actually have. They're probably all very similar.

    The 2 other good options for longer distance communication are Ethernet (~100 meters) and RS-485 serial (~1200 meters).

    With USB, all nodes need to be either earth grounded or floating. USB doesn't tolerate any difference in ground, which can become a real problem if you send power over those lengthy difference, since the power wires have some non-zero resistance which causes a voltage difference in GND between the 2 sides.

    Ethernet uses isolation transformers, so it's very good at handling ground shifts. RS-485 chips usually can handle about 7 volts of ground shift, which is quite a lot. RS-485 optical isolators are also common, though they do require making sure your code has "turn around delay" before you begin transmitting.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts