WO2022168475A1 - Dispositif de commande - Google Patents

Dispositif de commande Download PDF

Info

Publication number
WO2022168475A1
WO2022168475A1 PCT/JP2021/047276 JP2021047276W WO2022168475A1 WO 2022168475 A1 WO2022168475 A1 WO 2022168475A1 JP 2021047276 W JP2021047276 W JP 2021047276W WO 2022168475 A1 WO2022168475 A1 WO 2022168475A1
Authority
WO
WIPO (PCT)
Prior art keywords
unit
value
difference
counter
synchronization signal
Prior art date
Application number
PCT/JP2021/047276
Other languages
English (en)
Japanese (ja)
Inventor
好博 中谷
Original Assignee
オムロン株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from JP2021154989A external-priority patent/JP2022119703A/ja
Application filed by オムロン株式会社 filed Critical オムロン株式会社
Publication of WO2022168475A1 publication Critical patent/WO2022168475A1/fr

Links

Images

Classifications

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

Definitions

  • the present disclosure relates to a control device.
  • a PLC generally includes a basic unit (CPU (Central Processing Unit) unit) and an expansion unit.
  • CPU Central Processing Unit
  • a counter (timer) of the CPU unit and a counter of the expansion unit are synchronized so that there is no time lag between the data acquired from the CPU unit and the data acquired from the expansion unit.
  • Patent Document 1 discloses a technique for synchronizing the time of the CPU unit timer and the time of the expansion unit timer. Specifically, a synchronization signal is transmitted from the CPU unit to the expansion unit. The expansion unit synchronizes the time of the expansion unit timer with the time of the CPU unit timer according to the synchronization signal.
  • the CPU of the CPU unit executes the process of transmitting the synchronization signal by executing firmware. Therefore, the CPU unit timer and the expansion unit timer cannot be synchronized until after the firmware has started. Therefore, the CPU unit timer and the expansion unit timer are out of sync before the firmware starts. As a result, if a problem occurs before the firmware is started, it becomes difficult to arrange the order of occurrence of events among a plurality of units, and it takes time to investigate the cause of the problem.
  • the present disclosure has been made in view of the above problems, and its purpose is to provide a control device that can shorten the time required to investigate the cause of a problem that occurred before starting the firmware.
  • the control device includes a first unit and a second unit that exchange data.
  • the first unit includes a first hardware circuit.
  • a second unit includes a second hardware circuit.
  • a first hardware circuit includes a first counter, a signal output section for outputting a synchronization signal to the second unit, and a first value of the first counter when the synchronization signal is output to a second unit. and a time information output unit for outputting to the unit.
  • the second hardware circuit includes: a second counter; a difference calculator that calculates a first difference between a second value and a first value of the second counter when receiving the synchronization signal; and a correction unit that corrects the second counter based on the difference of 1.
  • synchronization processing between the first counter and the second counter is performed by the first hardware circuit of the first unit and the second hardware circuit of the second unit. Therefore, immediately after the control device is powered on, synchronization processing between the first counter and the second counter is started. Therefore, the first and second counters are synchronized before the firmware is activated. Therefore, even before the firmware is activated, it becomes easy to arrange the order of occurrence of events in the first unit and the second unit. As a result, it is possible to shorten the time required to investigate the cause of a problem that occurred before the firmware was started.
  • the first hardware circuit further comprises a third counter.
  • the second hardware circuit further has a fourth counter.
  • the signal output section repeatedly outputs the synchronization signal.
  • the time information output unit further outputs a second difference between the value of the third counter when the previous synchronization signal was output and the value of the third counter when the current synchronization signal was output as a second difference.
  • the difference calculation unit further calculates a third difference between the value of the fourth counter when receiving the previous synchronization signal and the value of the fourth counter when receiving the synchronization signal this time. Compute a fourth difference between the difference of and the third difference.
  • the correction unit corrects the second counter based on the fourth difference.
  • the fourth difference is the count number of the third counter and the count number of the fourth counter in the target period from the output of the previous synchronization signal to the output of the current synchronization signal. Show the difference with the number. Since the first counter and the third counter are included in the same hardware circuit, they count up in the same period according to the clock from the same clock oscillation source. Similarly, since the second counter and the fourth counter are included in the same hardware circuit, they count up in the same cycle according to the clock from the same clock oscillation source. Therefore, the difference between the count number of the first counter and the count number of the second counter in the target period is also the fourth difference.
  • the correction unit corrects the second counter based on the fourth difference, thereby correcting the difference between the values of the first counter and the second counter caused by the oscillation error of the clock source.
  • the signal output unit may output the synchronization signal each time the value of the first counter increases by a constant value.
  • the time information output section also outputs a constant value to the second unit.
  • the second hardware circuit measures a second difference between the value of the second counter when the previous synchronization signal was output and the value of the second counter when the current synchronization signal was output. It further has a measurement part.
  • the difference calculator further calculates a third difference between the second difference and the constant value.
  • the correction unit corrects the second counter based on the third difference.
  • the third difference is the difference between the count number of the first counter and the count number of the second counter in the target period in which the value of the first counter increases by a constant value.
  • the correction unit corrects the second counter based on the third difference, thereby correcting the difference between the values of the first counter and the second counter caused by the oscillation error of the clock source.
  • the scale of the first and second hardware circuits can be reduced as compared with the form having the third and fourth counters.
  • the first unit further includes a first light emitting element that blinks according to the value of the first counter.
  • the second unit further comprises a second light emitting element that blinks according to the value of the second counter.
  • the blinking cycles of the first light emitting element and the second light emitting element are synchronized, and a sense of unity can be given to the user. Conversely, the user can recognize that some kind of abnormality has occurred by visually confirming that the blinking cycles of the first light emitting element and the second light emitting element are not synchronized.
  • the first unit further comprises a processor executing firmware.
  • the firmware includes instructions for setting the timing of outputting the synchronization signal to the signal output section.
  • the signal output unit outputs a synchronization signal when the value of the first counter reaches the timing.
  • the firmware further includes instructions to calculate a fifth difference between the second value and the timing, and instructions to correct the second counter based on the fifth difference.
  • the processor disables the operation of the time information output section after starting the firmware.
  • the processor can synchronize the first counter and the second counter according to the firmware.
  • the first hardware circuit is an ASIC or FPGA.
  • the second hardware circuit is an ASIC or FPGA.
  • FIG. 3 is a schematic diagram showing a configuration example of a unit of the control device according to the embodiment;
  • FIG. It is a figure which shows the signal waveform using UART.
  • FIG. 4 is a diagram showing a signal waveform corresponding to time information (value X1);
  • FIG. 4 is a diagram showing the flow of data accompanying the waveform of a synchronizing signal;
  • FIG. 5 is a diagram schematically showing the configuration of a control device according to modification 1;
  • FIG. 11 is a diagram schematically showing the configuration of a control device according to modification 2;
  • FIG. 13 is a diagram schematically showing the configuration of a control device 1C according to Modification 3;
  • FIG. 10 is a diagram showing a data flow accompanying a waveform of a synchronization signal in Modification 3;
  • FIG. 10 is a diagram showing a signal distribution method when there are a plurality of extension units;
  • FIG. 1 is a diagram schematically showing an example of the configuration of a control device 1 according to this embodiment.
  • the control device 1 corresponds to a PLC, for example.
  • a PLC will be described as a specific example as a typical example of the "control device", but the technical idea disclosed in this specification is not limited to the PLC, and can be applied to any control device. Applicable.
  • control device 1 includes a CPU unit 100 and an expansion unit 200 that exchange data.
  • control device 1 includes one expansion unit 200 in FIG. 1 , it may be provided with a plurality of expansion units 200 .
  • CPU unit 100 is connected to expansion unit 200 via data bus 2 and signal lines 3 and 4 .
  • the CPU unit 100 has a program execution section that executes a program created according to the object to be controlled. More specifically, the CPU unit 100 corresponds to an arithmetic processing section that executes system programs and various user programs.
  • the extension unit 200 can be detachably externally attached to the CPU unit 100 in order to extend the functions of the control device 1 .
  • the expansion unit 200 is arranged to mediate between the network and the control device 1, for example performing communication processing or information processing.
  • the CPU unit 100 includes a CPU 10, a memory 11, a storage 12, and a hardware circuit 13.
  • Expansion unit 200 includes CPU 20 , memory 21 , storage 22 and hardware circuit 23 .
  • the CPU 10 reads the firmware and various user programs stored in the storage 12, develops them in the memory 11, and executes them.
  • the CPU 20 reads various programs stored in the storage 22, develops them in the memory 21, and executes them.
  • the hardware circuit 13 and the hardware circuit 23 are, for example, FPGA (Field-Programmable Gate Array) or ASIC (Application Specific Integrated Circuit).
  • the hardware circuit 13 has a free-running counter (hereinafter referred to as "FRC") 131, a synchronization signal output section 132, and a latch section 133.
  • FRC free-running counter
  • the FRC 131 is a counter that counts up at regular intervals.
  • FRC 131 is, for example, a 64-bit counter.
  • Various counters may be employed instead of the FRC 131 .
  • the synchronization signal output section 132 uses the signal line 3 to output the synchronization signal to the expansion unit 200 at arbitrary timing.
  • the synchronization signal output unit 132 arbitrarily generates the output timing of the synchronization signal.
  • the synchronization signal output unit 132 may set the timing at which the value of the FRC 131 reaches the set value as the timing for outputting the synchronization signal.
  • the synchronization signal output from the synchronization signal output section 132 is also input to the latch section 133 .
  • the latch section 133 latches the value X1 of the FRC 131 when the synchronization signal is output. Furthermore, the latch section 133 outputs the held value X1 to the expansion unit 200 using the signal line 4 .
  • the value X1 latched by the latch section 133 is time information indicating the time when the synchronization signal was output.
  • the hardware circuit 23 has an FRC 231 , a latch section 232 , a difference calculation section 233 and an FRC correction section 234 .
  • the FRC 231 is a counter that counts up at regular intervals.
  • FRC 231 is, for example, a 64-bit counter.
  • Various counters may be employed instead of the FRC 231 .
  • the latch section 232 latches the value X2 of the FRC 231 when receiving the synchronization signal from the signal line 3 .
  • the latch section 232 outputs the held value X2 to the difference calculation section 233 .
  • the difference calculator 233 outputs the difference Y1 to the FRC corrector 234 .
  • the FRC correction unit 234 corrects the FRC 231 based on the difference Y1. That is, the FRC correction unit 234 corrects the value of the FRC231 by the difference Y1 so that the FRC131 and the FRC231 are synchronized.
  • the synchronous signal output section 132 of the CPU unit 100 outputs the synchronous signal to the extension unit 200 .
  • the synchronization signal is also output to the latch section 133 (see (1) in the figure).
  • the latch section 133 of the CPU unit 100 latches the value X1 of the FRC 131 when the synchronization signal was output according to the input of the synchronization signal (see (2) in the figure).
  • the latch section 232 of the extension unit 200 latches the value X2 of the FRC 231 when receiving the synchronization signal in response to the input of the synchronization signal (see (3) in the figure).
  • the latch unit 133 outputs the held value X1 (time information indicating the timing at which the synchronization signal was output) to the extension unit 200 (see (4) in the figure). That is, the latch section 133 outputs to the extension unit 200 the value X1 of the FRC 131 when the synchronization signal is output.
  • the latch unit 232 outputs the held value X2 to the difference calculation unit 233 (see (5) in the figure).
  • the difference calculation section 233 calculates the difference Y1 between the value X2 held by the latch section 232 and the value X1 received from the CPU unit 100 (see (6) in the drawing).
  • the difference calculator 233 outputs the calculated difference Y1 to the FRC corrector 234 (see (7) in the figure).
  • the FRC correction unit 234 corrects the FRC 231 based on the difference Y1 (see (8) in the figure). Thereby, FRC231 and FRC131 are synchronized. The processes (1) to (8) are repeatedly executed.
  • the synchronization processing between the FRC231 and the FRC131 is executed by the hardware circuit 13 of the CPU unit 100 and the hardware circuit 23 of the expansion unit 200. Therefore, synchronization processing between the FRC231 and the FRC131 is started immediately after the control device 1 is powered on. Therefore, the FRC231 and the FRC131 are synchronized before the firmware stored in the storage 12 is activated.
  • FIG. 2 is a diagram schematically showing the configuration of the control device 1Z according to the reference embodiment.
  • the controller 1Z differs from the controller 1 shown in FIG. 1 in that it includes a CPU unit 100Z and an expansion unit 200Z instead of the CPU unit 100 and the expansion unit 200. .
  • the CPU unit 100Z differs from the CPU unit 100 in that it includes a hardware circuit 13Z instead of the hardware circuit 13.
  • the hardware circuit 13Z differs from the hardware circuit 13 in that it does not have the latch section 133.
  • the extension unit 200Z differs from the extension unit 200 in that it includes a hardware circuit 23Z instead of the hardware circuit 23.
  • the hardware circuit 23Z is different from the hardware circuit 23 in that it does not have the difference calculator 233 .
  • the hardware circuits 13Z and 23Z do not include the latch section 133 and the difference calculation section 233, so the FRC 231 and the FRC 131 are not synchronized with the hardware circuits 13Z and 23Z alone. Therefore, the firmware stored in the storage 12 is used to synchronize the FRC231 and the FRC131.
  • the firmware includes an instruction to set the timing X1 for outputting the synchronization signal to the synchronization signal output section 132 of the hardware circuit 13Z and an instruction to read the value X1 held in the latch section 232. Further, the firmware includes an instruction to calculate the difference Y1 between the value X2 and the timing X1, and an instruction to cause the FRC corrector 234 to correct the FRC 231 based on the difference Y1.
  • the CPU 10 executes synchronization processing as follows according to firmware including such instructions.
  • the CPU 10 of the CPU unit 100Z sets the synchronization signal output timing X1 in the synchronization signal output section 132 (see (11) in the figure).
  • the synchronization signal output section 132 outputs the synchronization signal to the expansion unit 200Z (see (12) in the figure).
  • the latch section 232 of the expansion unit 200Z latches the value X2 of the FRC 231 when receiving the synchronization signal in response to the input of the synchronization signal (see (13) in the figure).
  • the CPU 10 reads out the value X2 held in the latch section 232 via the data bus 2 (see (14) in the figure).
  • the FRC correction unit 234 corrects the FRC 231 based on the difference Y1 (see (16) in the figure). Thereby, FRC231 and FRC131 are synchronized. The processes (11) to (16) are repeatedly executed.
  • the CPU 10 performs the processes (11), (14) and (15) in the figure by executing the firmware. That is, after the firmware is activated, the synchronization processing between the FRC231 and the FRC131 is started. Therefore, the FRC131 and the FRC231 are not synchronized from when the control device 1Z is powered on until the firmware is activated. As a result, if a problem occurs during this period, it becomes difficult to arrange the order of occurrence of events in the CPU unit 100Z and the expansion unit 200Z, and it takes time to investigate the cause of the problem.
  • the FRC231 and the FRC131 are synchronized before the firmware is activated. Therefore, it becomes easy to arrange the order of occurrence of events in the CPU unit 100 and the expansion unit 200 even after the power is turned on until the firmware is activated. As a result, it is possible to shorten the time required to investigate the cause of a problem that occurred before the firmware was started.
  • FIG. 3 is a schematic diagram showing a configuration example of units of the control device 1 according to the present embodiment.
  • the control device 1 includes a CPU unit 100 , one or more expansion units 200 and one or more functional units 300 .
  • CPU unit 100 is connected to one or more expansion units 200 via data bus 2 and signal lines 3 and 4 .
  • the CPU unit 100 also connects with one or more functional units 300 via the data bus 5 .
  • the functional unit 300 has the function of a so-called I/O unit that exchanges signals between equipment and devices to be controlled and various devices (sensors, actuators, etc.) arranged therein.
  • the data bus 2 is, but not limited to, an I/O serial interface bus conforming to PCIe (PCI Express), for example.
  • the signal line 3 is an optical fiber cable or an electrical signal cable and transmits a synchronous signal.
  • Signal line 3 is connected between signal port 110 P of CPU unit 100 and signal port 210 P of expansion unit 200 .
  • the CPU unit 100 uses the signal line 3 to transmit the synchronization signal to the extension unit 200 .
  • the signal line 4 is an optical fiber cable or an electrical signal cable, and transmits time information (value X1).
  • Signal line 4 is connected between signal port 111P of CPU unit 100 and signal port 211P of expansion unit 200 .
  • the CPU unit 100 uses the signal line 4 to transmit the time information (value X1) to the expansion unit 200 .
  • Hardware circuits 13 and 23 communicate time information (value X1) using, for example, an asynchronous serial communication UART (Universal Asynchronous Receiver Transmitter).
  • UART Universal Asynchronous Receiver Transmitter
  • FIG. 4 is a diagram showing signal waveforms using UART. As shown in FIG. 4, the UART communicates in units of 8-bit data chunks. A Start bit and a Stop bit are respectively communicated before and after the 8-bit data block.
  • FIG. 5 is a diagram showing a signal waveform corresponding to time information (value X1).
  • value X1 of the FRC 131 is represented by 64 bits, eight 8-bit data chunks are transmitted as shown in FIG.
  • FIG. 6 is a diagram showing the flow of data accompanying the waveform of the synchronization signal.
  • the synchronization signal is output at regular intervals.
  • the constant period is, for example, several ms to several tens of ms.
  • the latch section 133 latches the value X1 of the FRC131 and the latch section 232 latches the value X2 of the FRC231.
  • the time information indicating the value X1 held in the latch section 133 is transmitted to the expansion unit 200 using, for example, UART.
  • the value of the FRC 231 is corrected by the FRC corrector 234 using the difference Y1.
  • the FRC correction unit 234 corrects the FRC231 value by subtracting the difference Y1 from the FRC231 value.
  • the FRC correction unit 234 may collectively subtract the difference Y1 from the value of the FRC231. Alternatively, the FRC correction unit 234 may divide the difference Y1 into a plurality of correction units, and subtract the correction units from the value of the FRC 231 multiple times in the correction period. A correction unit and a correction cycle are set in advance. For example, if the difference Y1 is 2 ns, the correction unit is 1 ns, and the correction period is 100 ns, the FRC correction unit 234 subtracts 1 ns from the FRC 231 value at time t1 immediately after the difference Y1 is calculated.
  • the FRC corrector 234 subtracts 1 ns from the value of the FRC 231 at time t1+100 ns.
  • FRC231 and FRC131 are gradually synchronized.
  • extreme changes in the value of FRC231 can be suppressed.
  • the FRC 131 included in the hardware circuit 13 counts up according to a clock generated using a clock oscillation source (not shown) outside the hardware circuit 13 .
  • FRC 231 included in hardware circuit 23 counts up according to a clock generated using a clock oscillation source (not shown) outside hardware circuit 23 . Therefore, due to an oscillation error (also referred to as static jitter) between the clock oscillation source of the CPU unit 100 and the clock oscillation source of the expansion unit 200, the period in which the FRC 131 counts up and the period in which the FRC 231 counts up may differ. There may be slight deviations in between.
  • the control device corrects the difference between the values of FRC131 and FRC231 (hereinafter referred to as "clock deviation") caused by static jitter.
  • FIG. 7 is a diagram schematically showing the configuration of a control device 1A according to Modification 1.
  • the control device 1A includes a CPU unit 100A and an extension unit 200A.
  • the CPU unit 100A differs from the CPU unit 100 shown in FIG. 1 in that it includes a hardware circuit 13A instead of the hardware circuit 13.
  • FIG. Expansion unit 200A is different from expansion unit 200 shown in FIG. 1 in that it includes hardware circuit 23A instead of hardware circuit 23 . Note that the memories 11 and 21 and the storages 12 and 22 are omitted from FIG.
  • the hardware circuit 13A differs from the hardware circuit 13 in that it has a latch section 133A instead of the latch section 133 and further has an FRC 134. Note that the synchronization signal output unit 132 of the hardware circuit 13A repeatedly outputs the synchronization signal.
  • the FRC 134 is a counter that counts up at regular intervals, such as a 64-bit counter. Various counters may be employed instead of the FRC 134 .
  • FRCs 131 and 134 count up according to a clock generated using a clock oscillation source (not shown) provided in CPU unit 100A. Therefore, the FRCs 131 and 134 count up in the same period.
  • the hardware circuit 23A has a latch section 232A, a difference calculation section 233A and an FRC correction section 234A in place of the latch section 232, the difference calculation section 233 and the FRC correction section 234 compared to the hardware circuit 23. It is different in that it has
  • the FRC 235 is a counter that counts up at regular intervals, such as a 64-bit counter. Various counters may be employed instead of the FRC 235 .
  • FRCs 231 and 235 count up according to a clock generated using a clock oscillation source (not shown) provided in expansion unit 200A. Therefore, the FRCs 231 and 235 count up in the same period.
  • the latch section 232A performs the following operations. That is, the latch section 232A latches the value X4 of the FRC 235 when receiving the synchronization signal from the signal line 3.
  • the FRC correction unit 234A performs the following operations in addition to the operations of the FRC correction unit 234. That is, the FRC corrector 234A corrects the FRC 231 based on the difference Y2.
  • the synchronization signal output section 132 of the CPU unit 100A outputs the synchronization signal to the expansion unit 200A.
  • the synchronization signal is also output to the latch section 133A (see (21) in the figure).
  • the latch section 133A of the CPU unit 100A latches the value X3 of the FRC 134 when the synchronization signal was output in response to the synchronization signal input (see (22) in the figure).
  • the latch section 232A of the extension unit 200A latches the value X4 of the FRC 235 when the synchronization signal is received (see (23) in the figure) in response to the synchronization signal input.
  • the latch unit 133A calculates the difference dX3 between the value X3′ of the FRC 134 latched when the synchronization signal was output last time and the value X3 newly latched, and outputs the difference dX3 to the expansion unit 200A ((24 )reference).
  • the latch unit 232A calculates the difference dX4 between the value X4' of the FRC 235 latched when the previous synchronization signal was input and the newly latched value X4, and outputs the difference dX4 to the difference calculation unit 233A (( 25)).
  • the difference calculator 233A calculates the difference Y2 between the difference dX4 and the difference dX3 (see (26) in the figure).
  • the difference calculator 233A outputs the calculated difference Y2 to the FRC corrector 234 (see (27) in the figure).
  • the FRC correction unit 234A corrects the FRC 231 based on the difference Y2 (see (28) in the figure).
  • the difference Y2 indicates the difference between the count number of FRC134 and the count number of FRC235 in the target period from the output of the previous synchronization signal to the output of the current synchronization signal.
  • FRCs 131 and 134 count up in the same period.
  • FRCs 231 and 235 count up in the same cycle. Therefore, the difference between the FRC131 count number and the FRC231 count number in the target period is also the difference Y2.
  • the FRC corrector 234A corrects the value of the FRC 231 by the difference Y2, thereby correcting the clock deviation caused by the static jitter.
  • the FRC231 is once synchronized with the FRC131 according to the synchronization processes (1) to (7) shown in FIG.
  • clock deviation due to static jitter continues to occur. Therefore, the FRC correction unit 234A continues to periodically correct the FRC 231 based on the difference Y2.
  • the FRC corrector 234 corrects the clock deviation at a predetermined correction cycle. Assuming that the target period from the output of the previous synchronization signal to the output of the current synchronization signal is T1, and the correction period is T2, the FRC correction unit 234 performs (Y2/T1) ⁇ T2 for each correction period. FRC231 should be corrected. This always cancels clock deviations due to static jitter.
  • Dynamic jitter includes, for example, transmission delay of synchronization signals. According to Modification 1, the clock deviation caused by static jitter is always cancelled. Therefore, even if the output cycle of the synchronization signal is lengthened, it is possible to avoid excessive deviation between the values of FRC131 and FRC231 due to dynamic jitter. This reduces the load required for the synchronization processing by the CPU 10 when the synchronization processing according to (11) to (16) shown in FIG. 2 is repeatedly executed after the firmware is activated.
  • the CPU 10 may disable only the output operation of the time information by the latch section 133A and enable the output operation of the difference dX3 by the latch section 133A. This allows the hardware circuits 13A and 23A to continue correcting clock deviations caused by static jitter even after the firmware has started.
  • the CPU 10 may disable the operation of outputting the difference dX3 by the latch section 133A after the firmware is activated.
  • the firmware includes an instruction to calculate the difference Y2 between the difference dX3 calculated by the latch section 133A and the difference dX4 calculated by the latch section 232A, and an instruction to correct the FRC 231 based on the difference Y2.
  • the CPU 10 may correct the FRC 231 based on the difference Y2 according to these commands of the firmware. This allows the CPU 10 to continue correcting the clock deviation caused by static jitter after the firmware is started.
  • modification of the firmware is required.
  • the CPU 10 preferably enables the output operation of the difference dX3 by the latch section 133A after the firmware is started.
  • FIG. 8 is a diagram schematically showing the configuration of a control device 1B according to Modification 2.
  • the control device 1B includes a CPU unit 100B and an expansion unit 200B.
  • the CPU unit 100B differs from the CPU unit 100 shown in FIG. 1 in that it includes a hardware circuit 13B instead of the hardware circuit 13.
  • FIG. Expansion unit 200B is different from expansion unit 200 shown in FIG. 1 in that it includes hardware circuit 23B instead of hardware circuit 23 .
  • the memories 11 and 21 and the storages 12 and 22 are omitted from FIG.
  • Modification 2 may be combined with Modification 1.
  • FIG. 1 the control device 1B includes a CPU unit 100B and an expansion unit 200B.
  • the CPU unit 100B differs from the CPU unit 100 shown in FIG. 1 in that it includes a hardware circuit 13B instead of the hardware circuit 13.
  • FIG. Expansion unit 200B is different from expansion unit 200 shown in FIG. 1 in that it includes hardware circuit 23B instead of hardware circuit 23 .
  • the hardware circuit 13B differs from the hardware circuit 13 in that it includes a light emitting element 135.
  • the hardware circuit 23B differs from the hardware circuit 23 in that it includes a light-emitting element 236 .
  • the light emitting elements 135, 236 are, for example, light emitting diodes. Light-emitting elements 135 and 236 blink according to the values of FRC 131 and 231, respectively. Specifically, the light emitting elements 135 and 236 emit light when the FRCs 131 and 231 reach preset values. Before starting the firmware, the FRCs 131 and 231 are synchronized by the processes (1) to (7) shown in FIG. After starting the firmware, the FRCs 131 and 231 are synchronized by the processes (11) to (15) shown in FIG. Therefore, the light emitting elements 135 and 236 emit light at the same timing.
  • the blinking cycles of the light emitting elements of the units are synchronized, and a sense of unity can be given to the user. Conversely, the user can recognize that some kind of abnormality has occurred by visually confirming that the blinking cycles of the light emitting elements of the units are not synchronized.
  • Modification 3 In Modification 1, each of the CPU unit 100A and the expansion unit 200A has two FRCs. Therefore, the scale of the hardware circuit increases. Modification 3 is a mode in which the clock deviation caused by static jitter is continuously corrected while suppressing an increase in the scale of the hardware circuit.
  • FIG. 9 is a diagram schematically showing the configuration of a control device 1C according to Modification 3.
  • the control device 1C includes a CPU unit 100C and an expansion unit 200C.
  • the CPU unit 100C differs from the CPU unit 100A shown in FIG. 7 in that it includes a hardware circuit 13C instead of the hardware circuit 13A.
  • Expansion unit 200C differs from expansion unit 200A shown in FIG. 7 in that it includes hardware circuit 23C instead of hardware circuit 23A. 9, the memories 11 and 21 and the storages 12 and 22 are omitted in the same manner as in FIG.
  • the hardware circuit 13C differs from the hardware circuit 13A in that it has a synchronization signal output section 132C, a latch section 133C and a signal interval counting section 136 instead of the synchronization signal output section 132, the latch section 133A and the FRC 134. do.
  • the signal interval counting unit 136 includes a counter that counts up according to a clock generated using a clock oscillation source (not shown) provided in the CPU unit 100C.
  • the signal interval counting section 136 outputs an output instruction to the synchronization signal output section 132C at the timing when the counter value reaches a certain value T.
  • FIG. The signal interval counting section 136 resets the counter value to 0 when outputting the output instruction to the synchronization signal output section 132C.
  • the value T corresponds to a constant cycle for outputting the synchronization signal and is set in advance. If the frequency of the clock generated using the clock oscillation source (not shown) is 125 MHz, the value T is, for example, 125000 (corresponding to 1 ms).
  • the signal interval counting section 136 may include a 16-bit counter. That is, the signal interval counting unit 136 includes a counter smaller in scale than the 64-bit FRC 134 (see FIG. 7). Therefore, as compared with Modification 1, an increase in the scale of the hardware circuit 13C is suppressed.
  • the synchronization signal output section 132C outputs the synchronization signal to the expansion unit 200C in response to receiving the output instruction from the signal interval counting section 136.
  • the synchronization signal output from the synchronization signal output section 132C is also input to the latch section 133C.
  • the FRC 131 also counts up according to a clock generated using a clock oscillation source (not shown) provided in the CPU unit 100C. Therefore, the counter included in the signal interval counting unit 136 and the FRC 131 count up at the same period.
  • the latch section 133C performs the same operation as the latch section 133 shown in FIG. That is, the latch section 133C latches the value X1 of the FRC 131 when the synchronization signal is output, and outputs time information including the held value X1 to the extension unit 200C. Furthermore, the latch section 133C causes the value T set in the signal interval counting section 136 to be included in the time information.
  • the hardware circuit 23C includes a latch unit 232A, a difference calculation unit 233A, an FRC correction unit 234A and a latch unit 232 instead of the FRC correction unit 235, a difference calculation unit 233C, an FRC correction unit 234C, and a signal interval measurement. It differs in that it has a portion 237 .
  • the signal interval measuring section 237 includes a counter that counts up according to a clock generated using a clock oscillation source (not shown) provided in the expansion unit 200C.
  • the signal interval measurement unit 237 outputs the counter value T1 to the difference calculation unit 233C at the timing of receiving the synchronization signal, and resets the counter value to 0.
  • the value T1 output from the signal interval measuring section 237 represents the count-up from the timing at which the previous synchronization signal was received to the timing at which the current synchronization signal was received.
  • the signal interval measuring section 237 may include a counter of the same scale as the signal interval counting section 136 . That is, the signal interval measurement unit 237 may include a counter smaller in scale than the 64-bit FRC 235 (see FIG. 7). Therefore, as compared with Modification 1, an increase in the scale of the hardware circuit 23C is suppressed.
  • the FRC 231 also counts up according to a clock generated using a clock oscillation source (not shown) provided in the expansion unit 200C. Therefore, the counter included in signal interval measuring section 237 and FRC 231 count up at the same period. Therefore, the signal interval measuring section 237 measures the value T1 as the difference between the value of the FRC 231 when the previous synchronization signal was output and the value of the FRC 231 when the current synchronization signal was output.
  • the FRC correction unit 234C corrects the FRC 231 based on the difference Z in addition to the operation of the FRC correction unit 234 shown in FIG.
  • the signal interval counting section 136 of the CPU unit 100C outputs an output instruction to the synchronization signal output section 132C at the timing when the counter value reaches a preset value T, and resets the counter value to 0 (see (31)).
  • the synchronization signal output section 132C outputs the synchronization signal to the expansion unit 200C according to the output instruction.
  • the synchronization signal is also output to the latch section 133C of the CPU unit 100C (see (32) in the figure).
  • the latch unit 133C latches the value X1 of the FRC 131 when the synchronization signal is output in response to the input of the synchronization signal, and extends the time information including the value X1 and the value T set in the signal interval counting unit 136. Output to the unit 200C (see (33) in the figure).
  • the latch section 232 of the extension unit 200C latches the value X2 of the FRC 231 when receiving the synchronization signal in response to the input of the synchronization signal, and outputs the value X2 to the difference calculation section 233C (see (34) in the figure). .
  • the signal interval measuring section 237 of the extension unit 200C measures the value T1, which is the count-up from the timing at which the previous synchronization signal is received to the timing at which the current synchronization signal is received, in response to the input of the synchronization signal.
  • T1 is output to the difference calculator 233C (see (35) in the figure).
  • the difference calculator 233C calculates the difference Y1 between the values X2 and X1 and the difference Z between the values T1 and T (see (36) in the figure).
  • the difference calculator 233C outputs the calculated differences Y1 and Z to the FRC corrector 234C (see (37) in the figure).
  • the FRC correction unit 234C corrects the FRC 231 based on the differences Y1 and Z (see (38) in the figure).
  • the method of correcting the FRC 231 based on the difference Y1 is as described above.
  • the method of correcting FRC231 based on difference Z is the same as the method of correcting FRC231 based on difference Y2.
  • the difference Z indicates the difference between the count number of the signal interval counting section 136 and the count number of the signal interval measuring section 237 in the target period from the output of the previous synchronization signal to the output of the current synchronization signal.
  • the counter included in the signal interval counting section 136 and the FRC 131 count up at the same period.
  • the counter included in the signal interval measuring section 237 and the FRC 231 count up at the same period.
  • the difference Z is therefore the clock deviation due to static jitter.
  • the FRC correction unit 234C continues to periodically correct the FRC 231 based on the difference Z. For example, the FRC corrector 234C corrects the clock deviation at a predetermined correction period. Assuming that the target period from the output of the previous synchronization signal to the output of the current synchronization signal is T1, and the correction period is T2, the FRC correction unit 234C performs (Z/T1) ⁇ T2 for each correction period. FRC231 should be corrected. This always cancels clock deviations due to static jitter.
  • FIG. 10 is a diagram showing the flow of data accompanying the waveform of the synchronization signal in Modification 3.
  • FIG. 10 shows the data flow for correction of clock deviation due to static jitter.
  • the synchronizing signal is output at a constant cycle indicated by the value T.
  • time information including the value T is output from the CPU unit 100C to the extension unit 200C.
  • the signal interval measuring section 237 of the extension unit 200C measures a value T1 that is the count-up from the timing at which the previous synchronization signal was received to the timing at which the current synchronization signal is received. For example, when a synchronization signal is received at timing t1, a value T11 is measured which is a count-up from timing t0 at which the previous synchronization signal was received to timing t1. Then, the difference Z1 between the value T11 and the value T is calculated, and the FRC 231 is corrected based on the difference Z1 .
  • the clock deviation caused by static jitter also depends on temperature and other factors. Therefore, the value T1 measured each time the synchronization signal is received may change depending on the environment. Therefore, by measuring the value T1 at regular intervals, the clock deviation caused by the static jitter is appropriately corrected according to the environment.
  • FIG. 11 is a diagram showing a signal distribution method when there are a plurality of extension units. As shown in FIG. 11, each of signal lines 3 and 4 connects CPU unit 100 and a plurality of expansion units 200 in a multi-drop configuration. Therefore, the synchronizing signal and time information output from the CPU unit 100 are distributed to the plurality of expansion units 200 via the signal lines 3 and 4, respectively.
  • the data bus 2 conforming to PCIe connects the CPU unit 100 and each of the plurality of expansion units 200 on a one-to-one basis.
  • the CPU unit 100 may be replaced with any one of the CPU units 100A, 100B, and 100C.
  • each of the plurality of expansion units 200 may be replaced with one of expansion units 200A, 200B, and 200C.
  • the first hardware circuit comprises: a first counter (131); a signal output unit (132, 132C) that outputs a synchronization signal to the second unit; a time information output unit (133, 133A, 133C) that outputs a first value of the first counter when the synchronization signal is output to the second unit;
  • the second hardware circuit comprises: a second counter (231); a difference calculator (233, 233A, 233C) for calculating a first difference between the second value of the second counter and the first value when the synchronization signal is received; and a correction unit (234, 234A, 234C) that corrects the second counter
  • said first hardware circuit (13A) further comprising a third counter (134);
  • the second hardware circuit (23A) further comprises a fourth counter (235),
  • the signal output unit (132) repeatedly outputs the synchronization signal,
  • the time information output unit (133A) further outputs the value of the third counter when the previous synchronization signal was output and the value of the third counter when the current synchronization signal was output.
  • the difference calculator (233A) further calculating a third difference between the value of the fourth counter when receiving the previous synchronization signal and the value of the fourth counter when receiving the synchronization signal this time; calculating a fourth difference between the second difference and the third difference;
  • the signal output unit (132C) outputs the synchronization signal each time the value of the first counter increases by a constant value
  • the time information output section (133C) further outputs the constant value to the second unit
  • the second hardware circuit (23C) stores the value of the second counter when the previous synchronization signal was output and the value of the second counter when the current synchronization signal was output.
  • the difference calculator (233C) further calculates a third difference between the second difference and the constant value
  • the control device (1C) according to claim 1, wherein said correction section (234C) corrects said second counter based on said third difference.
  • the first unit (100B) further comprises a first light emitting element (135) that blinks according to the value of the first counter, 4.
  • the control device (1B) according to any one of configurations 1 to 3, wherein the second unit (100C) further comprises a second light emitting element (236) that blinks according to the value of the second counter.
  • Composition 5 said first unit further comprising a processor (10) executing firmware
  • the firmware includes an instruction for setting the timing for outputting the synchronization signal to the signal output unit, The signal output unit outputs the synchronization signal when the value of the first counter reaches the timing,
  • the firmware further: instructions for calculating a fifth difference between the second value and the timing; an instruction to correct the second counter based on the fifth difference;
  • the control device according to configuration 1, wherein the processor disables the operation of the time information output unit after the firmware is activated.
  • composition 6 the first hardware circuit is an ASIC or FPGA; 6.

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

