4.0 Defining a TCS file


4.1 What is a TCS file?

4.2 Creating a New TCS file in TL1 Message Builder

4.3 Creating an Input Message

4.3.1 Adding a Verb

4.3.2 Adding Modifier1

4.3.3 Adding Modifier2

4.3.4 Adding Staging Parameter Block

4.3.5 Adding Message Payload Block

4.3.6 Adding Response Block

4.4 Creating an Autonomous Message

4.4.1 Adding a Verb

4.4.2 Adding Modifier1

4.4.3 Adding Modifier2

4.4.4 Adding Response Block

4.5 Saving the created TCS file


 

4.1 What is a TCS file?

 

TL1 Command Set file contains input message ,output message, and autonomous message definitions, which are to be implemented in the agent for managing an NE. The input message and the autonomous message definitions are stored  in XML format in TCS file.

 

Defining a TL1 Command Set (TCS) file is the first step toward building a TL1 Agent. The TCS is the source for TL1Compiler for generating code for the TL1 Agent for instrumentation, and also the TCS file  will be used in TL1Browser to query the agent. TCS file can be created using the TL1 MessageBuilder provided with the toolkit. TL1 Message builder helps to define input message, output message,  and autonomous message as per GR831 specification.

In this chapter, you learn how to create a new TCS file with two TL1 Messages - one an input message and the other an autonomous message.

 

4.2 Creating a New TCS File in TL1 Message Builder

 

Follow the steps given below to create a new file in the TL1 MessageBuilder.

  1. Open the TL1 MessageBuilder from the <Agent Toolkit Home>/bin directory using the TL1MessageBuilder.bat/sh file. You can also open it from the Launcher.

  2. Choose New option from the File Menu.

  3. Choose Command Set Editor from the dialog box.

  4. Enter the filename and the name of the directory where you would like to save the TCS file and select OK.

Now, you will see the Parent Node (your TCS file name) added under the TL1 Tree in the left frame.

 

Now, you can start adding the commands for the TCS file as explained in the following sections.

 

Note: You can also load any existing TCS file and modify it from the TL1 MessageBuilder.  Choose Load option from the File Menu to load an already existing TCS file.

 

4.3 Creating an Input Message

 

This section explains you how to add a new input message to the TCS file. Let us consider an example where the data in the memory between two given addresses is to be read. The syntax of the command is as follows:

 

Syntax: RD-MEM-DATA:<TID>:MemDevType:<CTag>:<General Block>:StartAddr, EndAddr;

 

Refer to TL1 basics for details about the input message syntax.

 

Here RD-MEM-DATA is the command code and MemDevType is the Access Identifier (AID) of the device, which is to be accessed for reading the memory details. MemDevType can either be ROM or RAM. RD is the Verb, MEM is the Modifier1, and DATA is the Modifier2 in the command code. The following sections will teach you to add the above command and its parameters in the TCS file using the TL1 MessageBuilder.

 

4.3.1 Adding a Verb

 

Verb identifies the action to be taken at the NE on receiving a TL-1 message from an OS. To add the Verb "RD" for the input message, follow the steps given below.

After entering the above details, click the OK button. Now the Verb will be added successfully to the TCS file tree.

4.3.2 Adding Modifier1

 

The first Modifier identifies where the action is to be applied in the NE. To add the Modifier1 "MEM" for the input message, follow the steps given below. MEM is the memory from which the data is to be read and sent to the TL1 Manager.

    1. Right-click on the VERB "RD" in the TCS file tree for which Modifier1 has to be added.

    2. Choose "Add Modifier1" from the pop-up menu. The wizard interface for Modifier1 opens in the right frame.

    3. Enter the following details:

4.3.3 Adding Modifier2                        

  

The second modifier may be used to further define the identity of the object upon which the action is to be taken. Modifier Data is the actual data that is to be read from the memory device. To add the Modifier2 "DATA" for the input message, follow the steps given below.

  1. Right-click on the Modifier1 "MEM" in the TCS file tree for which Modifier2 has to be added.

  2. Choose "Add Modifier2" from the pop-up menu. The wizard interface for Modifier2 opens in the right frame.

  3. Enter the following details:

Adding AID, MPB, Resp Block, and description  for the input message are dealt with in the next three sections.

 

4.3.4 Adding Staging Parameter Block

 

Access Identifier Block(AID): AID is used to uniquely identify the entity, within the target NE, to be acted upon by the input message to the NE. In this example, The data can be read from either of the two memory devices ROM or RAM. Hence, we can name the AID as "MemDevType".

Follow the steps given below to add the parameter MemDevType in the AID Block.

    1. Click the "..." button next to the AID Block.

    2. Enter the first parameter Name of the Response Block as "MemDevType".

    3. Choose parameter Type as "String".

    4. Choose Seperator as " "(An empty space).

    5. After entering the above details, click the "Add" button.You will find the new parameter added to the AID Block. 

    6. Click the OK button to finish adding the AID block.

4.3.5 Adding Message Payload Block

 

