Skip to content

Instantly share code, notes, and snippets.

@SaheblalBagwan
Created September 1, 2016 11:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SaheblalBagwan/7c4da4bc35c7ffc5e964e1c31c673497 to your computer and use it in GitHub Desktop.
Save SaheblalBagwan/7c4da4bc35c7ffc5e964e1c31c673497 to your computer and use it in GitHub Desktop.
#include "lcd.h"
int main()
{
/*Connect RS->P2.0, RW->P2.1, EN->P2.2 and data bus to P2.4 to P2.7*/
LCD_SetUp(P2_0,P2_1,P2_2,P_NC,P_NC,P_NC,P_NC,P2_4,P2_5,P2_6,P2_7);
LCD_Init(4,20);
LCD_DisplayString("Explore Embedded\n");
LCD_DisplayString("LCD 4-bit Mode\n");
LCD_DisplayString("20 x 4 \n");
LCD_DisplayString(":) :O");
while(1);
return (0);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment