#include<LiquidCrystal.h>
LiquidCrystal lcd(13,12,11,10,9,8); //INITIALIZING LCD IN 4-BIT MODE
char c[15]={"Hello"};
String s;
void setup()
{
lcd.begin(16 , 2);
lcd.clear();
}
void loop()
{
int i,j,k=0,l=0;
lcd.clear();
lcd.setCursor(0,0);
lcd.print(":/");
delay(1000);
for(i=14;i>=0;i--)
{
k=0;
for(j=i;j<=13;j++)
{
lcd.setCursor(j,1);
lcd.print(c[k]);
delay(90);
k++;
if(i==0 && j==13)
goto xyz; //IF string reaches the first matrix drop each character one by one
//so it feels that the string is terminating
}
}
xyz:
if(i==0 && j==13)
{
while(k!=0)
{
lcd.setCursor(0,1);
for(i=k;i>=2;i--)
{
l=15-i;
lcd.print(c[l]);
delay(90);
}
lcd.setCursor(0,0);
lcd.clear();
lcd.print(": )");
k--;
}
}
}