Teensy programmer time out

cuchan

Member
I experienced a programming (rebooting) failure problem on a PC, while the same Teensy and USB cable work fine on other computers. Pressing the reset button occasionally helps (see detailed below).

I notice that the rebooting response on Teensyduino always comes a few seconds AFTER the programmer reporting failure. Therefore, I suspect the issue is that the Teensy communication takes too long to respond to the reboot command, so the programmer reports failure BEFORE the reboot confirmation arrives and shows up on Teensyduino.

Indeed, I can get the programmer working be either: 1. Press the reset button a few seconds before I start uploading from my IDE; 2. Upload from my IDE once to send the reboot command, and then quickly initiate uploading again. Yet, both methods are a bit troublesome to operate.

Is there a way to set the timeout of the programmer? I think this problem can be easily fixed by allowing it to wait for a few seconds longer.

More details:
Windows 7, Teensy3.1,
IDE: Arduino or PlatformIO, Teensyduino 1.42
This doesn't depend on the code being uploaded.
 
In Teensy Loader, click Help > Verbose Info. In the info window, use the Log menu to save all the data to file, which you can post here. If using Quick Reply, click Go Advanced for the full message editor which allows you to attach a file.

Also, are you running McAfee or Norton or similar anti-virus software. McAfee has been reported to cause a lot of problems!
 
Thanks for replying. There is no Antivirus software installed on that PC. I have done tests to upload the blink.ino with Arduino IDE. The IDE output and log file are attached. Note that the IDE reports failure at 16:19:49.274, but the "reboot OK" shows up at 16:19:54.680. Oddly, even though the IDE report failure, the code was actually uploading well AFTER the "reboot OK" shows up (as it starts blinking). I didn't realized this in my last post. So I guess the situation is: the code is successfully uploaded and received by Teensy - it is just that the confirmation returns late and the Teesy loader thought it was failed.

View attachment test1_arduinoIDE.txt
View attachment test1_log.txt
 
The problem seems solved. The changes I made was 1. Disconnecting the USB power by cutting the bottom side contact. 2. Connecting a 5V external power supply. 3. Adding a crystal clock. (I think this is irrelevant.)

The root cause could be I am pulling too many devices with the USB power, so Teensy is running at a lower clock rate and takes much longer to reboot. Now it takes about 4 seconds for a long script.
 
Back
Top