2 Relays 120v coils

I have two 120v coil relays with NO & NC contacts. How do I program it to read the dry contacts when they are open and closed using pin 11 & 12? Can a ground signal be used to trigger it and if so how do I do this? I tried the 5v with a 330 resistor and ground
but no luck.

Yes, connect the NO terminal to one Arduino pin and the COM terminal to the Arduino's ground. Then set the pin to INPUT_PULLUP mode. You can then read if the contacts are open or closed with digitalRead().

I am new at this and as you can see, Would you happen to have an example of this?

Hello mega8270

Welcome to the worldbest Arduino forum ever.

Take a view here to gain the knowledge.

Have a nice day and enjoy coding in C++.

I was describing the way that button S3 is connected in the schematic posted by @paulpaulson.

Thank you and I will give it a shot.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.