The Scripts Toolbar

Picture148

Figure 341 – Scripts - Toolbar

3.   New NewFile – create a new Script (an initial template containing the main basic functions opens automatically after naming the new Script and clicking inside the empty editing section of the form)

4.   Save SaveFile – save changes made in a Script to file (.CS)

5.   Delete Delete – delete the Script

6.   Validate Verify – compile the Script

7.   Debug Bug – allow debugging the Script

8.   Sign Script SignRule – allows other users of a Perytons™ Protocol Analyzer license (without a Peryton-Scripting Add-On) to use this Script

9.   Quick Insert Quick Insert – allows inserting a code-set of mostly used functions code structure from a drop-down list

10. Field Lookup (F4) FieldLookup – shows all available fields applicable for using with the code, and insert the field name to the code
Note: The available applicable fields will be shown only if a data captured file has been loaded into the analyzer environment

11. Field Condition Lookup (F5) FiledCondition – shows all available field conditions applicable for using with the code, and inserts the field name with an IF statement
Note: The available applicable field conditions will be shown only if a data captured file has been loaded into the analyzer environment

12. Find and Replace Find – can be used while editing a Script

13. Toggle Script Bookmark Picture68 – add/remove (toggle) a Bookmark for debug purposes. The Bookmark will be set in the line selected and marked in the left margin of the form

14. Remove all the Script Bookmarks Picture152 from the form

15. Go to the previous Script Bookmark Picture151 in the code (used for debug purposes)

16. Go to the next Script Bookmark Picture150 in the code (used for debug purposes)

17. Help OnlineHelp – opens the Scripts On-Line help page with an Internet browser (Internet connection is required)

 

49.4.1    The Scripts Selection List

This Scripts list shows all available Scripts and allows the user to enable/disable the relevant ones he wants to execute:

Picture153

Figure 342 – Scripts,Selection List

Notes: When selecting more than one Script, the Scripts will be executed following the ABC of their name. e.g. if the Scripts called 'ChannelActivity', 'AddMessages' and 'TxTest' are all selected, the Scripts execution will be: 'AddMessages', then 'ChannelActivity' and last ' 'TxTest'. If the name includes a number, the numbers will be sorted by their numeric value, e.g. Script1, Script9, Script10.

49.4.2    The Scripts Editing window

Picture154

Figure 343 – Scripts, Editing window

This window allows editing the highlighted (in the Scripts list on the left hand side of the window) Script.
Notes:
Scripts files (.CS) can be also edited using an external tool of choice (e.g. Microsoft Visual Studio).

Editing a Script with external tools while the analyzer performs a Real Time capture is not allowed.

While writing a Script, the Insert Field Lookup Code icon can be used to show all available fields.

Alternatively the "<F4>" key can be used to show the field selection box.

Figure 344 – Scripts, Field Lookup drop down list

Note: The available applicable fields will be shown only if a data captured file has been loaded into the analyzer environment

The 'Enhanced Field Chooser' allows using wildcards when searching for the field name, and shows a hint explaining the field meaning (similarly to the 'Enhance Field Chooser' used within the Perytons™ Protocol Analyzer 'Find' tool – see par. ‎IV.14.2 for details).

49.4.3    Find/Replace

Allows searching/replacing the current Script code for specific text:

Figure 345 – Scripts, Find/Replace tool

 

49.4.4    Intelisense

Note: The Intelisense automatic drop-down list feature will be shown only if a data captured file has been loaded into the analyzer environment

The Scripts' editing tool included within the Perytons™ Protocol Analyzer environment is called Intelisense.

When typing a function name and then brackets ‘(‘, a box showing the possible arguments will be displayed:

Figure 346 – Scripts, Intelisense1

When typing a name of a class or variable, the list of its valid arguments is displayed:

Figure 347 – Scripts, Intelisense2

 

When using Intelisense, the available variables, fields and functions included in the Peryton-Scripting Add-On environment can be shown by tying the following string within the Script Editing Window:

Perytons.Analyzer.Core.

 

Elements following the 'pink' symbol are possible functions while elements with a 'hand' icon are 'read-only' properties:

Figure 348 – Scripts, Functions and Properties

and elements following a 'blue' icon are variables.

Figure 349 – Scripts, Variables

When pointing on the variable, a hint showing its type is displayed.

Figure 350 – Scripts, Variable Types

49.4.5    Script - Bookmarks

Allows marking lines of interest in the Script code file and easily navigating between them (used for debug purposes). Lines can me marked manually by using the ‘Toggle Bookmark’ icon, or by choosing 'Mark All' in the Find & Replace form.

Note: These Bookmarks are Scripts Bookmarks and aren't related to the Perytons™ Protocol Analyzer time related Bookmarks in Time View.

RulesBookmarks

Figure 351 – Scripts, Bookmarks

49.4.6    Scripts - Compilation Messages

This window displays the Script compilation errors. Clicking on an error line will bring the cursor to the error position in the Script edit window.

rule compilation errors 10-08

Figure 352 – Scripts, Compilation Messages

49.4.7    Script verification code

Scripts that have a valid verification (or signature) code can be used by all Perytons™ Protocol Analyzer licenses owners regardless of their license level (i.e. having an installed Peryton-Scripting Add-On is not required to run validated Scripts).

Users of Perytons™ Protocol Analyzer licenses that do not have the Peryton-Scripting Add-On, will not be able to write new Scripts or to alter those they are provided with.

Note: Modifying such a Script will make the verification code invalid and the Script unusable.

Picture155

Figure 353 – Scripts, verification code

 

In case of a non validated code, the following error message will be displayed:

Figure 354 – Invalid Verification Code, notification

And a warning will be written to the Events Log window when trying to run this Script.