Clear tera terminal screen

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Clear tera terminal screen

1,129 Views
josephg
Contributor II

I'm trying to clear the tera terminal screen using the clrscr() function with MCUXpresso IDE v10.3.0_200 but it is not working what should I do?

0 Kudos
Reply
2 Replies

1,004 Views
lpcxpresso_supp
NXP Employee
NXP Employee

Assuming that you are sending output to the UART via the standard SDK debug console functionality, then the following should clear the screen :

 PRINTF ("\x1b[2J");

This will cause the underlying DbgConsole_Printf() routine to send the escape sequence for a terminal "erase screen", which is <ESC>[2J    (where <ESC> is the ASCII escape character 0x1b). Note that the exact details of how this is handled will depend upon your terminal program

This certainly seems to work in the limited testing I've just done here with the IDE's built-in terminal (more information on this built in terminal can be found in  the MCUXpresso IDE v10.3 User Guide, section 19.8, "Using Terminal View for UART communication with target").

Regards,

MCUXpresso IDE Support

0 Kudos
Reply

1,003 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Joseph Grigaliunas ,

"clrscr()" function works in Turbo  C compiler only.

It seems there isn't function in MCXUpresso IDE support clear screen, I will confirm with development team,

then will tell you .ASAP.


Have a great day,
TIC

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos
Reply