Basic doubt in plc

Karoly

Member
Join Date
May 2012
Location
Doha
Posts
24
Hi all,

I am new to plc and new to here. I am learning PLC using the free software PSIM from learningpit.com.

I want to clarify how this code works. See the link

https://lh5.googleusercontent.com/-GuYyrvABsPQ/T6555vPQ9nI/AAAAAAAAAxI/zw-3mlkyIMs/s636/doubt.jpg

I have given two separate input to the same counter. I observe that when any of the inputs is high the counter continuously start counting like a timer, that too even when the other input is low. How this happens?

Thanks in advance
 
Don't use the same counter twice. Instead OR the two inputs into a single counter.

To understand what's going on, you have to think like the PLC thinks and understand that the PLC constantly runs the program, evaluating each rung of the ladder logic in sequence repeatedly. The counter increments its AC value each time the logic controlling changes from false to true.

For the case when I:100 is true and I:103 is false, when the PLC evaluates the first rung, the logic controlling the counter is true and the counter increments by one. In the very next rung the controlling logic is false. As a consequence, the next time the PLC evaluates the first rung, the controlling logic once again transitions from false to true and the AC value increments by one.
 

Similar Topics

Hi all, I have a noob question regarding data handling from sensors. I understand configurations and I/O mapping sensor input/output variables...
Replies
2
Views
220
Hello I am new here and new to PLC's, I wrote this program for a class that I am taking and my local tech school. The description is switch 7 will...
Replies
0
Views
414
Hello I am new here and new to PLC's, I wrote this program for a class that I am taking and my local tech school. The description is switch 7 will...
Replies
10
Views
1,975
I’m a bit stuck on HMI (KTP-1200) programming… See the picture attached. The PASS or FAIL box should only appear when the toggle switch is...
Replies
7
Views
1,072
Hey Programmers, Heres todays puzzle I was trying to solve... I have a Modbus TCP network with two Modicon M221 controllers live on my work bench...
Replies
0
Views
467
Back
Top Bottom