CONTROL SYSTEM, SUPPORT METHOD AND PROGRAM

The control system optimizes communication and calculation schedules across multiple PLCs by dividing user programs and adjusting timing, addressing inefficiencies in existing systems and reducing costs and effort in scaling up control systems.

JP7589598B2Active Publication Date: 2024-11-26OMRON CORP
View PDF 12 Cites 0 Cited by

Patent Information

Application Number
JP2021038267
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-03-10
Publication Date
2024-11-26
Estimated Expiration
2041-03-10

AI Technical Summary

Technical Problem

Existing control systems with multiple PLCs face inefficiencies in optimizing communication and calculation schedules, which are not adequately addressed by existing technologies.

Method used

A control system that includes a support device to divide user programs into partial programs, schedule communication and calculation tasks across multiple PLCs, and adjust timing to minimize wasteful waiting times, using TSN technology for synchronization.

Benefits of technology

This approach enables efficient optimization of communication and calculation within the control system, reducing costs and effort in scaling up control systems by minimizing wasteful waiting times and optimizing resource allocation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007589598000001
    Figure 0007589598000001
  • Figure 0007589598000002
    Figure 0007589598000002
  • Figure 0007589598000003
    Figure 0007589598000003
Patent Text Reader

Abstract

To provide a control system capable of efficiently optimizing communication and calculation contents of each control device.SOLUTION: A control system includes: division means for dividing a user program into a plurality of partial programs; scheduling means for determining a communication schedule for each of a plurality of control devices and an operation schedule for each processor of the plurality of control devices using information indicating connection relationships between the plurality of control devices and a plurality of communication slaves and assigned partial programs for each of a plurality of combinations of assigning the plurality of partial programs to the plurality of control devices; and calculation means for calculating an evaluation value according to the communication schedule and the operation schedule for each of the plurality of combinations.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to a control system, a support method, and a program. [Background technology]

[0002] In various manufacturing sites, control systems that include control devices such as PLCs (Programmable Logic Controllers) and multiple communication slaves connected to the control devices are being introduced. In manufacturing sites, there may be a demand to increase the scale of the control system. If the capabilities of the current PLC are insufficient to meet such demands, it may be possible to replace it with a high-performance PLC. For this reason, vendors that provide PLCs need to develop a wide variety of products according to the scale of the control system.

[0003] In recent years, a distributed controller system has been developed that connects multiple PLCs via a network and transmits and receives data between the PLCs to perform cooperative and synchronous operations (see JP 2010-097624 A (Patent Document 1)). By using a distributed controller system, it is possible to accommodate an increase in the scale of a control system by adding PLCs of the same model as existing PLCs. This allows the number of types of products that vendors need to prepare to be reduced. [Prior art documents] [Patent documents]

[0004] [Patent Document 1] JP 2010-097624 A Summary of the Invention [Problem to be solved by the invention]

[0005] When constructing a distributed controller system using multiple PLCs, it is necessary to optimize the communication within the control system and the calculation content of each PLC. Patent Document 1 does not consider how to improve the efficiency of such operations.

[0006] The present disclosure has been made in consideration of the above problems, and its purpose is to provide a control system, a support method, and a program that can efficiently optimize communication and the calculation contents of each control device. [Means for solving the problem]

[0007] According to an example of the present disclosure, a control system for controlling a control target includes a plurality of communication slaves and a plurality of control devices operating as communication masters. Each of the plurality of control devices includes a processor. The control system includes a division means, a scheduling means, and a calculation means. The division means divides a user program for controlling the control target into a plurality of partial programs. The scheduling means determines, for each of a plurality of combinations in which the plurality of partial programs are assigned to the plurality of control devices, a communication schedule for each of the plurality of control devices and a calculation schedule for each of the processors of the plurality of control devices, using information indicating a connection relationship between the plurality of control devices and the plurality of communication slaves and the assigned partial programs. The calculation means calculates an evaluation value according to the communication schedule and the calculation schedule for each of the plurality of combinations.

[0008] According to this disclosure, the user can refer to the evaluation value to judge the quality of the communication schedule and the operation schedule of each control device for multiple combinations. As a result, the user can efficiently optimize the communication within the control system and the operation content of each control device.

[0009] In the above disclosure, the control system further includes a selection means for selecting one combination from among the multiple combinations based on the evaluation value, and a setting means for setting a partial program assigned to one combination to each of the multiple control devices.

[0010] According to this disclosure, the partial programs can be installed in the control device according to one combination selected based on the evaluation values.

[0011] In the above disclosure, each of the plurality of control devices executes communication of input / output data with at least one of the plurality of communication slaves and calculation using the input / output data for each predetermined control period. The plurality of control devices include a first control device and a second control device. The control system further includes an adjustment means for adjusting a time difference between a start timing of the control period in the first control device and a start timing of the control period in the second control device in accordance with a communication timing between the first control device and the second control device.

[0012] According to this disclosure, the time difference between the start timing of a control cycle in the first control device and the start timing of a control cycle in the second control device is adjusted in accordance with the communication timing between the first control device and the second control device, thereby suppressing the occurrence of unnecessary waiting time.

[0013] In the above disclosure, the user program includes a monitoring program that monitors input data from a plurality of communication slaves. The plurality of control devices includes a first control device to which the monitoring program is not assigned and a second control device to which the monitoring program is assigned. The scheduling unit sets a communication method from any one of the plurality of communication slaves to the first control device to multicast, with the first control device and the second control device designated as destinations. Furthermore, the scheduling unit incorporates a read time for reading the input data transmitted by multicast into the communication schedule of the second control device.

[0014] According to this disclosure, the communication method is set to multicast, thereby making the communication of the control system more efficient.

[0015] In the above disclosure, each of the plurality of control devices executes communication of input / output data with at least one of the plurality of communication slaves and calculation using the input / output data for each predetermined control period. The control system further includes an adjustment means for adjusting a time difference between a start timing of the control period in the first control device and a start timing of the control period in the second control device in accordance with the read time.

[0016] According to this disclosure, the occurrence of unnecessary waiting time is suppressed, and as a result, the communication efficiency of the control system is improved.

[0017] In the above disclosure, each of the multiple control devices transmits output data to at least one of the multiple communication slaves for each predetermined control period. The setting unit further identifies a first timing that is the latest among the timings at which the output data arrives at the multiple communication slaves within the control period based on the communication schedule of each of the multiple control devices determined for one combination, and sets a second timing at which the multiple communication slaves start processing to be after the first timing. According to this disclosure, the processing of the multiple communication slaves can be synchronized.

[0018] According to another example of the present disclosure, a support method for supporting a control system that controls a control target includes first to third steps. The first step is a step of dividing a user program for controlling the control target into a plurality of partial programs. The second step is a step of determining, for each of a plurality of combinations in which the plurality of partial programs are assigned to a plurality of control devices, a communication schedule for each of the plurality of control devices and a calculation schedule for each of the processors of the plurality of control devices, using information indicating the connection relationships between the plurality of control devices and the plurality of communication slaves and the assigned partial programs. The third step is a step of calculating an evaluation value according to the communication schedule and the calculation schedule for each of the plurality of combinations.

[0019] According to another example of the present disclosure, a program causes a computer to execute the above support method.

[0020] These disclosures also enable users to efficiently optimize communications within a control system and the calculation content of each control device. Effect of the Invention

[0021] According to the present disclosure, users can efficiently optimize communications within a control system and the calculation content of each control device. [Brief description of the drawings]

