© 2010 Ugur Akinci
DIP switches are electronic components frequently used on circuit boards (a.k.a. “motherboards”, “panels”, “control boards” or “controller boards”) to configure basic system behavior by keeping a circuit either open or closed, by default. Once you set the value of a DIP switch it remains the same until you change it manually.
First things first: the correct way of writing DIP is always with upper-case letters since it’s actually an acronym. It stands for “Dual In-Line Package” which describes the way terminals of this switch are physically lined up in two rows, opposing one another and soldered to different wires or board circuits.
Incorrect: “dip switch”
Correct: “DIP switch”
DIP switches are sometimes used as an alternative to Jumpers, which is another two-state (“on” or “off”) hardware components used to keep a circuit either open or closed, by default. But in my line of work I’ve seen a lot of control boards with both jumpers and DIP switches. So they are not mutually exclusive components at all.
A DIP switch has two possible states: ON or OFF, which corresponds to the digital values of “1” (one) or “0” (zero).
There are three main types of DIP switches:
1) Slide Style
2) Rocker Style
3) Rotary Style (Technically I’m not sure if it’s correct to call this a DIP switch because it’s not designed as a “Dual In-Line Package” device; but traditionally this device is classified as a DIP Switch as well.)
The total number of ways in which a DIP switch can be configured depends on the number of PINS (metal connection legs) that a DIP switch has. A DIP switch cannot have less than 2 pins (which would be used to open or close a single circuit). But customarily a slide- or rocker-style DIP switch comes with 6 or 8 switches arranged side by side in a block, which corresponds to 12 or 16 pins, respectively.
Since each possible switch position on an individual switch represents either a “1” (one) or a “0” (zero), a DIP switch block has 2 to-the-power-of N possible values, where N represents the number of individual switches. That’s why an 8-switch DIP switch, for example, has a total of 256 values (outcomes), representing 256 system behaviors.
SPECIAL CASE: The rotary-style DIP switch obviously has only one value at any given time, depending on the value selected.
The best way to document the values represented by a DIP Switch is through a table.
The columns of the table represent each individual switch. The rows of the table represent the possible outcomes or system behaviors engendered by various DIP switch positions.
Each cell of the table represents whether the corresponding switch is in the ON or OFF state. Express that state either by using the words “ON” and “OFF” or by a “Check Mark” and “X” icon.
You do not need to illustrate every single permutation of those permutations are dummies and do not have any real behaviors assigned to them. In other words, if a DIP switch configuration does not make difference whatsoever in system behavior, you are free to omit it. This becomes a space-saving tactic when for example you have a total of 256 possible combinations. When you are documenting a DIP switch with 8 switches, don’t feel obligated to create a table with 256 rows, for the reason explained above. Document only what counts.
Here is an example:
|Backup Turned Off||OFF||ON||OFF||OFF|
|Alarm Turned Off||OFF||OFF||OFF||ON|
|Backup and Alarm Activated||ON||ON||OFF||OFF|
|Both Backup and Alarm are Turned Off||OFF||OFF||ON||ON|
|System shut down if main voltage is over 12 V D.C.||ON||OFF||ON||OFF|
This method takes the above table and switches the columns and rows around. Now columns become the ON or OFF state. Rows describe each individual switch. And the cells illustrate the end-state or system behavior.
Here is an example:
|DIP Switch #||ON||OFF|
|1||Backup Activated||Backup Turned Off|
|2||Alarm Activated||Alarm Turned Off|
|3||Backup and Alarm Activated||Both Backup and Alarm are Turned Off|
|4||System shut down if main voltage is over 12 V D.C.||—|
(Photo Credits: Wikipedia and http://ca.digikey.com)