VIAVI TestCenter: Easy way to install HLTAPI
Knowledge Base - FAQ
VIAVI TestCenter: Easy way to install HLTAPI
In order to install HLTAPI 4.77 (or earlier) you will need to do the following (considering you already have the STC application installed):
For the examples in the instructions bellow we are considering the following:
STC 4.77 (default install directory)HLTAPI 4.77ActiveState TCL 8.5.18 32bit version (for Linux TCL please refer to FAQ19031)
Only 8.5.9 and 8.5.14 Tcl versions are officially supported from the 8.5 series.
• Download and install TCL (8.4 - 8.5) 32 bit version from ActiveState
Example installation location: C:\Tcl (for Windows) or /root/tcl (for Linux)
Versions 8.6 and above will cause the "Save As HLTAPI" functionality to be disabled
• Download the HLTAPI from the CSC
• Go to the STC application installation folder, go under "VIAVI TestCenter Application" and create a folder called "HltAPI"
Example: C:\Program Files (x86)\VIAVI Communications\VIAVI TestCenter 4.77\VIAVI TestCenter Application\HltAPI
• Unzip the HLTAPI release package, and copy the SourceCode folder to the HltAPI folder just created.
• Create the following environment variables (directories must match the STC version you are using):
• STC_INSTALL_DIR = C:\Program Files (x86)\VIAVI Communications\VIAVI TestCenter 4.77\ VIAVI TestCenter Application
• STC_TCL = C:\Program Files (x86)\VIAVI Communications\VIAVI TestCenter 4.77\TCL\bin\tclsh
• TCLLIBPATH = "C:/Program Files (x86)/VIAVI Communications/VIAVI TestCenter 4.77/VIAVI TestCenter Application" "C:/Program Files (x86)/VIAVI Communications/VIAVI TestCenter 4.77/VIAVI TestCenter Application/HltAPI/SourceCode"
• If you are using a different version of HLTAPI that is installed in a different directory, change the second part of TCLLIBPATH to match the HLTAPI SourceCode directory that you want to use
• LD_LIBRARY_PATH = C:\Program Files (x86)\VIAVI Communications\VIAVI TestCenter 4.77
• Verify that the bin folder path of the ActiveState TCL is added in your environment variable Path, if not, add it.
Example: C:\Tcl\bin
• Open a fresh cmd and execute the following commands, you should get a similar output as the image below once everything is ok:
• tclsh
• package require yaml
• If you don't have it installed, please exit tclsh and execute on cmd: teacup install yaml
• package require ip
• If you don't have it installed, please exit tclsh and execute on cmd: teacup install ip
• package require Tclx
• If you don't have it installed, please exit tclsh and execute on cmd: teacup install Tclx
• info patchlevel
• package require stc
• package require sth
• If you can't successfully load sth, please open a ticket with support and provide the following:
• Screenshot of output for above commands
• Environment variables mentioned above (screenshot can be useful also)
• TCL version and bit version
• OS and bit version
• STC version and bit version
• HLTAPI version
Additionally, in order to use the "save to HLTAPI" tool on the GUI (only for Windows), you need to register the tool for that version, execute the "toolRegister.tcl" script (that comes inside the HLTAPI package that you have unzipped earlier, it should be under SourceCode\tools\) with the STC version as argument, see example below:
tclsh C:\Program Files (x86)\VIAVI Communications\VIAVI TestCenter 4.77\VIAVI TestCenter Application\HltAPI\SourceCode\tools\toolRegister.tcl 4.77
In order to install a HLTAPI version higher than 4.77 (4.81 and later) you will need to do the following:
For the examples in the instructions bellow we are considering the following:
STC 4.88 64 bits (default install directory)TCL 8.5 64 bits (downloaded from CSC) (for Linux TCL please refer to FAQ19031)HLTAPI 4.88 (comes with the STC install)
• Download and install the STC 4.88 64bit version (HLTAPI comes with the STC application instalation from STC 4.81 and later) you want to use.
• Download and install TCL 8.5 64 bits from CSC
• Create the following environment variables
• STC_INSTALL_DIR = C:\Program Files\VIAVI Communications\VIAVI TestCenter 4.88\ VIAVI TestCenter Application
• STC_TCL = C:\Program Files\VIAVI Communications\VIAVI TestCenter 4.88\TCL\bin\tclsh
• TCLLIBPATH = "C:/Program Files/VIAVI Communications/VIAVI TestCenter 4.88/VIAVI TestCenter Application" "C:/Program Files/VIAVI Communications/VIAVI TestCenter 4.88/VIAVI TestCenter Application/HltAPI/SourceCode"
• The second path on TCLLIBPATH can be omitted if you are going to use the same HLTAPI version as the STC, otherwise, you can add the path of another HLTAPI version SourceCode directory
• LD_LIBRARY_PATH = C:\Program Files\VIAVI Communications\VIAVI TestCenter 4.88
• Verify that the bin folder path of the TCL downloaded from the CSC is added in your environment variable Path, if not, add it.
Example: C:\Program Files\VIAVI Communications\VIAVI TestCenter 4.88\TCL\bin
• Open a fresh cmd and execute the following commands, you should get a similar output as steps above:
• tclsh
• info patchlevel
• package require stc
• package require sth
• If you can't successfully load sth, please open a ticket with support and provide the following:
• Screenshot of output for above commands
• Environment variables (screenshot can be useful also)
• TCL version and bit version
• OS and bit version
• STC version and bit version
• HLTAPI version