Quote Originally Posted by cncmachineguy View Post
Steve, wonderful examples, I think th OP may have a few questions for you, especially in the last with port indexing. But why doesn't his work after he moved the IF into the switchloop section? BTW, he will still have problems with button press being 1 for a zillion loop iterations, don't ya think?

@Brian, if you press the switch repeatedly, will that make the other LED's light? If so, does it seem to be random as to which will light?
Many thanks Steve for those examples. I tried both of your last ones just above this post and neither seem to be working. It does not light upon circuit power nor if i press the button to cycle through the other colors.