You first have to tell the LCD you're using 4-bit mode. The programming manual for your LCD's controller chip should tell you the initialisation sequence that you need to achieve this.