Closed
Description
Describe the problem
The Arduino IDE "Serial Monitor" view has a "Toggle Autoscroll" control. When this is enabled, the view automatically scrolls down as the number of lines of data exceed the visible height of the view.
🐛 The autoscroll is not done completely, resulting in the most recently printed line only being partly visible.
To reproduce
Equipment
- Any Arduino board capable of serial output.
Steps
- Create a sketch that produces sufficient serial output to exceed the height of the "Serial Monitor" view:
void setup() { Serial.begin(9600); delay(10000); for (byte counter = 0; counter <= 100; counter++) { Serial.print("hello #"); Serial.println(counter); } } void loop() {}
- Connect the Arduino board to your computer.
- Select the board and port in Arduino IDE.
- Open the "Serial Monitor" view if it is not already open.
- Select "9600 baud" from the dropdown baud rate menu at the top right corner of the "Serial Monitor" view.
- If it is not already enabled, click the "Toggle Autoscroll" icon near the top left corner of the "Serial Monitor" view to enable autoscroll.
- Select Sketch > Upload from the Arduino IDE menus.
- Wait for the upload to finish successfully.
- Immediately select the "Serial Monitor" tab in the bottom panel.
ⓘ The "immediately" instruction, as well as the delay in the sketch, are required to avoid the demo's result being affected by a separate autoscroll-related bughttps://github.com/arduino/arduino-ide/issues/1724
- Wait until the sketch program's 10 s delay has passed.
🐛 The line shown at the bottom of the "Serial Monitor" view is nothello #100
as expected:
- Scroll the output field of the "Serial Monitor" view downward.
🐛 The field was not scrolled all the way to the end of the output even though autoscroll was enabled.
Expected behavior
The most recently printed line is always shown above the bottom edge of the Serial Monitor view when autoscroll is enabled.
Arduino IDE version
Original report
Last verified with
Operating system
Windows
Operating system version
10
Additional context
I bisected the issue to ac9cce1 / #1662 (it does not occur when using the build from c0af1e6)
This bug also occurred in previous versions of Arduino IDE: #972, but was fixed by #1446
Additional reports
(from current incarnation of the bug)
- Unable to select files in explorer tab in Arduino ide2.0.3 #1891
- Scrollbar covers bottom line of Serial Monitor output #1602 (comment)
- https://forum.arduino.cc/t/arduino-2-0-3-serial-monitor-autoscroll-inoperative/1062358
- https://forum.arduino.cc/t/auto-scroll-wont-scroll-all-the-way/1089933
- https://forum.arduino.cc/t/bug-arduino-2-0-0-serial-monitor-scrolling-hides-last-line/1042690/7
- https://forum.arduino.cc/t/arduino-ide-2-0-4-is-now-available/1095650/4
(from time of the previous incarnation of the bug: #972)
- Serial monitor window cannot see bottom row #1267
- Serial Monitor new line text hiding behind status bar #1198
- Missing "Select All" capability for Serial Monitor #812 (comment)
- https://forum.arduino.cc/t/ide-2-0-rc6-serial-monitor-window-clipping-on-bottom-line/984677
- https://forum.arduino.cc/t/serial-monitor-never-shows-the-last-line/1003734
- https://forum.arduino.cc/t/serial-monitor-still-not-showing-last-line/1091388
- https://forum.arduino.cc/t/arduino-ide-2-0-4-is-now-available/1095650/4
- https://forum.arduino.cc/t/serial-monitor-not-scrolling-properly-in-version-23-1-6049-build-23-1-7883-775/1097581
Related
Issue checklist
- I searched for previous reports in the issue tracker
- I verified the problem still occurs when using the latest nightly build
- My report contains all necessary details