WO2021192456A1 - 情報処理装置およびラダープログラムを表示するためのプログラム - Google Patents

情報処理装置およびラダープログラムを表示するためのプログラム Download PDF

Info

Publication number
WO2021192456A1
WO2021192456A1 PCT/JP2020/047226 JP2020047226W WO2021192456A1 WO 2021192456 A1 WO2021192456 A1 WO 2021192456A1 JP 2020047226 W JP2020047226 W JP 2020047226W WO 2021192456 A1 WO2021192456 A1 WO 2021192456A1
Authority
WO
WIPO (PCT)
Prior art keywords
ladder
circuit
screen
ladder circuit
information
Prior art date
Application number
PCT/JP2020/047226
Other languages
English (en)
French (fr)
Inventor
健次郎 長尾
大生 笹井
Original Assignee
オムロン株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by オムロン株式会社 filed Critical オムロン株式会社
Publication of WO2021192456A1 publication Critical patent/WO2021192456A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B19/00Programme-control systems
    • G05B19/02Programme-control systems electric
    • G05B19/04Programme control other than numerical control, i.e. in sequence controllers or logic controllers
    • G05B19/05Programmable logic controllers, e.g. simulating logic interconnections of signals according to ladder diagrams or function charts

Definitions

  • This disclosure relates to an information processing device for displaying a ladder program and a program for displaying the ladder program.
  • Control devices such as PLC (Programmable Logic Controller) have been introduced at various manufacturing sites.
  • a control device is a kind of computer, and executes a user program designed according to a manufacturing device, a manufacturing facility, or the like.
  • Such a user program is created in a development environment prepared separately from the control device.
  • the programming language for describing the user program includes a ladder diagram (LD: Ladder Diagram) that can be displayed in a circuit mode in which a plurality of instruction elements are connected to each other.
  • LD Ladder Diagram
  • a program described in a circuit mode in which a plurality of instruction elements are connected to each other is also called a "ladder program”.
  • Patent Document 1 Japanese Patent Application Laid-Open No. 2017-0590446
  • the ladder program has a structure in which a logic circuit represented by a combination of contacts and coils is drawn in a ladder shape.
  • the coil indicates the output destination of the result of the logical operation combining the contacts.
  • a ladder program may be described in a hierarchical representation in which one logic circuit receives the result of another logic circuit and another logic circuit receives the result of another logic circuit. ..
  • the present invention aims to solve the above problems, and aims to display the hierarchical structure of the ladder program in an easy-to-understand manner.
  • an information processing device for displaying a ladder program.
  • the information processing device includes a ladder screen generation unit, a reception unit, a definition unit, and a hierarchical screen generation unit.
  • the ladder screen generation unit generates a ladder screen for displaying the ladder program in a circuit mode including a plurality of ladder circuits. A plurality of ladder circuits are displayed on the ladder screen, and text information registered for each ladder circuit is displayed corresponding to the corresponding ladder circuit.
  • the reception unit receives input of parent-child information indicating a parent-child relationship between one ladder circuit and another ladder circuit in response to an operation on the ladder screen.
  • the definition unit defines the hierarchical structure of a plurality of ladder circuits included in the ladder program based on the parent-child information received by the reception unit.
  • the hierarchical screen generation unit generates a hierarchical screen for displaying the hierarchical structure defined by the definition unit as text information.
  • a hierarchical structure can be easily expressed by providing indentation or connecting text information with ruled lines.
  • the information processing apparatus can display the entire structure of the ladder program in an easy-to-understand manner.
  • each of the text information included in the hierarchical screen may be associated with the position information indicating the position of the corresponding ladder circuit on the ladder screen.
  • the ladder circuit corresponding to the selected text information may be displayed in the area for displaying the ladder screen according to the selection of the text information via the hierarchical screen.
  • the display range of the ladder screen can be changed by operating through the hierarchical screen displaying the hierarchical structure, so that the target ladder circuit can be easily displayed.
  • the definition unit defines a hierarchical structure based on the position information indicating the position of the ladder circuit on the ladder screen and the parent-child information, and defines the hierarchical structure according to the change of the position information being accepted. You may try again.
  • the user can input the parent-child information while checking the contents of each ladder circuit having a parent-child relationship.
  • the reception unit may accept changes in location information according to operations on the hierarchical screen.
  • the positional relationship between the ladder circuits can be changed by operating through the hierarchical screen displaying the hierarchical structure, and the hierarchical structure can be changed according to the change in the positional relationship. Therefore, the hierarchical structure can be easily changed.
  • the definition unit has a hierarchical structure based on a predetermined additional rule and a layer of the selected ladder circuit when an additional operation of the ladder circuit is performed with one ladder circuit selected. May be redefined.
  • a hierarchical structure when developing a ladder program by adding a ladder circuit, a hierarchical structure can be easily defined.
  • the information processing apparatus may further include a creation unit that edits or creates text information.
  • the creation unit when the change of the position information is accepted in response to the addition of the ladder circuit, the creation unit adds the redefined hierarchical structure and the ladder circuit of the hierarchy to which the added ladder circuit belongs. Based on the corresponding text information, the text information corresponding to the added ladder circuit may be created.
  • the selected ladder circuit and the ladder circuit included in the child hierarchy of the selected ladder circuit are deleted. May be good.
  • the receiving unit accepts the selection of one ladder circuit, and also accepts the selected ladder circuit and the ladder circuit included in the child hierarchy of the selected ladder circuit as a component of one management unit. good.
  • an arbitrary hierarchical structure can be defined by inputting parent-child information, and reusable parts can be created at the same time.
  • the ladder screen generation unit may generate a ladder screen in which the ladder circuit included in the child hierarchy of the selected ladder circuit is omitted.
  • the overall structure of the ladder program can be displayed in a more understandable manner.
  • the hierarchical screen generation unit may generate a hierarchical screen in which the text information corresponding to the ladder circuit included in the child layer of the selected ladder circuit is omitted.
  • the overall structure of the ladder program can be displayed in a more understandable manner.
  • the ladder screen generation unit generates a ladder screen in which the ladder circuits included in the same layer and the ladder circuits included in different layers are displayed in different display modes based on the hierarchical structure defined by the definition unit. You may.
  • the user can easily grasp the division of the hierarchy just by checking the ladder screen.
  • the ladder program may include one or more call instructions that call a block composed of a set of program elements.
  • the hierarchical screen generation unit may generate a hierarchical screen so that the child hierarchy of the ladder circuit including the calling instruction includes the block called by the calling instruction.
  • a support program for displaying a ladder program displays the ladder program in a circuit mode including a plurality of ladder circuits, and generates a ladder screen for displaying the text information registered for each ladder circuit corresponding to the corresponding ladder circuit.
  • a hierarchical structure can be easily expressed by providing indentation or connecting text information with ruled lines.
  • the information processing apparatus can display the entire structure of the ladder program in an easy-to-understand manner.
  • the overall structure of the ladder program can be displayed in an easy-to-understand manner.
  • FIG. 1 is a block diagram showing a functional configuration of the support device 10 according to the present embodiment.
  • the support device 10 is an example of an information processing device for displaying the ladder program 42.
  • the support device 10 typically comprises a general purpose computer.
  • the support device 10 is used in a scene where the ladder program 42 is created, a scene where the operation of the ladder program 42 is confirmed, a scene where a bug of the ladder program 42 is corrected, and the like.
  • the ladder program 42 is a type of control program executed by a control device such as a PLC that controls various devices used in the FA field.
  • a "control program” is a program for providing basic functions of a control device that controls various devices used in the FA field, and a program arbitrarily designed according to a control target (also referred to as a "user program”). ) Is a concept that includes.
  • the ladder program 42 is a program written in a programming language that can be displayed in a circuit mode in which a plurality of instruction elements are connected to each other.
  • the ladder program 42 is a program described by a ladder diagram (LD: Ladder Diagram) among the programming languages of PLC applications defined in the international standard IEC61131-3.
  • LD Ladder Diagram
  • the ladder program 42 may include a program described in a text (ST: Structured Text), a language unique to each manufacturer, or a procedural programming language such as C language.
  • the support device 10 includes a ladder screen generation unit 12, a reception unit 14, a definition unit 16, and a hierarchical screen generation unit 18.
  • the ladder screen generation unit 12 generates a ladder screen 120 for displaying the ladder program 42 in a circuit mode including one or a plurality of ladder circuits 420.
  • the ladder screen generation unit 12 generates the ladder screen 120 so as to display the ladder circuits 420 side by side and display the text information 460 registered for each ladder circuit 420 in association with the corresponding ladder circuit 420.
  • Each ladder circuit 420 is a logic circuit drawn by using an input side bus 421 and an output side bus 422, and a connection line and a circuit element between the input side bus 421 and the output side bus 422 (hereinafter, simply “circuit”). Also called).
  • the circuit element includes, for example, a contact 423 that turns on / off based on an input signal, and a coil 424 that outputs a calculation result in the circuit. In FIG. 1, some reference numerals are omitted.
  • Text information 460 is information composed of characters. The letters may also include symbols and numbers. Text information 460 is typically the name of the ladder circuit 420. In the example shown in FIG. 1, the name of the ladder circuit 420 (for example, the character “circuit 1" in FIG. 1) and the order of the ladder circuits 420 (for example, the character "0" in FIG. 1) are used as the text information 460. ) Is displayed on the ladder screen 120. A comment indicating the contents of the ladder circuit 420 may be registered as the text information 460. Further, the text information 460 may be automatically generated, or may be generated by being input by the user.
  • the reception unit 14 receives input of parent-child information 480 indicating a parent-child relationship between one ladder circuit 420 and another ladder circuit 420 for each ladder circuit 420 in response to an operation on the ladder screen 120.
  • Parent-child relationship means a subordinate relationship.
  • the ladder circuit 420 in the upper layer is the parent, and the ladder circuit 420 included in the lower layer in the layer is the child.
  • Parent-child information 480 can be input so as to be performed.
  • the parent-child information 480 is input in association with the ladder circuit 420 corresponding to the text information 460. Is accepted.
  • the user can divide the hierarchy by inputting the special symbol "#", and the depth of the hierarchy can be indicated by the number of special symbols "#".
  • the ladder circuit 420 indicated by “circuit 1” has a variable “a” which is an output result of the ladder circuit 420 indicated by “circuit 1-1” and “circuit 1-2".
  • the output result changes depending on the variable "b" which is the output result of the ladder circuit 420 shown.
  • the user uses the ladder circuit 420 indicated by "Circuit 1" as the parent, the ladder circuit 420 indicated by “Circuit 1-1”, and the ladder circuit 420 indicated by "Circuit 1-2" by “Circuit 1".
  • Parent-child information 480 can be input so as to be a child of the ladder circuit 420 shown.
  • the definition unit 16 defines a hierarchical structure 160 of a plurality of ladder circuits 420 included in the ladder program 42 based on the parent-child information 480 received by the reception unit 14. For example, the definition unit 16 defines the hierarchical structure 160 based on the input parent-child information 480 and a predetermined rule for inputting the parent-child information 480.
  • the definition unit 16 has, for example, the 0th ladder circuit 420 and the 1st ladder circuit based on the parent-child information 480 (“#”) received for the 0th ladder circuit 420.
  • a hierarchy is separated from 420, and the number of "#" identifies that the 0th ladder circuit 420 is the highest hierarchy.
  • the definition unit 16 defines that the first ladder circuit 420 is a child layer of the 0th ladder circuit 420. Further, since the parent-child information 480 is not input to the second ladder circuit 420, the definition unit 16 defines that the second ladder circuit 420 has the same layer as the first ladder circuit 420.
  • the hierarchical screen generation unit 18 generates a hierarchical screen 180 in which the hierarchical structure 160 defined by the definition unit 16 is displayed with text information 460.
  • the layer screen generation unit 18 expresses the layer of the ladder circuit 420 corresponding to the text information 460 depending on how many indents are provided at the beginning of the text information 460.
  • the 0th ladder circuit 420 corresponding to "0. circuit 1" is the ladder circuit 420 of the uppermost layer because "0. circuit 1" is not provided with an indent.
  • the ladder program 42 may be described in a hierarchical representation such that the result output by the coil 424 in one ladder circuit 420 is received by the contact 423 included in the other ladder circuit 420.
  • the ladder program 42 described in a hierarchical representation is composed of a plurality of ladder circuits 420. Since the range in which the ladder screen 120 can be displayed is limited, it is difficult to fit the entire ladder program 42 in the display, and it is difficult to express the entire structure of the ladder program 42.
  • the positions of the input side bus 421 are displayed in a fixed manner. It is possible to express the hierarchical relationship by changing the position of the input side bus 421, but if the position of the input side bus 421 is changed, the display position of the ladder circuit 420 changes for each ladder circuit 420, which is difficult to see. There is.
  • the support device 10 receives input of parent-child information 480 according to an operation on the ladder circuit 420. Therefore, the user can arbitrarily define the parent-child relationship between the ladder circuits 420 while checking the ladder circuit 420.
  • the support device 10 includes a hierarchical screen generation unit 18 for generating a hierarchical screen 180 for displaying the hierarchical structure 160 defined based on the parent-child information 480 with the text information 460.
  • the hierarchical structure 160 can be easily expressed by providing an indent or connecting the text information 460s with a ruled line. Therefore, the support device 10 can display the entire structure of the ladder program 42 in an easy-to-understand manner.
  • the area required for displaying the text information 460 is narrower than the area required for displaying the ladder circuit 420. Therefore, by representing the hierarchical structure 160 with the text information 460, it becomes easy to fit the hierarchical structure 160 in one screen. As a result, the entire structure of the ladder program 42 can be displayed in an easy-to-understand manner.
  • FIG. 2 is a schematic diagram showing a configuration example of a control system 1 to which the support device 10 can be applied.
  • the control system 1 includes a plurality of PLCs 200-1, 200-2, 200-3, 200-4, ... (hereinafter, also collectively referred to as "PLC200").
  • PLC200 PLCs 200-1, 200-2, 200-3, 200-4, ...
  • Each of the PLC 100 is an example of a control device that controls a control target that is a field device such as a relay or a sensor.
  • the support device 10 can be connected to the PLC 200 and provides an environment for supporting the development of the control program of the PLC 200.
  • the control system 1 may be configured to include one PLC200. In the following, for the sake of simplicity, a development environment for one PLC200 will be described.
  • the PLC 200 typically exchanges signals from a field with a CPU (Central Processing Unit) unit 20 that executes various programs including a control program, a power supply unit 22 that supplies power to the CPU unit 20 and the like. Includes an I / O (Input / Output) unit 24.
  • the I / O unit 24 is connected to the CPU unit 20 via the system bus 21.
  • the development support environment provided by the support device 10 may have a control program editor (editing), a debucker, a simulator, and a monitor function for outputting these output information to a monitor such as a display.
  • the support device 10 also has a function of acquiring the state value of the PLC 200 during operation and outputting it to a monitor such as a display.
  • the support program which is an application program stored in the optical recording medium 8
  • the support program may be downloaded from an external server device or the like via a network.
  • the support device 10 is connected to the CPU unit 20 of the PLC 200 via a connection cable.
  • FIG. 3 is a schematic view showing a hardware configuration example of the support device 10.
  • the support device 10 typically comprises a general purpose computer. From the viewpoint of maintainability at the manufacturing site where the PLC200 is arranged, a notebook-type personal computer having excellent portability is preferable.
  • the support device 10 includes a storage unit 101 and a CPU 102 that executes various programs including an operating system (OS).
  • the storage unit 101 includes a ROM (Read Only Memory) 104 that stores BIOS and various data, a RAM (Random Access Memory) 106 that provides a work area for storing data necessary for executing a program on the CPU 102, and the RAM (Random Access Memory) 106.
  • It includes a hard disk (HDD) 108 that non-volatilely stores programs and the like executed by the CPU 102.
  • the ROM 104 and the HDD 108 are examples of embodying a non-temporary computer-readable medium.
  • the support device 10 further includes an operation unit 103 including a keyboard 110 and a mouse 112 operated by the user to input instructions to the support device 10, and a display 114 for presenting information to the user.
  • the support device 10 includes a communication interface 118 for communicating with the PLC 200 (CPU unit 20) and the like.
  • the communication interface 118 may include a USB communication module for communicating with a USB (Universal Serial Bus) interface (not shown) included in the PLC 200.
  • the support device 10 includes an optical recording medium reading device 116 for reading a support program for providing a development support environment stored in the optical recording medium 8 from the optical recording medium 8.
  • the optical recording medium 8 is a concrete example of a non-temporary computer-readable medium.
  • FIG. 3 shows a configuration example in which necessary functions are provided by a processor such as the CPU 102 executing a program, and some or all of these provided functions are provided by a dedicated hardware circuit (for example,).
  • a dedicated hardware circuit for example, ASIC (Application Specific Integrated Circuit) or FPGA (Field-Programmable Gate Array), etc.
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • virtualization technology may be used to execute a plurality of OSs having different uses in parallel, and to execute necessary applications on each OS.
  • FIG. 4 is a schematic diagram showing a software configuration example of the support device 10.
  • FIG. 4 shows an example of information stored in the storage unit 101 in association with the software configuration of the support device 10.
  • the information stored in the storage unit 101 includes a ladder program 42, text information 460, parent-child information 480, position information 440, hierarchical structure 160, component information 430, setting information 450, and object information 52. Includes support program 54.
  • the ladder program 42 will be described as being stored in the storage unit 101 in a state before being compiled described in the ladder diagram.
  • the ladder program 42 includes a plurality of ladder circuits 420. Further, each ladder circuit 420 included in the ladder program 42 is edited and created by an editor 15 described later.
  • Text information 460 is stored for each ladder circuit 420.
  • Each text information 460 includes information that can identify which ladder circuit 420 corresponds to.
  • the text information 460 includes at least one of text information indicating the name of the ladder circuit 420 and text information indicating the order of the ladder circuits 420.
  • the parent-child information 480 is information input via the ladder screen 120, and is information indicating a hierarchical relationship between one ladder circuit 420 and another ladder circuit 420.
  • the parent-child information 480 includes information that can identify which ladder circuit 420 is the information input to.
  • the parent-child information 480 includes information indicating the division of the hierarchy and information indicating the depth of the hierarchy.
  • the parent-child information 480 is information that is input according to the input rule included in the setting information 450.
  • the input rule may be predetermined or may be a configuration that can be changed by the user.
  • the position information 440 is information indicating the position of each ladder circuit 420 on the ladder screen 120.
  • the position information 440 may indicate the position of each ladder circuit 420, and may indicate the order of the ladder circuits 420, for example.
  • the hierarchical structure 160 is information indicating the overall structure of the ladder circuit 420 included in the ladder program 42 defined by the definition unit 16 based on the parent-child information 480.
  • the hierarchical structure 160 is defined based on the input rule included in the setting information 450, the parent-child information 480, and the position information 440.
  • the part information 430 includes a function block called by a calling command included in the ladder program 42. Further, the component information 430 includes a component composed of one or a plurality of arbitrarily selected ladder circuits 420.
  • the setting information 450 adds or deletes an input rule for parent-child information 480, a display rule for displaying the ladder screen 120 and the hierarchical screen 180 on the display 114, a rule for redefining the hierarchical structure 160, and a new ladder circuit 420. Includes rules for doing so.
  • the object information 52 is used to visually display the ladder program 42 on the display 114.
  • the object information 52 includes each component for visually indicating the contents of the ladder program 42.
  • the object information 52 includes an input side bus 421, an output side bus 422, a contact 423, a coil 424, and the like.
  • the support program 54 includes a program for displaying the ladder program 42. Further, the support program 54 is a program for realizing various functions for developing a control program.
  • the various functions shown in FIG. 4 are realized by the CPU 102 executing the support program 54.
  • the support program 54 provides the functions of the reception unit 14, the editor 15, the ladder screen generation unit 12, the definition unit 16, the creation unit 17, the hierarchical screen generation unit 18, the componentization unit 19, and the display unit 11. do.
  • the reception unit 14 receives an operation input from the operation unit 103.
  • the reception unit 14 is typically an input interface.
  • the reception unit 14 receives input of parent-child information 480, change of position information 440, registration of part information 430, input of text information 460, and the like.
  • the change of the position information 440 includes the one based on the addition of the ladder circuit 420 or the deletion of the ladder circuit 420.
  • the editor 15 edits and creates the ladder program 42 according to the user operation.
  • the editor 15 may further provide an online editing function that rewrites (edits) a part of the control program executed while the PLC 200 is in operation.
  • the ladder screen generation unit 12 generates the ladder screen 120. As described above, a plurality of ladder circuits 420 are displayed side by side on the ladder screen 120, and the text information 460 registered for each ladder circuit 420 is displayed above the corresponding ladder circuit 420.
  • the ladder screen generation unit 12 updates the display content of the ladder screen 120 according to the received content. For example, when the reception unit 14 accepts the input of the parent-child information 480, the ladder screen generation unit 12 displays the input parent-child information 480 on the ladder screen 120.
  • the definition unit 16 defines the hierarchical structure 160 based on the parent-child information 480. In the present embodiment, the definition unit 16 defines the hierarchical structure 160 based on the input rule included in the setting information 450, the parent-child information 480, and the position information 440.
  • the definition unit 16 redefines the hierarchical structure 160 according to the received contents. For example, the definition unit 16 redefines the hierarchical structure 160 in response to the input of the parent-child information 480 or the change of the position information 440.
  • the creation unit 17 edits or creates the text information 460.
  • the creation unit 17 edits or creates the text information 460 when the reception unit 14 receives the input of the text information 460. Further, the creating unit 17 updates or creates the text information 460 according to the addition or deletion of the ladder circuit 420. Details will be described later.
  • the hierarchical screen generation unit 18 generates a hierarchical screen 180 in which the hierarchical structure 160 defined by the definition unit 16 is displayed with text information 460.
  • the expression method of the hierarchical structure 160 is not limited to the method of providing an indent at the beginning of the text information 460 shown in FIG. It may be an expression method in which a slash indicating a delimiter is inserted.
  • the hierarchical screen generation unit 18 updates the display contents of the hierarchical screen 180 according to the received contents. For example, the hierarchical screen generation unit 18 updates the display content of the hierarchical screen 180 when the hierarchical structure 160 is redefined or the content of the text information 460 is updated according to the content received by the reception unit 14. do.
  • the component unit 19 registers a plurality of ladder circuits 420 as one component in the component information 430. For example, in the componentization unit 19, when the reception unit 14 accepts the selection of one ladder circuit 420, all the ladder circuits 420 included in the child hierarchy of the selected ladder circuit 420 and the selected ladder circuit 420. Is registered in the part information 430 as one part.
  • the display unit 11 displays the ladder screen 120 generated by the ladder screen generation unit 12 and the hierarchical screen 180 generated by the hierarchical screen generation unit 18 on the display 114. Further, the display unit 11 changes the display range of the ladder screen 120 and the hierarchical screen 180 displayed on the display 114 when the reception unit 14 accepts the change of the display range. For example, the display unit 11 displays the ladder screen 120 so that the ladder circuit 420 corresponding to the text information 460 is displayed in the display 114 when one text information 460 is selected via the hierarchical screen generation unit 18. Change the display range.
  • FIG. 5 is an example of the user interface screen 140.
  • the user interface screen 140 is generated by the display unit 11 and displayed on the display 114.
  • the user interface screen 140 includes a first area 142 for displaying the ladder screen 120 and a second area 144 for displaying the hierarchical screen 180. Further, the ladder screen 120 is provided with a switching button 146 for expanding the first area 142 for displaying the ladder screen 120 by omitting the display of the hierarchical screen 180. Further, the user interface screen 140 is provided with a scroll bar 148 for changing the display range of the ladder screen 120 displayed on the first area 142.
  • the ladder screen 120 and the hierarchical screen 180 are displayed in one user interface screen 140.
  • the method of displaying the ladder screen 120 and the hierarchical screen 180 is not limited to this.
  • the ladder screen 120 and the hierarchical screen 180 may be displayed in separate windows.
  • FIG. 6 is a flowchart showing a display process executed when the ladder program 42 is displayed on the display 114.
  • the display process shown in FIG. 6 is a process for displaying the user interface screen 140 on the display 114.
  • the display process is called and executed from the main routine (not shown) at predetermined processing cycles, for example, when the display of the user interface screen 140 is requested.
  • the CPU 102 generates a ladder screen 120. More specifically, the CPU 102 displays the ladder program 42 in a circuit mode including a plurality of ladder circuits 420, and makes the text information 460 registered for each ladder circuit 420 correspond to the corresponding ladder circuit 420. A ladder screen 120 for display is generated. The text information 460 may be generated in the order in which the ladder circuits 420 are displayed. Further, in S101, the CPU 102 generates position information 440 indicating the position of each ladder circuit 420 on the ladder screen 120 when the ladder screen 120 is generated.
  • the CPU 102 accepts the input of the parent-child information 480. More specifically, when the special symbol "#" is input on the ladder screen 120, the CPU 102 accepts the input.
  • the layering process is executed.
  • the layering process is a process of defining a layered structure 160 of a plurality of ladder circuits 420 included in the ladder program 42.
  • the layering process is executed based on the position information 440 generated in S102 and the parent-child information 480 received in S102. The layering process will be described later with reference to FIG.
  • the CPU 102 generates a hierarchical screen 180. More specifically, the CPU 102 generates a hierarchical screen 180 in which the hierarchical structure 160 is represented by the text information 460, based on the text information 460 and the hierarchical structure 160.
  • the CPU 102 In S106, the CPU 102 generates a user interface screen 140 including the ladder screen 120 generated in S101 and the hierarchical screen 180 generated in S105, displays it on the display 114, and ends the display process.
  • the reception unit 14 accepts the change of the position information 440.
  • the reception unit 14 changes the position information 440 not only by the operation input via the ladder screen 120 but also by the operation performed based on the operation input via the hierarchical screen 180. accept.
  • the hierarchical structure 160 can be arbitrarily defined according to the positional relationship between the ladder circuits 420 on the ladder screen 120, the user can input the parent-child information 480 while checking the contents of each ladder circuit 420 having a parent-child relationship.
  • the positional relationship between the ladder circuits 420 can be changed by the operation via the hierarchical screen generation unit 18, and the hierarchical structure 160 can also be changed according to the change in the positional relationship. Therefore, the hierarchical structure 160 can be easily changed.
  • the position information 440 is changed not only when the order of the ladder circuit 420 is changed, but also when the ladder circuit 420 is added or when the ladder circuit 420 is deleted.
  • the change of the position information 440 is not limited to the operation of changing the order of the ladder circuit 420, but is also performed by the operation of adding the ladder circuit 420 and the operation of deleting the ladder circuit 420.
  • the processing when each operation is accepted will be described in detail.
  • FIG. 7 is a flowchart showing additional processing executed when the ladder circuit 420 is added.
  • the additional process is a process performed by the CPU 102 when an operation for adding the ladder circuit 420 is accepted.
  • the CPU 102 determines the position to insert the ladder circuit 420 according to the insertion rule.
  • the insertion rule is stored in the storage unit 101 in advance as setting information 450.
  • the insertion rule may be predetermined by the vendor providing the support program 54, or may be modifiable by the user.
  • the CPU 102 updates the position information 440. Specifically, the position information 440 of the newly added ladder circuit 420 is added, and the position information 440 of the ladder circuit 420 whose order is later than that of the newly added ladder circuit 420 is updated.
  • the CPU 102 updates the newly added ladder circuit 420 and the parent-child information 480 of the ladder circuit 420 adjacent to the newly added ladder circuit 420.
  • the CPU 102 updates the parent-child information 480 according to at least one of the ladder circuit 420 and the position where the ladder circuit 420 is added, which is selected when the ladder circuit 420 is added.
  • An example of updating the parent-child information 480 will be described later with reference to FIGS. 10 and 11.
  • the layering process is a process of defining a layered structure 160 of a plurality of ladder circuits 420 included in the ladder program 42.
  • the layering process is executed based on the position information 440 updated in S112 and the parent-child information 480 updated in S113. The layering process will be described later with reference to FIG.
  • the CPU 102 updates the text information 460.
  • the text information 460 includes information indicating the name of the ladder circuit 420 and information indicating the order of the ladder circuits 420.
  • the CPU 102 updates the information indicating the order of the ladder circuits 420 based on the position information 440 after being updated in S112. Further, the CPU 102 creates a name of the ladder circuit 420 to be newly added.
  • the creating unit 17 updates the information indicating the order of the ladder circuits 420 included in the text information 460 based on the updated position information 440, and newly adds the information indicating the order of the ladder circuits 420. Create a name for the added ladder circuit 420.
  • the name to be created may be a predetermined standard text (for example, "circuit comment"), or may be a text created according to a predetermined rule.
  • the creation unit 17 may create a text indicating the hierarchy to which the newly added ladder circuit 420 belongs as a name.
  • the CPU 102 updates the display of the ladder screen 120 based on various updated information by executing the processes of S111 to S115.
  • the CPU 102 updates the display of the hierarchical screen 180 based on various updated information by executing the processes of S111 to S115, and ends the additional process.
  • FIG. 8 is a diagram showing an example of an insertion rule.
  • the user can move the cursor P by operating the operation unit 103 to select one text information 460 on the hierarchical screen 180.
  • the ladder circuit 420 corresponding to the selected text information 460 is selected.
  • the additional processing shown in FIG. 7 is executed, and the screen shown on the left side of FIG. 8 transitions to the screen shown on the right side.
  • the CPU 102 adds a new ladder circuit 420 according to the rule of inserting a new ladder circuit 420 at the bottom of the child hierarchy of the selected ladder circuit 420.
  • a new ladder circuit 420 and text information 460 "2 circuit comment” are added to the second line on the ladder screen 120, and "2 circuit” is added on the hierarchical screen 180.
  • the text information 460 "comment" is added.
  • the insertion rule is not limited to the rule shown in FIG. 9 to 11 are diagrams showing other examples of insertion rules.
  • the CPU 102 may add a new ladder circuit 420 according to the rule of inserting a new ladder circuit 420 at the top of the child hierarchy of the selected ladder circuit 420.
  • a new ladder circuit 420 and text information 460 are added to the first line on the ladder screen 120, and the text "1. Circuit comment" is added on the hierarchical screen 180.
  • Information 460 is added.
  • the positions of the ladder circuits 420 from the first line onward are shifted one by one, and the text information 460 is also updated. Further, it is defined that the added new ladder circuit 420 is included in the child hierarchy of the ladder circuit 420 indicated by "Circuit 1".
  • the CPU 102 has the same layer as the selected ladder circuit 420, and the new ladder circuit 420 is inserted according to the rule that the ladder circuit 420 is inserted so as to be located one below the selected ladder circuit 420. May be added.
  • a new ladder circuit 420 and text information 460 are added to the second line on the ladder screen 120, which is under the child hierarchy of the ladder circuit 420 shown by "Circuit 1".
  • the text information 460 "2. Circuit comment” is added on the hierarchical screen 180.
  • the ladder circuits 420 on the second and subsequent lines are shifted one by one, and the text information 460 is also updated. Further, it is defined that the added new ladder circuit 420 has the same layer as the ladder circuit 420 indicated by "0. Circuit 1".
  • the CPU 102 adds a new ladder circuit 420 in the same hierarchy as the selected ladder circuit 420, according to the rule that the ladder circuit 420 is inserted at the bottom of the hierarchy of the selected ladder circuit 420. You may. According to this rule, as shown in FIG. 11, a new ladder circuit 420 and text information 460 are added to the 10th line on the ladder screen 120, and the text "10. Circuit comment" is added on the hierarchical screen 180. Information 460 is added. Further, it is defined that the added new ladder circuit 420 has the same layer as the ladder circuit 420 indicated by "0. Circuit 1".
  • the parent-child information 480 is updated as necessary. Specifically, the parent-child information 480 is updated based on whether or not the parent-child information 480 is input to the selected ladder circuit 420 and at least one of the insertion positions. For example, as shown in FIGS. 10 and 11, when the ladder circuit 420 to which the parent-child information 480 is input is selected and the ladder circuit 420 is added to the same layer as the selected ladder circuit 420, the added ladder is added. Parent-child information 480 is added to the circuit 420.
  • the insertion rule is not limited to that shown in FIGS. 8 to 11.
  • the CPU 102 may add a new ladder circuit 420 in the same layer as the selected ladder circuit 420 according to the rule that the ladder circuit 420 is inserted at the top of the layer of the selected ladder circuit 420.
  • the hierarchical structure 160 is redefined every time the ladder circuit 420 is added as described above, so that the hierarchical structure 160 can be easily defined.
  • the CPU 102 may add the ladder circuit 420 without considering the hierarchy.
  • FIG. 12 is a diagram showing an example of an insertion rule that does not consider the hierarchy.
  • the CPU 102 may add a new ladder circuit 420 one above the selected ladder circuit 420 without considering the hierarchy of the selected ladder circuit 420. Since the CPU 102 does not consider the hierarchy, the CPU 102 does not execute the process of adding the parent-child information 480. Even when the ladder circuit 420 is inserted according to any of the above-mentioned insertion rules, the CPU 102 does not have to execute the process of adding or changing the parent-child information 480.
  • FIG. 13 is a diagram for explaining an example of a rule for creating text information 460.
  • the creation unit 17 may create new text information 460 according to a predetermined rule.
  • the creation unit 17 corresponds to the added ladder circuit 420 based on the redefined hierarchical structure 160 and the text information 460 corresponding to the ladder circuit 420 of the layer to which the added ladder circuit 420 belongs.
  • Text information 460 may be created.
  • the newly added ladder circuit 420 is a child layer of the circuit 1, and is the second from the top of the ladder circuit 420 included in the child layer.
  • the text information 460 corresponding to the ladder circuit 420 (parent ladder circuit 420) of the layer to which the newly added ladder circuit 420 belongs is "circuit 1".
  • the creating unit 17 creates the text information 460 of "circuit 1-2".
  • the text information 460 corresponding to the added ladder circuit 420 is created. Therefore, for the newly added ladder circuit 420, text information 460 indicating the hierarchy of the ladder circuit 420 can be generated.
  • FIG. 14 is an example of screen transition when copy and paste is performed.
  • the additional process shown in FIG. 7 is performed.
  • the text information 460 corresponding to the newly added ladder circuit 420 may be a copy of the original text information 460, and the creation unit 17 may use the text information 460. It may be newly created.
  • the CPU 102 may provide a mark clearly indicating the added portion on the ladder screen 120 and the hierarchical screen 180.
  • FIG. 15 is a flowchart showing a deletion process executed when the ladder circuit 420 is deleted.
  • the deletion process is a process performed by the CPU 102 when an operation for deleting the ladder circuit 420 is accepted.
  • the CPU 102 determines the deletion target according to the deletion rule.
  • the deletion rule is stored in the storage unit 101 in advance as setting information 450.
  • the deletion rule may be predetermined by the vendor providing the support program 54, or may be changed by the user.
  • the CPU 102 updates the position information 440. More specifically, the position information 440 of the ladder circuit 420, which is later in order than the ladder circuit 420 to be deleted, is updated.
  • the CPU 102 updates the parent-child information 480.
  • the CPU 102 updates the parent-child information 480 according to the ladder circuit 420 to be deleted.
  • An example of updating the parent-child information 480 will be described later with reference to FIG.
  • the layering process is a process of defining a layered structure 160 of a plurality of ladder circuits 420 included in the ladder program 42.
  • the layering process is executed based on the position information 440 updated in S122 and the parent-child information 480 updated in S123.
  • the layering process will be described later with reference to FIG.
  • the layered process executed in the delete process and the layered process executed in the additional process of FIG. 7 are common processes.
  • the CPU 102 updates the text information 460.
  • the text information 460 includes the name of the ladder circuit 420 and information indicating the order of the ladder circuits 420.
  • the CPU 102 updates the information indicating the order of the ladder circuits 420 based on the position information 440 after being updated in S122.
  • the above-mentioned creation unit 17 updates the information indicating the order of the ladder circuits 420 included in the text information 460 based on the updated position information 440.
  • the CPU 102 updates the display of the ladder screen 120 based on various updated information by executing the processes of S121 to S125.
  • the CPU 102 updates the display of the hierarchical screen 180 based on various updated information by executing the processes of S121 to S125, and ends the deletion process.
  • FIG. 16 is a diagram showing an example of a deletion rule.
  • the user can move the cursor P by operating the operation unit 103 to select one or more text information 460 on the hierarchical screen 180.
  • the ladder circuit 420 corresponding to the selected text information 460 is selected.
  • one text information 460 is selected, but a plurality of text information 460 may be selected.
  • the deletion process shown in FIG. 15 is executed, and the screen shown on the left side of FIG. 16 transitions to the screen shown on the right side.
  • the CPU 102 deletes the ladder circuit 420 according to the deletion rule of deleting the selected ladder circuit 420, and executes the process of S123 according to the rule that the parent-child information 480 is not updated.
  • the ladder circuit 420 on the seventh and subsequent lines on the ladder screen 120 is moved up, and the text information 460 is also updated.
  • the ladder circuit 420 indicated by the "circuit 2-1-2-1" included in the child hierarchy of the ladder circuit 420 indicated by the “circuit 2-1-2" to be deleted is ". It will be included in the child hierarchy of the ladder circuit 420 indicated by "Circuit 2-1-1".
  • the deletion rule is not limited to the rule shown in FIG. FIG. 17 is a diagram showing another example of the deletion rule.
  • the CPU 102 may determine the selected ladder circuit 420 and the ladder circuit 420 included in the child hierarchy of the selected ladder circuit 420 as deletion targets. More specifically, referring to FIG. 17, when the ladder circuit 420 indicated by "Circuit 2-1-2" is selected, the CPU 102 indicates the deletion target by "Circuit 2-1-2". The ladder circuit 420 and the ladder circuit 420 indicated by the "circuit 2-1-2-1" defined in the child hierarchy of the ladder circuit 420 indicated by the "circuit 2-1-2" may be determined.
  • the selected ladder circuit 420 and the ladder circuit 420 included in the child hierarchy of the selected ladder circuit 420 are targeted for deletion, so that one ladder circuit 420 is selected and the plurality of ladder circuits 420 are deleted. can.
  • the ladder program 42 can be easily edited, and the convenience at the time of development is improved.
  • FIG. 18 is a diagram showing an example of an update rule for the parent-child information 480.
  • the CPU 102 may move up one layer of the ladder circuit 420 in the child layer.
  • the CPU 102 is indicated by the “circuit 2-1-2-1” included in the child hierarchy of the ladder circuit 420 indicated by the “circuit 2-1-2” to be deleted.
  • FIG. 19 is a flowchart showing a movement process executed when the ladder circuit 420 is moved.
  • the move process is a process performed by the CPU 102 when an operation for moving the ladder circuit 420 is accepted.
  • the CPU 102 updates the position information 440. More specifically, the CPU 102 updates the position information 440 of the ladder circuit 420, which is later in order than the ladder circuit 420 to be moved and earlier in order than the destination.
  • the CPU 102 updates the parent-child information 480. For example, the CPU 102 updates the parent-child information 480 before and after moving the ladder circuit 420 to be selected so that the parent-child relationship of the ladder circuits 420 other than the selection target does not change.
  • the CPU 102 updates the parent-child information 480 so that the parent-child relationship between the ladder circuit 420 to be selected and the ladder circuits 420 located before and after the insertion destination satisfies a predetermined rule.
  • the CPU 102 updates the parent-child information 480 so that the ladder circuit 420 to be selected becomes a child of the ladder circuit 420 located in front of the insertion destination.
  • the CPU 102 may update the parent-child information 480 so that the ladder circuit 420 to be selected has the same layer as the ladder circuit 420 located before or after the insertion destination.
  • the layering process is a process of defining a layered structure 160 of a plurality of ladder circuits 420 included in the ladder program 42.
  • the layering process is executed based on the position information 440 updated in S132 and the parent-child information 480 updated in S133.
  • the layering process will be described later with reference to FIG.
  • the layered process executed in the move process, the layered process executed in the additional process of FIG. 7, and the layered process executed in the delete process of FIG. 15 are common processes to each other.
  • the CPU 102 updates the text information 460.
  • the text information 460 includes the name of the ladder circuit 420 and information indicating the order of the ladder circuits 420.
  • the CPU 102 updates the information indicating the order of the ladder circuits 420 based on the position information 440 after being updated in S132.
  • the above-mentioned creation unit 17 updates the information indicating the order of the ladder circuits 420 included in the text information 460 based on the updated position information 440.
  • the CPU 102 updates the display of the ladder screen 120 based on various updated information by executing the processes of S132 to S135.
  • the CPU 102 updates the display of the hierarchical screen 180 based on various updated information by executing the processes of S132 to S135, and ends the deletion process.
  • FIG. 20 is a diagram showing an example of screen transition due to a movement operation.
  • the user can move the cursor P by operating the operation unit 103 to select one or more text information 460 on the hierarchical screen 180.
  • the ladder circuit 420 corresponding to the selected text information 460 is selected.
  • one text information 460 is selected, but a plurality of text information 460 may be selected.
  • the move process shown in FIG. 19 is executed, and the screen shown on the left side of FIG. 20 transitions to the screen shown on the right side.
  • the CPU 102 inserts the ladder circuit 420 indicated by “Circuit 1-1” on the first line between the seventh line and the eighth line.
  • the CPU 102 inserts the ladder circuit 420 indicated by "Circuit 1-1" on the first line between the seventh and eighth lines into the ladder circuit 420 from the second line to the seventh line. Update the corresponding text information 460. Further, in the example shown in FIG. 19, the CPU 102 inputs the parent-child information 480 to the selected ladder circuit 420 so as to be a child layer of the ladder circuit 420 located in front of the insertion destination. More specifically, the CPU 102 inputs the parent-child information 480 "######" to the ladder circuit 420 on the 7th line. The CPU 102 may provide a mark 124 on the ladder screen 120 so that the ladder circuit 420 to be moved can be known.
  • FIG. 21 is a flowchart showing a layering process for defining the layered structure 160.
  • the hierarchical processing shown in FIG. 21 is an example, and the hierarchical structure 160 may be defined by another processing procedure.
  • the layering process shown in FIG. 21 is executed in the above-mentioned display process, addition process, deletion process, and move process.
  • the layering process executed in each of the display process, the add process, the delete process, and the move process may be a common process, or may be a layered process unique to each process.
  • the layering process executed in each of the display process, the add process, the delete process, and the move process will be described as a common process.
  • the CPU 102 uses the ladder circuit 420 on the first line as the target ladder circuit.
  • the CPU 102 determines whether or not the parent-child information 480 is input to the target ladder circuit 420. When it is determined that the parent-child information 480 is not input to the target ladder circuit 420 (NO in S142), in S144, the CPU 102 sets the target ladder circuit 420 in the same layer as the previous ladder circuit 420.
  • the CPU 102 sets the layer of the target ladder circuit 420 to the top layer.
  • the depth of the layer is set based on the input parent-child information 480. Then, based on the position information 440, the CPU 102 is among the ladder circuits 420 set in the ladder circuit 420 before the target ladder circuit 420 and one layer higher than the set depth layer.
  • the ladder circuit 420 closest to the target ladder circuit 420 is the parent.
  • the CPU 102 After executing the process of S144 or S146, the CPU 102 determines in S148 whether or not there is a ladder circuit 420 behind it based on the position information 440.
  • the CPU 102 determines that there is a ladder circuit 420 behind (YES in S148)
  • the CPU 102 changes the target ladder circuit 420 to the ladder circuit 420 one behind in S150, and executes the processes of S142 to S148.
  • the CPU 102 executes S150 and repeats the processes of S142 to S148 until it is determined that there is no ladder circuit 420 behind.
  • the CPU 102 determines that there is no ladder circuit 420 behind (NO in S148)
  • the CPU 102 ends the layering process.
  • the layer screen generation unit 18 displays or omits the text information 460 corresponding to the ladder circuit 420 included in the child layer of the one ladder circuit 420 selected via the layer screen 180 on the layer screen 180. Can be done.
  • FIG. 22 is a diagram showing an example of abbreviated display and expanded display.
  • the hierarchical screen generation unit 18 provides, for example, a tab 182 on the hierarchical screen 180 for switching between abbreviated display and expanded display.
  • the hierarchical screen generation unit 18 displays (expanded display) or omits (omitted) the text information 460 corresponding to the ladder circuit 420 of the child hierarchy on the hierarchical screen 180.
  • the screen shown on the left side in FIG. 22 is an example of the screen being expanded and displayed.
  • the screen shown on the right side in FIG. 22 is an example of the screen being abbreviated.
  • the text information 460 corresponding to the ladder circuit 420 located in the child hierarchy of the ladder circuit 420 corresponding to the “circuit 2” is “. 4. "Circuit 2-1", “5. Circuit 2-1-2”, “6. Circuit 2-1-2”, “7. Circuit 2-1-2-1” are displayed or omitted. Or The hierarchical screen generation unit 18 may make the shape of the tab 182 different between the shape in the expanded display and the shape in the omitted display in order to indicate that the tab 182 is omitted.
  • the ladder screen generation unit 12 may switch the display on the ladder screen 120 according to the switching between the abbreviated display and the expanded display of the hierarchical screen generation unit 18.
  • FIG. 23 is a diagram showing other examples of abbreviated display and expanded display. The screen shown on the left side in FIG. 23 is an example of the screen being expanded and displayed. The screen shown on the right side in FIG. 22 is an example of the screen being abbreviated.
  • the ladder screen generation unit 12 displays on the ladder screen 120 the display of the ladder circuit 420 corresponding to the text information 460 whose display is omitted on the hierarchical screen 180 during the omitted display. It may be omitted. At this time, the ladder screen generation unit 12 may provide a mark 122 indicating the reduction and the reduced portion on the ladder screen 120.
  • such a function of switching between the reduced display and the expanded display is particularly effective when the number of ladder circuits 420 is large.
  • the user can grasp the whole image of the ladder program 42 by the reduced display and can examine the ladder program 42 in detail by switching to the expanded display.
  • the ladder screen generation unit 12 may provide a tab corresponding to the tab 182 on the ladder screen 120 and switch between the abbreviated display and the expanded display according to the operation for the tab.
  • the hierarchical screen generation unit 18 may or may not switch between the omitted display and the expanded display of the hierarchical screen 180 according to the switching between the omitted display and the expanded display of the ladder screen 120.
  • the ladder screen generation unit 12 may generate a ladder screen 120 expressing the hierarchical structure 160 defined by the definition unit 16 by changing the display mode of each ladder circuit 420.
  • the ladder screen generation unit 12 has a ladder screen 120 in which the background of the area for displaying each ladder circuit 420 is different between the one ladder circuit 420 and the ladder circuit 420 included in the child hierarchy of the one ladder circuit 420. May be generated.
  • FIG. 24 is a diagram showing an example of a ladder screen 120 showing the hierarchical structure 160.
  • the ladder screen generation unit 12 uses the background A of the range for displaying the ladder circuit 420 of the uppermost layer (first layer) as the background A and the background B of the range for displaying the ladder circuit 420 of the second layer as the background B. Then, the ladder screen 120 may be generated with the background of the range in which the ladder circuit 420 of the third layer is displayed as the background C.
  • the user can easily grasp the division of the layers simply by checking the ladder screen 120 without checking the layer screen 180.
  • FIG. 25 is a diagram showing how the range of the ladder screen 120 displayed in the first area 142 is changed.
  • the ladder circuit 420 corresponding to the text information 460 is displayed in the first area 142 of the display 114.
  • the display range of the ladder screen 120 may be changed as described above.
  • FIG. 25 when a specific operation (for example, double-clicking) is accepted while the cursor P is placed on one text information 460 on the hierarchical screen 180, as shown on the right side of FIG. 25. , The display range of the ladder screen 120 displayed in the first area 142 is changed.
  • the display unit 11 when one text information 460 on the hierarchical screen 180 is selected and a specific operation is accepted, the display unit 11 has a ladder circuit 420 corresponding to the selected text information 460 in the first region.
  • the display range of the ladder screen 120 is changed so that it is located at the top of 142.
  • the display unit 11 changes the display range of the ladder screen 120 so that the selected ladder circuit 420 is located at the uppermost part of the first area 142.
  • the position where the selected ladder circuit 420 is displayed is not limited to the uppermost part of the ladder screen 120, and any of the positions on the first area 142 such as the center of the first area 142 and the lowermost part of the first area 142. It may be a position.
  • the user can arbitrarily define the overall structure of the ladder program 42 while creating the ladder circuit 420, and display the defined overall structure (hierarchical structure 160) on the hierarchical screen 180. Since the display range of the ladder screen 120 can be changed by the operation via the hierarchical screen 180, the user can easily find the target ladder circuit 420 even when the number of ladder circuits 420 increases.
  • the component unit 19 registers the plurality of ladder circuits 420 as one component in the component information 430. More specifically, the componentization unit 19 includes everything included in the selected ladder circuit 420 and the child hierarchy of the selected ladder circuit 420 when the reception unit 14 accepts the selection of one ladder circuit 420. The ladder circuit 420 of the above is registered in the component information 430 as one component.
  • FIG. 26 is a diagram showing how one or a plurality of ladder circuits 420 are registered as one component.
  • the componentization unit 19 is indicated by “circuit 1".
  • Part information 430 with a program consisting of the ladder circuit 420 and the ladder circuit 420 of "circuit 1-1" and “circuit 1-2" included in the child hierarchy of the ladder circuit 420 indicated by “circuit 1" as one component. Register with.
  • a program composed of one or a plurality of ladder circuits 420 registered as component information 430 may be displayed in a separate window.
  • a POU corresponds to a unit of a group of program elements. That is, in other words, the componentization unit 19 registers the selected ladder circuit 420 and all the ladder circuits 420 included in the child layers of the selected ladder circuit 420 as one POU in the component information 430.
  • This user proceeds with the development of the ladder program 42 while adding or deleting the ladder circuit 420 on the ladder screen 120.
  • the user since the input of the parent-child information 480 is accepted via the ladder screen 120, the user can define an arbitrary hierarchical structure 160 while proceeding with the development of the ladder program 42. Then, among the hierarchical structures 160 arbitrarily defined by the user, all the ladder circuits 420 included in one layer can be registered as one component. That is, the user can arbitrarily define the hierarchical structure 160 and at the same time create reusable parts.
  • the ladder program 42 includes one or more call instructions that call another POU.
  • the layer screen generation unit 18 generates the layer screen 180 so that the child layer of the ladder circuit 420 including the call command includes the POU called by the call command.
  • FIG. 27 is a diagram showing an example of a screen in which the POU is displayed as a child layer of the ladder circuit of the caller.
  • the ladder circuit 420 shown by “Circuit 1” shown in FIG. 27 includes a call instruction 425 that calls a function which is an example of a POU named “Faction 0”.
  • the ladder circuit 420 shown by “Circuit 1-1” shown in FIG. 27 includes a call instruction 425 that calls a function block which is an example of a POU named “excellentBlock0”.
  • the layer screen generation unit 18 includes a POU of "Faction 0" in the child layer of "Circuit 1" and “Faction Block 0" in the child layer of "Circuit 1-1".
  • the hierarchical screen 180 is generated so that the POU of is included.
  • the call instruction 425 included in the ladder circuit 420 is displayed on the layer screen 180 as a child layer of the ladder circuit 420, so that what kind of POU is called in each ladder circuit 420 is displayed on the layer screen. It can be displayed on 180.
  • FIG. 28 is a flowchart showing the layering process according to the modified example.
  • FIG. 29 is a diagram showing an example of the hierarchical structure 160 defined according to the hierarchical processing according to the modified example.
  • the layering process according to the modified example is different from the layering process shown in the above embodiment in that S143, S145, and S147 are executed instead of S144 as compared with the layering process shown in FIG.
  • S143, S145, and S147 are executed instead of S144 as compared with the layering process shown in FIG.
  • the points different from the above-described embodiment will be mainly described.
  • the CPU 102 determines that the parent-child information 480 is not input to the target ladder circuit 420 (NO in S142), the CPU 102 executes the processes of S143, S145, and S147.
  • the CPU 102 determines whether or not the parent-child information 480 is input to the previous ladder circuit 420.
  • the previous ladder circuit 420 is specified based on the position information 440.
  • the CPU 102 determines that the parent-child information 480 is not input to the previous ladder circuit 420 (NO in S143), the CPU 102 sets the target ladder circuit 420 in the same layer as the previous ladder circuit 420 in S145.
  • the CPU 102 determines that the parent-child information 480 is input to the previous ladder circuit 420 (YES in S143), the CPU 102 sets the target ladder circuit 420 in the child hierarchy of the previous ladder circuit 420 in S147.
  • the depth of the layer and the ladder circuit 420 of the parent are set based on the input of the parent-child information 480 (S146). For example, as shown in FIG. 29, the depth of the hierarchy is set by the number of "#”, and “circuit 1", “circuit 2", and “circuit 3" in which one "#” is input are set. Is set to the top layer (first layer). Further, “Circuit 2-1" and “Circuit 3-1" in which two "#" are input are set in the second layer.
  • the ladder circuit 420 described next to the ladder circuit 420 to which the parent-child information 480 is input is set to the child layer of the ladder circuit 420 to which the parent-child information 480 is input (S147). ).
  • the "circuit 1-1" next to the “circuit 1" in which one "#" is input is set in the child hierarchy of the "circuit 1".
  • the ladder circuits 420 located above and below are all set to the same layer. (S145). For example, as shown in FIG. 29, "Circuit 1-1" and “Circuit 1-2" in which "#" is not input are both set in the same hierarchy.
  • layering rule is an example, and any rule can be set, not limited to the rule shown in the above embodiment and the rule shown in the modified example.
  • (Structure 1) An information processing device (10) that displays a ladder program (42).
  • a ladder screen generator (12) for generating a ladder screen (120) for displaying the ladder program (42) in a circuit mode including a plurality of ladder circuits (420) is provided.
  • a plurality of the ladder circuits (420) are displayed on the ladder screen, and text information (460) registered for each ladder circuit (420) is displayed corresponding to the corresponding ladder circuit (420).
  • a reception unit (14) that receives input of parent-child information (480) indicating a parent-child relationship between one ladder circuit (420) and another ladder circuit (420) in response to an operation on the ladder screen (120).
  • a definition unit (16) that defines a hierarchical structure (160) of a plurality of the ladder circuits (420) included in the ladder program (42) based on the parent-child information (480) received by the reception unit (14).
  • An information processing device further including a hierarchical screen generation unit (18) for generating a hierarchical screen (180) for displaying the hierarchical structure (160) defined by the definition unit (16) with the text information (460). ..
  • Each of the text information (460) included in the hierarchical screen (180) is associated with position information (440) indicating the position of the corresponding ladder circuit (420) on the ladder screen (120).
  • the selected text information (460) is included in the area (142, 114) for displaying the ladder screen (120). ) Is displayed, the information processing apparatus according to the configuration 1.
  • the definition unit (18) is The hierarchical structure (160) is defined based on the position information (440) indicating the position of the ladder circuit (420) on the ladder screen (120) and the parent-child information (480).
  • the information processing apparatus according to configuration 1, wherein the hierarchical structure (160) is redefined (S114, S124, S134) in response to the change in the position information (440) being accepted.
  • the definition unit (16) has a predetermined additional rule and the selected ladder circuit when an additional operation of the ladder circuit (420) is performed while one of the ladder circuits (420) is selected.
  • the information processing apparatus according to configuration 3 or 4, wherein the hierarchical structure (160) is redefined based on the hierarchy of (420) (S111 to S114).
  • a creation unit (17) for editing or creating the text information (460) is further provided.
  • the creation unit (17) redefines the hierarchical structure (160) when a change in the position information (440) is accepted in response to the addition of the ladder circuit (420) (S112). ) And the text information (460) corresponding to the ladder circuit (420) in the hierarchy to which the added ladder circuit (420) belongs, and the text corresponding to the added ladder circuit (420).
  • the information processing apparatus according to configuration 3 or 4, wherein the information (460) is created (S115).
  • the reception unit (14) accepts the selection of one ladder circuit (420), and also includes the selected ladder circuit (420) and the ladder included in the child hierarchy of the selected ladder circuit (420).
  • the information processing apparatus according to configuration 1, which accepts a circuit (420) as a component (430) of one management unit.
  • the layer screen generation unit (18) has the text information corresponding to the ladder circuit (420) included in the child layer of the selected ladder circuit (420).
  • the information processing apparatus according to configuration 1, which generates the hierarchical screen (180) in which (460) is omitted.
  • the ladder screen generation unit (12) is different from the ladder circuit included in the same layer and the ladder circuit included in a different layer based on the hierarchical structure (160) defined by the definition unit (16).
  • the ladder program (42) includes one or more calling instructions (425) that call a block composed of a set of program elements.
  • the layer screen generation unit (18) has the layer screen (180) so that the child layer of the ladder circuit (420) including the call command (425) includes the block called by the call command (425).
  • the information processing apparatus according to configuration 1, wherein the information processing apparatus is generated.
  • a step (S101) of generating a ladder screen (120) for displaying the ladder program (42) in a circuit mode including a plurality of ladder circuits (420) is included.
  • a plurality of the ladder circuits (420) are displayed on the ladder screen (120), and the text information (460) registered for each ladder circuit (420) corresponds to the corresponding ladder circuit (420).
  • a support program further comprising a step (S105) of generating a hierarchical screen (180) for displaying the defined hierarchical structure (160) in the text information (460).
  • a step (S101) of generating a ladder screen (120) for displaying the ladder program (42) in a circuit mode including a plurality of ladder circuits (420) is included.
  • a plurality of the ladder circuits (420) are displayed on the ladder screen (120), and the text information (460) registered for each ladder circuit (420) corresponds to the corresponding ladder circuit (420).
  • a method for displaying a ladder program further comprising a step (S105) of generating a hierarchical screen (180) for displaying the defined hierarchical structure (160) in the text information (460).

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Programmable Controllers (AREA)

