Hello BlissEva
.
Looking at the code that you enclose in your post #1 reads as follows:
#define R1 RC0 // Row1 Port C BIT 0
#define R2 RC1 // Row2 Port C BIT 1
#define R3 RC2 // Row3 Port C BIT 2
#define R4 RC3 // Row4 Port C BIT 3
#define C1 RC4 // Column1 Port C BIT 4
#define C2 RC5 // Column2 Port C BIT 5
#define C3 RC6 // Column3 Port C BIT 6
#define C4 RC7 // Column4 Port C BIT 7
.
In Function Main says:
TRISC = 0xF0; // KeyPad. So, BITs 0, 1, 2 And 3 Are Outputs. BITs 4, 5, 6 And 7 Are Inputs.
.
Subsequently, through the rows, you shift a low level(0) and verify which column is low (0) to make a decision.
Now analyze the circuit is in the PDF document attached to you.
Your design should be working . . . Or not ??
Congratulations on getting the hardware to work, that is an important stating point.Thankyou so much! my circuit finally is now working.
btw do you all have any idea for displaying two digit number??
You got me thinking now, Ernie...There are probably more (correct) ways to do this than there are programmers who have done it.
now my lcd can only show one digit number when i press it. how to make it to two digit like using some kind of array? or buffer?Hello BlissEva
.
What do you mean: you know how to make them display in 2digit?
Maybe that pressing the second key on the keypad displayed on the LCD 2 numbers.
But. . . then what to do ??
.
What is the whole idea ??
.
depends what you're doing with the input.now my lcd can only show one digit number when i press it. how to make it to two digit like using some kind of array? or buffer?
char Buffer[] = " "; // two blank spaces
key_get = keypad_wait();
WriteChar(key_get);
key_get = keypad_wait(); // get a new character
Buffer[0] = Buffer[1] // shift the old character
Buffer[1] = key_get // inser the new character
SetCursor(2,0); // point to starting place on screen
WriteString(Buffer); // print our two character string