I have 14 bits, each is set when a particular fault occurs, the problem is once 1 fault occurs and the machine stops it then causes more "red herring" faults.
I need to detect which fault happened first and report this as the reason the machine stopped.
I can do it the long way:-
A M100.0
AN M100.1
AN M100.2
etc...
but this would result in 14 very similar networks, and what if my fault list grows to say 100?
Is there a quicker/more efficient way of detecting which bit was set first?