I'm very new to Arduino and running into a probably stupid question...
I'm trying to read the button input simply as in the attached image, but when the button is pressed, there isn't any signal... However, when I change line 5 from "INPUT" to "INPUT_PULLUP", the signal shows even if it is reversed 1 and 0. I fail to understand why...
I'm using a 2-pin push button on a real Arduino, but it didn't work, so I try to replicate it in the emulator. My goal is to get a signal 0 when the button is not pressed and a 1 when it is pressed...
Actually, I'm not getting anything but 0 with the schematic I showed... But when I have INPUT_PULLUP instead of the INPUT, I have the reversed as you said...