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

Thread: Is it possible to connect the usb2 port on Teensy 4.1 to the computer? I have tried b

  1. #1
    Junior Member
    Join Date
    Sep 2020
    Posts
    2

    Is it possible to connect the usb2 port on Teensy 4.1 to the computer? I have tried b

    Is it possible to connect the usb2 port on Teensy 4.1 to the computer? I have tried but it's failed.Click image for larger version. 

Name:	Screenshot 2020-09-12 205747.png 
Views:	5 
Size:	402.1 KB 
ID:	21704

  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,757
    Short answer is no. That port is only meant to run in USB host mode.

    Longer answer is the hardware can do this, but software support is lacking.

  3. #3
    Junior Member
    Join Date
    Sep 2020
    Posts
    2
    Thank you. I just started my project with Teensy but have very little tutorials on it. I have to fake ip here because the ip package of Vietnam is blocked without knowing why.

  4. #4
    Quote Originally Posted by PaulStoffregen View Post
    Longer answer is the hardware can do this, but software support is lacking.
    Just to clarify – "software support" here means just libraries & drivers provided with Teensyduino and the core library repo – MCU itself is capable of implementing two separate USB devices connected to two different hosts?

    I am starting to plan my custom mechanical keyboard (as custom as I can do, it's supposed to be a hobby project, not a practical one – I want very overpowered MCU and a lot of bells and whistles), and one of the ideas was to be able to plug the thing into two separate computers and implement something like a KVM switch (just the K part, though) without physically disconnecting from one USB host and connecting to another one. Teensy would be connected to two different computers on two USB hosts, present to each as a keyboard, and decide where to send keystrokes based on any logic I could program into firmware.

    Would this be possible? From a glance at the IMXRT1062 reference, it should be. Am I right?

  5. #5
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    7,684
    Should mention, there are ways for you to talk to second PC through the host if you desire. At least by simple Serial...

    That is we support many of the USB to Serial adapters (FTDI, PL2303, CH341, CP210).. Then depending on your adapters, you can maybe either setup to hardware Serial port on the second PC or use another USB to serial adapter that connects up the one on the Teensy...

    Of course you could in this case also bypass using the USB to Serial adapter on the Teensy and simply connect up to Hardware Serial pins.

    Hope that makes sense.

Posting Permissions

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