need help storing text to scroll through 10lines on 4 line lcd display

Ok, maybe your not seeing anything because it does not know where to look for the strings. You declair the strings in another function but you not returning them. That or you need to send those strings into the lcddisplay function.

Try to break the code down and just use the rfid tags to put out a few simple messages to the LCD. Dont worry about anything else at the moment, just focus on the LCD output. Then when you can get that to work, put it in this code. You might need to tweak your functions, but you wont know if you don't do any tests.

i have tried that and it now says there are too many arguments in void

If you're looking for help on this, feel free to show us the code and any errors you get; we're not psychic.

we're not psychic

I thought I was once, but it turns out I was just psychotic. XD

when i first started i used this code and it printed to the lcd display fine

#include <LiquidCrystal.h>

LiquidCrystal lcd(4,5,6,7,8,9);
int data = 0;
int cardone[16] = {
  2,53,57,48,48,50,57,51,49,67,51,56,50,13,10,3};
int cardthree[16] = {
  2,53,57,48,48,50,57,52,55,50,69,49,57,13,10,3};
int cardfour[16] = {
  2,53,57,48,48,50,57,50,67,57,69,67,50,13,10,3};
int cardfive[16] = {
  2,53,57,48,48,50,57,55,66,48,49,48,65,13,10,3};
int newcard [16] = {
  0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
float pay = 0;
float total = 0;
int i = 1;
int items = 0;

void setup ()
{
  Serial.begin(9600);
  Serial.flush();
  lcd.begin (20,4);
  lcd.clear();
  lcd.setCursor(2,i);
  delay(1000);
  lcd.print ("Hello shopper");
  delay(5000);
  lcd.clear();
  totalpay();
}

void totalpay()
 {total=pay+total;
      delay (500);
  lcd.home();
  lcd.print ("items:");
  lcd.print (items);
  lcd.print (" total:");
  lcd.print (total,2);
  delay (1000);
  pay = 0;
  }

void loop()

{ 
  if (Serial.available() > 0)
  {
    delay(100);
    for (int z=0; z<16; z++)
    { 
      data=Serial.read();
      newcard[z] = data;
      Serial.flush();}
      lcd.setCursor(0,i);
  {
    if (newcard[9] == cardone[9]){
      lcd.print ("Heinz Baked Beans");
      pay=0.10;   
      i++;
      items++;
    }
    else if (newcard[9] == cardthree[9]) {
     lcd.print ("pint skimmed milk");
      pay=0.50;
      delay (100);
      i++;
      items++;
    }
    else if (newcard[9] == cardfour[9]) {
      lcd.print ("loaf white bread");
      pay =0.70;
      delay(100);
      i++;
      items++;
    }
    else if (newcard[9] == cardfive[9]) {
      lcd.print ("6 eggs");
      pay=0.25;
      delay (100);
      i++;
      items++;
    }
    else{
      lcd.print ("No match");
      i++;
    }
    {totalpay();}
  }
  }
  }

the problem with it was that it wrote over line 3 of the lcd display.

i needed to write new code to move all the lines up one and display the next line. i thought it best to store the lines in memory so i can then advance once again and introduce buttons to scroll up and down through the list.

at the moment i am just writting notes next to my new code so when i put it on here it will be easier to read.

my code is too big so i have attached it,

it seems that line 1 wont keep the text within it to show on the lcd display, when taken put in the subroutine lcddisplay.
can someone help as to why i cant store text and reuse it in a subroutine.

storing2memory.ino (10.2 KB)