Message Payload Block indicates the subject matter of the message. In this example, we will be entering the starting address and the ending address of the memory, between which we will be requiring the data to read from, in the Message Payload Block. Hence, the Message Payload Block Parameters are "StartAddr" and "EndAddr". Follow the steps given below to add the parameters to the Message Payload Block.

    1. Click the "..." button next to the Message Payload Block.

    2. Click Add Block button.

    3. Enter the first parameter Name of the Response Block as "StartAddr".

    4. Choose parameter Type as "Integer".

    5. Select EQ_VAL as "false". If true is selected , the parameter should be given as name=value in input message.

    6. Click the "Add" button.

You will find the new parameter added to the Message Payload Block. The other parameter

"EndAddr" can be added to the Message Payload Block in a similar manner.

 

4.3.6 Adding Response Block

 

When RD-MEM-DATA command is sent to the TL1 Agent, the Agent must respond with the data between the given memory address for the device given in the AID block. Hence, the response block has to be defined. The response block has the following information.

The syntax of the response is as follows:

      <cr><lf><lf> 

      ^^^<rsphdr><cr><lf> 

      M^^<ctag>^COMPLD<cr><lf> 

      ^^^"<addr>,<memdata>"<cr><lf> 

      ;

       

      Note: ^ represents Blank Space

Following are the steps involved in adding the Response Block.

    1. Click the "..." button next to the Response block.

    2. Choose response type as Quote and click on  Add Block.

    3. Enter the first parameter Name of the Response Block as "addr".

    4. Choose parameter Type as "String".

    5. Select EQ_VAL as "True". If true is selected, the response will be displayed in Name=Value format. 

    6. Choose Delimiter as ",". This will enable more parameters to be added to the Response Block.

    7. Click the "Add" button.

You will find the new parameter added to the Response Block. The other parameter "memdata" can be added to the Response Block in a similar manner.

 

After entering all the above explained details for Verb, Modifier1, and Modifier2, click the OK button. The new command code will be created successfully in the TCS file.

 

4.4 Creating an Autonomous Message

 

This section explains how to add an Autonomous Message to the TCS file. Let us consider an example where an alarm message will be sent by the NE/NS to the Agent, indicating the administrator the occurrence of a particular event.

 

The syntax of the autonomous message is as follows:

 

<cr><lf><lf> 

^^^<rsphdr><cr><lf> 

<almcode>^<atag>^REPT^ALM^SECU<cr><lf> 

^^^"<AID>,<NOTICODE>,<SECUALMTYPE>"<cr><lf> 

 

Here, REPT-ALM-SECU is the autonomous message code. REPT is the Verb that reports the event, ALM is the Modifier1 indicating that an Alarm is being sent, and SECU is the Modifier2 in the command code that stands for security. The following sections will teach you to add the above command and its parameters in the TCS file using the TL1 MessageBuilder.

 

4.4.1 Adding a Verb

 

To add the Verb "REPT" for the Autonomous Message, follow the steps given below.

    1. Select the Parent Node (Your TCS filename) under the TL1 Tree in the left frame of the tool.

    2. Right-click and choose the Add Verb Option.

    3. The wizard interface for verb will be opened on the right frame. 

    4. Enter the following details:

After entering the above details, click the OK button. Now, the Verb will be added successfully to the TCS file tree.

      Note: For this Command,  we shall define the Response Block and description in Modifier1. Response Block is to be defined only when Command Code option is selected as Yes.

4.4.2 Adding Modifier1

 

To add the Modifier1 "ALM" for the autonomous message, follow the steps given below.

4.4.3 Adding Modifier2

 

To add the Modifier2 "SECU" for the Autonomous Message, follow the steps given below.

    1. Right-click on the Modifier1 "ALM" in the TCS file tree for which Modifier2 has to be added.

    2. Choose "Add Modifier2" from the pop-up menu. The wizard interface for Modifier1 opens in the right frame.

    3. Enter the following details:

Adding Response Block for the autonomous  message is dealt with in the following section.

 

4.4.4 Adding Response Block

 

The response block has the following information.

Following are the steps involved in adding the Response Block

    1. Click the "..." button next to the Response block

    2. Choose response type as Quote and click Add Block. >

    3. Enter the first parameter Name of the Response Block as "SECUALMTYPE".

    4. Choose parameter Type as "String".

    5. Select EQ_VAL as "True". If true is selected the response will be displayed in Name=Value format.

    6. Choose <span style="font-weight: bold;">Delimiter as ",". This will enable more parameters to be added to the Response Block.

    7. After entering the above details, click the "Add" button.

You will find the new parameter added to the Response Block. The other parameters AID and NOTICODE  can be added to the Response Block in a similar manner.

 

After entering all the above explained details for Verb, Modifier1, and Modifier2, click the OK button. The new autonomous message will be created successfully in the TCS file.

 

4.5 Saving the Created TCS File

 

After adding the two command codes: one Input message and one Autonomous message, save the file using the File>>Save option in the Menu Bar or press CNTRL+S. The New TCS file is created and can be used in the TL1 Compiler for code generation and compilation as explained in the next topics.

 




Copyright © 2009, ZOHO Corp. All Rights Reserved.