Teensy 3.6 extremely slow serial

Status
Not open for further replies.

A6_quattro

Active member
Hi

I've reached the end of my struggle to get my Teensy come up to speed when writing and printing to serial monitor. It's extremely slow even with the simpliest code example that I've found in the example folder for Teensy in my Arduino IDE.

I've googled this for hours and almost given up, I think the problem is with the COM port.

Read several forum threads here on PJRC on this but nothing will help me fix the problem...

Please, could someone give me some guidance or input?

Running Win 10 on my laptop.

Regards
Hans
 
Please, could someone give me some guidance or input?

I have no idea why it's running so slow for you. I don't know what code you're running, or what exactly you're observing that appears to be so slow.

But I can run a test here with a simple program. I can even record a short video, so you can see the code and exactly how I tested, and the speed of printing in the serial monitor.


I believe you can see it prints very fast here on my Windows 10 laptop.

Maybe you could try running this very simple program and compare results?
 
Hi

Extremely thankfull that you responded!

The Teensy ran fine before a couple of day ago and I thought I might have done some with some settings in the Arduino IDE, so after a couple of tries with the COM port settings I unistalled the Arduino and installed it togehter with Teensuino. But no change, tried to switch of the Windows Defender, no change. I Think I've tried all things that I could find in forum threads.

The test program I've tried to run is:

void setup()
{
Serial.begin(38400);
Serial.println("Setup!");

}

void loop()
{
Serial.println("Hello world!");

}

It will print the command in the loop area but not in the setup. I've tried the RawHID setting for the Port setting also but nothing is really working. Should I try to install Arduino IDE on Another computer to if it'll work better?

I going to run your program also to test.

Regards
Hans
 
Now I'm confused. Is the problem "extremely slow" or "does not print the first line"?

It will print the command in the loop area but not in the setup.

You need to add this:

Code:
  while (!Serial) ; // wait for serial monitor

Your setup() is finishing very quickly, before Windows can complete detecting the USB device. This line causes Teensy to wait.

Also make sure you add a count variable or other way the lines change. If you print the same "Hello World!" on every line, you have no way to see how fast they are printing because every line is the same!

Teensy is very fast. If you have a slower Windows machine, the high speed of printing and scrolling can overwhelm your computer! Usually adding "delay(1)" in loop helps.

I'm pretty sure every problem you're seeing is due to it running far too fast.
 
Also, if you add the "while (!Serial) ;" line, but then leave the Hello World printing in loop() without any delay, Teensy 3.6 will print those lines so rapidly that Arduino will scroll the first line off screen and purge it from memory after just a few seconds.

Teensy 3.6 is fast. This "problem" is even more severe on Teensy 4.0, which can send so fast that most Windows computers can not keep up. Even Linux struggles to handle Arduino scrolling at that speed.

Remember to add delays if you want to actually see the results!
 
Hi Paul

Sorry for late respons in this matter. I think the problem is with my old laptop usb connection because I've tested on another computer with success so it seem it's not Teensy to blame for this.

Sorry for not testing that before writing here…

And thanks again for your help.
 
Status
Not open for further replies.
Back
Top