Abstract

サポート装置(10)は、ラダープログラム(42)を複数のラダー回路(420)を含む回路態様で表示するとともに、ラダー回路(420)ごとに登録されたテキスト情報(460)を対応するラダー回路(420)に対応付けて表示するためのラダー画面(120)と、ラダー画面(120)を介して入力された親子情報(480)に基づいて定義された階層構造(160)をテキスト情報(460)で表示するための階層画面(180)とを表示する。

Description

情報処理装置およびラダープログラムを表示するためのプログラム
 本開示は、ラダープログラムを表示する情報処理装置およびラダープログラムを表示するためのプログラムに関する。
 様々な製造現場において、PLC(Programmable Logic Controller)などの制御装置が導入されている。このような制御装置は、一種のコンピュータであり、製造装置や製造設備などに応じて設計されたユーザプログラムを実行する。このようなユーザプログラムは、制御装置とは別に用意された開発環境にて作成される。
 ユーザプログラムを記述するためのプログラミング言語には、複数の命令要素を互いに繋いだ回路態様で表示可能なラダーダイアグラム(LD:Ladder Diagram)を含む。複数の命令要素を互いに繋いだ回路態様で記述されたプログラムは、「ラダープログラム」とも言われる。
 ユーザプログラムを開発するための環境を提供する開発支援装置として、ラダープログラムを作成する際に、各ラダープログラムの内容を理解しやすくするために、ラダープログラム内に適宜コメント行を設けるものが知られている(たとえば、特開2017-059046号公報(特許文献1)参照)。
