Tag Archives: programmable logic controller tutorial

One of the features of the BRX Series PLC is the ability to expand its capability to fit your application. This is easily done by “snap-on” modules that will fit on the side of the BRX MPU (Multi Processor Unit). As we have seen before in the BRX PLC System Configuration post we can add additional discrete inputs and outputs. Automation Direct now offers Analog Voltage and Analog Current input and output modules. These modules come as an 8 point channel unit. There is also a 4 point thermocouple input module also available. We will be configuring, scaling and programming the Analog input and output Voltage modules for our BRX PLC. Let’s get started. Continue Reading!

Advanced HMI is a powerful, adaptable HMI/SCADA (Supervisory Control and Data Acquisition) development package that takes advantage of Visual Studio. There is no coding required and you can simply drag and drop items onto the page. The best thing is that the software is free. We will look at using AdvancedHMI with the BRX Series PLC.
Our sample BRX PLC program will display a digital panel meter and a gauge of a value in the PLC. Stop and start momentary pushbuttons on the HMI will allow this number to increase or stop. An indication will turn green when the number is increasing and red when it has stopped. The AdvancedHMI package will communicate Modbus TCP over Ethernet to the BRX PLC. We will be able to monitor our process via the AdvancedHMI window. Lets get started. Watch on YouTube…Continue Reading!

Compare instruction are often used in PLC programs to test pairs of values. The output of this comparison conditions the logical continuity of a rung. The BRX series of programmable logic controllers has the following compare contact instructions.
= (if Equal contact)
<> (if Not Equal contact)
> (if Greater Than contact)
>= (if Greater Than or Equal contact)
< (if Less Than contact)
<= (if Less Than or Equal contact)
Besides these instruction the BRX PLC will also have compare instructions for the built in real time clock of the system. We will be looking at these instructions along with some programming examples. As a system integrator, this ability can prove very useful to you in the field when commissioning your automation system.
Lets get started with the BRX PLC Compare Instructions. Continue Reading!

The BRX PLC like all of the PLCs in the Do-More Series use strong data typing. This means that there are fixed memory structures to work with in your program. Errors will be displayed if you try to put the wrong type of value in the memory location. The data structures will automatically assist you in your automation system.
Memory can now be as flexible as you want and need. You can define and allocate all the data memory the way you want it up to specific maximums. As a system integrator you determine what best fits your automation framework.
We will be looking at the addressing and numbering systems in the BRX Series PLC. Let’s get started. Continue Reading!

We will now use the Do-More Designer software to establish communication with the BRX PLC. This is the same software that we used in the Learn PLC Programming Fee Video Series. Using the Do-More Designer software, we will communicate via USB, RS485 and Ethernet. These three methods will allow us to communicate to our BRX PLC in order to program or troubleshoot this controller. Once we have established communication we will then look at updating the firmware in our controller. Let’s get started. Continue Reading!

Previously we used VB6 (Visual Basic 6) to implement the Omron Host Link Protocol to communicate to our programmable logic controller. (PLC) In part 2 we used Visual Basic for Applications (VBA) to accomplish our host link serial communication. We will now look at using VB.Net to establish and retrieve information in and out of the PLC using host link. (C mode commands)

Hostlink communication protocol is a method developed by Omron for communication to PLC’s and other equipment. This ASCII based protocol is used over RS232 or RS422/RS485. It is a many to one implementation which means that you can communicate with up to 32 devices back to a master. (1:N) This communication on the industrial floor can control PLC’s, Temperature Controllers, Panel Meters, etc.

The Omron CP1H plc will be used with a CP1W-CIF11 (RS485) communication serial link adapter. We will also use a USB-485M Universal Serial Bus to RS485 adapter from automation direct. The video at the end of this post will demonstrate the communications by reading 10 registers form the DM area of the PLC. Continue Reading!

When I was in school PLC’s were just in their infancy. We were taught that the PLC consisted of the central processing unit (CPU), analog and digital inputs and outputs. Everything was programmed with dedicated handheld devices and/or software devices on specialized hardware. We now have modern PLC systems that are capable of so much more. Let’s look at how we can now break up these modern PLC system into the seven essential components.

Understanding how the PLC will scan and update your program is critical in programming and troubleshooting your system. Typically a PLC will solve your logic from left to right, top to bottom. The status of the memory from the previous rung, are available for the next rung to use. We will look at a few examples to determine how the PLC will solve logic to illustrate the above program scanning. Keep on Reading!

We will continue the series by looking at a sequencer controlling seven cylinders that can be taught. The cylinders can be operator programmed from the AdvancedHMI screen. You will be able to select what cylinders to activate at each step and program in 500 steps. Our PLC will be the Do-More from Automation Direct.

