Hi , i'm new in arduino and I really need help in my code and thank you so much
// I need to generat 2 string from keypad and put them in A and B the probleme I have that B take always the value of A and I want It to take Also value from keypas not the same .
// I need to generate B in time i don't know how to change float or integer to time
(I wille compare it latter with DS3231 so i will make it in the same category (time) )
String A;
String B ;
char X1;
char X2;
int i=0;
int j=0;
void setup() {
lcd.init();
lcd.backlight();
}
void loop() {
if (key) {
if (IsNumber(key))
{
ProcessNumber(key);
}
}
bool IsNumber(char key)
{
if(key >= '0' && key <= '9')
return true;
return false;
}
void ProcessNumber(char key)
{
lcd.setCursor(0,1);
if(X1 == ' ')
i++;
A+= key;
lcd.print(A);
lcd.setCursor(6,1);
if(X2 == ' ')
j++;
B+= key;
lcd.print(B);
float Z = B.toInt();