I'm not extremely familiar with Arduino development so I might be a bit off but some things I noticed:
color1,color2,color2,are not very descriptive names. If they corresponds to color channels they should be named accordingly likecolor2red are not very descriptive names. If they corresponds to color channels they should be named accordingly like, redgreen,, greenblue`,blue.You have a couple of methods which take a time like
delay_timeorgap_time. It might be an absolutely ingrained standard in Arduino development that times are always measured in milliseconds but appending the unit to the name likedisplay_time_msorgap_time_mswould make it clear to reader what the time unit should be.I'm not sure why you copy the random word you select into a buffer and then append it to a
Stringobject. It looks to me that this is an unnecessary temporary copy. If I read the documentation right this:
output = text + buffer;
essentially gets transformed into
output = text.concat(String(buffer))
(given that text and output are String object while buffer is a char[])
So to me this looks like it could be simplified to:
int rand = random(0,13);
char* random_word = (char*)pgm_read_word(&(string_table[rand]));
String text = "Your personalised reading: ";
String output = text + random_word;
which eliminates the requirement for the temporary buffer copy.