What are real code and complementary code in rotary DIP switches?

Good points, timo.

Thank you for the inspiration for this related post.

I agree that the actual device isn’t too important as it is easy to change the values in the code. However, at a system level the complementary switch may be better as it provides positive logic input to the microcontroller. That is assuming internal pull-up resistors are used. Less mental work and faster troubleshooting.

Then again, as you suggested, a single bit or zero-Ohm jumper will keep the production line running.

Have a good weekend,

APDahlen