Teensy 3.6 host port for PC connection instead of microUSB (but not for programming)

Status
Not open for further replies.

AndyBaker

Member
Hello everybody!

I've searched through the forum for a bit and haven't found a clear-cut answer, so I'm going to post a clear cut question...

Background: I'm basically making a video game controller out of a Teensy 3.6, but I keep having trouble with the microUSB getting RIPPED off the board from carelessness. The fix for this will never happen and is outside the scope of this discussion. :mad: For the same reasons, it's also important that I can have the Teensy in a socketed configuration, because....that's right... carelessness. :mad:

My motivation is that I want to use a more robust USB connector on my own board, but I don't like the idea of pogo pins for reliability reasons. Maybe I'm wrong here. I know I could use the D+ and D- pads, but it just gives me the heebie jeebies, because if that connection fails, my phone starts ringing late at night and that's not my idea of a good time, because then the same dummies that broke it in the first place are in there wiggling things. :mad:

Programming the Teensy over the MicroUSB is just fine, and in fact, probably can't be done any other way. This is OK, and perhaps even a good thing!

Question:
I want to be able to use my Teensy 3.6 as a keyboard/serial/joystick etc device connected to a computer, but using the 'host' port instead, since it's accessible by through-hole pins, which I'm much more comfortable with. To be clear, I don't want the teensy to host a USB device. it IS the device, hosted by the computer. Over the other port.

Can I do this? Do I need to make very serious changes to lower-level teensy libraries? This would be OK.

Any ideas on this port switch would be appreciated, or alternatively, pogo pin pep talks and helpful suggestions.

Thanks! :D

Andy
 
Wow, did you really manage to tear the connector off a Teensy 3.6?

We occasionally hear about this happening with Teensy LC & 3.2, where the connector is only surface mount. Teensy 3.5 and 3.6 have the much stronger connector where 4 tabs are soldered into slots.

If this really happened (as opposed to a concern that it *might* occur), then I believe you will be the first confirmed case.


But regarding your main question, the easy path is to put Teensy 3.6 inside a sturdy box, and use this cable to connect from the Teensy to the side of the box.

https://www.pjrc.com/store/cable_usb_panel_micro.html

cable_usb_panel_micro.jpg



To directly answer your question about the host port...

I want to be able to use ... the 'host' port instead, since it's accessible by through-hole pins, which I'm much more comfortable with. To be clear, I don't want the teensy to host a USB device. it IS the device, hosted by the computer. Over the other port.

Can I do this?

No matter what you do, the bootloader will only support uploading code on the main USB port. It will not support uploading on the host port.

Theoretically, you could write code to run the host port in device mode.


Do I need to make very serious changes to lower-level teensy libraries? This would be OK.

Yes, it's a massive change.

However, the upcoming Teensy 4.0 board will have 2 ports, both with the same USB controller as we have only on the host port on Teensy 3.6. (The device port on 3.6 is a completely different controller). So if you look at the beta test we're doing for Teensy 4, you can find some code that puts that controller into device mode. As you can guess from the messages on that lengthy thread, the USB device code still leaves much to be desired. But I will be working on it soon. If you wait several weeks, you'll probably find code that's pretty close. If you wait several months, eventually that code will get back-ported to Teensy 3.6 and probably published as libraries to use the 2nd port in device mode.

But you're *still* going to need a cable to connect from Teensy 3.6 to a study USB B connector. Why not just use the cable and software that already exists for the main USB port?
 
Wow, did you really manage to tear the connector off a Teensy 3.6?

We occasionally hear about this happening with Teensy LC & 3.2, where the connector is only surface mount. Teensy 3.5 and 3.6 have the much stronger connector where 4 tabs are soldered into slots.

If this really happened (as opposed to a concern that it *might* occur), then I believe you will be the first confirmed case.

Well you can make that 2 confirmed cases - broke it off my T3.5 by dropping on floor with the cable on - and of course it fell cable end first - just plain carelessness .
20190322_180951.jpg

EDIT: Based on the next post - guess I am the only one :)
 
Last edited:
Hey Paul,

Thanks for the very clear answer.

I haven't actually put any Teensy 3.6s in to production here at the circus, I'm replacing an LC because I need a lot more I/O, so I haven't ripped any USB ports off them, but I can confirm that I have a special box of Teensy LC & 3.2 with missing USB connectors. I just figured I'd be dealing with the same problem on the 3.6. If I succeed, I'll be sure to document and let you know. As for using that second port, I'll punt and stay with the Micro USB and find a way to lock down the cable like you suggest.

Thanks for the quick response.

Andy
 
Status
Not open for further replies.
Back
Top