EasyPLC Simulator Robotic Cell Click PLC

EasyPLC Simulator Robotic Cell Click PLC

The Machine Simulator (MS) is part of the EasyPLC software suite. It has many built-in machines that are used to show different programming techniques. The robotic cell example is one of these machines. This will demonstrate a sequencer example. In this case, an engine is lifted and placed onto a rack. The logic will step through various steps to perform the task.
EasyPLC Simulator Robotic Cell Click PLC
We will be using a Click PLUS PLC and the Click programming software to program this EasyPLC machine simulator engine loader of the robotic cell. This will be done using Modbus TCP (Ethernet) for communications. The program will allow you to start, stop and jog the sequencer. Using the five steps for program development, we will show how this sequencer is programmed. Let’s get started.

Learn PLC programming the easy way. See below how to receive a 10% discount on this already cost-effective learning tool. Invest in yourself today.
Previously we have done the following:
Easy PLC Installing the SoftwareVideo
EasyPLC Software Suite – Quick StartVideo
Click PLC – Easy Transfer Line ProgrammingVideo
Productivity PLC Simulator – Chain Conveyor MSVideo
Do-More PLC – EasyPLC Box Selection ProgramVideo
Click PLC EasyPLC Gantry SimulatorVideo
Click PLC Simple Conveyor EasyPLCVideo
EasyPLC Paint Line Bit Shift – BRX Do-More PLCVideo
Click PLC – EasyPLC PLC Mixer ProgrammingVideo
Click PLC EasyPLC Warehouse Stacker ExampleVideo
–  Operation Video
EasyPLC Machine Simulator Productivity PLC Robotic CellVideo

Define the task: (Step 1 – Easyplc Robotic Cell)

The first step of PLC program development is determining what must be done. Start the EasyPLC Machine Simulator (MS). Select the start button on the main page or select machines from the main menu at the machines simulator window.

All the available machines will now be displayed. Click on the “13 Engine Loading”. This is the example that we will be programming. To the left of the screen, information will be displayed on what the machine needs to do and the inputs and outputs required for the program.
This system uses:
1 Robot
2 Conveyor Lines
2 Conveyor Stops
2 Inductive Switches
1 Beacon Light
Use the industrial robot to load the engine blocks into the pallets. Manage the conveyors and stops to place the parts in their positions. The robot loads the engine block into the pallet. Once loaded, release the pallet. The robot moves with PLC digital IO signals.

The machine simulator has a demo mode for the built-in machines. This will allow you to watch the operation of the robotic cell. Select the demo mode for the engine loading.

The load robot process demo mode will operate, showing you the basics of operation.

Move around the 3D virtual environment. There are three icons on the top of the window that allows you to move around this 3D environment. The first icon is the default selection. This will enable you to move around without bumping into the components. The last icon will automatically show you around this virtual environment. The first-person mode will mimic a person in your 3D learning world. Once we understand what must be done, we can now move on to the next step in the PLC program development.

Define the Inputs and Outputs: (Step 2 – Easyplc Robotic Cell)

The View IO at the bottom of the machine simulator window will display the inputs and outputs required for this robotic cell example. While still in demo mode, you can see the operation of the information and outputs.

Use the following PLC signals to move the robot:
PLC Digital Outputs:
2 – Activate the robot fix system (to take the engine block)
4 – Move the robot to the home position
5 – Moves robot to the take engine position
6 – Move the robot to the lift engine position
7 – Move the robot to the load engine position (in pallet)
8 – Move the robot to the lift position (once the engine is loaded into the pallet)
PLC Digital Inputs:
0 – Active when the robot detects an engine in the gripping device
1 – Active when the robot finishes the movement
Use the following PLC signals to manage the machine:
PLC Digital Outputs:
0 – Start conveyor system
1 – Activate conveyor stop 1 (engine part)
3 – Activate conveyor stop 2 (pallet part)
9 – Request a new engine part
10 – Request a new pallet part
11 – Beacon Red Light
12 – Beacon Yellow Light
13 – Beacon Green Light
PLC Digital Inputs:
2 – Inductive SW1 signal for engine part
3 – Inductive SW2 signal for pallet part

The EasyPLC robotic cell engine loader example will require 14 digital outputs and four digital inputs.
If you are unsure what output or input is doing, start the engine loading machine in Start mode.

Select the View IO on the bottom middle of the machine simulator window. You can manually run the robotic cell without any control or PLC connected.

Clicking on the outputs will allow you to turn them on manually. You can then monitor the inputs to see their operation. The restart button on the bottom of the machine simulator window will reset the scene back to the start.
The following table will define the inputs and outputs (IO) and Modbus addresses in the Click PLC that we will use for this program.

