Log data processing device, log data processing system, log data processing method and program
The log data processing device addresses the inefficiency of analyzing PLC control data across multiple files by chronologically combining them, enhancing analysis efficiency.
Patent Information
- Application Number
- JP2025561244
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2025-07-11
- Publication Date
- 2026-01-09
- Estimated Expiration
- 2045-07-11
AI Technical Summary
Analyzing logged PLC control data across multiple files is time-consuming due to the need to switch back and forth between files when the time period of the control data spans multiple files.
A log data processing device that combines multiple log files chronologically by adding empty records if necessary to ensure continuity, allowing for continuous analysis without file switching.
Facilitates efficient analysis of PLC control data by ensuring chronologically continuous records, simplifying the analysis process and improving work efficiency.
Smart Images

Figure 0007796949000001 
Figure 0007796949000002 
Figure 0007796949000003
Abstract
Description
[Technical Field]
[0001] The present disclosure relates to a log data processing device, a log data processing system, a log data processing method, and a program. [Background technology]
[0002] In general, in FA (Factory Automation) systems, control data of a PLC (Programmable Logic Controller) is logged, and when a problem occurs, the logged control data is used to analyze the cause of the problem (see, for example, Patent Document 1). Patent Document 1 describes a technology for updating logging settings without stopping the logging process of the PLC. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Patent No. 7548464 Summary of the Invention [Problem to be solved by the invention]
[0004] Normally, logged control data is saved as a data file in some format. In this case, the file in which the logged control data is stored is typically switched according to certain conditions (such as time or data size) so that the data size of each file does not become too large. As a result, for example, PLC control data logged over the entire time period of a working day is stored in multiple files under certain conditions.
[0005] However, when a problem occurs and the time period of the control data to be analyzed spans multiple files, it may be necessary to go back and forth between the multiple files to analyze it, which is time-consuming.
[0006] The present disclosure has been made to solve the above problems, and aims to provide a log data processing device, a log data processing system, a log data processing method, and a program that can facilitate the analysis of logged PLC control data. [Means for solving the problem]
[0007] In order to achieve the above object, the log data processing device according to the present disclosure includes: a join target designation receiving means for receiving, as join target data, a plurality of designations of log data that is time-series data in which a plurality of records indicating control data at a certain time of a PLC are stored; and a combining means for combining the plurality of join target data accepted by the join target designation receiving means so that each record is chronologically continuous, and storing the combined data in a storage device. 、 When the logging start time, which is the logging time of the first record of one of the two pieces of data to be joined, is later than the logging end time, which is the logging time of the last record of the other piece of data to be joined, the joining means adds to one of the pieces of data to be joined a number of empty records equivalent to a value obtained by subtracting 1 from a value obtained by dividing the difference between the logging start time and the logging end time by the logging period, and then joins the two pieces of data to be joined. . [Effects of the Invention]
[0008] According to the present disclosure, it is possible to facilitate the analysis of logged PLC control data. [Brief explanation of the drawings]
[0009] [Figure 1] FIG. 1 shows a configuration of an analysis support system according to a first embodiment. [Figure 2] FIG. 1 is a block diagram showing a hardware configuration of an analysis support device according to a first embodiment. [Figure 3] FIG. 1 is a block diagram showing a functional configuration of an analysis support device according to a first embodiment. [Figure 4] FIG. 1 is a diagram illustrating a record configuration of a log file according to the first embodiment. [Figure 5] 1 is a flowchart showing the procedure of a joining process according to the first embodiment. [Figure 6] 1 is a flowchart showing the procedure of the first joining process according to the first embodiment. [Figure 7]FIG. 1 is a diagram schematically illustrating a combination performed by a first combination process according to the first embodiment; [Figure 8] 1 is a flowchart showing the procedure of the second joining process according to the first embodiment. [Figure 9] FIG. 1 is a diagram schematically illustrating the joining performed by the second joining process according to the first embodiment; [Figure 10] FIG. 1 is a block diagram showing a functional configuration of an analysis support device according to a modification of the first embodiment. [Figure 11] FIG. 1 is a block diagram showing a functional configuration of an analysis support device according to a modification of the first embodiment. [Figure 12] FIG. 10 is a diagram showing the configuration of an analysis support system according to a second embodiment. [Figure 13] FIG. 10 is a block diagram showing the functional configuration of an analysis support device according to a second embodiment. [Figure 14] FIG. 10 is a diagram illustrating a joining process according to the second embodiment. [Figure 15] FIG. 10 is a block diagram showing a functional configuration of an analysis support device according to a modification of the second embodiment. [Figure 16] FIG. 10 is a block diagram showing a functional configuration of an analysis support device according to a modification of the second embodiment. [Figure 17] FIG. 10 is a diagram showing the configuration of an analysis support system according to a third embodiment. [Figure 18] FIG. 10 is a block diagram showing the functional configuration of an analysis support device according to a third embodiment. [Figure 19] FIG. 10 is a diagram showing a schematic diagram of a combination performed by a combination process according to the third embodiment; [Figure 20] FIG. 10 is a diagram illustrating a joining process according to a modification of the third embodiment. [Figure 21] FIG. 10 is a block diagram showing a functional configuration of an analysis support device according to a modification of the third embodiment. [Figure 22] FIG. 10 is a block diagram showing a functional configuration of an analysis support device according to a modification of the third embodiment. DETAILED DESCRIPTION OF THE INVENTION
[0010] The log data processing device, the log data processing system, the log data processing method, and the program according to the present disclosure can be applied to various control devices.
[0011] (Embodiment 1) FIG. 1 is a diagram showing the configuration of an analysis support system 1A according to a first embodiment. The analysis support system 1A is a system that supports a user in analyzing logged control data output by a PLC, and includes a PLC system 2 and an analysis support device 3A. The PLC system 2 corresponds to part of an FA system installed in a factory, and controls controlled devices (not shown) that are field devices such as sensors and actuators. This FA system may be, for example, a production system, an inspection system, a processing system, or other systems. The PLC system 2 includes a PLC, one or more remote I / O (Input / Output) devices, and one or more controlled devices connected to each remote I / O device, all of which are not shown.
[0012] <Hardware configuration of analysis support device 3A> The analysis support device 3A is an example of a log data processing device according to the present disclosure, and is also an example of a log data processing system according to the present disclosure. The analysis support device 3A is a device that supports a user in analyzing the logged control data. As shown in FIG. 2 , the analysis support device 3A includes, as its hardware configuration, a display 30, an operation reception unit 31, a communication unit 32, a processor 33, a ROM (Read-Only Memory) 34, a RAM (Random-Access Memory) 35, and an auxiliary storage device 36. These components are interconnected via a bus 37. The display 30 includes a display device such as a CRT display, a liquid crystal display, or an organic EL (Electroluminescence) display. Under the control of the processor 33, the display 30 displays various screens in response to user operations.
[0013] The operation reception unit 31 includes one or more input devices such as a keyboard, a mouse, push buttons, a touch panel, or a touch pad, receives operation input from a user, and outputs a signal related to the received operation to the processor 33. The communication unit 32 is a communication interface for communicating with the PLC system 2 via a network 4. The network 4 is a network such as a LAN (Local Area Network), a CAN (Campus Area Network), a MAN (Metropolitan Area Network), a WAN (Wide Area Network), or the Internet. The processor 33 is a CPU (Central Processing Unit) that controls the analysis support device 3A. The ROM 34 is a storage device that stores non-rewriteable programs such as a BIOS (Basic Input / Output System). The RAM 35 is a storage device used as a working area for the processor 33.
[0014] The auxiliary storage device 36 is an example of a storage device according to the present disclosure. The auxiliary storage device 36 is a storage device configured with a readable / writable nonvolatile semiconductor memory, a hard disk drive (HDD), or the like. Examples of the readable / writable nonvolatile semiconductor memory include an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), and a flash memory. The auxiliary storage device 36 stores application software known as an engineering tool and data for executing the engineering tool. The processor 33 executes the engineering tool, thereby realizing functions of the analysis support device 3A, such as processing a log file and reproducing (i.e., simulating) the behavior of the PLC system 2 when a problem occurs using the processed log file.
[0015] The analysis support device 3A can acquire the above-mentioned engineering tool or an update program for updating the above-mentioned engineering tool via communication from a server, terminal, etc. (not shown) and install it in itself. These programs can also be stored and distributed on a computer-readable recording medium such as a CD-ROM (Compact Disc Read-Only Memory), a DVD (Digital Versatile Disc), a magneto-optical disk, a USB (Universal Serial Bus) memory, a HDD, an SSD (Solid-State Drive), or a memory card. When such a recording medium is directly or indirectly attached to the analysis support device 3A, the analysis support device 3A can read the above-mentioned engineering tool or the update program from the recording medium and install it in itself.
[0016] <Functional configuration of analysis support device 3A> As shown in FIG. 3 , the analysis support device 3A includes, as its functional configuration, a merge target designation receiving unit 300, a log file merging unit 301, and a simulation execution unit 302. These functional units are realized by the processor 33 executing the above-described engineering tool stored in the auxiliary storage device 36. The merge target designation receiving unit 300 is an example of a merge target designation receiving means according to the present disclosure. The merge target designation receiving unit 300 receives, from a user, a plurality of designations of log files, which are time-series data in which records indicating PLC control data are stored in a predetermined format, as merge target files. The merge target files are an example of merge target data according to the present disclosure, and the log files are an example of log data according to the present disclosure.
[0017] When the PLC system 2 is operating, the PLC periodically logs control data (e.g., every minute). One log file stores records of control data for a predetermined logging time (e.g., 60 minutes). The PLC system 2 transmits the log files it holds to the analysis support device 3A at predetermined times or in response to a request from the analysis support device 3A. The analysis support device 3A saves the log files transmitted from the PLC system 2 in the log file storage unit 360. The log file storage unit 360 is a memory area provided by the auxiliary storage device 36. Information indicating the logging period is added to each log file as a file name. The logging period is indicated, for example, by a logging start time, which is the time when the first record is logged, and a logging end time, which is the time when the last record is logged.
[0018] In this embodiment, the log file storage unit 360 stores multiple log files for a predetermined period obtained by one CPU unit in the PLC system 2 executing the same control program. Each log file has a common record structure. As shown in FIG. 4, each record included in each log file stores a device and a value associated with each other. A device is an identifier that indicates a specific memory area in a storage device (not shown) of the PLC system 2, and is expressed by a combination of the type and number of the device. When executing a control program, the PLC references the device value as input data and updates the device value according to the control result. In other words, the device is control data, and the type and value of the control data are associated and stored in the record. One log file stores as many records as the number of logging events during the logging period.
[0019] The merge target designation receiving unit 300 displays the file names of each log file stored in the log file storage unit 360, and also displays a merge target designation screen (not shown) for receiving designation of merge target files from the user on the display 30. When the user designates multiple merge target files via the merge target designation screen, the merge target designation receiving unit 300 notifies the log file combining unit 301 of the file names of each merge target file.
[0020] The log file merging unit 301 is an example of a merging unit according to the present disclosure. The log file merging unit 301 reads each of the specified files to be merged from the log file storage unit 360 and merges the read files to be merged so that the records are chronologically continuous. The merging process performed by the log file merging unit 301 will be described in detail below.
[0021] <Combination process> 5 is a flowchart showing the procedure for the merging process. To facilitate understanding, the merging process will be described below using an example in which the user specifies two log files (log files 1 and 2) as files to be merged, and the creation time of log file 1 (i.e., the logging start time) is earlier than the creation time of log file 2.
[0022] (Step S101) The log file combining unit 301 compares the logging end time of log file 1 with the logging start time of log file 2, and determines whether the logging start time of log file 2 is before the logging end time of log file 1. When the PLC system 2 is operating, normally, to prevent any control data from being missed, storage of records in the next log file starts before the last record is stored in the log file (i.e., before the logging end time). In other words, one or more records are stored in duplicate in log file 1 and log file 2. On the other hand, when the operation of the PLC system 2 is stopped, logging is not performed during the non-operating period, so a time gap occurs between the logging end time of the previous last log file and the logging start time of the new logging file.
[0023] If the logging start time of log file 2 is before the logging end time of log file 1 (step S101; YES), the process of the log file combination unit 301 proceeds to step S102. On the other hand, if the logging start time of log file 2 is not before the logging end time of log file 1, that is, if the logging start time of log file 2 is after the logging end time of log file 1 (step S101; NO), the process of the log file combination unit 301 proceeds to step S103.
[0024] (Step S102) The log file combining unit 301 executes the first combining process. After that, the log file combining unit 301 ends the combining process. The first combining process will be described in detail later.
[0025] (Step S103) The log file combining unit 301 executes the second combining process. After that, the log file combining unit 301 ends the combining process. The second combining process will be described in detail later.
[0026] <First joining process> FIG. 6 is a flowchart showing the procedure of the first joining process.
[0027] (Step S201) The log file combination unit 301 assigns the position of the first record in log file 2 as an initial value to variable P. Variable P indicates the position of the record to be judged in log file 2 (hereinafter referred to as the "target record") in this process. Thereafter, the process of the log file combination unit 301 proceeds to step S202.
[0028] (Step S202) The log file combining unit 301 determines whether or not a record identical to the target record in log file 2 exists in log file 1. If a record identical to the target record in log file 2 exists in log file 1 (step S202; YES), the process of the log file combining unit 301 proceeds to step S203. On the other hand, if a record identical to the target record in log file 2 does not exist in log file 1 (step S202; NO), the process of the log file combining unit 301 proceeds to step S204.
[0029] (Step S203) The log file combination unit 301 increments P. After that, the process of the log file combination unit 301 returns to step S202.
[0030] (Step S204) The log file combination unit 301 deletes all records from the first record to the P-1th record in the log file 2. After that, the process of the log file combination unit 301 proceeds to step S205.
[0031] (Step S205) The log file combining unit 301 combines the log file 1 with the processed log file 2. After that, the process of the log file combining unit 301 proceeds to step S206.
[0032] (Step S206) The log file combining unit 301 stores the combined log file as a combined file in the combined file storage unit 361. The combined file is an example of combined data according to the present disclosure. The combined file storage unit 361 is a memory area provided by the auxiliary storage device 36. Thereafter, the log file combining unit 301 ends the first combining process. Note that if the combined log file is not in a replayable format, the log file combining unit 301 converts the combined log file into a replayable format and stores the converted log file as a combined file in the combined file storage unit 361. A replayable format file means a file in a format that allows a simulation to be performed by the simulation execution unit 302, which will be described later.
[0033] By the above-described first joining process, even if there are overlapping records between log file 1 and log file 2, log file 1 and log file 2 can be joined so that each record is chronologically continuous, preventing any inconvenience in analysis (see Figure 7).
[0034] <Second joining process> FIG. 8 is a flowchart showing the procedure of the second joining process.
[0035] (Step S301) The log file combination unit 301 calculates the difference between the logging start time of log file 2 and the logging end time of log file 1. After that, the process of the log file combination unit 301 proceeds to step S302.
[0036] (Step S302) The log file combining unit 301 divides the calculated difference value by the logging period (for example, one minute). After that, the process of the log file combining unit 301 proceeds to step S303.
[0037] (Step S303) The log file combination unit 301 determines whether the value obtained by the division in step S302 is 1. If the value obtained by the division in step S302 is 1 (step S303; YES), the process of the log file combination unit 301 proceeds to step S304. If the value obtained by the division in step S302 is not 1 (step S303; NO), the process of the log file combination unit 301 proceeds to step S305.
[0038] (Step S304) In this case, the record at the logging end time of log file 1 and the record at the logging start time of log file 2 are consecutive in time, so the log file combination unit 301 combines log file 1 and log file 2 without processing them. After that, the process of the log file combination unit 301 proceeds to step S307.
[0039] (Step S305) The log file combination unit 301 adds a number of empty records equivalent to the value obtained by subtracting 1 from the value obtained by the division in step S302 to the log file 1. After that, the process of the log file combination unit 301 proceeds to step S306.
[0040] (Step S306) The log file combining unit 301 combines the processed log file 1 with the log file 2. After that, the process of the log file combining unit 301 proceeds to step S307.
[0041] (Step S307) The log file combination unit 301 stores the combined log file as a combined file in the combined file storage unit 361. After that, the log file combination unit 301 ends the second combination process. If the combined log file is not in a format that can be played back, the log file combination unit 301 converts the combined log file into a format that can be played back, and stores the converted log file in the combined file storage unit 361 as a combined file.
[0042] By the second joining process described above, even if there is a time gap between the logging end time of log file 1 and the logging start time of log file 2, log file 1 and log file 2 can be joined so that each record is chronologically continuous, preventing any inconvenience in analysis (see Figure 9).
[0043] When three or more log files are specified as files to be combined, the log file combination unit 301 combines two log files in sequence based on predetermined conditions using the above-mentioned combining process to ultimately generate one combined file. In this case, for example, the log file combination unit 301 may generate one combined file using a method of sequentially combining log files with earlier logging start times (hereinafter referred to as the "first method"), or may generate one combined file using a method of sequentially combining log files with similar logging start times (hereinafter referred to as the "second method").
[0044] As a specific example, a description will be given of merging when log files 1 to 4 (log files 1 to 4 have the earliest logging start times) are specified as files to be merged. For example, in a first method, the log file merging unit 301 first merges log file 1 with log file 2, then merges the merged log file (log file 1+2) with log file 3, and finally merges the merged log file (log file 1+2+3) with log file 4. In a second method, the log file merging unit 301 merges log file 1 with log file 2, then merges log file 3 with log file 4, and finally merges the file resulting from the merge of log file 1 with log file 2 with the file resulting from the merge of log file 3 with log file 4.
[0045] 3, the simulation execution unit 302 reads the combined file to be simulated (in other words, the target of playback) from the combined file storage unit 361 in response to a user operation, simulates the behavior of the PLC system 2 based on the read combined file, and displays the simulation results on the display 30. Specifically, the simulation execution unit 302 displays a control program (e.g., a ladder diagram) on the display 30, and displays the values of each device as they change over time based on the combined file. This allows the user to accurately grasp the behavior of the PLC system 2 before and after a problem occurs, and efficiently perform work related to analyzing the problem.
[0046] As described above, in the analysis support system 1A according to this embodiment, the analysis support device 3A has the function of combining multiple log files with different logging periods so that each record is chronologically continuous. Therefore, when a problem occurs, there is no need to switch back and forth between multiple log files; instead, the user can simply refer to the combined log file. This simplifies the user's analysis of logged PLC control data, improving work efficiency.
[0047] (Variation 1) The merge target specification receiving unit 300 may receive a specification of a log file that has already been merged by the log file merging unit 301 as a file to be merged.
[0048] (Variation 2) In the above embodiment, a log file, which is a data file, was exemplified as log data related to the present disclosure, but a data set storing logged control data may also be an example of log data related to the present disclosure.
[0049] (Variation 3) In the above embodiment, the log file combining unit 301 stores the combined log file in the combined file storage unit 361 included in the analysis support device 3A, but the combined log file may also be stored in a storage device included in an external device connected via the network 4 or another network. In this case, the storage device is an example of the storage device according to the present disclosure.
[0050] (Variation 4) In the above embodiment, in the first combining process, if there are duplicate records between log file 1 and log file 2, the log file combining unit 301 deletes the duplicate records from log file 2, which is the log file with the later logging start time. However, it is also possible to delete the duplicate records from log file 1 instead of log file 2, and combine the processed log files 1 and 2.
[0051] (Variation 5) 10 , the analysis support device 3A may further include a time interval designation receiving unit 303 that receives, from a user, designation of a time interval of records to be extracted, and a record extraction unit 304 that extracts, from the combined file, records corresponding to the time interval accepted by the time interval designation receiving unit 303, generates an extraction file that is a replayable log file storing the extracted records, and saves the extraction file in the combined file storage unit 361. The time interval designation receiving unit 303 is an example of a time interval designation receiving means according to the present disclosure, the record extraction unit 304 is an example of a record extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0052] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0053] (Variation 6) 11 , the analysis support device 3A may further include an extraction type designation receiving unit 305 that receives, from a user, designation of the type of control data to be extracted, and a data extraction unit 306 that extracts the type and a value corresponding to the type received by the extraction type designation receiving unit 305 from each record of the combined file, generates an extraction file that is a reproducible log file in which the extracted values are stored in each record, and stores the extracted file in the combined file storage unit 361. The extraction type designation receiving unit 305 is an example of an extraction type designation receiving means according to the present disclosure, the data extraction unit 306 is an example of a data extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0054] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0055] (Variation 7) A log file for each control program may be stored in the log file storage unit 360. In other words, multiple log files with the same logging period that were generated when multiple CPU units in the PLC system 2 executed different control programs in parallel may be stored.
[0056] (Variation 8) All or part of the functional units of the analysis support device 3A (see FIG. 3) may be realized by dedicated hardware, such as a single circuit, a composite circuit, a programmed processor, an ASIC (Application-Specific Integrated Circuit), an FPGA (Field-Programmable Gate Array), or a combination thereof.
[0057] The technical ideas according to the above-described modifications may be realized independently or in appropriate combination.
[0058] (Embodiment 2) Next, a description will be given of embodiment 2 of the present disclosure. In the following description, components and the like common to embodiment 1 will be given the same reference numerals, and descriptions thereof will be omitted as appropriate.
[0059] 12 is a diagram showing the configuration of an analysis support system 1B according to embodiment 2. The analysis support system 1B is a system that supports a user in analyzing logged control data output by a PLC, and includes a PLC system 2 and an analysis support device 3B.
[0060] <Hardware configuration of analysis support device 3B> The analysis support device 3B is an example of a log data processing device according to the present disclosure, and is an example of a log data processing system according to the present disclosure. The analysis support device 3B is a device that supports a user in analyzing the logged control data. The hardware configuration of the analysis support device 3B is the same as the hardware configuration of the analysis support device 3A of the first embodiment (see FIG. 2).
[0061] The analysis support device 3A in the first embodiment had the function of combining multiple log files with different logging periods that were generated when one CPU unit in the PLC system 2 executed one control program so that each record was chronologically continuous. In addition to this function, the analysis support device 3B has the function of combining multiple log files with the same logging period that were generated when multiple CPU units in the PLC system 2 executed different control programs in parallel. Generally, when control programs are different, at least some of the devices used by each control program will be different between the multiple control programs. Therefore, multiple log files with the same logging period contain data from different devices.
[0062] <Functional configuration of analysis support device 3B> 13, the analysis support device 3B has, as its functional configuration, a merge target designation receiving unit 307, a log file merging unit 308, and a simulation execution unit 302. These functional units are realized by the processor 33 of the analysis support device 3B executing an engineering tool stored in the auxiliary storage device 36. The merge target designation receiving unit 307 is an example of a merge target designation receiving means according to the present disclosure. The merge target designation receiving unit 307 receives, from the user, designations of multiple log files as merge target files.
[0063] In this embodiment, a plurality of log files for a predetermined period for each control program are stored in the log file storage unit 360. That is, a plurality of log files for a predetermined period obtained by each of a plurality of CPU units in the PLC system 2 executing a different control program are stored in the log file storage unit 360. Information indicating the logging period (e.g., logging start time and logging end time) and information indicating the corresponding control program are added to each log file as a file name.
[0064] The merge target designation receiving unit 307 displays the file names of the log files stored in the log file storage unit 360, and also displays a merge target designation screen (not shown) for receiving designation of merge target files from the user on the display 30. When the user designates multiple merge target files via the merge target designation screen, the merge target designation receiving unit 307 notifies the log file combining unit 308 of the file names of each merge target file.
[0065] The log file merging unit 308 is an example of a merging means according to the present disclosure. The log file merging unit 308 reads each of the specified files to be merged from the log file storage unit 360 and merges the read files to be merged based on predetermined conditions. In particular, if the multiple files to be merged correspond to the same control program (in other words, if the multiple files to be merged do not contain data for different devices), the log file merging unit 308 merges these log files so that the records are chronologically continuous, using a method similar to that used by the log file merging unit 301 of the first embodiment (see FIGS. 5, 6, and 8).
[0066] On the other hand, if multiple files to be merged do not correspond to the same control program, i.e., if each of the multiple files to be merged corresponds to a different control program (in other words, if data for different devices is included between the multiple files to be merged), the log file merger 308 merges these files to be merged by integrating records stored at the same time in each file to be merged (i.e., records with the same logging time) so that there is no device overlap.
[0067] Specifically, the log file combining unit 308 combines these files to be combined by sequentially integrating the data of each record from the first record of these files to be combined so that devices do not overlap.
[0068] For example, if the records of log file 1, which is a file to be merged, store devices A1, B1, C1, D1, E1, and F1 in association with the values of each device, and the records of log file 2, which is a file to be merged, store devices a1, B1, c1, d1, E1, and f1 in association with the values of each device, and log file 1 and log file 2 are merged, the records in the merged file, which is the log file after the merge, will have the configuration shown in FIG. 14. The log file merger 308 stores the merged file thus merged in the merged file storage unit 361. Even when three or more log files corresponding to different control programs are specified as files to be merged, the log file merger 308 merges these files to be merged using the same procedure.
[0069] As described above, in the analysis support system 1B of this embodiment, the analysis support device 3B has the same functions as the analysis support device 3A of the first embodiment. In addition, the analysis support device 3B combines multiple log files corresponding to different control programs by integrating records with the same logging time so that the devices do not overlap. This eliminates the need to switch between multiple log files during analysis when a problem occurs; users can simply refer to the combined log file. This simplifies the analysis of logged PLC control data, improving work efficiency. Furthermore, because analysis can be performed using multiple log files corresponding to different control programs (i.e., analysis can be performed using values from more devices), a wider range of problem analysis is possible.
[0070] (Variation 1) The merge target specification receiving unit 307 may receive a specification of a log file that has already been merged by the log file merging unit 308 as a file to be merged.
[0071] (Variation 2) In the above embodiment, a log file, which is a data file, was exemplified as log data related to the present disclosure, but a data set storing logged control data may also be an example of log data related to the present disclosure.
[0072] (Variation 3) In the above embodiment, the log file combining unit 308 stores the combined log file in the combined file storage unit 361 included in the analysis support device 3B, but the combined log file may also be stored in a storage device included in an external device connected via the network 4 or another network. In this case, the storage device is an example of the storage device according to the present disclosure.
[0073] (Variation 4) The merge target specification receiving unit 307 may receive from the user a specification of a device to be merged. In this case, when merging multiple merge target files corresponding to different control programs, the log file merging unit 308 merges these merge target files by integrating data corresponding to the specified device among records stored at the same time in each merge target file so that there is no duplication. This makes it possible to generate a log file that is narrowed down to only the necessary and sufficient control data, thereby reducing the data size of the merged file.
[0074] (Variation 5) 15 , analysis support device 3B may further include a time interval designation receiving unit 309 that receives, from a user, designation of a time interval of records to be extracted, and a record extraction unit 310 that extracts, from the combined file, records corresponding to the time interval accepted by time interval designation receiving unit 309, generates an extraction file that is a replayable log file storing the extracted records, and saves the extraction file in combined file storage unit 361. Time interval designation receiving unit 309 is an example of a time interval designation accepting means according to the present disclosure, record extraction unit 310 is an example of a record extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0075] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0076] (Variation 6) 16, the analysis support device 3B may further include an extraction type designation receiving unit 311 that receives, from a user, designation of the type of control data to be extracted, and a data extraction unit 312 that extracts the type and a value corresponding to the type received by the extraction type designation receiving unit 311 from each record of the combined file, generates an extraction file that is a reproducible log file in which the extracted values are stored in each record, and stores the extracted file in the combined file storage unit 361. The extraction type designation receiving unit 311 is an example of an extraction type designation receiving means according to the present disclosure, the data extraction unit 312 is an example of a data extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0077] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0078] (Variation 7) All or part of the functional units of the analysis support device 3B (see FIG. 13) may be realized by dedicated hardware, such as a single circuit, a composite circuit, a programmed processor, an ASIC, an FPGA, or a combination thereof.
[0079] The technical ideas according to the above-described modifications may be realized independently or in appropriate combination.
[0080] (Embodiment 3) Next, a description will be given of embodiment 3 of the present disclosure. In the following description, components and the like common to embodiment 1 will be given the same reference numerals, and descriptions thereof will be omitted as appropriate.
[0081] 17 is a diagram showing the configuration of an analysis support system 1C according to embodiment 3. The analysis support system 1C is a system that supports a user in analyzing logged control data output by a PLC, and includes a PLC system 2 and an analysis support device 3C.
[0082] <Hardware configuration of analysis support device 3C> The analysis support device 3C is an example of a log data processing device according to the present disclosure, and is also an example of a log data processing system according to the present disclosure. The analysis support device 3C is a device that supports a user in analyzing the logged control data. The hardware configuration of the analysis support device 3C is the same as the hardware configuration of the analysis support device 3A of the first embodiment (see FIG. 2).
[0083] The analysis support device 3A in the first embodiment has a function of combining multiple log files with different logging periods that were generated when one CPU unit in the PLC system 2 executed one control program so that each record was continuous in time. Instead of this function, the analysis support device 3C has a function of combining a log file corresponding to dynamic data and a log file corresponding to static data that were generated when one CPU unit in the PLC system 2 executed one control program.
[0084] <Functional configuration of analysis support device 3C> As shown in FIG. 18 , the analysis support device 3C has, as its functional configuration, a merge target designation receiving unit 313, a log file merging unit 314, and a simulation execution unit 302. These functional units are realized by the processor 33 of the analysis support device 3C executing an engineering tool stored in the auxiliary storage device 36. The merge target designation receiving unit 313 is an example of a merge target designation receiving means according to the present disclosure. The merge target designation receiving unit 313 receives, from the user, a designation of a log file corresponding to dynamic data as a first merge target file. The first merge target file is an example of first merge target data according to the present disclosure.
[0085] In this embodiment, the log file storage unit 360 stores a plurality of log files corresponding to dynamic data, each with a different logging period, and one log file corresponding to static data. The log file corresponding to dynamic data is a file that stores only records indicating dynamic data, which is control data that changes dynamically during control, and the log file corresponding to static data is a file that stores only records indicating static data, which is data that does not change dynamically during control (e.g., parameter data, recipe data, etc.). In this embodiment, in order to reduce the data size of the log files, the PLC system 2 logs dynamic data at every logging cycle during operation, but logs static data only once at any timing during operation.
[0086] The merge target designation receiving unit 313 displays the file names of the log files corresponding to the dynamic data stored in the log file storage unit 360, and also displays a merge target designation screen (not shown) for receiving designation of a first merge target file from the user on the display 30. When the user designates the first merge target file via the merge target designation screen, the merge target designation receiving unit 313 notifies the log file combining unit 314 of the file name of the first merge target file.
[0087] The log file merging unit 314 is an example of a merging means according to the present disclosure. The log file merging unit 314 reads a specified first file to be merged from the log file storage unit 360, and also reads a second file to be merged, which is a log file corresponding to static data, from the log file storage unit 360. The second file to be merged is an example of second data to be merged according to the present disclosure. The log file merging unit 314 then executes a process to merge the read first file to be merged and the second file to be merged. The merging process executed by the log file merging unit 314 will be described in detail below, assuming that the first file to be merged is log file 1 and the second file to be merged is log file 2.
[0088] First, the log file merging unit 314 expands log file 2 so that its logging period is the same as that of log file 1. As described above, static data is logged only once, so only one record is stored in log file 2. Therefore, the log file merging unit 314 expands log file 2 by increasing the number of records in log file 2 to the number of records equivalent to the logging period of log file 1. The data stored in each record at this time is the same as the data stored in the original record.
[0089] The log file combining unit 314 then combines log file 1 and log file 2 by integrating the data of both records, starting from the first record of both log file 1 and expanded log file 2. The log file combining unit 314 stores the combined file in this manner as a combined file in the combined file storage unit 361. Figure 19 is a diagram schematically illustrating the combining performed by the log file combining unit 314.
[0090] As described above, in the analysis support system 1C of this embodiment, the analysis support device 3C combines a log file containing multiple records corresponding to dynamic data with a log file containing one record corresponding to static data without causing any analytical problems. Therefore, when a problem occurs, there is no need to switch back and forth between the log file corresponding to dynamic data and the log file corresponding to static data. Instead, the user can simply refer to the combined log file. This simplifies the user's analysis of logged PLC control data, improving work efficiency.
[0091] Furthermore, in the PLC system 2, it is not necessary to log static data every cycle, which can avoid memory pressure. This allows resources such as memory capacity to be concentrated on logging dynamic data, which can increase the size of dynamic data that can be logged (in other words, increase the number of devices that are the target of logging) and lengthen the logging period.
[0092] (Variation 1) The merge target specification receiving unit 313 may receive, as the first merge target file, a specification of a log file in which a plurality of log files with different logging periods are merged using the same method as in the first embodiment.
[0093] (Variation 2) In the above embodiment, a log file, which is a data file, was exemplified as log data related to the present disclosure, but a data set storing logged control data may also be an example of log data related to the present disclosure.
[0094] (Variation 3) In the above embodiment, the log file combining unit 314 stores the combined log file in the combined file storage unit 361 included in the analysis support device 3C, but the combined log file may also be stored in a storage device included in an external device connected via the network 4 or another network. In this case, the storage device is an example of the storage device according to the present disclosure.
[0095] (Variation 4) Static data that may be updated may be stored in each record of the first file to be merged (hereinafter referred to as log file 1). In this case, the log file merger 314 removes the static data (i.e., data related to the device corresponding to the static data) from the original record in the second file to be merged (hereinafter referred to as log file 2), and then expands log file 2 by increasing the number of records with the same content as the original record up to the number equivalent to the logging period of log file 1. Then, the log file merger 314 merges log file 1 and log file 2 by integrating the data of both records, starting from the first record of both log file 1 and expanded log file 2.
[0096] For example, in the case where devices A1, B1, C1, D1, E1, and b1 and the values of each device are associated and stored in each record of log file 1, which is the first file to be merged, and devices a1, b1, and c1 are associated and stored in each record of log file 2, which is the second file to be merged, and devices A1, B1, C1, D1, and E1 correspond to dynamic data and devices a1, b1, and c1 correspond to static data, when log file 1 and log file 2 are merged, each record in the merged file will have the configuration shown in Figure 20.
[0097] By doing this, even if specific static data is updated by data access from an external device while the PLC system 2 is running, the log file corresponding to the dynamic data and the log file corresponding to the static data can be combined without causing any analytical problems.
[0098] (Variation 5) The merge target specification receiving unit 313 may receive from the user the specification of devices to be merged. In this case, the log file merging unit 314 removes data corresponding to devices other than the specified device from the original records in the second file to be merged (hereinafter referred to as log file 2), and then expands log file 1 by increasing the number of records with the same content as the removed data up to the logging period of the first file to be merged (hereinafter referred to as log file 1). Then, the log file merging unit 314 merges log file 1 and log file 2 by sequentially integrating the data of both records, starting from the first record of log file 1 and expanded log file 2. In this case, the log file merging unit 314 only integrates data corresponding to the specified device in the records of log file 1.
[0099] This allows a log file to be generated that is narrowed down to the necessary and sufficient control data, and the data size of the combined file can be further reduced.
[0100] (Variation 6) 21 , the analysis support device 3C may further include a time interval designation receiving unit 315 that receives, from a user, designation of a time interval of records to be extracted, and a record extraction unit 316 that extracts, from the combined file, records corresponding to the time interval accepted by the time interval designation receiving unit 315, generates an extraction file that is a replayable log file storing the extracted records, and saves the extraction file in the combined file storage unit 361. The time interval designation receiving unit 315 is an example of a time interval designation receiving means according to the present disclosure, the record extraction unit 316 is an example of a record extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0101] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0102] (Variation 7) 22 , the analysis support device 3C may further include an extraction type designation receiving unit 317 that receives, from a user, designation of the type of control data to be extracted, and a data extraction unit 318 that extracts the type and a value corresponding to the type received by the extraction type designation receiving unit 317 from each record of the combined file, generates an extraction file that is a reproducible log file in which the extracted values are stored in each record, and stores the extracted file in the combined file storage unit 361. The extraction type designation receiving unit 317 is an example of an extraction type designation receiving means according to the present disclosure, the data extraction unit 318 is an example of a data extraction means according to the present disclosure, and the extraction file is an example of extracted data according to the present disclosure.
[0103] This allows the creation of a log file that contains only the necessary and sufficient control data, making the data size smaller than the original combined file. As a result, for example, it becomes easier to send the log file and improves the efficiency of control data analysis work.
[0104] (Variation 8) All or part of the functional units of the analysis support device 3C (see FIG. 18) may be realized by dedicated hardware, such as a single circuit, a composite circuit, a programmed processor, an ASIC, an FPGA, or a combination thereof.
[0105] The technical ideas according to the above-described modifications may be realized independently or in appropriate combination.
[0106] The present disclosure allows various embodiments and modifications without departing from the broad spirit and scope. Furthermore, the above-described embodiments are intended to explain the present disclosure and do not limit the scope of the present disclosure. In other words, the scope of the present disclosure is defined by the claims, not the embodiments. Various modifications made within the scope of the claims and within the meaning of the disclosure equivalent thereto are considered to be within the scope of the present disclosure. [Industrial Applicability]
[0107] The present disclosure can be suitably employed in analyzing logged control data. [Explanation of symbols]
[0108] 1A, 1B, 1C analysis support system, 2 PLC system, 3A, 3B, 3C analysis support device, 4 network, 30 display, 31 operation reception unit, 32 communication unit, 33 processor, 34 ROM, 35 RAM, 36 auxiliary storage device, 37 bus, 300, 307, 313 join target specification reception unit, 301, 308, 314 log file combination unit, 302 simulation execution unit, 303, 309, 315 time interval specification reception unit, 304, 310, 316 record extraction unit, 305, 311, 317 extraction type specification reception unit, 306, 312, 318 data extraction unit, 360 log file storage unit, 361 combined file storage unit
Claims
1. a join target specification receiving means for receiving, as join target data, a plurality of specifications of log data which is time-series data in which a plurality of records indicating control data of a PLC (Programmable Logic Controller) at a certain time are stored; a combining unit that combines the plurality of join target data accepted by the join target specification accepting unit so that the records are temporally continuous, and stores the combined data in a storage device; When the logging start time, which is the logging time of the first record of one of the two pieces of data to be joined, is later than the logging end time, which is the logging time of the last record of the other piece of data to be joined, the joining means adds to one of the pieces of data to be joined a number of empty records equivalent to a value obtained by subtracting 1 from a value obtained by dividing a difference between the logging start time and the logging end time by a logging period, and then joins the two pieces of data to be joined. Log data processing device.
2. A join target designation receiving means for receiving, as join target data, a plurality of designations of log data which is time series data in which a plurality of records indicating control data of a PLC at a certain time are stored; a combining unit that combines the plurality of join target data accepted by the join target specification accepting unit so that the records are temporally continuous, and stores the combined data in a storage device; the record includes a type and a value of the control data; when the plurality of pieces of data to be joined include different types, the joining means joins the plurality of pieces of data to be joined by integrating records having the same logging time so that the types do not overlap; Log data processing device.
3. A join target designation receiving means for receiving, as join target data, a plurality of designations of log data, which is time series data in which a plurality of records indicating control data of a PLC at a certain time are stored; a combining unit that combines the plurality of join target data accepted by the join target specification accepting unit so that the records are temporally continuous, and stores the combined data in a storage device; a time interval specification receiving means for receiving a specification of a time interval of the record to be extracted; a record extraction means for extracting, from the combined data, a record corresponding to the time interval accepted by the time interval designation accepting means, and storing the extracted record in the storage device as extracted data, Log data processing device.
4. A join target designation receiving means for receiving, as join target data, a plurality of designations of log data, which is time series data in which a plurality of records indicating control data of a PLC at a certain time are stored; a combining unit that combines the plurality of join target data accepted by the join target specification accepting unit so that the records are temporally continuous, and stores the combined data in a storage device; the record includes a type and a value of the control data; extraction type designation receiving means for receiving designation of the type to be extracted; a data extraction unit that extracts the type and a value corresponding to the type accepted by the extraction type designation acceptance unit from each record of the combined data, and stores the extracted data in the storage device, the extracted value being stored in each record. Log data processing device.
5. a join target designation receiving means for receiving, as the first join target data, designation of log data which is time-series data storing a plurality of records indicating periodically logged dynamic data among the control data of the PLC; a combining unit that combines the first data to be combined received by the combining target designation receiving unit with second data to be combined, which is log data that stores a record indicating static data that has been logged only once among the control data, and stores the combined data in a storage device; Log data processing device.
6. the combining means expands the second data to be combined by increasing the number of records indicating the static data for the second data to be combined to a number equivalent to the logging period of the first data to be combined, and combines the first data to be combined and the second data to be combined by integrating data of the records of the first data to be combined and the expanded second data to be combined; The log data processing device according to claim 5.
7. a time interval specification receiving means for receiving a specification of a time interval of the record to be extracted; a record extraction unit that extracts, from the combined data, a record corresponding to the time interval accepted by the time interval designation accepting unit, and stores the extracted record in the storage device as extracted data, 7. The log data processing device according to claim 5 or 6.
8. the record includes a type and a value of the control data; extraction type designation receiving means for receiving designation of the type to be extracted; a data extraction unit that extracts the type and a value corresponding to the type accepted by the extraction type designation acceptance unit from each record of the combined data, and stores the extracted data in the storage device, the extracted value being stored in each record.
7. The log data processing device according to claim 5 or 6.
9. a join target designation receiving means for receiving, as the join target data, a plurality of designations of log data which are time series data in which a plurality of records indicating control data of the PLC at a certain time are stored; a combining unit that combines the plurality of join target data accepted by the join target specification accepting unit so that the records are temporally continuous, and stores the combined data in a storage device; the record includes a type and a value of the control data; when the plurality of pieces of data to be joined include different types, the joining means joins the plurality of pieces of data to be joined by integrating records having the same logging time so that the types do not overlap; Log data processing system.
10. a join target designation receiving means for receiving, as the first join target data, designation of log data which is time-series data storing a plurality of records indicating periodically logged dynamic data among the control data of the PLC; a combining unit that combines the first data to be combined received by the combining target designation receiving unit with second data to be combined, which is log data that stores a record indicating static data that has been logged only once among the control data, and stores the combined data in a storage device; Log data processing system.
11. The combining target designation receiving means receives, as the combining target data, a plurality of designations of log data which are time-series data in which a plurality of records indicating control data of the PLC at a certain time are stored; A log data processing method, wherein a combining unit combines the plurality of pieces of combine target data accepted by the combine target designation accepting unit so that the records are temporally continuous, and stores the combined data in a storage device, the record includes a type and a value of the control data; when the plurality of pieces of data to be joined include different types, the joining means joins the plurality of pieces of data to be joined by integrating records having the same logging time so that the types do not overlap; Log data processing method.
12. The combining target designation receiving means receives, as the first combining target data, designation of log data which is time-series data storing a plurality of records indicating dynamic data periodically logged among the control data of the PLC; a combining means combining the first data to be combined received by the combining target designation receiving means with second data to be combined, which is log data storing a record indicating static data that has been logged only once among the control data, and storing the combined data in a storage device; Log data processing method.
13. Computer, a join target designation receiving means for receiving, as join target data, a plurality of designations of log data which are time series data in which a plurality of records indicating control data of the PLC at a certain time are stored; a combining unit that combines the plurality of join target data received by the join target designation receiving unit so that the records are temporally continuous, and stores the combined data in a storage device; the record includes a type and a value of the control data; when the plurality of pieces of data to be joined include different types, the joining means joins the plurality of pieces of data to be joined by integrating records having the same logging time so that the types do not overlap; program.
14. Computer, a join target designation receiving means for receiving, as the first join target data, designation of log data which is time-series data storing a plurality of records indicating periodically logged dynamic data among the control data of the PLC; a combining unit that combines the first combined data accepted by the combined data acceptance unit with the second combined data, which is log data that stores a record indicating static data that has been logged only once among the control data, and stores the combined data in a storage device; program.
Citation Information
Patent Citations
Time series data display device
JP2013065167A
Radiographic apparatus, imaging control method, radiographic system, and control method therefor
JP2019130183A
Programmable logic controller, support device, and logging method
JP7548464B1