Recently I’ve noticed that the Serial Monitor is very slow to start up. Previously it seemed to start up in 1-2 seconds, but now it takes ~8.5 seconds on a MacBook Pro running macOS Big Sur 11.6.8. The target platform is a Teensy 4.0.
Normally I upload my code using the “Upload” icon at the bottom of the screen, and then (if necessary), immediately press the Serial Monitor icon. With a 3 second delay in my code after Serial.begin(), everything previously worked fine. Now I’ve needed to increase the delay to 10 seconds, which seems eternally long when you’re anxious to see if your code works.
Any ideas on why the Serial Monitor behavior/performance has changed? Is there a different workflow I should be using? Since Teensy 4 doesn’t support debuggers, I rely on printf-style debugging. This has worked fine for me, but sometimes requires lots of iterations, and the 10-second delay adds up…
I’ve just created a separate branch of PIO Core with debug information. Please open PlatformIO Core terminal in VSCode (terminal icon on the bottom status bar) and type:
pip install -U https://github.com/platformio/platformio-core/archive/refs/heads/feature/debug-dev-monitor.zip
pio device monitor
You will see a debug output with time frames. Please share it here.
Hi @ivankravets !
I had the same problems with the serial terminal.
After installing the package you specified, it became much faster.
However, I don’t see any time frames.
I’d like to help more, but I’m leaving for Burning Man in a couple of hours. I used PlatformIO to write the LED lighting code for a large art project (25 foot glass/steel shark), and I’m still making tweaks, so I don’t want to mess with my configuration right now. I hope you understand. I’ll be totally off-grid for the next 12 days, so I’ll check in when I get back. I hope the other guys can help you track down the problem.
I tried installing the debug device monitor but I’m not seeing any additional output. Here’s what I got while installing the code and running pio device monitor:
Just checking a couple of things I noticed that if I specify the port value, either on the command line or in the platform.io then the terminal starts up quite quickly. If I don’t specify a port then it takes the 5 seconds or more to find the port and then start up.