Sign in to follow this  
Followers 0
DonNH

Another ladder logic question

4 posts in this topic

Another simple problem I believe . . .

I'm turning on a motor, keeping it on for a specified time, then shutting it off.

The thing is, I have to use a function block to turn on the motor (ARCL connection with mobile robot).

So, I'm setting variables MotorOn to activate the timer once the initial function block is complete , and Timer_done to activate the function block to turn off the motor.

This works fine, unless I try to stop the motor before the timer has expired, by turning off the Start_motor switch. In that case, Timer_done never becomes True, so the motor continues indefinitely.

Seems like there should be a fairly simple way to activate the Motor_Off function block when the Start_motor switch is turned off.

 

 

Motor activate.png

Share this post


Link to post
Share on other sites

I would use a normally closed contact of the Start_motor put ahead of the Motor_Off function...?

Share this post


Link to post
Share on other sites

I thought I had already tried this (added as an OR branch), but I just did it and it works.

Looks wrong when monitoring as the rung activates as soon as the connection is made between the PLC and AMR, but that's correct.

motor off.png

Share this post


Link to post
Share on other sites

You can use TP instead of TON so you always get the same length output no matter how long Start_motor stays on (or doesn't).

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0