Here is a quick review of the programming series so far. If you are new to the site, we recommend reviewing the other parts in the series first.
In part 1 we looked at writing PLC programs to control a traffic light using discrete bits and then using timed sequencing using indirect addressing.Part 2 used indirect addressing for inputs as well as output to control the sequence of pneumatic (air) cylinders in the program. Part 3 and 4 we returned to the traffic light application and expand our program significantly. We looked at the sequence of operation using Input, output and mask tables.
In part 5 we used the AdvancedHMI software to create the game of Simon. A round in the game consists of the device lighting up one or more buttons in a random order, after which the player must reproduce that order by pressing the buttons. As the game progresses, the number of buttons to be pressed increases.

We will be using AdvancedHMI to communicate Modbus TCP to the Automation Direct Do-More Designer Software Simulator. The following is the sequence of operation:Watch on YouTube : Running the Cylinder Sequence (PLC / HMI)
Note: All of the programs used are provided free of charge and are an excellent way to learn PLC / HMI programming.

The following table is the Modbus TCP memory map to the Do-More PLC:

Coil/Register Numbers

Data Addresses

Type

Do-More PLC

Table Name

00001-09999

0000 to 270E

Read-Write

MC1 to MC1023

Discrete Output Coils

10001-19999

0000 to 270E

Read-Only

MI1 to MI1023

Discrete Input Contacts

30001-39999

0000 to 270E

Read-Only

MIR1 to MIR2047

Analog Input Registers

40001-49999

0000 to 270E

Read-Write

MHR1 to MHR2047

Analog Output Holding Registers

Here are the inputs and outputs we will be using for our program:

Device

Data Addresses

Type

Do-More PLC

Description

Start Pushbutton

00011

Input

MC11

Stop Pushbutton

00012

Input

MC12

Jog Pushbutton

00013

Input

MC13

Reset Pushbutton

00014

Input

MC14

Run/ Jog Selector

00008 / 00015

Input/ Output

MC8 / MC15

MC8 is the value and MC15 is the click

Light Stack

00010 / 00009 / 00008

Output

MC10 / MC9 / MC8

Red / Green / Amber

Set Pushbutton

00071

Input

MC71

Jog / Teach Selector

00070

Input

MC70

MC70 on is teach mode

Sequence Step (Panel Meter)

40001

Output

MHR1

Current step in the sequence

Inputs Actual

40002

Input

MHR2

Show the actual inputs in binary format

Output Sequence

40003

Output

MHR3

Show the actual outputs in a binary format

Input Sequence

40004

Input

MHR4

Show the input sequence bits in a binary format

Cylinder 1 to 7 – value

00001 to 00007

Output

MC1 to MC7

Determine if cylinder is on/off

Cylinder 1 to 7 – set (click)

00041 to 00047

Input

MC41 to MC47

Set the cylinder button

Cylinder 1 to 7 – retract indicators

00021 to 00027

Input

MC21 to MC27

Indicate cylinder has retracted

Cylinder 1 to 7 – extend indicators

00031 to 00037

Input

MC31 to MC37

Indicate cylinder has extended

Cylinder 1 to 7 – extend / retract error indicators

00050 to 00063

Output

MC50 to MC63

Indicate cylinder input error when jogging

The first thing we will do is design the HMI. We have three main areas on the screen. Basic Controls, Cylinder Visualization and the Sequence Step/Teach area. Please refer to the above reference chart for the inputs and outputs programmed on the screen.

Basic Controls:
This area will allow us to see what mode we are in via the stack light. Red – Stop
Yellow – Jog / Teach Mode – Troubleshooting
Green – Run

Cylinder Visualization:
Each cylinder will have indication lights to determine status of the cylinder. (Extended / Retracted)
The cylinder will also have red indication lights to reflect the differences between the current sequence and the next sequence step. This is visible when we are in jog mode.

Sequence Step/Teach:
When in jog or teach mode the sequence step is visible, which indicates the current step that we are on. The inputs and outputs are displayed as a binary value which represents the actual inputs and outputs. This is valuable when troubleshooting and finding errors in the system. The set button is visible when in teach mode. When pushed the outputs and inputs are set for that step and the sequence will then increment.

The following is the code for each of the words that the DataScribers are reading. This includes the code to change the word into a 16 bit binary value.

If you’re like most of my readers, you’re committed to learning about technology. Numbering systems used in PLC’s are not difficult 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.

First Name:Last Name:Email address:

Leave this field empty if you're human:

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

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