ESP8266 - PULLUP resistor using Arduino code
The NodeMcu has no pull-up on pins 12 and 14. The esp8266 has internal pull-up and you activate it with pin mode INPUT_PULLUP. Without activated internall pull-up, there is no pull-up for this pns.