[0022] [Figure 1] FIG. 1 is a diagram illustrating an example of a control system to which a support device according to an embodiment is applied. [Diagram 2] FIG. 13 is a diagram showing an example of increasing the scale of a control system. [Diagram 3] FIG. 1 illustrates an example of a scaled-up control system using a distributed controller system. [Figure 4] FIG. 2 is a diagram showing a process flow in a distributed controller system. [Diagram 5] FIG. 2 illustrates an example of a hardware configuration of a support device. [Figure 6] FIG. 2 is a diagram illustrating an example of a hardware configuration of a PLC. [Figure 7] FIG. 2 illustrates an example of a functional configuration of a support device. [Figure 8] FIG. 13 is a diagram illustrating an example of a variable list. [Figure 9] FIG. 2 is a diagram illustrating an example of modules included in the control system shown in FIG. [Figure 10] FIG. 13 is a diagram illustrating an example of a definition of an operation. [Figure 11] FIG. 13 is a diagram illustrating an example of a calculation block incorporated in a user program. [Figure 12] FIG. 13 is a diagram showing a part of a user program created in accordance with the definition of operations and allocation information. [Figure 13] FIG. 13 is a diagram illustrating an example of dividing a user program into a plurality of partial programs. [Figure 14] FIG. 11 is a diagram showing an example of a partial program divided from a user program. [Figure 15] FIG. 11 is a diagram showing one of a number of combinations identified by a scheduling unit. [Figure 16] FIG. 2 is a diagram illustrating an example of communication performed in a control system. [Figure 17] FIG. 13 is a diagram showing frame communication performed in combination (2). [Figure 18] FIG. 13 is a diagram illustrating an example of a communication schedule of IO data in a PLC. [Figure 19] FIG. 2 is a diagram showing an example of allocation of various programs included in a user program to tasks. [Figure 20] FIG. 11 is a diagram showing an example of a schedule determined by a scheduling unit. [Figure 21] FIG. 11 is a diagram showing another example of allocation of various programs included in a user program to tasks. [Figure 22] FIG. 13 is a diagram showing another example of a schedule determined by the scheduling unit. [Diagram 23]FIG. 13 is a diagram showing a schedule of the PLC 200a in the case of a combination (1) in which the partial programs 222d and 222e are assigned to the PLC 200a. [Figure 24] FIG. 13 is a diagram showing schedules of PLCs 200a and 200b in the case of combination (2). [Diagram 25] 11 is a diagram showing an example of an evaluation value calculated from a communication schedule and a calculation schedule; FIG. [Figure 26] FIG. 13 is a diagram showing another example of an evaluation value calculated from a communication schedule and a calculation schedule. [Figure 27] FIG. 13 illustrates another example of communication implemented in the control system. [Figure 28] FIG. 13 is a diagram showing the schedules of the PLCs 200a and 200b when the partial program 222e includes a monitoring program in the combination (2). [Figure 29] FIG. 11 illustrates an example of a method for setting a processing schedule of a communication slave. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0023] Hereinafter, each embodiment according to the present invention will be described with reference to the drawings. In the following description, the same parts and components are given the same reference numerals. Their names and functions are also the same. Therefore, detailed description thereof will not be repeated. Note that each embodiment and each modified example described below may be appropriately combined selectively.

[0024] § 1. Examples of Application An overview of a control system according to the present embodiment will be described. Fig. 1 is a diagram showing an example of a control system according to the present embodiment. The control system 1 shown in Fig. 1 controls various control targets such as a robot, a transport device, and a safety device.

[0025] As shown in Fig. 1, the control system 1 includes a support device 100, a plurality of PLCs 200, a plurality of communication slaves 300, and one or more switches 400. The PLC 200 is an example of a control device that operates as a communication master. In the example shown in Fig. 1, the plurality of PLCs 200 include PLCs 200a and 200b. The plurality of communication slaves 300 include communication slaves 300a to 300i. However, the number of PLCs 200 is not limited to two, and may be three or more. The number of communication slaves 300 is not limited to eight, and may be two or more.

[0026] In the control system 1, TSN (Time-Sensitive Networking) technology is adopted to synchronize the multiple PLCs 200. The TSN technology is a network technology for interoperating an industrial network that extends standard Ethernet (registered trademark) with an information network, and is based on Ethernet (registered trademark), guaranteeing time synchronization and real-time performance. The specifications of the TSN technology are defined by the network standard "IEEE 802.1 AS-Rev Timing and Synchronization for Time-Sensitive Applications." Scheduling of TSN is handled by a PLC that functions as a network controller and has a CNC (Central Network Controller) implemented among the multiple PLCs 200. Alternatively, the control system 1 may include a network controller connected to the switch 400. In this case, the network controller may perform TSN scheduling.

[0027] The PLC 200 includes a CPU (Central Processing Unit) unit having a processor 202. The PLC 200 may further include expansion units such as a communication unit and a safety unit. The communication slave 300 is a device such as an input / output device.

[0028] Each of the plurality of PLCs 200 executes communication of input / output data (IO data) with at least one of the plurality of communication slaves 300 and calculations using the IO data at each predetermined control period.

[0029] The switch 400 is, for example, an L2 switch. The switch 400 stores the MAC address of a connected device, and transmits data only to a destination using the MAC address.

[0030] The support device 100 supports the control system 1. The support device 100 is an information processing device (an example of a computer) that supports the preparations required for the multiple PLCs 200 to control the control targets.

[0031] Specifically, the support device 100 executes a support process for supporting the optimization of communications between the PLCs 200 and the calculation contents of each PLC 200. The support process includes the following steps (1) to (3).

[0032] (1) The support device 100 divides a user program for controlling a control target into a plurality of partial programs.

[0033] (2) The support device 100 identifies a plurality of combinations for allocating a plurality of partial programs to a plurality of PLCs 200. The support device 100 acquires connection information indicating the connection relationships between the plurality of PLCs 200 and the plurality of communication slaves 300. For each of the plurality of combinations, the support device 100 determines a communication schedule for each PLC 200 and a calculation schedule for the processor 202 of each PLC 200 using the connection information and the allocated partial programs.

[0034] (3) The support device 100 calculates an evaluation value for each of a plurality of combinations according to the communication schedule and the computation schedule.

[0035] By checking the evaluation value calculated by the above support process, the user can determine the quality of the communication schedule of each PLC200 and the calculation schedule by the processor 202 of each PLC200 among a plurality of combinations. As a result, the user can efficiently proceed with the optimization of communication within the control system 1 and the calculation content of each PLC200.

[0036] Note that the support device 100 may provide a development environment for the user program (program creation and editing tools, parser, compiler, etc.), a setting environment for setting parameters (configurations) of a plurality of PLC200s and a plurality of communication slaves 300, and the like. The support device 100 provides these environments using known techniques. Therefore, the details of providing the development environment and the setting environment are omitted from the description.

[0037] §2. Specific Example <A. Increase in the Scale of the Control System> FIG. 2 is a diagram showing an example of increasing the scale of the control system. FIG. 2 shows an example in which the number of modules composed of two communication slaves 300 related to each other increases from 1 to 3.

[0038] The control system 1X before the increase in scale includes a PLC200X and a module Ma. A user program 122X for controlling the module Ma is installed in the PLC200X.

[0039] The control system 1Y after the increase in scale further includes modules Mb and Mc in addition to the module Ma. The PLC200X does not have the ability to control the three modules Ma, Mb, and Mc. Therefore, the control system 1Y is provided with a high-performance PLC200Y instead of the PLC200X. High-performance PLC200Ys are generally costly. Therefore, the cost for replacing the PLC200X with the PLC200Y becomes high. Furthermore, the vendor providing the PLC needs to develop a variety of PLCs according to the scale of the control system.

