Getting Started:
From the Main Menu screen of
the PSIM program, select the I/O simulation display.
The I/O Simulator:
The I/O (Input/Output) simulation screen shown above
should now be displayed on the display.
Using The I/O simulator
The I/O simulator allows you to change the state of the switches
connected to the Input Card of
our simple PLC. The windows in the centre of the display allow us
to monitor the state of the PLC's Data Table. Although all PLCs
store this data as ones and zeros, our simulator substitutes a
period in place of any zero in order to make the display easier
to read. In addition, we can have the simulator alternatively
display this information in both decimal and hexadecimal format
by pressing the [F3] "Toggle Radix" function key.
- [F1] Toggle Switch State
You can control the state of the switches connected to Input
Card of our simple PLC by pressing the F1 function key.
To select which switch is to be toggled, first use the Up
and Down arrow keys on the keyboard to move the cursor
focus to the desired switch.
- [F2] Toggle Tables
When you first enter the I/O
simulation, the upper data window displays the Output
image words of our simple PLC. The lower window displays
the Input Image words. The [F2] key allows you to display
other areas of PLC's data table such as those areas used
by timers and counters etc. For this exercise however, we
only wish to view the Input and Output section of the
Data Table. Each time you press this key another view of
the PLC's data table will be shown. If you keep pressing
this key you will eventually return to the original
Input/Output display.
- [F3] Toggle Radix
Pressing the Toggle Radix function
key toggles between Binary and Decimal/ Hexadecimal
display of Data Table information.
- [F5] Rung Edit
Pressing this key takes you to the
Ladder Rung Program Editor. We will use this shortly to
enter our first practice program.
- [F6] Exit (Esc)
Pressing F6 or the
Esc key will return you to the PSIM Main Menu display.
Entering The Rung Editor
From the I/O simulator screen select the Rung Edit function [F5]
The Rung Editor Screen shown below should now be displayed on your
Computer.

- The Editor is displaying a
single rung which marks the end of the program. This rung
is present in every program and is included in the count
of the program rungs. Thus an empty program will still
have a rung count of one.
- Note the Function Key Menu
along the Bottom of the screen. For most operations you
will be required to press the corresponding Function Key
on your Keyboard in order to invoke the specified
operation which is described by this and other Function
Key Menus.
Entering a Rung
Ensure that you are in the Rung Editor

Enter the above program by following these steps:
Note
- All keystrokes that you are
required to enter are shown in square brackets [ ].
- Ensure that the NumLock light
is on if using the numeric keypad for numbers.
- Insert a Rung into your empty
program by pressing the F2 function key
- Select the XIC (Examine-On)
instruction by pressing F1.
- Now enter the address of the
first toggle switch by entering [ I 1 0 0 ] followed by
pressing the Return or Enter Key.
Note: The backspace key (the left
arrow key above the Enter key) may be used to delete
incorrect entries prior to pressing Enter.
- Next, press the F8 (Output
Instructions) which will display a new menu at the bottom
of the screen.
- Select the OTE (Output
Energize) instruction by pressing the F1 function key.
- Now enter the address of the
first simulator Light. [ O 1 0 0 ] followed by the Enter
key.
- The rung should now be
complete and a second rung will have been started. Exit
from the insert mode by pressing the F10 (Exit) key or
the Esc key.
- You can now test your program
by exiting the editor (F10 or Esc). When you exit back to
the I/O simulation display the PLC is automatically
placed in the RUN mode.
- Toggle the switch several
times and observe the operation of your program. Light 00
should light whenever switch 00 is true (closed).
Adding a Rung
From the I/O simulator screen select the Rung Edit function.

Modify your program by adding a second rung as shown above.
- Append a second Rung to your program by pressing the
F1 function key
Note: "Insert
Rung" adds a rung above the rung the cursor is on.
"Append Rung"
adds a rung below the rung the cursor is on.
- Select the XIC instruction
and enter the address [ I 1 0 1 ] followed by Enter.
- Now press F1 again to enter
the second XIC instruction and enter its address. [ I 1 0
6 ] followed by Enter.
- Press the F8 function key to
display the Output Instructions menu.
- Select the OTE instruction
and enter its address. [ O 1 0 1 ]
- Finally exit the insert mode
of the editor and then the editor itself by pressing the
F10 twice in a row.
- Test your program by toggling
switch 01 and 06 to different states. Light 01 should
light only when both input 01 and 06 are true (closed).
A Branch within a Rung
From the I/O simulator screen select the Rung Edit function

