I am from IT background so I don't have much knowledge on electrical. This is maybe a very simple question. I want to connect a switch to act as a master "on/off" to the IND.IO. If the switch is off, the program in loop will not be executed. According to arduino samples, I should use pull down resistor to get rid of the "floating" state in the digital input pin. Is it the same in IND.IO-1286? The switch has two NO ports and both ports will be connected when the switch is on. I am thinking to connect +V from power supply to first NO port and second NO port to one of the IND.IO digital pin as INPUT. Will it work? I want it to send signal HIGH (24Vdc from psu) to the input pin when the switch is on but worry I would damage the IND.IO if I wire it wrongly. The same power supply is used to power up the IND.IO. Please kindly advise. Thank you =)
I usually do the opposite for the very reason you state.
I write HIGH on the input to enable pull-up resistor and then connect the switch between the I/O and GND.
This way I feel more safe against mistakes.
But either way is just fine.
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!