[0040] A user program 122Y for controlling the modules Ma, Mb, and Mc is installed in the PLC 200Y. Since the modules Ma, Mb, and Mc are controlled by a single PLC 200Y, the user program 122Y may include an enabling process and an disabling process for each module. This makes it time-consuming to create the user program 122Y.

[0041] In this way, when the PLC 200X is replaced with a high-performance PLC 200Y in response to an increase in the scale of the control system, problems arise in that costs and the effort required to create user programs increase.

[0042] Fig. 3 is a diagram showing an example of a control system whose scale is increased by using a distributed controller system. The control system 1Z shown in Fig. 3 includes modules Ma, Mb, and Mc, PLCs 200Xa, 200Xb, and 200Xc that respectively control the modules Ma, Mb, and Mc, and a switch 400Z. The switch 400Z switches communication between the PLCs 200Xa, 200Xb, and 200Xc.

[0043] In the control system 1Z, each of the PLCs 200Xa, 200Xb, and 200Xc controls one module, and therefore only needs to have the same performance as the PLC 200X of the control system 1X shown in Fig. 2. Therefore, when increasing the scale from the control system 1X to the control system 1Z, it is sufficient to add two inexpensive PLCs 200X.

[0044] Furthermore, the user can create the user program 122Z by combining the programs 122Za, 122Zb, and 122Zc for controlling the modules Ma, Mb, and Mc, respectively. The programs 122Za, 122Zb, and 122Zc are then installed in the PLCs 200Xa, 200Xb, and 200Xc, respectively. Therefore, the user can omit adding module enablement and disablement processes when creating the user program 122Z. As a result, the effort required to create the user program is reduced.

[0045] In this way, by using a distributed controller system, an increase in the cost required for the PLC and the labor of creating a user program can be suppressed. However, when the number of communication slaves and the number of PLCs included in the control system increase, work is required to optimize the communication within the control system and the calculation content of each PLC. Therefore, the support device 100 according to the present embodiment supports the work for optimizing the communication within the control system and the calculation content of each PLC.

[0046] <B. Flow of Processing in Distributed Controller System> FIG. 4 is a diagram showing the flow of processing in a distributed controller system. FIG. 4 shows the flow of processing of PLCs 200a and 200b when a distributed controller system is constructed using PLCs 200a and 200b.

[0047] First, in steps S1a and S1b, the PLCs 200a and 200b perform time correction of the internal timer. Thereby, the internal timers of the PLCs 200a and 200b are synchronized.

[0048] Next, the PLCs 200a and 200b start the operation of the scheduler (steps S2a and S2b). The PLCs 200a and 200b perform address resolution (steps S3a and S3b).

[0049] Next, the PLCs 200a and 200b perform verification with the connected communication slaves 300 (steps S4a and S4b). According to the verification result, the PLCs 200a and 200b establish a connection with the connected communication slaves 300 (steps S5a and S5b).

[0050] Next, the PLCs 200a and 200b perform transmission and reception of a synchronization trigger (steps S6a and S6b). The PLCs 200a and 200b start communication according to the synchronization trigger (S7a and S7b). Thereby, the communication processing of the PLCs 200a and 200b is synchronized.

[0051] <C. Hardware Configuration> (C-1. Hardware configuration of support device) FIG. 5 is a diagram showing an example of a hardware configuration of the support device. As shown in FIG. 5, the support device 100 includes a CPU 102, a ROM (Read Only Memory) 103, a RAM (Random Access Memory) 104, a HDD (Hard Disk Drive) 105, a communication controller 107, and an I / O (Input / Output) interface 108. A keyboard 109 and a display 110 are connected to the support device 100. The keyboard 109 accepts inputs including instructions from a user to the support device 100. To accept the inputs, other devices such as a mouse may be connected to the support device 100. The display 110 includes an LCD (Liquid Crystal Display) or an organic EL (Electro Luminescence), and displays a video or image according to a video signal or image signal output from the support device 100. The support apparatus 100 includes an R / W (reader / writer) device 106 for removably mounting an external storage medium 101 and reading and writing programs and / or data to the mounted storage medium 101.

[0052] The communication controller 107 controls communication with external devices (including the PLC 200) via a network. The communication controller 107 includes, for example, a network interface card (NIC). The I / O interface 108 controls data exchange between the CPU 102 and the keyboard 109 and display 110.

[0053] The HDD 305 stores a system program 120 including an OS, a UPG generation program 121 for generating a user program 122 , the user program 122 , connection information 123 , and a distribution design program 124 .

[0054] The UPG generation program 121 includes an editor that edits (generates) the user program 122 in accordance with user operations received from the keyboard 109, a compiler that compiles the edited user program 122, a builder that converts the user program 122 into an executable format, and the like. The builder may also include a compilation function.

[0055] The connection information 123 indicates the connection relationships between the devices of the control system 1. Specifically, the connection information 123 indicates the physical wiring between the devices, the length of the wiring, etc. For example, in the case of the configuration shown in FIG. 1, the connection information 123 indicating the connection relationships between the PLCs 200a and 200b, the communication slaves 300a to 300i, and the switch 400 is created in advance and stored in the HDD 105.

[0056] The distributed design program 124 provides design support when constructing the control system 1 as a distributed control system.

[0057] (C-2. PLC hardware configuration) Fig. 6 is a diagram showing an example of a hardware configuration of a PLC. As shown in Fig. 6, the PLC 200 includes, as main hardware components, a processor 202, a main memory 204, a storage 206, a field network controller 212, a communication controller 213, and a local bus controller 214. These hardware components are electrically connected via an internal bus 218.

[0058] The processor 202 corresponds to an arithmetic processing unit, and is composed of a CPU, a GPU (Graphics Processing Unit), etc. Specifically, the processor 202 reads out a program stored in the storage 210, expands it in the main memory 204, and executes it to realize arithmetic processing and various processing according to the control target.

[0059] The main memory 204 is configured with a volatile storage device such as a dynamic random access memory (DRAM) or a static random access memory (SRAM). The storage 206 is configured with a non-volatile storage device such as a solid state drive (SSD) or a hard disk drive (HDD).

[0060] The storage 206 stores a system program 220 for implementing basic functions, a partial program 222 which is a part of the user program 122 created according to the control target, and system setting information 224 which defines a communication schedule and an operation schedule. The system program 220 implements basic functions in the PLC 200 and can therefore be regarded as at least a part of the control program.

[0061] The field network controller 212 is connected to a network configured to circulate frames. More specifically, the field network controller 212 has a port that is responsible for transmitting and receiving frames using a communication protocol such as EtherCAT (registered trademark) or EtherNet / IP. The field network controller 212 functions as a communication master. The field network controller 212 may have a synchronization counter for periodically transmitting and receiving frames.

[0062] The communication controller 213 controls communication with external devices (including the support device 100) via the network.

[0063] The local bus controller 214 is electrically connected to one or more expansion units 216 via an internal bus 218. The expansion unit 216 includes functions such as the function of exchanging various signals with the controlled object. The expansion unit 216 has, for example, one or more of the following functions: a DI (Digital Input) function for receiving a digital signal from the controlled object, a DO (Digital Output) function for outputting a digital signal to the controlled object, an AI (Analog Input) function for receiving an analog signal from the controlled object, and an AO (Analog Output) function for outputting an analog signal to the controlled object. Further, the expansion unit 216 may include a controller that implements special functions such as PID (Proportional Integral Derivative) control and motion control.

