; @Title: Script to find given string on terminal ; @Description: ; This script reads a string from a window, it looks for a string given ; as a parameter when the script is launched ; do termfind.cmm ; @Author: LBA ; @Keywords: serial terminal ; @Copyright: (C) 1989-2014 Lauterbach GmbH, licensed for use with TRACE32(R) only ; $Id: termfind.cmm 7551 2014-08-20 13:26:52Z mobermeir $ LOCAL &comport LOCAL &speed LOCAL &string ENTRY &comport &speed &string IF "&comport"=="" &comport="COM1" IF "&speed"=="" &speed="115200." IF "&string"=="" &string="my_string" PRINT "port=&comport, bps=&speed" PRINT "looking for [&string]... " WinPOS 4. 4. 80. 25. 0. 0. term TERM.RESet TERM.METHOD COM &comport &speed 8 NONE 1STOP NONE TERM.SIZE 80 1000 ; define capacity of the TERM window TERM.SCROLL ON ; scrolling follows to the TERM cursor TERM.Mode VT100 ; or ASCII (default), STRING, HEX ... TERM.view ; open the TERM window WAIT 2.s TERM.Out " " 10. PRINT "Wait for [&string]..." RePeaT 10. ;repeat the fetch 10 times ( WAIT 1.s SCREEN.display WinFIND "&string" term ) WHILE !FOUND() ENDDO