Ingenious use of PLC internal power-down holding registers - Database & Sql Blog Articles

In designing a small PLC control system, it's common to need to modify internal data such as counter values, timer settings, or data registers to meet specific production requirements. Additionally, after the system is powered down, this data should be preserved within the PLC so that it can be retrieved and used upon re-powering. Many small PLCs now offer some form of power-down holding registers to store user-defined data during shutdown. However, due to cost constraints, manufacturers often limit the number of these registers available, which can become a problem when the number of adjustable data points exceeds the available registers. This limitation can reduce system flexibility, potentially affecting product quality or increasing costs. I encountered this issue while designing a hot air sewing machine for a garment factory. To address this, I developed a method to maximize the use of existing power-down registers without requiring additional hardware or higher-cost PLC models. The PLC used was the Panasonic FP0-C16T, with 16 adjustable data points. The internal power-down holding registers included 8 data registers (DT1652–DT1659) and 2 internal relays (WR61, WR62), each 16 bits in size. Conventional methods would only allow 10 adjustable data points, but I needed to handle 16. After analyzing the adjustment range, I found that most data only required values from 0 to 255 (i.e., 8-bit range). This allowed me to use one register to store two 8-bit values by splitting the 16-bit register into upper and lower 8 bits. Here’s how the program works: 1. **Power-On Initialization:** When the PLC starts, the pulse relay R9013 triggers once during the first scan cycle. It separates the upper and lower 8 bits of the power-down holding register DT1655 into two general data registers. - Instruction F65 performs a bitwise AND with hexadecimal FF, extracting the lower 8 bits and storing them in DT0. - A right shift instruction (F120 with K8) isolates the upper 8 bits and stores them in DT1. - The word transfer instruction (F0) moves data from DT10 to DT1 for further processing. 2. **Data Reassembly on Run:** During the second scan cycle, the pulse relay R9014 activates. - A left shift instruction (F121 with K8) shifts the data in DT0 to the upper 8 bits. - A bitwise OR instruction (F66) combines the shifted data from DT0 with the data in DT20 and writes it back to the power-down register DT1655. By using this approach, the system can store and retrieve 16 adjustable data points using just one 16-bit register, significantly improving flexibility without increasing costs. This technique allows for more efficient use of limited resources in small PLC systems, making it ideal for applications where cost and space are critical factors.

All Accessories Of Laser Level

Green Laser Protective Glasses,Laser Protection Glasses,Laser Protection Eyewear,Laser protection

Guangdong Tumtec Communication Technology Co., Ltd , https://www.gdtumtec.com

Posted on