[0064] FIG. 6 shows a configuration example in which functions necessary for the processor 202 to execute a program are provided. However, some or all of these provided functions may be implemented using a dedicated hardware circuit (for example, an ASIC (Application Specific Integrated Circuit) or an FPGA (Field-Programmable Gate Array)). Alternatively, the main part of the PLC 200 may be realized using hardware that follows a general-purpose architecture (for example, an industrial personal computer based on a general-purpose personal computer). In this case, virtualization technology may be used to execute a plurality of different OSs (Operating System) in parallel and to execute necessary applications on each OS.

[0065] <D. Functional Configuration of Support Device> Fig. 7 is a diagram showing an example of the functional configuration of the support device. As shown in Fig. 7, the support device 100 includes a storage unit 10, a division unit 11, a scheduling unit 12, a calculation unit 13, a selection unit 14, and a setting unit 15. The storage unit 10 is realized by the ROM 103, the RAM 104, and the HDD 105 shown in Fig. 4. The division unit 11, the scheduling unit 12, the calculation unit 13, the selection unit 14, and the setting unit 15 are realized by the CPU 102 executing the distributed design program 124.

[0066] The storage unit 10 stores a user program 122, connection information 123, and a variable list 125.

[0067] Fig. 8 is a diagram showing an example of a variable list. As shown in Fig. 8, the variable list 125 is a list of the device name, the variable name used by the communication slave 300, and the global variable name for each communication slave 300. The variable list 125 is created in advance by using the setting environment provided by the support device 100.

[0068] The dividing section 11 (see FIG. 6) divides the user program 122 into a plurality of partial programs 222. A method of dividing the user program 122 into a plurality of partial programs 222 will be described later.

[0069] The scheduling unit 12 identifies a plurality of combinations for allocating a plurality of partial programs to a plurality of PLCs 200 included in the control system 1. The scheduling unit 12 only needs to recognize the number of PLCs 200 included in the control system 1 by referring to the connection information 123. For each of the plurality of combinations, the scheduling unit 12 determines a communication schedule for each PLC 200 and a calculation schedule for the processor 202 of each PLC 200, using the connection information and the allocated partial programs.

[0070] The calculation unit 13 calculates an evaluation value for each of the multiple combinations according to the communication schedule and the computation schedule.

[0071] The selection unit 14 selects one combination from among a plurality of combinations based on the evaluation value. For example, the selection unit 14 displays the evaluation value of each of the plurality of combinations on the display 110, and selects one combination in response to an input to the keyboard 109. Alternatively, the selection unit 14 may select one combination having the highest evaluation value from among the plurality of combinations.

[0072] The setting unit 15 sets the partial program 222 assigned in the selected one combination to each of the plurality of PLCs 200. Specifically, the setting unit 15 installs the partial program 222 in the PLC 200. Further, the setting unit 15 sets a communication schedule and an arithmetic schedule corresponding to the selected one combination to each of the plurality of PLCs 200. Specifically, the setting unit 15 generates system setting information 224 for defining the communication schedule and the arithmetic schedule for each PLC 200, and sets the generated system setting information 224.

[0073] <E. Method for Dividing User Program> Each of the plurality of communication slaves 300 provided in the control system 1 is associated with any one of the plurality of mechanisms installed on the production line. Therefore, the plurality of communication slaves 300 can be classified into a plurality of modules according to the related mechanisms.

[0074] FIG. 9 is a diagram showing an example of modules included in the control system shown in FIG. 1. As shown in FIG. 9, the control system 1 includes a module Md composed of communication slaves 300b to 300d related to each other, and a module Me composed of communication slaves 300e to 300i related to each other.

[0075] The dividing unit 11 divides the user program 122 into a plurality of partial programs 222 in module units, for example.

[0076] Fig. 10 is a diagram showing an example of a definition of an operation. Definition 50 shown in Fig. 9 defines inputs "A_in1" to "A_inN", logic, and outputs "A_out1" to "A_outM". The logic defines an operation for outputting "A_out1" to "A_outM" by referring to "A_in1" to "A_inN".

[0077] A user creates a user program 122 using multiple definitions including the definition 50 shown in Fig. 10. For example, the user creates a user program 122 including the calculation of the definition 50 by setting variables or devices to be assigned to the inputs "A_in1" to "A_inN" of the definition 50 and variables or devices to be assigned to the outputs "A_out1" to "A_outM" of the definition 50.

[0078] Fig. 11 is a diagram showing an example of a calculation block incorporated in a user program. The calculation block 52 shown in Fig. 10 is created by assigning variables or devices to the inputs and outputs of the definition 50 shown in Fig. 9. For example, a sensor 60 is assigned to the input "A_in1", a variable 61 is assigned to the input "A_inN", an actuator 62 is assigned to the output "A_out1", and a variable 63 is assigned to the output "A_outM". In this case, the calculation block 52 performs a calculation using the data input from the sensor 60 and the variable 61, outputs the data obtained by the calculation to the actuator 62, and updates the variable 63.

[0079] The operation block 52 is created based on the definition 50 and allocation information. The allocation information indicates the variables or devices to be allocated to each input and the variables or devices to be allocated to each output. The allocation information is created in response to user input when the user program 122 is created.

[0080] 12 is a diagram showing a part of a user program created in accordance with operation definitions and allocation information. As shown in FIG. 12, design information for designing a user program 122 includes operation definitions 50 and 51 and allocation information 70 to 72.

[0081] The calculation block 52 is created based on the definition 50 and the allocation information 70. The calculation block 52 performs calculations using data input from a sensor 60 and a variable 61, outputs the data obtained by the calculation to an actuator 62, and updates a variable 63.

[0082] The calculation block 53 is created based on the definition 50 and the allocation information 71. The calculation block 53 performs calculations using data input from a sensor 64 and a variable 65, outputs the data obtained by the calculation to an actuator 66, and updates a variable 67.

[0083] The calculation block 54 is created based on the definition 51 and the allocation information 72. The calculation block 54 performs calculations using data input from a device 80 on the network and the variables 63 and 67, outputs the data obtained by the calculation to the device 80, and updates the variables 61 and 65.

[0084] The dividing unit 11 identifies a mechanism including the sensors 60, 64 and the actuators 62, 66, and divides the user program 122 into a plurality of partial programs 222 according to the identification result. The dividing unit 11 may identify a mechanism including the sensors 60, 64 and the actuators 62, 66 according to an input to the keyboard 109. Alternatively, when the connection information 123 includes information indicating a connection relationship between the sensors 60, 64 and the actuators 62, 66 and the mechanisms, the dividing unit 11 may identify a mechanism including the sensors 60, 64 and the actuators 62, 66 by referring to the connection information 123.

[0085] Fig. 13 is a diagram showing an example of dividing a user program into a plurality of partial programs. As shown in Fig. 13, the sensor 60 and the actuator 62 are included in a mechanism 90 associated with the module Md shown in Fig. 9. The sensor 64 and the actuator 66 are included in a mechanism 91 associated with the module Me shown in Fig. 9.

[0086] The division unit 11 identifies, for each mechanism, a calculation block that performs calculations using inputs from devices (sensors, actuators, etc.) included in the mechanism, and a calculation block that outputs data to the devices (sensors, actuators, etc.). The division unit 11 determines, for each mechanism, the identified calculation block as a part of a partial program for a module related to the mechanism.

[0087] 12, the division unit 11 determines an operation block 52 that performs an operation using an input from a sensor 60 included in the mechanism 90 as a part of a partial program 222d for a module Md (see FIG. 9) related to the mechanism 90. Similarly, the division unit 11 determines an operation block 53 that performs an operation using an input from a sensor 64 included in the mechanism 91 as a part of a partial program 222e for a module Me (see FIG. 9) related to the mechanism 91.

