0:01
learn PLC programming the easy way with
0:04
xg5000 instruction list simulator we'll
0:07
show you how to simplify your PLC
0:09
programming tasks and increase
0:10
productivity the xg5000 simulator is
0:13
part of the xg5000 PLC programming
0:15
software this powerful completely free
0:18
tool allows you to test and debug your
0:20
PLC programs in a virtual environment
0:22
without physical Hardware with its
0:24
user-friendly interface and realistic
0:26
simulation we'll be able to learn PLC
0:28
programming Concepts quickly and easily
0:30
whether you're a beginner or an advanced
0:32
programmer this will guide you through
0:33
the basics of PLC programming using the
0:35
xg5000 IL simulator so if you want to
0:39
take your PLC programming skills to the
0:41
next level let's start and simulate our
0:44
success detailed information contained
0:46
in this video can be found at ACC
1:00
what is ilil instruction list PLC
1:06
programming instruction list is one of
1:08
the five standard PLC programming
1:09
languages defined by the IEC 61131-3
1:13
standard although ilil programming is
1:16
regarded as the least popular
1:17
programming language this may change
1:19
based on regenerative artificial
1:20
intelligence or AI instruction list IL
1:24
programming is text-based programming
1:26
language similar to assembly code I can
1:29
execute quickly make making it suitable
1:30
for time critical applications and where
1:32
compact code is required using AI we
1:35
will create a standard stop start
1:44
project run the xg5000 programming
1:47
software for the ls electric PLC
1:49
controllers under the main menu project
1:51
select new project this can also be
1:53
selected using the shortcut key
1:55
combination of control+ n there's also a
1:58
new project icon on the main screen
2:00
the new project window will now be
2:02
displayed give the project a name the
2:05
directory where this program can be
2:07
stored will can also be set under the
2:10
PLC selection select the PLC that we
2:12
will be programming the CPU series is an
2:19
dxxx H2 and we will leave the default
2:22
name as LS PLC under the programming
2:25
heading we will name the iil program and
2:28
select I IEC as the programming language
2:32
a project description can also be put in
2:34
to the new project window to document
2:36
what we were trying to
2:40
okay the new program that we named will
2:43
now be displayed this is where we will
2:44
program our instruction list IL code if
2:47
we expand the program name under the
2:49
project window you can see the local
2:52
list IL programming commands can be seen
2:55
in The Help menu of the xg5000
2:57
programming software we did a summary of
2:59
these commands in our post xgb PLC
3:01
instruction list first AI
3:05
program note as we program ensure that
3:08
you select save often this can be done
3:10
with the main page icon or main menu
3:16
save using artificial intelligence AI
3:19
for ilil PLC instruction list
3:23
code since I is a text based language
3:26
that follows rules and guidelines it is
3:28
an ideal candidate for machine learning
3:30
algorithms chat GPT is a powerful AI
3:33
tool that can generate code in I for our
3:37
circuit select the reason option in our
3:40
AI interface this will allow us to
3:42
understand the logic behind our
3:44
answer as chat gbt2 create a motor
3:48
control program using IL programming a
3:50
momentary normally open push button will
3:52
latch the motor output a momentary
3:55
normally closed stop push button will
4:00
the user is asking to create a motor
4:01
control program using IL programming we
4:03
want the start push button to latch the
4:04
motor on and stop it with the stop push
4:06
button which is momentary and normally
4:07
closed in iil the logic is simple if the
4:09
stop button is pressed the motor turns
4:10
off if the start button is pressed the
4:12
motor activates and stays latched until
4:13
the stop I'll need to focus on how to
4:15
implement this in the I language I'm
4:16
thinking of using a latch coil or a rung
4:18
with latching Logic for the motor
4:19
control the I code could look something
4:20
like this thinking through the motor
4:22
control structure we want the start
4:24
button to latch the motor on until the
4:25
stop button is pressed this typical
4:26
setup involves a combination of normally
4:27
open and normally closed contacts which
4:29
we can can Implement an I using
4:30
instructions like LD and and or I'm now
4:32
focusing on the correct IL code for
4:34
motor controller Behavior here's what
4:35
I've come up with this reflects the
4:37
desired logic first evaluate icore start
4:39
or M then in it with I underscore stop
4:41
and finally store the result to M this
4:42
ensures that m is latched correctly and
4:44
the motor will stop if the stop button
4:45
is pressed regardless of any prior state
4:47
after my tests this approach avoids The
4:48
Unwanted behavior of leaving the motor
4:49
running below is one acceptable solution
4:52
in I in this example icore start is the
4:54
input from the momentary normally open
4:56
start push button icore stop is the
4:58
input from the momentary normally closed
4:59
stop push button it is true when not
5:01
pressed qcore motor is the motor output
5:03
the logic is the motor will be energized
5:05
if icore start is pressed or if it is
5:07
already on latching but only if icore
5:09
stop is not pressed when icore stop is
5:11
pressed I becomes false the output is
5:13
deenergized explanation LD icore start
5:16
loads the value of the start button when
5:18
the button is pressed icore start
5:19
becomes true or qcore motor combines the
5:22
start button with the current state of
5:23
the motor output this latches the motor
5:25
so that once it's on it stays on and
5:26
iore stop the result is handied with a
5:28
stop button status since iore stop is
5:30
normally true it will only be false and
5:32
thus to energize the motor when the stop
5:34
push button is pressed sdq motor the
5:36
final result is storing qore motor this
5:38
means the motor will be on if either the
5:40
start was pressed or it is already
5:41
running and the stop button has not been
5:43
pressed this iil code achieves the
5:44
desired motor Control
5:46
Function chat GPT did a good job we can
5:49
now copy this I program and paste it
5:51
into the coding Block in our xg5000
5:54
programming software you will see that
5:56
every instruction in the program is
5:58
documented this ensures that that we
6:00
understand what the code is trying to
6:03
accomplish create the variable
6:08
list we have the instruction list code
6:10
but now have not defined the variables
6:12
we will be using under the project
6:14
window in the lslc double click local
6:17
variables this will call up our local
6:18
variables window in our program we can
6:21
now enter the variables that AI has
6:23
generated for our iil PLC code copy the
6:27
start stop and motor ver variables into
6:30
the variable chart all of these
6:32
variables are Boolean this means that
6:34
they are either on or off one or zero or
6:50
false save the program
7:04
simulator the PLC simulator can be
7:07
started by selecting the start stop
7:08
simulator icon on the main menu this can
7:11
also be started by the main menu tool
7:13
start Simulator the XG Sim window will
7:16
represent the ls electric PLC we choose
7:20
program our xg5000 PLC software will be
7:24
shown with a communication to the
7:25
simulator this is the red bar at the
7:27
bottom of the xg5000 programming s
7:29
software the right to PLC window will
7:32
automatically be displayed xg5000
7:34
software treats the simulator like a PLC
7:36
controller and you must establish
7:38
communication and transfer the program
7:40
we will leave all the default settings
7:46
okay our instruction list IL start stop
7:48
circuit will be loaded into the PLC
7:51
Simulator the xg5000 right complete
7:54
message will be displayed select
7:57
okay the PLC simulator will be placed
7:59
automatically in run mode this is
8:01
indicated by the green bar at the bottom
8:03
of the xg5000 software close this check
8:06
program window by selecting the X on the
8:09
corner our program is now being executed
8:12
in the simulator we can change the font
8:15
size of the text on the screen by using
8:16
the zoom in and out on the main menu you
8:20
can also start stop the scan of the
8:22
program in a simulator by using the
8:25
menu if you are enjoying this video
8:27
please hit the like button below keeping
8:29
up with all the latest automation
8:31
Innovations can be difficult so hit the
8:33
Subscribe button remember to click the
8:35
Bell beside your subscription to
8:37
actually to receive those
8:41
notifications monitoring and testing the
8:48
code we can use the PLC simulator's
8:51
monitoring and troubleshooting tools to
8:52
observe the behavior of our ilil PLC
8:55
program the monitor icon is
8:57
automatically turned on when you use the
9:00
simulator we can display the inputs and
9:02
outputs we want to monitor using the
9:03
monitoring Windows selecting the IL code
9:06
or variables is an easy way to add the
9:08
variables to the monitor list once the
9:11
variables or code or highlighted select
9:13
add from the main menu monitor add to
9:17
monitor this can also be done by right
9:19
clicking on the highlighted variables or
9:21
code selecting add the variable Monitor
9:24
and then choosing the monitor number our
9:26
selected variables will now be displayed
9:28
on the monitor number
9:31
we can change the input variables and
9:33
observe our program Behavior by double
9:37
them adjustments can be made in the
9:40
program using xg5000 when issues or
9:42
errors are discovered we can create and
9:44
save the necessary changes to our IL
9:46
programming code offline or online and
9:53
again using the PLC simulator in the
9:56
xg5000 programming software for
9:57
instruction list IL effectively test and
10:00
debug PLC programs without physical
10:03
Hardware this provides a safe and
10:05
efficient environment to validate your
10:06
logic and ensure proper operation before
10:08
deploying it into the real world
10:10
applications by following steps outlined
10:13
you can harness the power of the PLC
10:15
simulator by streamlining your
10:16
development process and deliver reliable
10:20
programs now that you know more about
10:22
the xg5000 PLC Simulator for I
10:25
programming click here to learn more
10:27
about entering and modifying your I code
10:29
code to see all the posts and videos for
10:32
the xgb PLC click here