Keypad input and output to LCD 20X4, please help me

Hi, just a newbie to keypad. Please help me with my problem about keypad.

here's my output In LCD:

" Welcome User!
Press * "

when the user pressed '*'

the LCD will be cleared "lcd.clear();"
and the user should able to input 5 numbers which is I am now confused.
void loop() {

char key=keypad.getKey();
lcd.print("Verification code:");
lcd.print("Press # ");

** key==NO_KEY;**
** {**
** count++;**
** if(count==5)**
** {**
** lcd.clear();**
** count=0;**


when i pressed '*', i should be able to input 5 numbers which i can't get after pressing *.

You've made enough posts to have read the first three posts to this Forum which detail how to post a question here. If you read those and follow what they say, you will get better responses to your question. Until we see evidence that you have at least invested the time to read those posts and act accordingly, you're going to you're going to wonder if someone yelling in the woods with no one to hear makes any sound at all.


Why are you comparing key and NO_KEY? You might as well put



Take a look at this here KeypadPassword

More keypad sketches in the Playground, follow this link, and go under Input / Output :: Keypad