Abstract:
ATM cells for use in a cell relay network are assembled by creating a template data structure representing the structure of a cell to be assembled, storing the template data structure in memory, and creating cells by retrieving the template data structures and inserting variable information therein.

Description:
BACKGROUND OF THE INVENTION  
         [0001]    1. Field of the Invention  
           [0002]    This invention relates to cell relay networks, such as ATM (Asynchronous Transfer Mode) networks, and more particularly to a method and device for constructing cells for transmission over such a network.  
           [0003]    2. Description of the Prior Art  
           [0004]    In a cell relay network, such as ATM, the data is assembled in to fixed size cells which are transferred over the network in accordance with information stored in the cell header. In case of ATM cells are 53 bytes in length with five bytes reserved for the header.  
           [0005]    The cells are assembled by the ATM Adaptation Layer (AAL). Various layers, numbered from 1 to 5, offer different types of service. For example, AAL 1 relates to a service that offers constant bit rate traffic, such as voice or video traffic. In the prior art, cells must be custom assembled before being passed to a UTOPIA interface for connection to the physical layer. However, this process can be unnecessarily slow because much of the information contained in the headers does not change from cell to cell.  
         SUMMARY OF THE INVENTION  
         [0006]    The invention provides a method of assembling cells using predefined templates with variable fields to improve the efficiency of the reassembly process.  
           [0007]    According to the present invention there is provided a method of assembling cells for use in a cell relay network, comprising the steps of creating a template data structure representing the structure of a cell to be assembled, storing said template data structure in memory, and creating cells by retrieving said template data structures and inserting variable information therein.  
           [0008]    The cell template data structures (CTDS) are typically used in an ATM Adaptation Layer type 1 (AAL1) to produce ATM cells. CTDS allow the functions of an AAL type 1 , as defined in of ITU-T COM 13-R 51-E AAL, to be implemented. CTDS can also be used in implementations which support Circuit Emulation Service (CES) as described in ATM Forum Specification af-vtoa-0078.00 and Dynamic Structure Sizing (DSS) as defined in ATM Forum Specification af-vtoa-0085.00.  
           [0009]    A CTDS contains information which is required to construct cells for a virtual circuit (VC). The CTDS typically resides in a memory device such as RAM or registers and is preferably be created by software running on a central processing unit (CPU). The Segmentation portion of the SAR (Segmentation and reassembly) sublayer of an AAL1 Layer can use the information contained in the CTDS to produce cells for a VC. A separate CTDS is used for each VC being supported by the SAR.  
           [0010]    CTDSs may be used to support CBR Cells, such as UDT (Unstructured Data Transfer) Cells, SDT (Structured Data Transfer) Cells with and without CES, and DSS (Dynamic Structure Sizing) Cells with and without CES.  
           [0011]    The cell templates are normally located in memory. A pointer table is used for this purpose. There is a separate pointer for each VC and, possibly, a separate pointer table for each port.  
           [0012]    In a preferred implementation, the UDT Cell Template structure consists of 5 fields each of which are 16 bits wide. Fields  1 - 3  Contain the cell header and remain static after being written by the CPU. Field  0  holds the sequence number of the next cell and SRTS information. The segmentation system modifies this field after each cell is produced.  
           [0013]    In the SDT Cell Template, fields  0 - 6  may be used to determine when to produce the cell, control the number of channels being sent in the VC, hold SRTS data, determine when to produce a pointer cell, determine the value of the offset field of a pointer cell, calculate the AAL1 Header byte, determine when to place CAS values in the cell, and determine the location of the next TDM/CAS value to be placed in the cell  
           [0014]    Fields  7 - 9  contain cell header information  
           [0015]    The remaining fields of the control structure contain pointers to circular buffers (1 pointer for every channel in the VC) which contain TDM data. The pointers are read in a round robin fashion and are used to control which channels are to be placed into the cell payload.  
           [0016]    In one preferred embodiment of the invention, the SDT DBCES (Structured Data Cell, Dynamic Bandwidth Circuit Emulation Service) template is typically divided into 3 major regions. The first (fields  0  to  5 ) contains information such as the cell header which does not change when the multiframe structure is re-sized.  
           [0017]    The Alpha and Beta regions of the structure contain the information which changes during a multiframe resize. If the Segmentation process is using the Alpha region to construct cells then the CPU may modify the contents of the Beta region and vice versa. The cr (current region) bit of field  0  is used by the CPU to determine which region may be modified.  
           [0018]    After the CPU has finished writing information to a region it will program the nr (next region) bit of field  0 . The cr bit will be set equal to the nr bit by the Segmentation process at the next structure boundary after the next valid pointer and the new multiframe structure will then be sent. 
       
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0019]    The invention will now be described in more detail, by way of example, only with reference to the accompanying drawings, in which:  
         [0020]    [0020]FIG. 1 is a system level view of a TXSAR module;  
         [0021]    [0021]FIG. 2 is a block diagram of a TxSAR block and internal memory;  
         [0022]    [0022]FIG. 3 shows a data cell control structure;  
         [0023]    [0023]FIG. 4 shows the TxSAR control structure;  
         [0024]    [0024]FIG. 5 shows the control structure pointer table for port X;  
         [0025]    [0025]FIG. 6 shows the TxSAR control structure for SDT non DBCES mode;  
         [0026]    [0026]FIG. 7 shows how the read_pointer is used to access circular buffers; and  
         [0027]    [0027]FIG. 8 shows the DBCES control structure. 
     
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS  
       [0028]    Referring now to FIG. 1, a TxSARs (Transmit Segmentation and Reassembly module) includes a TxSAR block  1 , which outputs ATM cells to a UTOPIA interface  2  and is connected over a bidirectional link to a control structure memory  3 . The TxSAR block  1  receives data from UDT buffer unit  5 , circular buffer unit  6 , and SRTS unit  7 .  
         [0029]    The memory  3 , as shown in FIG. 2, is a 1056×16 block of internal RAM memory, which in turn is connected to a microprocessor block  8 . The memory  3  contains a control structure for each VCC of the TDM port and is used in the cell assembly process. The format of the control structure depends on the mode of operation (UDT, SDT (non DBCES), SDT (DBCES)). The control structures are discussed below.  
         [0030]    The data TX_SAR control structure is shown in FIG. 3. The Base Address of the TxDataCell FIFO in external memory is selected in the Data TX_SAR configuration register ( 1038 ). This register is also used to select the size of the cell fifo. Cells must begin on 64 byte boundaries as illustrated in FIG. 3.  
         [0031]    Cell transmission begins when the write pointer is set to the top of the FIFO and the Data TX_SAR is enabled via a TDSEN bit in register  103 E. The cells in the FIFO will be sent in order starting with the lowest memory address. After each cell is produced the Data TX_SAR increments a read_pointer and cell transmission will cease when the read pointer is equal to the write pointer. If the write pointer is set to be higher then the size of the fifo the Data TX_SAR will continuously send the contents of the FIFO.  
         [0032]    The same memory is used for both SDT and UDT. In the UDT mode, however, only the lower five locations of the memory are used. FIG. 4 shows the format of the control structure for one of 28 TDM ports feeding the TX_SAR.  
         [0033]    Each of the fields of the control structure are described in detail as follows:  
         [0034]    Field  0   
         [0035]    reserved (bits  15 : 8 ):  
         [0036]    These bits are reserved for future revisions of the chip and are initialized to 0  
         [0037]    srts (bits  7 : 4 ):  
         [0038]    If the srts_enable (se) bit of the control structure is set to one then the TxSAR will read an srts nibble from the Clock Management block at the beginning of each cell sequence (sequence=b#000). This value will be stored in the srts bits. In cells with odd sequence numbers the most significant srts bit will be placed into the csi bit of the SAR-PDU header. The SRTS value will then be shifted left and written back to the srts bits. In this way a complete SRTS nibble will be sent in each 8 cell sequence. srts enable (bit  3 ):  
         [0039]    The srts_enable (se) bit is used to indicate that the VCC is carrying SRTS data. When high the TxSAR will place SRTS data into the csi bit, of the SAR-PDU header, in cells with odd sequence values. When low the csi bit will always be set to zero.  
         [0040]    sequence(bits  2 : 0 ):  
         [0041]    These bits hold the sequence number of the next cell to be transmitted. The sequence bits should be initialized to b#000 by the cpu.  
         [0042]    Field  1   
         [0043]    gfc (bits  15 : 12 ):  
         [0044]    The gfc (Generic Flow Control) value is placed in the gfc field of the cell header in a UNI cell. If the associated cell is NNI these bits form the four most significant bits of the vpi.  
         [0045]    vpi (bits  11 : 4 ):  
         [0046]    The TxSAR will place this value into the vpi field of the cell header.  
         [0047]    vci (bits  3 : 0 ):  
         [0048]    The TxSAR will place this value into the vci field of the cell header.  
         [0049]    Field  2   
         [0050]    vci (bits  15 : 4 ):  
         [0051]    The TxSAR will place this value into the vci field of the cell header.  
         [0052]    pti (bits  3 : 1 ):  
         [0053]    The TxSAR will place this value into the pti field of the cell header.  
         [0054]    clp (bit  0 ):  
         [0055]    The TxSAR will place this value into the clp field of the cell header.  
         [0056]    Field  3   
         [0057]    hec (bits  15 : 8 ):  
         [0058]    The physical layer is generally responsible for calculating the hec value and therefore this field is normally used as a place holder. If the physical layer does not calculate hec then the contents of the hec field of the TxSAR control structure will appear in the hec field of the cell header. The user may generate this value by preforming a modulo 2 division on the first 4 octets of the cell header using the generator polynomial G(x)=x 8+x^ 2+x+1.  
         [0059]    udf (bits  7 : 0 ):  
         [0060]    This value is copied to the udf2 field of the cell header when the UTOPIA module is operating in 16 bit mode.  
         [0061]    Field  4   
         [0062]    Field  4  contains the number of cells that have been transmitted. The cpu should initialize this field to 0000h.  
         [0063]    Control Structure Pointer Table  
         [0064]    In the SDT DBCES and Non DBCES modes the TxSAR makes use of pointer tables to determine the location of each control structure in the internal memory  3 . Each port of the device which is in SDT mode has a pointer table associated with it. The base address of the pointer table, in internal memory, is programmed through the PX_PTB register shown in the table below.  
                                                 Port 0 Pointer Table Base Address       Address: 2002 (Hex)       Label: P0_PTB       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               PTBA   15:0   R/W   In SDT mode these bits hold the base address                   of the port 0 control structure pointer table.                   In UDT mode these bits form a pointer to the                   UDT control structure associated with port 0.                  
 
         [0065]    As shown in FIG. 5, the PX_PTB register contains the word address of the pointer table X base in internal memory. For example a value of 10h indicates that the base of the pointer table starts on the 16th word in internal memory (byte address 20h). The value in the PX_PTB represents an offset from the base address of the TxSAR internal memory in the Monaco chip.  
         [0066]    The following is a description of the fields of a pointer:  
         [0067]    L (Bit  15 ):  
         [0068]    A value of 1 in this bit indicates that the current pointer is the last valid pointer in the table and as a result the TxSAR will not read any further entries in the current table.  
         [0069]    A (Bit  14 ):  
         [0070]    A value of 1 in this bit indicates that the associated control structure is active. If this bit is set to 0 the TxSAR will not produce cells for the associated control structure.  
         [0071]    Control Structure Pointer (Bits  13 : 0 ):  
         [0072]    This is the address of a control structure expressed as a word offset from the base address of the TxSAR Internal memory.  
         [0073]    A detailed description of each field of the TxSAR control structure for non DBCES SDT mode follows with reference to FIG. 6.  
         [0074]    Field  0   
         [0075]    nmbr_of_tdm(15:10):  
         [0076]    This field indicates the number of TDM octets required to fill the next cell of the corresponding VCC. It is used by the TxSAR to determine when to create a cell for the VCC associated with the control structure. After each cell of the VCC is sent the TxSAR will determine the number of octets available for TDM in the next cell and update the nmbr_of_tdm field. This field must be initialized by the user as shown in the Table below.  
                                                                         TDM                   mode   nmbr_of_channels   nmbr_of_tdm value                                        DS1   1   45           DS1   2:24   46           E1   1   44           E1   2   45           E1   3:30   46           J2   1:96   46           STBUS   1:30   46                      
 
         [0077]    nmbr_of channels (9:2):  
         [0078]    The nmbr_of_channels (Number of Channels) bits indicate the number of TDM channels in the VCC associated with the control structure. The following table summarizes the range of possible values.  
                                                       Range of values in           TDM Type   nmbr_of_channels field                           DS1   1 to 24           E1   1 to 30           Back Plane Mode    1 to 128                      
 
         [0079]    remainder (bit  1 ):  
         [0080]    This bit indicates that there is enough TDM data to create more than 1 cell in the current frame. It should be initialized to 0.  
         [0081]    wait for multiframe (bit  0 ):  
         [0082]    When 1 the TxSAR will wait for the multiframe boundary before producing the first cell of the VCC. This will result in the first basic frame of the multiframe being sent in the first payload octet of the first cell (sequence=0, offset field=0). When 0 the first cell will be produced as soon as enough TDM data is available.  
         [0083]    Field  1   
         [0084]    read pointer (bits  15 : 10 ):  
         [0085]    The value in this field is concatenated with circular_buffer_base_ptrG to form an address within a circular bufferG as shown in FIG. 7. The read_pointer field will be incremented each time current_tdm=last_tdm. Initialize this field to 00h unused (bits  9 : 8 ):  
         [0086]    Reserved for future use. Initialize these bits to 0.  
         [0087]    first_cell (bit  7 )  
         [0088]    This bit should be initialized to 1 by the cpu It is used to indicate that this is the first cell to be sent for the current VCC.  
         [0089]    srts (bits  6 : 3 ):  
         [0090]    If the srts_enable (se) bit of the current VCC is set to one then the TxSAR will read an SRTS nibble from the Clock Management block at the beginning of each cell sequence (sequence =b#000). This value will be stored in the srts bits. In cells with odd sequence numbers the most significant bit of the SRTS value will be placed into the csi bit of the SAR-PDU header. The SRTS value will then be shifted left and written back. In this way a complete SRTS nibble will be sent in each 8 cell sequence. This field does not need to be initialized by the user.  
         [0091]    sequence (bits  2 : 0 ):  
         [0092]    The sequence bits hold the sequence number of the cell that is about to be assembled by the TxSAR. This value is used by the TxSAR to generate the SAR-PDU header and determine if the current cell is to be a P format cell. The sequence number of the next cell in the VCC is determined using the equation:  
         NextSequence        (   CurrentSequence   )       =                  CurrentSequence   +     1                 forCurrentSequence       &lt;   7                 0                 forCurrentSequence     =   7                                   
 
         [0093]    The next sequence number is written to the sequence bits of the TxSAR control structure after the current cell has been sent.  
         [0094]    Initialize sequence to 0h.  
         [0095]    Field  2   
         [0096]    structure_lngth(bits  15 : 4 ):  
         [0097]    The structure_lngth (Structure Length) field contains the length of the multiframe structure (payload substructure+signalling substructure). As an example:  
         [0098]    TDM type=DS1  
         [0099]    nmbr_of_channels=3  
         [0100]    structure_lngth=nmbr_of_channels×24+roundup(nmbr_of_channels/2)=74 octets  
         [0101]    The following table provides a summary of possible values.  
         [0102]    Value in the Structure Length field (nmbr_of_channels=#of channels in the VCC)  
                                           Value to be written to   Range of Structure       TDM Type   Structure Length field   Length value                   DS1 with CAS   24 × nmbr_of_channels +   25 to 3136           roundup(nmbr_of_channels/2)       E1 with CAS   16 × nmbr_of_channels +   17 to 2112           roundup(nmbr_of_channels/2)       DS1 without CAS   nmbr_of_channels   1 to 128       E1 without CAS   nmbr_of_channels   1 to 128                  
 
         [0103]    unused (bits  3 : 2 )  
         [0104]    Reserverd for future use. Initialize these bits to 0.  
         [0105]    mode (bits  1 : 0 )  
         [0106]    The TxSAR requires the mode bits to determine the number of TDM octets in a cell pay-load. They are used to indicate the TDM structure size relative to a cell payload and the TDM type being used. The meaning of the bits is given in the following table.  
                                                   Description of mode bits            Value of mode bits   Meaning                    00   CCS mode or DS1 with CAS number of channels &gt;           1 or E1 with CAS number of channels &gt; 2.       01   DS1 with CAS number of channels = 1       10   E1 with CAS number of channels = 1       11   E1 with CAS number of channels = 2                  
 
         [0107]    Field  3   
         [0108]    structure_boundary_ptr (bits  15 : 4 ):  
         [0109]    The structure_boundary_ptr (Structure Boundary Pointer) bits contain the distance, in ocets, between the last payload byte written and the next structure boundary. The TxSAR uses this value to keep track of its current position in the multiframe structure, determine when to send a P format cell and to generate the offset field of the SAR-PDU header. Initialize the structure_boundary_ptr field to h#0000.  
         [0110]    srst_enable (bit  3 ):  
         [0111]    The srts_enable (se) bit is used to indicate that the associated VCC is carrying SRTS data. When high the TxSAR will place SRTS data into the csi bit of the SAR-PDU header in cells with odd sequence values. When low the csi bit will be set to zero in cells with odd sequence values. Only one VCC/per link may carry SRTS.  
         [0112]    pointer_sent (bit  2 ):  
         [0113]    The pointer_sent (ps) bit is used to ensure that only a single P format cell is sent within an eight cell sequence. When the P format cell occurs this bit will be set high by the TxSAR. No further P format cells will be produced while ps=1. When the last cell of the sequence (sequence=b#111) is sent ps will be cleared so that another P format cell will be produced in the next cell sequence. The pointer_sent bit should be initialized to the value of the pointer_enable bit.  
         [0114]    pointer enable (bit  1 ):  
         [0115]    The pointer_enable (pe) bit should be set to zero in a single channel VCC which is not transporting CAS. This will prevent P format cells from being produced for the VCC. pe should be set to one in all other cases. This will cause the P format cell to be generated once per eight cell sequence.  
         [0116]    pointer_cell (bit  0 )  
         [0117]    After transmission of a cell the TxSAR will determine if the next cell of the VCC is to be a P format cell and will set the pointer cell (p) bit accordingly. When the time comes to create the next cell the SAR will place the SAR-PDU pointer field in the cell if p=1. This bit must be initialized to the value in the pointer_enable field.  
         [0118]    Field  4   
         [0119]    current_cas (bits  15 : 8 ):  
         [0120]    When the TxSAR is writing CAS data to the cell payload it will use this field to keep track of which circular buffer pointer to read next. Initialize this field to 0Ah.  
         [0121]    current_tdm (bits  7 : 0 ):  
         [0122]    When the TxSAR is writing TDM data to the cell payload it will use this field to keep track of which circular buffer pointer to read next. Initialize this field to 0Ah.  
         [0123]    Field  5   
         [0124]    last (bits  15 : 8 ):  
         [0125]    This field contains the address (relative to field  0 ) of the last valid circular_buffer_base_ptr in the control structure. In general  
         [0126]    last=nmbr_of_channels+9  
       EXAMPLE  
       [0127]    nmbr_of_channels=8  
         [0128]    last=11 h  
         [0129]    nmbr_of_cas (bits  7 : 0 ):  
         [0130]    The nmbr_of_cas (ncas) field contains the size, in octets, of the signalling substructure and should be initialized as shown in Table  
       EXAMPLE  
       [0131]    In the case of a DS 1 link with nine channels in the payload substructure. nmbr_of_cas=5.  
         [0132]    Possible nmbr_of_cas values. K=# of channels in the structure  
                                                       TDM mode   Formula   nmbr_of_cas Range                           DS1   roundup(K/2)   0 to 64           E1   roundup(K/2)   0 to 64           CCS mode   NA   0                      
 
         [0133]    Field  6   
         [0134]    cell_count_statistic (bits  15 : 0 ):  
         [0135]    The cell_count_statistic bits indicate the number of cell that have been produced for the VCC. Initialize these bits to 0000h.  
         [0136]    Header  1   
         [0137]    gfc (bits  15 : 12 ):  
         [0138]    The gfc (Generic Flow Control) value is placed in the gfc field of the cell header in a UNI cell. If the associated cell is NNI these bits form the four most significant bits of the vpi. vpi (bits  11 : 4 ):  
         [0139]    The TxSAR will place this value into the vpi field of the cell header.  
         [0140]    vci (bits  3 : 0 ):  
         [0141]    The TxSAR will place this value into the vci field of the cell header.  
         [0142]    1.0.16 Header  2   
         [0143]    vci (bits  15 : 4 ):  
         [0144]    The TxSAR will place this value into the vci field of the cell header.  
         [0145]    pti (bits  3 : 1 ):  
         [0146]    The TxSAR will place this value into the pti field of the cell header.  
         [0147]    clp (bit  0 ):  
         [0148]    The TxSAR will place this value into the clp field of the cell header.  
         [0149]    Header  3   
         [0150]    hec (bits  15 : 8 ):  
         [0151]    The physical layer is generally responsible for calculating the hec value and therefore this field is normally used as a place holder. If the physical layer does not calculate hec then the contents of the hec field of the TxSAR control structure will appear in the hec field of the cell header. The user may generate this value by preforming a modulo 2 division on the first 4 octets of the cell header using the generator polynomial G(x)=x 8+x^ 2+x+1.  
         [0152]    udf (bits  7 : 0 ):  
         [0153]    This field is copied to the udf2 field of the cell header when the UTOPIA module is operating in 16 bit mode.  
         [0154]    Circular Buffer Pointer Space circular_buffer_base_ptrX (bits  15 : 0 ):  
         [0155]    The Circular Buffer base pointers are concatenated with the read pointer bits to form the 22 bit address shown in FIG. 7. This value is used to address a TDM or CAS value in a particular circular buffer. There will be a pointer for each channel in the VCC.  
         [0156]    DBCES Control Structure  
         [0157]    The DBCES Control Structure is shown in FIG. 8.  
         [0158]    Field  0   
         [0159]    unused(Bits  15 : 6 ):  
         [0160]    These bits are reserved for future use and should be initialized to 0.  
         [0161]    first(Bit  5 )  
         [0162]    This bit shoud be set to 1 by the cpu when the control structure is initialized.  
         [0163]    number_of_bit_masks (Bits  4 : 2 )  
         [0164]    The following table indicates the number of masking octets in the bit mask substructure.  
         [0165]    meaning of nmbr_of_bit_mask bits  
                                   nmbr_of_bit_mask bits   Size of bit masking substructure                   001   1 octet       010   2 octets       011   3 octets       100   4 octets       all others   Invalid                  
 
         [0166]    next_region (Bit  1 ):  
         [0167]    This bit is used to re-size the multiframe structure and indicates the region of the control structure which will be used after the re-size occurs. When the time comes to re-size the structure the cpu should initialize the region of the control structure which is not being read by the TxSAR. The next region bit is then set cpu must wait for the next_region and current_region bits to contain the same value. It may then set the next_region bit  
         [0168]    next_region bit definition  
                                             next_region   control structure region used after re-size                                0   Alpha region       1   Beta region                  
 
         [0169]    current_region (Bit  0 ):  
         [0170]    This bit indicates the region of the control structure that the TxSAR is currently using to construct cells refer to the following table. To re-size the structure the cpu should write in the region which is not being used to assemble cells. Initialize this bit to 0.  
         [0171]    current_region bit definition  
                                                         control structure region   region available for the       current_region   currently being used   cpu to write                                0   Alpha region   Beta region       1   Beta region   Alpha region                  
 
         [0172]    Field  1  cell_count_statistic  
         [0173]    This field contains the number of cells which have been currently sent. It should be initialized to 0000h.  
         [0174]    Field  2   
         [0175]    time_out (Bits  15 : 12 ):  
         [0176]    These bits are used to control the time between the transmission of cells which are transporting inactive structures. The time between cells is determined as follows:  
         [0177]    inactive_structure_timer (11:0):  
         [0178]    These bits are used to determine if it is time to send a cell which is carrying an inactive structure. The cpu should initialize this value to 000 h.  
         [0179]    Cell Header Fields  
         [0180]    These fields are placed into the cell header  
         [0181]    Field  6  Alpha and Beta regions  
         [0182]    nmbr_of_tdm (Bits  15 : 10 ):  
         [0183]    This value is represents the number of octets in the next cell which are available fro transporting TDM. Initialize this value according to the following table.  
         [0184]    Initialization of nmbr_of_tdm bits  
                                                                 multi frame configuration   nmbr_of_tdm                                        DS1 with CAS nmbr_of_channels = 1   45           E1 with CAS nmbr_of_channels = 1   44           E1 with CAS nmbr_of_channels = 2   45           all other configurations   46                      
 
         [0185]    nmbr_of_channels (Bits  9 : 2 ):  
         [0186]    The nmbr_of_channels value indicates the number of TDM channels in the VCC associated with the control structure and may contain a value of 0 to 31 inclusive.  
         [0187]    structure_boundary_in_next_cell (Bit  1 ):  
         [0188]    This bit indicates that the structure boundary will occur in the next cell. Initialize this value to 1.  
         [0189]    unused (Bit  0 ):  
         [0190]    This bit is reserved for future use and should be initialized to 0.  
         [0191]    Field  7  Alpha and Beta Regions  
         [0192]    read_pointer (Bits  15 : 10 ):  
         [0193]    This value is concatenated with the circular buffer pointer to form an address to a TDM/CAS value in a circular buffer. In the case of many N=1 VCCs these bits may be used to distribute cell production over 64 frames.  
         [0194]    current_bit_mask (Bits  9 : 3 ):  
         [0195]    This is a pointer to the next bit mask to be sent. Initialize this value according the following table.  
         [0196]    Initialization of current_bit_mask  
                                                   Control Structure Region   current_bit_mask initialization value                           Alpha   2Ch           Beta   56h                      
 
         [0197]    sequence (Bits  2 : 0 ):  
         [0198]    These bits hold the sequence number of the next cell. Initialize this value to 0h.  
         [0199]    Field  8  Alpha and Beta Regions  
         [0200]    structure_length (Bits  15 : 3 ):  
         [0201]    This value represents the length of the multiframe structure and should be initialized as follows:  
         [0202]    Initialization of structure_length value  
                                           Value to be written to Structure   Range of Structure       TDM Type   Length field   Length value                   DS1 with CAS   24 × nmbr_of_channels +   0 to 588           roundup(nmbr_of_channels/2)       E1 with CAS   16 x nmbr_of_channels +   0 to 495           roundup(nmbr_of_channels/2)       DS1 without CAS   nmbr_of_channels   0 to 31       E1 without CAS   nmbr_of_channels   0 to 31                  
 
         [0203]    unused (Bits  3 : 2 ):  
         [0204]    Reserved for future use. Initialize these bits to 0h.  
         [0205]    mode (Bits  1 : 0 ):  
         [0206]    Initialize these bits according to the following table.  
         [0207]    Initialization of mode bits  
                                                   Configuration   mode                           DS1 with CAS nmbr_of_channels =   01b           1           E1 with CAS nmbr_of channels =   10b           1           E1 with CAS nmbr_of_channels =   11b           2           all other conditions   00b                      
 
         [0208]    Field  9  Alpha and Beta regions structure_boundary_pointer (Bits  15 : 4 ):  
         [0209]    This pointer is used to keep track of the current location with in the multi-frame structure. Initialize this value to 000h.  
         [0210]    mask_pending (Bit  3 ):  
         [0211]    This bit indicates that a bit mask will occur within the next 94 octets. Initialize this bit to 1.  
         [0212]    pointer_sent (Bit  2 ):  
         [0213]    Indicates that a pointer was sent in the current cell sequence. Initialize this bit to 0.  
         [0214]    pointer_enable (Bit  1 ):  
         [0215]    Initialize this bit to 1.  
         [0216]    pointer_cell (Bit  0 ):  
         [0217]    This bit indicates that the next cell is a pointer cell. Initialize this bit to 1.  
         [0218]    Field  10  Alpha and Beta regions  
         [0219]    current_cas (Bits  15 : 8 ):  
         [0220]    This is a pointer to the next circular buffer from which CAS is to be read. Initialize this value according to the following table.  
         [0221]    Initialization of current_cas pointer  
                                                   Control Structure Region   current_bit_mask initialization value                           Alpha   0Dh           Beta   37h                      
 
         [0222]    current_tdm (Bits  7 : 0 ):  
         [0223]    This is a pointer to the next circular buffer from which TDM is to be read. Initialize this value according Table  
         [0224]    Initialization of current_tdm pointer  
                                                   Control Structure Region   current_bit_mask initialization value                           Alpha   0Dh           Beta   37h                      
 
         [0225]    Field  11  Alpha and Beta region  
         [0226]    last (Bits  15 : 8 ):  
         [0227]    This is a pointer to the last circular buffer pointer in the control structure. Initialize this pointer according to the following table.  
         [0228]    Initialization of last pointer  
                                                   Control Structure Region   current_bit_mask initialization value                           Alpha   nmbr_of_channels + 0Ah           Beta   nmbr_of_channels + 36h                      
 
         [0229]    nmbr_of_cas (Bits  7 : 0 ):  
         [0230]    This value represents the number of CAS octets in the multiframe structure. Initialize this value as shown in the following table.  
         [0231]    Initialization of the nmbr_of_cas value  
                                                   Configuration   nmbr_of_cas value                           CAS mode   roundup(nmbr_of_channels/2)           CCS mode   0                      
 
         [0232]    Field  12  Alpha and Beta regions  
         [0233]    unused (Bits  15 : 7 ):  
         [0234]    Reserved for future revisions. Initialize to 000h.  
         [0235]    last_bit_mask (6 bits):  
         [0236]    This is a pointer to the last bit mask in the control structure. Initialize this pointer according to the following table.  
         [0237]    Initialization of last bit mask pointer  
                                                   Control Structure Region   current_bit_mask initialization value                           Alpha   number of bit masks + 2Bh           Beta   number of bit masks + 55h                      
 
         [0238]    Circular buffer pointer space  
         [0239]    circular_buffer_base_ptrX (bits  15 : 0 ):  
         [0240]    The Circular Buffer base pointers are concatenated with the read_pointer bits to form the 22 bit address shown in FIG. 7. This value is used to address a TDM or CAS value in a particular circular buffer. There will be a pointer for each channel in the VCC.  
         [0241]    Bit mask space  
         [0242]    These values are placed into the bit masking octets of the cell. The contents of the field are set to conform with AF-VTOA-0085.000 July 1997. The values are written to the cell in order starting with field  44 .  
         [0243]    The TXSAR registers will now be listed.  
         [0244]    Port  0 TxSAR Operation Mode Register  
                                                     Address: 2000 (Hex)       Label: P0_TXOM       Reset Value: 0000 (Hex)                    Bit                   Label   Position   Type   Description                       TCFNG   1:0   R/W   TxSAR Configuration.                       00 TxSAR is disabled                       01 UDT mode                       10 SDT DBCES Mode                       11 SDT Non DBCES Mode           Reserved   15:2   R/O   Reserved. Always read                       “0000_0000_0000_00”.                      
 
         [0245]    Data TX_SAR Configuration Register  
                                                 Address: 2004 (Hex)       Label: TXCFGR       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               DTSIZE   1:0   R/W   Data TX_SAR cell buffer size selection.                   00-16 Cells                   01-32 Cells                   10-64 Cells                   11-128 Cells       DTBASE   10:2   R/W   Data TX_SAR Cell Buffer Base Address. These bits                   represent address bits 20:12 of the base address of                   the cell buffer in external memory.       Reserved   15:11   R/O   Always read “0000_0”                  
 
         [0246]    Data TX_SAR Write Pointer  
                                                 Address: 2006 (Hex)       Label: DTWPR       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               DTWP    7:0   R/W   Data TX_SAR Write Pointer.                   Indicates the cell structure number in which                   the cpu is currently writing (the cell                   is not yet valid).       Reserved   15:8   R/O   Always read “0000_0000”                  
 
         [0247]    Data TX_SAR Read Pointer  
                                                 Address: 2008 (Hex)       Label: DTRPR       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               DTWP    6:0   R/O   Data TX_SAR Read Pointer.                   Indicates the cell structure number in which                   the Data TX_SAR is currently reading.                   This pointer is cleared when the TDSEN bit                   in the Data TX_SAR control register is                   set to 0.       Reserved   15:7   R/O   Always read “0000_0000_0”                  
 
         [0248]    Data TX_SAR Control Register  
                                                 Address: 200A (Hex)       Label: DTCR       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               TDSEN   0   R/W   Data TX_SAR Enable. When 0                   the read pointer is reset to 0000_000 and no                   data cells are produced. When 1 the Data                   TX_SAR will send the cells in the                   cell buffer.       AUTO   1   R/W   When 1 the Data TX_SAR will produce                   cells when the CBR TX_SAR is not busy.                   When 0 the Data cell generation is controlled                   by the DCGTOR register.       FMTIE   2   R/W   Cell Buffer Empty Interrupt Enable.                   When 1 the Cell Buffer Empty interrupt will                   be asserted when the cell buffer is empty.                   When 0 this interrupt is masked.       Reserved   15:3   R/O   Always read “0000_0000_0000_0”                  
 
         [0249]    [0249]                                       TABLE 2                           Data Cell Generation Time Out Register            Address: 200C (Hex)       Label: DCGTOR       Reset Value: 0001 (Hex)                Bit               Label   Position   Type   Description               DCGP    9:0   R/W   These bits represent the time in mS between                   data cell transmission when the Data                   TX_SAR is in timer mode. A value of                   0000_0000_00 will disable data                   cell transmission.       Reserved   15:10   R/O   Always read “0000_00”                    
         [0250]    Data TX_SAR Status Register  
                                                 Address: 200E (Hex)       Label: DTSR       Reset Value: 0000 (Hex)                Bit               Label   Position   Type   Description               TBMT   0   R/O   Transmit Cell Buffer Empty. This bit                   is set when the read pointer is equal to the                   write pointer and indicates that all of                   the cells in the buffer have been sent.       Reserved   15:1   R/O   Always read “0000_0000_0000_000”                  
 
         [0251]    The use of the template data structure described considerably improves the efficiency of cell formation in a SAR device in ATM services.