特開2017-059046号公報
 ラダープログラムは、接点およびコイル等の組み合わせで表現される論理回路が梯子状に描かれた構成を有している。コイルは、接点を組み合わせた論理演算の結果の出力先を示す。また、一の論理回路が他の論理回路の結果を受け、さらに、他の論理回路が、別の他の論理回路の結果を受けるような階層的な表現でラダープログラムは記述されることもある。
 従来の開発支援装置によるラダープログラムの表示方法では、逐次実行される論理回路の内容を理解しやすくすることはできたものの、階層のない表現であったため、ラダープログラムの全体構造がわかりにくかった。
 本発明は、上記課題を解決することを目的とするものであって、ラダープログラムの階層構造を分かりやすく表示することを目的とする。
 本開示の一例によれば、ラダープログラムを表示する情報処理装置が提供される。情報処理装置は、ラダー画面生成部と、受付部と、定義部と、階層画面生成部とを含む。ラダー画面生成部は、ラダープログラムを複数のラダー回路を含む回路態様で表示するためのラダー画面を生成する。ラダー画面には、複数のラダー回路が表示されるとともに、ラダー回路ごとに登録されたテキスト情報が対応するラダー回路に対応して表示される。受付部は、ラダー画面に対する操作に応じて、一のラダー回路と他のラダー回路との親子関係を示す親子情報の入力を受け付ける。定義部は、受付部が受け付けた親子情報に基づいて、ラダープログラムに含まれる複数のラダー回路の階層構造を定義する。階層画面生成部は、定義部が定義した階層構造をテキスト情報で表示するための階層画面を生成する。
 この開示によれば、テキスト情報であれば、インデントを設けたり、あるいは、罫線でテキスト情報同士をつなげたりする方法によって容易に階層構造を表現できる。その結果、情報処理装置は、ラダープログラムの全体構造を分かり易く表示できる。
 上述の開示において、階層画面に含まれるテキスト情報の各々は、対応するラダー回路のラダー画面上における位置を示す位置情報に関連付けられていてもよい。この場合に、階層画面を介してテキスト情報が選択されたことに応じて、ラダー画面を表示する領域内に、選択されたテキスト情報に対応するラダー回路が表示されるようにしてもよい。
 この開示によれば、階層構造を表示した階層画面を介した操作によりラダー画面の表示範囲を変更できるため、目的のラダー回路を容易に表示できる。
 上述の開示において、定義部は、ラダー回路のラダー画面上における位置を示す位置情報と親子情報とに基づいて階層構造を定義し、位置情報の変更が受け付けられたことに応じて階層構造を定義し直してもよい。
 この開示によれば、ラダー画面上におけるラダー回路間の位置関係に応じて任意に階層構造を定義できるため、ユーザは、親子関係とする各ラダー回路の内容を確認しながら親子情報を入力できる。
 上述の開示において、受付部は、階層画面に対する操作に応じて位置情報の変更を受け付けてもよい。
 この開示によれば、階層構造を表示した階層画面を介した操作によりラダー回路間の位置関係を変更でき、位置関係の変更に応じて階層構造も変更できる。そのため、階層構造の変更を容易に行うことができる。
 上述の開示において、定義部は、一のラダー回路が選択された状態でラダー回路の追加操作がされた場合に、予め定められた追加ルールと選択されたラダー回路の階層とに基づいて階層構造を定義し直してもよい。
 この開示によれば、ラダー回路を追加してラダープログラムを開発していく際に、容易に階層構造を定義できる。
 上述の開示において、情報処理装置は、テキスト情報の編集または作成を行う作成部をさらに含み得る。この場合に、作成部は、ラダー回路が追加されたことに応じて位置情報の変更が受け付けられた場合に、定義し直された階層構造と、追加されたラダー回路が属する階層のラダー回路に対応するテキスト情報とに基づいて、追加されたラダー回路に対応するテキスト情報を作成してもよい。
 この開示によれば、新たに追加されたラダー回路の階層を示したテキスト情報を生成できる。
 上述の開示において、一のラダー回路が選択された状態でラダー回路の削除操作がされた場合、選択されたラダー回路と、選択されたラダー回路の子階層に含まれるラダー回路とが削除されてもよい。
 この開示によれば、ラダープログラムの開発をする際の利便性が向上する。
 上述の開示において、受付部は、一のラダー回路の選択を受け付けるとともに、選択されたラダー回路および、選択されたラダー回路の子階層に含まれるラダー回路を一の管理単位の部品として受け付けてもよい。
 この開示によれば、親子情報の入力により任意の階層構造を定義できるとともに、再利用できる部品の作成も同時にできる。
 上述の開示において、ラダー画面生成部は、ラダー回路が選択された場合に、選択されたラダー回路の子階層に含まれるラダー回路を省略したラダー画面を生成してもよい。
 この開示によれば、ラダープログラムの全体構造をより分かり易く表示できる。
 上述の開示において、階層画面生成部は、ラダー回路が選択された場合に、選択されたラダー回路の子階層に含まれるラダー回路に対応するテキスト情報を省略した階層画面を生成してもよい。
 この開示によれば、ラダープログラムの全体構造をより分かり易く表示できる。
 上述の開示において、ラダー画面生成部は、定義部が定義した階層構造に基づいて、同じ階層に含まれるラダー回路と異なる階層に含まれるラダー回路とを互いに異なる表示態様で表示したラダー画面を生成してもよい。
 この開示によれば、ラダー画面を確認するだけで、階層の区切りをユーザに容易に把握させることができる。
 上述の開示において、ラダープログラムは、プログラム要素のまとまりから構成されたブロックを呼び出す1または複数の呼出命令を含み得る。階層画面生成部は、呼出命令を含むラダー回路の子階層に呼出命令によって呼び出されるブロックが含まれるように階層画面を生成してもよい。
 この開示によれば、各ラダー回路でどのようなブロックが呼び出されるかを階層画面上に表示できる。
 本開示の別の一例によれば、ラダープログラムを表示するためのサポートプログラムが提供される。サポートプログラムは、ラダープログラムを複数のラダー回路を含む回路態様で表示するとともに、ラダー回路ごとに登録されたテキスト情報を対応するラダー回路に対応させて表示するためのラダー画面を生成するステップと、ラダー画面に対する操作に応じて、一のラダー回路と他のラダー回路との親子関係を示す親子情報の入力を受け付けるステップと、受け付けられた親子情報に基づいて、ラダープログラムに含まれる複数のラダー回路の階層構造を定義するステップと、定義された階層構造をテキスト情報で表示するための階層画面を生成するステップとを含む。
 この開示によれば、テキスト情報であれば、インデントを設けたり、あるいは、罫線でテキスト情報同士をつなげたりする方法によって容易に階層構造を表現できる。その結果、情報処理装置は、ラダープログラムの全体構造を分かり易く表示できる。
 本開示の一例によれば、ラダープログラムの全体構造を分かりやすく表示できる。
