Abstract:
The present invention provides a transmission device performing prescribed processing on signals of a plurality of channels and transmitting the signals of the plurality of channels, comprising: a first storage unit for storing, in different memory cells for each channel, first control data in which one or more types of control data elements for each channel are configured as at least one word data; a first data structure conversion unit for selecting control data elements of the same type from said first control data of the plurality of channels stored in said first storage unit, and converting the structure of said first control data such that the control data elements of the same type are configured as one word data; and a data generation unit for processing, in word units, said first control data after conversion by said first data structure conversion unit, and generating second control data necessary for said prescribed processing.

Description:
BACKGROUND OF THE INVENTION  
         [0001]    1. Field of the Invention  
           [0002]    The present invention relates to a transmission device which performs prescribed processing of signals in a plurality of channels, and transmits signals in the plurality of channels, and a data processing method and data conversion method in this transmission device. The present invention further relates to a program product to cause a computer to execute data processing and data conversion in a transmission device which performs prescribed processing of signals in a plurality of channels, and transmits signals in the plurality of channels.  
           [0003]    2. Description of the Related Art  
           [0004]    In a communication system, devices in which realtime processing is required conventionally are generally realized through dedicated hardware circuits in order to perform high-speed processing. For example, line switching control units in bi-directional line switched ring (BLSR) systems using the SONET/SDH (Synchronous Optical Network/Synchronous Digital Hierarchy) transmission method are required to perform realtime processing, and so conventionally have been realized using dedicated hardware circuits.  
           [0005]    [0005]FIG. 21A is a block diagram showing the configuration of a BLSR system using the SONET/SDH transmission method. This BLSR system has, for example, six nodes, n 1  to n 6 , in a 4BLSR system in which four optical fibers (cores) are connected between each node. Of the four fibers, two are used as work lines (Work), and the remaining two are used as protection lines (PTCT). One of the work lines and one of the protection lines are used to transmit optical signals in the clockwise direction; the remaining lines are used to transmit optical signals in the counterclockwise direction.  
           [0006]    A plurality of channels are multiplexed using time slots (time-division multiplexing) and transmitted in one optical fiber. For example, in the case of OC (Optical Carrier)-48, channels ch 1  to ch 48  are multiplexed; in the case of OC-192, channels ch 1  to ch 192  are multiplexed.  
           [0007]    In the state in which there are no faults in any optical fibers or nodes (the normal state), signals (the main signal) are transmitted in the work line. However, when a fault occurs in an optical fiber or in a node, switching processing is executed by an APS (Automatic Protection Switching) protocol, and the main signal is transmitted in the protection line. Specifically, according to the circumstances of the fault, a span-switch and span-bridge, or a ring-switch and ring-bridge, are executed at the node.  
           [0008]    [0008]FIG. 21B shows switching processing for the case in which a fault has occurred in the four optical fibers between nodes n 2  and n 3  in the BLSR system of FIG. 21A. When a fault occurs between nodes n 2  and n 3 , a loop-back (a ring-switch and ring-bridge in each of the east side in node n 2  and the west side in node n 3 ) is executed by the APS protocol, in an attempt to salvage the main signal.  
           [0009]    Though not shown in the figure, if a fault occurs only in the work line between nodes n 2  and n 3 , instead of a loop-back, a span-switch and span-bridge are executed in which the main signal of the work line between nodes n 2  and n 3  is switched to the protection line in the same direction between nodes n 2  and n 3 , in an attempt to salvage the main signal. For example, if a fault occurs in the work line from node n 2  to node n 3 , a span-bridge is executed on the east side of node n 2 , and the main signal is transmitted via the protection line to node n 3 . And, a span-switch is executed on the west side of node n 3 , to return the main signal input from the protection line to the work line side.  
           [0010]    Such switching processing in the nodes by the APS protocol is executed by a line switching control unit provided at each node. FIG. 22 is a block diagram showing in summary the configuration of nodes n 1  to n 6  in a BLSR system.  
           [0011]    Each node has a host processor  1 ; a line switching control unit  200 ; a span-switch unit  3 ; a ring-switch unit  4 ; a span-bridge unit  5 ; and a ring-bridge unit  6 . The span-switch unit  3  has selection circuits  31  and  32 , and AIS (Alarm Indicated Signal) insertion circuits  33  and  34 . The ring-switch unit  4  has selection circuits  41  and  42 ; the span-bridge unit  5  has selection circuits  51  and  52 ; and the ring-bridge unit  6  has selection circuits  61  and  62 .  
           [0012]    Though not shown in the figure, within each node the main signal is processed as an electrical signal, so that at the input terminal, a photoelectric converter to convert optical signals input from the optical fiber into electrical signals is provided, and at the output terminal, a photoelectric converter to convert electrical signals into optical signals is provided. A switch unit to perform time slot switching (exchanging) is also provided.  
           [0013]    The host processor  1  manages node operation; holds information relating to faults according to the APS protocol which is communicated between nodes, information on the initial settings of the device, and other information; and sends this information as control data to the line switching control unit  200 .  
           [0014]    The line switching control unit  200  is configured from dedicated hardware circuitry. The line switching control unit  200  generates control signals to control each of the selection circuits and/or AIS insertion circuits of the span-switch unit  3  to the ring-bridge unit  6 , based on control data sent by the host processor  1 , and sends the control signals to these circuits.  
           [0015]    Based on these control signals, the selection circuits  31 ,  32 ,  41 ,  42 ,  51 ,  52 ,  61 , and  62  select and output one main signal from the two main signals input. The AIS insertion circuits  33  and  34  output an AIS based on control signals, and insert the AIS into the main signal. By this means, normal transmission/reception of main signals, as well as switching processing (ring-switch and ring-bridge, or span-switch and span-bridge processing) upon occurrence of a fault, are executed.  
           [0016]    For example, at the span switch and span bridge, the work line channels are switched with the protection line channels in the same direction, and an AIS is inserted into the protection line channels. At the ring switch and ring bridge, the work line channels are switched with the protection line channels in the opposite direction.  
           [0017]    However, when hardware circuitry is used to realize a line switching unit, it is necessary to redesign and remanufacture hardware each time there is a change in the recommended specifications of the ITU-T or similar, or a small-scale modification, addition, or functional upgrade of specifications. Consequently development time is lengthened, and costs are increased.  
           [0018]    On the other hand, rapid product development and shipment is also required. Hence there is a need to realize in software, rather than in hardware circuitry, the functions of a line switching control unit, which is required to perform realtime processing, and to develop an inexpensive device in a short period of time.  
           [0019]    [0019]FIG. 23 is a block diagram showing the conventional configuration of the line switching control unit  200  for the case in which processing by the line switching control unit  200  is realized in software. The line switching control unit  200  has a CPU (RISC processor)  201 ; memory (two-port RAM)  202  and  205 ; work memory (RAM)  203 ; instruction storage memory (ROM)  204 ; and parallel/serial converters (PS)  206   1  to  206   4 .  
           [0020]    The memory  202  stores control data sent from the host processor  1 . FIG. 24 shows control data stored in memory  202 .  
           [0021]    The control data sent from the host processor  1  is stored in memory cells in order from a prescribed address (here, address X). Each memory cell holds 32 bits. In the figure, the right end of each memory cell is the first (lowermost) bit, and the left end is the 32nd (uppermost) bit.  
           [0022]    Control data has line control data (A, B, C, D, X, Y), provided in a plurality of channel units (or ring units) (in FIG. 24, there are 24 channel units), and line setting data (channel setting data), provided for each channel.  
           [0023]    Line control data includes two bits of node fault data A (hereafter also called “BSC”); one bit of ring bridge trigger data B (hereafter also “BR”); one bit of ring switch trigger data C (hereafter also “SW”); one bit of control data D for device testing (hereafter also “TESTcont”); one bit of span switch trigger data X (hereafter also “Spanswcont”); and one bit of span bridge trigger data Y (hereafter also “Spanbrcont”).  
           [0024]    In FIG. 24, the line control data is provided in 24 channel units. Specifically, one set of line control data is provided for channels ch 1  to ch 24 , directed from the west (input) side of the node toward the east (output) side (hereafter “east side”), and one set of line control data is provided for channels ch 1  to ch 24 , directed from the east (input) side of the node toward the west (output) side (hereafter “west side”).  
           [0025]    When there are twenty-five or more channels, a set of line control data is similarly provided for the 24 east-side channels ch 25  to ch 48 , and a set of line control data is provided for the 24 west-side channels ch 25  to ch 48 .  
           [0026]    The node fault data A (BSC) indicates that no fault has occurred when A=0, indicates occurrence of a fault at another node when A=1, indicates that a fault has occurred in the east-side channel of the node itself when A=2, and indicates that a fault has occurred in the west-side channel of the node itself when A=3.  
           [0027]    The ring-bridge trigger data B (BR) indicates that no ring bridge is to be executed when B=0, and that a ring bridge is to be executed when B=1. The ring-switch trigger data C (SW) indicates that no ring switch is to be executed when C=0, and that a ring switch is to be executed when C=1. The device testing control data D (TESTcont) indicates that device testing is not performed when D=0, and that device testing is performed when D=1.  
           [0028]    The span-switch trigger data X (Spanswcont) indicates that no span switch is to be executed when X=0, and that a span switch is to be executed when X=1. The span-bridge trigger data Y (Spanbrcont) indicates that no span bridge is to be executed when Y=0, and that a span bridge is to be executed when Y=1.  
           [0029]    Line setting data includes, as control data elements, one-bit NUT channel (channel which does not perform salvaging by means of the BLSR) setting data E (hereafter also called simply “NUT”); one-bit submarine switch control data F (hereafter also “SubmarineSW”); one-bit ring-switch control data G for device testing (hereafter also “RingSWcont”); one-bit submarine bridge control data S (hereafter also “SubmarineBR”); and one-bit ring-bridge control data T for device testing (hereafter also “RingBRcont”). These line setting data bits are provided for each channel.  
           [0030]    When the data bit E (NUT) is set to E=0, the corresponding channel is set to a channel which is salvaged by means of BLSR, and when set to E=1, the corresponding channel is set to a channel which is not salvaged by means of BLSR. When the data bit F (SubmarineSW) is set to F=0, submarine switching is not performed; when set to F=1, submarine switching is performed.  
           [0031]    When the data bit G (RingSWcont) is set to G=0, ring switching for device testing is not performed; when set to G=1, ring switching for device testing is performed. When the data bit S (SubmarineBR) is set to S=0, submarine bridging is not performed; when set to S=1, submarine bridging is performed. When the data bit T (RingBRcont) is set to T=0, ring bridging for device testing is not performed; when set to T=1, ring bridging for device testing is performed.  
           [0032]    This line control data and line setting data is converted into control signal data and stored in the memory  205 .  
           [0033]    As shown in FIG. 25, the control signal data includes, as data elements, ring-switch control data H (hereafter also “RingSW”); ring-bridge control data I (hereafter also “RingBR”); span-switch control data J (hereafter also “SpanSW”); and span-bridge control data K (hereafter also “SpanBR”). This control signal data is provided for the east side of each channel, and for the west side of each channel.  
           [0034]    The east-side ring-switch control data H is sent to the selection circuit  41  of the ring-switch unit  4 ; the west-side ring-switch control data H is sent to the selection circuit  42  of the ring-switch unit  4 . The selection circuits  41  and  42  select and output the main signal on the first input (work line) side when H=0, and select and output the main signal on the second input (protection line) side when H=1.  
           [0035]    The east-side ring-bridge control data I is sent to the selection circuit  61  of the ring-bridge unit  6 ; the west-side ring-bridge control data I is sent to the selection circuit  62  of the ring-bridge unit  6 . The selection circuits  61  and  62  select and output the main signal on the first input (work line) side when I=0, and select and output the main signal on the second input (protection line) side when I=1.  
           [0036]    The east-side span-switch control data J is sent to the selection circuit  31  and AIS insertion circuit  33  of the span-switch unit  3 ; the west-side span-switch control data J is sent to the selection circuit  32  and AIS insertion circuit  34  of the span-switch unit  3 . The selection circuits  31  and  32  select and output the main signal on the first input (work line) side when J=0, and select and output the main signal on the second input (protection line) side when J=1. The AIS insertion circuits  33  and  34  insert and output an AIS when J=1, and do not insert and output an AIS when J=0.  
           [0037]    The east-side span-bridge control data K is applied to the selection circuit  51  of the span-bridge unit  5 . The west-side span-bridge control data K is applied to the selection circuit  52  of the span-bridge unit  5 . The selection circuits  51  and  52  select and output the main signal on the first input (work line) side when K=0, and select and output the main signal on the second input (protection line) side when K=1.  
           [0038]    If processing to convert line control data and line setting data into control signal data H through K, which is conventionally executed in hardware, is replaced without modification by software processing, the software processing is described by the flowchart as shown in FIG. 26. This flowchart shows only the portion in which the east-side ring-switch control data H is generated. FIG. 27 is an example of a program, written in the C programming language and in the assembly language for a RISC processor, to perform the processing of this flowchart. This program is stored in the instruction storage memory  204 .  
           [0039]    The CPU  201  first initializes the variable i, used as an index to specify the channel number, to 1 (S 101 ), and then judges whether the NUT of channel chi is 0 or not (S 102 ).  
           [0040]    If the NUT of channel chi is not 0 (“N” in S 102 ), the CPU  201  sets RingSW (data H) for channel chi to 0 (S 109 ), and if the NUT of channel chi is 0 (“Y” in S 102 ), judges whether TESTcont is 0 or not (S 103 ).  
           [0041]    If TESTcont is not 0 (“N” in S 104 ), the CPU  201  sets RingSW to the value of RingSWcont (Silo), and if TESTcont is 0 (“Y” in S 104 ), judges whether SubmarineSW for channel chi is 0 or not (S 104 ).  
           [0042]    If SubmarineSW is not 0 (“N” in S 104 ), the CPU  201  sets RingSW to 1, and if SubmarineSW is 0 (“Y” in S 104 ), judges whether BSC is 2 (“10” in binary notation) and SW is 1 (S 105 ).  
           [0043]    If BSC is 2 and SW is 1 (“Y” in S 105 ), the CPU  201  sets RingSW to 1 (S 106 ), and otherwise (“N” in S 105 ) sets RingSW to 0 (S 112 ).  
           [0044]    Thereafter, the CPU  201  increments the variable i by 1, and generates the data H for the next channel (S 107 , S 108 ). This processing is repeated a number of times N equal to the number of channels (for example, N=24).  
           [0045]    In this way, if conventional hardware processing is realized in software without modification, processing in channel units is repeated for the number of channels accommodated, so that processing time is lengthened, and there is the problem that processing cannot be performed within the allowed time.  
           [0046]    For example, as shown in FIG. 27, when using instructions for a RISC processor, twenty-two steps per channel are required. Generation of a ring-bridge control signal I involves similar processing, and so the number of steps is approximately the same. Hence when executing a ring switch and ring bridge, the number of steps is approximately 44.  
           [0047]    In an OC-192 4BLSR system, processing for 768 channels must be performed, and so a total of 768×44=33792 steps are required.  
           [0048]    If the operating frequency of the CPU  201  is 100 MHz, and one clock cycle is required for execution of one step, then 33792×10 (nanoseconds)=338 (microseconds) is required.  
           [0049]    This is only one example of the time required for generation of ring-switch control data H and ring-bridge control data I; in actual processing, RIP (Ring Interworking on Protection) and other functions are realized, so that processing is more complicated, and still more steps are required.  
           [0050]    Consequently when realizing the functions of a line switching control unit  200  in software, there is the concern that the allowable time from the occurrence of a fault until the completion of switching (for example, 50 milliseconds) may be exceeded.  
           [0051]    In order to speed software processing, the CPU operating frequency may be raised, the CPU bandwidth (number of processed bits) may be increased, or a multiprocessor architecture may be adopted; however, these measures result in increased power consumption, and are not preferable in that they result in increases in hardware scale and costs.  
           [0052]    Hence there is a need to reduce the number of steps required for processing to generate the control signal data H, I and similar, to shorten the time required for processing.  
         SUMMARY OF THE INVENTION  
         [0053]    The present invention was devised in consideration of this, and has as an object reduction of the number of processes of data processing in the nodes and other transmission devices in a BLSR system.  
           [0054]    A transmission device according to the present invention is a transmission device for performing prescribed processing on signals of a plurality of channels and transmitting the signals of the plurality of channels, comprising: a first storage unit for storing first control data for the plurality of channels in different memory cells for each channel, each first control data for each channel having one or more types of first control data elements for each channel configured as at least one word data; a first data structure conversion unit for selecting first control data elements of the same type from said first control data stored in said first storage unit, and converting the structure of said first control data such that the first control data elements of the same type are configured as one word data; and a data generation unit for processing, in word units, said first control data converted by said first data structure conversion unit, and generating second control data necessary for said prescribed processing.  
           [0055]    A data processing method according to the present invention is a data processing method in a transmission device for performing prescribed processing of signals for a plurality of channels and transmitting signals over the plurality of channels, comprising steps of: storing first control data for the plurality of channels in different memory cells for each channel, each first control data for each channel having one or more types of control data elements for each channel configured as at least one word data; selecting control data elements of the same type from said first control data stored in said memory cells; converting the structure of said first control data such that the control data elements of the same type are configured as one word data; processing the first control data after said conversion in word units; and generating second control data necessary for said prescribed processing.  
           [0056]    A data conversion method according to the present invention is a data conversion method in a transmission device for performing prescribed processing of signals for a plurality of channels and transmitting the signals over the plurality of channels, comprising steps of: storing first control data for the plurality of channels in different memory cells for each channel, each first control data for each channel having one or more types of control data elements for each channel configured as at least one word data; selecting control data elements of the same type from said first control data stored in said storage cells; and converting the structure of said first control data such that the control data elements of the same type are configured in one word data.  
           [0057]    The program product according to the present invention causes the above data processing method or data conversion method to be executed by a computer.  
           [0058]    According to the present invention, from the first control data for the plurality of channels, the first control data elements of the same type are selected, and the selected first control data elements of the same type are converted to one word data. As a result, the one word data has the first control data elements of the same type for a plurality of channels. Hence even when the processing of the data generation unit is described by a program (software) which is executed by a central processing unit (CPU), the CPU can process the control data elements of the same type for a plurality of channels by one word data processing.  
           [0059]    By this means, the number of processes can be reduced, and the time required for processing can be shortened. Also, functions can be realized in software, so that a system which can flexibly accommodate specification changes can be developed at low cost and in a short period of time, while retaining processing performance. 
       
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0060]    [0060]FIG. 1 is a block diagram showing the configuration of a line switching control unit according to a first embodiment of the present invention;  
         [0061]    [0061]FIG. 2 is a block diagram showing the detailed configuration of the memory unit  21 ;  
         [0062]    [0062]FIG. 3 shows a flowchart describing data structure conversion processing;  
         [0063]    [0063]FIG. 4A shows data structures before rearrangement and after rearrangement;  
         [0064]    [0064]FIG. 4B shows an example of a program which generalizes data rearrangement;  
         [0065]    [0065]FIG. 5 shows an example of the line setting data after data structure conversion processing;  
         [0066]    [0066]FIG. 6 is a flowchart showing the flow of processing to generate the control signal data H;  
         [0067]    [0067]FIG. 7 is an example of a program written in the C language and an example of a program written in assembly language for a RISC processor, corresponding to the flowchart of FIG. 6;  
         [0068]    [0068]FIG. 8 is a flowchart showing the flow of processing to generate ring-bridge control data I;  
         [0069]    [0069]FIG. 9 is an example of a program in the C language corresponding to the flowchart of FIG. 8;  
         [0070]    [0070]FIG. 10 is a flowchart showing the flow of processing to generate span-switch control data J;  
         [0071]    [0071]FIG. 11 is an example of a program in the C language corresponding to the flowchart of FIG. 10;  
         [0072]    [0072]FIG. 12 is a flowchart showing the flow of processing to generate span-bridge control data K;  
         [0073]    [0073]FIG. 13 is an example of a program in the C language corresponding to the flowchart of FIG. 12;  
         [0074]    [0074]FIG. 14 shows control signal stored in memory  22 ;  
         [0075]    [0075]FIG. 15 is a flowchart showing the flow of processing to convert the control signal data shown in FIG. 14 into the control signal data structure shown in FIG. 25;  
         [0076]    [0076]FIG. 16 is a block diagram showing another configuration of the memory unit  21 ;  
         [0077]    [0077]FIG. 17 is a block diagram showing the configuration of the line switching control unit according to the fifth embodiment of the present invention;  
         [0078]    [0078]FIG. 18 is a block diagram showing the detailed configuration of the data structure conversion device;  
         [0079]    [0079]FIG. 19 is a block diagram showing in summary the configuration of a CPU which incorporates data structure conversion processing circuitry between a source register and a destination register;  
         [0080]    [0080]FIG. 20 is a block diagram showing the detailed configuration of the data structure conversion processing circuitry;  
         [0081]    [0081]FIG. 21A is a block diagram showing the configuration of a BLSR system using the SONET/SDH transmission method;  
         [0082]    [0082]FIG. 21B shows switching processing for the case in which a fault has occurred in the four optical fibers between nodes n 2  and n 3  in the BLSR system of FIG. 21A;  
         [0083]    [0083]FIG. 22 is a block diagram showing in summary the configuration of nodes n 1  to n 6  in a BLSR system;  
         [0084]    [0084]FIG. 23 is a block diagram showing the conventional configuration of the line switching control unit for the case in which processing by the line switching control unit is realized in software;  
         [0085]    [0085]FIG. 24 shows control data sent from the host processor;  
         [0086]    [0086]FIG. 25 shows control signal data;  
         [0087]    [0087]FIG. 26 is a flowchart showing the flow of processing to convert line control data and line setting data into control signal data; and  
         [0088]    [0088]FIG. 27 is an example of a program, written in the C programming language and in the assembly language for a RISC processor, to perform the processing of the flowchart shown in FIG. 26. 
     
    
     DESCRIPTION OF THE PREFERRED EMBODIMENTS  
       [0089]    First Embodiment  
         [0090]    [0090]FIG. 1 is a block diagram showing the configuration of a line switching control unit  2  according to a first embodiment of the present invention. As explained above, each node of a BLSR system has the line switching control unit  2 . The overall configuration of the BLSR system, and the general configuration of each node, are shown in the above-mentioned FIG. 21 and FIG. 22 respectively, and so explanations are omitted. The line switching control unit  200  in FIG. 22 is replaced by the line switching control unit  2 .  
         [0091]    This line switching control unit  2  has a CPU  20 ; a memory unit  21 ; a memory  22 ; a work memory  23 ; an instruction storage memory  24 ; and parallel/serial converters (PS)  25   1  to  25   4 .  
         [0092]    The CPU  20  is, for example, a RISC processor. In this embodiment, one word (the unit of information that can be processed (read, written, or operated on) at once) of the CPU  20  is 32 bits.  
         [0093]    The instruction storage memory  24  is, for example, ROM, and stores a program describing the processing of the line switching control unit  2  (including data structure conversion processing and control signal data generation processing, described below). The CPU  20  executes this program.  
         [0094]    The work memory  23  is RAM having, for example, 32 bits in the memory cells (one word) at each address. The work memory  23  stores intermediate data generated during processing of the CPU  20 . The intermediate data includes line control data sent from the host processor  1 , and the results of data structure conversion of line setting data (see FIG. 5, described below).  
         [0095]    The memory  22  is, for example, two-port RAM having 32 bits in the memory cells (1 word) at each address. CPU  20  writes control signal data (see FIG. 14, described below) to this memory  22  through one of the ports, and the control signal data is read from the other port, and sent to PS  25   1  to  25   4 .  
         [0096]    PS  25   1  to  25   4  (hereafter sometimes collectively called “PSs  25 ”) convert parallel data (for example, 32-bit data) sent from the memory  22  into serial data (bit streams), and output the serial data.  
         [0097]    PS  25   1  outputs to the span-switch unit  3  (see FIG. 22) east-side and west-side span-switch control data J. PS  25   2  outputs to the ring-switch unit  4  (see FIG. 22) east-side and west-side ring-switch control data H. PS  25   3  outputs to the span-bridge unit  5  (see FIG. 22) east-side and west-side span-bridge control data K. PS  25   4  outputs to the ring-bridge unit  6  (see FIG. 22) east-side and west-side ring-bridge control data I. The east-side and west-side data for each of the data items H through K is output by time division; first the east-side data is output, and then the west-side data is output.  
         [0098]    The memory unit  21  has the configuration shown in FIG. 2, having a memory  21   a , a delay element (delay)  21   b , a monitoring device  21   c , and a register  21   d.    
         [0099]    The memory  21   a  is, for example, two-port RAM having 32 bits in the memory cells (1 word) at each address, and stores line control data and line setting data provided by the host processor  1 . This line control data and line setting data stored in the memory  21   a  is the same as that shown in the above-mentioned FIG. 24, and so an explanation is here omitted. The address (in FIG. 24, address X and subsequent addresses) and bit positions at which the line control data and line setting data are stored are determined in advance.  
         [0100]    This line control data and line setting data is provided, together with the address in memory  21   a  (and a write-enable signal), to the delay element  21   b  and monitoring device  21   c  by the host processor  1 . The line control data and line setting data may be provided all at once (for example, when making initial settings (provisioning)), or only that data for channels which have changed may be provided (for example, when a fault occurs during operation).  
         [0101]    The delay element  21   b  outputs to the memory  21   a  the control data (line control data, line setting data) and address (and write-enable signal) after a prescribed time has passed. This prescribed time is the time until the end of reading of data from the memory  21   a  by the monitoring device  21   c , as described below; this may for example be the time of several clock cycles of the clock signal supplied to the CPU  20 .  
         [0102]    The memory  21   a  stores, in the memory cell specified by the address sent from the delay element  21   b , the control data (line control data or line setting data) provided by the delay element  21   b . As a result, the contents of memory cells of the memory  21   a  are updated.  
         [0103]    When the monitoring device  21   c  receives data and an address from the host processor  1 , it reads the data stored in the memory cell specified by the received address from the memory  21   a . As explained above, this reading is performed before the delay element  21   b  outputs (writes) to the memory  21   a  the data received from the host processor  1 . Hence data read by the monitoring device  21   c  from the memory  21   a  is data prior to updating (replacement) by the memory  21   a  with data provided by the host processor  1 .  
         [0104]    The monitoring device  21   c  compares the control data (line control data or line setting data) read from memory  21   a  with the control data (line control data or line setting data) received from the host processor  1 . If, as a result of the comparison, the data items are different, the monitoring device  21   c  writes a “1” to the prescribed bit of the register  21   d.    
         [0105]    The register  21   d  has for example 32 bits. Each of the bits in the register  21   d  corresponds to one or more channels. For example, the first bit corresponds to the east-side channels ch 1  to ch 24  and to the west-side channels ch 1  to ch 24 , for a total of 48 channels. The second bit corresponds to the east-side channels ch 25  to ch 48  and to the west-side channels ch 25  to ch 48 , for a total of 48 channels. The situation is similar for other bits. In this way, by associating each bit with one or more channels, it is possible to perform processing only for channels associated with bits which have changed.  
         [0106]    If, as a result of comparison, there has been a change in the line control data and/or line setting data, the monitoring device  21   c  writes a “1” to the corresponding bits of the register  21   d ; if there have been no changes, no writing is performed.  
         [0107]    For example, if there is a change in at least one line setting data item for the east-side and/or west-side channels ch 1  to ch 24 , the monitoring device  21   c  writes a “1” to the first bit of the register  21   d . If there is a change in the line control data for the east-side and/or west-side channels ch 1  to ch 24  (data at address X, address (X+1), address (X+26), address (X+27)), a “1” is written to the first bit of register  21   d . Similar processing is performed for the other channels.  
         [0108]    The CPU  20  performs polling of the register  21   d  at prescribed time intervals, and reads the value of the register  21   d . It is preferable that this prescribed time interval be adequately short (for example, several milliseconds, or several to several hundred microseconds) compared with the switching allowed time (approximately 50 milliseconds).  
         [0109]    When at least one bit of the register  21   d  is “1”, the CPU  20  judges that there has been a change in the line control data and/or line setting data, and begins data structure conversion processing and control signal data generation processing. Thereby, data structure conversion and other processing can be begun in synchronization with the change in line control data and/or line setting data.  
         [0110]    Prior to or after this data structure conversion processing and control signal data generation processing, the CPU  20  resets all the bits of the register  21   d  to “0”.  
         [0111]    First the CPU  20  executes data structure conversion processing, and then executes control signal data generation processing.  
         [0112]    Data structure conversion processing is processing in which the line setting data (see FIG. 24) for each channel, stored in individual memory cells of the memory  21   a , is rearranged within a single memory cell (one word) of the work memory  23  as shown in FIG. 5.  
         [0113]    [0113]FIG. 5 shows the line setting data after data structure conversion processing. FIG. 5 shows an example for the case in which the number of east-side channels and the number of west-side channels are both  24 .  
         [0114]    The NUT setting data E for each of the east-side channels ch 1  to ch 24  are stored in order from the first to the 24th bit in a single memory cell. That is, in the memory  21   a , as shown in FIG. 24, data E which has been arranged in series from address (X+2) to address (x+25) is arranged in parallel in the work memory  23 , as shown in FIG. 5, within the single memory cell of address Z. The NUT setting data E of the west-side  24  channels is similarly processed. Similar conversions are performed for the other line setting data F, G, S and T.  
         [0115]    When there exist 25 or more channels on both the east and the west sides, data is arranged in parallel in memory cells for each of 24 channels&#39; worth of line setting data. For example, the data E for the 24 channels from channel ch 25  to ch 48  is stored at address (Z+1).  
         [0116]    [0116]FIG. 3 shows a flowchart describing such data structure conversion processing. As one example, this flowchart shows data structure conversion processing for the line setting data E, F, G, S and T of east-side channels ch 1  to ch 24 .  
         [0117]    First, the CPU  20  sets the variable i, used as an index to specify the channel number, to 0, and sets the variable j, used as an index to specify the type of line setting data, to 0 (S 1 ). Also, the CPU  20  substitutes 0 as the value of the one-word variable tmp (32 bits) for temporary storage (S 1 ).  
         [0118]    Next, the CPU  20  masks to 0 the value of bits other than the j th  bit of the line setting data at address (X+2+i) in the memory  21   a  (that is, line setting data for channel ch(i+1); hereafter “CH[i] data”) (S 2 ). By this means, values other than the line setting data to be processed (for example, if j=0, the NUT channel setting data E; if j=1, the submarine switch control data F) are set to 0.  
         [0119]    Next, the CPU  20  shifts the masked CH[i] data to the right by j bits, and then shifts the data to the left by i bits (S 3 ). By this means, the parameters of channel ch 1  are moved to the first bit (lowermost bit), the parameters of channel ch 2  are moved to the second bit, and the parameters of channel chi are moved to the (i+1) th  bit.  
         [0120]    Then, the CPU  20  takes the logical sum (computes the logical OR) of the shifted value and the variable tmp, and assigns the computation result to the variable tmp (S 4 ). Following this, the CPU  20  increments the variable i by 1 (S 5 ), and compares the variable i and the number of channels N (here, N=24) (S 6 ).  
         [0121]    If the variable i is smaller than the number N (“YES” in S 6 ), the processing of steps S 2  through S 6  is again repeated. By repeating the processing of steps S 2  to S 5  N times, a single line setting data item for N channels, ch 1  through chN, is stored in the single-word variable tmp.  
         [0122]    In step S 6 , if the variable i is equal to or greater than N (“NO” in S 6 ), the CPU  20  writes the value of the variable tmp to the address (Z+j) in the work memory  23  (S 7 ).  
         [0123]    Next, the CPU  20  increments the variable j by 1 (S 8 ), and compares the variable j and the number of line setting data items M (here M=5) (S 9 ). If the variable j is smaller than M (“YES” in S 9 ), the CPU  20  returns again to the step S 2 , and repeats processing from step S 2 . If the variable j is equal to or greater than M (“NO” in S 9 ), the CPU  20  ends processing. By this means, the data structure of the line setting data shown in FIG. 22 is converted into the data structure shown in FIG. 5.  
         [0124]    Similar processing is performed for the line setting data items E, F, G, S and T for the west-side channels ch 1  to ch 24 .  
         [0125]    [0125]FIG. 4B shows an example of a program which generalizes this data rearrangement (the example program is in the C language); this program converts the data stored in the data structure shown on the left side in FIG. 4A into the data structure shown on the right side.  
         [0126]    Next, the CPU  20  executes control signal data generation processing, based on line control data and on line setting data (see FIG. 5) which has been structure-converted, and generates the control signal data items H to K.  
         [0127]    [0127]FIG. 6 is a flowchart showing the flow of processing to generate the control signal data H (ring-switch control data). This flowchart also shows processing for the example of the east-side channels ch 1  to ch 24 . FIG. 7 is an example of a program written in the C language and an example of a program written in assembly language for a RISC processor, corresponding to the flowchart of FIG. 6.  
         [0128]    First, the CPU  20  judges whether BSC (node fault data A) is equal to 2 and whether SW (ring-switch trigger data C) is equal to 1 (S 11 ).  
         [0129]    If BSC is equal to 2 (that is, if a fault has occurred in an east-side channel of the node itself), and SW is also equal to 1 (that is, ring-switching is executed) (“YES” in S 11 ), then the CPU  20  substitutes the hexadecimal constant 0xFFFFFF into the one-word variable tmp (32 bits) for temporary storage (S 12 ).  
         [0130]    In other words, the CPU  20  sets each of the lower 24 bits of the variable tmp to “1”, and each of the upper 8 bits to “0”. On the other hand, if BSC is not equal to 2, or if SW is not equal to 1 (“NO” in S 11 ), the CPU  20  substitutes 0 into the variable tmp, so that all 32 bits of tmp are set to “0” (S 13 ).  
         [0131]    Following this, the CPU  20  judges whether TESTcont (control data D for device testing) is equal to 0 (S 14 ).  
         [0132]    If TESTcont is equal to 0 (that is, if device testing is not to be performed) (“YES” in S 14 ), the CPU  20  computes the logical sum (logical OR) of the variable tmp and the submarine switching control data F (SubmarineSW) for the east-side channels ch 1  to ch 24 , and assigns the computation result to the variable tmp (S 15 ).  
         [0133]    Because, as explained above, the data for the east-side channels ch 1  to ch 24  is stored in a single (one-word) memory cell, and the variable tmp is also a single word, the logical sum computation is executed by the CPU  20  (specifically, by the ALU) by a single computation (single step). In this way, data for 24 channels can be computed by executing a single step, so that the number of computations is greatly decreased, and processing time is shortened, compared with the conventional method.  
         [0134]    Next, the CPU  20  computes the logical product (logical AND) of the variable tmp and the result of 0/1 inversion of each bit of the NUT setting data E (NUT) for the channels ch 1  to ch 24 , stores the computation result, as the ring-switch control data H (RingSW) for the east-side channels ch 1  to ch 24 , at address Y (see FIG. 14) of the memory  22  (S 16 ), and ends processing.  
         [0135]    This 0/1 inversion processing is also executed by a single computation of the CPU  20 , since the NUT setting data E of the channels ch 1  to ch 24  is stored in a single word. Also, the logical product computation is executed in a single ALU operation. As a result, the number of computations is greatly reduced, and processing time is shortened, compared with the conventional method.  
         [0136]    If however in step S 14  TESTcont is not equal to 0 (that is, device testing is to be performed) (“NO” in S 14 ), the CPU  20  stores the device testing ring-switch control data G (RingSWcont) for east-side channels ch 1  to ch 24 , without modification, in the ring-switch control data H (RingSW) for east-side channels ch 1  to ch 24 , that is, at address Y of memory  22  (see FIG. 14) (S 17 ).  
         [0137]    Here the device testing ring-switch control data G (RingSWcont) for east-side channels ch 1  to ch 24  is also converted into one-word data, so that processing to store this in memory  22  is also executed in a single operation. By this means the number of processes is reduced, and the processing time is shortened.  
         [0138]    As shown in FIG. 7, when converted into the number of operations of the RISC processor (CPU  20 ), step S 11  involves 8 steps; step S 12  or step S 13  involves 2 steps. Step S 14  involves 4 steps, step S 15  involves 4 steps, step S 16  involves 5 steps, and step S 11  involves 2 steps. Hence the total number of steps performed in steps S 11 , S 12 , S 14 , S 15 , S 16  is 23 steps. That is, by means of 23 steps, control signal data for 24 channels is generated.  
         [0139]    By this means, even if the number of operations employed in data structure conversion processing in the above-described FIG. 3 is added, the number of operations is reduced, and processing time shortened, compared with the conventional method.  
         [0140]    Next, processing to generate ring-bridge control data I is explained. FIG. 8 is a flowchart showing the flow of processing to generate ring-bridge control data I. Processing which is the same as in FIG. 6 is assigned the same symbol, and a detailed explanation is omitted. FIG. 9 is an example of a program in the C language corresponding to the flowchart of FIG. 8.  
         [0141]    First, the CPU  20  judges whether BSC (node fault data A) is equal to 2, and whether BR (ring-bridge trigger data B) is equal to 1 (S 21 ).  
         [0142]    If BSC is equal to 2, and BR is equal to 1 (that is, a ring bridge is executed) (“YES” in S 21 ), the CPU  20  executes step S 12 ; otherwise, step S 13  is executed.  
         [0143]    Next, the CPU  20  performs the judgment of step S 14 , and if TESTcont is equal to 0 (“YES” in S 14 ), the logical sum of the variable tmp and the submarine bridge control data S (SubmarineBR) for east-side channels ch 1  to ch 24  is computed, and the computation result assigned to the variable tmp (S 25 ). This logical sum computation is, similarly to step S 15  described above, executed in a single operation of the CPU  20 , so that the number of computations is greatly decreased, and the processing time is shortened, compared with the conventional method.  
         [0144]    Next, the CPU  20  computes the logical product of the variable tmp and the result of 0/1 bit inversion of each bit of the NUT setting data E (NUT) for channels ch 1  to ch 24 , stores the computation result in the address (Y+2) (see FIG. 14) of the memory  22  as the ring-bridge control data I (RingBR) of east-side channels ch 1  to ch 24  (S 26 ), and ends processing. Here also, similarly to step S 16 , the number of computations is greatly decreased and the processing time is shortened, compared with the conventional method.  
         [0145]    On the other hand, if in step S 14  TESTcont is not equal to 0 (“NO” in S 14 ), the CPU  20  stores the device testing ring-bridge control data T (RingBRcont) for east-side channels ch 1  to ch 24  without modification in the ring-bridge control data I (RingBR) (address Y+2, see FIG. 14) for east-side channels ch 1  to ch 24  (S 27 ). Here also, as in step S 17 , the number of computations is decreased and the processing time is shortened.  
         [0146]    As seen in FIG. 9, when converted into the steps of a RISC processor, the processing of the flowchart of FIG. 8 also involves 23 steps.  
         [0147]    Next, processing to generate the span-switch control data J is explained. FIG. 10 is a flowchart showing the flow of processing to generate span-switch control data J. Processing which is the same as in FIG. 6 is assigned the same symbol, and a detailed explanation is omitted. FIG. 11 is an example of a program in the C language corresponding to the flowchart of FIG. 10.  
         [0148]    First, the CPU  20  judges whether Spanswcont (span-switch trigger data X) is equal to 1 (S 31 ). If Spanswcont is equal to 1 (that is, if span-switching is performed) (“YES” in S 31 ), the CPU  20  executes step S 12 ; if not (“NO” in S 31 ), the CPU  20  executes step S 13 .  
         [0149]    Next, the CPU  20  computes the logical product of the variable tmp and the result of 0/1 bit inversion of each bit of the NUT setting data E (NUT) for channels ch 1  to ch 24 , stores the computation result in memory  22  (see FIG. 14) as the span-switch control data J (SpanSW) of east-side channels ch 1  to ch 24  (S 34 ), and ends processing. Here also, similarly to step S 16 , the number of computations is greatly decreased and the processing time is shortened, compared with the conventional method.  
         [0150]    As is seen from FIG. 11, processing of the flowchart of this FIG. 10, when converted into RISC processor steps, involves 15 steps.  
         [0151]    Next, processing to generate span-bridge control data K is explained. FIG. 12 is a flowchart showing the flow of processing to generate span-bridge control data K. Processing which is the same as in FIG. 6 is assigned the same symbol, and a detailed explanation is omitted. FIG. 13 is an example of a program in the C language corresponding to the flowchart of FIG. 12.  
         [0152]    First, the CPU  20  judges whether Spanbrcont (span-bridge trigger data Y) is equal to 1 (S 41 ). If Spanbrcont is equal to 1 (that is, if span-bridging is performed) (“YES” in S 41 ), the CPU  20  executes step S 12 ; if not (“NO” in S 41 ), the CPU  20  executes step S 13 .  
         [0153]    Next, the CPU  20  computes the logical product of the variable tmp and the result of 0/1 bit inversion of each bit of the NUT setting data E (NUT) for channels ch 1  to ch 24 , stores the computation result in memory  22  (see FIG. 14) as the span-bridge control data K (SpanBR) of east-side channels ch 1  to ch 24  (S 44 ), and ends processing. Here also, similarly to step S 16 , the number of computations is greatly decreased and the processing time is shortened, compared with the conventional method.  
         [0154]    As is seen from FIG. 13, processing of the flowchart of this FIG. 12, when converted into RISC processor steps, involves 15 steps.  
         [0155]    [0155]FIG. 14 shows control signal data which has been generated in this way and stored in memory  22 . This control signal data is read from the other port of the memory  22  and supplied to the PSs  25 .  
         [0156]    First the east-side span-switch control data J is sent to PS  25   1 , and then the west-side span-switch control data J is sent. That is, the east-side span-switch control data J and the west-side span-switch control data J are output by means of time division. This east-side span-switch control data J and west-side span-switch control data J are input from PS  25   1  to the span-switch unit  3  (see FIG. 22) as serial data.  
         [0157]    In synchronization with PS  25   1  data output, at the span-switch unit  3 , when the east-side span-switch control data J is output from PS  25   1 , the selection circuit  31  and AIS insertion circuit  33  receive the east-side span-switch control data J, and when the west-side span-switch control data J is output from PS  25   1 , the selection circuit  32  and AIS insertion circuit  34  receive west-side span-switch control data J.  
         [0158]    Similarly, east-side ring-switch control data H output from PS  25   2  is received by the selection circuit  41  of the ring-switch unit  4 , and west-side ring-switch control data H is received by the selection circuit  42  of the ring-switch unit  4 . East-side span-bridge control data K output from PS  25   3  is received by the selection circuit  51  of the span-bridge unit  5 , and west-side span-bridge control data K is received by the selection circuit  52  of the span-bridge unit  5 . East-side ring-bridge control data I output from PS  25   4  is received by the selection circuit  61  of the ring-bridge unit  6 , and west-side ring-bridge control data I is received by the selection circuit  62  of the ring-bridge unit  6 .  
         [0159]    When the value of the input data J is “0”, the selection circuits  31  and  32  select and output, for the channel corresponding to the data, the main signal of the channel on the first input (work line) side. On the other hand, when the value of the input data J is “1”, the main signal of the second input (protection line) side for the channel corresponding to the data is selected and output.  
         [0160]    When the value of the input data J is “0”, the AIS insertion circuits  33  and  34  do not output an AIS to the channel corresponding to the data; when the value of the input data J is “1”, an AIS is output to the channel corresponding to the data.  
         [0161]    Similar operations are performed by the other selection circuits  41 ,  42 ,  51 ,  52 ,  61  and  62 , and by the AIS insertion circuits  33  and  34 .  
         [0162]    By this means, span-switching and span-bridging, or ring-switching and ring-bridging, are executed.  
         [0163]    In this way, by means of this embodiment the number of processing steps is reduced, and the processing time is shortened, in software processing to generate control signal data based on line control data and line setting data provided by the host processor  1 . Even if the operating frequency of the CPU  20  (RISC processor) is 100 MHz, switching processing can be completed within an allowable time for switching of 50 milliseconds.  
         [0164]    By the way, when there is a change in the data stored in memory  21   a , the monitoring device  21   c  can provide the CPU  20  with an interrupt signal and with data (such as channel number, etc.) indicating the channel in which the change has occurred.  
         [0165]    Also, FIG. 5 and FIG. 14 are examples of control data, and there are cases in which other data is stored in “unused” bits. Other data might be, for example, far end node ID information; squelch table information (source-side node IDs, sink-side node IDs and similar needed for squelch judgments); RIP (Ring Interworking on Protection) channel setting information; switch-squelch control information; bridge-squelch control information (squelch: function to insert an AIS for a line causing misconnection); protection through control information; and drop AIS control information (a function to halt adding (ADD) of protection lines when faults occur, and enable pass-through).  
         [0166]    Further, the bits of register  21   d  reflect changes in a total of 48 channels, including 24 east-side channels and 24 west-side channels; but the number of channels change in which is reflected by each bit in the register  21   d  may be different from this.  
         [0167]    Second Embodiment  
         [0168]    The control signal data of the first embodiment, shown in FIG. 14, can also be converted into a conventional control signal data structure shown in FIG. 25, and output from PSs  25 .  
         [0169]    [0169]FIG. 15 is a flowchart showing the flow of processing to convert the control signal data shown in FIG. 14 into the control signal data structure shown in FIG. 25. The processing shown in this flowchart is, as one example, processing to convert east-side ring-switch data H for 24 channels, stored in the memory cell at address Y. This processing is described in a program stored in the instruction storage memory  24 , and is executed by the CPU  20 .  
         [0170]    First, the CPU  20  sets the value of the variable i, which specifies the bit position of the memory cell at address Y in FIG. 14, to 1 (S 51 ). That is, the bit position of the memory cell at address Y is specified as the i th  bit.  
         [0171]    Next, the CPU  20  masks to 0 the values of bits other than the i th  bit in the memory cell at address Y (S 52 ), and right-shifts the result of masking by i bits (S 53 ). By this means, the ring-switch data H of channel chi is moved to the first bit.  
         [0172]    Then, the CPU  20  stores the result of shifting in the memory cell at another address (the address is taken to be (Y′+i−1)) (S 53 ). By this means, the ring-switch data H of channel chi is stored in the first (lowermost) bit of one memory cell as shown in FIG. 25.  
         [0173]    Next, the CPU  20  increments the variable i by 1 (S 55 ), and compares the variable i and the number of channels N (here N=24) (S 56 ). If i≦N, processing is repeated from step S 52 , and ring-switch data H for the next channel is processed. If i&gt;N, processing ends. By this means, the east-side ring-switch control data shown in FIG. 14 is substituted in the first bit of 24 consecutive memory cells, as shown in FIG. 25.  
         [0174]    Thereby, the existing interface between the line switch control unit  2 , span-switch unit  3 , ring-switch unit  4 , span-bridge unit  5 , and ring-bridge unit  6  can be used, and the existing PS  206   1  to  206   4  shown in FIG. 23 can be used as the PSs  25 .  
         [0175]    Third Embodiment  
         [0176]    The memory unit  21  in the first embodiment can also be configured as shown in FIG. 16. In FIG. 16, component elements which are the same as in FIG. 2 are assigned the same symbols, and detailed explanations are omitted.  
         [0177]    This memory unit  21  has a memory  21   a ; delay element  21   b ; monitoring device  21   c ; registers  21   d  and  21   e ; an AND gate  21   f ; and a zero-judgment circuit  21   g.    
         [0178]    As described in the explanation of the first embodiment, the monitoring device  21   c  sets to “1” the bits in the register  21   d  (which is, for example, a 32-bit register) corresponding to line control data and/or line setting data which has changed.  
         [0179]    The register  21   e  has the same number of bits (for example, 32 bits) as the register  21   d . A high-level “H” (“1”) or low-level “L” (“0”) transfer (copy) enable signal is input to the register  21   e  from the AND gate  21   f . When a high-level transfer enable signal is input to the register  21   e , the values of all the bits of the register  21   d  are transferred (copied) to the register  21   e  (which is written). After the transfer, the value of the register  21   d  is reset to 0.  
         [0180]    The CPU  20  reads the value of the register  21   e  at prescribed time intervals by polling. Similarly to the first embodiment, the CPU  20  executes processing of line control data and line setting data for channels (48 channels) corresponding to bits of the register  21   e  set to “1”, and generates and outputs control signal data. After the end of this processing, the CPU  20  resets all the bits of the register  21   e  to 0.  
         [0181]    The zero-judgment circuit  21   g  judges whether the values of all the bits of the register  21   e  are “0”. If all the bits of the register  21   e  are “0”, the zero-judgment circuit  21   g  outputs a high-level “H” (“1”) signal to the AND gate  21   f , and if at least one bit of the register  21   e  is set to “1”, outputs a low-level “L” (“0”) signal to the AND gate  21   f.    
         [0182]    In addition to the signal from the zero-judgment circuit  21   g , a transfer timing signal (clock signal) at a prescribed frequency (for example, 8 kHz) is also input to the AND gate  21   f  from an oscillator, not shown.  
         [0183]    Only when both the signal from the zero-judgment circuit  21   g  and the transfer timing signal are at high level does the AND gate  21   f  output a high-level transfer enable signal to the register  21   e ; at all other times, a low-level transfer enable signal is output to the register  21   e.    
         [0184]    A transfer enable signal from the AND gate  21   f  is input to the register  21   e , and so if the value of the register  21   e  is not 0, the value of the register  21   d  is not transferred to the register  21   e . In other words, after the CPU  20  ends processing of line control data and line setting data for a given channel (48 channels), and the register  21   e  is reset to 0, the value of the register  21   d  is transferred to the register  21   e.    
         [0185]    By this means, the CPU  20  can discriminate the channel (channel group) to be processed through a single polling (because, during processing by the CPU  20 , the value of the register  21   e  does not change), and so processing efficiency can be improved.  
         [0186]    Fourth Embodiment  
         [0187]    Of the data shown in FIG. 24, the line setting data (E, F, G, and the like) are provided to the line switching control unit  2  even before the node enters the operational state (for example, upon initial settings (provisioning) performed on startup of the node). Thereafter, if a fault occurs during node operation, of the data shown in FIG. 24, line control data (A, B and the like) is provided to the line switching control unit  2 .  
         [0188]    Even if a fault occurs, there exist many line setting data items which do not change. Hence by executing data conversion processing in advance, when node initial settings are set, the need to perform data conversion processing when a fault occurs is eliminated in cases where there are no changes in line setting data on occurrence of the fault. By this means, the time required for execution of data structure conversion processing during operation can be eliminated, and software-processing time can be shortened.  
         [0189]    In other words, when node initial settings are set, if the line setting data (E, F, G, S, T, and similar) is provided by the host processor  1  to the line switching control unit  2 , the CPU  20  executes data structure conversion processing of the line setting data (see FIG. 3) as part of this initial setting processing, and stores the converted data in the work memory  23 .  
         [0190]    After completion of initial settings, the CPU  20  puts the line switching control unit  2  into the operating state (in service).  
         [0191]    Thereafter, if a fault occurs while in the operating state, and the host processor  1  provides line control data (A, B, C, and similar) to the memory unit  21  (monitoring device  21   c , delay element  21   b , memory  21   a ) of the line switching control unit  2 , the memory unit  21  sends an interrupt signal to the CPU  20 .  
         [0192]    As a result of this interrupt signal, the CPU  20  begins the polling of the above-described second or third embodiment, and executes control signal data generation processing for channels for which a change in the line control data has occurred.  
         [0193]    Fifth Embodiment  
         [0194]    In the fifth embodiment, data structure conversion processing is performed by hardware circuitry. FIG. 17 is a block diagram showing the configuration of the line switching control unit  2   a  of the fifth embodiment. Component elements which are the same as in the line switching control unit  2  of FIG. 1 are assigned the same symbols, and detailed explanations are omitted.  
         [0195]    This line switching control unit  2   a  has a CPU  20 ; a memory  22 ; an instruction storage memory  24 ; a work memory  23   a ; a data structure conversion device  26 ; and PS  25   1  to PS  25   4 .  
         [0196]    The work memory  23   a  differs from the work memory (RAM)  23  of FIG. 1 in that it is two-port RAM.  
         [0197]    The data structure conversion device  26  employs hardware circuitry to execute the data structure conversion processing that had been executed by software in the first embodiment. FIG. 18 is a block diagram showing the detailed configuration of the data structure conversion device  26 .  
         [0198]    The data structure conversion device  26  has a format conversion circuit  261 ; a flip-flop (FF)  262 ; a differentiating circuit  263 ; decoder  264 ; a write/read control circuit  265 ; and an address generation circuit  266 .  
         [0199]    The host processor  1  inputs to the data structure conversion device  26  line setting data (write data), an address in work memory  23   a  to which to write line setting data (write address), and a write enable signal (write EN).  
         [0200]    The address is input to the decoder  264 . Based on the input address, the decoder  264  generates a leading address for the data group to which the line setting data specified by the address belongs.  
         [0201]    Here, if as shown for example in FIG. 24 the line setting data is grouped in 24-channel groups, the “leading address for the data group to which the line setting data specified by the address belongs” is the leading address of this group (the (X+2) address, (X+28) address, and similar in FIG. 24), and this group is called a data group.  
         [0202]    For example, when in FIG. 24 any of the addresses from address (X+2) to (X+25) is input to the decoder  264 , the leading address (X+2) is output based on this address. Similarly, when any of the addresses (X+28) to (X+51) is input to the decoder  264 , the leading address (X+28) is output based on this address.  
         [0203]    The address generation circuit  266  outputs to the work memory  23   a  (to the address input terminal AD), in order, the addresses of the data group, based on the leading address provided by the decoder  264 . For example, if the leading address is (X+2), the address generation circuit outputs, in order, the addresses from (X+2) to (X+25). These addresses are used as read addresses for line setting data stored in the work memory  23   a.    
         [0204]    The write EN signal is input to the differentiating circuit  263 . When the differentiating circuit  263  detects a change in the write EN signal (for example, in the case of active-low, the falling edge from high level to low level; in the case of active-high, the rising edge), a trigger signal is output to the FF  262  and write/read control circuit  265 .  
         [0205]    By means of this trigger signal input, the FF  262  latches (stores) the line setting data (write data) provided by the host processor  1 .  
         [0206]    By means of this trigger signal input, the write/read control circuit  265  outputs to the work memory  23   a  (the read enable terminal REN) read enable signals in synchronization with the output of the read address by the address generation circuit  266 , in a number equal to the number of read addresses output by the address generation circuit  266 .  
         [0207]    As a result of the read addresses output by the address generation circuit  266  and the read enable signals output by the write/read control circuit  265 , line setting data is read in order from the work memory  23   a . For example, line setting data is read in order for 24 channels, from the address (X+2) to the address (X+25).  
         [0208]    The line setting data read in this way is input to the format conversion circuit  261 . Data latched by the FF  262  is also input to the format conversion circuit  261 .  
         [0209]    The format conversion circuit  261  converts the plurality of line setting data items (for 24 channels) input from work memory  23   a  and the FF  262  into a single word of data, as shown in FIG. 5, and outputs the converted data word to work memory  23   a.    
         [0210]    The address generation circuit  266  outputs to work memory  23   a  (the address input terminal AD) the address to which to write the converted data (for example, address Z in FIG. 5), in synchronization with the output of converted data by the format conversion circuit  261 .  
         [0211]    The write/read control circuit  265  outputs to work memory  23   a  (the write enable input terminal WEN) a write enable signal, in synchronization with the output of converted data by the format conversion circuit  261 .  
         [0212]    By this means, one word of line setting data with data structure converted is stored in the work memory  23   a.    
         [0213]    After conversion, when the format conversion circuit  261  or similar sends an interrupt signal to the CPU  20 , the CPU  20  can execute control signal data generation processing.  
         [0214]    In this embodiment, data structure conversion processing is executed by hardware circuitry, so that data structure conversion processing can be executed more rapidly. In addition, the work memory  23   a  is used both as the memory unit  21  (memory  21   a ) and as work memory  23 , so that the amount of hardware can be reduced.  
         [0215]    By the way, the line control data does not require data structure conversion, and so is either written to the work memory  23   a  without being converted by the format conversion circuit  261 , or else is written to the work memory  23   a  by bypassing the data structure conversion device  26 .  
         [0216]    Also, by providing hardware to perform processing which is the inverse of this line setting data structure conversion, processing to convert the data structure of the control signal data shown in FIG. 14 into the data structure shown in FIG. 25 can be executed by hardware circuitry.  
         [0217]    Sixth Embodiment  
         [0218]    Hardware circuitry for data structure conversion processing can also be incorporated within the CPU  20 .  
         [0219]    In general, the CPU has a source register, an ALU, and a destination register; processing is repeated in which the data stored in the source register is operated on by the ALU, and the operation result is stored in the destination register.  
         [0220]    Data structure conversion processing circuitry can be incorporated between the source register and the destination register. FIG. 19 is a block diagram showing in summary the configuration of a CPU which incorporates data structure conversion processing circuitry between the source register and destination register. FIG. 20 is a block diagram showing the detailed configuration of the data structure conversion processing circuitry.  
         [0221]    The CPU has an instruction decoder  20   a , a source register file  20   b , a destination register file  20   c , an ALU  20   d , and a data structure conversion circuit  20   e.    
         [0222]    A data structure conversion instruction, which causes the data structure conversion circuit  20   e  to execute data structure conversion processing, is added to the CPU instruction set. When this data structure conversion instruction is sent to the CPU, the instruction decoder  20   g  decodes this instruction and sends it to the data structure conversion circuit  20   e.    
         [0223]    As shown in FIG. 20, the data structure conversion circuit  20   e  has at least M selectors  210   1  to  210   M  (where M is the number of line setting data items; in FIG. 24, M=5).  
         [0224]    The source register file  20   b  has at least N registers  220   1  to  220   N  (where N is the number of channels; in FIG. 24, N=24). Each register  220   1  to  220   N  has 32 bits.  
         [0225]    The CPU stores line setting data for each channel in the registers  220   1  to  220   N . For example, in the example shown in FIG. 24, line setting data for the east-side channels ch 1  to ch 24  is stored in the registers  220   1  to  220   N  respectively.  
         [0226]    The first bit of data in each of the registers  220   1  to  220   N  is provided to the selector  210   1 . Similarly, the second through M th  bits of data in the registers  220   1  to  220   N  are provided to the selectors  210   2  to  210   M .  
         [0227]    The destination register file  20   d  has at least M registers  230   1  to  230   M . Each of the registers  230   1  to  230   M  has 32 bits.  
         [0228]    An instruction from the instruction decoder  20   a  is input to the selectors  210   1  to  210   M . When an instruction from the instruction decoder  20   a  is input to each of the selectors  210   1  to  210   M , the selectors  210   1  to  210   M  each output data from the registers  220   1  to  220   N  to the registers  230   1  to  230   M . At this time, the selectors  210   1  to  210   M  store data (one bit of data) from the register  220   i  (where i is an integer from 1 to N) in the i th  bit of the registers  230   1  to  230   M . By this means, data structure conversion processing is executed.  
         [0229]    In this way, by incorporating a data structure conversion circuit within the CPU and providing a data structure conversion instruction in the CPU instruction set, the software-processing overhead due to data structure conversion can be reduced.  
         [0230]    This data structure conversion circuit  20   e  can also be mounted as a circuit external to the CPU, similarly to a CPU coprocessor.  
         [0231]    It is also possible to configure hardware circuitry to perform processing to convert the data structure of the control signal data shown in FIG. 14 into the data structure shown in FIG. 25, to be positioned in the CPU between the source register file  20   b  and the destination register file  20   c , or to be mounted externally like a coprocessor.  
         [0232]    Other Embodiments  
         [0233]    The line setting unit  2  was explained separately from the host processor  1 ; however, it is also possible to have the host processor execute the processing of the line setting unit  2 , and eliminate the line setting unit  2 .  
         [0234]    As described above, by means of this invention, the number of processing steps in a transmission device can be reduced, and the time required for processing can be shortened. Further, because functions can be realized in software, it is possible to develop, at low cost and in a short period of time, a system which can respond flexibly to changes in specifications, while maintaining processing performance.