[0088] Furthermore, for each of the remaining operation blocks, the division unit 11 identifies other operation blocks that update the input variables. If the identified other operation blocks belong to any of the partial programs 222, the division unit 11 includes the remaining operation blocks in the partial program 222 to which the other operation blocks belong. If there are multiple identified other operation blocks, the division unit 11 selects one operation block from the multiple other operation blocks. The division unit 11 may select one operation block arbitrarily, or may select one operation block in response to an input to the keyboard 109.

[0089] Alternatively, the splitting unit 11 may identify a communication slave 300 that refers to the variable list 125 and updates the variables input to each arithmetic block, and include the arithmetic block in a partial program 222 for a module including the identified communication slave 300.

[0090] In the example shown in FIG. 13, the splitting unit 11 identifies an arithmetic block 52 that updates the variable 63 input to the arithmetic block 54. The splitting unit 11 includes the arithmetic block 54 in the partial program 222d to which the arithmetic block 52 belongs. Alternatively, the splitting unit 11 may identify an arithmetic block 53 that updates the variable 67 input to the arithmetic block 54. In this case, the splitting unit 11 includes the arithmetic block 54 in the partial program 222e to which the arithmetic block 53 belongs.

[0091] In this way, the splitting unit 11 splits the user program 122 into a plurality of partial programs 222.

[0092] FIG. 14 is a diagram showing an example of a partial program split from a user program. As shown in FIG. 14, the user program 122 is split into a partial program 222d for the module Md and a partial program 222e for the module Me. As shown in FIG. 13, the arithmetic block 54 belonging to the partial program 222d performs an operation using the variable 67 updated by the arithmetic block 53 belonging to the partial program 222e. The arithmetic block 53 performs an operation using the variable 65 updated by the arithmetic block 54. Therefore, as shown in FIG. 14, an exchange of instructions and status is required between the partial programs 222d and 222e.

[0093] <F. Combinations of Assigning Multiple Partial Programs to Multiple PLCs> The scheduling unit 12 identifies a plurality of combinations for allocating a plurality of partial programs 222 to a plurality of PLCs 200 included in the control system 1. For example, when the control system 1 includes PLCs 200a and 200b (see FIG. 1), and the user program 122 is divided into partial programs 222d and 222e (see FIG. 13), the scheduling unit 12 identifies the following four combinations (1) to (4). Combination (1): Allocate partial programs 222d and 222e to PLC 200a. Combination (2): Allocate partial program 222d to PLC 200a and allocate partial program 222e to PLC 200b. Combination (3): Allocate partial program 222d to PLC 200b and allocate partial program 222e to PLC 200a. Combination (4): Allocate partial programs 222d and 222e to PLC 200b.

[0094] FIG. 15 is a diagram showing one of the plurality of combinations identified by the scheduling unit. In FIG. 15, the above combination (2) is shown.

[0095] <G. Determination of Communication Schedule and Calculation Schedule> Next, with reference to FIGS. 16 to 24, an example of a method for determining a communication schedule and a calculation schedule for each combination will be described.

[0096] FIG. 16 is a diagram showing an example of communication performed in the control system. In FIG. 16, the communication performed in combination (2) shown in FIG. 15 is shown. The arrows in the figure represent communication between devices.

[0097] Because the partial program 222d assigned to the PLC 200a is intended for the module Md, the scheduling unit 12 determines that communication of input / output data (IO data) is required between the PLC 200a and the communication slaves 300b-300d included in the module Md. Similarly, because the partial program 222e assigned to the PLC 200b is intended for the module Me, the scheduling unit 12 determines that communication of IO data is required between the PLC 200b and the communication slaves 300e-300i included in the module Me.

[0098] Furthermore, the scheduling unit 12 determines that communication of IO data is required between the communication slave 300a, which is daisy-chain connected to the communication slaves 300b to 300d, and the PLC 200a.

[0099] As described above, it is necessary to exchange instructions and status between the partial programs 222d and 222e. Therefore, the scheduling unit 12 determines that it is necessary to communicate instructions and status between the PLCs 200a and 200b.

[0100] The scheduling unit 12 determines the communication schedule when communication is performed using the TSN technology. In the TSN technology, the time when the queue is opened and closed is calculated, the time built into all switches is synchronized, and when the port is opened and closed at that time is set in all switches, so that frames can pass through the switch without waiting in the queue.

[0101] Fig. 17 is a diagram showing frame communication performed in the combination (2) shown in Fig. 15. Fig. 17 shows how frames are transmitted from the PLC 200a to the switch 400, the PLC 200b, and the communication slaves 300b to 300d.

[0102] The scheduling unit 12 calculates the time required for frame communication using the frame size, the frame propagation time, and the delay time for processing within the device.

[0103] For example, the opening and closing times of a queue in a port of the switch 400 are calculated as follows: The scheduling unit 12 calculates the opening time of the switch 400 according to formula (a). Start time = frame transmission start time + offset time + transmission jitter T12 + frame propagation delay time T13 + frame sending time T11 ··· Equation (a).

[0104] The frame transmission start time is the time when the PLC 200a starts transmitting a frame. The scheduling unit 12 determines the frame transmission start time by analyzing the partial program 222d assigned to the PLC 200a in the combination (2). The frame transmission start time is determined by setting the time of communication start (steps S7a and S7b) shown in FIG. 4 as 0.

[0105] The offset time is the time difference between the internal timer of the PLC 200a and the internal timer of the switch 400. When determining the communication schedule for each combination, the offset time may be set to 0.

[0106] The transmission jitter T12 is the time it takes for a frame to propagate through a communication cable. The scheduling unit 12 stores the transmission jitter T12 measured in advance. Alternatively, when the connection information 123 includes the length of the wiring between the devices, the scheduling unit 12 may refer to the connection information 123 and multiply the length of the wiring by a predetermined coefficient to calculate the transmission jitter T12.

[0107] The frame propagation delay time T13 is the time required for processing in the switch 400. The scheduling unit 12 stores the frame propagation delay time T13 measured in advance. Alternatively, the scheduling unit 12 stores the frame propagation delay time T13 provided by the vendor selling the switch 400.

[0108] The frame transmission time T11 is the time required to transmit a frame from the beginning to the end. The scheduling unit 12 calculates the frame transmission time T11 based on the frame size. The frame size is the size of the IO data to be communicated, and is specified by the user, for example.

[0109] Furthermore, when the size of each frame is the same, the scheduling unit 12 calculates the closing time of the switch 400 according to equation (b), where N is the number of frames to be transmitted consecutively. Close time = open time + transmission jitter T12 × N + frame propagation delay time T13 × (N-1) + frame sending time T11 × N · · · equation (b).

[0110] In this manner, the scheduling unit 12 calculates the open time and close time of the switch 400, and calculates the time T15 during which the switch 400 communicates. In a similar manner, the scheduling unit 12 calculates the time T14 during which the PLC 200a communicates.

[0111] Fig. 18 is a diagram showing an example of a communication schedule for IO data in a PLC. Fig. 18 shows communication processes 41 and 42 of IO data of the PLC 200a in the combination (2) shown in Fig. 15. The communication process 41 is performed between the PLC 200a and the communication slaves 300b to 300d. The communication process 42 is performed between the PLC 200a and the PLC 200b. The scheduling unit 12 determines the times of the communication processes 41 and 42 by performing the above calculations.

[0112] Furthermore, the scheduling unit 12 determines the operation schedule of the processor 202 of each PLC.