Digital Type Description Click PLC Modbus Address Machine Simulator Modbus Address
PLC Output – MS Input Conveyor 1 2 Advance Y101 – 8225 8224
PLC Output – MS Input Stop 1 Stop Y102 – 8226 8225
PLC Output – MS Input Robot Fix Part Y103 – 8227 8226
PLC Output – MS Input Stop 2 Stop Y104 – 8228 8227
PLC Output – MS Input Robot Home Y105 – 8229 8228
PLC Output – MS Input Robot Take Part Y106 – 8230 8229
PLC Output – MS Input Robot Lift Part Y107 – 8231 8230
PLC Output – MS Input Robot Load Part Y108 – 8232 8231
PLC Output – MS Input Robot Elevate Robot Y109 – 8233 8232
PLC Output – MS Input Work Part Create Engine Y110 – 8234 8233
PLC Output – MS Input Light Machine Create Pallet Y111 – 8235 8234
PLC Output – MS Input Beacon Light Red Y112 – 8236 8235
PLC Output – MS Input Beacon Light Yellow Y113 – 8237 8236
PLC Output – MS Input Beacon Light Green Y114 – 8238 8237
PLC Input – MS Output Robot Detect X101 – 100033 32
PLC Input – MS Output Robot Stopped Movement X102 – 100034 33
PLC Input – MS Output Inductive Switch 1 X103 – 100035 34
PLC Input – MS Output Inductive Switch 2 X104 – 100036 35

Note: The machine simulator will be offset by one on the Modbus Addresses. See the video below for the demo mode and determining inputs and outputs.

Develop a logical sequence of operation: (Step 3 – Easyplc Robotic Cell)

A flow chart or sequence table is used to fully understand the process that needs to be controlled. It must also answer questions like the following:

What happens when electrical power and/or pneumatic air is lost? What happens when the input/output devices fail? Do we need redundancy?

This step is where you will spend most of your time. Understanding everything about the operation will save you time. It will help prevent you from continuously re-writing the PLC program logic. Knowing all these answers upfront is vital in developing the PLC program.

The sequence of operation comes down to using indirect addressing (Pointers) in the PLC.

Here is the sequence table for the robotic cell. If the input conditions are met, then the outputs are set. The following input conditions are looked at. If they are equal, then the subsequent outputs are selected. This will continually cycle through the table.

A PLC programmer must know how everything about the sequence and operation of the machine before programming.

Ask questions or view existing documentation to ensure that you know the logical steps to the machine operation.

Develop the Click PLC program: (Step 4 – Easyplc Robotic Cell)

Writing the ladder logic code for the PLC example will be the next step in our program development. We will be using the Click programming software with the Click PLUS PLC.
The Click Series will take you through installing the program, communicating to the controller instructions, and addressing the controller.

Select the Com Port under the main menu | Setup.

Select the setup on Port 1, which is the Ethernet port.

Make a note of the static IP address we are using for the Click PLC. This will be used later to connect to the EasyPLC machine simulator.
Close these windows and click on the Modbus TCP Setup.

This is located on the main menu | Setup.

The enable Modbus TCP Server is selected by default. Ensure that this is chosen so that the EasyPLC Machine Simulator can communicate to the Click PLC on the default 502 port. Select OK.

I am using the address picker to select X101. Select the display Modbus address on the bottom right-hand side. This will show you the Modbus addresses for the inputs from the EasyPLC machine simulator.

The output Modbus addresses the EasyPLC machine simulator can be seen by selecting Y101. We will need these addresses when we test our PLC ladder logic in the next step of our program development.

Our inputs for our sequence table start at address DS100. The initial value is set according to the table above. This ensures that the values entered will not be lost.

The outputs for our sequence table start at address DS200.
We are now ready to start the ladder logic programming.

The physical IO on the Click PLC will be used to start and stop the robotic cell operation. Output Y001 will indicate the run mode.

The time delay output of the sequencer is used to separate items in the list that do not have changes in the inputs from step to step. This 0.5-second timer is used to ensure that the sequence runs smoothly.

When the robotic cell is running, the sequence output indicated by the pointer will set the output bits. The pointer (DS51) will select the sequence output to use. This is done using the Copy Single and Unpack instructions.

If the robotic cell is not running, the value of 0 (off) is usually copied to the output bits. This will be done by enabling the outputs directly if they are to run or not during the stop bit. In our case, we have disabled this rung from running because we want to be able to jog through the outputs.

The bits that are not allowed to run during the jog sequence will have the robotic cell run bit in front of the output like the advanced conveyors’ output. The bits that create the pallet and engine will keep the same status when the robotic cell run bit is on or off.

