Category Archives: systems

Here is a Method That is Helping PLC Programmers to Program Faster

PLC programming involves both direct and indirect addressing. Direct address programming involves writing each ladder logic rung to do the operation required. We often forget about using the powerful indirect addressing to solve our logic.

The below animated picture will show a simple example of using indirect addressing. This will use the MOVE instruction and transfer a word indirectly to output word V100. V[V0] means that the value in V0 will point to the V memory to get the value to move. You can think of this as a pointer for the memory location to move.

Of course we need to monitor V0. Our values are in sequence from V1 to V6. We need to ensure that V0 is always in the range from 1 to 6.

Lets take a look at a program sample using the Do-more Designer Software. We will set up the sequence similar to the animation above, but expand the program.
Just like above we will set up the pointer at V0 and the output at V100 memory locations. V1 to V37 will hold our output data sequence. This is outputs that we want to set on each event and/or time frame. You can see some of the registers and the corresponding values. These are set as a hexadecimal value. The following link will provide a review of the numbering systems in the PLC. (WHAT EVERYBODY OUGHT TO KNOW ABOUT PLC (PROGRAMMABLE LOGIC CONTROLLER) NUMBERING SYSTEMS)

This is the logic to set up the move instruction. The source is V[V0] which means the pointer is V0 in this memory area. The destination will be V100.

An internal timing bit ST5($100ms) is used to increment the pointer V0. This could also be done by an event or series of events. The pointer is then compared to ensure that it is between 1 and 37.

Finally the output word is then transferred to the physical outputs. This is done by using the MAPIO instruction. Each bit can be set independently.

p

This example uses indirect addressing to program a sequence based upon time. We could just as easily used indirect addressing to compare inputs to a table and set the outputs accordingly. You can see how this method can greatly reduce the amount of time to develop your program. This holds especially true if the sequence needs to be changed. It would be just a matter of changing data values in the table.

The following are separate posts that use indirect addressing:

Building a PLC Program You Can Be Proud Of – Part 1
This use the control of an intersection traffic light to demonstrate direct versus indirect addressing.

Building a PLC Program That You Can Be Proud Of – Part 2
A sample program to control valves. This uses indirect addressing for the inputs as well as the outputs.

Now You Can Have Robust Data Logging for Free – Part 1
Using indirect addressing, this sample program will log information in the PLC to be retrieved at a later time.

Indirect addressing is a powerful method of programming to simplify and program faster than you ever thought possible. You can even use indirect addressing in the PLC to scale a non-linear analog input signal. Let me know you thoughts on using indirect addressing. What can you come up with?

Watch on YouTube : Here is a Method That is Helping PLC Programmers to Program Faster

If you have any questions or need further information please contact me.
Thank you,
Garry



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.


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.

Looking For Production Improvements – Then Do A Gemba Walk!

I recently went for a Gemba Walk with Ann Machan,  General Manager of Pentair. Instead of doing normal daily production meetings, their walk does everything you can do in a boardroom, plus so much more.

What is a Gemba Walk?
http://www.gembawalk.com/the-gemba-walk/

We met in her office and were explained the KPI (Key Performance Indicators) for the operation of the plant.  Each of these KPI’s are posted at each department where the work happens and are on a large white board.

The walk each morning starts at the shipping office with the rest of the staff. The operator in shipping  discusses how their department has done in the last 24 hours in relation to the KPI. Questions are raised about the next 24 hours and possible issues. Before we leave this department Ann asks a few personal questions to the shipper. He answers and they start to laugh. It is obvious that they have a good relationship in which information can flow freely.

Splitting up the group into three different teams to cover the entire plant, the walk continues. We went to three additional departments where again we were shown the KPIs and how they related to the department. Notes were taken and questions asked about possible issues and current problems. Information was exchanged from the previous days problem with the solution for one that was to be implemented that afternoon.

