odd or even

VJTX

Member
Join Date
Oct 2007
Location
TEXAS
Posts
126
I would like to determine if a counter setpoint is odd or even. This is on a micrologix 1100 plc. Is the best way to do a div/2?
 
If least significant bit is 1 then it is odd, else it is even.

e.g. assuming T4:0

If T4:0.PRE/0 is "1" then is odd

[Edit - OK, timer/counter - same idea. You want I should actually read the posting carefully?]
 
Last edited:

Similar Topics

I have an Allen Bradley temperature switch that I am trying to use in studio 5000. I am getting the message "Unable to interpret the IODD file"...
Replies
0
Views
72
So I had an odd request from a customer for the above. I have written the logic and tested it all in one PLC with only using 7 outputs and 7...
Replies
15
Views
428
I have been requested to test this proportioning valve for PLC control of flow/pressure. Dwyer Series SVP Proportioning Solenoid Valve The flow...
Replies
10
Views
421
Howdy guys - Looking for some insight on the MAM instruction. Had an interesting one today: I performed a controller upgrade on an older system...
Replies
1
Views
437
Hi everyone, curious if anyone has ever witnessed the following comm error: A little history, I had a department PC die, WIN 7. Had to upgrade...
Replies
4
Views
625
Back
Top Bottom