The input bits are set to consecutive C memory bit locations.

The inputs are copied to the sequence input word address using the Copy Pack Bits instruction. The order of the bits in the pack instruction is the same as the sequence table above. Copy single instruction is used to copy the input pointer (DS50) to the input word indirect. This can then be used for our comparisons.

When the robotic cell runs, the sequence input word is compared to the sequence table with the pointer. If the robotic cell is not running, the jog robotic sequence bit will increase the pointers. If the two are the same, the input and output pointers are incremented by 1, so the following output sequence is set.

When the input pointer is more significant than 106 (6 steps), the input pointer is reset back to 100. The output pointer will be also reset to 200. This will also reset with the first scan bit in the PLC or the reset sequence input.
Save and transfer the PLC program to the simulator. Ensure that the PLC is in Run mode.
Watch the video below to see this PLC program in action

Test the program: (Step 5 – Easyplc Robotic Cell)

We will be using Modbus TCP on our Click PLUS PLC to communicate to the EasyPLC Machine Simulator.
Call up the engine loading machine simulator in start mode.

The status of the machine simulator will be along the bottom of the screen. Currently, we have no PLC connected. Select IO Drivers on the bottom middle of the screen.

The EasyPLC driver is selected by default. Under the driver pull-down menu, select “ModBusDriver.” This driver will communicate Modbus TCP (Ethernet) and Modbus RTU (Serial). Select the down arrow on the driver’s name.

Select the configure button.

We can now enter the information for our Modbus driver. Select TCP/IP. This means the Ethernet port on the computer will communicate to the PLC.
The digital inputs from MS to the Productivity PLC will start at address 8225.  Due to the offset of 1, this will start at address 8224. Digital outputs from MS to the Productivity PLC will begin at address 33. This will start at address 32 due to the offset of 1. Select the OK button.

You will now see the inputs and outputs specified for the Modbus driver. We can now manually assign the driver outputs to the PLC inputs and the driver inputs to the PLC outputs. However, the automatic assignment works well and will save you time.
Select Automatic Assignment from the driver option in the main menu.

This will automatically assign the PLC IO to the Machine Simulator IO. Select start driver and exit from the main menu.

On the bottom left side of the window, you will see that the driver is communicating to the PLC by the green light. Select view IO to know the input and output status of the machine simulator.

Ensure that the PLC is in run mode. We can see the operation of our industrial process mixer. Select the start from the PLC simulator input card.

The digital inputs and outputs of the MS will correspond to the PLC controller.
Using Machine Simulator (MS) to test the program will ensure that our program works.

Using the Data View window of the Click programming software, we can also watch the inputs and output operations.

Watch the video below to see this operation.

Download the Click PLC sample program and sequence table here.

Watch the video below to see the five steps of program development applied to the engine loading robotic cell. The machine simulator is one of the best applications to help you learn PLC programming.

EasyPLC Software Suite is a complete PLC, HMI, and Machine Simulator Software package. This PLC learning package includes the following:
Easy PLC – PLC Simulation that will allow programming in Ladder, Grafcet, Logic Blocks, or Script.
HMI System – Easily create a visual human-machine interface (HMI)
Machine Simulator – A virtual 3D world with real-time graphics and physical properties. PLC programs can be tested using the EasyPLC or through other interfaces. (Modbus RTU, TCP, etc.)
Machine Simulator Lite – Designed to run on Android Devices.
Machine Simulator VR – Virtual Reality comes to life so you can test, train or practice your PLC programming.

Purchase your copy of this learning package for less than $75 for a single computer install or less than $100 to allow different computers.
Receive 10% off the price by typing in ACC in the comment section when you order. http://www.nirtec.com/index.php/purchase-price/
Learn PLC programming the easy way. Invest in yourself today.

Watch on YouTube: EasyPLC Simulator Robotic Cell Click PLC
If you have any questions or need further information, please contact me.
Thank you,

If you’re like most of my readers, you’re committed to learning about technology. Numbering systems used in PLCs are not challenging to learn and understand. We will walk through the numbering systems used in PLCs. This includes Bits, Decimal, Hexadecimal, ASCII, and Floating Point.

To get this free article, subscribe to my free email newsletter.

Use the information to inform other people how numbering systems work. Sign up now.

The ‘Robust Data Logging for Free’ eBook is also available for free download. The link is included when you subscribe to ACC Automation.

Leave a Reply

Your email address will not be published.

Currently you have JavaScript disabled. In order to post comments, please make sure JavaScript and Cookies are enabled, and reload the page. Click here for instructions on how to enable JavaScript in your browser.