We assembled back all together in a central location in the plant. A large board with people’s names (Responsible for Department) was listed on the left side and twenty one numbers were written on the top representing three weeks. The current week that they were on, followed by the next two weeks. This grid pattern was where they then discussed the walk and the issues raised. To the right of the board a chart was placed. This chart contained the total number of problems/issues solved for each department and total company. A graph was also displayed showing the growing trend. Underneath this chart were the KPI charts that all showed either sustained or improved performance.

We started with the previous days issues under yesterdays date. A status update was given and the posted note was moved to either the completion clip at the side or put under a future date. When this was complete, a representative of each of the three groups when through their list of issues. These were then assigned and placed on the board. Problems that required additional investigation were discussed briefly and then the 5 why process was assigned to the person who had the greatest knowledge.

This whole process took about one hour. The Gemba walk accomplished the following:

  • Everyone’s understanding on the current company situation based upon the KPIs
  • Everyone knowing exactly what is expected
  • Everyone taking pride and knowing they are doing a good job
  • Everyone knowing someone is there to help

I found the whole experience of the Gemba walk fascinating. It is the only way that I see that you can have clear lines of communication to all staff. The way in which to grow as a company is to learn from our workers and in turn we will teach them.  It was an opportunity to:

  • See the work being done
  • Experiment with ideas
  • Learn from all parties involved
  • Explain why things are this / that way
  • Watch what is being done

Take your own Gemba walk on your production floor. Let me know how it turns out.

If you have any questions or need further information please contact me.
Thank you,
Garry



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.


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.

Lubrication basics

I recently went to a seminar on lubrication basics. This was presented by Mike Deckert of Flo Components Ltd.

So why talk about lubrication on a industrial automation website? Lubrication is vital in maintaining uptime on equipment. It is often thought of near the end of most automation projects, but it should be a principle component of all projects. If a piece of equipment moves, it will probably need lubrication. We often talk about MTBF (Mean Time Before Failure) on equipment. MTBF will be very low if lubrication is neglected.

In a study conducted by a major component manufacturer, over 50% of failures are the result of improper lubrication.  (Pins and Bushing)

  • Lubrication Related Failures: 54%
    • Inadequate Lubrication – 34.4%
    • Contamination – 19.6%
  • Installation Errors – 17.7%
  • Overload – 6.9%
  • Storage and Handling Errors – 2.8%
  • Other 18.6 %

Bearings fail in a plant for many reasons. Manual lubrication is still the dominant method of lubrication for grease bearings. 95% of all bearings are manually lubed. With plant production increasing the scheduled service time between has lengthened. Maintenance staff have generally been reduced resulting in fewer people carrying out the lubrication requirements.

Lubrication has the following functions:

  • Reduce Friction
  • Reduce Wear
  • Helps Dampen Shock or Absorb Shock
  • Reduce Temperature
  • Minimize Corrosion
  • Seal out Contaminants

Lubrication interval depends on the following:

  • Metal to metal contact area of bearing
  • Environment (Application)
  • Machine Speed
  • Operating Temperature
  • Type of Grease

Not all grease is the same. Grease is a solid or semi-solid formed when a thickening agent is dispersed in the oil base. Additives give grease their final special properties. The National Lubrication Grading Index  (NLGI) will grade the grease from 000 to 6, but this is not the whole story. Always look at the manufactures specification. Base oil viscosity can be completely different but still have the same NLGI.

Why are automatic lubrication systems better?

  • Grease evenly distributed
    • The best time to grease is when the object is in motion. This spreads the grease evenly.
  • Will not over lubricate
    • Grease is delivered by measured injection. This prevents seals from blowing out.
  • Correct amount of grease is applied
    • This will ensure the maximum life of the equipment.
  • Environmentally safe

Lubrication is a vital component to automation. MTBF can be increase if we plan on ensuring that our moving parts are well maintained.

Flo Components Ltd. is an excellent company to help you understand and maintain your systems. They have a library full of information on their website.

www.flocomponents.com/Library.htm

I encourage you to check this out and make lubrication part of your automation projects. If you have any questions, or need further information please contact me.
Thank you,
Garry



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.


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.

Adjusting Daylight Savings Time In Do-More

Adjusting for daylight saving time in Do-More PLC.