Modify your program by adding the
above rung to the Top of your program.
- Using the arrow keys, move
the cursor to the first rung of your program. Insert a
Rung above this first rung by pressing the Insert (above)
rung key F2.
- Press the Branch Start Key
F3.
- Press the XIC key and enter
the address [ I 1 0 0 ].
- Press F1 again to enter the
second XIC instruction. Enter its address.[ I 1 0 2 ]
- Press the F3 (Branch Start)
key a second time. The cursor should now be on the branch
below the first XIC instruction.
- Enter the 3rd XIC instruction
and address. [ I 1 0 3 ]
- Now press F4 (Branch Close)
to complete the branch.
- Select the output menu and
enter the OTE instruction and address. [ O 1 0 2 ]
- Return to the I/O simulator
and test the operation of your program.
Saving and Retrieving a Program
- From the I/O simulator screen
select the Rung Edit function
- While in the Rung-Editor we
will use the Program Utility function to save and later
retrieve a program to and from the computer's Disk Drive.
- Select the Program Utility
function by pressing the F7 function key.
- The Program Utility's
function key Menu shown below, should now be displayed at
the bottom of your computer's screen.

- Press the [F1] function key
to Save your program to Disk.
- When you press the F1 key,
the Disk activity light should illuminate briefly as the
computer writes your program to the disk. When complete
the computer will then replace the Program Utility
Function Key Menu with the normal Menu.
- If you missed seeing the
activity light, enter the program utility again and
repeat the program save operation.
- Press the F8 (Clear Memory)
function key to erase your current program.
- We have now erased the
program from the memory of the computer. Our program
however is safe on the computer's Disk and we can
retrieve it at will by using the Load Program utility
function.
- Select the Program Utility
function and then retrieve your program by pressing the
F2 (Load Program) function key.
Modifying Instructions Within a Rung
Ensure that you are in the Rung Editor and your program is
displayed on the computer's screen.

Using the arrow keys, ensure that the cursor is positioned on the
first instruction of the above rung.
- With the cursor on the above
rung, press the F3 (Modify Rung) function key.
You should now be in the Modify
Rung mode and able to place the cursor over any of the
instructions on the selected rung using the left and
right arrow keys. A new function key Menu should be in
place and the current instruction and its address as
denoted by the cursor should be displayed on the command
line at the bottom of the screen.
- Using the right arrow key,
move the cursor to the XIC I:103 instruction located on
the lower branch of the rung.
- Press the F1 (Insert
Instruction) function key selection.
- Press the XIC key and enter
the address [ I 1 0 0 ].
- Using the arrow keys, place
the cursor over the OTE O:1/02 output instruction.
- Press the F4 (Modify
Instruction) function key.
- Select the OTE instruction
from the Output instructions menu and enter the new
address [ O 1 0 7 ].
Your program should now look like the following:

Now return to the I/O simulator and test the operation
of your program.
Practice Exercises
Enter the Rung Editor from the I/O
simulator and erase your current program.
- Enter and test out the
operation of the following program rung which emulates
the operation of a typical Stop/Start motor control
circuit.

- Add a rung which will turn on
light O:101 whenever light O:100 is off. When you have
completed testing this new rung, print a diagram of it on
the back of this page.
- Add a rung which will turn on
light O:102 whenever light 0:100 is on and switch I:105
is momentarily pressed. List the rung on the back of this page.
- Using an output latch
instruction (OTL), add a rung which will latch on light
O:103 whenever switch I:107 is on and either switch I:103
or switch I:104 are momentarily pressed. Also add a rung
to unlatch light O:103 when switch I:105 is pressed. List
these 2 rungs.
- Erase your program from memory.
- Create, enter and test a
program which will emulate the common wiring function of
controlling a single light from two different locations.
Light O:100 should change state whenever switch I:100 or
switch I:101 change state. List your program.
Optional Exercises
Enter the Rung Editor from the I/O
simulator and erase your current program.
- Create, enter and test a
program which will change the state of light O:101
whenever switch I:104 or switch I:105 is momentarily
pressed and then released.
- Create, enter and test a
program which uses a single switch (I:102) to control the
operation of 3 lights (O:100,O:101,O:102) using the
following sequence of steps.
Step#
- when switch I:102 is
first pressed, the first light O:100 will turn on and
remain on when the switch is released.
- when switch I:102 is
pressed for the second time, the first light O:100
will turn off and the second light O:101 will turn on
and remain on when the switch is released.
- when the switch is
pressed for the third time, the second light O:101
will turn off and the third light O:102 will turn on
and remain on when the switch is released.
- when the switch is
pressed for the 4th. time, the third light O:102 will
turn off and the first light (O:100) will turn on and
remain on when the switch is released.
- The sequence now
continues at Step #2 above.