Break out the USB on teensy 4 to my custom PCB problem.

frankzappa

Well-known member
I made a PCB a while ago and it's working great but I decided to redesign it and break out the USB from the back of the teensy by using castellated holes via an ESD protection circuit, here is the IC used: https://jlcpcb.com/api/file/downloadByFileSystemAccessId/8588885254287736832

Soldering went well but I must have messed something up because I can't upload anything. It gets power but it seems it doesn't get the data lines from the USB. I'm getting a slow orange blink and then when I press the program button I get a slow red blink which should indicate I have power but no data.

I tried swapping the d+ and d- on the JST connector but no difference.

Can someone take a look if I made a mistake?

Or maybe those pins on the bottom can't be used to program it?

1742480382716.png
 
Last edited:
Those pads on the bottom go to the second USB port, separate from the one used for programming.
 
Those pads on the bottom go to the second USB port, separate from the one used for programming.
So you can't program it from the bottom pads? That's unfortunate. Just wasted 250 dollars for not asking here on the forum first. So only option is to use a teensy 4.1 then to breakout the USB?
 
So you can't program it from the bottom pads? That's unfortunate. Just wasted 250 dollars for not asking here on the forum first. So only option is to use a teensy 4.1 then to breakout the USB?
Yes, the Teensy 4.1 changed the pads under the PCB to be the first USB that can be used for programming, and not the second USB which can act as a USB host. On the 4.1, you have to use the 5 pins in the PCB to get to the second USB. I believe the Teensy 4.0 is the only Teensy where the bottom pads are the 2nd USB device and not the first. Historically, the Teensy 3.0/3.1/3.2/3.4 did not have the 2nd USB port. Only the Teensy 3.5/4.0/4.1 has the 2nd USB port. All 3 of those Teensies have 5 through hole pins on the inside that you can connect a USB plug, and it uses the layout that older internal PC USB cables used.

If search around there is some third party patches to allow re-programming the Teensy from non-USB devices. But it isn't in the standard sources. You might be able to use the 2nd USB.

As I understand it, USB is either client or host until you get to USB C. The first USB port is client only (i.e. you have to connect it to a USB host like a computer). The second USB port allows the Teensy to act like a host. I.e. with the second USB port, you can plug in USB client devices like USB powered flash drives, wifi/bluetooth adapters, etc.

A kludge solution might be to get a DIY USB micro B cable to bring out the USB pins.
 
Last edited:
Yes, the Teensy 4.1 changed the pads under the PCB to be the first USB that can be used for programming, and not the second USB which can act as a USB host. On the 4.1, you have to use the 5 pins in the PCB to get to the second USB. I believe the Teensy 4.0 is the only Teensy where the bottom pads are the 2nd USB device and not the first. Historically, the Teensy 3.0/3.1/3.2/3.4 did not have the 2nd USB port. Only the Teensy 3.5/4.0/4.1 has the 2nd USB port. All 3 of those Teensies have 5 through hole pins on the inside that you can connect a USB plug, and it uses the layout that older internal PC USB cables used.

If search around there is some third party patches to allow re-programming the Teensy from non-USB devices. But it isn't in the standard sources. You might be able to use the 2nd USB.

As I understand it, USB is either client or host until you get to USB C. The first USB port is client only (i.e. you have to connect it to a USB host like a computer). The second USB port allows the Teensy to act like a host. I.e. with the second USB port, you can plug in USB client devices like USB powered flash drives, wifi/bluetooth adapters, etc.

A kludge solution might be to get a DIY USB micro B cable to bring out the USB pins.
Always problems. Why can't stuff be simple?

Seems like the only solution is to either use a teensy 4.1 or make a custom teensy on the board. Ideally I'd have a custom teensy 4 on my PCB but that is a huge task
 
I believe that the USB data lines can be accessed at the vias circled in the picture below.
I am not sure which two of the 3 circled are the correct ones. Perhaps Paul can chime in.
z.jpg
 
I believe that the USB data lines can be accessed at the vias circled in the picture below.
I am not sure which two of the 3 circled are the correct ones. Perhaps Paul can chime in.
View attachment 37185
Thanks. Not sure how that would help me, I was trying to break out the USB to a JST connector for robustness. Teensy needs to be in a high vibration environment.
 
Thanks. Not sure how that would help me, I was trying to break out the USB to a JST connector for robustness. Teensy needs to be in a high vibration environment.
Just thought it might be possible to run small wires from the vias to your pcb usb connection point(s).
 
Back
Top