When does it start and end?
Canada Daylight Saving Time begins at 2:00 am local time on the second Sunday in March. On the first Sunday in November areas on Daylight Saving Time return to Standard Time at 2:00 am local time. When Daylight Saving Time begins turn your clocks ahead one hour. This is what happens in most parts of Canada.



There are several methods in the Do-More PLC to account for Daylight Savings Time. You can use the internet time clock, manual adjustment or use an internal bit to set daylight savings time. Since websites for internet time may not always be reliable and we do not want to wake up at 2 am in the morning to set the real time clock, we will use the internal bit method.

ST768 $SummerTime Configuration
Set this bit ON to add one hour to LocalTime to account for Daylight Savings Time.

The first line of code will check for the 3rd month (March). Then ensure that the day is between 8 and 14 so that we are viewing the second week. Next make sure the day of the week is 0 (Sunday). Finally it will check to make sure the hour is 2 (2am). The ST768 $SummerTime will then be turned on to add one hour to the real time clock in the PLC.

The second line of code will check for the 11th month (November). Then ensure that the day is less than 8 first week. Next make sure the day of the week is 0 (Sunday). Finally it will check to make sure the hour is 2 (2am). The ST768 $SummerTime will then be turned off to subtract one hour to the real time clock in the PLC.

Adding this code to your existing logging information in the PLC can be helpful when determining the correct time.

If you have any questions or need further information, please contact me.
Regards,
Garry

P.S. In the contact section, send me a email and I will send you a link for the download of this code.



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.


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.

Is Manufacturing Dead In Canada? Not so!

Everywhere you look there are signs of doom for Canadian Manufacturing. Unemployment rate, companies moving or going out of business seems to be a common theme. However we have is an increase in manufacturing output.

How is manufacturing jobs disappearing and output increasing?


Investment in the business

Take a look around. Businesses that are investing in themselves will have the staying power. Those that do not are going to be left behind, wither and die.
How is your company doing?

People
We often hear that people are the greatest asset for the business. What is the game plan? When asked to see or inquire about how they are advancing there employees; you get blank faces. A constant learning environment must be established.
The learning environment includes:

  • How individuals interact with and treat one another.
  • How information is conveyed
    • Internet
    • Intranet
    • Meetings
    • Teams
    • Postings
  • Knowledge of individual contributions
    • Strengths and Weaknesses
  • Recognize how individuals learn (Example: Millennials do not get information from an authority figure.)
    • Customize leaning for individuals

Process
Look at your process from a new born perspective. Inquire and explore why things have to happen in a certain way. Break every step down.
Kipling wrote:
I keep six honest serving men. They taught me all I knew. Their names are What and Why and When And How and Where and Who.
Query your people with questions and listen.

  • If they had more time, what would they work on?
  • What is there biggest challenge?
  • What is bugging them?
  • Are you happy?

Machine
Keep up on the latest machine innovations for your industry as well as others. Know the limitations of each machine. Table new concepts to your learning environment.
If you are to fix the machine then ask

  • Is this the first time this has happened? Will it happen again?
  • How long did it take to troubleshoot the problem?
  • Is there something we can improve upon?
  • How can this knowledge be shared with operators, maintenance, management?

Automation
There is a reason that this is last on the list. Automation can stand by itself, but it really requires an understanding of each of the items mentioned above before it is successful.
You must understand your people, process and machine before automation can prove to be an asset.

Automation, people, process and machine innovation can happen. It is up to you.

If you have any questions or need further information, please contact me.
Thank you,
Garry

Reference:
Statistics Canada for Manufacturing
http://www5.statcan.gc.ca/cansim/a33?lang=eng&spMode=mainTables&themeID=4005&RT=TABLE




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.


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.

The Secret Of Getting Rid Of Noise On Your Analog Signal

Allot of times in industrial environments we get noise on the analog signal input to PLC’s or other controllers. The noise can be generated by motors, bad wiring, etc.

Placing a 1- 100 uF capacitor on the input signal and ground (common to the cabinet)  will reduce the noise that the input is receiving.

If you have any questions or need further information please contact me.
Thank you,
Garry



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.


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.

