Go Down

Topic: Clear Screen on Serial Monitor. (Read 16202 times) previous topic - next topic

denadai

Hiho All!

I'm a brazilian guy and my english isn't pretty good. So if anyone can help me i will thankful a lot!

My problem is:

How i can clear the screen on serial monitor?

like we does on #C: "system("cls");" or "clrscr;"

I've tryed "Serial.Clear", but i don't get any results, only a big red message, on my board.

Sorry about the english.

Thx.

PaulS

Why do you want to clear the screen? It's a debugging window.

Closing it, and reopening it will clear it. It will also restart the Arduino.

You could also write your own serial window application. That's what I did. I have a Find field, to find data in the window. I can add additional features are they occur to me.

retrolefty

#2
Nov 24, 2009, 04:58 am Last Edit: Nov 24, 2009, 04:59 am by retrolefty Reason: 1
Or better yet, instead of using the IDE serial monitor, use a real serial terminal program. If you are using Windows I highly recommend Brey terminal, it has tons of features, it's free, it's a standalone exe file, so no installation required. Along with tons of over commands, it has a clear receive window, clear send window.

http://sites.google.com/site/braypp/terminal

Lefty

denadai

Oh, thank everybody!

i want this code, because i'm reading the deegres of a servo and sending this data by serial, and debugging in serial monitor.

But when the debug gets a lot of lines, the serial comunication with arduino stop, and i need to restart the sketch!

I only want, try to clear the serial monitor screen to stop this error...

But i going to try brayapp like lefty said.

sorry about the english, one more time.   :-/

thx everyone again!

Osgeld

#4
Nov 24, 2009, 05:18 pm Last Edit: Nov 24, 2009, 05:18 pm by Osgeld Reason: 1
if your using a normal terminal program i believe the clear charter is (ascii code)12 or 13
http://arduino.cc/forum/index.php?action=unread;boards=2,3,4,5,67,6,7,8,9,10,11,66,12,13,15,14,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,86,87,89,1;ALL

xp19375

To clear the screen in a terminal emulator, a standard clear screen command is (esc)[2J, so your code would look like this:

 Serial.print(27,BYTE);   //Print "esc"
 Serial.print("[2J");

This will not work in the Arduino Serial Monitor, so you need a terminal emulator.  Since it doesn't use a serial port, you also need a serial port emulator.  DOSBox and Procomm will work.  Both are free.

Download and install DOSBox (I am using v 0.74), then modify the config file under [serial] and set serial1=directserial realport:COM1 (or whatever COM port you are using).

In Procomm, set the appropriate baud rate, using alt-p, and no parity, 8 data bits, and 1 stop bit.

Hope this helps.

retrolefty

Quote
Hope this helps.


It would have a year ago or so.  ;D

Go Up