- Help Center
- Automation/Electrical
- Programmable Controllers
-
Pneumatics
- Air Cylinders
- Air Dryers
- Auto Switches
- Boosters
- Electric Actuators
- Fieldbus System/Serial Transmission System
- Fittings
- Modular F.R.L.
- Pressure Switches
- Regulators
- Rotary Actuators
- Solenoid Valve
- Temperature Control Equipment
- Vacuum Equipment
- Photoelectric Sensors
- Process Valves
- Valve Clamps and Accessories
- Pumps
- Additional Articles in Pneumatics
- Safety Valves
- Tubing
-
Hydraulics
-
Automation/Electrical
- Contact Sensors / Liquid Leakage Sensors
- Level Switches
- Basic Switches
- Limit Switches
- Push Buttons / Indicator Lamps
- Thumbwheel Switches
- Safety Limit Switches
- Temperature Controllers
- Counters
- Programmable Relays
- Programmable Controllers
- Safety Sensors
- Safety Door Switches
- Solid-state Relays
- Timers
- Inverters
- Power Supplies
- Axial Fans
- Wiring Systems
- Rotary Encoders
- Pressure Sensors
- Displacement Sensors/Measurement Sensors
- Ultrasonic Sensors
- Emergency Stop Switches
- Power Controllers
- Signal Converters
- Machine Automation Controllers
- RFID Systems
- Measuring / Motor Protective Relays
- Vision Sensors / Machine Vision Systems
- Photomicro Sensors
- Digital Panel Indicators
- Programmable Terminals
- Servomotors / Servo Drivers
- Proximity Sensors
- General Purpose Relays
- Fieldbus Communications
-
Safety
-
Website Help Center
Can the same DM address be used for the first and third, or second and third operand in a math instruction?
Yes. As shown in Figure 1, in a differentiated program where processing is completed with a single scan by turning ON the add command bit (CIO 0.00), there is no problem if the first (or second) operand are the same as the third operand, but after processing, the augend data stored in D100 will be deleted. For easy debugging or software maintenance, it is recommended to use a different DM Area address for the third operand.
Programming: CS1/CJ1-series Programmable Controllers
Figure 1
Explanation of Figure 1
Initially, the value 123 (BCD) is stored in D100, but when add command bit (CIO 0.00) turns ON, the addition process given below is executing in a single scan, and the value stored in D100 will be changed from 123 to 246.
123 (D100) + 123 (constant) = 246 (D100)
Note: The instruction in Figure 1 will execute each cycle. So when you want to perform the operation A + B = C in real-time when the add command bit (CIO 0.00) is turned ON, the DM address of C must be different from that of A and B. If the same address is used, the result data will be updated as many times as the instruction is scanned causing an incorrect value to be stored in the third operand.