Who Else Wants To Lean PLC Programming For Free?

I have always been an old school programmer. Hardware in front of you hooked up to all of the I/O. I have recently looked at the automation direct do-more designer software solution. The Do-More Designer Software will allow you to build your ladder logic, download into a simulator (comes with the software) and run the code. The price of all of this… FREE

I will not get into allot of details because the documention available already will get you through the software step by step.
– Download the software
– Install the software
– Use the YouTube videos for help with getting around the software and making your first program.

The following are several links to help you discover the plc programmer in you:

Automaion Direct – Do-more Programming Software
http://www.automationdirect.com/adc/Overview/Catalog/Software_Products/Programmable_Controller_Software/Do-more_PLC_Programming_Software

http://www.aboutplcs.com/do-more/software/

http://www.aboutplcs.com/do-more/software/simulator.html

The simulator has allot of great features, including PID simulation.

Do-more PLC – How to videos on youtube
https://www.youtube.com/playlist?list=PLPdypWXY_ROoJx-HnK9gj2Z5a-i7th-UK

Update: Here is a video from YouTube about the simulator basic instructions:
http://www.youtube.com/watch?v=ZnRSw3ykW6k#t=274
https://www.youtube.com/watch?v=4JiMzBHPa7E

If you have any questions or need further information please contact me.
Thank you,
Garry



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.


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.

Here’s a Quick Way to Convert Grey Code into Binary for PLC

Grey Code
Grey Code is used because only one bit of data will change at a time. The following chart shows the conversion of Grey Code to Binary.

Number Binary Code Grey Code Number Binary Code Grey Code
0 0000 0000 8 1000 1100
1 0001 0001 9 1001 1101
2 0010 0011 10 1010 1111
3 0011 0010 11 1011 1110
4 0100 0110 12 1100 1010
5 0101 0111 13 1101 1011
6 0110 0101 14 1110 1001
7 0111 0100 15 1111 1000

It is important for absolute encoders because if the power is interrupted the encoder will know where it is within the one bit.

Example:
Power is interrupted when the encoder is between 7 and 8. If we are looking at Binary Code all of the bits would be effected and we would not be sure as to what number we are looking at for the encoder. Therefore we have lost position. In Grey Code only one bit changes so we will still be able to tell if we were on 7 or 8 if the power was interrupted.

The following sample PLC program will convert 4 bit grey code into binary code.
This code was written in an Automation Direct PLC software called Do-more Designer.

Do-more Designer Software
How to use video’s for Do-more Designer Software

Contact me for the above program. I will be happy to email it to you.
Thank you,
Garry



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.


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.

What Everybody Ought to Know About PLC (Programmable Logic Controller) Numbering Systems

Programmable Logic Controllers (PLC) are the same as computers. They only understand two conditions; on and off. (1 or 0 / Hi or Low/ etc.) This is known as binary. The PLC will only understand binary but we need to display, understand and use other numbering systems to make things work. Let’s look at the following common numbering systems.

Binary has a base of two (2). Base means the number of symbols used. In binary the symbols are 1 or 0. Each binary symbol can be referred to as a bit. Putting multiple bits together will give you something that looks like this: 100101112. The 2 represents the number of symbols/binary notation. Locations of the bits will indicate weight of the number. The weight of the number is just the number to the power of the position. Positions always start at 0. The right hand bit is the ‘least significant bit’ and the left hand bit is the ‘most significant bit’.

Let’s look back at our example to determine what the value of the binary number is:
100101112 =
We start with the least significant bit and work our way to the most significant bit.
1 x 2= 1 x 1 = 1
1 x 2= 1 x 2 = 2

1 x 2= 1 x 2 x 2 = 4
0 x 2= 0 x 2 x 2 x 2 = 0
1 x 2= 1 x 2 x 2 x 2 x 2 = 16
0 x 2= 0 x 2 x 2 x 2 x 2 x 2 = 0
0 x 2= 0 x 2 x 2 x 2 x 2 x 2 x 2 = 0
1 x 2= 1 x 2 x 2 x 2 x 2 x 2 x 2 x 2 = 128
 100101112  = 1 + 2  + 4 + 16 + 128
 100101112  = 151
