N00R

Can you please explain whats wrong with my coils?

Some of them turn True when receiving True Bool Value and some stay False?

Reply 0 0
N00R

Here's the project file

While running Simulation

Variable up0 up1 up2 should automatically turn true but only up1 turns true

same happens with almost all coils

 

Reply 0 0
thiagoralves
I haven't open your project file yet, but I'm pretty sure the "issue" is because you might be reusing your coils elsewhere on the program. As ladder logic is cyclic, if your coil is used somewhere else, its state after the end of the cycle will ultimately be the last state it received in the program. So, it doesn't matter if it set to true on the first rung, if at the last rung it is set to false. The final state will be false.
Reply 0 0
thiagoralves
That indeed is the case:
Coils.png 
You can only reuse coils in ladder logic that are of type Set or Reset, as that makes sense. Normal coils cannot be reused or their value will be replaced by whatever logic has on the next rung.
Reply 0 0
N00R
Okay that makes sense
I'll use set and reset coils for now or I'll use move instructions to change coil status
Thanks for help
Reply 0 0
hackaru
Hi Thiago,

I can use the SET or RESET coils on arduino is that normal ?
If i use a Coil with SET i wont get any output from the arduino
Reply 0 0
thiagoralves
Yes, you can use a SET coil with Arduino. What do you mean by not getting any output?
Reply 0 0
hackaru
I have a Dinput(ix0.1) and a SET Coil (qx0.0) attached to a led.
When I press the PB1(ix0.1) the Led won't light up.
What I am doing wrong?
The SET Coil only needs a pulse, right? 
Reply 0 0
Reply