L'invention concerne un dispositif de commande pourvu d'une première unité et d'une seconde unité. Un premier circuit matériel de la première unité comporte un premier compteur, une partie de sortie de signal qui délivre un signal de synchronisation à la seconde unité et une partie de sortie d'informations temporelles qui délivre une première valeur du premier compteur à la seconde unité lorsque le signal de synchronisation a été émis. Un second circuit matériel de la seconde unité a un second compteur, une partie de calcul de différence qui calcule une première différence entre la première valeur et une seconde valeur du second compteur lorsque le signal de synchronisation a été reçu et une partie de correction qui corrige le second compteur sur la base de la première différence. Cela permet une réduction du temps nécessaire pour déterminer la cause d'une erreur qui peut s'être produite avant le démarrage du micrologiciel.
PCT/JP2021/047276 2021-02-04 2021-12-21 Dispositif de commande WO2022168475A1 (fr)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
JP2021-016473 2021-02-04
JP2021016473 2021-02-04
JP2021-154989 2021-09-24
JP2021154989A JP2022119703A (ja) 2021-02-04 2021-09-24 制御装置

Publications (1)

Publication Number Publication Date
WO2022168475A1 true WO2022168475A1 (fr) 2022-08-11

Family

ID=82742119

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2021/047276 WO2022168475A1 (fr) 2021-02-04 2021-12-21 Dispositif de commande

