MrDippy Posted November 26, 2019 Report Posted November 26, 2019 (edited) Hi all, This is one of those times, I just cannot see what I am doing wrong with this PLC program. It is for a FX5UC using GXWorks 3 in FBD/LD format. The program grown to such a size and suddenly started doing strange things. I managed to isolate the culprit code and modified it to run on its own. Expectations for the simple program is: When Button tag is set, the PLS will execute the proceeding instructions only once but only if the counter value is below 46. What is happening is that it increments continuously even when the BUTTON is no longer set. This also happens under simulation. Am I doing something totally wrong here? I've attached the GXW3 program and a snap shot of the program. SimpleTest2.gx3 Edited November 26, 2019 by MrDippy
FredrikS Posted November 27, 2019 Report Posted November 27, 2019 (edited) The compare (LT_E) will only update the output when EN is on, therefore you get strange behavior. Try this instead: Edited November 27, 2019 by FredrikS
MrDippy Posted November 29, 2019 Author Report Posted November 29, 2019 Thanks Frediks. I can see so many people falling into this situation if the EN in compare functions are not on continuously.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now