Next time, add
** **[code]** **
before your code and
** **[/code]** **
after your code. Makes it easier to read and easier to copy.
This is what your code now looks like
// this is factory config shield initialisation
LiquidCrystal lcd(8, 9, 4, 5, 6, 7);
// initialise the keypad
DFR_LCD_Keypad keypad(A0, &lcd);
#define btnSELECT 4);
int abc_key_in;
int read_LCD_buttons;
int diceOne;
int diceTwo;
void setup() {
lcd.begin(16, 2);
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("Press to dice");
abc_key_in = analogRead(0);
}
void loop() {
if (btnSELECT)
diceOne = random(1, 7);
diceTwo = random(1, 7);
if (diceOne + diceTwo == 7) {
lcd.clear();
lcd.setCursor(7, 0);
lcd.print("7");
lcd.setCursor(3, 1);
That does not seem to be your complete code or there are big parts missing. Each { needs to have a matching }. You will need to fix that first.
The line #define btnSELECT 4); should not have a semi-colon at the end. I suspect that you're missing a #include for the DFR_LCD_Keypad.
Have a look at this example: Arduino_LCD_KeyPad_Shield__SKU__DFR0009_-DFRobot