Give binary values to my arduino inputs

the red rectangles belongs to the wiring of the cassette.
Connexion is done with DB connectors.

image