{"id":7479,"date":"2024-12-13T18:40:43","date_gmt":"2024-12-13T18:40:43","guid":{"rendered":"https:\/\/bama.es\/plc-operation\/"},"modified":"2026-08-28T18:12:46","modified_gmt":"2026-08-28T18:12:46","slug":"plc-operation","status":"publish","type":"post","link":"https:\/\/bama.es\/en\/plc-operation\/","title":{"rendered":"PLC Operation"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><strong>Programmable Logic Controllers (PLCs)<\/strong> are the backbone of <strong>industrial automation<\/strong>, but their true power lies in their versatility and scalability. Here we explore, in detail, how PLCs work, what the operating cycle is, and their different modes. <br\/><\/p>\n\n<h2 class=\"wp-block-heading\"><strong>PLC Operating Cycle<\/strong><\/h2>\n\n<p class=\"wp-block-paragraph\">The operation of a PLC is based on a continuous and very fast cycle known as a <strong>scan cycle<\/strong>. <\/p>\n\n<p class=\"wp-block-paragraph\">The <strong>scan cycle<\/strong> of a PLC represents the complete sequence of steps that the controller performs during the <a href=\"https:\/\/bama.es\/en\/plc-programming-company\/\" data-type=\"page\" data-id=\"2310\">execution of its program<\/a>. This process ranges from reading inputs to updating outputs. It is called a &#8220;cycle&#8221; because the program execution is repetitive, and &#8220;<em>scan<\/em>&#8221; because of the constant review the PLC carries out on the status of inputs, outputs, and intermediate variables. This continuous flow ensures that the system responds in real time to any change in the process and consists of the following stages:   <\/p>\n\n<h3 class=\"wp-block-heading\"><strong>1. Reading inputs<\/strong><\/h3>\n\n<p class=\"wp-block-paragraph\">The PLC collects data from devices such as sensors, buttons, or meters. This data informs the system about the status of the process in real time. <\/p>\n\n<ul class=\"wp-block-list\">\n<li>Example: A proximity sensor detects if an object is on a conveyor belt.<\/li>\n<\/ul>\n\n<h3 class=\"wp-block-heading\"><strong>2. Program processing<\/strong><\/h3>\n\n<p class=\"wp-block-paragraph\">The CPU executes the program loaded into its memory, processing the input data according to predefined instructions.<\/p>\n\n<ul class=\"wp-block-list\">\n<li>Example: If the object is present, the program activates a robotic arm to move it.<\/li>\n<\/ul>\n\n<h3 class=\"wp-block-heading\"><strong>3. Updating outputs<\/strong><\/h3>\n\n<p class=\"wp-block-paragraph\">After processing the data, the PLC sends signals to actuators, such as motors or valves, to execute the necessary actions.<\/p>\n\n<ul class=\"wp-block-list\">\n<li>Example: The robotic arm moves the object to a different position.<\/li>\n<\/ul>\n\n<h3 class=\"wp-block-heading\"><strong>4. Diagnostics and internal tasks<\/strong><\/h3>\n\n<p class=\"wp-block-paragraph\">The PLC monitors its own status, checking for errors or faults in the system. If something is wrong, it generates alerts or activates safety mechanisms. <\/p>\n\n<div style=\"height:22px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"480\" src=\"https:\/\/bama.es\/wp-content\/uploads\/2024\/12\/Ilustracion-bama-16-1.jpg\" alt=\"plc operation\" class=\"wp-image-2653\" srcset=\"https:\/\/bama.es\/wp-content\/uploads\/2024\/12\/Ilustracion-bama-16-1.jpg 640w, https:\/\/bama.es\/wp-content\/uploads\/2024\/12\/Ilustracion-bama-16-1-300x225.jpg 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n<\/div>\n<div style=\"height:22px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n<h2 class=\"wp-block-heading\">PLC scan time: what is it and why is it so important?<\/h2>\n\n<p class=\"wp-block-paragraph\">The <strong>scan cycle time<\/strong> of a PLC refers to the time it takes for the controller to complete a full cycle of its operation: reading inputs, processing the user program, and updating outputs. Simply put, it is the time required for the PLC to perform one complete iteration of its work cycle. <\/p>\n\n<p class=\"wp-block-paragraph\">This time is measured in milliseconds (ms), and an acceptable average value is usually between <strong>20 and 40 ms<\/strong>. Ideally, a scan cycle of less than <strong>20 ms<\/strong> is optimal, and if you achieve less than <strong>10 ms<\/strong>, we can speak of an extremely efficient system. <\/p>\n\n<h3 class=\"wp-block-heading\">When should you worry about scan time?<\/h3>\n\n<p class=\"wp-block-paragraph\">If your scan cycle exceeds <strong>70 ms<\/strong>, you should start to worry. And if it reaches or exceeds <strong>100 ms<\/strong>, it is a clear sign that the PLC program is poorly designed. This may be due to unnecessary loops or the constant reading of an excessive number of variables, which unnecessarily slows down the system. While an occasional peak might be acceptable, maintaining a high average scan time indicates that the program needs an urgent review.   <\/p>\n\n<h2 class=\"wp-block-heading\">PLC Operating Modes<\/h2>\n\n<p class=\"wp-block-paragraph\">A PLC operates in different modes that determine how it interacts with the user program and the system to which it is connected. These modes are essential to ensure that the controller functions correctly at each stage of an industrial process. The four generic modes are:  <\/p>\n\n<ol class=\"wp-block-list\">\n<li><strong>RUN (Execution):<\/strong><br\/>In this mode, the PLC executes the user program continuously. All stages of the scan cycle are completed here: reading inputs, processing the program, and updating outputs. It is the standard operating mode when the system is in production.  <\/li>\n\n\n\n<li><strong>STOP (Stop):<\/strong><br\/>The PLC stops the execution of the user program and, instead, carries out its internal routines. This mode allows the user to monitor and program the PLC without affecting the physical outputs. <\/li>\n\n\n\n<li><strong>ERROR (Fault):<\/strong><br\/>If the PLC detects a critical error in the hardware or the user program, it stops execution and deactivates the outputs. This mode is designed to prevent system damage and ensure safety. The controller remains in this state until the problem is resolved.  <\/li>\n\n\n\n<li><strong>POWER-ON (Startup):<\/strong><br\/>This mode is activated when the PLC receives power. During this phase, it performs a self-diagnosis to check hardware integrity, connection status, and memory. After completion, the PLC automatically transitions to RUN, STOP, or ERROR mode, depending on the detected conditions.  <\/li>\n<\/ol>\n\n<h3 class=\"wp-block-heading\">Variants by Manufacturer<\/h3>\n\n<p class=\"wp-block-paragraph\">Each manufacturer may offer slight differences in operating modes. For example: <\/p>\n\n<ul class=\"wp-block-list\">\n<li><strong>OMRON:<\/strong> Includes modes such as <em>Program<\/em> (standby to send or receive the program) and <em>Monitor<\/em> (program execution with the option to monitor variables).<\/li>\n\n\n\n<li><strong>Allen-Bradley:<\/strong> Adds <em>REM<\/em> mode, which allows switching between other modes remotely.<\/li>\n<\/ul>\n\n<p class=\"wp-block-paragraph\">These modes ensure that the PLC can adapt to different operational situations, from adjustments and testing to full program execution in a production environment.<\/p>\n\n<div style=\"height:100px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n<div class=\"wp-block-cover\" style=\"margin-top:0;padding-top:4vw;padding-right:4vw;padding-bottom:4vw;padding-left:4vw;min-height:50vh;aspect-ratio:unset;\"><span aria-hidden=\"true\" class=\"wp-block-cover__background has-vivid-cyan-blue-background-color has-background-dim-100 has-background-dim\"><\/span><div class=\"wp-block-cover__inner-container is-layout-flow wp-block-cover-is-layout-flow\">\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p class=\"has-text-align-left has-text-color wp-block-paragraph\" style=\"color:#ffb23d;font-size:31px;font-style:normal;font-weight:700;letter-spacing:2px;line-height:0.9;text-transform:none\">We hope you found this article of interest. <\/p>\n\n\n\n<p class=\"has-text-align-left has-white-color has-text-color wp-block-paragraph\" style=\"font-size:31px;font-style:normal;font-weight:700;letter-spacing:2px;line-height:0.9;text-transform:none\">If you need any additional information on how PLCs work, please do not hesitate to contact us.<\/p>\n\n\n\n<div style=\"height:48px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<div class=\"wp-block-buttons is-content-justification-center is-layout-flex wp-container-core-buttons-is-layout-fe48e5de wp-block-buttons-is-layout-flex\">\n<div class=\"wp-block-button has-custom-font-size\" style=\"font-size:20px;font-style:normal;font-weight:700;letter-spacing:1px;text-transform:uppercase\"><a class=\"wp-block-button__link has-text-color has-background wp-element-button\" href=\"https:\/\/bama.es\/en\/contact\/\" style=\"color:#2c3066;background-color:#ffb23d;padding-top:32px;padding-right:48px;padding-bottom:32px;padding-left:48px\">contact us now<\/a><\/div>\n<\/div>\n<\/div><\/div>\n<\/div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Programmable Logic Controllers (PLCs) are the backbone of industrial automation, but their true power lies in their versatility and scalability. Here we explore, in detail, how PLCs work, what the operating cycle is, and their different modes. PLC Operating Cycle The operation of a PLC is based on a continuous and very fast cycle known [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":7480,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[21],"tags":[],"class_list":["post-7479","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-industrial-automation"],"acf":[],"_links":{"self":[{"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/posts\/7479","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/comments?post=7479"}],"version-history":[{"count":1,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/posts\/7479\/revisions"}],"predecessor-version":[{"id":7481,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/posts\/7479\/revisions\/7481"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/media\/7480"}],"wp:attachment":[{"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/media?parent=7479"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/categories?post=7479"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/bama.es\/en\/wp-json\/wp\/v2\/tags?post=7479"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}