[0113] FIG. 19 is a diagram showing an example of the allocation of various programs included in a user program to tasks. The user program 122 includes various programs, and each program is assigned to one of a plurality of tasks according to its priority. The allocation of each program to a task is set according to a user input. The plurality of tasks include a high-priority primary task, a secondary task having a lower priority than the primary task, and an event task. The primary task is executed at every control period Tc (=X ms) set by the user. The secondary task is executed at every period (=Y ms) set by the user. The length of the period of the secondary task may be the same as the control period Tc, or may be a multiple of the control period Tc. The event task is executed at the timing when an event occurs.

[0114] 19, the user program 122 includes a control program 131, a safety program 132, a monitoring program 133, and an event program 134. The control program 131 defines the calculations for controlling the control target. The safety program 132 provides a safety function for preventing human safety from being threatened by equipment, machinery, etc. The monitoring program 133 monitors variables used in the control system 1. The event program 134 defines the operation when an event occurs.

[0115] It is desirable that the control program 131 and the safety program 132 are executed periodically without delay. Therefore, the control program 131 and the safety program 132 are usually assigned to a primary task. Note that the communication processing of IO data required for the execution of the control program 131 and the safety program 132 is also assigned to the primary task.

[0116] It is desirable for the monitoring program 133 to be executed periodically, but delays are acceptable. Therefore, the monitoring program 133 is usually assigned to a secondary task. The communication processing of IO data required for the execution of the monitoring program 133 is also assigned to a secondary task.

[0117] The event program 134 is assigned to an event task because it does not need to be executed periodically.

[0118] In TSN technology, a QoS (Quality of Service) priority is set for each frame. Each frame is assigned to a queue according to its QoS priority. QoS priority is set to one of eight values, from "0" to "7." QoS priority "7" is the highest and QoS priority "0" is the lowest.

[0119] It is preferable that the frames of IO data required for the execution of the control program 131 and the safety program 132 are communicated with priority. Therefore, a QoS priority of "7" is set for the frames of IO data required for the execution of the control program 131 and the safety program 132.

[0120] The scheduling unit 12 determines, for each PLC 200 , an operation schedule for the processor 202 of the PLC 200 based on the tasks assigned to the partial programs 222 assigned to the PLC 200 and the operation contents defined by the partial programs 222 .

[0121] Fig. 20 is a diagram showing an example of a schedule determined by the scheduling unit 202. Fig. 20 shows a schedule for the processor 202 of the PLC 200a in the combination (2) shown in Fig. 15.

[0122] As shown in FIG. 20, the scheduling unit 12 determines a communication schedule for executing communication processes 41 and 42 and a computation schedule for executing a computation process 43 as schedules for primary tasks.

[0123] The communication processes 41 and 42 are communication processes of IO data required for executing a program assigned to a primary task in the partial program 222d. The communication process 41 is communication processing with the communication slaves 300b to 300c. The communication process 42 is communication processing with the PLC 200b. A QoS priority of "7" is set for frames communicated by the communication processes 41 and 42.

[0124] The calculation process 43 is defined by a program assigned to a primary task in the partial program 222d.

[0125] Similarly, the scheduling unit 12 determines a communication schedule for executing a communication process 44 as a schedule for a secondary task.

[0126] The communication process 44 is a communication process for IO data required for executing a program assigned to a secondary task in the partial program 222d. A QoS priority of "5" is set for frames communicated by the communication process 44.

[0127] The method of calculating the times required for the communication processes 41, 42, and 44 is as described with reference to FIGS.

[0128] The scheduling unit 12 calculates the time required for the calculation process 43 based on the analysis result of the partial program 222d, the information input by the user, the operation information of each device, and the like.

[0129] During the free time of the control period Tc, for example, arithmetic processing defined by a program assigned to an event task and other communication processing are executed.

[0130] During the control period Tc, frames are communicated that include data that has become necessary in response to calculation results, data that has become necessary in response to the occurrence of an event, etc. QoS priorities are set in advance for these frames.

[0131] Fig. 21 is a diagram showing another example of assignment of various programs included in a user program to tasks. In the example shown in Fig. 21, the user program 122 includes a control program 131, a safety program 132, a monitoring program 133, an event program 134, and a data link setting program 135.

[0132] The data link setting program 135 is a program that sets a data link that automatically updates each other's memory areas using communication between multiple PLCs 200 and always reflects the memory status of one PLC 200 in the other PLCs 200. By executing the data link setting program 135, the multiple PLCs 200 communicate data in their memory areas with each other.

[0133] In the example shown in FIG. 21, the data link setting program 135 is assigned to the secondary task.

[0134] Fig. 22 is a diagram showing another example of a schedule determined by the scheduling unit. Fig. 22 shows a schedule of the processor 202 of the PLC 200a in the combination (2) shown in Fig. 15. As shown in Fig. 22, the scheduling unit 12 includes a communication process 45 for a data link with the PLC 200b in the communication schedule of the secondary task. The time required for the communication process 45 is calculated according to the capacity of the memory area.

[0135] In this manner, the scheduling unit 12 determines the communication schedule and the operation schedule of each PLC 200 for each combination.

[0136] FIG. 23 is a diagram showing a schedule for the PLC 200a in the case of combination (1) in which the partial programs 222d and 222e are assigned to the PLC 200a.

[0137] 23, the schedule of the PLC 200a includes a communication schedule for executing the communication process 41a with all communication slaves 300, and an arithmetic schedule for executing arithmetic processes 43d and 43e. The arithmetic process 43d is defined by a partial program 222d for the module Md. The arithmetic process 43e is defined by a partial program 222e for the module Me.

[0138] FIG. 24 is a diagram showing schedules for the PLCs 200a and 200b in the case of combination (2) in which the partial programs 222d and 222e are assigned to the PLCs 200a and 200b, respectively.

[0139] 24, the schedule of the PLC 200a includes a communication schedule for executing the communication processes 41b and 42a, and a calculation schedule for executing the calculation process 43d. The communication process 41b is a communication process with the communication slaves 300a to 300d (see FIG. 16). The communication process 42a is a communication process with the PLC 200b.

[0140] The schedule of the PLC 200b includes a communication schedule for executing the communication processes 41c and 42b, and a calculation schedule for executing the calculation process 43e. The communication process 41c is a communication process with the communication slaves 300e to 300i (see FIG. 15). The communication process 42b is a communication process with the PLC 200a.

[0141] In communication process 42a, the data transmitted from PLC 200a is received by PLC 200b in communication process 42b. The data transmitted from PLC 200b in communication process 42b is received by PLC 200a in communication process 42a. Therefore, the scheduling unit 12 may operate as an adjustment means for adjusting the time difference Td between the start timing of the control cycle Tc in PLC 200a and the start timing of the control cycle Tc in PLC 200b. That is, the scheduling unit 12 adjusts the time difference Td according to the communication timing between PLCs 200a and 200b (that is, the timing of communication processes 42a and 42b). If the time difference Td is uniformly set to 0, a wasted waiting time occurs between communication process 41c and communication process 42b in PLC 200b. However, by adjusting the time difference Td, the occurrence of such a waiting time is suppressed.

[0142] <H. Method for calculating evaluation value> With reference to FIGS. 25 and 26, a method for calculating an evaluation value according to a communication schedule and an arithmetic schedule will be described.

[0143] FIG. 25 is a diagram showing an example of an evaluation value calculated from a communication schedule and an arithmetic schedule. As shown in FIG. 25, the calculation unit 13 calculates, for each combination, the load factor of the processor 202 of each PLC 200 as an evaluation value. The calculation unit 13 calculates the load factor of the processor 202 by dividing the total time of the communication process and the arithmetic process executed in each control cycle by the control cycle Tc.

