Device Monitoring Studio - Monitor, log and analyze data coming through PC ports and connections
Docs

Working with Scripts

To create new empty script file, execute the File » New » Script command. To open an existing script file, execute the File » Open… command.

Script files are opened in their own windows. You may use the built-in editor to modify script text.

Running Scripts

To start script execution, execute the Tools » Run Script command. TypeScript compiler is invoked first to compile the user script. During compilation, an extensive syntax error detection is performed. If any errors are found, they are displayed in script output and highlighted in the script text.

After script is checked and compiled, the execution of its global scope starts. It continues until the last statement of the global scope finishes execution. Script is then halted but not stopped completely. This is done in order for script to be able to process scheduled asynchronous functions or bound events. Note that scheduled asynchronous functions and bound event handlers cannot be executed until the global script scope execution is finished. The exception is event handlers invoked during execution of the main script body.

To stop script execution, use the Tools » Stop Script command.

Persistence

There are a number of options that govern the behavior of automatic script persistence. All these options are configured in the Tools » Settings, General Tab.

Command Line Support

Full paths to script files passed in command line to Device Monitoring Studio are automatically loaded and opened. If -run option prepends a path, corresponding script file is automatically executed after being opened.