<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" >

<channel><title><![CDATA[Automated Electrics - BLOG]]></title><link><![CDATA[https://www.automatedelectrics.com.au/blog]]></link><description><![CDATA[BLOG]]></description><pubDate>Sun, 13 Oct 2024 18:57:54 +1100</pubDate><generator>Weebly</generator><item><title><![CDATA[Take Your PLC Programming from a Basic Level to an Advanced Level With a Few Simple Fundamentals]]></title><link><![CDATA[https://www.automatedelectrics.com.au/blog/plc-programming-development-tips]]></link><comments><![CDATA[https://www.automatedelectrics.com.au/blog/plc-programming-development-tips#comments]]></comments><pubDate>Tue, 23 Feb 2016 02:16:18 GMT</pubDate><category><![CDATA[Programming]]></category><guid isPermaLink="false">https://www.automatedelectrics.com.au/blog/plc-programming-development-tips</guid><description><![CDATA[Share    PLC Programming Development TipsBy Automated ElectricsHelpful tips and advice for PLC programmers as well as considerations for site managers on solid PLC code development.Programming code is the invisible magic that runs our entire world. It is not only in automation equipment like PLC and SCADA systems but also the majority of electronic equipment and services we use every day including computers, phones, TV’s and even our cars.&nbsp;Coding is responsible for the clean water we drin [...] ]]></description><content:encoded><![CDATA[<div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:64.621409921671%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:35.378590078329%; padding:0 15px;"><div><div id="514100872746333646" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><p style="text-align:center;font-size:14px;color:black;">Share</p><span class='st_sharethis_large' displaytext='ShareThis'></span> <span class='st_facebook_large' displaytext='Facebook'></span> <span class='st_twitter_large' displaytext='Tweet'></span> <span class='st_linkedin_large' displaytext='LinkedIn'></span> <span class='st_googleplus_large' displaytext='Google +'></span></div></div><div class="wsite-spacer" style="height:50px;"></div></td></tr></tbody></table></div></div></div><div><div id="819233963529141912" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><div itemscope="" itemtype="https://schema.org/NewsArticle"><meta itemscope="" itemprop="mainEntityOfPage" itemtype="https://schema.org/WebPage" itemid="https://www.automatedelectrics.com.au/blog/plc-programming-development-tips"><h1 itemprop="headline"><font size="6" color="#000000" face="arial">PLC Programming Development Tips</font></h1><h3 itemprop="author" itemscope="" itemtype="https://schema.org/Person"><font size="3" style="font-weight:normal;">By <span itemprop="name">Automated Electrics</span></font></h3><br><br><span itemprop="description"></span><center><span itemprop="description"><font size="4" color="#000000" face="arial">Helpful tips and advice for PLC programmers as well as considerations for site managers on solid PLC code development.</font></span></center><br><br><br><div itemprop="image" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/Code-Design-Graphic.png" alt="Programming Code" width="100%" height="100%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/Code-Design-Graphic.png"><meta itemprop="width" content="580"><meta itemprop="height" content="324"></div><div itemprop="publisher" itemscope="" itemtype="https://schema.org/Organization"><br><div itemprop="logo" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg" alt="Automated Electrics Logo at 20% original size" width="30%" height="30%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg"><meta itemprop="width" content="357"><meta itemprop="height" content="136"></div><meta itemprop="name" content="Automated Electrics"></div><meta itemprop="datePublished" content="2016-02-22T10:00:00+10:00"><meta itemprop="dateModified" content="2016-02-23T06:10:00+10:00"></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;">Programming code is the invisible magic that runs our entire world. It is not only in automation equipment like PLC and SCADA systems but also the majority of electronic equipment and services we use every day including computers, phones, TV&rsquo;s and even our cars.<br>&nbsp;<br>Coding is responsible for the clean water we drink, the telephone calls we make, the TV shows we watch and more. It has a big influence in our lives whether we know it or not, and poorly developed code can not only cause great frustration but it can also be very costly, even dangerous!<br>&nbsp;<br>This is why we want to point out how if you&rsquo;re a programmer you can improve in your coding, and if you&rsquo;re a manager or user you can ask the right questions of your programmer and better understand the coding process.</div><div class="wsite-spacer" style="height:50px;"></div><div><div id="197011770477021797" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h2><font size="5" color="#000000" face="arial">Code Planning Is Crucial</font></h2></div></div><div class="paragraph" style="text-align:left;">How can you start anything without a plan? If you want to build a house you don&rsquo;t just start nailing bits of timber together and hope for the best, no, you put pen to paper and draw up a plan showing what rooms will be where. This is the same for code development. A good plan will save development time, minimise mistakes, and you will end up with a program that better suits the application.<br></div><div><!--BLOG_SUMMARY_END--></div><div class="paragraph" style="text-align:left;">The more detailed your plan the better it will be for your code development, having said that even a few notes on a piece of paper that outlines the basic functionality is better that nothing. Quite often a functional description has already been put together by the process engineers that describes the requirements and functionality of the process you are trying to control.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="909864021753195382" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h2><font size="5" color="#000000" face="arial">Understand the Process You&rsquo;re Trying to Program</font></h2></div></div><div class="paragraph" style="text-align:left;">You cannot write any program without understanding what it is you&rsquo;re trying to achieve. You will be a better programmer, and write better programs, if you have a core understanding of how the process works. Do some research into the process and don&rsquo;t be afraid to ask questions. Your knowledge doesn&rsquo;t need to be at a process engineer&rsquo;s level, but a core understanding as to why that motor is turned on then, or why that chemical is added will help you in writing a well-rounded and functional program.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="242729602624639253" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h2><font size="5" color="#000000" face="arial">Choose the Right Programing Method</font></h2></div></div><div class="paragraph" style="text-align:left;">There are several different methods of programming, each with its advantages and disadvantages. The most common types in automation are;<br></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="953154821509267390" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Ladder Logic Code</font></u></h3></div></div><div><div class="wsite-image wsite-image-border-thick" style="padding-top:10px;padding-bottom:10px;margin-left:0px;margin-right:0px;text-align:center"><a href='https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/5976217_orig.gif' rel='lightbox' onclick='if (!lightboxLoaded) return false'><img src="https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/5976217_orig.gif" alt="Ladder Logic Code Example" style="width:auto;max-width:100%"></a><div style="display:block;font-size:90%"></div></div></div><div class="wsite-spacer" style="height:12px;"></div><div class="paragraph" style="text-align:left;">This is probably the most common type of programming in automation. Ladder logic is great for those with an electrical background because it looks like a relay logic circuit. Fault finding with ladder logic is often easier than other methods because you can see each condition in the rung and quickly identify what is preventing your desired outcome. Ladder logic is great for single dimensioned outcomes (e.g. on/off), but it can get quite complex for repeated or multi-conditional outcomes (e.g. looping functions)<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="701783901846785198" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Function Block Code</font></u></h3></div></div><div><div class="wsite-image wsite-image-border-thick" style="padding-top:10px;padding-bottom:10px;margin-left:0px;margin-right:0px;text-align:center"><a href='https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/5304181_orig.gif' rel='lightbox' onclick='if (!lightboxLoaded) return false'><img src="https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/5304181_orig.gif" alt="Function Block Code Example" style="width:auto;max-width:100%"></a><div style="display:block;font-size:90%"></div></div></div><div class="wsite-spacer" style="height:14px;"></div><div class="paragraph" style="text-align:left;">Function block is used widely in the HVAC (air conditioning) industry and is based on blocks that have pre-defined code inside to perform a specific function like a timer or a comparator. Function block code is programmed by linking the input and output&nbsp;signals of various blocks together and is great for those with an electronic background because it graphically looks like logic gates. Function block code is generally more suited for programmers who are process based in thought and familiar with P&amp;ID (Piping &amp; Instrumentation Drawing) formats.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="865501630188909534" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Structured Text Code</font></u></h3></div></div><div><div class="wsite-image wsite-image-border-thick" style="padding-top:10px;padding-bottom:10px;margin-left:0px;margin-right:0px;text-align:right"><a href='https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/4218923_orig.gif' rel='lightbox' onclick='if (!lightboxLoaded) return false'><img src="https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/4218923_orig.gif" alt="Structured Text Code Example" style="width:auto;max-width:100%"></a><div style="display:block;font-size:90%"></div></div></div><div class="wsite-spacer" style="height:16px;"></div><div class="paragraph" style="text-align:left;">Structured text is very popular in the computer sciences and is highly favoured by those with computer based backgrounds like web or app developers. As the name suggests, structured text is a text based code and is great for complex maths and repeating conditional functions. What would generally take dozens of lines in ladder logic to complete these types of functions can easily be completed in structured text with only a few lines of code.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:26px;"></div><div class="paragraph" style="text-align:left;">There is nothing wrong with sticking to one type of method if that is what you are comfortable with, but there will be circumstances where a combination of these methods would be the best approach in which you can draw upon the strengths of each method for a strong, well-rounded program.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="111076536789891522" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h2><font size="5" color="#000000" face="arial">Code Development and Structure Techniques</font></h2></div></div><div class="paragraph" style="text-align:left;">The development method and structure of your code can be just as important as the actual code itself, and these are the basics you should consider when developing a program. You could also apply the same considerations and techniques to other forms of programming, not just automation programming.<br></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="650579529875143723" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Start With the Basics First</font></u></h3></div></div><div class="paragraph" style="text-align:left;">I am often surprised how a program can develop into a complex tapestry of code, what I end up with is nothing like what I started out with. The best way to begin is to lay the foundations by starting with the basics first and then go back to add all of the bells and whistles into the program later, think of it like programming in layers.<br>&nbsp;<br>Start by setting up the basics. In PLC programming I set up the controller and add all of the modules first. I then give each input and output a description (which is great when it comes time to use it in your code to check that you have grabbed the right one!) then add the basic control code into the subroutines for each device. Once the basics are in, I then go back and start adding the specific functionality, building on that original base code. Remember that you will have many balls to juggle and many angles to think about while you&rsquo;re programming. Have a systematic approach to your programming and do one thing at a time, get that section right before moving on to the next.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="243407547392070459" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Keep Notes</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Keeping notes on what you have to do and where you need to come back to will help free your mind to concentrate on your task at hand. As you are programming you will have many ideas and thoughts popping into your head to do with your code, list them on a piece of paper that you can refer back to so you won't forget.<br><br>Quite often the piece of code you are currently writing will rely on another bit of code that you haven't developed yet. In these situations so I don't forget and to get it off my mind, I put a line in the area where the yet developed code will go and add some brief comments. I then place some sort of "error" in the line of code like an un-tagged variable so the program will not compile properly, this allows me to keep programming the bit of code I am currently working on, and later on if I forget, the program compile error will remind me that I need to go back and finish that section of code.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="439387684611130444" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Don&rsquo;t Rush Your Code</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Just like the assignment that was started the night before it was due, your program will never reach its true potential if you rush your code. When you give yourself time to clearly go through your logic and review your code you will be able to identify silly mistakes, programming loop holes, and greatly improve your code.<br>&nbsp;<br>There will be times that a problem will have you stumped, you would have worked on it for hours with no success and frustration could be setting in. Stop and take a break, you will be surprised how many ideas that will come to you when you&rsquo;re not even thinking about programming. Quite often I have had a great idea or a solution to a problem while I was sleeping or doing a mundane task. I once was working on a problematic section of code late one night for several hours with no success, but the next morning with a clear head I had it solved in 20 minutes! The answer was simple but I couldn&rsquo;t see it with a weary mind.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="530518138584968221" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Simpler Is Better In Programming</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Keep your code as simple as possible, it makes it easier to follow, easier to fault find, and easier to modify in the future. Overly complex code is generally fraught with loop holes and unforeseen errors due to its complexity. You won&rsquo;t look like a clever programmer because your code is complex or large, in fact it takes a smarter programmer to develop code that is both functional and simple.<br>&nbsp;<br>Why do something in one line of code which takes a rocket scientist's degree to work out, when you could have broken it down into 2 or 3 simpler lines with the same functionality and make it much easier to follow? There will come a point in time when you will look back at your code and have no idea what the hell you were thinking, and you won't even be able to follow your own work!<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="516743304332455070" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Reusable Code - Why reinvent the wheel?</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Reusable code is the holy grail of programming. When you create a reusable piece of code that serves a specific purpose or function, you can then place that code throughout your program many times without the need to re-write it every time.<br>&nbsp;<br>Well tested reusable code gives you the advantages of;<ul><li>Rapid code development.</li><li>Accuracy in repeated code.</li><li>Consistency in your program.</li></ul>&nbsp;<br>In PLC programming, there are several ways you can achieve this;<ul><li>Create an instruction block that can be pasted into other areas of your program.</li><li>Create a separate routine that you call upon through a &ldquo;jump to&rdquo; instruction.</li><li>Copy and paste the code into various sections of your program.</li></ul>&nbsp;<br>There are times that you would use one over the other. A function block or separate routine is easily updated or changed in one spot and the changes are globally applied throughout your program, whereas specifically pasting the code into various sections of your program means that you can tailor each section as necessary, but for a global change you would have to go to each section and make the same change multiple times.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="456415680822577456" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Code Consistency</font></u></h3></div></div><div class="paragraph" style="text-align:left;">In any program, consistency in your code is absolutely crucial. Regardless of any inefficiencies or errors in your code, you should always be consistent. There is nothing worse than trying to work with a program that was started one way and ended in a different way. A program that is consistent is easier to navigate which automatically means that it is easier to fault find, modify and integrate with for third parties.<br>&nbsp;<br>Key areas in programming where consistency is required are;<br></div></td></tr></tbody></table></div></div></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:22.845953002611%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:77.154046997389%; padding:0 15px;"><div><div id="908454356356689297" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">Naming Conventions</font></h4></div></div><div class="paragraph" style="text-align:left;">Standardise on a naming convention for your code, and by that I mean all the tags, variables, routines and functions that will make up your program. Quite often in a process control program we will prefix the tag or variable with the P&amp;ID number for quick reference, for example MO701_ALM_FTST for Motor 701 failed to start alarm.<br><br>When you have several thousand variables in your code to navigate, a standardised naming convention will save you time in searching and improve your accuracy in programming.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="241515199146340123" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">Line Structure</font></h4></div></div><div class="paragraph" style="text-align:left;">Keeping variables and conditions in the same position between similar lines of code throughout your program will make navigation easier and quicker, particularly when you are fault finding or diagnosing an issue.<br>&nbsp;<br>In our case one of the lines of code in our motor control routines are the motor ready status, shown in the Ladder Logic picture above. All of the conditions in this line need to be true before a flag is raised to say this particular motor is ready. No matter what motor in our code you go to, the position of these conditions always remains the same.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="546159033530936437" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">Functional Structure</font></h4></div></div><div class="paragraph" style="text-align:left;">Similar to line structure, functional structure is keeping your code in the order of processing. If you were to program a recipe to bake a cake, the first step would be to add the ingredients, the second step would mix the batter and pour it into a tin, and finally the third step would bake the cake in the oven. Your program for the cake shouldn&rsquo;t have the baking function before the ingredients function.<br>&nbsp;<br>Keeping your functional structure in the order of processing will make programming easier and help your code run more efficiently.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="786697756173319810" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Error and Fault Handling</font></u></h3></div></div><div class="paragraph" style="text-align:left;">If I had to choose which of these items is the most important, it would have to be error and fault handling in your program. Errors and faults will happen within any program and careful consideration is needed to both limit and handle them.<br>&nbsp;<br>Errors and faults can come in various forms;<br></div></td></tr></tbody></table></div></div></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:22.845953002611%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:77.154046997389%; padding:0 15px;"><div><div id="477372731686825370" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">Process Errors</font></h4></div></div><div class="paragraph" style="text-align:left;">This is where your knowledge of the process will be an advantage, allowing you to identify possible situations or faults within the process that will need handling. For example, what happens if that pump stops working while that valve is open?<br>&nbsp;<br>Generally a well written functional description will list most of the faults that will need handling, but you will find there are a few extras that will need to be taken care of within your code.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="186660592296800800" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">User Interaction Errors</font></h4></div></div><div class="paragraph" style="text-align:left;">Never assume that an operator or user will enter data into your program in the correct format or range. Always have checks in place to validate the data entered by the user. Is it valid? Is it within the limits?<br>&nbsp;<br>To prevent accidental triggers by a user, consider having a double action for major events that require 2 deliberate triggers by the user before the desired outcome. An example of this would be shutting a plant down, the operator could click on a shutdown button which then pops up a confirmation window &ldquo;Are you sure you want to shut down the plant?&rdquo;<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="329016224586371966" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h4><font size="4" color="#000000" face="arial">Program Errors</font></h4></div></div><div class="paragraph" style="text-align:left;">In certain situations a program can run into a problem, and without error handling that problem could crash the program. One of the most common errors I see in PLC code are counters with variables that have no limits, and eventually the variable&rsquo;s value is exceeded and the PLC goes into program fault.<br>&nbsp;<br>An example of this is a motor start counter in a PLC. Every time the motor starts, a counter adds 1 to an accumulated total. An unsigned 16 bit integer has a limit of 65,535. If that motor was to start for a 65,536th time, the integer variable in the counter would be exceeded and possibly fault out the PLC (I say possible because it does depend on how the program fault handling has been set up in the PLC). An easy fix would be to add one more line under the counter that resets this value if it gets to 65,535, thus avoiding a program fault one day.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="424531755858538538" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Comment, Comment, Comment!</font></u></h3></div></div><div class="paragraph" style="text-align:left;">I cannot stress enough how important it is to comment your code, there is no such thing as over-commenting! Comments are a great way to explain what your code is doing and any thoughts you had at the time of writing that code. The comments might explain why that piece of code is there, or why the code is performing the function that it is. Code comments help anyone else who navigates through your program to understand your thought process, and trust me, you will be grateful one day that you took the time to comment your code because in the future they will help you understand your own thought process!<br>&nbsp;<br>It is extremely frustrating to work with a program that has no comments. You don&rsquo;t have to comment every single line of your code, but at least the beginning of major sections within your program. Don&rsquo;t fall for the trap of telling yourself &ldquo;No need to add comments, I&rsquo;ll remember this&rdquo;<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="307769364748177199" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Code Testing and Commissioning</font></u></h3></div></div><div class="paragraph" style="text-align:left;">It may seem obvious but once you have finished your program, thoroughly test your code. I say thoroughly because testing can be boring and I know some programmers who do not put enough time into this phase of the code development.<br>&nbsp;<br>Code testing not only proves the functionality of your program but also identifies errors within your code. I generally find that most errors are the copy and paste type where I forgot to change the pasted values, and the code was using the wrong data. A dumb mistake but one that is easily identified with proper and thorough testing.<br>&nbsp;<br>Your testing should incorporate the following;<ul><li>Code accuracy</li><li>Functionality and potential loop-holes</li><li>Error and fault handling</li><li>Program speed</li><li>Program security</li></ul>&nbsp;<br>There will be times that your code will be executing too fast to catch exactly where a fault within the code is happening. A great solution is to use temporary break points in your code so you can &ldquo;pause&rdquo; the code execution, or move key values within your code into temporary variables so you can see what was happening at each stage. Be sure though to prefix your temporary variables with something like &ldquo;Test&rdquo; or &ldquo;Temp&rdquo; so you can easily go back at the end of testing and remove them.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="127477783880934447" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Code Cleaning</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Residual and redundant code not only bogs down your program and ties up valuable memory, but it can also make it more difficult and confusing to navigate. As your program changes, be sure to remove redundant code and variables that no longer have a use within your program.<br></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="577213643625367980" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3><u><font size="4" color="#000000" face="arial">Program Version Control</font></u></h3></div></div><div class="paragraph" style="text-align:left;">Your program will go through many changes and alterations, not only as it is developed but also throughout its functional life, and it is crucial that you keep track of the various versions your program goes through.<br>&nbsp;<br>Program version control is the tracking of changes to your program over time. Added features or changes to your program are commissioned under a new version, with the old version left un-touched. Version control makes it easier to identify bugs in a specific release and allows you to quickly roll back to the last known working version while the buggy version is further developed. Where the program is used on multiple sites, you can easily keep track of where each site is up to and what version it is running.<br>&nbsp;<br>The simple method of version control is a version prefix to the file name and just a few comments at the beginning of your code identifying the version and changes from the last one, but this is reliant on the programmer being diligent enough to keep the notes updated. Alternatively, there are dedicated software packages out there that can manage version control for you and keep a detailed log of the different versions of your program and who made what changes when.<br>&nbsp;<br>Whatever works for you, make sure you keep track of your program versions, and back them up!<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div><div id="338855828476394691" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h2><font size="5" color="#000000" face="arial">Have Fun With Your Programming!</font></h2></div></div><div class="paragraph" style="text-align:left;">Finally, and most importantly, enjoy your programming experience. It is a wonderful feeling to see all of your hard work and clever ideas in action. Standing back and watching the process working with your program and remembering all of the obstacles you had to overcome to achieve success is very rewarding.<br>&nbsp;<br>So take this knowledge and make your next program better than your last.<br>Happy Programming!<br></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;"><font size="2"><u>PLC Programming Development Tips</u><br>Published By: Automated Electrics<br>Written By: Chris Orban<br>Category: Programming</font><br></div>]]></content:encoded></item><item><title><![CDATA[Automation System Managers Can Learn From Telstra’s Mistakes]]></title><link><![CDATA[https://www.automatedelectrics.com.au/blog/thank-you-telstra-your-outage-has-opened-our-eyes]]></link><comments><![CDATA[https://www.automatedelectrics.com.au/blog/thank-you-telstra-your-outage-has-opened-our-eyes#comments]]></comments><pubDate>Sat, 13 Feb 2016 00:39:19 GMT</pubDate><category><![CDATA[General]]></category><guid isPermaLink="false">https://www.automatedelectrics.com.au/blog/thank-you-telstra-your-outage-has-opened-our-eyes</guid><description><![CDATA[Share    Thank You Telstra; Your Outage Has Opened Our EyesBy Automated ElectricsTake a lesson from Telstra about the true cost of human error for your automation system.Thank you Telstra for that brief period this week where our mobiles remained silent, we put our phones down, our efficiency soared and we were able to get a ton of work finished without disruptions!&nbsp;Thank you Telstra also for reminding us that we need to be mindful of the points of failure within our own systems and process [...] ]]></description><content:encoded><![CDATA[<div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:64.705882352941%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:35.294117647059%; padding:0 15px;"><div><div id="781696416660298220" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><p style="text-align:center;font-size:14px;color:black;">Share</p><span class='st_sharethis_large' displaytext='ShareThis'></span> <span class='st_facebook_large' displaytext='Facebook'></span> <span class='st_twitter_large' displaytext='Tweet'></span> <span class='st_linkedin_large' displaytext='LinkedIn'></span> <span class='st_googleplus_large' displaytext='Google +'></span></div></div><div class="wsite-spacer" style="height:50px;"></div></td></tr></tbody></table></div></div></div><div><div id="811685076786395175" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><div itemscope="" itemtype="https://schema.org/NewsArticle"><meta itemscope="" itemprop="mainEntityOfPage" itemtype="https://schema.org/WebPage" itemid="https://www.automatedelectrics.com.au/blog/thank-you-telstra-your-outage-has-opened-our-eyes"><h1 itemprop="headline"><font size="6" color="#000000" face="arial">Thank You Telstra; Your Outage Has Opened Our Eyes</font></h1><h3 itemprop="author" itemscope="" itemtype="https://schema.org/Person"><font size="3" style="font-weight:normal;">By <span itemprop="name">Automated Electrics</span></font></h3><br><br><span itemprop="description"></span><center><span itemprop="description"><font size="4" color="#000000" face="arial">Take a lesson from Telstra about the true cost of human error for your automation system.</font></span></center><br><br><br><div itemprop="image" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/TelstraDisconnectLogo.png" alt="Telstra Logo It&rsquo;s How We Disconnect!" width="100%" height="100%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/TelstraDisconnectLogo.png"><meta itemprop="width" content="1034"><meta itemprop="height" content="456"></div><div itemprop="publisher" itemscope="" itemtype="https://schema.org/Organization"><br><div itemprop="logo" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg" alt="Automated Electrics Logo at 20% original size" width="30%" height="30%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg"><meta itemprop="width" content="357"><meta itemprop="height" content="136"></div><meta itemprop="name" content="Automated Electrics"></div><meta itemprop="datePublished" content="2016-02-12T11:00:00+10:00"><meta itemprop="dateModified" content="2016-02-22T10:03:00+10:00"></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;">Thank you Telstra for that brief period this week where our mobiles remained silent, we put our phones down, our efficiency soared and we were able to get a ton of work finished without disruptions!<br>&nbsp;<br>Thank you Telstra also for reminding us that we need to be mindful of the points of failure within our own systems and processes, because if your chief operations officer Kate McKenzie is correct, this large and sophisticated system of yours can be brought down by one person&rsquo;s simple mistake!<br></div><div class="paragraph" style="text-align:left;">Telstra&rsquo;s official statement was that a field technician &ldquo;failed to follow the correct procedure&rdquo; and brought a major telecommunications system to its knees due to an &ldquo;embarrassing human error&rdquo;. Comforting to know that a specific procedure needs to be followed to keep Australia&rsquo;s biggest telecommunications network running.<br></div><div><!--BLOG_SUMMARY_END--></div><div class="paragraph" style="text-align:left;">It is estimated that of the 16.7 million Telstra customers, several million were affected by this week&rsquo;s network outage and the true cost of this will never be known as lost sales and production for businesses who rely on Telstra&rsquo;s mobile network can never be accurately counted. We here at Automated Electrics use the 4G network for remote connectivity to automation and control systems on various sites for our clients. Fortunately there wasn&rsquo;t too much going on during the network outage, otherwise we would have been left high and dry also.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">System Checks and Balances Are Critical In Automation</font><br></h2><div class="paragraph" style="text-align:left;">All automation and control systems require some amount of human involvement, including the Telstra communications network, and human error is an inevitable fact of life. If plant managers are not careful, they could face a similar scenario with a simple error crippling their entire operations. Careful consideration is always required to identify the points of failure in a process which can often be counteracted with specific checks and balances to ensure that mistakes are caught and filtered out before the worst happens.<br></div><div class="paragraph" style="text-align:left;">Points of failure are not just processing techniques or operational methods, they can be within the programming functionality also, and quite often the automation system controlling the plant can have simple tweaks or changes made to the programming code for a more robust and self-managed fault protection mechanism. For example, if the operator can shut down an entire section of the plant from the SCADA with the click of a button, a simple check might be a message popping up asking the operator &ldquo;Are you sure you want to &hellip;&hellip;&rdquo; requiring a double action from the operator to confirm that this is in fact what they want to do, and giving them an option out if it was a mistake.<br></div><div class="paragraph" style="text-align:left;">We often say that programming is the brain of your automation system and the smarts to make your plant reliable and profitable. In this day and age with all the technology available, there should be no excuse for such a catastrophic failure from a simple &ldquo;embarrassing human error&rdquo;. Who knows, maybe this entire Telstra nightmare could have been avoided with a simple message popping up for the field technician!<br>&nbsp;<br>Food for thought, Thank You Telstra.<br></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;"><font size="2"><u>Thank You Telstra; Your Outage Has Opened Our Eyes</u><br>Published By: Automated Electrics<br>Written By: Chris Orban<br>Category: General</font></div>]]></content:encoded></item><item><title><![CDATA[A Storm Can Bring More Than Just The Rain]]></title><link><![CDATA[https://www.automatedelectrics.com.au/blog/power-surge-protection-guide]]></link><comments><![CDATA[https://www.automatedelectrics.com.au/blog/power-surge-protection-guide#comments]]></comments><pubDate>Mon, 01 Feb 2016 20:08:55 GMT</pubDate><category><![CDATA[Power]]></category><guid isPermaLink="false">https://www.automatedelectrics.com.au/blog/power-surge-protection-guide</guid><description><![CDATA[Share    Power Surge Protection GuideBy Automated ElectricsOur Power Surge Protection Guide will help you understand what is often overlooked by many people.Power surges, power spikes, dirty power, however you want to describe them, they are something that cannot be prevented unfortunately and we just have to understand that it does happen within our electricity distribution system. More importantly you need to know that you don’t have to put up with them or suffer their consequences!&nbsp;We  [...] ]]></description><content:encoded><![CDATA[<div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:64.621409921671%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:35.378590078329%; padding:0 15px;"><div><div id="447919190750333488" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><p style="text-align:center;font-size:14px;color:black;">Share</p><span class='st_sharethis_large' displaytext='ShareThis'></span> <span class='st_facebook_large' displaytext='Facebook'></span> <span class='st_twitter_large' displaytext='Tweet'></span> <span class='st_linkedin_large' displaytext='LinkedIn'></span> <span class='st_googleplus_large' displaytext='Google +'></span></div></div><div class="wsite-spacer" style="height:50px;"></div></td></tr></tbody></table></div></div></div><div><div id="678710824114678700" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><div itemscope="" itemtype="https://schema.org/NewsArticle"><meta itemscope="" itemprop="mainEntityOfPage" itemtype="https://schema.org/WebPage" itemid="https://www.automatedelectrics.com.au/blog/power-surge-protection-guide"><h1 itemprop="headline"><font size="6" color="#000000" face="arial">Power Surge Protection Guide</font></h1><h3 itemprop="author" itemscope="" itemtype="https://schema.org/Person"><font size="3" style="font-weight:normal;">By <span itemprop="name">Automated Electrics</span></font></h3><br><br><span itemprop="description"></span><center><span itemprop="description"><font size="4" color="#000000" face="arial">Our Power Surge Protection Guide will help you understand what is often overlooked by many people.</font></span></center><br><div itemprop="image" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/LightningPicture.png" width="100%" height="100%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/LightningPicture.png"><meta itemprop="width" content="900"><meta itemprop="height" content="598"></div><div itemprop="publisher" itemscope="" itemtype="https://schema.org/Organization"><br><div itemprop="logo" itemscope="" itemtype="https://schema.org/ImageObject"><center><img src="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg" width="30%" height="30%"></center><meta itemprop="url" content="https://www.weebly.com/editorhttps://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/custom_themes/734236763772553868/files/AutomatedElectricsLogo-20.jpg"><meta itemprop="width" content="357"><meta itemprop="height" content="136"></div><meta itemprop="name" content="Automated Electrics"></div><meta itemprop="datePublished" content="2016-01-02T08:00:00+10:00"><meta itemprop="dateModified" content="2016-01-05T07:30:00+10:00"></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;">Power surges, power spikes, dirty power, however you want to describe them, they are something that cannot be prevented unfortunately and we just have to understand that it does happen within our electricity distribution system. More importantly you need to know that you don&rsquo;t have to put up with them or suffer their consequences!<br>&nbsp;<br>We have had numerous calls from plant managers on various sites effected by the recent thunder storms sweeping the country, and we thought it would be a great time to raise the issue of power surge protection so it is in the forefront of people&rsquo;s minds. We will look at why power surges occur and what you can do to protect yourself against them. Surge protection is an interesting topic that can get quite in-depth, but we will keep this brief and light.<br>&nbsp;<br>Although in this article we are focusing on power surge protection for the automation industry, you can apply the same theory and methodology for the commercial and residential sectors.<br></div><div class="wsite-spacer" style="height:33px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">What are power surges?</font><br></h2><div class="paragraph" style="text-align:left;">Power surges are sudden, sharp high voltage rises in the electricity supply and are one type of electrical disturbance that causes dirty power. The extremely high voltage spikes of a power surge can last for anywhere up to a few milliseconds and damage sensitive electronic equipment and systems.</div><div class="paragraph" style="text-align:left;">There are various types of electrical disturbances such as;<br></div><div><!--BLOG_SUMMARY_END--></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;"><ul><li>Sags (dips in voltage)</li><li>Swells (increase in voltage)</li><li>Spikes / Transients (sudden, sharp rise in voltage - Surges)</li><li>Harmonics (non-sinusoidal waveform distortion)</li><li>Noise (high frequency signals)<br></li></ul></div></td></tr></tbody></table></div></div></div><div class="paragraph" style="text-align:left;">Any disturbance in the mains power is bad, but arguably the most common and one that causes the most damage are the power surges.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">What causes power surges?</font><br></h2><div class="paragraph" style="text-align:left;">Power surges occur generally from one of two instances;</div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;"><ul><li>Disruption to the flow of electricity, such as<ul><li>Disconnection of large loads or appliances</li><li>Electricity network switching&nbsp;<br></li></ul></li></ul></div><div class="paragraph" style="text-align:left;"><ul><li>Lightning events, such as<ul><li>Direct strike</li><li>Induced surge<br></li></ul></li></ul></div></td></tr></tbody></table></div></div></div><div class="paragraph" style="text-align:left;">It is estimated that up to 85% of all power surges occur within the customer&rsquo;s own premises. Surges caused by electrical flow disruptions are the most common and are generally less severe as compared to lighting events. They can occur when a heavy load suddenly stops or is disconnected from the electrical network, for example large motors. When a large motor is stopped, the demand on the electrical transformer in the street that was supplying all of this energy is suddenly reduced. The problem is that the transformer needs to dissipate all of this built up energy in the form of a magnetic field which was used to power the motor. This magnetic field suddenly starts collapsing within the transformer causing a spike in the supply voltage.<br>&nbsp;<br>The second major cause of power surges are lightning events. With each bolt of lightning producing up to 300,000 amps and one billion volts of electricity, it&rsquo;s no wonder they can wreak so much havoc! A direct strike to the building itself will cause major issues, but not every building though is susceptible to a direct strike. Depending on a number of factors including the geographical location and surrounding infrastructure, a lot of premises will suffer more from the effects of either a surge coming in through the power lines, or lightning induced surges coming in from underground services. When lightning hits the earth, the energy directed into the ground causes a rise in ground voltage radiating outwards from the point of impact. The high voltage from the lightning strike is then induced into the underground services such as electrical, plumbing and communications that are within this point of impact area.</div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">What damage can power surges do?</font><br></h2><div class="paragraph" style="text-align:left;">When you have a look at any electronic product you will see that internally it is made up of small, low powered components that are sensitive and have low voltage thresholds. During a power surge, the voltage on the electrical network spikes and the components within the various electronic devices connected to the network are hit with a voltage that they can&rsquo;t handle. The voltage thresholds of these electrical components are exceeded, causing them damage.<br>&nbsp;<br>All power surges will cause some sort of damage, but not all power surges will cause your equipment to instantly fail. A series of smaller surges can end up hurting your electronic equipment just as much as one large surge. Each surge wears the electronic components down bit by bit until one day they will completely fail.<br>&nbsp;<br>Think of it like a boxer in a fight. There could be one large knockout punch that takes the boxer out in the first round, or their opponent could wear them down with a series of smaller jabs until they are too tired to continue.<br>&nbsp;<br>One thing is for sure, power surges do happen no matter where you are and they do cause damage!<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">How can I protect against power surges?</font><br></h2><div class="paragraph" style="text-align:left;">Nobody wants to replace their equipment unnecessarily, and breakdowns are an expensive exercise for any plant or process to go through. That is why it is absolutely crucial that each surge protection design is properly engineered as each installation is different and each plant will have its own requirements that need careful consideration.</div><div class="paragraph" style="text-align:left;">A surge protection system should have the following considerations in its design;<br></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="197247477136171625" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Direct Lightning Strikes</u></h3></div></div><div class="paragraph" style="text-align:left;">As we discussed earlier, not all buildings are at risk of a direct strike. Geographical location, surrounding infrastructure, even the building materials used all play a crucial part in assessing the potential risk of a direct lightning strike. Depending on the site&rsquo;s risk assessment, protection against lighting strikes can be achieved with something as simple as bonding building structures and grounding systems together, all the way to full blown lightning protection systems with masts in the air that tower over the entire site and guide the lightning strike safely to the grounded earth.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="869120340188243758" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Earthing Installation</u></h3></div></div><div class="paragraph" style="text-align:left;">A good earthing system is crucial to successful surge protection. You may have the best system available with all the bells and whistles, but if you don&rsquo;t have a strong earthing system in place it will all be for nothing! The key to surge protection is to give the surge an easy path back to the grounded earth, which is where it is trying to get to. If you cannot provide a strong earth path then it will try and find its way through other means like your electronic equipment, or even worse, YOU! It cannot be underestimated how important earthing is.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="216474778737137836" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Mains Power Reticulation</u></h3></div></div><div class="paragraph" style="text-align:left;">The mains power reticulation is basically the way your electrical boards are installed and connected to the electricity supply. Starting with the supply from the street, all the way to the final power point on site, your power reticulation network will need careful consideration when it comes to designing your surge protection system. This will determine what type of surge diverters and filters will need to be installed in the various switchboards and control panels on site. We will cover the various types of surge protection units shortly.</div><div class="wsite-spacer" style="height:39px;"></div><div><div id="584790128245058217" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Underground Services</u></h3></div></div><div class="paragraph" style="text-align:left;">Although your site may not be hit directly by lightning, the power surge can still get into your building via the underground services connected to it. Careful consideration needs to be made not only to the power services underground, but also the instrumentation and control cables that connect into the electronic equipment like the PLC and SCADA systems on site. Field instrumentation that is connected by underground wiring generally has surge protection at both the PLC and field ends to ensure the power surge has no affect at either end of the cable.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="225164950998631897" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Communications Services</u></h3></div></div><div class="paragraph" style="text-align:left;">Power surges are not limited to only the mains power reticulation, they can also come in via the incoming telephone lines and underground communications cabling systems. As with the underground instrumentation, the underground communication wiring generally has surge protection installed at both ends to handle any surges. An alternative to communications surge protection is to replace the copper wiring with fibre optic cables, as the glass fibre optic cables are not effected by magnetic fields or power surges.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="400880118594359906" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Surge Protection Monitoring</u></h3></div></div><div class="paragraph" style="text-align:left;">After your surge protection system is installed, there will need to be some sort of monitoring plan or system put in place. Basically the surge protection units take the hit of the surge instead of your expensive electronic devices, which means that each surge or hit your site gets will degrade the protection system to some extent. Occasional maintenance will be required down the track to keep the surge protection system fully operational. Surge protection monitoring can be something as simple as a manual periodic inspection or it can be connected to your PLC and SCADA control system for full automatic monitoring and problem notification. Either way you will want to know when your surge protection system needs servicing.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:27px;"></div><div class="paragraph" style="text-align:left;">One thing to remember is that there is no one device that will protect the entire installation. Generally, depending on the manufacturer, there are 3 different classes of surge protection available and each class handles a specific part of the surge.<br></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div><div id="687304152204382369" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Class 1 Surge Protection</u></h3></div></div><div class="paragraph" style="text-align:left;">Class 1 surge protection units are diverters that steer the surge away from the electrical installation and towards the grounded earth which is where the power surge is trying to get to. The main job of a Class 1 unit is to take the brunt of the energy out of the surge so the units below can handle the rest. Generally a Class 1 unit employs spark gap technology and reduces the voltage and power of a surge enough for the Class 2 units downstream.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="893586299628370506" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Class 2 Surge Protection</u></h3></div></div><div class="paragraph" style="text-align:left;">Class 2 surge protection units are also diverters, like the Class 1 units, and continue on from where the Class 1 units left off. The Class 2 units cannot handle the amount of energy that a Class 1 unit can, but they reduce the voltage of a surge more than what the Class 1 units do. Generally a Class 2 unit employs MOV (Metal Oxide Varistor) technology and reduces the voltage and power of a surge enough for the Class 3 units downstream.<br></div><div class="wsite-spacer" style="height:39px;"></div><div><div id="447445242702915379" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h3 style="text-align:left;font-size:18px;font-weight:bold;"><u>Class 3 Surge Protection</u></h3></div></div><div class="paragraph" style="text-align:left;">Class 3 surge protection units are power filters that are connected in line with the power to various electronic equipment. Class 3 units have a low discharge capacity and should only be installed after a Class 2 unit. The Class 3 is the final stage of surge protection for your electronic equipment.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><font size="5">What are the risks of inadequate surge protection?</font><br></h2><div class="paragraph" style="text-align:left;">Unfortunately there are a lot of automation systems out there that do not have any surge protection for their plant&rsquo;s electronic equipment, and it is possible that they don&rsquo;t understand the risks they face by not having one. Whether the surge protection system was an over site in the engineering and design phase of the project or it has been left out due to budget restrictions, the lack of surge protection could prove to be a very costly mistake down the track when the owners have to start paying for brand new equipment and parts to replace the ones damaged from a power surge.<br></div><div class="paragraph" style="text-align:left;">The risks of inadequate surge protection include;<br></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;"><ul><li>Premature aging of equipment / reduced life span</li><li>Increased plant maintenance costs</li><li>Data loss</li><li>Unscheduled downtime</li><li>Reduced productivity and profits<br></li></ul></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:15px;"></div><div class="paragraph" style="text-align:left;">Added to these risks, we are hearing throughout the industry more often that some insurance companies are no longer covering surge damage unless the site has a proper surge protection system installed. After reading this guide you would agree that a surge protection system for your site is an insurance policy you will never be able to beat!<br></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;"><font size="2"><u>Power Surge Protection Guide</u><br>Published By: Automated Electrics<br>Written By: Chris Orban<br>Category: Power</font><br></div>]]></content:encoded></item><item><title><![CDATA[Would You Be Ready If Your SCADA System Failed Tomorrow?]]></title><link><![CDATA[https://www.automatedelectrics.com.au/blog/scada-disaster-recovery-plan]]></link><comments><![CDATA[https://www.automatedelectrics.com.au/blog/scada-disaster-recovery-plan#comments]]></comments><pubDate>Tue, 26 Jan 2016 06:02:38 GMT</pubDate><category><![CDATA[SCADA]]></category><guid isPermaLink="false">https://www.automatedelectrics.com.au/blog/scada-disaster-recovery-plan</guid><description><![CDATA[Share    SCADA System Backup and Disaster Recovery PlanSCADA, which stands for Supervisory Control And Data Acquisition, is the graphical user interface for an automation control system and is a critical piece of infrastructure that allows the plant operator to efficiently monitor and control the automated process. So imagine the chaos when the SCADA system suddenly dies! The operators are left blind and unable to properly control their plant. This is why it is absolutely critical to have a Disa [...] ]]></description><content:encoded><![CDATA[<div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:64.705882352941%; padding:0 15px;"><div class="wsite-spacer" style="height:67px;"></div></td><td class="wsite-multicol-col" style="width:35.294117647059%; padding:0 15px;"><div><div id="619812034340323398" align="right" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><p style="text-align:center;font-size:14px;color:black;">Share</p><span class='st_sharethis_large' displaytext='ShareThis'></span> <span class='st_facebook_large' displaytext='Facebook'></span> <span class='st_twitter_large' displaytext='Tweet'></span> <span class='st_linkedin_large' displaytext='LinkedIn'></span> <span class='st_googleplus_large' displaytext='Google +'></span></div></div><div class="wsite-spacer" style="height:50px;"></div></td></tr></tbody></table></div></div></div><div><div id="873170380915294219" align="left" style="width: 100%; overflow-y: hidden;" class="wcustomhtml"><h1 style="text-align:centre;font-size:22px;color:black;font-weight:bold;">SCADA System Backup and Disaster Recovery Plan<br><br></h1></div></div><div><div class="wsite-image wsite-image-border-none" style="padding-top:10px;padding-bottom:10px;margin-left:0px;margin-right:0px;text-align:center"><a><img src="https://www.automatedelectrics.com.au/uploads/5/4/4/0/54407243/damaged-laptop-1-out-of-service-nbg_orig.png" alt="Broken SCADA Computer" style="width:auto;max-width:100%"></a><div style="display:block;font-size:90%"></div></div></div><div class="wsite-spacer" style="height:50px;"></div><div class="paragraph" style="text-align:left;">SCADA, which stands for Supervisory Control And Data Acquisition, is the graphical user interface for an automation control system and is a critical piece of infrastructure that allows the plant operator to efficiently monitor and control the automated process. So imagine the chaos when the SCADA system suddenly dies! The operators are left blind and unable to properly control their plant. This is why it is absolutely critical to have a Disaster Recovery Plan for all SCADA systems.</div><div class="paragraph" style="text-align:left;">It is not a case of <u>IF</u> a system will fail, it is a case of <u>WHEN</u>. SCADA systems are computer based and even the best system will fail at some point due to various reasons like;</div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;"><ul><li>Hardware Failures (disk failure, power surges etc).</li><li>Software Failures (viruses, operating system errors etc).</li><li>Accidental System Changes.</li><li>Network Failures.</li></ul></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:19.76666px;"></div><div class="paragraph" style="text-align:left;">Your SCADA Disaster Recovery Plan should start with asking a few questions to identify what sort of system you have;</div><h2 class="wsite-content-title" style="text-align:left;"><u>SCADA Critical Importance</u><br></h2><div><!--BLOG_SUMMARY_END--></div><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;">The first step in setting up your SCADA disaster recovery plan is identifying the level of critical importance for your system, which is determined by how long your plant can go without your SCADA system running. If your plant is controlling a highly sensitive process like an electricity power plant or high pressure boilers, then your SCADA critical importance is high. Alternatively if your plant is controlling a low sensitivity process like a packing line or pumping station and you can afford to do without your plant running for a while then your critical importance is low.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>Disaster Recovery Budget</u><br></h2><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:50px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227154%; padding:0 15px;"><div class="paragraph" style="text-align:left;">Once you have identified your SCADA system&rsquo;s critical importance, you can then work out what sort of budget you can afford to implement and maintain your disaster recovery plan. Disaster recovery for a SCADA system with high critical importance is generally more expensive to implement and maintain due to the extra equipment required, alternatively the low critical importance systems are cheaper to implement and maintain.<br><br>There are several types of disaster recovery plans available and your budget will go a long way to which options you are going to utilise.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>Disaster Recovery Plans</u></h2><div><div class="wsite-multicol"><div class="wsite-multicol-table-wrap" style="margin:0 -15px;"><table class="wsite-multicol-table"><tbody class="wsite-multicol-tbody"><tr class="wsite-multicol-tr"><td class="wsite-multicol-col" style="width:12.402088772846%; padding:0 15px;"><div class="wsite-spacer" style="height:45.76666px;"></div></td><td class="wsite-multicol-col" style="width:87.597911227153%; padding:0 15px;"><div class="paragraph" style="text-align:left;">Selecting your disaster recovery plan is an obvious choice between the functionality of each option, your SCADA system requirements and your available budget. There are several options available with each one having different pros and cons that you need to carefully consider.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>Full Redundancy Plan</u></h2><div class="paragraph" style="text-align:left;">If you have a SCADA system with high critical importance, and you absolutely cannot live without your system running, the full redundancy architecture is the option you would go for. This is where the SCADA system has multiple servers, whether the servers are virtualised or actual physical servers, one server is actively running the SCADA system while the other servers are online and waiting idle. If the active SCADA server fails for whatever reason, one of the standby servers takes over and continues running the SCADA system. This way the plant operators are still able to control the plant and they are alerted that there has been a server failure.<br></div><div class="paragraph" style="text-align:left;">The redundancy architecture generally runs multiple operator workstations also to ensure the operators always have at least one workstation to access the SCADA system from.<br></div><div class="paragraph" style="text-align:left;">The full redundancy plan is going to be the most expensive option available but the one that has the highest available SCADA up time for your system which is essential for highly critical or sensitive processes. If your SCADA system&rsquo;s critical importance is not so high, you can start looking at some cheaper alternatives below.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>Configuration Backup Plan</u></h2><div class="paragraph" style="text-align:left;">The cheapest and simplest disaster recovery plan is the configuration backup. This is where the SCADA configuration (SCADA programming) is manually backed up and stored somewhere like an external disk, thumb drive or in the cloud.&nbsp;<br></div><div class="paragraph" style="text-align:left;">The downfall of the configuration backup method is that each backup must be done manually, and you are only backing up the configuration of the SCADA system, not the whole computer itself. The configuration backup method will not protect you from actual computer disasters including hardware failures and viruses. During a disaster recovery event, you will still need to have a fully working PC with the SCADA program installed. Then the configuration backups can be used to help re-establish the system.<br></div><div class="paragraph" style="text-align:left;">The configuration backup method is a good start to any disaster recovery plan, but it should not be relied upon as your only backup plan. Also, be sure to have a complete set of software installation disks ready with your configuration backups should the computer itself ever fail and you need to set up another computer to replace it.</div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>System Imaging Plan</u></h2><div class="paragraph" style="text-align:left;">The next step up from configuration backups is system imaging. This is a cost effective solution where a software package takes regular images of the various SCADA computers and stores them in the cloud or on backup disks. An image is a &ldquo;photo&rdquo; of the computer&rsquo;s hard drives which can then be used to precisely restore the computer back to a time when the image was taken. There are some fantastic disk imaging software packages available like Acronis and Easeus which can easily be set up to run on a schedule and automatically backup your SCADA computers.<br></div><div class="paragraph" style="text-align:left;">When your computer&rsquo;s hard drive fails, the latest image can be used to restore the system on a brand new hard drive which will get your SCADA computer up and running again exactly the way it was when the image was taken. The system images can also be used for recovery from a virus by selecting an image and restoring the system back to a known good date before the virus infected the computer.<br></div><div class="paragraph" style="text-align:left;">System images are a very easy and versatile method to get your SCADA system back up and running with minimal fuss.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>Spare SCADA PC Plan</u><br></h2><div class="paragraph" style="text-align:left;">Having a complete spare computer is another method of disaster recovery. This is where a complete second computer is setup with the SCADA software and configuration files, the computer is commissioned so it can communicate with the plant and then it is unplugged and stored away for future use. Don&rsquo;t confuse this method with a full redundancy system because the second computer in this situation is not actually plugged in and working as an online standby unit.<br></div><div class="paragraph" style="text-align:left;">The theory is that when your main SCADA PC fails, the spare PC can be plugged in its place and have you up and running again fairly quickly. The spare SCADA PC method can be an effective backup solution providing that any system changes made after commissioning have been updated on the second computer. What generally tends to happen is that the system changes that a normal process or plant goes through during its life are not updated on the second computer, and so the second computer is outdated and not at the current version when you need it the most.<br></div><div class="wsite-spacer" style="height:50px;"></div><h2 class="wsite-content-title" style="text-align:left;"><u>SCADA Virtualisation Plan</u><br></h2><div class="paragraph" style="text-align:left;">Computer virtualisation has been around now for over 20 years and has some very nice features that suit the SCADA environment perfectly.<br></div><div class="paragraph" style="text-align:left;">Conventionally, an actual computer with an operating system like Microsoft Windows runs the SCADA program that the operators use to monitor and control the plant. This is currently the most common setup in the industry and probably the one that you are using now for your plant&rsquo;s SCADA system.<br></div><div class="paragraph" style="text-align:left;">Virtualisation is the future of computing and it is fast becoming the way Operations Technology (OT) is run. Virtualisation is where an operating system runs on an actual physical computer in a virtualised, or hypothetical, environment with special software. Virtualised operating systems (called a machines) can run concurrently on a single physical computer and can be built with various types of operating systems (Windows Server versions, Windows Desktop versions, Linux versions etc).<br></div><div class="paragraph" style="text-align:left;">The SCADA Virtualisation method is a virtual machine that is running the SCADA program. It looks and feels exactly like a &lsquo;normal&rsquo; SCADA computer would, it is just in a virtualised environment. One of the great benefits with any virtual machine is that it is not reliant on any particular type of computer or specific hardware. Basically, as long as you have a computer with the virtualisation software loaded, you can run the virtual machine on that computer. There is no need to worry about drivers, updates or various other software packages like Word, Excel, Outlook etc.<br></div><div class="paragraph" style="text-align:left;">Disaster recovery with the SCADA Virtualisation method is as simple as getting another computer, load the virtualisation software, and run the SCADA virtual machine. DONE!<br></div><div class="paragraph" style="text-align:left;">You can also do some very fancy stuff with virtual machines including load sharing and redundancy protection which are great for large scale SCADA systems. We use vmware virtualisation in our business for the many and various software programs we have to run for automation systems. The Virtual machine snapshot feature built into vmware is similar to the System Imaging method we discussed earlier. We often use snapshots when we are testing a new piece of software so if anything goes wrong, we can quickly get back to before we installed the software.<br></div></td></tr></tbody></table></div></div></div><div class="wsite-spacer" style="height:53.76666px;"></div><div><div style="height: 20px; overflow: hidden; width: 100%;"></div><hr class="styled-hr" style="width:100%;"><div style="height: 20px; overflow: hidden; width: 100%;"></div></div><div class="paragraph" style="text-align:left;">The best part of these various disaster recovery methods we have discussed above is that you can use several methods together to create a tailored solution that suits your needs. You might want to have a SCADA Virtualisation plan with the virtualisation software pre-loaded on a Spare SCADA PC, or you might like a Full Redundancy system with System Images backing up all your SCADA servers and workstations to the cloud for off-site disaster recovery protection.<br></div><div class="paragraph" style="text-align:left;">In any case, we cannot emphasis enough how important it is to back up your SCADA system, it's absolutely critical. The SCADA Disaster Recovery Plan is easily the most over looked part of any plant's maintenance routine, and failure to have an effective plan in place will have disastrous repercussions down the track when the entire plant is brought to its knees because the SCADA system has died.<br></div><div class="wsite-spacer" style="height:35.76666px;"></div><div class="paragraph" style="text-align:center;"><font size="4"><strong>If you would like assistance with your SCADA Disaster Recovery Plan,<br>give the team at Automated Electrics a call.</strong></font><br><br><font size="4"><strong>One of our SCADA experts will be able to guide you through the process and ensure you&rsquo;re protected when the SCADA gremlin hits your system!</strong></font><br></div>]]></content:encoded></item></channel></rss>