RSLogix 500

Thread Starter

TK33

Joined Sep 15, 2011
2
Using RSLogix to program Micrologix 1000.

I'm having problems writing a program that uses 1-push button to turn on LED then push the same button to turn the LED off.

I can use a seal-in circuit or a latch to turn it on but cant figure out how to write the next rung to turn it off with the same button.

Any suggestion?
 

ftsolutions

Joined Nov 21, 2009
48
Use a state variable to keep track of the LED state (ON |OFF). Simply toggle the variable from one state to the other each time the button is pressed and released. Have a rung simply turn the light on or off based on the state variable.
 

Thread Starter

TK33

Joined Sep 15, 2011
2
Im not quite sure if I understand how to set a state variable? Is that similar to setting the I/O to a simple 0;1?

The only thing I could imagine is a latch then seal the input then somehow unlatch using some parallel command..
 
Top