Overview
The system can connect to a local PLC to publish status and production information and to allow the PLC to select the recipe that is run. The option is enabled by setting the PLC IP Addr parameter to a valid IP address (see the parameter section below).
Communication is over EtherNet/IP; the driver the system uses connects to Allen-Bradley ControlLogix/CompactLogix (CLX) controllers. The remote PLC is reached over the ethernet port on the back of the system. That port is a separate network connection on the HMI PC with its own IP address, so the PLC does not need to be on the same subnet as the rest of the system (192.168.1.x) — only on the same subnet as the address assigned to that port. The PLC's IP address is set with the PLC IP Addr parameter. The system confirms the PLC is reachable by pinging the configured address; if the PLC stops responding, the system marks it as disconnected and automatically retries the connection.
Hardware
A remote PLC must be available on the network to use this option. The system's driver communicates with Allen-Bradley ControlLogix/CompactLogix PLCs over EtherNet/IP, reaching the PLC over the rear ethernet port. No hardware beyond the standard ethernet connection is required on the system side.
Run Behavior
When the PLC sends a recipe to the system, that recipe must match one listed in the system. The recipe is then displayed on the home screen, and users no longer have access to the recipe selection dropdown. If the PLC sends an empty string, the recipe selection dropdown becomes accessible again and the user can choose the recipe.
If the PLC sends a recipe that does not exist in the system, the system alarms and does not run.
In dual mode, " LEFT" and " RIGHT" are appended to the recipe name sent by the PLC, and the resulting recipes are run on the left and right sides, respectively.
The system continuously writes the names of the recipes currently running back to the PLC (see RecipeA and RecipeB under PLC Tags). This lets the PLC confirm which recipes are active, including the suffixed names produced in dual mode.
PLC Tags
The parameters page allows users to define a base tag for the PLC communications (the PLC Base Tag parameter) as well as a recipe tag (the PLC Pallet Tag parameter). If the recipe tag is blank, the system will not look for the PLC to send a recipe. If the base tag is blank, the system will not write any status tags to the PLC.
Each tag below is appended to the base tag — for example, if the base tag is Palletizer., the keep-alive tag is Palletizer.KeepAlive.
| Tag | Description |
KeepAlive | Heartbeat. The system toggles this value between 1 and 0 on every communication cycle. The PLC should monitor it for a continuously changing value to confirm the system is connected, and should not write to it. |
StatusInfo | Bit-packed status word. Bit 0 is always set while the system is connected; bit 1 is set when a pick has completed on either side; bit 2 is set while the system is in reduced-speed mode. |
SystemStatus | High-level system status, 0–6. See the table below. |
SystemState | Raw internal state value of the system (diagnostic; not the same as SystemStatus). |
LeftPalletBoxes | Number of boxes currently placed on the left (A) pallet. |
RightPalletBoxes | Number of boxes currently placed on the right (B) pallet. |
TotalBoxes | Total number of boxes the system has placed in its lifetime. Cannot be reset from within the software. |
TotalPallets | Total number of full pallets removed from the system in its lifetime. Cannot be reset from within the software. |
FaultCode | Current fault code from the robot (base alarm word). |
FaultCode_HMI | Fault code of the first active HMI/system alarm. |
FaultCode_Conveyor | Fault code of the conveyor system. |
FaultDescription | Text description of the current active alarm; empty string when no alarm is active. |
RecipeA | Name of the recipe currently running on the left (A) side. |
RecipeB | Name of the recipe currently running on the right (B) side. |
System Status values
| Status Tag Value | Palletize System Status |
| 0 | Off / disconnected (also set when the palletize robot is not present) |
| 1 | Not ready to run / faulted |
| 2 | Idle |
| 3 | Running |
| 4 | Reserved (not used) |
| 5 | Blocked (pallets full or missing) |
| 6 | Starved (no boxes to pick) |
A status value of 0 for a full disconnection must be produced by the PLC, because the system cannot write its own tags while it is disconnected. A common approach is a keepalive timeout in the PLC: if the KeepAlive tag stops changing, force the status to 0.
If needed, a limited set of additional tags can be read or set via the custom scripting engine. These are generally custom boolean flags rather than arbitrary system values, so not everything in the HMI can be exposed to the PLC this way.
Parameters
PLC IP Addr — The IP address of the remote PLC the system connects to when PLC Connection is checked. Because the PLC uses the dedicated ethernet port on the back of the system — a separate connection with its own address — this only needs to match the subnet of that port, not the system's internal 192.168.1.x network. If this parameter is blank or set to it’s default value of “0.0.0.0” then the system will not attempt to connect to a PLC.
PLC Type — Selects the type of PLC the system connects to when PLC Connection is checked.
PLC Pallet Tag — The string tag in the PLC that controls which recipe the system runs. Takes effect only when PLC Connection is checked. If this parameter is left empty, the system does not look for a remote tag and recipe selection stays local. When it is configured, the system reads the tag each cycle: an empty string allows the user to select a recipe locally, a matching recipe name runs that recipe, and a value that does not match any recipe in the system causes the system to alarm.
PLC Base Tag — The root string prepended to the series of status tags the system writes to the PLC (for example KeepAlive, SystemStatus, TotalBoxes). If this parameter is empty, the system writes no status tags. See the PLC Tags subsection above for the full list.
Comments
0 comments
Article is closed for comments.