Note that the we just converted the binary number to our decimal numbering system. The decimal numbering system is not written with a base value of 10 because this is universally understood.
To be sure we have the concept down, let’s take a look at our decimal numbering system the same way as we did the binary.
Decimal has a base of ten (10). The symbols are 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9.
15110 =
1 x 10= 1 x 1 = 1

5 x 10= 5 x 10 = 50
1 x 10= 1 x 10 x 10 = 100
15110 = 1 + 50 + 100
151 = 151

Hexadecimal has a base of sixteen (16). The symbols are  0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E and F. Hexadecimal is used to represent binary numbers. F16 = 1111
Every for bits of binary represent one hexadecimal digit.
In our original binary number we now can convert this to hexadecimal.
100101112
The least significant four bits are:
01112 =
1 x 2= 1 x 1 = 1
1 x 2= 1 x 2 = 2

1 x 2= 1 x 2 x 2 = 4

0 x 2= 0 x 2 x 2 x 2 = 0

0111= 1 + 2 + 4 + 0 = 716
The most significant four bits are:
1001=
1 x 2= 1 x 1 = 1
0 x 2= 0 x 2 = 0
0 x 2= 0 x 2 x 2 = 0

1 x 2= 1 x 2 x 2 x 2 = 8

1001= 1 + 0 + 0 + 8 = 916
Therefore:
100101112 = 9716 
We can now convert this hexadecimal number back into decimal
9716 =

7 x 16= 7 x 1 = 7
9 x 16= 9 x 16 = 144
9716 = 7 + 144 = 151

The following chart will show all of the combinations for 4 bits (nibble) of binary. Its shows the Binary, Decimal and Hexadecimal (Hex) values. It is interesting to not that Hex is used because you still have only one digit (Place Holder) to represent the nibble of information.

Binary Decimal Hexadecimal Binary Decimal Hexadecimal
0000 00 0 1000 08 8
0001 01 1 1001 09 9
0010 02 2 1010 10 A
0011 03 3 1011 11 B
0100 04 4 1100 12 C
0101 05 5 1101 13 D
0110 06 6 1110 14 E
0111 07 7 1111 15 F
ASCII (American Standard Code for Information Interchange)
Two nibbles (8 bits of data) together form a byte. A byte is what computers (PLC) use to store and use individual information. So it will take one unique byte to represent each individual numbers, letters (upper and lower case), punctuation etc. www.AsciiTable.com
Example:
Chr ‘A’ = 4116 = 010000012
Chr ‘a’ = 6116 = 011000012
Chr ‘5’ = 3516 = 001101012
Each time you hit a key on your keyboard, the following 8 bits of data get sent.
A word is made up of two bytes, or 4 nibbles, or 16 bits of data. Words are used in the PLC for holding information. The word can also be referred to as an integer.
Long word / Double word is made up of 4 bytes, or 8 nibbles, or 32 bits of data. Long words are used for instructions in the PLC like math.
Hey what about negative numbers?
So far we have talked about unsigned words. (Positive numbers)
Signed words can hold negative numbers. Bit 15 (most significant bit) of a word is used to determine if the word is negative or not.
The following table shows you the signed vs unsigned numbers that can be represented in the PLC.
HEX
8000
BFFF
FFFE
FFFF
0000
3FFF
7FFE
7FFF
Signed
-32768
-16385
-0002
-0001
00000
16383
32766
32767
Unsigned
32768
49151
65534
65535
00000
16383
32766
32767
Memory retentiveness:
When working with PLC’s look at the memory tables to determine what will happen if power is removed from the device. Will the bits go all off or retain their prior state?
Usually there will be areas that can be used in the PLC for both conditions.
As you can see PLC numbering systems and computers are very much related and it all boils down to individual bits turning on and off. The interpretation of these bits will determine what the value will be.

Reference:
Let me know your thoughts, or questions that you have on PLC numbering systems.

Thank you,
Garry



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.


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.