T41: Periodic USB port disconnection (about every 8 seconds)

Status
Not open for further replies.

Latschenseppl

New member
Subject: T41 Periodic USB port disconnection (about every 8 seconds)

Hello all,
I had a curious error last week that brought me to the brink of despair.
The solution was simple in the end, but there are still questions.
I am writing this report to prevent anyone else from falling into the same trap.
I have a rather complex application (Hardware in the Loop in interaction with X-Plane).
I am using Arduino 8.1.15 with Teensduino 1.54.
To get a better performamce I migrated the project from T36 to T41 and the problems started immediately :-(
Everybody knows this saying:
The problem with troubleshooting is that sometimes the trouble shoots back.
This is exactly what happened
I have tried all the hot "tips" from the Internet without success. The hottest "tip" was to uninstall all USB devices and restart WIN 10,
so that Windows restarts all USB devices on reboot.
I was promised that this would solve all my problems.
The whole thing ended with a total crash and a blue screen.
That was the low point of my troubleshooting :-(
After reinstalling Windows and Arduino from a backup , i tried a new way.
Meanwhile i had checked, that all Teensy-examples were running fine. Also the compilation with the T36 ran perfectly.
I then rebuilt the project and added the modules and header files one after the other.
When adding a header file I found the problem.
T41_error_b04.jpg
The problem was the variable modifier "PROGMEM".
see picture) After deleting this variable modifier everything was ok.
Solutions can be so simple.

I would be interested in the opinion of the specialists here in the forum whether there is an explanation for it or whether it is a BUG in conjunction with T41.
 
Something in your program is crashing or accessing illegal addresses, triggering a fault exception. 1.54 has a new fault recovery which automatically reboots after 8 seconds.

There's also a new CrashReport feature to help you figure out what's going wrong. Add this at the beginning of setup:

Code:
void setup() {
  Serial.begin(9600);
  while (!Serial) ; // wait for Arduino Serial Monitor
  if (CrashReport) {
    Serial.print(CrashReport);
    Serial.print("click Send to start running");
    while (Serial.available() == 0) ; // wait for incoming data
    Serial.clear();                   // discard received data
  }

}

For more background, check out the 1.54 new features article. Scroll to the last part about Fault Recovery & CrashReport.

https://www.pjrc.com/teensyduino-1-54-released/
 
Status
Not open for further replies.
Back
Top