本実施の形態に係るサポート装置10の機能構成を示すブロック図である。 サポート装置10を適用可能な制御システム1の構成例を示す模式図である。 サポート装置10のハードウェア構成例を示す模式図である。 サポート装置10のソフトウェア構成例を示す模式図である。 ユーザインターフェイス画面140の一例である。 ディスプレイ114上にラダープログラム42を表示する際に実行される表示処理を示すフローチャートである。 ラダー回路420を追加するときに実行される追加処理を示すフローチャートである。 挿入ルールの一例を示す図である。 挿入ルールの他の例を示す図である。 挿入ルールの他の例を示す図である。 挿入ルールの他の例を示す図である。 階層を考慮しない挿入ルールの一例を示す図である。 テキスト情報460の作成ルールの一例について説明するための図である。 コピー・アンド・ペーストをした場合の画面遷移の一例である。 ラダー回路420を削除するときに実行される削除処理を示すフローチャートである。 削除ルールの一例を示す図である。 削除ルールの他の例を示す図である。 親子情報480の更新ルールの一例を示す図である。 ラダー回路420を移動するときに実行される移動処理を示すフローチャートである。 移動操作による画面遷移の一例を示す図である。 階層構造160を定義するための階層化処理を示すフローチャートである。 省略表示と展開表示の一例を示す図である。 省略表示と展開表示の他の例を示す図である。 階層構造160を表したラダー画面120の一例を示す図である。 第1領域142に表示されるラダー画面120の範囲が変更される様子を示す図である。 1または複数のラダー回路420を一の部品として登録する様子を示す図である。 POUを呼出元のラダー回路の子階層として表示した画面の一例を示す図である。 変形例にかかる階層化処理を示すフローチャートである。 変形例にかかる階層化処理に従って定義された階層構造160の一例を示す図である。
 本発明の実施の形態について、図面を参照しながら詳細に説明する。なお、図中の同一または相当部分については、同一符号を付してその説明は繰返さない。
 <A.適用例>
 図1を参照して、本発明が適用される場面の一例について説明する。図1は、本実施の形態に係るサポート装置10の機能構成を示すブロック図である。
 サポート装置10は、ラダープログラム42を表示するための情報処理装置の一例である。サポート装置10は、典型的には、汎用のコンピュータで構成される。サポート装置10は、ラダープログラム42を作成する場面、ラダープログラム42の動作を確認する場面、またはラダープログラム42のバグを修正する場面などで利用される。
 ラダープログラム42は、FA分野で使用される各種装置を制御するPLCのような制御装置が実行する制御プログラムの一種である。「制御プログラム」は、FA分野で使用される各種装置を制御する制御装置の基本的な機能を提供するためのプログラムと、制御対象に応じて任意に設計されるプログラム(「ユーザプログラム」ともいう)とを包含する概念である。
 ラダープログラム42は、複数の命令要素を互いに繋いだ回路態様で表示可能なプログラミング言語で記述されているプログラムである。典型的には、ラダープログラム42は、国際規格IEC61131-3において既定されているPLCアプリケーションのプログラミング言語のうち、ラダーダイアグラム(LD:Ladder Diagram)で記述されたプログラムである。なお、プログラム全体を複数の言語で記述する方式を採用する場合に、ファンクションブロックダイアグラム(FBD:Function Block Diagram)、シーケンシャルファンクションチャート(SFC:Sequential Function Chart)、インストラクションリスト(IL:Instruction List)、ストラクチャードテキスト(ST:Structured Text)、各メーカ独自の言語、またはC言語等の手続き型プログラミング言語などで記述されたプログラムがラダープログラム42に含まれていてもよい。
 図1を参照して、サポート装置10は、ラダー画面生成部12と、受付部14と、定義部16と、階層画面生成部18とを備える。
 ラダー画面生成部12は、ラダープログラム42を1または複数のラダー回路420を含む回路態様で表示するためのラダー画面120を生成する。ラダー画面生成部12は、ラダー回路420を並べて表示するとともに、ラダー回路420ごとに登録されたテキスト情報460を対応するラダー回路420に対応付けて表示するようにラダー画面120を生成する。
 各ラダー回路420は、入力側母線421および出力側母線422、ならびに入力側母線421と出力側母線422との間に接続線と回路要素とを用いて描かれた論理回路(以下、単に「回路」とも称する)から構成される。回路要素は、たとえば、入力信号に基づいてオン/オフする接点423と、回路内の演算結果を出力するコイル424とを含む。なお、図1において、一部符号を省略している。
 テキスト情報460は、文字からなる情報である。なお、文字は、記号および数字も含み得る。テキスト情報460は、典型的には、ラダー回路420の名称である。図1に示す例では、テキスト情報460として、ラダー回路420の名称(たとえば、図1中の「回路1」という文字)と、ラダー回路420の順番(たとえば、図1中の「0」という文字)とがラダー画面120上に表示されている。なお、テキスト情報460として、ラダー回路420の内容を示すコメントが登録されていてもよい。また、テキスト情報460は、自動で生成されてもよく、また、ユーザによって入力されることで生成されてもよい。
 受付部14は、ラダー画面120に対する操作に応じて、一のラダー回路420と他のラダー回路420との親子関係を示す親子情報480の入力をラダー回路420ごとに受け付ける。親子関係とは、従属関係を意味する。上位の階層のラダー回路420が親であり、その階層の下位層に含まれるラダー回路420が子である。たとえば、ユーザは、一のラダー回路420が他のラダー回路420の出力結果を受けるようにラダープログラムを記述する場合に、他のラダー回路420(子)を一のラダー回路420(親)に従属させるように親子情報480を入力できる。
 図1に示す例では、ラダー画面120上のテキスト情報460が表示された領域に特殊記号「#」が入力されることで、テキスト情報460に対応するラダー回路420に関連付けて親子情報480の入力が受け付けられる。また、ユーザは、特殊記号「#」を入力することで階層を区切ることができ、特殊記号「#」の数により階層の深さを表すことができる。
 たとえば、図1に示す例では、「回路1」が示すラダー回路420は、「回路1-1」が示すラダー回路420の出力結果である「a」という変数と、「回路1-2」が示すラダー回路420の出力結果である「b」という変数とによって出力結果が変わる。この場合に、ユーザは、「回路1」が示すラダー回路420を親、「回路1-1」が示すラダー回路420と、「回路1-2」が示すラダー回路420とを「回路1」が示すラダー回路420の子とするように親子情報480を入力できる。
 定義部16は、受付部14が受け付けた親子情報480に基づいて、ラダープログラム42に含まれる複数のラダー回路420の階層構造160を定義する。たとえば、定義部16は、入力された親子情報480と、予め定められた親子情報480を入力するルールに基づいて階層構造160を定義する。
 図1に示す例では、定義部16は、たとえば、0番目のラダー回路420に対して受け付けられた親子情報480(「#」)に基づいて、0番目のラダー回路420と1番目のラダー回路420とで階層の区切りが生じ、「#」の数により0番目のラダー回路420が1番上の階層であることを特定する。そして、定義部16は、1番目のラダー回路420が0番目のラダー回路420の子階層であることを定義する。また、2番目のラダー回路420に対して親子情報480の入力がされていないため、定義部16は、2番目のラダー回路420が1番目のラダー回路420と同じ階層であることを定義する。
 階層画面生成部18は、定義部16が定義した階層構造160をテキスト情報460で表示した階層画面180を生成する。図1に示す例では、階層画面生成部18は、テキスト情報460の冒頭にインデントをいくつ設けるかによって、このテキスト情報460に対応するラダー回路420の階層を表現する。たとえば、「0.回路1」に対応する0番目のラダー回路420は、「0.回路1」にインデントが設けられていないため、1番上の階層のラダー回路420である。
 ラダープログラム42は、一のラダー回路420内のコイル424が出力する結果を他のラダー回路420に含まれる接点423が受けるような階層的な表現で記述されることがある。
 階層的な表現で記述されたラダープログラム42は、複数のラダー回路420から構成されている。ラダー画面120を表示可能な範囲には制限があるため、ラダープログラム42全体をディスプレイ内に収めることは難しく、ラダープログラム42の全体構造を表現することが難しかった。
 また、一般的に、ラダー回路420を並べて表示する場合、入力側母線421の位置が固定された態様で表示される。入力側母線421の位置を変更することで階層関係を表現することも可能だが、入力側母線421の位置を変更するとラダー回路420の表示位置がラダー回路420ごとに変わってしまい、見難いという課題がある。
 本実施の形態にかかるサポート装置10は、ラダー回路420に対する操作に応じて親子情報480の入力を受け付ける。そのため、ユーザは、ラダー回路420間の親子関係を、ラダー回路420を確認しながら任意に定義することができる。
 また、サポート装置10は、親子情報480に基づいて定義される階層構造160をテキスト情報460で表示するための階層画面180を生成するための階層画面生成部18を備える。ラダー回路420と異なり、テキスト情報460であればインデントを設けたり、あるいは、罫線でテキスト情報460同士をつなげたりする方法によって容易に階層構造160を表現できる。そのため、サポート装置10は、ラダープログラム42の全体構造を分かりやすく表示できる。
 また、ラダー回路420とテキスト情報460とを比較すると、テキスト情報460を表示するために必要な領域は、ラダー回路420を表示するために必要な領域よりも狭い。そのため、テキスト情報460で階層構造160を表すことで階層構造160を一の画面内に収めることが容易になる。その結果、ラダープログラム42の全体構造を分かりやすく表示できる。
 以下、本発明の具体例として、本実施の形態に係るサポート装置10のより詳細な構成および処理について説明する。
 <B.サポート装置を適用可能な制御システム>
 図2は、サポート装置10を適用可能な制御システム1の構成例を示す模式図である。図2を参照して、制御システム1は、複数のPLC200-1,200-2,200-3,200-4,…(以下、「PLC200」とも総称する。)を含んでいる。PLC100の各々は、リレー,センサー等のフィールド機器である制御対象を制御する制御装置の一例である。サポート装置10は、PLC200に接続可能であり、PLC200の制御プログラムの開発を支援する環境を提供する。制御システム1は、1台のPLC200を含む構成であってもよい。以下では、説明を簡単にするために、1台のPLC200を対象にした開発環境を説明する。
 PLC200は、典型的には、制御プログラムを含む各種プログラムを実行する主体であるCPU(Central Processing Unit)ユニット20と、CPUユニット20などへ電力を供給する電源ユニット22と、フィールドからの信号を遣り取りするI/O(Input/Output)ユニット24とを含む。I/Oユニット24は、CPUユニット20とシステムバス21を介して接続されている。
 サポート装置10が提供する開発支援環境は、制御プログラムのエディタ(編集)、デバッカ、シミュレータおよびこれらの出力情報をディスプレイ等のモニタに出力するためのモニタ機能等を有し得る。サポート装置10は、さらに、運転中のPLC200の状態値を取得し、ディスプレイ等のモニタに出力する機能なども備える。
 光学記録媒体8に格納されたアプリケーションプログラムであるサポートプログラムがサポート装置10にインストールされることで、上述したような開発支援環境のための各種機能が実現される。光学記録媒体8に代えて、外部のサーバ装置などからネットワークを介して、サポートプログラムをダウンロードするようにしてもよい。サポート装置10は、一例として、接続ケーブルを介してPLC200のCPUユニット20と接続される。
 <C.サポート装置10のハードウェア構成例>
 図3は、サポート装置10のハードウェア構成例を示す模式図である。図3を参照して、サポート装置10は、典型的には、汎用のコンピュータで構成される。なお、PLC200が配置される製造現場における保守性の観点からは、可搬性に優れたノート型のパーソナルコンピュータが好ましい。
 サポート装置10は、記憶部101と、オペレーティングシステム(OS)を含む各種プログラムを実行するCPU102とを備える。記憶部101は、BIOSや各種データを格納するROM(Read Only Memory)104と、CPU102でのプログラムの実行に必要なデータを格納するための作業領域を提供するRAM(Random Access Memory)106と、CPU102で実行されるプログラムなどを不揮発的に格納するハードディスク(HDD)108とを含む。ROM104と、HDD108とは、非一時的なコンピュータ可読媒体の具体化例である。
 サポート装置10は、さらに、サポート装置10に指示を入力するためにユーザが操作するキーボード110およびマウス112を含む操作部103、および情報をユーザに提示するためのディスプレイ114を含む。サポート装置10は、PLC200(CPUユニット20)などと通信するための通信インターフェイス118を含む。通信インターフェイス118は、PLC200が備えるUSB(Universal Serial Bus)インターフェイス(図示略)と通信するためにUSB通信モジュールを含み得る。
 サポート装置10は、光学記録媒体8からそれに格納されている開発支援環境を提供するためのサポートプログラムを読み取るための光学記録媒体読取装置116を含む。光学記録媒体8は、非一時的なコンピュータ可読媒体の具体化例である。
 図3には、CPU102等のプロセッサがプログラムを実行することで必要な機能が提供される構成例を示したが、これらの提供される機能の一部または全部を、専用のハードウェア回路(例えば、ASIC(Application Specific Integrated Circuit)またはFPGA(Field-Programmable Gate Array)など)を用いて実装してもよい。この場合には、仮想化技術を用いて、用途の異なる複数のOSを並列的に実行させるとともに、各OS上で必要なアプリケーションを実行させるようにしてもよい。
 <D.サポート装置10のソフトウェア構成>
 図4は、サポート装置10のソフトウェア構成例を示す模式図である。図4では、サポート装置10のソフトウェア構成に関連付けて、記憶部101に格納される情報の一例が示される。
 (d1.サポート装置10に格納される情報)
 記憶部101に格納される情報は、ラダープログラム42と、テキスト情報460と、親子情報480と、位置情報440と、階層構造160と、部品情報430と、設定情報450と、オブジェクト情報52と、サポートプログラム54とを含む。
 本実施の形態において、ラダープログラム42は、ラダーダイアグラムで記述されたコンパイルがされる前の状態で記憶部101に格納されているものとして説明する。ラダープログラム42は、複数のラダー回路420を含む。また、ラダープログラム42に含まれる各ラダー回路420は、後述するエディタ15によって編集され、作成される。
 テキスト情報460は、ラダー回路420ごとに格納されている。各テキスト情報460は、いずれのラダー回路420と対応関係にあるかを特定可能な情報を含む。テキスト情報460は、図示しないものの、ラダー回路420の名称を示すテキスト情報および、ラダー回路420の順番を示すテキスト情報のうちの少なくとも一方の情報を含む。
 親子情報480は、ラダー画面120を介して入力される情報であって、一のラダー回路420と他のラダー回路420との階層関係を示す情報である。親子情報480は、いずれのラダー回路420に対して入力された情報であるかを特定可能な情報を含む。本実施の形態においては、親子情報480は、階層の区切りを示す情報と階層の深さを示す情報とを含む。
 なお、親子情報480は、設定情報450に含まれる入力ルールに従って入力される情報である。入力ルールは、予め定められていてもよく、また、ユーザによって変更可能な構成であってもよい。
 位置情報440は、ラダー画面120上における各ラダー回路420の位置を示す情報である。なお、位置情報440は、各ラダー回路420の位置を示すものであればよく、たとえば、ラダー回路420の順序を示すものであってもよい。
 階層構造160は、親子情報480に基づいて定義部16が定義するラダープログラム42に含まれるラダー回路420の全体構造を示す情報である。本実施の形態においては、階層構造160は、設定情報450に含まれる入力ルールと、親子情報480と、位置情報440とに基づいて定義される。
 部品情報430は、ラダープログラム42に含まれる呼出命令によって呼び出されるファンクションブロックを含む。また、部品情報430は、任意に選択した1または複数のラダー回路420から構成された部品を含む。
 設定情報450は、親子情報480の入力ルール、ディスプレイ114にラダー画面120および階層画面180を表示する際の表示ルール、階層構造160を定義し直す際のルール、新たなラダー回路420を追加または削除するときのルールなどを含む。
 オブジェクト情報52は、ラダープログラム42を視覚的にディスプレイ114に表示するために用いられる。オブジェクト情報52は、ラダープログラム42の内容を視覚的に示すための各部品を含む。たとえば、オブジェクト情報52は、入力側母線421、出力側母線422、接点423、およびコイル424などを含む。
 サポートプログラム54は、ラダープログラム42を表示するためのプログラムを含む。また、サポートプログラム54は、制御プログラムを開発するための各種機能を実現するためのプログラムである。
 (d2.ラダープログラムを表示するためのモジュール)
 図4に示された各種機能は、CPU102がサポートプログラム54を実行することで実現される。具体的には、サポートプログラム54は、受付部14、エディタ15、ラダー画面生成部12、定義部16、作成部17、階層画面生成部18、部品化部19、および表示部11の機能を提供する。
 受付部14は、操作部103からの操作の入力を受け付ける。受付部14は、典型的には、入力インターフェイスである。たとえば、受付部14は、親子情報480の入力、位置情報440の変更、部品情報430の登録、テキスト情報460の入力などを受け付ける。なお、位置情報440の変更は、ラダー回路420の追加またはラダー回路420の削除に基づくものを含む。
 エディタ15は、ユーザ操作に従いラダープログラム42の編集および作成を実施する。エディタ15は、PLC200の運転中に実行される制御プログラムの一部を書き換える(編集する)オンラインエディット機能をさらに提供し得る。
 ラダー画面生成部12は、ラダー画面120を生成する。ラダー画面120上には、上述したように、複数のラダー回路420が並べて表示され、ラダー回路420ごとに登録されたテキスト情報460が対応するラダー回路420の上部に表示される。
 ラダー画面生成部12は、受付部14が情報の入力を受け付けた場合、受け付けた内容に応じてラダー画面120の表示内容を更新する。たとえば、ラダー画面生成部12は、受付部14が親子情報480の入力を受け付けた場合に、入力された親子情報480をラダー画面120上に表示する。
 定義部16は、親子情報480に基づいて階層構造160を定義する。本実施の形態において、定義部16は、設定情報450に含まれる入力ルールと、親子情報480と、位置情報440とに基づいて階層構造160を定義する。
 また、定義部16は、受付部14が情報の入力を受け付けた場合、受け付けた内容に応じて階層構造160を定義しなおす。たとえば、定義部16は、親子情報480が入力されたこと、または位置情報440が変更されたことに応じて、階層構造160を定義しなおす。
 作成部17は、テキスト情報460の編集または作成を行う。たとえば、作成部17は、受付部14がテキスト情報460の入力を受け付けた場合にテキスト情報460の編集または作成を行う。また、作成部17は、ラダー回路420が追加されたり、あるいは削除されたりしたことに応じて、テキスト情報460を更新または作成する。詳細については、後述する。
 階層画面生成部18は、定義部16が定義した階層構造160をテキスト情報460で表示した階層画面180を生成する。階層構造160の表現方法は、図1に示したテキスト情報460の冒頭にインデントを設ける方法に限られず、たとえば、罫線を用いてテキスト情報460同士を繋いだ表現方法、テキスト情報460の間に階層区切りを示すスラッシュを入れる表現方法などであってもよい。
 階層画面生成部18は、受付部14が情報の入力を受け付けた場合、受け付けた内容に応じて階層画面180の表示内容を更新する。たとえば、階層画面生成部18は、受付部14が受け付けた内容に応じて階層構造160が定義しなおされたり、テキスト情報460の内容が更新されたりした場合に、階層画面180の表示内容を更新する。
 部品化部19は、複数のラダー回路420を一の部品として部品情報430に登録する。たとえば、部品化部19は、受付部14が、一のラダー回路420の選択を受け付けた場合に、選択されたラダー回路420および選択されたラダー回路420の子階層に含まれるすべてのラダー回路420を一の部品として部品情報430に登録する。
 表示部11は、ラダー画面生成部12が生成したラダー画面120と、階層画面生成部18が生成した階層画面180とをディスプレイ114に表示する。また、表示部11は、受付部14が表示範囲の変更を受け付けた場合に、ディスプレイ114に表示するラダー画面120および階層画面180の表示範囲を変更する。たとえば、表示部11は、階層画面生成部18を介して一のテキスト情報460が選択された場合に、テキスト情報460に対応するラダー回路420がディスプレイ114内に表示されるようにラダー画面120の表示範囲を変更する。
 <E.ユーザインターフェイス画面>
 図5は、ユーザインターフェイス画面140の一例である。ユーザインターフェイス画面140は、表示部11によって生成されて、ディスプレイ114に表示される。
 図5を参照して、ユーザインターフェイス画面140は、ラダー画面120を表示する第1領域142と階層画面180を表示するための第2領域144とを含む。また、ラダー画面120には、階層画面180の表示を省略して、ラダー画面120を表示するための第1領域142を広げるための切替ボタン146が設けられている。また、ユーザインターフェイス画面140は、第1領域142上に表示するラダー画面120の表示範囲を変更するためのスクロールバー148が設けられている。
 本実施の形態において、ラダー画面120と階層画面180とは、一のユーザインターフェイス画面140内に表示される。なお、ラダー画面120と階層画面180とを表示する方法は、これに限られない。たとえば、ラダー画面120と階層画面180とは、それぞれ別のウィンドウに表示されてもよい。
 <F.表示処理>
 図6は、ディスプレイ114上にラダープログラム42を表示する際に実行される表示処理を示すフローチャートである。図6に示す表示処理は、ユーザインターフェイス画面140をディスプレイ114に表示するための処理である。表示処理は、たとえば、ユーザインターフェイス画面140の表示が求められているときに、所定の処理周期毎にメインルーチン(図示せず)から呼び出されて実行される。
 S101において、CPU102は、ラダー画面120を生成する。より具体的には、CPU102は、ラダープログラム42を複数のラダー回路420を含む回路態様で表示するとともに、ラダー回路420ごとに登録されているテキスト情報460を、対応するラダー回路420に対応させて表示するためのラダー画面120を生成する。テキスト情報460は、ラダー回路420を表示する順番に従って生成されてもよい。また、CPU102は、S101において、ラダー画面120を生成したときにラダー画面120上における各ラダー回路420の位置を示す位置情報440を生成する。
 S102において、CPU102は、親子情報480の入力を受け付ける。より具体的には、CPU102は、ラダー画面120上に特殊記号「#」の入力がされた場合に、その入力を受け付ける。
 S104において、階層化処理を実行する。階層化処理は、ラダープログラム42に含まれる複数のラダー回路420の階層構造160を定義する処理である。階層化処理は、S102で生成された位置情報440とS102で受け付けられた親子情報480とに基づいて実行される。階層化処理については、図21を参照して後述する。
 S105において、CPU102は、階層画面180を生成する。より具体的には、CPU102は、テキスト情報460と、階層構造160とに基づいて、階層構造160をテキスト情報460で表した階層画面180を生成する。
 S106において、CPU102は、S101で生成したラダー画面120と、S105で生成した階層画面180とを含むユーザインターフェイス画面140を生成してディスプレイ114上に表示して、表示処理を終了する。
 <G.位置情報440の変更操作>
 上述のように、受付部14は、位置情報440の変更を受け付ける。本実施の形態において、受付部14は、ラダー画面120を介して入力された操作に限らず、階層画面180を介して入力された操作に基づいて行われる操作によっても、位置情報440の変更を受け付ける。
 ラダー画面120上におけるラダー回路420間の位置関係に応じて任意に階層構造160を定義できるため、ユーザは、親子関係とする各ラダー回路420の内容を確認しながら親子情報480を入力できる。
 また、階層画面生成部18を介した操作によりラダー回路420間の位置関係を変更でき、位置関係の変更に応じて階層構造160も変更できる。そのため、階層構造160の変更を容易に行うことができる。
 位置情報440は、ラダー回路420の順序を変更したときに限らず、ラダー回路420を追加した場合、またはラダー回路420を削除した場合に変更される。位置情報440の変更は、ラダー回路420の順序を変更する操作に限らず、ラダー回路420を追加する操作、およびラダー回路420を削除する操作によっても行われる。以下、各操作が受け付けられたときの処理について詳細に説明する。
 (g1.追加操作)
 図7は、ラダー回路420を追加するときに実行される追加処理を示すフローチャートである。追加処理は、ラダー回路420を追加するための操作が受け付けられたときにCPU102によって行われる処理である。
 S111において、CPU102は、挿入ルールに従ってラダー回路420を挿入する位置を決定する。挿入ルールは、設定情報450として予め記憶部101に格納されている。挿入ルールは、サポートプログラム54を提供するベンダによって予め定められていてもよく、また、ユーザによって変更可能であってもよい。
 S112において、CPU102は、位置情報440を更新する。具体的には、新たに追加されたラダー回路420の位置情報440が追加され、新たに追加されたラダー回路420よりも順番が後のラダー回路420の位置情報440が更新される。
 S113において、CPU102は、新たに追加されたラダー回路420および、新たに追加されたラダー回路420と隣り合うラダー回路420の親子情報480を更新する。たとえば、CPU102は、追加する際に選択したラダー回路420およびラダー回路420を追加する位置の少なくとも一方に応じて親子情報480を更新する。親子情報480の更新の一例については、図10および図11を参照して後述する。
 S114において、CPU102は、階層化処理を実行する。階層化処理は、ラダープログラム42に含まれる複数のラダー回路420の階層構造160を定義する処理である。階層化処理は、S112で更新された位置情報440とS113で更新された親子情報480とに基づいて実行される。階層化処理については、図21を参照して後述する。
 S115において、CPU102は、テキスト情報460を更新する。本実施の形態において、テキスト情報460は、ラダー回路420の名称を示す情報と、ラダー回路420の順番を示す情報とを含む。CPU102は、ラダー回路420の順番を示す情報を、S112において更新された後の位置情報440に基づいて更新する。また、CPU102は、新たに追加するラダー回路420の名称を作成する。
 すなわち、作成部17は、ラダー回路420が追加されたときに、更新された後の位置情報440に基づいて、テキスト情報460に含まれるラダー回路420の順番を示す情報を更新するとともに、新たに追加されたラダー回路420の名称を作成する。
 なお、作成する名称は、予め定められた定型テキスト(たとえば、「回路コメント」)であってもよく、また、所定のルールに従って作成されたテキストであってもよい。たとえば、作成部17は、新たに追加されたラダー回路420が属する階層を指すテキストを名称として作成してもよい。
 S116において、CPU102は、S111~S115の処理を実行することで更新した各種情報に基づいてラダー画面120の表示を更新する。
 S117において、CPU102は、S111~S115の処理を実行することで更新した各種情報に基づいて階層画面180の表示を更新して追加処理を終了する。
 (g2.追加操作による画面遷移)
 図8を参照して、追加操作による具体的な画面遷移を説明する。図8は、挿入ルールの一例を示す図である。たとえば、ユーザは、操作部103を操作することで、カーソルPを動かし、階層画面180上の一のテキスト情報460を選択できる。階層画面180上で一のテキスト情報460を選択することで、選択したテキスト情報460に対応するラダー回路420が選択されたこととなる。
 ラダー回路420が選択された状態で追加操作がされると、図7に示した追加処理が実行され、図8の左側に示した画面が右側に示した画面に遷移する。図8に示す例では、CPU102は、選択したラダー回路420の子階層の一番下に新たなラダー回路420を挿入するというルールに従って新たなラダー回路420を追加する。その結果、図8に示すように、ラダー画面120上の2行目に新たなラダー回路420と、「2 回路コメント」というテキスト情報460とが追加されるとともに、階層画面180上に「2 回路コメント」というテキスト情報460が追加される。そして、2行目以降のラダー回路420の位置が一つずつずれるとともに、テキスト情報460も更新される。また、追加された新たなラダー回路420が、「回路1」が示すラダー回路420の子階層に含まれることが定義される。
 なお、挿入ルールは、図8に示したルールに限られない。図9~図11は、挿入ルールの他の例を示す図である。図9を参照して、CPU102は、選択したラダー回路420の子階層の一番上に新たなラダー回路420を挿入するというルールに従って新たなラダー回路420を追加してもよい。このルールに従うと、図9に示すように、ラダー画面120上の1行目に新たなラダー回路420とテキスト情報460とが追加されるとともに、階層画面180上に「1.回路コメント」というテキスト情報460が追加される。そして、1行目以降のラダー回路420の位置が一つずつずれるとともに、テキスト情報460も更新される。また、追加された新たなラダー回路420が、「回路1」が示すラダー回路420の子階層に含まれることが定義される。
 図10を参照して、CPU102は、選択したラダー回路420と同じ階層であって、選択したラダー回路420の一つ下に位置するようにラダー回路420を挿入するというルールに従って新たなラダー回路420を追加してもよい。このルールに従うと、図10に示すように、「回路1」が示すラダー回路420の子階層の下である、ラダー画面120上の2行目に新たなラダー回路420とテキスト情報460とが追加されるとともに、階層画面180上に「2.回路コメント」というテキスト情報460が追加される。そして、2行目以降のラダー回路420が一つずつずれるとともに、テキスト情報460も更新される。また、追加された新たなラダー回路420が、「0.回路1」が示すラダー回路420と同じ階層であることが定義される。
 図11を参照して、CPU102は、選択したラダー回路420と同じ階層であって、選択したラダー回路420の階層の一番下にラダー回路420を挿入するというルールに従って新たなラダー回路420を追加してもよい。このルールに従うと、図11に示すように、ラダー画面120上の10行目に新たなラダー回路420とテキスト情報460とが追加されるとともに、階層画面180上に「10.回路コメント」というテキスト情報460が追加される。また、追加された新たなラダー回路420が、「0.回路1」が示すラダー回路420と同じ階層であることが定義される。
 なお、階層を考慮してラダー回路420が挿入される場合、必要に応じて親子情報480が更新される。具体的には、選択したラダー回路420に対して親子情報480が入力されているか否か、および挿入位置のうちの少なくとも一方の情報に基づいて、親子情報480が更新される。たとえば、図10および図11に示すように、親子情報480が入力されたラダー回路420が選択された状態で、選択されたラダー回路420と同じ階層にラダー回路420を追加する場合、追加したラダー回路420に親子情報480が追加される。
 なお、挿入ルールは、図8~図11に示したものに限られない。たとえば、CPU102は、選択したラダー回路420と同じ階層であって、選択したラダー回路420の階層の一番上にラダー回路420を挿入するというルールに従って新たなラダー回路420を追加してもよい。
 テキスト情報460を追加してラダープログラム42を開発していく際に、上述のように、ラダー回路420を追加する度に階層構造160が定義し直されるため、容易に階層構造160を定義できる。
 また、CPU102は、階層を考慮することなくラダー回路420を追加してもよい。図12は、階層を考慮しない挿入ルールの一例を示す図である。たとえば、CPU102は、選択したラダー回路420の階層を考慮することなく、選択したラダー回路420の一つ上に新たなラダー回路420を追加してもよい。CPU102は、階層を考慮しないため、親子情報480を追加する処理を実行しない。なお、CPU102は、上述したいずれかの挿入ルールに従ってラダー回路420を挿入する場合であっても、親子情報480を追加、または変更する処理を実行しなくともよい。
 図13を参照して、テキスト情報460の作成ルールについて説明する。図13は、テキスト情報460の作成ルールの一例について説明するための図である。上述したように、作成部17は、所定のルールに従って新たなテキスト情報460を作成してもよい。たとえば、作成部17は、定義し直された階層構造160と、追加されたラダー回路420が属する階層のラダー回路420に対応するテキスト情報460とに基づいて、追加されたラダー回路420に対応するテキスト情報460を作成してもよい。
 図13に示す例では、定義し直された階層構造160において、新たに追加されたラダー回路420は、回路1の子階層であって、子階層に含まれるラダー回路420の上から2番目に位置する。また、新たに追加されたラダー回路420が属する階層のラダー回路420(親のラダー回路420)に対応するテキスト情報460は、「回路1」である。この場合に、作成部17は、作成部17は、「回路1-2」というテキスト情報460を作成する。
 定義し直された階層構造160と、追加されたラダー回路420が属する階層のラダー回路420に対応するテキスト情報460とに基づいて、追加されたラダー回路420に対応するテキスト情報460が作成されるため、新たに追加されたラダー回路420に対して、そのラダー回路420の階層を示したテキスト情報460を生成できる。
 上記追加処理は、選択したラダー回路420をコピーして、貼り付ける(ペースト)場合に実行されてもよい。図14は、コピー・アンド・ペーストをした場合の画面遷移の一例である。貼り付け操作が受け付けられた場合、図7で示した追加処理が行われる。なお、貼り付け操作が受け付けられた場合には、新たに追加されたラダー回路420に対応するテキスト情報460は、元のテキスト情報460をコピーしたものであってもよく、また、作成部17によって新たに作成されてもよい。
 なお、追加処理が行われた場合に、CPU102は、ラダー画面120および階層画面180上に追加した箇所を明示する目印を設けてもよい。
 (g3.削除操作)
 図15は、ラダー回路420を削除するときに実行される削除処理を示すフローチャートである。削除処理は、ラダー回路420を削除するための操作が受け付けられたときにCPU102によって行われる処理である。
 S121において、CPU102は、削除ルールに従って削除対象を決定する。削除ルールは、設定情報450として予め記憶部101に格納されている。削除ルールは、サポートプログラム54を提供するベンダによって予め定められていてもよく、また、ユーザによって変更可能であってもよい。
 S122において、CPU102は、位置情報440を更新する。より具体的には、削除対象のラダー回路420よりも順番が後のラダー回路420の位置情報440が更新される。
 S123において、CPU102は、親子情報480を更新する。たとえば、CPU102は、削除対象のラダー回路420に応じて親子情報480を更新する。親子情報480の更新の一例については、図18を参照して後述する。
 S124において、CPU102は、階層化処理を実行する。階層化処理は、ラダープログラム42に含まれる複数のラダー回路420の階層構造160を定義する処理である。階層化処理は、S122で更新された位置情報440とS123で更新された親子情報480とに基づいて実行される。階層化処理については、図21を参照して後述する。なお、削除処理において実行される階層化処理と、図7の追加処理において実行される階層化処理とは、共通の処理である。
 S125において、CPU102は、テキスト情報460を更新する。本実施の形態において、テキスト情報460は、ラダー回路420の名称と、ラダー回路420の順番を示す情報とを含む。CPU102は、ラダー回路420の順番を示す情報を、S122において更新された後の位置情報440に基づいて更新する。
 換言すると、上述した作成部17は、ラダー回路420が削除されたときに、更新された後の位置情報440に基づいて、テキスト情報460に含まれるラダー回路420の順番を示す情報を更新する。
 S126において、CPU102は、S121~S125の処理を実行することで更新した各種情報に基づいてラダー画面120の表示を更新する。
 S127において、CPU102は、S121~S125の処理を実行することで更新した各種情報に基づいて階層画面180の表示を更新して削除処理を終了する。
 (g4.削除操作による画面遷移)
 図16を参照して、削除操作による具体的な画面遷移を説明する。図16は、削除ルールの一例を示す図である。たとえば、ユーザは、操作部103を操作することで、カーソルPを動かし、階層画面180上の一または複数のテキスト情報460を選択できる。階層画面180上で一または複数のテキスト情報460を選択することで、選択したテキスト情報460に対応するラダー回路420が選択されたこととなる。図16に示す例では、一つのテキスト情報460が選択されている例を示すが、複数のテキスト情報460を選択できるようにしてもよい。
 ラダー回路420が選択された状態で削除操作がされると、図15に示した削除処理が実行され、図16の左側に示した画面が右側に示した画面に遷移する。図16に示す例では、CPU102は、選択したラダー回路420を削除するという削除ルールに従ってラダー回路420を削除し、また、親子情報480の更新を行わないというルールに従ってS123の処理を実行する。その結果、ラダー画面120上の7行目以降のラダー回路420が繰り上がるとともに、テキスト情報460も更新される。また、親子情報480が更新されないため、削除対象である「回路2-1-2」が示すラダー回路420の子階層に含まれる「回路2-1-2-1」が示すラダー回路420が「回路2-1-1」が示すラダー回路420の子階層に含まれることになる。
 なお、削除ルールは、図16に示したルールに限られない。図17は、削除ルールの他の例を示す図である。図17を参照して、CPU102は、選択したラダー回路420と、選択したラダー回路420の子階層に含まれるラダー回路420を削除対象に決定してもよい。より具体的には、図17を参照して、「回路2-1-2」が示すラダー回路420が選択された場合に、CPU102は、削除対象を、「回路2-1-2」が示すラダー回路420と、「回路2-1-2」が示すラダー回路420の子階層に定義されている「回路2-1-2-1」が示すラダー回路420とに決定してもよい。
 このように、選択したラダー回路420と、選択したラダー回路420の子階層に含まれるラダー回路420が削除対象とされることで、一のラダー回路420を選択して複数のラダー回路420を削除できる。その結果、ラダープログラム42の編集が容易になり、開発する際の利便性が向上する。
 また、図16に示した例では、親子情報480の更新を行わないものとした。なお、親子情報480を更新するようにしてもよい。図18は、親子情報480の更新ルールの一例を示す図である。たとえば、選択したラダー回路420の子階層にラダー回路420が含まれる場合に、CPU102は、子階層のラダー回路420の階層を一つ繰り上げるようにしてもよい。具体的には、CPU102は、図18に示すように、削除対象である「回路2-1-2」が示すラダー回路420の子階層に含まれる「回路2-1-2-1」が示すラダー回路420を、「回路2-1-2」が示すラダー回路420の親である「回路2-1」が示すラダー回路420の子階層に含めるように「回路2-1-2-1」が示すラダー回路420に入力された親子情報480を削除するようにしてもよい。
 (g5.移動操作)
 図19は、ラダー回路420を移動するときに実行される移動処理を示すフローチャートである。移動処理は、ラダー回路420を移動するための操作が受け付けられたときにCPU102によって行われる処理である。
 S132において、CPU102は、位置情報440を更新する。より具体的には、CPU102は、移動対象のラダー回路420よりも順番が後であって、移動先よりも順番が前のラダー回路420の位置情報440を更新する。
 S133において、CPU102は、親子情報480を更新する。たとえば、CPU102は、選択対象のラダー回路420を移動する前後で、選択対象以外のラダー回路420の親子関係が変化しないように親子情報480を更新する。CPU102は、選択対象のラダー回路420と、挿入先の前後に位置するラダー回路420との親子関係が予め定められたルールを満たすように親子情報480を更新する。たとえば、CPU102は、選択対象のラダー回路420が挿入先の前に位置するラダー回路420の子となるように親子情報480を更新する。なお、CPU102は、選択対象のラダー回路420が、挿入先の前または後ろに位置するラダー回路420と同じ階層となるように親子情報480を更新してもよい。
 S134において、CPU102は、階層化処理を実行する。階層化処理は、ラダープログラム42に含まれる複数のラダー回路420の階層構造160を定義する処理である。階層化処理は、S132で更新された位置情報440とS133で更新された親子情報480とに基づいて実行される。階層化処理については、図21を参照して後述する。なお、移動処理において実行される階層化処理と、図7の追加処理において実行される階層化処理と、図15の削除処理において実行される階層化処理とは、互いに共通の処理である。
 S135において、CPU102は、テキスト情報460を更新する。本実施の形態において、テキスト情報460は、ラダー回路420の名称と、ラダー回路420の順番を示す情報とを含む。CPU102は、ラダー回路420の順番を示す情報を、S132において更新された後の位置情報440に基づいて更新する。
 換言すると、上述した作成部17は、ラダー回路420が移動されたときに、更新された後の位置情報440に基づいて、テキスト情報460に含まれるラダー回路420の順番を示す情報を更新する。
 S136において、CPU102は、S132~S135の処理を実行することで更新した各種情報に基づいてラダー画面120の表示を更新する。
 S137において、CPU102は、S132~S135の処理を実行することで更新した各種情報に基づいて階層画面180の表示を更新して削除処理を終了する。
 (g6.移動操作による画面遷移)
 図20を参照して、移動操作による具体的な画面遷移を説明する。図20は、移動操作による画面遷移の一例を示す図である。たとえば、ユーザは、操作部103を操作することで、カーソルPを動かし、階層画面180上の一または複数のテキスト情報460を選択できる。階層画面180上で一または複数のテキスト情報460を選択することで、選択したテキスト情報460に対応するラダー回路420が選択されたこととなる。図16に示す例では、一つのテキスト情報460が選択されている例を示すが、複数のテキスト情報460を選択できるようにしてもよい。
 ラダー回路420が選択された状態で移動操作(ドラッグアンドドロップ)がされると、図19に示した移動処理が実行され、図20の左側に示した画面が右側に示した画面に遷移する。図20に示す例では、CPU102は、1行目の「回路1-1」が示すラダー回路420を7行目と8行目との間に挿入する。
 CPU102は、1行目の「回路1-1」が示すラダー回路420を7行目と8行目との間に挿入することに伴って、2行目から7行目までのラダー回路420に対応するテキスト情報460を更新する。また、図19に示す例では、CPU102は、挿入先の前に位置するラダー回路420の子階層となるように、選択したラダー回路420に親子情報480を入力する。より具体的には、CPU102は、7行目のラダー回路420に「#####」という親子情報480を入力する。なお、移動対象のラダー回路420がわかるように、CPU102は、ラダー画面120上に目印124を設けてもよい。
 <H.階層化処理>
 図21は、階層構造160を定義するための階層化処理を示すフローチャートである。なお、図21に示す階層化処理は、一例であって、他の処理手順で階層構造160が定義されてもよい。また、図21に示す階層化処理は、上述した表示処理、追加処理、削除処理、および移動処理において実行される。なお、表示処理、追加処理、削除処理、および移動処理の各々で実行される階層化処理は共通の処理であってもよく、また、処理ごとに固有の階層化処理であってもよい。本実施の形態においては、表示処理、追加処理、削除処理、および移動処理の各々で実行される階層化処理は共通の処理であるとして説明する。
 図21を参照して、S141において、CPU102は、1行目のラダー回路420を対象のラダー回路とする。
 S142において、CPU102は、対象のラダー回路420に親子情報480が入力されているか否かを判定する。対象のラダー回路420に親子情報480が入力されていないと判定した場合(S142においてNO)、S144において、CPU102は、対象のラダー回路420を前のラダー回路420と同じ階層に設定する。
 対象のラダー回路420に親子情報480が入力されていると判定した場合(S142においてYES)、S146において、対象のラダー回路420の階層の深さと、対象のラダー回路420の親となるラダー回路420を設定する。
 たとえば、CPU102は、入力されている親子情報480が一番上の階層(第1階層目)を示している場合、対象のラダー回路420の階層を一番上の階層に設定する。一方、入力されている親子情報480が一番上の階層ではない場合(第2階層以下)、入力されている親子情報480に基づいて階層の深さを設定する。そして、CPU102は、位置情報440に基づいて、対象のラダー回路420よりも前のラダー回路420であって設定した深さの階層よりも一つ上の階層に設定されているラダー回路420のうち対象のラダー回路420と最も近いラダー回路420を親とする。
 CPU102は、S144またはS146の処理を実行した後、S148において、位置情報440に基づいて、後ろにラダー回路420があるか否かを判定する。
 CPU102は、後ろにラダー回路420があると判定した場合(S148においてYES)、S150において、対象のラダー回路420を一つ後ろのラダー回路420に変更して、S142~S148の処理を実行する。
 CPU102は、後ろにラダー回路420がないと判定するまで、S150を実行するとともにS142~S148の処理を繰り返す。CPU102は、後ろにラダー回路420がないと判定した場合(S148においてNO)、階層化処理を終了する。
 <I.子階層に含まれるラダー回路420の表示態様>
 階層画面生成部18は、階層画面180を介して選択された一のラダー回路420の子階層に含まれるラダー回路420に対応するテキスト情報460を階層画面180上に表示したり、あるいは、省略したりすることができる。
 図22は、省略表示と展開表示の一例を示す図である。階層画面生成部18は、たとえば、階層画面180上に省略表示と展開表示とを切り替えるためのタブ182を設ける。カーソルPでタブ182が選択されると、階層画面生成部18は、階層画面180上に子階層のラダー回路420に対応するテキスト情報460を表示したり(展開表示)、あるいは省略したり(省略表示)する。図22中の左側に示した画面は、展開表示中の画面の一例である。図22中の右側に示した画面は、省略表示中の画面の一例である。
 図22においては、「回路2」の横に位置するタブ182が選択されると、「回路2」に対応するラダー回路420の子階層に位置するラダー回路420に対応するテキスト情報460である「4.回路2-1」、「5.回路2-1-2」、「6.回路2-1-2」、「7.回路2-1-2-1」が表示されたり、あるいは省略されたりする。なお、階層画面生成部18は、省略表示されていることを示すために、タブ182の形状を展開表示中の形状と省略表示中の形状とで異なるようにしてもよい。
 なお、ラダー画面生成部12は、階層画面生成部18の省略表示と展開表示との切り替えに応じて、ラダー画面120上の表示を切り替えてもよい。図23は、省略表示と展開表示の他の例を示す図である。図23中の左側に示した画面は、展開表示中の画面の一例である。図22中の右側に示した画面は、省略表示中の画面の一例である。
 ラダー画面生成部12は、図23中の右側に示すように、省略表示中に、階層画面180上で表示が省略されているテキスト情報460に対応するラダー回路420の表示をラダー画面120上で省略してもよい。このとき、ラダー画面生成部12は、縮小していること、および縮小している箇所を示す目印122をラダー画面120上に設けてもよい。
 このような縮小表示と展開表示とを切り替える機能は、図22および図23に示すように、ラダー回路420の数が多いときに特に有効である。たとえば、ユーザは、縮小表示によりラダープログラム42の全体像を把握するとともに、展開表示に切り替えることでラダープログラム42を詳細に検討できる。
 なお、ラダー画面生成部12は、ラダー画面120上にタブ182に相当するタブを設け、当該タブに対する操作に応じて省略表示と展開表示とを切り替えるようにしてもよい。この場合、階層画面生成部18は、ラダー画面120の省略表示と展開表示との切り替えに応じて、階層画面180の省略表示と展開表示とを切り替えてもよく、また、切り替えなくともよい。
 <J.ラダー画面120上での階層構造160の表示>
 ラダー画面生成部12は、各ラダー回路420の表示態様を変えることで定義部16が定義した階層構造160を表現したラダー画面120を生成してもよい。たとえば、ラダー画面生成部12は、一のラダー回路420と、一のラダー回路420の子階層に含まれるラダー回路420とで、各ラダー回路420を表示する領域の背景を異ならせたラダー画面120を生成してもよい。
 図24は、階層構造160を表したラダー画面120の一例を示す図である。たとえば、ラダー画面生成部12は、一番上の階層(一階層目)のラダー回路420を表示する範囲の背景を背景Aとし、二階層目のラダー回路420を表示する範囲の背景を背景Bとし、3階層目のラダー回路420を表示する範囲の背景を背景Cとしてラダー画面120を生成してもよい。
 ラダー回路420の表示態様を階層ごとに変更することで、階層画面180を確認しなくとも、ラダー画面120を確認するだけで、階層の区切りをユーザが容易に把握できる。
 <K.第1領域142に表示されるラダー画面120の範囲の変更>
 図25は、第1領域142に表示されるラダー画面120の範囲が変更される様子を示す図である。上述したように、表示部11は、階層画面180を介して一のテキスト情報460が選択された場合に、テキスト情報460に対応するラダー回路420がディスプレイ114の第1領域142内に表示されるようにラダー画面120の表示範囲を変更してもよい。
 たとえば、図25を参照して、階層画面180上の一のテキスト情報460にカーソルPを合わせた状態で、特定の操作(たとえば、ダブルクリック)が受け付けられると、図25の右側に示すように、第1領域142に表示されるラダー画面120の表示範囲が変更される。図25に示す例では、表示部11は、階層画面180上の一のテキスト情報460が選択されて特定の操作が受け付けられると、選択されたテキスト情報460に対応するラダー回路420が第1領域142の最上部に位置するようにラダー画面120の表示範囲を変更する。
 図25に示す例では、表示部11は、選択されたラダー回路420が第1領域142の最上部に位置するようにラダー画面120の表示範囲を変更するとした。なお、選択されたラダー回路420を表示する位置は、ラダー画面120の最上部に限らず、たとえば、第1領域142の真ん中、第1領域142の最下部など、第1領域142上のいずれの位置であってもよい。
 たとえば、ラダープログラム42の開発が進み、多くのラダー回路420がラダープログラム42内に含まれる場合、ラダー画面120上から目的のラダー回路420を探し出すことは困難である。このような場合、ユーザは、ラダー回路420を作成しながらラダープログラム42の全体構造を任意に定義し、階層画面180上に定義した全体構造(階層構造160)を表示させておくことができる。階層画面180を介した操作によりラダー画面120の表示範囲を変更できるため、ユーザは、ラダー回路420が多くなった場合でも目的のラダー回路420を容易に探せる。
 <L.部品化>
 上述したように、部品化部19は、複数のラダー回路420を一の部品として部品情報430に登録する。より具体的には、部品化部19は、受付部14が、一のラダー回路420の選択を受け付けた場合に、選択されたラダー回路420および選択されたラダー回路420の子階層に含まれるすべてのラダー回路420を一の部品として部品情報430に登録する。
 図26は、1または複数のラダー回路420を一の部品として登録する様子を示す図である。図26を参照して、「回路1」というテキスト情報460に対応するラダー回路420が選択された状態で部品化にかかる操作が受け付けられた場合、部品化部19は、「回路1」が示すラダー回路420および、「回路1」が示すラダー回路420の子階層に含まれる「回路1-1」と「回路1-2」とのラダー回路420をからなるプログラムを一の部品として部品情報430に登録する。
 部品化にかかる操作が受け付けられると、図26の下に示すように、部品情報430として登録された1または複数のラダー回路420から構成されたプログラムが別ウィンドウで表示されてもよい。
 国際規格IEC61131-3においては、プログラムやプロジェクトを構成するブロックは、POU(Program Organization Units)と称される。POUは、プログラム要素のまとまりの単位に相当する。すなわち、換言すると、部品化部19は、選択されたラダー回路420および選択されたラダー回路420の子階層に含まれるすべてのラダー回路420を一のPOUとして部品情報430に登録する。
 こユーザは、ラダー画面120上でラダー回路420を追加したり、削除したりしながら、ラダープログラム42の開発を進める。本実施の形態においては、ラダー画面120を介して親子情報480の入力が受け付けられることから、ユーザは、任意の階層構造160をラダープログラム42の開発を進めながら定義できる。そして、ユーザが任意に定義した階層構造160のうち、一の階層に含まれるすべてのラダー回路420を一の部品として登録できる。すなわち、ユーザは、階層構造160を任意に定義しながら、再利用できる部品の作成も同時にできることとなる。
 <M.呼出命令の階層化表示>
 ラダープログラム42は、別のPOUを呼び出す1または複数の呼出命令を含む。階層画面生成部18は、呼出命令を含むラダー回路420の子階層に呼出命令によって呼び出されるPOUが含まれるように階層画面180を生成する。
 図27は、POUを呼出元のラダー回路の子階層として表示した画面の一例を示す図である。図27に示す「回路1」が示すラダー回路420は、「Function0」という名称のPOUの一例であるファンクションを呼び出す呼出命令425を含む。図27に示す「回路1-1」が示すラダー回路420は、「FunctionBlock0」という名称のPOUの一例であるファンクションブロックを呼び出す呼出命令425を含む。
 この場合に、図27を参照して、階層画面生成部18は、「回路1」の子階層に「Function0」のPOUが含まれており、「回路1-1」の子階層に「FunctionBlock0」のPOUが含まれているように階層画面180を生成する。
 このように、階層画面180上にラダー回路420に含まれる呼出命令425が、当該ラダー回路420の子階層として表示されることで、各ラダー回路420でどのようなPOUが呼び出されるかを階層画面180上に表示できる。
 <N.階層化ルールの変形例>
 上記実施の形態においては、対象のラダー回路420に親子情報480が入力されているか否かに応じて、対象のラダー回路420の前のラダー回路420と、対象のラダー回路420との間で階層が変わる例を示した。なお、上記実施の形態に示した階層化のルールは、一例であって、上記実施の形態に示したルールに限られない。
 図28および図29を参照して、ラダー回路420の階層化ルールの変形例について説明する。図28は、変形例にかかる階層化処理を示すフローチャートである。図29は、変形例にかかる階層化処理に従って定義された階層構造160の一例を示す図である。
 変形例にかかる階層化処理は、図21に示した階層化処理と比較して、S144に代えて、S143,S145,S147を実行する点で上記実施の形態に示した階層化処理と異なる。以下、上記実施の形態と異なる点を中心に説明する。
 CPU102は、対象のラダー回路420に親子情報480が入力されていないと判定した場合(S142においてNO)、S143,S145,およびS147の処理を実行する。
 S143において、CPU102は、一つ前のラダー回路420に親子情報480が入力されているか否かを判定する。なお、一つ前のラダー回路420は、位置情報440に基づいて特定される。
 CPU102は、一つ前のラダー回路420に親子情報480が入力されていないと判定した場合(S143においてNO)、S145において、対象のラダー回路420を前のラダー回路420と同じ階層に設定する。
 CPU102は、一つ前のラダー回路420に親子情報480が入力されていると判定した場合(S143においてYES)、S147において、対象のラダー回路420を前のラダー回路420の子階層に設定する。
 すなわち、変形例にかかる階層化ルールに従うと、親子情報480の入力に基づいて階層の深さと親のラダー回路420が設定される(S146)。たとえば、図29に示すように、「#」の数により階層の深さが設定されることになり、「#」が1つ入力された「回路1」、「回路2」、および「回路3」は、一番上の階層(第1階層目)に設定される。また、「#」が2つ入力された「回路2-1」、および「回路3-1」は、第2階層目に設定される。
 変形例にかかる階層化ルールに従うと、親子情報480が入力されたラダー回路420の次に記載されたラダー回路420が、親子情報480が入力されたラダー回路420の子階層に設定される(S147)。たとえば、図29に示すように、「#」が1つ入力された「回路1」の次の「回路1-1」は、「回路1」の子階層に設定される。
 また、変形例にかかる階層化ルールに従うと、上下に位置するラダー回路420のいずれにも親子情報480が入力されていなければ、上下に位置するラダー回路420は、いずれも同じ階層に設定される(S145)。たとえば、図29に示すように、「#」が入力されていない「回路1-1」と「回路1-2」とは、いずれも同じ階層に設定される。
 なお、階層化ルールは、一例であって、上記実施の形態に示したルール、および変形例に示したルールに限らず、任意のルールを設定することができる。
 <O.付記>
 以上のように、上記の実施の形態および変形例は以下のような技術思想を含む。
 (構成1)
 ラダープログラム(42)を表示する情報処理装置(10)であって、
 前記ラダープログラム(42)を複数のラダー回路(420)を含む回路態様で表示するためのラダー画面(120)を生成するラダー画面生成部(12)を備え、
 ラダー画面には、複数の前記ラダー回路(420)が表示されるとともに、前記ラダー回路(420)ごとに登録されたテキスト情報(460)が対応する前記ラダー回路(420)に対応して表示され、
 前記ラダー画面(120)に対する操作に応じて、一の前記ラダー回路(420)と他の前記ラダー回路(420)との親子関係を示す親子情報(480)の入力を受け付ける受付部(14)と、
 前記受付部(14)が受け付けた前記親子情報(480)に基づいて、前記ラダープログラム(42)に含まれる複数の前記ラダー回路(420)の階層構造(160)を定義する定義部(16)と、
 前記定義部(16)が定義した前記階層構造(160)を前記テキスト情報(460)で表示するための階層画面(180)を生成する階層画面生成部(18)とをさらに備える、情報処理装置。
 (構成2)
 前記階層画面(180)に含まれる前記テキスト情報(460)の各々は、対応する前記ラダー回路(420)の前記ラダー画面(120)上における位置を示す位置情報(440)に関連付けられており、
 前記階層画面(180)を介して前記テキスト情報(460)が選択されたことに応じて、前記ラダー画面(120)を表示する領域(142、114)内に、選択された前記テキスト情報(460)に対応する前記ラダー回路(420)が表示される、構成1に記載の情報処理装置。
 (構成3)
 前記定義部(18)は、
  前記ラダー回路(420)の前記ラダー画面(120)上における位置を示す位置情報(440)と前記親子情報(480)とに基づいて前記階層構造(160)を定義し、
  前記位置情報(440)の変更が受け付けられたことに応じて前記階層構造(160)を定義し直す(S114,S124,S134)、構成1に記載の情報処理装置。
 (構成4)
 前記受付部(14)は、前記階層画面(180)に対する操作に応じて前記位置情報(440)の変更を受け付ける、構成3に記載の情報処理装置。
 (構成5)
 前記定義部(16)は、一の前記ラダー回路(420)が選択された状態で前記ラダー回路(420)の追加操作がされた場合に、予め定められた追加ルールと選択された前記ラダー回路(420)の階層とに基づいて前記階層構造(160)を定義し直す(S111~S114)、構成3または構成4に記載の情報処理装置。
 (構成6)
 前記テキスト情報(460)の編集または作成を行う作成部(17)をさらに備え、
 前記作成部(17)は、前記ラダー回路(420)が追加されたことに応じて前記位置情報(440)の変更が受け付けられた場合に(S112)、定義し直された前記階層構造(160)と、追加された前記ラダー回路(420)が属する階層の前記ラダー回路(420)に対応する前記テキスト情報(460)とに基づいて、追加された前記ラダー回路(420)に対応する前記テキスト情報(460)を作成する(S115)、構成3または構成4に記載の情報処理装置。
 (構成7)
 一の前記ラダー回路(420)が選択された状態で前記ラダー回路(420)の削除操作がされた場合、選択された前記ラダー回路(420)と、選択された前記ラダー回路(420)の子階層に含まれる前記ラダー回路(420)とが削除される(S121)、構成3または構成4に記載の情報処理装置。
 (構成8)
 前記受付部(14)は、一の前記ラダー回路(420)の選択を受け付けるとともに、選択された前記ラダー回路(420)および、選択された前記ラダー回路(420)の子階層に含まれる前記ラダー回路(420)を一の管理単位の部品(430)として受け付ける、構成1に記載の情報処理装置。
 (構成9)
 前記ラダー画面生成部(12)は、前記ラダー回路(420)が選択された場合に、選択された前記ラダー回路(420)の子階層に含まれる前記ラダー回路(420)を省略した前記ラダー画面(120)を生成する、構成1に記載の情報処理装置。
 (構成10)
 前記階層画面生成部(18)は、前記ラダー回路(420)が選択された場合に、選択された前記ラダー回路(420)の子階層に含まれる前記ラダー回路(420)に対応する前記テキスト情報(460)を省略した前記階層画面(180)を生成する、構成1に記載の情報処理装置。
 (構成11)
 前記ラダー画面生成部(12)は、前記定義部(16)が定義した前記階層構造(160)に基づいて、同じ階層に含まれる前記ラダー回路と異なる階層に含まれる前記ラダー回路とを互いに異なる表示態様(A,B,C)で表示した前記ラダー画面(120)を生成する、構成1に記載の情報処理装置。
 (構成12)
 前記ラダープログラム(42)は、プログラム要素のまとまりから構成されたブロックを呼び出す1または複数の呼出命令(425)を含み、
 前記階層画面生成部(18)は、前記呼出命令(425)を含む前記ラダー回路(420)の子階層に前記呼出命令(425)によって呼び出される前記ブロックが含まれるように前記階層画面(180)を生成する、構成1に記載の情報処理装置。
 (構成13)
 ラダープログラム(42)を表示するためのプログラム(54)であって、
 前記ラダープログラム(42)を複数のラダー回路(420)を含む回路態様で表示するためのラダー画面(120)を生成するステップ(S101)を含み、
 前記ラダー画面(120)には、複数の前記ラダー回路(420)が表示されるとともに、前記ラダー回路(420)ごとに登録されたテキスト情報(460)が対応する前記ラダー回路(420)に対応して表示され、
 前記ラダー画面(120)に対する操作に応じて、一の前記ラダー回路(420)と他の前記ラダー回路(420)との親子関係を示す親子情報(480)の入力を受け付けるステップ(S102)と、
 受け付けられた前記親子情報(480)に基づいて、前記ラダープログラム(42)に含まれる複数の前記ラダー回路(420)の階層構造(160)を定義するステップ(S104)と、
 定義された前記階層構造(160)を前記テキスト情報(460)で表示するための階層画面(180)を生成するステップ(S105)とをさらに含む、サポートプログラム。
 (構成14)
 構成13に記載のサポートプログラム(54)を格納した非一時的なコンピュータ可読媒体(8,104,108)。
 (構成15)
 ラダープログラム(42)を複数のラダー回路(420)を含む回路態様で表示するためのラダー画面(120)を生成するステップ(S101)を含み、
 前記ラダー画面(120)には、複数の前記ラダー回路(420)が表示されるとともに、前記ラダー回路(420)ごとに登録されたテキスト情報(460)が対応する前記ラダー回路(420)に対応して表示され、
 前記ラダー画面(120)に対する操作に応じて、一の前記ラダー回路(420)と他の前記ラダー回路(420)との親子関係を示す親子情報(480)の入力を受け付けるステップ(S102)と、
 受け付けられた前記親子情報(480)に基づいて、前記ラダープログラム(42)に含まれる複数の前記ラダー回路(420)の階層構造(160)を定義するステップ(S104)と、
 定義された前記階層構造(160)を前記テキスト情報(460)で表示するための階層画面(180)を生成するステップ(S105)とをさらに含む、ラダープログラムを表示するための方法。
 今回開示された実施の形態はすべての点で例示であって制限的なものではないと考えられるべきである。本発明の範囲は、上記した説明ではなく、請求の範囲によって示され、請求の範囲と均等の意味および範囲内でのすべての変更が含まれることが意図される。また、実施の形態および各変形例において説明された発明は、可能な限り、単独でも、組合せても、実施することが意図される。
 1 制御システム、8 光学記録媒体、10 サポート装置、11 表示部、12 ラダー画面生成部、14 受付部、15 エディタ、16 定義部、17 作成部、18 階層画面生成部、19 部品化部、20 CPUユニット、21 システムバス、22 電源ユニット、24 I/Oユニット、42 ラダープログラム、52 オブジェクト情報、54 サポートプログラム、101 記憶部、102 CPU、103 操作部、104 ROM、106 RAM、108 HDD、110 キーボード、112 マウス、114 ディスプレイ、116 光学記録媒体読取装置、118 通信インターフェイス、120 ラダー画面、122 目印、140 ユーザインターフェイス画面、142 第1領域、144 第2領域、146 切替ボタン、148 スクロールバー、160 階層構造、180 階層画面、182 タブ、420 ラダー回路、421 入力側母線、422 出力側母線、423 接点、424 コイル、425 呼出命令、430 部品情報、440 位置情報、450 設定情報、460 テキスト情報、480 親子情報、P カーソル。

Claims (13)

  1.  ラダープログラムを表示する情報処理装置であって、
     前記ラダープログラムを複数のラダー回路を含む回路態様で表示するためのラダー画面を生成するラダー画面生成部を備え、
     前記ラダー画面には、複数の前記ラダー回路が表示されるとともに、前記ラダー回路ごとに登録されたテキスト情報が対応する前記ラダー回路に対応して表示され、
     前記ラダー画面に対する操作に応じて、一の前記ラダー回路と他の前記ラダー回路との親子関係を示す親子情報の入力を受け付ける受付部と、
     前記受付部が受け付けた前記親子情報に基づいて、前記ラダープログラムに含まれる複数の前記ラダー回路の階層構造を定義する定義部と、
     前記定義部が定義した前記階層構造を前記テキスト情報で表示するための階層画面を生成する階層画面生成部とをさらに備える、情報処理装置。
  2.  前記階層画面に含まれる前記テキスト情報の各々は、対応する前記ラダー回路の前記ラダー画面上における位置を示す位置情報に関連付けられており、
     前記階層画面を介して前記テキスト情報が選択されたことに応じて、前記ラダー画面を表示する領域内に、選択された前記テキスト情報に対応する前記ラダー回路が表示される、請求項1に記載の情報処理装置。
  3.  前記定義部は、
      前記ラダー回路の前記ラダー画面上における位置を示す位置情報と前記親子情報とに基づいて前記階層構造を定義し、
      前記位置情報の変更が受け付けられたことに応じて前記階層構造を定義し直す、請求項1に記載の情報処理装置。
  4.  前記受付部は、前記階層画面に対する操作に応じて前記位置情報の変更を受け付ける、請求項3に記載の情報処理装置。
  5.  前記定義部は、一の前記ラダー回路が選択された状態で前記ラダー回路の追加操作がされた場合に、予め定められた追加ルールと選択された前記ラダー回路の階層とに基づいて前記階層構造を定義し直す、請求項3または請求項4に記載の情報処理装置。
  6.  前記テキスト情報の編集または作成を行う作成部をさらに備え、
     前記作成部は、前記ラダー回路が追加されたことに応じて前記位置情報の変更が受け付けられた場合に、定義し直された前記階層構造と、追加された前記ラダー回路が属する階層の前記ラダー回路に対応する前記テキスト情報とに基づいて、追加された前記ラダー回路に対応する前記テキスト情報を作成する、請求項3または請求項4に記載の情報処理装置。
  7.  一の前記ラダー回路が選択された状態で前記ラダー回路の削除操作がされた場合、選択された前記ラダー回路と、選択された前記ラダー回路の子階層に含まれる前記ラダー回路とが削除される、請求項3または請求項4に記載の情報処理装置。
  8.  前記受付部は、一の前記ラダー回路の選択を受け付けるとともに、選択された前記ラダー回路および、選択された前記ラダー回路の子階層に含まれる前記ラダー回路を一の管理単位の部品として受け付ける、請求項1に記載の情報処理装置。
  9.  前記ラダー画面生成部は、前記ラダー回路が選択された場合に、選択された前記ラダー回路の子階層に含まれる前記ラダー回路を省略した前記ラダー画面を生成する、請求項1に記載の情報処理装置。
  10.  前記階層画面生成部は、前記ラダー回路が選択された場合に、選択された前記ラダー回路の子階層に含まれる前記ラダー回路に対応する前記テキスト情報を省略した前記階層画面を生成する、請求項1に記載の情報処理装置。
  11.  前記ラダー画面生成部は、前記定義部が定義した前記階層構造に基づいて、同じ階層に含まれる前記ラダー回路と異なる階層に含まれる前記ラダー回路とを互いに異なる表示態様で表示した前記ラダー画面を生成する、請求項1に記載の情報処理装置。
  12.  前記ラダープログラムは、プログラム要素のまとまりから構成されたブロックを呼び出す1または複数の呼出命令を含み、
     前記階層画面生成部は、前記呼出命令を含む前記ラダー回路の子階層に前記呼出命令によって呼び出される前記ブロックが含まれるように前記階層画面を生成する、請求項1に記載の情報処理装置。
  13.  ラダープログラムを表示するためのプログラムであって、
     前記ラダープログラムを複数のラダー回路を含む回路態様で表示するためのラダー画面を生成するステップを含み、
     前記ラダー画面には、複数の前記ラダー回路が表示されるとともに、前記ラダー回路ごとに登録されたテキスト情報が対応する前記ラダー回路に対応して表示され、
     前記ラダー画面に対する操作に応じて、一の前記ラダー回路と他の前記ラダー回路との親子関係を示す親子情報の入力を受け付けるステップと、
     受け付けられた前記親子情報に基づいて、前記ラダープログラムに含まれる複数の前記ラダー回路の階層構造を定義するステップと、
     定義された前記階層構造を前記テキスト情報で表示するための階層画面を生成するステップとをさらに含む、ラダープログラムを表示するためのプログラム。
PCT/JP2020/047226 2020-03-26 2020-12-17 情報処理装置およびラダープログラムを表示するためのプログラム WO2021192456A1 (ja)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2020055649A JP7380376B2 (ja) 2020-03-26 2020-03-26 情報処理装置およびラダープログラムを表示するためのプログラム
JP2020-055649 2020-03-26

Publications (1)

Publication Number Publication Date
WO2021192456A1 true WO2021192456A1 (ja) 2021-09-30

Family

ID=77891203

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2020/047226 WO2021192456A1 (ja) 2020-03-26 2020-12-17 情報処理装置およびラダープログラムを表示するためのプログラム

Country Status (2)

Country Link
JP (1) JP7380376B2 (ja)
WO (1) WO2021192456A1 (ja)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011086118A (ja) * 2009-10-15 2011-04-28 Yokogawa Electric Corp プログラム入力装置
WO2014136240A1 (ja) * 2013-03-07 2014-09-12 三菱電機株式会社 ラダープログラム表示プログラムおよびラダープログラム表示装置
JP2016206910A (ja) * 2015-04-21 2016-12-08 株式会社安川電機 ラダープログラム作成装置、コンピュータープログラム及びラダープログラム作成方法

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011086118A (ja) * 2009-10-15 2011-04-28 Yokogawa Electric Corp プログラム入力装置
WO2014136240A1 (ja) * 2013-03-07 2014-09-12 三菱電機株式会社 ラダープログラム表示プログラムおよびラダープログラム表示装置
JP2016206910A (ja) * 2015-04-21 2016-12-08 株式会社安川電機 ラダープログラム作成装置、コンピュータープログラム及びラダープログラム作成方法

Also Published As

Publication number Publication date
JP2021157382A (ja) 2021-10-07
JP7380376B2 (ja) 2023-11-15

Similar Documents

Publication Publication Date Title
EP3798817B1 (en) User interface logical and execution view navigation and shifting
JP5039428B2 (ja) プログラマブルコントローラ及びplcシステム
CN112579050A (zh) 基于任务的配置呈现背景
US20170351646A1 (en) User Interface with Movable Mini-Tabs
JP2014032529A (ja) Plcシステム、その作画エディタ装置、プログラマブル表示器
KR101772785B1 (ko) 프로그램 그래프 표시 장치, 프로그램 그래프 표시 방법 및 프로그램 그래프 표시 프로그램을 기록한 컴퓨터 판독 가능한 기록 매체
CN110765028B (zh) 验证环境的可视化搭建方法、装置及存储介质
JP2008204369A (ja) シミュレータ開発システム及びシミュレータ開発方法
CN105074587A (zh) ***开发装置、方法以及程序
CN112579051A (zh) 优选自动化视图管理
US6407758B1 (en) Screen forming editor
JP2013222439A (ja) プログラム生成装置
JP7067520B2 (ja) 開発支援装置、開発支援装置の制御方法、情報処理プログラム、および記録媒体
WO2021192456A1 (ja) 情報処理装置およびラダープログラムを表示するためのプログラム
WO2022244425A1 (ja) 開発支援装置、開発支援装置の制御方法、情報処理プログラム、および記録媒体
JP4476223B2 (ja) 画面データ作成装置、画面データの編集方法及び画面データ編集プログラム
KR101726120B1 (ko) 프로그램 편집 장치, 프로그램 편집 방법 및 프로그램 편집 프로그램을 기록한 컴퓨터 판독 가능한 기록 매체
WO2022254802A1 (ja) 改善システム、改善方法
JP2017102872A (ja) 開発装置、開発システム、およびプログラム
JP2009238215A (ja) データ処理装置及びデータ処理方法
JP5205988B2 (ja) Plcのグローバル変数定義方式
JP2021082031A (ja) プログラム作成支援装置
CN107561950B (zh) 楼宇中控制器的编程方法及提供控制器编程工具的服务器
WO2022190417A1 (ja) 開発支援装置、開発支援方法および開発支援プログラム
EP4152145A1 (en) Industrial automation controller project online/offline state separation

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20927579

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20927579

Country of ref document: EP

Kind code of ref document: A1