[0144] Furthermore, the calculation unit 13 calculates, for each combination, the ratio of the communication process in the load of the processor 202 of each PLC 200 as an evaluation value. The calculation unit 13 calculates the ratio of the communication process in the load of the processor 202 by dividing the total time of the communication process executed in each control cycle by the control cycle Tc.

[0145] FIG. 26 is a diagram showing another example of the evaluation value calculated from the communication schedule and the operation schedule. As shown in FIG. 25, the calculation unit 13 calculates, for each combination, an index representing the network bandwidth for each communication cable as the evaluation value. The calculation unit 13 may calculate an index representing the network bandwidth based on the connection relationship between the devices indicated by the connection information 123 and the communication volume for each communication cable.

[0146] <I. Processing Example of Selection Unit 14 and Setting Unit 15> For example, the selection unit 14 displays the evaluation value calculated by the calculation unit 13 for each combination on the display 110, and prompts for an input of an instruction to select one combination from among the plurality of combinations. The user may select a desired combination with reference to the displayed evaluation value. The setting unit 15 may set the determined communication schedule and operation schedule for the selected combination in the PLC 200.

[0147] <J. Another Determination Example of Communication Schedule> FIG. 27 is a diagram showing another example of communication implemented in the control system. FIG. 27 shows the communication implemented in the combination (2) shown in FIG. 15. The arrows in the figure represent the communication between the devices. In combination (2), as described above, the partial program 222d for the module Md is assigned to the PLC 200a, and the partial program 222e for the module Me is assigned to the PLC 200a. However, an expansion unit 216b having a cloud broker function is attached to the PLC 200b, and the monitoring program 133b is included in the partial program 222e assigned to the PLC 200b.

[0148] The monitoring program 133b monitors the input data from the communication slaves 300b to 300i and provides the monitoring result to the expansion unit 216b. The expansion unit 216 outputs the provided monitoring result to the cloud system 500.

[0149] The input data from the communication slaves 300b to 300d is necessary for the calculation of the partial program 222d for the module Md. Therefore, the output data from the communication slaves 300b to 300d is transmitted to the PLC 200a. However, since the monitoring program 133b is assigned to the PLC 200b, the PLC 200b also needs to receive the input data from the communication slaves 300b to 300d. Therefore, the scheduling unit 12 changes the setting of the communication method of the output data from the communication slaves 300b to 300d from unicast with the PLC 200a as the destination to multicast with the PLCs 200a and 200b as the destinations. This allows the PLCs 200a and 200b to obtain the output data from the communication slaves 300b to 300d.

[0150] FIG. 28 is a diagram showing the schedules of the PLCs 200a and 200b when the partial program 222e includes a monitoring program in the combination (2).

[0151] The schedule shown in Fig. 28 differs from the schedule shown in Fig. 25 in that the communication schedule of PLC 200b includes a communication process 46 and a providing process 47. The communication process 46 is a process for reading input data multicast from the communication slaves 300b to 300d. In this manner, the scheduling unit 12 need only incorporate a read time for reading the input data transmitted by multicast into the communication schedule of PLC 200b.

[0152] Furthermore, the scheduling unit 12 may operate as an adjustment unit that adjusts the time difference Td between the start timing of the control period Tc in the PLC 200a and the start timing of the control period Tc in the PLC 200b according to the read time. That is, the scheduling unit 12 adjusts the time difference Td so that the communication process 46 is performed after the input data is multicast from the communication slaves 300b to 300d. This suppresses the occurrence of unnecessary waiting time.

[0153] The providing process 47 is a process of providing input data from the communication slaves 300b to 300i to the expansion unit 216b.

[0154] <K. Setting of the processing schedule of the communication slave> The setting unit 15 may set the processing schedule of the communication slave 300 based on the communication schedules of the respective PLCs 200 determined for the combination selected by the selection unit 14.

[0155] FIG. 29 is a diagram showing an example of a method for setting the processing schedule of the communication slave. As shown in FIG. 29, the setting unit 15 specifies the latest timing t1 among the timings at which frames reach the plurality of communication slaves 300 within the control period Tc, based on the respective communication schedules of the PLCs 200a and 200b corresponding to the selected combination. The setting unit 15 sets the timing t2 at which the plurality of communication slaves 300 start various processes after the timing t1. Thereby, the processing of the plurality of communication slaves 300 can be synchronized.

[0156] <L. Scheduling of TSN> As described above, among the plurality of PLCs 200, the PLC 200 in which the CNC is mounted performs TSN scheduling. When the partial programs 222 are set in each of the plurality of PLCs 200, the PLC 200 in which the CNC is mounted may adjust the phase of the control period of each PLC 200 using the values measured online. That is, the PLC 200 in which the CNC is mounted may operate as an adjustment means for adjusting the time difference Td between the start timing of the control period Tc in the PLC 200a and the start timing of the control period Tc in the PLC 200b. Alternatively, the network controller provided in the control system 1 may operate as an adjustment means for adjusting the time difference Td.

[0157] For example, when IO data communication is required between the PLC 200a and the PLC 200b, the PLC 200 having a CNC implemented therein adjusts the time difference Td in accordance with the communication schedule between the PLC 200a and the PLC 200b, as shown in FIG.

[0158] Alternatively, when PLC 200b needs to read input data transmitted in a multicast manner (see FIG. 27), PLC 200 having a CNC implemented therein adjusts the time difference Td according to the read time of the input data by PLC 200b, as shown in FIG. 28.

[0159] § 3. Supplementary Notes As described above, the disclosure according to the above embodiment includes the following disclosure.

[0160] <Configuration 1> A control system (1) for controlling a control target, A plurality of communication slaves (300); A plurality of control devices (200) operating as communication masters; Each of the plurality of control devices (200) includes a processor (202); The control system (1) further comprises: A dividing means (11, 102) for dividing a user program (122) for controlling the control target into a plurality of partial programs (222); a scheduling means (12, 102) for determining, for each of a plurality of combinations of allocating the plurality of partial programs (222) to the plurality of control devices (200), a communication schedule for each of the plurality of control devices (200) and a calculation schedule for each of the processors (202) of the plurality of control devices (200) using information indicating a connection relationship between the plurality of control devices (200) and the plurality of communication slaves (300) and the allocated partial programs (222); A control system (1) comprising: a calculation means (13, 102) for calculating an evaluation value according to the communication schedule and the calculation schedule for each of the plurality of combinations.

[0161] <Configuration 2> A selection means (13, 102) for selecting one combination from among the plurality of combinations based on the evaluation value; The control system (1) according to configuration 1, further comprising: setting means (14, 102) for setting a partial program (222) assigned in one of the combinations to each of the plurality of control devices (200).

[0162] <Configuration 3> each of the plurality of control devices (200) executes communication of input / output data with at least one of the plurality of communication slaves (300) and calculation using the input / output data at each predetermined control period; The plurality of control devices (200) include a first control device (200a) and a second control device (200b), The control system (1) further comprises: The control system (1) according to configuration 1 or 2, further comprising an adjustment means (12, 102, 200) for adjusting a time difference between a start timing of the control cycle in the first control device (200a) and a start timing of the control cycle in the second control device (200b) in accordance with a communication timing between the first control device (200a) and the second control device (200b).

[0163] <Configuration 4> The user program (122) includes a monitoring program (133b) for monitoring input data from the plurality of communication slaves, the plurality of control devices (200) include a first control device (200a) to which the monitoring program (133b) is not assigned, and a second control device (200b) to which the monitoring program (133b) is assigned; The scheduling means (12, 102) setting a communication method from any one of the plurality of communication slaves (300) to the first control device (200a) to a multicast destination designated for the first control device (200a) and the second control device (200b); 3. The control system (1) according to configuration 1 or 2, wherein a read time for reading the input data transmitted by the multicast is incorporated into a communication schedule of the second control device (200b).

