Programmable controller, control method, and program
By segregating application program execution and multivariate analysis into distinct periods, the programmable controller maintains processing cycle stability, enabling effective integration of multivariate analysis for defect detection.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-08-24
- Publication Date
- 2026-03-25
AI Technical Summary
Existing programmable controllers face challenges in implementing multivariate analysis without disrupting the processing cycles of application programs, as multivariate analysis requires significant computation time and fluctuates the processing cycle of application programs.
The programmable controller executes application programs in one cycle period and other tasks, including data processing and multivariate analysis, in separate periods, allowing for efficient integration of multivariate analysis without affecting application program processing cycles.
This approach enables the implementation of multivariate analysis in programmable controllers while maintaining consistent application program processing cycles, facilitating early detection of defects and abnormalities in equipment.
Smart Images

Figure 0007834974000001 
Figure 0007834974000002 
Figure 0007834974000003
Abstract
Description
Technical Field
[0001] The present invention relates to a programmable controller, a control method, and a program.
Background Art
[0002] Patent Document 1 discloses a scheduling method in a programmable controller that allows a user to customize the ratio of the 1 execution cycle time allocated to ladder applications and data processing. Patent Documents 2 and 3 describe a method of applying multivariate analysis techniques to a series of processes called batch processing in a programmable controller. [Prior Art Documents] [Patent Documents] [Patent Document 1] Japanese Patent No. 4811260 [Patent Document ②] Japanese Patent No. 4911055 [Patent Document ③] Japanese Patent No. 6733164
Summary of the Invention
Problems to be Solved by the Invention
[0003] It is desired to implement multivariate analysis on a programmable controller without affecting the processing of the application program.
Means for Solving the Problems
[0004] A programmable controller according to an aspect of the present invention may include an execution unit that executes tasks of an application program within a first period in one cycle and executes tasks other than the application program within a second period in one cycle. The execution unit may execute an input process for receiving an input of time series data indicating the state of a diagnosis target within the first period, and within the second period, execute at least part of an accumulation process for accumulating the time series data received by the input process in a storage unit and a diagnosis process for diagnosing the state of the diagnosis target based on the time series data accumulated in the storage unit by the accumulation process.
[0005] The execution unit may perform a single diagnosis of the condition to be diagnosed over multiple cycles by executing storage processing and diagnostic processing within the second period of each cycle.
[0006] The diagnostic process may include, once a predetermined amount of time-series data has been stored in the memory unit through the storage process, a preprocessing step which converts the predetermined amount of time-series data into a data format for diagnosis; an analysis step which performs multivariate analysis based on the time-series data processed in the preprocessing step; and a determination step which determines whether the state of the target to be diagnosed is normal or not based on the analysis results of the analysis step.
[0007] The execution unit may, within the second period, execute a generation process to generate a diagnostic model to be used in the analysis process based on time-series data that indicates the state of the subject to diagnosis is normal.
[0008] The execution unit may perform an update process to update the diagnostic model used in the analysis process using the diagnostic model generated by the generation process while the analysis process is not being performed during the second period.
[0009] The execution unit may perform the update process before the start of the preprocessing.
[0010] The execution unit executes control processing on the controlled device related to the diagnostic target within the first period, and the diagnostic processing may include notification processing that notifies the control processing of the determination result obtained by the determination processing.
[0011] The storage process and the diagnostic process may consist of at least one function block.
[0012] The programmable controller may further include a receiving unit that receives information specifying the proportion of the first and second periods within a single cycle. The execution unit may adjust the lengths of the first and second periods based on this information.
[0013] The diagnostic process may include output processing that outputs a message to the effect that it is not possible to complete a single diagnosis of the condition being diagnosed within a predetermined number of cycles.
[0014] The execution unit may adjust the lengths of the first and second periods in response to the message so that the proportion of the second period within a cycle increases.
[0015] Tasks other than application programs may include tasks involving data communication processing between the application and a management device that manages the programmable controller.
[0016] A control method according to one aspect of the present invention may be a control method for controlling a programmable controller. The control method may include an execution stage in which a task of an application program is executed within a first period of one cycle, and a task other than that of an application program is executed within a second period of one cycle. The execution stage may include an input processing step in which time-series data indicating the state of the object to be diagnosed is input within the first period. The execution stage may include, in the second period, an accumulation process in which the time-series data received by the input processing is accumulated in a storage unit, and at least a part of a diagnostic process in which the state of the object to be diagnosed is diagnosed based on the time-series data accumulated in the storage unit in the accumulation process is executed.
[0017] A program according to one aspect of the present invention may be a program for causing a computer to function as a programmable controller. The program may cause the computer to perform an execution stage in which it executes tasks of an application program within a first period of one cycle and tasks other than those of the application program within a second period of one cycle. The execution stage may include, within the first period, an input processing step of receiving time-series data indicating the state of the object to be diagnosed. The execution stage may include, within the second period, an accumulation process of accumulating the time-series data received by the input processing in a storage unit, and at least a part of a diagnostic process of diagnosing the state of the object to be diagnosed based on the time-series data accumulated in the storage unit in the accumulation process.
[0018] Note that the above summary of the invention does not enumerate all the features of the present invention. Also, sub - combinations of these feature groups can also be inventions.
Brief Description of the Drawings
[0019] [Figure 1] FIG. is a diagram showing an example of the configuration of a system to which a programmable controller is applied. [Figure 2] FIG. is a diagram showing an example of the schematic hardware configuration of a CPU module. [Figure 3] FIG. is a diagram showing an example of the software structure of a programmable controller. [Figure 4] FIG. is a diagram for explaining task processing in a programmable controller. [Figure 5] FIG. is a diagnostic flowchart of multivariate analysis processing applied to a programmable controller. [Figure 6] FIG. is a flowchart of diagnostic model generation. [Figure 7] FIG. is a diagram showing an example of a hardware configuration.
Modes for Carrying Out the Invention
[0020] Hereinafter, the present invention will be described through embodiments of the invention. However, the following embodiments do not limit the invention according to the claims. Also, not all combinations of features described in the embodiments are essential for the solution means of the invention.
[0021] FIG. 1 shows an example of the configuration of a system 10 to which a programmable controller is applied. System 10 may be used in industrial facilities such as factories or plants. System 10 may be used as at least a part of factory automation. The programmable controller controls the production line of the industrial facility and controls the machine tools.
[0022] System 10 comprises a CPU module 100, a function module 200, an I / O module 300, a management device 400, a controlled device 250, and a controlled device 350. The CPU module 100 performs calculation processing to control the controlled devices 250 and 350. The function module 200 has the function of performing predetermined specific processing. For example, the function module 200 has the function of a servo amplifier or inverter for controlling actuators such as motors. The I / O module 300 performs data input and output to the CPU module 100. The management device 400 assists with the settings of the CPU module 100, etc. The CPU module 100, the function module 200, and the I / O module 300 are programmable controllers, each with different functions.
[0023] The management device 400 may be configured as software on a general-purpose personal computer. The management device 400 may also be a dedicated device for managing the programmable controller. For convenience, here we refer to the personal computer that manages the software as the management device 400. The management device 400 and the CPU module 100 are connected using a communication cable such as RS-232C or USB.
[0024] Furthermore, the CPU module 100, the function module 200, and the I / O module 300 are network-connected to each other and perform input / output data transfer and message communication.
[0025] The controlled devices 250 and 350 are the devices to be controlled. The controlled devices 250 and 350 may be, for example, industrial machinery. The controlled devices 250 and 350 may be motors, encoders, pumps, valves, cameras, various sensors, etc.
[0026] The CPU module 100, function module 200, and I / O module 300 can be freely selected by the user depending on the scale or configuration of the system they wish to control. The user uses the management device 400 to configure the system and set the operation of each module. The user also uses the management device 400 to create control application programs using ladder diagrams, etc., and downloads the created application programs to the CPU module 100.
[0027] Figure 2 shows an example of the hardware configuration of the CPU module 100. The CPU module 100 comprises a CPU 102, a driver / receiver 104, a bus controller 106, a flash memory 108, a program memory 110, and a data memory 112. The driver / receiver 104 may be RS422 or USB for connection to the management device 400. The bus controller 106 is connected to a network and controls communication between the function module 200 and the I / O module 300. The flash memory 108 stores programs for the system processing of the CPU module 100 (system management of the CPU module 100, communication processing, fault information collection, etc.) and application programs for control. The program memory 110 is a memory for the CPU 102 to boot and execute programs from the flash memory 108 in order to execute system processing and application programs at a higher speed. The data memory 112 stores data used by the program. The CPU 102 performs various calculations using the program in the program memory 110 and the data in the data memory 112. CPU 102 is an example of an execution unit. Data memory 112 is an example of a storage unit.
[0028] The hardware configuration shown in Figure 2 is merely a schematic representation of some of the functions of the CPU module 100 and is not limited to this configuration. The CPU module 100 may further include, for example, a power supply circuit, a reset circuit, and an interface to a removable external storage device. Also, if the system 10 has multiple CPU modules 100, not all CPU modules 100 have to have the hardware configuration shown in Figure 2. For example, the program memory 110 may be a faster SDRAM, or the CPU 102 may have built-in RAM.
[0029] As described above, the CPU module 100 collects input data from the function module 200 and the I / O module 300 via the network at regular intervals (scan cycles). Based on the input data, the CPU module 100 executes a control application program and outputs output data based on the execution results of the application program to the function module 200 and the I / O module 300 via the network.
[0030] Here, in order to precisely control the controlled devices 250 and 350 connected to the functional module 200 and the I / O module 300, it is desirable that the input / output processing via the aforementioned network be performed accurately, quickly, and at a constant interval.
[0031] Typically, programmable controllers prioritize the execution of control application programs. Therefore, other processes are generally executed during the remaining time after the application program has finished running within a single execution cycle.
[0032] In recent years, in the field of factory automation (FA), there has been a need to apply multivariate analysis technology to programmable controllers for the early detection of defects in processed products and abnormalities in equipment. The application program for the programmable controller needs to control the controlled devices 250 and 350 at high speed and at a constant cycle. On the other hand, when applying multivariate analysis technology to a programmable controller, multivariate analysis generates a diagnostic model from normal input patterns, provides input data to this diagnostic model, and then performs advanced matrix operations. Compared to application programs, multivariate analysis requires a significant amount of computation time before obtaining diagnostic results. Furthermore, in multivariate analysis, because recursive operations are performed to obtain analysis results, the time to obtain the diagnostic results is not always definitively determined. For this reason, if the diagnostic processing using multivariate analysis is implemented within the control application program, the processing cycle of the application program may fluctuate significantly.
[0033] Therefore, in this embodiment, the diagnostic function using multivariate analysis is decomposed into multiple functions (storage process 608, preprocessing 612, analysis process 614, judgment process 616, and notification process 618), as shown in Figure 5 below. Of these decomposed functions, the data input for the storage process 608 is performed by the application program, while time-consuming processes such as preprocessing 612, analysis process 614, and judgment process 616 are performed by the data processing described below. By decomposing the diagnostic function in this way, it becomes possible to realize the multivariate analysis function on the programmable controller while keeping the impact on the processing cycle of the application program to approximately the time it takes to copy the input data.
[0034] Figure 3 shows an example of the software structure of a programmable controller. The real-time OS 160 runs on the hardware 162. The real-time OS 160 calls the bandwidth management layer 158 as a single processing system, within which the application scheduler 156 and data processing 152 are called. The bandwidth management layer 158 sets the time allocated to the application scheduler 156 and data processing 152 in a time allocation ratio within one execution cycle, according to user-specified parameters. The application scheduler 156 processes the user application program 150 according to the execution time ratio set by the bandwidth management layer 158, and the remaining time is used by the data processing 152. In the data processing 152, multivariate analysis processing is executed along with data communication processing, data transfer processing, fault data collection processing, etc. This allows the user to specify the time allocation between the application program and multivariate analysis processing within one execution cycle. The basic system 154 also includes processing belonging to the processing necessary to operate the system as a programmable controller, such as initial processing and system maintenance processing. When performing processing belonging to the basic system 154 after the application has started, the basic system 154 is operated within the bandwidth of the data processing 152.
[0035] The time allocation ratio for the bandwidth management layer 158 is changed by the user from the management device 400. The time allocation ratio is a parameter that specifies how the execution cycle time allocated to the bandwidth management layer 158 within one execution cycle time is allocated between the application scheduler 156 and the data processing 152. The user sets a time allocation ratio that suits the system, taking into account the total execution cycle time, the execution time of the user application program 150, and the execution time of the data processing 152.
[0036] Figure 4 illustrates task processing scheduling in a programmable controller. The programmable controller includes a CPU 102, which corresponds to the execution unit. The vertical axis shows task priority, and the horizontal axis shows elapsed time. One execution cycle time includes a period 501 in which tasks of the user application program 150 are executed, and a period 502 in which tasks other than those of the user application program 150 are executed. Tasks other than those of the user application program 150 include tasks of the data processing 152. Period 501 is an example of the first period, and period 502 is an example of the second period.
[0037] One execution cycle time is allocated to tasks by the application scheduler 156, which manages the execution of the user application program 150, and tasks by the data processing 152. The CPU 102 executes these tasks. At the highest priority are interrupt handling 540 for the OS or higher-level hardware, etc. Immediately below that in priority are the tasks of the user application program 150 scheduled by the application scheduler 156.
[0038] The CPU 102 executes the tasks of the user application program 150 in the order of highest priority, task a510, task b512, and task c514, within the period 501 allocated to the user application program 150. After completing the execution of the tasks of the user application program 150, the CPU 102 executes the tasks of the data processing 152 in the order of highest priority, task A520, and task B522, within the period 502 allocated to the data processing 152. The tasks of the data processing 152 include tasks for data communication processing with the management device 400 that manages the CPU module 100.
[0039] For example, if a user customizes the system to prioritize data processing 152 within one execution cycle, they can set a larger allocation ratio for period 502. In this case, the period 501 allocated to the user application program 150 becomes relatively shorter. As a result of the shortened period 501 for the user application program 150, any remaining execution processes that were not executed will be processed in the next execution cycle. In the case of real-time control where the control system performs positioning, setting a larger period 501 for the user application program 150 can improve positioning performance. In the case of a monitoring system where the control system displays data collected by a program controller on a screen, setting a larger period 502 for data processing 152 can improve screen display / update performance.
[0040] Figure 5 shows an example of a diagnostic flow using multivariate analysis. In this embodiment, the multivariate analysis consists of a flow 700 of the user application program 150 and a flow 600 of the data processing 152. The CPU 102 subdivides the flow 700 of the user application program 150 into tasks and executes them within a period 501. The CPU 102 subdivides the flow 600 of the data processing 152 into tasks and executes them within a period 502.
[0041] The CPU 102 executes a time-series data acquisition start command 702, and triggers the time-series data acquisition start command to start the flow 700 of the user application program 150. During the period 501, the CPU 102 executes an input process 704 that receives time-series data indicating the state of the target to be diagnosed from the function module 200 and the I / O module 300. The input process 704 may consist of function blocks as described later. The target to be diagnosed may be a workpiece such as a processed product on a manufacturing line, a controlled device 250 controlled by the CPU module 100, or a controlled device 350. Time-series data refers to data that changes with each scan period, such as various sensor values, speed or torque from a servo amplifier. The CPU 102 passes the received time-series data to the storage process 608 in the data processing flow 600 of the data processing 152. The input process 704 does not store the time-series data from the function module 200 and the I / O module 300 in a buffer, but instead outputs it sequentially to the storage process 608.
[0042] During period 502, the CPU 102 starts the data processing flow 600 of data processing 152. During period 502, the CPU 102 executes at least part of the storage process 608 and the diagnostic process 610. The storage process 608 stores the time-series data received by the input process 704 in the data memory 112. The diagnostic process 610 diagnoses the state of the target based on the time-series data stored in the data memory 112 by the storage process 608. The diagnostic process 610 includes pre-processing 612, analysis process 614, judgment process 616, and notification process 618.
[0043] Preprocessing 612 converts a predetermined amount of time series data into a data format for diagnosis. Analysis 614 performs multivariate analysis based on the time series data processed in preprocessing 612. Analysis 614 performs multivariate analysis according to a predetermined algorithm to obtain values indicating the state of the subject to diagnosis, such as the Q statistic (Q value) and T 2 Statistics (T 2The value may be output. The determination process 616 determines whether the state of the target to be diagnosed is normal or not based on the analysis results of the analysis process 614. The determination process 616 may determine whether the state of the target to be diagnosed is normal or not by comparing the value indicating the state of the target to be diagnosed with a threshold. The determination process 616 may determine whether the state of the target to be diagnosed is normal or not by determining whether the value indicating the state of the target to be diagnosed falls within a threshold range according to the diagnostic model. The CPU 102 may perform a single diagnosis of the state of the target to be diagnosed over multiple execution cycles by executing the storage process 608 and the diagnosis process 610 within the period 502 of each execution cycle.
[0044] The CPU 102 executes diagnostic initialization 602 to start initializing the diagnostic processing program. Next, the CPU 102 executes model loading 604 to load the diagnostic model from the data memory 112. Then, the CPU 102 determines whether it is time to start time-series data collection for the diagnostic program based on whether a command to start time-series data collection has been output (606). If it is time to start time-series data collection for the diagnostic program, the CPU 102 sequentially stores the time-series data from input processing 704 into the data memory 112 in storage processing 608. The CPU 102 determines whether a predetermined amount of time-series data, which is the number of data required for diagnosis, has been stored in the data memory 112 (609). Once a predetermined amount of time-series data has been stored, the CPU 102 performs preprocessing 612. More specifically, the CPU 102 performs preprocessing 612 on the time-series data to shape it into diagnostic data, such as imputing missing data and converting to frequency components (FFT). Subsequently, the CPU 102 performs multivariate analysis, such as univariate analysis and bivariate analysis, based on the diagnostic data. Finally, the CPU 102 performs a determination process 616 to determine whether the operation of the controlled device 250 and the controlled device 350 or the processed product is normal or abnormal, and performs a notification process 618 to notify the diagnostic result as the determination result.
[0045] If the CPU 102 cannot complete the series of processes that constitute one diagnosis, from the storage process 608 to the notification process 618, within one execution cycle, it will perform one diagnosis by executing the series of processes over multiple execution cycles, each within a period 502. If the time it takes to complete the series of processes is too long, it will take time to reflect the diagnosis results in the operation of the controlled devices 250 and 350. In other words, it may take a long time to discover that there is a malfunction in the operation of the controlled devices 250 and 350. In this case, for example, the number of defective products may increase.
[0046] Therefore, if the CPU 102 fails to complete a single diagnosis within a predetermined number of execution cycles, the CPU 102 may execute output processing to output a message to that effect when a single diagnostic process is completed, or during the diagnostic process. The output processing may consist of a function block as described later. The user can specify a new parameter to increase the proportion of period 502 within one execution cycle in response to the message. If a new parameter is specified, the CPU 102 adjusts the lengths of period 501 and period 502 according to the new parameter. This shortens the time it takes to reflect the diagnostic results in the operation of the controlled devices 250 and 350, and for example, can suppress an increase in the number of defective products. If a message indicating that a single diagnosis could not be completed within a predetermined number of execution cycles is output, the CPU 102 may adjust the lengths of period 501 and period 502 in response to the message so that the proportion of period 502 within one cycle increases. CPU 102 may adjust the lengths of periods 501 and 502 so that the length of period 502 increases by a predetermined percentage. CPU 102 may set the predetermined percentage based on the number of execution cycles required until the series of processes are completed. CPU 102 may set the predetermined percentage so that it increases in proportion to the number of execution cycles required until the series of processes are completed.
[0047] The input processing 704 for time-series data to be passed from the user application program 150 to the storage processing 608 in the data processing 152 may be composed of a function block.
[0048] A function block (hereinafter referred to as FB) is one of the program components in the programming language specification for programmable controllers defined in IEC 61131-3. FBs modularize programs that are repeatedly processed within a sequence program, making them reusable. Unlike functions, which require input of all necessary parameters for each call, FBs are characterized by their ability to perform calculations using internally held data in addition to input parameters.
[0049] Furthermore, the storage process 608, preprocessing 612, analysis process 614, judgment process 616, and notification process 618 may each consist of at least one FB. The storage process 608, preprocessing 612, analysis process 614, judgment process 616, and notification process 618 may each consist of an FB. If the storage process 608 is composed of an FB, the storage process 608, which is called at each scan cycle, can record the input values up to the previous call and the value input this time. Once the CPU 102 has accumulated enough time-series data for the scan cycle in which the diagnosis is performed, it executes the subsequent preprocessing 612, analysis process 614, and judgment process 616.
[0050] Regarding the notification process 618, methods such as stopping the programmable controller or notifying external display devices such as LEDs are also conceivable. However, by configuring the notification process 618 itself as a feedback loop, it becomes possible to reflect the diagnostic results received by the control process 706 on the user application program 150 side into the control performed by the user application program 150. For example, when diagnosing defects in processed products, feeding back the diagnostic results during the processing of the user application program 150 makes it possible to sort defective products in a timely manner.
[0051] Within the period 501, the CPU 102 executes a control process 706 in the user application program 150 for the controlled devices 250 and 350 related to the diagnostic target. The control process 706 may be a process that controls actuators such as motors driven on the production line. The control process 706 may consist of at least one feedback function (FB). For the aforementioned feedback, the CPU 102 may execute a notification process 618 that notifies the control process 706 executed in the user application program 150 of the diagnostic result, which is the result of the determination process 616. The notification process 618 may also consist of an FB. In the control process 706, the CPU 102 may execute a process to separate defective products by controlling actuators such as motors driven on the production line according to the diagnostic result.
[0052] When a programmable controller incorporates a diagnostic function based on multivariate analysis using a diagnostic model, it is anticipated that the execution of the diagnostic function will take a long time if the load of the diagnostic function is higher than the load of the user application program 150. Therefore, the CPU 102 may also function as a reception unit that receives ratio information specifying the proportion of each of period 501 and period 502 within one execution cycle. The reception unit may receive user-specified parameters that specify the time allocation ratio as ratio information. The CPU 102 may adjust the lengths of period 501 and period 502 based on the parameters received from the user. This allows the user to optimally specify the time allocation ratio between the user application program 150 and the data processing 152.
[0053] Generally, diagnostic models are generated by combining data from multiple successful processing patterns and generating a diagnostic model based on this successful data. For example, a user could manually generate a diagnostic model using the management device 400 shown in Figure 1 before system operation and download the generated diagnostic model to the CPU module 100. At the start of operation, the user would load the diagnostic model into the CPU module 100 and use it for multivariate analysis. However, if the model generation process is functionally divided into a model generation data storage process and a model generation process, and then performed by the data processing of the CPU module 100, the model generation function can be implemented in the CPU module 100.
[0054] Diagnostic models are affected by changes in the product being processed or the cutting tools of the equipment, requiring modifications to the diagnostic model. Users can recognize such changes. It is possible to manually regenerate the diagnostic model each time such changes occur. However, changes in environmental factors such as temperature and humidity around the equipment, or the aging of cutting tools or moving parts on the production line during use, are relatively gradual fluctuations and therefore difficult for users to recognize. As a result, it is difficult for users to update the diagnostic model due to factors such as changes in environmental factors or aging.
[0055] Therefore, in this embodiment, the CPU 102 executes a generation process 628 within the period 502 to generate a diagnostic model to be used in the analysis process 614 based on time series data that indicates the state of the condition to be diagnosed is normal. The generation process 628 may generate a diagnostic model using time series data that indicates normality according to a predetermined algorithm such as multiple regression analysis, principal component regression, partial least squares (PLS), autoregressive (AR) model, or vector autoregressive (VAR) model.
[0056] The CPU 102 may execute an update process 630 to update the diagnostic model used in the analysis process 614 with the diagnostic model generated by the generation process 628 while the analysis process 614 is not being executed within the period 502. This prevents the analysis from failing to proceed properly due to the diagnostic model currently used in the analysis process 614 being updated midway through the analysis. Since the analysis process 614 is not being executed before the start of the preprocessing 612, the CPU 102 may execute the update process 630 before the start of the preprocessing 612.
[0057] Figure 6 shows an example of the flow for generating and updating a diagnostic model. Within period 501, the CPU 102 executes a time-series data collection start command 710, and the flow for generating and updating the diagnostic model is triggered by the time-series data collection start command. Within period 501, the CPU 102 executes an input process 712 that receives time-series data indicating the state of the diagnostic target from the function module 200 and the I / O module 300. The input process 704 may consist of a function block as described later.
[0058] Within period 502, CPU 102 executes diagnostic model generation initialization 620 to start initializing the diagnostic model generation program. Next, CPU 102 determines whether it is time to start time series data collection for diagnostic model generation based on whether a command to start time series data collection has been output (622). If it is time to start time series data collection for diagnostic model generation, CPU 102 executes model generation data storage process 624 within period 502 to store time series data that has been determined to be normal by the judgment process 616 in the diagnostic process 610 from the time series data received from the input process 712 in the data memory 112. CPU 102 determines whether a predetermined amount of time series data, which constitutes one time series data, has been stored (626). Furthermore, CPU 102 determines whether a predetermined number of time series data has been stored in the data memory 112 (627). When a predetermined number of time series data has been stored, CPU 102 determines that a predetermined amount of time series data necessary for generating the diagnostic model has been stored.
[0059] When a predetermined amount of time-series data necessary for generating a diagnostic model has been accumulated, the CPU 102 executes the generation process 628. In the generation process 628, the CPU 102 uses the time-series data that was determined to be normal in the judgment process 616 of the diagnostic process 610 to generate the diagnostic model used in the analysis process 614 as needed.
[0060] The CPU 102 executes the update process 630 when the analysis process 614 is not being executed. For example, the CPU 102 executes the update process 630 before the start of the preprocessing 612. The CPU 102 sets a generation completion flag when the generation of a new diagnostic model is completed in the generation process 628. The CPU 102 also sets an analysis completion flag when the analysis process 614 using the currently used diagnostic model is completed. The CPU 102 executes the update process 630 when both the generation completion flag and the analysis completion flag are set. By sequentially updating the diagnostic model in this way, the CPU module 100 can always operate the control system using the optimal diagnostic model.
[0061] In the actual application of diagnostic model generation, for example, the diagnostic model may be updated according to the processing lot from the perspective of quality traceability. Furthermore, measures such as saving the date and time of the diagnostic model change and the applied diagnostic model data may be implemented. Additionally, a function may be used to roll back to the previously used diagnostic model if the judgment result of the applied diagnostic model is inappropriate.
[0062] Figure 7 shows an example of a computer 1200 in which multiple aspects of the present invention may be embodied in whole or in part. A program installed on the computer 1200 can cause the computer 1200 to function as an operation associated with an apparatus according to an embodiment of the present invention, or as one or more "parts" of said apparatus. Alternatively, the program can cause the computer 1200 to execute said operation or said one or more "parts". The program can cause the computer 1200 to execute a process or a stage of said process according to an embodiment of the present invention. Such a program may be executed by the CPU 1212 to cause the computer 1200 to execute a particular operation associated with some or all of the blocks in the flowcharts and block diagrams described herein.
[0063] The computer 1200 according to this embodiment includes a CPU 1212 and RAM 1214, which are interconnected by a host controller 1210. The computer 1200 also includes a communication interface 1222 and input / output units, which are connected to the host controller 1210 via an input / output controller 1220. The computer 1200 also includes a ROM 1230. The CPU 1212 operates according to programs stored in the ROM 1230 and RAM 1214, thereby controlling each unit.
[0064] The communication interface 1222 communicates with other electronic devices via a network. A hard disk drive may store programs and data used by the CPU 1212 in the computer 1200. The ROM 1230 stores boot programs and / or programs that depend on the computer 1200's hardware, such as a boot program executed by the computer 1200 upon activation. Programs are provided via computer-readable recording media such as a CR-ROM, USB memory, or IC card, or via a network. Programs are installed in RAM 1214, which is also an example of a computer-readable recording media, or in ROM 1230, and executed by the CPU 1212. The information processing described within these programs is read by the computer 1200, resulting in coordination between the programs and the various types of hardware resources described above. An apparatus or method may be configured to implement information operations or processing in accordance with the use of the computer 1200.
[0065] For example, when communication is performed between a computer 1200 and an external device, the CPU 1212 may execute a communication program loaded into RAM 1214 and, based on the processing described in the communication program, instruct the communication interface 1222 to perform communication processing. Under the control of the CPU 1212, the communication interface 1222 reads the transmission data stored in the transmission buffer area provided in RAM 1214 or a recording medium such as a USB memory, sends the read transmission data to the network, or writes the received data received from the network to a receive buffer area or the like provided on the recording medium.
[0066] Furthermore, the CPU 1212 may read all or necessary parts of a file or database stored on an external storage medium such as a USB memory stick into the RAM 1214, and perform various types of processing on the data in the RAM 1214. The CPU 1212 may then write the processed data back to the external storage medium.
[0067] Various types of information, such as various types of programs, data, tables, and databases, may be stored on the recording medium and subjected to information processing. The CPU 1212 may perform various types of processing on the data read from RAM 1214, including various types of operations, information processing, conditional judgments, conditional branching, unconditional branching, information retrieval / replacement, etc., as described throughout this disclosure and specified by the program instruction sequence, and write the results back to RAM 1214. The CPU 1212 may also retrieve information in files, databases, etc., within the recording medium. For example, if multiple entries are stored in the recording medium, each having an attribute value of a first attribute associated with an attribute value of a second attribute, the CPU 1212 may search among the multiple entries for an entry that matches the condition for which the attribute value of the first attribute is specified, read the attribute value of the second attribute stored in that entry, and thereby obtain the attribute value of the second attribute associated with the first attribute that satisfies a predetermined condition.
[0068] The program or software module described above may be stored on or near computer 1200 on a computer-readable storage medium. Alternatively, a recording medium such as a hard disk or RAM provided within a server system connected to a dedicated communication network or the Internet can be used as a computer-readable storage medium, thereby providing the program to computer 1200 via the network.
[0069] Computer-readable media may include any tangible device capable of storing instructions that can be executed by a suitable device. As a result, computer-readable media having instructions stored therein will comprise a product containing instructions that can be executed to create means for performing operations specified in a flowchart or block diagram. Examples of computer-readable media may include electronic storage media, magnetic storage media, optical storage media, electromagnetic storage media, semiconductor storage media, etc. More specific examples of computer-readable media may include floppy disks, diskettes, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), electrically erasable programmable read-only memory (EEPROM), static random access memory (SRAM), compact disk read-only memory (CD-ROM), digital versatile disk (DVD), Blu-ray (RTM) disk, memory stick, integrated circuit card, etc.
[0070] Computer-readable instructions may include either source code or object code written in any combination of one or more programming languages. Source code or object code may include conventional procedural programming languages. These conventional procedural programming languages may include assembler instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or object-oriented programming languages such as Smalltalk®, Java®, C++, etc., and the "C" programming language or similar programming languages. Computer-readable instructions may be provided locally or via a wide area network (WAN) such as a local area network (LAN) or the internet to the processor or programmable circuit of a general-purpose computer, a special-purpose computer, or other programmable data processing device. The processor or programmable circuit may execute computer-readable instructions to create means for performing operations specified in a flowchart or block diagram. Examples of processors include computer processors, processing units, microprocessors, digital signal processors, controllers, microcontrollers, etc.
[0071] Although the present invention has been described above using embodiments, the technical scope of the present invention is not limited to the scope described in the above embodiments. It will be apparent to those skilled in the art that various modifications or improvements can be made to the above embodiments. It will be clear from the claims that such modified or improved forms may also be included in the technical scope of the present invention. It should be noted that the execution order of operations, procedures, steps, and stages in the apparatus, systems, programs, and methods shown in the claims, specifications, and drawings is not explicitly stated as "before," "prior to," etc., and that these can be implemented in any order unless the output of a previous process is used in a later process. Even if the operation flow in the claims, specifications, and drawings is described using phrases such as "first," "next," etc. for convenience, it does not mean that it is essential to perform the operations in that order. [Explanation of symbols]
[0072] 10 Systems 100 CPU modules 102 CPU 104 Driver / Receiver 106 Bus Controller 108 Flash Memory 110 Program Memory 112 data memory 150 User Application Programs 152 Data Processing 154 Basic System 156 Application Scheduler 158 Bandwidth Management Layer 162 Hardware 200 Function Modules 250,350 Controlled equipment 300 I / O modules 400 Management device 602 Diagnostic reset 608 Storage process 610 Diagnostic Processing 612 Preprocessing 614 Analysis Processing 616 Judgment process 618 Notification Processing 620 Initialization of diagnostic model generation 624 Data storage process for model generation 628 Generation process 630 Update process 702,710 Time-series data collection start command 704,712 Input Processing 706 Control Processing 1200 Computers 1210 Host Controller 1212 CPU 1214 RAM 1220 Input / Output Controller 1222 Communication Interface 1230 ROM
Claims
1. An execution unit that executes tasks of an application program within a first period within one cycle, and executes tasks other than those of the application program within a second period following the first period within the same cycle, A receiving unit that receives information specifying the respective proportions of the first period and the second period within one cycle, The execution unit is, Within the first period, the application program performs an input process as a task to receive time-series data indicating the state of the subject to diagnosis. Within the second period, at least a portion of the following is performed: storage processing, which stores the time-series data received by the input processing in a storage unit; and diagnostic processing, which diagnoses the state of the target to be diagnosed based on the time-series data stored in the storage unit in the storage processing. The aforementioned diagnostic process is: When a predetermined amount of the time-series data is stored in the storage unit through the storage process, a preprocessing step is taken to convert the predetermined amount of the time-series data into a data format for diagnosis. An analysis process that performs multivariate analysis based on the time series data processed in the aforementioned preprocessing, A determination process that determines whether the state of the subject to diagnosis is normal or not based on the analysis results of the analysis process, If a single diagnosis of the condition to be diagnosed cannot be completed within a predetermined number of cycles, an output process is performed to output a message to that effect. Includes, The execution unit adjusts the lengths of the first period and the second period in response to the message, such that the proportion of the second period within one cycle increases. Programmable controller.
2. The programmable controller according to claim 1, wherein the execution unit performs the storage process and the diagnostic process over multiple cycles, within the second period of each cycle, thereby performing a single diagnosis of the state of the target to be diagnosed over the multiple cycles.
3. The programmable controller according to claim 1 or 2, wherein the execution unit performs a generation process within the second period to generate a diagnostic model used in the analysis process based on time series data from the time series data that indicates the state of the target to be diagnosed is normal.
4. The programmable controller according to claim 3, wherein the execution unit performs an update process to update the diagnostic model used in the analysis process with the diagnostic model generated by the generation process while the analysis process is not being performed during the second period.
5. The programmable controller according to claim 4, wherein the execution unit performs the update process before the start of the preprocessing.
6. The execution unit executes control processing on the controlled device related to the diagnostic target within the first period. The programmable controller according to any one of claims 1 to 5, wherein the diagnostic process includes a notification process that notifies the control process of the determination result obtained by the determination process.
7. The programmable controller according to any one of claims 1 to 6, wherein the storage process and the diagnostic process are comprised of at least one function block.
8. The programmable controller according to any one of claims 1 to 7, wherein tasks other than the application program include tasks of data communication processing with a management device that manages the programmable controller.
9. A control method for controlling a programmable controller, An execution phase in which the tasks of an application program are executed within a first period within one cycle, and tasks other than those of the application program are executed within a second period following the first period within the same cycle, The process includes receiving information that identifies the respective proportions of the first period and the second period within one cycle, The aforementioned execution stage is, Within the first period, the application program performs an input process that accepts time-series data indicating the state of the subject to diagnosis as a task, Within the second period, the steps include: a storage process in which the time-series data received by the input process is stored in a storage unit; and a diagnostic process in which at least a part of the diagnostic process is performed in which the state of the target to be diagnosed is diagnosed based on the time-series data stored in the storage unit in the storage process. The aforementioned diagnostic process is: When a predetermined amount of the time-series data is stored in the storage unit through the storage process, a preprocessing step is taken to convert the predetermined amount of the time-series data into a data format for diagnosis. An analysis process that performs multivariate analysis based on the time series data processed in the aforementioned preprocessing, A determination process that determines whether the state of the subject to diagnosis is normal or not based on the analysis results of the analysis process, If a single diagnosis of the condition to be diagnosed cannot be completed within a predetermined number of cycles, an output process is performed to output a message to that effect. Includes, The control method further includes the step of adjusting the lengths of the first period and the second period in response to the message, such that the proportion of the second period within a cycle increases.
10. A program that enables a computer to function as a programmable controller. An execution phase in which the tasks of an application program are executed within a first period within one cycle, and tasks other than those of the application program are executed within a second period following the first period within the same cycle, The computer is made to perform the steps of receiving information that identifies the respective proportions of the first period and the second period within one cycle, The aforementioned execution stage is, Within the first period, the application program performs an input process that accepts time-series data indicating the state of the subject to diagnosis as a task, Within the second period, the steps include: a storage process in which the time-series data received by the input process is stored in a storage unit; and a diagnostic process in which at least a part of the diagnostic process is performed in which the state of the target to be diagnosed is diagnosed based on the time-series data stored in the storage unit in the storage process. The aforementioned diagnostic process is: When a predetermined amount of the time-series data is stored in the storage unit through the storage process, a preprocessing step is taken to convert the predetermined amount of the time-series data into a data format for diagnosis. An analysis process that performs multivariate analysis based on the time series data processed in the aforementioned preprocessing, A determination process that determines whether the state of the subject to diagnosis is normal or not based on the analysis results of the analysis process, If a single diagnosis of the condition to be diagnosed cannot be completed within a predetermined number of cycles, an output process is performed to output a message to that effect. Includes, The program is a program that, in response to the message, causes the computer to further perform the step of adjusting the lengths of the first period and the second period so that the proportion of the second period within one cycle increases.
Citation Information
Patent Citations
Control device, control method, and control program
JP2018181315A
Control device and program
JP2020101904A