Failed to display text on LCD using NodeMCU1.0

Hi everyone,
I am doing a small project to display text on LCD using NodeMCU1.0. The problem is that the text is not displayed when I upload the sketch "Blank screen only"?
Any help?

        #include <Wire.h> 
    #include <LiquidCrystal_I2C.h>
    
    // Set the LCD address to 0x27 for a 16 chars and 2 line display
    // Arduino UNO => PIN 4 = SCL, PIN 5 = SDA
    // NodeMCU Dev Kit => D1 = SCL, D2 = SDA
    LiquidCrystal_I2C lcd(0x27, 20, 4);
    
    void setup()
    {
    	// initialize the LCD
    	lcd.begin();
    	// Turn on the blacklight and print a message.
    	lcd.backlight();
    	lcd.print("Hello World");
    }
    void loop(){
    }

You haven't given nearly enough information for anyone to help you.

In no specific order:

  • What is NodeMCU1.0?
  • What display are you using?
  • What I2C adapter are you using
  • What Arduino device are you using
  • What version of the Arduino IDE are you using?
  • What I2C library are you using?
  • How did you come up with 0x27 for your I2C address?

You might want to search for I2C LCD using the search box at the upper right of the screen.

Don