[0164] <Component 5> each of the plurality of control devices (200) executes communication of input / output data with at least one of the plurality of communication slaves (300) and calculation using the input / output data at each predetermined control period; The control system (1) further comprises: The control system (1) according to configuration 4, further comprising an adjustment means (12, 102, 200) for adjusting a time difference between a start timing of the control cycle in the first control device (200a) and a start timing of the control cycle in the second control device (200b) in accordance with the read time.

[0165] <Component 6> Each of the plurality of control devices (200) transmits output data to at least one of the plurality of communication slaves (300) at each predetermined control period; The setting means (15, 102) further includes: identifying a first timing, which is the latest among timings at which the output data arrives at the plurality of communication slaves (300) within the control period, based on the communication schedule of each of the plurality of control devices (200) determined for the one combination; The control system (1) according to configuration 2, wherein a second timing at which the plurality of communication slaves (300) start processing is set to be later than or equal to the first timing.

[0166] <Component 7> A method for supporting a control system (1) for controlling a controlled object, comprising: The control system (1) A plurality of communication slaves (300); A plurality of control devices (200) operating as communication masters; Each of the plurality of control devices (200) includes a processor (202); The support method includes: Dividing a user program (122) for controlling the control target into a plurality of partial programs (222); determining, for each of a plurality of combinations of allocating the plurality of partial programs (222) to the plurality of control devices (200), a communication schedule for each of the plurality of control devices (200) and a calculation schedule for each of the processors (202) of the plurality of control devices (200) using information (123) indicating a connection relationship between the plurality of control devices (200) and the plurality of communication slaves (300) and the allocated partial programs (222); calculating an evaluation value for each of the plurality of combinations according to the communication schedule and the computation schedule.

[0167] <Component 8> A program (124) for causing a computer to execute the support method according to configuration 7.

[0168] The embodiments disclosed herein should be considered to be illustrative and not restrictive in all respects. The scope of the present invention is indicated by the claims, not by the above description, and is intended to include all modifications within the meaning and scope of the claims. In addition, the inventions described in the embodiments and each modified example are intended to be implemented, as far as possible, either alone or in combination. [Explanation of symbols]

[0169] 1,1X,1Y,1Z Control system, 10 Memory unit, 11 Division unit, 12 Scheduling unit, 13 Calculation unit, 14 Selection unit, 15 Setting unit, 41,41a-41c,42,42a,42b,44-46 Communication processing, 43,43d,43e Calculation processing, 47 Provision processing, 50,51 Definition, 52-54 Calculation block, 60,64 Sensor, 61,63,65,67 Variable, 62,66 Actuator, 70-72 Allocation information, 80 Equipment, 90,91 Mechanism, 100 Support device, 101 Storage medium, 102 CPU, 103 ROM, 104 RAM, 106 Device, 107,213 Communication controller, 108 I / O interface, 109 Keyboard, 110 Display, 120,220 System program, 121 UPG generation program, 122, 122X, 122Y, 122Z User program, 122Za, 122Zb, 122Zc program, 123 Connection information, 124 Distributed design program, 125 Variable list, 131 Control program, 132 Safety program, 133, 133b Monitoring program, 134 Event program, 135 Data link setting program, 200, 200X, 200Xa, 200Xb, 200Xc, 200Y, 200a, 200b PLC, 202 Processor, 204 Main memory, 206, 210 Storage, 212 Field network controller, 214 Local bus controller, 216, 216b Expansion unit, 218 Internal bus, 222, 222d, 222e Part program, 224 System setting information, 300, 300a~300i communication slaves, 400, 400Z switches, 500 cloud system.

Claims

1. A control system for controlling a control target, A plurality of communication slaves; a plurality of control devices acting as communication masters; each of the plurality of control devices includes a processor; The control system further comprises: A dividing means for dividing a user program for controlling the controlled object into a plurality of partial programs; a scheduling means for determining, for each of a plurality of combinations of allocating the plurality of partial programs to the plurality of control devices, a communication schedule for each of the plurality of control devices and a calculation schedule for each of the processors of the plurality of control devices, using information indicating a connection relationship between the plurality of control devices and the plurality of communication slaves and the allocated partial programs; a calculation means for calculating an evaluation value according to the communication schedule and the calculation schedule for each of the plurality of combinations, the user program includes a monitoring program that monitors input data from the plurality of communication slaves; the plurality of control devices include a first control device to which the monitoring program is not assigned and a second control device to which the monitoring program is assigned; The scheduling means comprises: A communication method from any one of the plurality of communication slaves to the first control device is set to a multicast destination designated to the first control device and the second control device; A control system incorporating a read time for reading the input data transmitted by the multicast into a communication schedule of the second control device.

2. a selection means for selecting one combination from among the plurality of combinations based on the evaluation value; The control system according to claim 1 , further comprising: a setting unit that sets a partial program assigned in said one combination to each of said plurality of control devices.

3. each of the plurality of control devices executes communication of input / output data with at least one of the plurality of communication slaves and a calculation using the input / output data at each predetermined control period; The plurality of control devices includes two control devices, The control system further comprises:

3. The control system according to claim 1 or 2, further comprising an adjustment means for adjusting the time difference between the start timing of the control period in one of the two control devices and the start timing of the control period in the other of the two control devices in accordance with communication timing between the two control devices.

4. each of the plurality of control devices executes communication of input / output data with at least one of the plurality of communication slaves and a calculation using the input / output data at each predetermined control period; The control system further comprises:

3. The control system according to claim 1, further comprising an adjustment means for adjusting a time difference between a start timing of the control cycle in the first control device and a start timing of the control cycle in the second control device in accordance with the readout time.

5. each of the plurality of control devices transmits output data to at least one of the plurality of communication slaves at each predetermined control period; The setting means further includes: identifying a first timing, which is the latest among timings at which the output data arrives at the plurality of communication slaves within the control period, based on the communication schedule of each of the plurality of control devices determined for the one combination; The control system according to claim 2 , wherein a second timing at which the plurality of communication slaves start processing is set to be later than or equal to the first timing.

6. A method for supporting a control system that controls a control target, comprising the steps of: The control system includes: A plurality of communication slaves; a plurality of control devices acting as communication masters; each of the plurality of control devices includes a processor; The support method includes: Dividing a user program for controlling the control target into a plurality of partial programs; determining, for each of a plurality of combinations of allocating the plurality of partial programs to the plurality of control devices, a communication schedule for each of the plurality of control devices and a calculation schedule for each of the processors of the plurality of control devices, using information indicating a connection relationship between the plurality of control devices and the plurality of communication slaves and the allocated partial programs; calculating an evaluation value according to the communication schedule and the calculation schedule for each of the plurality of combinations; the user program includes a monitoring program that monitors input data from the plurality of communication slaves; the plurality of control devices include a first control device to which the monitoring program is not assigned and a second control device to which the monitoring program is assigned; The step of determining the communication schedule includes: setting a communication method from any one of the plurality of communication slaves to the first control device to a multicast destination designated by the first control device and the second control device; incorporating in a communication schedule of the second control device a read time for reading the input data transmitted by the multicast.

7. A program for causing a computer to execute the support method according to claim 6.

Citation Information

Patent Citations

  • Fail safe device of Anti-skid control system

    JP1983008450A

  • Task scheduling method

    JP1994075786A

  • Device and method for controlling FA system, and control program generating method

    JP1997171405A

  • Controller

    JP2004280222A

  • Distribution processing system, distribution processing method, and its program

    JP2006106858A