DIP switches are used in PC expansion cards to select interrupt requests (IRQs) and memory addresses, allowing the device to work properly. This is usually done by setting the switches to specific positions according to the instructions given in the device manual.