OpenAutomation Knowledge Base


The scripting language contains similar syntax for setting and getting values of individual parameters of the chassis resources. Some parameters, like inter-frame gap, support both set and get; others, like physical port type, support only get; and a few, like injecting errors, support only set.

You change the value of a settable parameter using:

module/port parameter [index,…] value value …

Here, module and port are the numeric indices for a particular port (for chassis-level parameters neither of these are present, and for module-level parameters only module is present); parameter is one of the names specified later in this document in the reference sections; index is a possible sub-index of the parameter, for instance identifying a stream; and each value specifies a value appropriate for the particular parameter. All indices start at zero.

Values are specified using one of the following formats:

  • Integer (I): decimal integer, in the 32-bit range, e.g.: 1234567.
  • Long (L): decimal integer, in the 64-bit range, e.g.: 123456789123.
  • Byte (B): decimal integer, in the 8-bit range, e.g.: 123.
  • Hex (H): two hexadecimal digits prefixed by 0x, e.g.: 0xF7.
  • String (S): printable 7-bit ASCII characters enclosed in ”, e.g.: ”A string”. Characters with values outside the 32-126 range and the ” character itself are specified by their decimal value, outside the quotation marks and separated by commas, e.g.: ”A line”,13,10,” and the next line”.
  • Owner (O): a short string used to identify an owner, used for the reservation.
  • Address (A): a dot-separated IP address, e.g.:

Some parameters allow a variable number of values of a particular type (I*, B*, H*), and these are simply written with spaces in between. For hex values (H*), multiple bytes can be specified using a single0x prefix, e.g.: 0xF700ABCD2233.

Finally, certain parameters are actually integers, but use coded names for special numeric values to enhance readability, e.g.: (0=OFF,1=ON).

You query the current value of a gettable parameter using a very similar syntax:

module/port parameter [index,…] ?

The chassis responds with a line using identical syntax to the change-command, containing the current values. These responses can, therefore, be ‘replayed’ back to the chassis to re-establish the value from a previous query. This is actually the core of the load/save mechanism of the XenaManager, as you can see by using an ordinary text editor to inspect the local files produced by saving. You can also change the content if you want to; it is not interpreted by the XenaManager.

Note that some queries, like P_INFO ? and P_CONFIG ?, are special in that they do not refer to one particular parameter, but rather to a collection of parameters. The response is multiple lines containing the current value of each of these parameters.