Flip flop not working?

I will leave that post up as a lesson to myself.

I found the issue and fixed it, there was nothing wrong with the flip flop, there was a mov instruction about 20 rungs below that was setting B3:3/4.

Isn't there a proverb about not seeing forest through the trees?
 
Is B3:3/4 used anywhere else in the program?

Especially, does it have any other (U) coils?

EDIT: lol, yep, that'l do it...



B3:3 was used in MOV instruction. I had searched for B3:3/4 with no hits (beyond mine), but I did not search for B3:3. Lesson learned.
 
I like the code you wrote.
In the interest of learning, if you ever wanted to do a flip flop at a word level, this works pretty good. The nice thing about this one is that you can "flip/flop" multiple bits independently I.E. if you toggle bit "B9:0.0", bit "B9:1.0" will react. If you toggle bit "B9:0.4", bit "B9:1.4" will react and so on.

WORD_Level_flipflop.jpg
 
I like the code you wrote.
In the interest of learning, if you ever wanted to do a flip flop at a word level, this works pretty good. The nice thing about this one is that you can "flip/flop" multiple bits independently I.E. if you toggle bit "B9:0.0", bit "B9:1.0" will react. If you toggle bit "B9:0.4", bit "B9:1.4" will react and so on.

WORD_Level_flipflop.jpg


That's fancy and interesting. Thanks!
 
Mark on yours wouldn't the counter value be retentive? So you would need to be sure that whatever is happening with T4:0/DN is ok to start by itself after a reboot if it was on when plc went down.
 

Similar Topics

I am having this issue trying to figure out how to do this. I have a Hydraulic ram that travels when a machine is running. The ram extends to the...
Replies
31
Views
9,528
Hi everyone, I'm learning ladder logic and have built a flip flop circuit (see pic) from an online tutorial. Closing the switch A is meant to...
Replies
19
Views
6,936
I am calculating power factor from samples of voltage and current. Calculation is done by multiplying voltage and current samples. What Im...
Replies
0
Views
1,645
Hi all, my first post here, I've been lurking for a while. I'm a beginner and I hit a wall on one of my first projects I'm working on. I know it...
Replies
6
Views
2,548
Hi Everyone, I am trying to write a flip flop circuit with one input that changes the state of two outputs. If I press the button once it brings...
Replies
3
Views
3,254
Back
Top Bottom