The following are miscellaneous instructions used in TSM scripts.
chantype ()
The chantype instruction is used while implementing Converse Data Return to support the DEFINITY Call Vectoring feature. The instruction enables scripts to determine the type of channel they are running on.
TAS Script Instructions contains a list of values returned in register r.0 from the /att/include/irDefines.h header file. A negative value is returned if an error occurs.
For example:
#include "/att/include/irDefines.h"
/* get channel type */
chantype()
load(int.F_chantype, r.0)
/* channel type must be TR or LSE1/LST1 */
jmp(int.F_chantype == IRD_TR, L__chan_OK)
jmp(int.F_chantype == IRD_ASAI, L__chan_OK)
jmp(int.F_chantype == IRD_LST1_DEF, L__chan_OK)
jmp(int.F_chantype == IRD_LST1_GAL, L__chan_OK)
jmp(int.F_chantype == IRD_LST1_ASAI, L__chan_OK)
hbridge (type.src,type.src)
The hbridge script instruction directs the current channel to bridge partially to another channel. This results in the audio coming in on the specified channel to be heard or dropped by the calling party (current channel). The specified channel does not hear the calling party. The current channel does not hear voice responses on the specified channel.
The first type.src argument is a valid channel number. The second type.src argument is either 1 to add the specified channel or 0 (zero) to drop the channel. Values for the channel numbers and the add/drop flag follow the conventions for all type.src arguments.
If the hbridge instruction is not successful, a negative value is returned to r.0. The following are conditions under which the hbridge instruction may fail:
hundsec(type.dst)
The hundsec() instruction loads the integer type.dst with the system time in hundredths of a second.
Note:
Do not use the hundsec instruction in a loop to insert delays in script execution. Use the sleep or nap instructions instead.
trace(type.src [, type.src ])
The trace script instruction works with the /vs/bin/trace command to monitor the progress of scripts. This capability is useful in debugging and troubleshooting scripts, either during initial application development or if problems rise while the application is running. The trace instruction enables TSM to print messages to the shared memory area for trace messages. These messages can include the default trace messages for TSM or a specific channel.
Note:
If there are too many traces running simultaneously on a system, the buffer in which this information is stored may be filled and some data lost, with no notice of this in the trace output.
The first argument is evaluated as a number and is used as a step identifier. The optional argument can be used to print a specific data value of interest. The optional argument may be any integer type, or a null terminated character string.
In the following example, 25001 and int.F_TEMP are traced.
trace (25001, int.F_TEMP)
When the example trace statement above is run, the statement appears as step 25001 in the trace and the content of F_TEMP is displayed.