Message processing unit of PLC system
09871867 ยท 2018-01-16
Assignee
Inventors
Cpc classification
H04L67/125
ELECTRICITY
G05B2219/25218
PHYSICS
International classification
G05B19/05
PHYSICS
Abstract
Disclosed is a message processing unit provided in a PLC system including a master and a plurality of slaves. The message processing unit is provided to each of the slaves and includes a first filter configured to receive a message transmitted from the master and to determine whether the message is a broadcast message, a second filter configured to receive the message delivered from the first filter and to determine whether the message is a message-to-be-processed, and a processor configured to process the message he delivered from the first filter or the second filter.
Claims
1. A message processing unit provided in a Programmable Logic Controller (PLC) system comprising a master and a plurality of slaves, the message processing unit being provided to each of the slaves, the message processing unit comprising: a first filter configured to receive a message transmitted from the master and configured to determine whether the message is a broadcast message; a second filter configured to receive the message from the first filter when it is determined that the message is not a broadcast message, and configured to determine whether the message is a message-to-be-processed; and a processor configured to process the message from the first filter when it is determined that the message is a broadcast message or from the second filter when it is determined that message is a message-to-be-processed.
2. The message processing unit according to claim 1, wherein the first filter is configured to deliver the message to the processor when it is determined that the message is the broadcast message, and is further configured to deliver the message to the second filter when it is determined that the message is not the broadcast message.
3. The message processing unit according to claim 1, wherein the second filter is configured to deliver the message to the processor when it is determined that the message is the message-to-be-processed, and is further configured to discard the message when it is determined that the message is not the message-to-be-processed.
4. The message processing unit according to claim 1, wherein the message comprises a Message Group field, a MAC ID field and a Message ID field, wherein the message processing unit is classified into the broadcast message or the message-to-be-processed according to a value set in the Message ID field, the broadcast message being received by all the slaves and the message-to-be-processed being received by a slave set in the MAC ID field.
5. The message processing unit according to claim 4, wherein the first filter comprises a pair of Filter Enable field and Filter Value field, the pair having the same structure as the message, wherein the Filter Enable field and the Filter Value field are configured to determine whether the message is the broadcast message.
6. The message processing unit according to claim 5, wherein a field of the Filter Value corresponding to the Message Group field of the message is set to have the same value as the Message Group field of the broadcast message, and a field of the Filter Value corresponding to the Message ID field of the message is set to have the same value as the Message ID field of the broadcast message.
7. The message processing unit according to claim 4, wherein the second filter comprises a pair of Filter Enable field and Filter Value field, the pair having the same structure as the message, wherein the Filter Enable field and the Filter Value field are configured to determine whether the message is the message-to-be-processed.
8. The message processing unit according to claim 7, wherein a field of the Filter Value corresponding to the Message Group field of the message has the same value as the Message Group field of the message-to-be-processed, and a MAC ID of the slave is set as a value of a field of the Filter Value corresponding to the MAC ID field of the message.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1) The above and other aspects, features and other advantages of the present disclosure will be more clearly understood from the following detailed description taken in conjunction with the accompanying drawings, in which:
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
DETAILED DESCRIPTION
(10) Advantages and features of the present disclosure and methods to achieve them will become apparent from the descriptions of exemplary embodiments herein below with reference to the accompanying drawings. However, the present disclosure is not limited to the exemplary embodiments disclosed herein but may be implemented in various different forms. The exemplary embodiments are provided to make the description of the present disclosure thorough and to fully convey the scope of the present disclosure to those skilled in the art. It is to be noted that the scope of the present disclosure is defined only by the claims. Wherever possible, the same reference numbers will be used throughout the descriptions to refer to the same or like parts.
(11) In describing embodiments of the present disclosure, a detailed description of well-known functions and constituents will be omitted if it is determined that such description can unnecessarily obscure the main points of the disclosure. In addition, terms which will be used below are defined in consideration of the functions of the corresponding elements in the disclosure. The definitions of the terms may vary depending on intention of a user, a precedent case, or the like. Therefore, the terms should be defined based on the entire specification.
(12) Hereinafter, a detailed description will be given of configuration and operation of a message processing unit of a PLC system according to embodiments of the present disclosure with reference to the accompanying drawings.
(13)
(14) Referring to
(15) Each of the slaves 520-1 to 520-N includes a message processing unit. The message processing unit includes a first filter 521-1, . . . , 521-N, a second filter 522-1, . . . , 522-N and a processor 523-1, . . . , 523-N.
(16) In the slaves 520-1 to 520-N, the first filters 521-1 to 521-N have the same function, the second filters 522-1 to 522-N have the same function and the processors 523-1 to 523-N have the same function. Thus, description will be given of the first slave 520-1 alone.
(17) The first slave 520-1 includes a first filter 521-1, a second filter 522-1 and a processor 523-1.
(18) The first filter 521-1 determines whether a message transmitted from the master 510 is a broadcast message. Herein, the broadcast message represents a message which the master 510 transmits to all slaves.
(19) If the received message is determined to be a broadcast message as a result of determination of the first filter 521-1, the first filter 521-1 delivers the received message to the processor 523-1.
(20) On the other hand, if the received message is not a broadcast message as a result of determination of the first filter 521-1, the first filter 521-1 delivers the received message to the second filter 522-1.
(21) Regarding configuration of the first filter 521-1, 2 bits of Filter Enable corresponding to Message Group field of the message are all set to 0, and bits of Filter Value corresponding to Message Group field of the message are set to 1 and 0, as shown in
(22) In addition, 3 bits of Filter Enable corresponding to Message ID field of the message are all set to 0, and bits of Filter Value corresponding to Message ID field of the message are all set to 0.
(23) In addition, 6 bits corresponding to MAC ID field of the message are all set to 1, and thus the first filter 521-1 is not affected by the value of MAC ID field of the message. Specifically, the first filter 521-1 may recognize a message having Message Group field set to 10 and Message ID field set to 000.
(24) Thereby, a field of Filter Value corresponding to the Message Group field of the message has the same value as the Message Group field of the broadcast message. A field of Filter Value corresponding to the Message ID field of the message set to have the same value as the Message ID field of the broadcast message.
(25) Accordingly, if the first filter 521-1 is configured as shown in
(26) The second filter 522-1 receives a message delivered from the first filter 521-1 and determines whether the received message is a message to be processed by the slave 520-1 (message-to-be-processed).
(27) Since the message of Message Type #1 of
(28) Meanwhile, if the received message is determined to be a message-to-be-processed as a result of determination of the second filter 522-1, the second filter 522-1 delivers the received message to the processor 523-1.
(29) On the other hand, if it is determined that the received message is not a message-to-be-processed as a result of determination of the second filter 522-1, the second filter 522-1 discards the received message.
(30) Regarding configuration of the second filter 522-1, 2 bits of Filter Enable corresponding to Message Group field of the message are all set to 0 as shown in
(31) In addition, 6 bits corresponding to MAC ID field of the message are all set to 0, and MAC ID of the slave is set in Filter Value. That is, the second filter 522-1 may determine whether the message is a message having MAC ID of the slave.
(32) Thereby, a field in Filter Value corresponding to the Message Group field of the message has the same value as the Message Group field of the message-to-be-processed. The value of a field in Filter Value corresponding to the MAC ID field of the message is set to MAC ID of the slave.
(33) Accordingly, if the second filter 522-1 is configured as shown in
(34) The processor 533-1 processes a message delivered from the first filter 531-1 and a message delivered from the second filter 522-1.
(35) Since the messages which the processor 523-1 receives are all messages-to-be-processed, the processor 523-1 processes both received messages without determining whether the received messages are messages-to-be-processed.
(36) Accordingly, even if the number of slaves increases, the number of messages processed by the processor 523-1 remains constant because messages are delivered to the processor 533-1 through the first and second filters 521-1 and 522-1 are messages-to-be-processed.
(37) According to another embodiment of the present disclosure, a PLC system including a message processing unit includes multiple modules. One of the modules operates as a master module and the other modules operate as slave modules. Herein, the master transmits the five types of messages shown in
(38) Each of the slaves may include the message processing unit. The message processing unit may include a first filter and a processor.
(39) The first filter may receive a message transmitted from the master and determine whether the received message is a broadcast message. In addition, the first filter may determine whether the message is a message-to-be-processed. The processor may receive the message from the first filter and process the same.
(40) If the first filter determines that the message is a broadcast message, the first filter delivers the message to the processor. If the first filter determines that the message is not a broadcast message, the first filter may determine whether the message is a message-to-be-processed.
(41) If the first filter determines that the message is a message-to-be-processed, the first filter may deliver the message to the processor. If the first filter determines that the message is not a message-to-be-processed, the first filter may discard the message.
(42) In the description above, configuration and functions of a message processing unit of a PLC system according to embodiments of the present disclosure have been discussed. Hereinafter, description will be given of a method for processing a message in a PLC system configured as illustrated in
(43)
(44) Referring to
(45) Thereby, the first filter 521-1 of the slave 520-1 is configured to determine whether a message transmitted from the master 510 is a broadcast message. The second filter 522-1 of the slave 520-1 is configured to determine whether the message transmitted from the master 510 is a message-to-be-processed which the slave equipped with the second filter 522-1 should process.
(46) If the slave 520-1 receives a message from the master 510 of the PLC system (S820) after the first and second filters 521-1 and 522-1 of the slave 520-1 are configured in step S810, the first filter 521-1 of the slave 520-1 determines whether the received message is a broadcast message (S830).
(47) If the received message is determined to be a broadcast message (S830Yes) as a result of determination in step S830, the first filter 521-1 delivers the message to the processor 523-1 (S840).
(48) Thereafter, the processor 523-1 receives and processes the message delivered from the first filter 521-1 in step S840 (S850).
(49) If the received message is determined to be a broadcast message (S830No) as a result of determination in step S830, the first filter 521-1 delivers the message to the second filter 522-1, and the second filter 522-1 determines whether the received message is a message-to-be-processed (S860).
(50) If the received message is determined to be a message-to-be-processed (S860Yes) as a result of determination in step S860, the second filter 522-1 delivers the message to the processor 523-1 (S840), and the processor 523-1 processes the message delivered from the second filter 522-1 (S850).
(51) On the other hand, if it is determined that the received message is not a message-to-be-processed (S860No) as a result of determination in step S860, the second filter 522-1 discards the message (S870).
(52) According to embodiments of the present disclosure described above, the slave in the PLC system receives a message transmitted from the master in the PLC system through multiple filtering operations. Accordingly, the slave receives only messages destined therefor.
(53) Thereby, even if the number of slaves increases, the number of messages processed by one slave remains constant. Therefore, load of message processing interrupt may be reduced, and the time taken to process messages may be reduced. Thereby, messages may be efficiently processed.
(54) Embodiments of configuration and functions of a message processing unit of a PLC system have been described. However, the scope of the present disclosure is not limited thereto. Various substitutions, modifications and changes can be made in the present disclosure within the scope which is apparent to those skilled in the art.
(55) Accordingly, the exemplary embodiments described herein and the accompanying drawings are not intended to limit the scope of the present disclosure. The technical idea of the present disclosure is not limited by the exemplary embodiments and the accompanying drawings. The scope of protection sought by the present disclosure should be determined by the appended claims and their legal equivalents, and all changes coming within the meaning and equivalency range of the appended claims are intended to be embraced therein.