Teensy not recognised but blink sketch load

MOCmaniac

Member
Hello everyone,

As part of my master thesis project, I'm using a Teensy 4.1 to communicate with devices over CAN. My first setup was on a breadboard and worked flawlessly for several months. Now that everything is validated, I've soldered the final circuit onto a protoboard, including the two CAN transceivers, a USB cable for power, decoupling capacitors to be on the safe side and other components. The Teensy is powered through a diode as recommended here because when it was still on the breadboard, it was powered with 5V from a battery while also connected to USB. When the Teensy is running and connected to a PC, it outputs quite a lot of debug on the serial monitor in the arduino IDE (115200baudrate). Lines of around 300 chars every 50ms (also logged on the SD card). It is perhaps not a lot compared to the usb port capabilities but I prefer to mention it.

After a few hours of operation in this new setup (closed enclosure), the Teensy stopped responding. Here's what I've observed so far:
  • The Teensy no longer shows up in the Arduino IDE (nor in the Device Manager).
  • I held the button down for about 10 seconds - the LED next to the USB port turned on, and then the Blink sketch started running.
  • I tried plugging it in using a different micro USB cable, but it didn’t help. Another Teensy 4.1 works fine with the same cable and is correctly detected by my computer, and I can upload code to it without any issues.
  • The board still receives 5V, and I also measure 3.3V output from the regulator.
  • The same code (quite confidential - I can't post it directly here) is running without any noticeable issue on the other Teensy and was running on it before.
Here is a photo of my current setup. (I also have a suspicion that the D+ and D− pads might be swapped - is that possible?)
IMG_20250701_214917(1).jpg


For now, I can easily replace the Teensy, but I’d really like to understand why it stopped working, and more importantly, how to avoid this issue in the future. This is a critical project for me, and if the Teensy fails during the final presentation, it would be a major problem.

Since the Teensy is inside this almost closed enclosure, could a component have overheated? What could I test after this to determine the cause of the problem?

Thanks in advance for your help!

Arnaud
 
@MOCmaniac (Arnaud): it's not easy to tell for sure how much clearance you have between the T4.1 & the top cover of the case, but check to make sure that the PROGRAM button is not getting pressed by the top cover or by any wires when the case is closed.

Hope that helps . . .

Mark J Culross
KD5RXT
 
The T4.1 program button is a few mm away from the lid and the problem occurs even when it's outside of the case as it is in the picture. There is no restart or whatsoever so I don't think it is overheating. It was disconnected from everything during the night and it still does not appear in the device manager but the blink sketch is still running from the previous reset.
 
Try twisting D+ and D- from the cable exit to the pads.
Where is connected the USB cable shielding ????
Is the USB GND connected to the Teensy GND ????
 
(I also have a suspicion that the D+ and D− pads might be swapped - is that possible?)

Normally green is D+ and white is D-. So if your cable is connected the normal way, this looks like the signals aren't swapped. Of course, the photo doesn't show the connections all the way to the USB connector, so impossible to say more than this based only on the wire colors.

However, these wires don't look like they're meant for 480 Mbit/sec USB signals. Normally about an inch of ordinary wire works, but this looks longer. Usually best to use a shielded cable or run the USB ground together with the 2 data wires, because USB is not 100% fully differential like Ethernet and PCIe. It uses 3 signal states (J, K, SE0) where the SE0 state is both lines low. Ground is really important.
 
Thanks @Angelo and @Paul for your replies. The USB cable I'm using is an old USB to RJ45 cable from which I removed the RJ45 connector. The GND is connected to the Teensy's GND, the 5V to 5V via the diode, the green cable to D+ and the white cable to D-. The cable shield isn't connected at the moment. I'll look into improving this connection and reducing the free cable length in the case. (For the reversed D+ and D-, I simply misread the pinout diagram).

Aside from this connection, when I use another cable (tested with another Teensy) directly into the micro USB port, I have exactly the same symptoms.
 
@MOCmaniac: I may be misreading what you are saying. With the T4.1 outside the case as shown in your picture (nothing else connected), unless you are connecting directly to the microUSB connector on the T4.1 itself, USB would not work with just those two USB D+ & D- wires. GROUND is needed as well (& how is it getting power when outside the box ??).

Mark J Culross
KD5RXT
 
@kd5rxt-mark. I'm using another cable from the grey one, directly connected from my pc to the micro usb port (most basic ans reliable setup I can use I think). So no connexion with the D+ and D- pads or anything else. With that the T4.1 still doesn't show on the device manager or whatsoever.
 
Is it being connected to a plain old PC usb port, or something more exotic like a mac with a USB-C port using a converter? Details are important here...
 
How are CAN transceivers being powered?
3.3V? or 5V?
Since T4.x I/O pins are not 5V tolerant, you should not power CAN chips from 5V.
Check the voltage at CAN pcb's to verify they are both being powered from 3.3V.

I'd suggest you desolder the USB wires from bottom pads and test T4.1 with only a USB cable connected to PC. The flying wires could be the issue (as other people have mentioned).

You mentioned T4.1 was powered via diode as shown in this link while testing on a breadboard (USB power source and 5V battery source). I don't see a diode on bottom of Teensy in the photo. Did you cut T4.1 pcb track as shown on that link? Please provide details of power connections when using breadboard vs protoboard.
 
The CAN transceivers are connected to the T4.1 3.3V with small decoupling capacitors.

I should have been more clear about the diode on the power input. My first setup on the breadboard was with the other (working) T4.1. That one has a diode soldered on the bottom and the track near the usb port is cut. The T4.1 that is dead does not have a diode between VUSB and 5V but only on the power coming from the grey USB cable. I removed the D+ and D- flying wires from the T4.1 but it changes nothing.

Here is a schematic of the circuit soldered on the protoboard:
Teensy 41_250702_145632_0.png


You can also find pictures of the working and dead T4.1 (Black USB cable connected to it). I still have exactly the same behaviour as in my first message:

  • The Teensy no longer shows up in the Arduino IDE (nor in the Device Manager).
  • I held the button down for about 10 seconds - the LED next to the USB port turned on, and then the Blink sketch started running.
  • I tried plugging it in using a different micro USB cable, but it didn’t help. Another Teensy 4.1 works fine with the same cable and is correctly detected by my computer, and I can upload code to it without any issues.
  • The board still receives 5V, and I also measure 3.3V output from the regulator.
  • The same code (quite confidential - I can't post it directly here) is running without any noticeable issue on the other Teensy and was running on it before.
 

Attachments

  • IMG_20250702_145904.jpg
    IMG_20250702_145904.jpg
    390.8 KB · Views: 22
  • IMG_20250702_145852.jpg
    IMG_20250702_145852.jpg
    405.7 KB · Views: 22
It's a bad idea to run a LED from the Teensy's IO pins like that - they're limited to ~4ma max.
 
Thanks @jmarsh for the feedback. I will find another solution for that. I had the usual 20-40mA of Arduino's output in mind when creating this circuit. But could this create the problem I have with my board ? The CPU seems fine as the blink sketch is running
 
Thanks for clarifying the power scheme and photo's. That helps.

I wonder if you've knocked a component off Teensy while extracting from prototype board?
Or, possibly cracked a solder joint while extracting Teensy. Teensy pcb is pretty thin and some people have cracked the solder balls under processor. You could try squeezing processor and pcb together (between thumb and first finger) then connect to PC USB and see if it shows up.

It does sound like Teensy is still alive (evidence a working Blink program). Is there possible damage to Teensy USB connector? Inspect inside it. Maybe a solder whisker shorting USB signals (around where you soldered).

I know you said the USB cable works with the other Teensy, but it might be worthwhile to try another USB cable.
 
But could this create the problem I have with my board ? The CPU seems fine as the blink sketch is running
On one hand, it doesn't sound like it - the problem seems to be related to the connectivity of the USB lines. But on the other hand all sorts of random hardware issues can be caused by cooking the IOs.

FWIW I wouldn't rely too much on the blink sketch making the Teensy show up as a USB device on the host PC - better to push the programming button to put it into programming mode (the top LED should stay on) to ensure it's in a state where it is known for sure that it will enumerate.
 
I just checked the board, and no components seem to be missing compared to the one that works. I've tried a dozen times pressing the various integrated circuits, but nothing was detected on the PC side. The USB connector seems fine, but it's so small I can't be sure. No debris are stuck inside it too. Since the beginning, I've tried three USB cables that are in my box of "good" cables, aka those with D+ and D- connected.

The only difference I noticed between the two T4.1s is that on the one that died, when I press the program button, the LED next to the USB port stays on for approximately 2 seconds, then goes off for 2 seconds, and this cycle starts again endlessly.

If the PCB is cracked or a component is unsoldered, can I put the board in an oven with a certain temperature profile to try to revive it? If it's dead, I might as well try! I have access to a reflow oven at the company I am doing my master thesis with.
 
The LED is not likely your issue. Most LEDs have a 2.0V or larger voltage drop and a 330 ohm resistor will keep current down under 4mA. If you want to be conservative or have an LED with very low voltage drop like 1.7V, you can increase it to something like 470 ohms to be safe. The Teensy module itself has an LED on pin 13 with a 470 ohm resistor and that is on the mission critical SCK line.

Slow steady blinking on the small red LED when Program button is pressed usually means there is no USB communication. Everything seems to point to a USB data problem. Since you have apparently ruled out the USB cable and you no longer have your external USB hooked up, I would suspect the USB SMD pins.

If you have access to something like a stereoscopic microscope, those can be quite handy for finding poor solder joints or whiskers. I would also be tempted to put some liquid flux on the USB pins and reflow them with a soldering iron, then clean them up well with some IPA. I don’t think you will have any success trying to reflow the whole Teensy.

Meanwhile I would get some run-time on your 'good' Teensy in your setup to minimize the risk of a failure occurring during your presentation.

1751487623632.png
 
This may be a dumb question, but when you're testing with a known good cable, is the cable plugged directly into Teensy's USB connector? And if so, are those non-USB white and green wires still soldered to the bottom side during the test?

I'm also curious what this part is on the bottom side? Or really, my question is whether it is making metal contact to the 2 bottom side USB signals?

1751491777976.png
 
This may be a dumb question, but when you're testing with a known good cable, is the cable plugged directly into Teensy's USB connector?
Yes, same setup as the pictures attached to this message:
You can also find pictures of the working and dead T4.1 (Black USB cable connected to it). I still have exactly the same behaviour as in my first message:
And if so, are those non-USB white and green wires still soldered to the bottom side during the test?
No, I removed them (see pictures previous message).

I'm also curious what this part is on the bottom side? Or really, my question is whether it is making metal contact to the 2 bottom side USB signals?

View attachment 37810
It's a low V_f diode. I put kapton tape under it to only leave the 5V and VUSB pads apparent to avoid shorting anything accidentally. This is the working Teensy so I'm not worried about it
 
If you have access to something like a stereoscopic microscope, those can be quite handy for finding poor solder joints or whiskers. I would also be tempted to put some liquid flux on the USB pins and reflow them with a soldering iron, then clean them up well with some IPA. I don’t think you will have any success trying to reflow the whole Teensy.
This morning I put flux on the smd pins and a little bit of solder on my iron tip and try to drag solder these pins, they look okay. I connected my cable to the USB port of the T4.1 and the other end of the cable to a breakout board. I have continuity between the power pins and the T4.1 and breakout board. For the data line, I also have continuity between the small circular pads on the bottom side of the T4.1 (under the USB port) and the breakout board so I guess the smd pins are soldered correctly, or at least enough to get continuity.

Is there anything else I could check to debug this board ?
 
Maybe some comparing against the known working Teensy.
1) Use a charger USB cable to power Teensy. Then look at USB data pins and compare.
2) Observe 24MHz oscillator signals with oscilloscope using low capacitance probes. The probes will throw the frequency off, but you shouldn't see a drastic difference between crystals (like 18MHz on 1 crystal and 23MHz on the other).

