Jump to content

Push-button input timing, 2 tasks on 1 input


Recommended Posts

Posted
Hi everyone, Could someone enlighten me if it possible to achieve following with my S7-226? I0.0 is a push-button Q0.0 is lightbulb1 Q0.1 is lightbulb2 Pressing I0.0 just once would bring Q0.0 up Pressing I0.0 for 3 seconds would ONLY bring Q0.1 up This seems pretty complex for me .. I am not pro on PLC, just got one because it interests me for some automation around the house. I've looked on my MicroWin 4.0 but ..... Thanks en regards, Jan
Posted
Should be possible. First thing to do it to determine whether it's a long button press or not. Run a timer for 3 seconds off that input. I would look at the falling edge of the input if the timer is not expired to set your Q0.0 on, or the completing of the timer to set Q0.1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...