The present application claims priority under 35 U.S.C. §119 to Japanese Patent Application No. 2015-122868, filed Jun. 18, 2015. The contents of this application are incorporated herein by reference in their entirety.
The embodiments disclosed herein relate to a programmable controller.
Japanese Unexamined Patent Application Publication No. 2003-167608 discloses a programmable controller to manage, as formation information, kinds and arrangements of input devices and output devices connected to the programmable controller.
According to one aspect of the present disclosure, a programmable controller to control a control machine includes an arithmetic processor, a storage, and a selector. The storage stores a plurality of definition files and a control program. The plurality of definition files each define a corresponding relationship between specification information and a plurality of control elements of the control machine. The specification information specifies an input-output end from and to which the programmable controller receives and outputs at least one of a command and information. The control program is executable by the arithmetic processor to input and output at least one of the command and the information from and to the plurality of control elements based on at least one definition file among the plurality of definition files. The selector is configured to select the at least one definition file to use as a basis on which the arithmetic processor executes the control program.
A more complete appreciation of the present disclosure and many of the attendant advantages thereof will be readily obtained as the same becomes better understood by reference to the following detailed description when considered in connection with the accompanying drawings, wherein:
The embodiments will now be described with reference to the accompanying drawings, wherein like reference numerals designate corresponding or identical elements throughout the various drawings.
The programmable controller 1 is what is called an upper-level controller to control operation and information of control elements of the production machine 2 based on a control program and definition files stored in a memory, described later. In the illustrated example, the programmable controller 1 is provided with a power source 11, a CPU 13, a servo control unit 14, an I/O control unit 15, and a communication control unit 16, which correspond to slots S1 to S5 of the main body of the programmable controller 1 in ascending order. The CPU 13 includes the memory 12.
The power source 11 functions to supply power to each component of the programmable controller 1.
The CPU 13 (which is the arithmetic processor) functions to transmit and receive commands and information to and from each component of the programmable controller 1 based on a control program and a definition file (see
The production machine 2, described later, includes drive shafts (actuators) as the control elements. The servo control unit 14 is connected to each of the drive shafts and functions to output commands from the CPU 13 to the drive shafts.
The production machine 2, described later, includes auxiliary devices such as various sensors, lamps, and solenoids as the control elements. The I/O control unit 15 is connected to the auxiliary devices and functions to make commands and information input and output between the I/O control unit 15 and the CPU 13.
The communication control unit 16 is connected to programmable controllers of other machine control systems through suitable communication lines and functions to control transmission and reception of information to and from the CPU 13 so as to perform cooperation with the programmable controllers.
The servo control unit 14, the I/O control unit 15, and the communication control unit 16 each include a plurality of ports (which are the connectors), and are connected to a plurality of control elements of the production machine 2 and other programmable controllers through the ports. The plurality of ports are discriminated in advance as input and output ports of commands and information so as to specify the ports on the hardware level. In order to avoid complication of the drawings and facilitate description, assume that the servo control unit 14 includes five ports P1, P2, P3, P4, and P5 in the example illustrated in
One of a general-use personal computer 21 (abbreviated to general-use PC in
The production machine 2 is an assembly of mechanical elements to perform predetermined actions by driving movable portions by rotary or linear motors (actuators) incorporated in the production machine 2. Additionally, the production machine 2 performs cooperative control using auxiliary devices such as various sensors, lamps, and solenoids. Each of these motors and a servo amplifier (not illustrated) to control the motor will be referred to as drive shaft. It is noted that it is not necessary to correspond the motors to the servo amplifiers in one-to-one manner. In a non-limiting embodiment, a single multi-axis control servo amplifier may control a plurality of motors. In this case as well, the motors will be each referred to as drive shaft and are regarded as units to be respectively connected to the ports P1 to P5 individually.
The production machine 2 in the example illustrated in
As described above, the programmable controller 1 is connected to a plurality of control elements (drive shafts and auxiliary devices) of the production machine 2 through the ports. The CPU 13 performs the input and output of commands and/or information with respect to the control elements in accordance with the control program. Thus, the programmable controller 1 controls actions of the production machine 2. Other than the control program, however, it is necessary for the programmable controller 1 to individually prepare definition files for respective occasions in advance. A definition file defines, as software, which control elements are actually connected in which configuration.
Properties of this Embodiment
As described above, the production machine 2 may have the connection configuration changed in various manners by randomly adding and connecting option shafts separate from the standard shafts. It is necessary to individually prepare and manage definition files as well in accordance with respective connection configurations of the production machine 2.
In contrast, in this embodiment, the memory 12 of the programmable controller 1 stores a plurality of definition files and a control program. A definition file defines which control element is connected to which of the ports in accordance with each connection configuration of the production machine 2. The control program causes the CPU 13 to perform the input and output of commands and/or information with respect to the plurality of control elements based on at least one of the plurality of definition files. The programmable controller 1 also includes a selector (described in detail later) to select based on which of the plurality of definition files the CPU 13 is made to execute the control program. Thus, software of the production machine 2 of large variation can be used in common to facilitate development and operation management of the software.
The flash memory 31 (which is the non-volatile storage) is what is called a non-volatile storage in which the stored contents are readable and rewritable when the power is supplied and from which the stored contents are not erased even when the power supply is interrupted. In this embodiment, the flash memory 31 stores one preserved project (control project) made up of one common control program and a plurality of definition files. An exemplary preserved project illustrated in
The RAM 32 (which is the volatile storage) is what is called a volatile storage in which the stored contents are readable and rewritable when the power is supplied and from which the stored contents are erased when the power supply is interrupted. The RAM 32 stores one execution project (control project) made up of the common control program and one definition file transferred from the flash memory 31. The access speed of the RAM 32 is relatively high. The CPU 13 accesses and executes the execution project stored in the RAM 32 so as to increase the processing speed.
The ROM 33 is what is called a non-volatile storage in which the stored contents are only readable when the power is supplied and from which the stored contents are not erased even when the power supply is interrupted. In this embodiment, the ROM 33 stores a system program for, for example, transferring the stored contents from the flash memory 31 to the RAM 32 when the programmable controller 1 is powered (see
When the stored contents are transferred from the flash memory 31 to the RAM 32, the selector 41 selects one of the plurality of definition files in the preserved project stored in the flash memory 31 and transfers the selected definition file to the RAM 32. In the example of this embodiment, the selector 41 includes a hardware switch such as a rotary switch, and the selector 41 is operated to select the definition file. It is noted that the selector 41 may be arranged to set the contents of a system register (not illustrated) of the CPU 13 so as to select the definition file by means of software.
It is noted that since the ports P1 to P5 are compatible with each other on the hardware level, the contents of the definition files may have various combinations other than the illustrated examples. For example, even when the production machine 2 includes the four drive shafts A to D, as illustrated in
As a comparative example, an exclusive control program that is executed in accordance with only the above-described standard definition file is arranged in such a manner that it suffices that drive processing X, Y, and Z is unconditionally performed for the respective drive shafts A, B, and C, as illustrated in
As a comparative example, an exclusive control program that is executed in accordance with only the above-described standard+first option definition file (see
As a comparative example, an exclusive control program that is executed in accordance with only the above-described standard+second option definition file is arranged in such a manner that it suffices that drive processing X, Y, Z, V, and W is unconditionally performed for the respective drive shafts A, B, C, D, and E, as illustrated in
The common control program used in this embodiment, however, is described in such a manner that even when the common control program is combined with any of the plurality of definition files prepared in advance in the preserved project, the common control program can be appropriately executed. Specifically, as illustrated in
With the storage configuration of the memory 12 illustrated in
Even when the production machine 2 has a different connection configuration, the selector 41 merely selects a definition file corresponding to the connection configuration so as to set an appropriate execution project in the RAM 32 and make the CPU 13 execute the execution project. In other words, definition files corresponding to various connection configurations are merely prepared in advance in the preserved project in the flash memory 31 so as to use the project in common. This facilitates the management and improves development efficiency of the control program.
A control procedure of the system program executed in the ROM 33 by the CPU 13 in order to implement the above-described functions will be described step by step by referring to
First, at step S105, the CPU 13 transfers only the common control program from the flash memory 31 (abbreviated to F memory in
Next, the processing proceeds to step 5110, and the CPU 13 transfers a definition file selected by the selector 41 from the flash memory 31 to the RAM 32.
Next, the processing proceeds to step S115, and the CPU 13 sets an execution project with the common control program and the definition file in the RAM 32, which have been transferred at step S105 and step S110.
Next, the processing proceeds to step S120, and the CPU 13 executes the execution project in the RAM 32, which has been set at step S115. Thus, the CPU 13 controls actions and information of the control elements of the production machine 2 through the ports. Then, this flow is ended.
Effects of this Embodiment
As has been described heretofore, with the programmable controller 1 of this embodiment, the memory 12 stores the plurality of definition files and the common control program. The definition files each define a corresponding relationship between the numerals P1 to P5 of the ports and the plurality of control elements of the production machine 2. The numerals P1 to P5 of the ports specify an input-output end from and to which the programmable controller receives and outputs at least one of a command and information. The common control program causes the CPU 13 to perform the input and output of commands and/or information with respect to the plurality of control elements based on at least one of the plurality of definition files. The programmable controller 1 also includes the selector 41 to select based on which of the plurality of definition files the CPU 13 is made to execute the common control program. Thus, even when the production machine 2 has various connection configurations, the selector 41 is merely operated to appropriately control the production machine 2 of each connection configuration based on the corresponding definition file. This facilitates appropriate control in accordance with various changes in the connection configuration of the production machine 2.
In this embodiment, in particular, the programmable controller 1 includes the plurality of control elements and the plurality of ports P1 to P5 respectively connected to the control elements. With the numerals P1 to P5 of these ports, the input-output ends of commands and/or information are specified. Thus, the port numerals P1 to P5, which are set in advance on the hardware level, are used to readily specify the input-output ends of commands and/or information.
In this embodiment, in particular, the control program is described as the common control program to cause the CPU 13 to perform the input and output of commands and/or information with respect to only the control elements which have the connection defined by the definition file selected by the selector 41. Thus, the common control program can be integrated as a single control program to function for the plurality of definition files in common.
In this embodiment, in particular, the selector 41 substantially selects a definition file only when the programmable controller 1 to execute the system program in
In this embodiment, in particular, the memory 12 includes the volatile RAM 32 and the non-volatile flash memory 31. The flash memory 31 stores the plurality of definition files and the common control program. At the start time of the programmable controller 1, the RAM 32 reads the definition file selected by the selector 41 and the common control program from the flash memory 31 and stores the definition file and the common control program. Then, based on the definition file stored in the RAM 32, the CPU 13 executes the common control program stored in the same RAM 32. Thus, even when the power supply is interrupted, the plurality of definition files and the common control program stored in the flash memory 31 can be all kept without being erased. Also, at the start time of the programmable controller 1, only the required definition file and the common control program can be read by the RAM 32 having a relatively high access speed and executed. This improves the processing speed of the control and the memory efficiency. In this embodiment, the flash memory 31 and the RAM 32 are used for different purposes. This, however, should not be construed in a limiting sense. For example, the memory 12 does not include the RAM 32 but may include the flash memory 31 and the ROM 33 only. Thus, with the definition file selected by the selector 41 and the common control program, the execution project is set in the flash memory 31 and executed.
The present invention is not limited to the above-described embodiment. Various modifications are possible without departing from the subject matter. One of such modifications will now be described.
In the embodiment described above, each control unit includes the plurality of ports P1 to P5 that can be individually specified, and the control unit is connected to the control elements of the production machine 2 through the ports P1 to P5. This, however, should not be construed in a limiting sense. For example, as illustrated in
In the example illustrated in
For the network connection having such a high freedom degree, it suffices that a definition file corresponding to the connection configuration is prepared, as illustrated in
As described above, the programmable controller 1 of this modification is connected through the network NW to the plurality of node terminals 51, which are respectively connected to the plurality of control elements. With the node addresses randomly and uniquely set respectively for the plurality of node terminals, it is specified the input-output ends of commands and/or information. Thus, the node addresses set with a high degree of freedom and randomly are used to specify the input-output ends of commands and/or information.
Otherwise, the above-described embodiments and modification may be combined in any manner deemed suitable.
Obviously, numerous modifications and variations of the present disclosure are possible in light of the above teachings. It is therefore to be understood that within the scope of the appended claims, the present disclosure may be practiced otherwise than as specifically described herein.
Number | Date | Country | Kind |
---|---|---|---|
2015-122868 | Jun 2015 | JP | national |