If available, a USB protocol analyzer might indicate if Teensy is attempting communications (with USB data cable of course).

Have you checked for a short between D+ and D- signals? Between ground and D? Between +5 and D?

If the company has a reflow oven, they might also have a BGA inspection camera. This is used to observe rows/columns of solder balls when device has been soldered to pcb, looking for defects. It's a pretty neat view! Cracked solder balls are detectable.
 
2) Observe 24MHz oscillator signals with oscilloscope using low capacitance probes. The probes will throw the frequency off, but you shouldn't see a drastic difference between crystals (like 18MHz on 1 crystal and 23MHz on the other).
Sadly, I don't have such a good oscilloscope at home, my "pocket" oscilloscope only goes to 1MHz. I was able to probe the 33kHz (?) crystal but more than that becomes difficult. They have 10GHz oscilloscopes at the company so I will be able to probe them when I go there. I will also ask if they have a USB protocol analyzer.

Have you checked for a short between D+ and D- signals? Between ground and D? Between +5 and D?
I checked every combination possible and I'm also in the 10-20Mohm range so it's ok for that. I also measured the current drawn by the working and dead T4.1, both reset with 10 seconds program button and they both use around 60mA so this looks good too.
1) Use a charger USB cable to power Teensy. Then look at USB data pins and compare.
I will also do that at the company with proper equipment, with my oscilloscope and my setup it's difficult to probe both data lines correctly at the same time.

It's really frustrating, the board does not seem to have a broken component, I don't think that pins got shorted at one point in the enclosure (can easily happen on a breadboard with component move around all the time) and the CPU still looks okay...

Thanks everyone for the help until now and I will come back with more results after inspecting it at the company I'm working at !
 
Back
Top