Country Status (1)

Country Link
WO (1) WO2022168475A1 (fr)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115080495A (zh) * 2022-08-22 2022-09-20 北京普太科技有限公司 一种标准外设扩展接口设备的时间同步方法及系统

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017079009A (ja) * 2015-10-21 2017-04-27 株式会社キーエンス プログラマブル・ロジック・コントローラのモニタ装置
JP2018064219A (ja) * 2016-10-14 2018-04-19 オムロン株式会社 制御装置および通信装置
JP2018173710A (ja) * 2017-03-31 2018-11-08 オムロン株式会社 制御装置、制御プログラム、および制御システム
CN111158867A (zh) * 2018-11-07 2020-05-15 阿里巴巴集团控股有限公司 时间同步处理方法、线程调度方法、装置及电子设备

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017079009A (ja) * 2015-10-21 2017-04-27 株式会社キーエンス プログラマブル・ロジック・コントローラのモニタ装置
JP2018064219A (ja) * 2016-10-14 2018-04-19 オムロン株式会社 制御装置および通信装置
JP2018173710A (ja) * 2017-03-31 2018-11-08 オムロン株式会社 制御装置、制御プログラム、および制御システム
CN111158867A (zh) * 2018-11-07 2020-05-15 阿里巴巴集团控股有限公司 时间同步处理方法、线程调度方法、装置及电子设备

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115080495A (zh) * 2022-08-22 2022-09-20 北京普太科技有限公司 一种标准外设扩展接口设备的时间同步方法及系统

Similar Documents

Publication Publication Date Title
EP3076251B1 (fr) Appareil de traitement d'informations, procédé de traitement d'informations et programme de traitement d'informations
EP3309647B1 (fr) Dispositif de commande et dispositif de communication
JP5794449B2 (ja) プログラマブルコントローラ
CN111052006B (zh) 控制装置以及控制方法
WO2022168475A1 (fr) Dispositif de commande
JP2013156987A (ja) センサーデータ伝送装置
EP3361635A1 (fr) Système de commande et dispositif de sortie d'impulsions
JP2015179999A (ja) 時刻同期装置並びにそのためのバックアップ装置および時刻同期システム
JP2016110458A (ja) プログラマブル・ロジック・コントローラ、基本ユニット、制御方法およびプログラム
US9081371B2 (en) Method for synchronizing an operating clock with a time clock of an automation network
KR20180006285A (ko) 광학 계측 장치
JP6704548B1 (ja) 通信システム、通信装置及びプログラム
WO2022168338A1 (fr) Dispositif de commande
US11689347B2 (en) Communication apparatus, communication system, communication method, and computer readable medium
US20230023970A1 (en) Control system
KR20170125405A (ko) 시각 동기 장치 및 시각 동기 시스템
JP4788260B2 (ja) 多変量伝送器
JP2019215818A (ja) 制御装置およびその制御方法
JP6587566B2 (ja) 半導体装置
JP2006340371A (ja) システムバスへのアクセス時間を制御するための方法および通信モジュール
JP6132097B2 (ja) 測定システムおよび測定方法
WO2022259381A1 (fr) Dispositif de synchronisation temporelle, procédé de synchronisation temporelle et programme
US20230308514A1 (en) Input unit, control system, communication method, and recording medium
JPWO2020049698A1 (ja) 通信システム、通信装置、及びプログラム
JP6217478B2 (ja) 制御システムおよび制御装置

Legal Events

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

Ref document number: 21924860

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21924860

Country of ref document: EP

Kind code of ref document: A1