ITEM FOR A SOFTAIR GAME

I’m crazy for a week to try to figure out where the error lies in telling me the arduin verification when I try to load a program to run a countdown and other things that serve for a game called softai
I put you under the whole code and I tell you the mistake it is from PLEASE HELP ME

‘menuprincipal’ was not declared in this scope

/tmp/920426219/Time_BOMB_Airsoft_GAME/Time_BOMB_Airsoft_GAME.ino: In function ‘void loop()’:

/tmp/920426219/Time_BOMB_Airsoft_GAME/Time_BOMB_Airsoft_GAME.ino:194:17: error: ‘menuPrincipal’ was not declared in this scope

menuPrincipal();

^

exit status 1

#include <Wire.h>
#include <Keypad.h>
//#include <LiquidCrystal_I2C.h>
#include <LiquidCrystal.h>
/*
Arduino Bomb Pro

The circuit:

created 4,Sep, 2010
Modified 11 Nov 2015
by Ignacio Lillo

*/

//LiquidCrystal_I2C lcd(0x38,16,2);
LiquidCrystal lcd(7, 6, 5, 4, 3, 2);
const byte ROWS = 4; //four rows
const byte COLS = 4; //three columns
char keys[ROWS][COLS] = {
{‘1’,‘2’,‘3’,‘a’}
,
{‘4’,‘5’,‘6’,‘b’}
,
{‘7’,‘8’,‘9’,‘c’}
,
{’*’,‘0’,’#’,‘d’}
};

byte rowPins[ROWS] = {
12, 13, A5, A4}; //connect to the row pinouts of the keypad
byte colPins[COLS] = {
A3, A2, A1, A0
}; //connect to the column pinouts of the keypad

Keypad keypad = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );

char codeInput[8];
byte time[4];
boolean refresh=true;//1 refresh one time…
char password[8];
int key=-1;
char lastKey;
char var;
boolean passwordEnable=false;

//Buttons for lcd shield
char BT_RIGHT = ‘4’;
char BT_UP = ‘a’;
char BT_DOWN = ‘b’;
char BT_LEFT = ‘6’;
char BT_SEL = ‘d’; // Ok key
char BT_CANCEL = ‘c’;
char BT_DEFUSER = ‘x’; // not implemented

//leds

const int REDLED = 11;
const int GREENLED = 10;
//const int BLUELED = 12;
//RELAYPIN
boolean relayEnable = false;
const int RELAYPIN = 9;
//IS VERY IMPORTANT THAT YOU TEST THIS TIME. BY DEFAULT IS IN 1 SEC. THAT IS NOT TOO MUCH. SO TEST IT!
const int RELAY_TIME = 5000;

//TIME INTS
int GAMEHOURS = 0;
int GAMEMINUTES = 45;
int BOMBMINUTES = 4;
int ACTIVATESECONDS = 5;

boolean endGame = false;

boolean sdStatus = false; //search and destroy game enable used in config
boolean saStatus = false; //same but SAbotaghe
boolean doStatus = false; //for DEmolition
boolean start = true;
boolean defusing;
boolean cancelando;
// SOUND TONES
boolean soundEnable = true;
int tonepin = 8; // Pin 13 for the sound
int alarmTone1 = 700;
int alarmTone2 = 2600;
int activeTone = 1330;
int errorTone = 100;

unsigned long iTime;
unsigned long timeCalcVar;
unsigned long redTime;
unsigned long greenTime;
unsigned long iZoneTime;//initial time for zone
byte team=0; // 0 = neutral, 1 = green team, 2 = red team

void setup(){
lcd.begin(16, 2);
Serial.begin(9600);
lcd.setCursor(3,0);
tone(tonepin,2400,30);
lcd.print(“BLUECORE TECH”);// you can add your team name or someting cool
lcd.setCursor(0,1);
lcd.print(" AIRSOFT BOMB");// you can add your team name or someting cool
keypad.setHoldTime(50);
keypad.setDebounceTime(50);
keypad.addEventListener(keypadEvent);

//PinModes
pinMode(GREENLED, OUTPUT);
pinMode(REDLED, OUTPUT);
pinMode(RELAYPIN, OUTPUT);
// CONFIGURE THE BARS OF PROGRESS BAR
byte bar1[8] = {
B10000,
B10000,
B10000,
B10000,
B10000,
B10000,
B10000,
B10000,
};
byte bar2[8] = {
B11000,
B11000,
B11000,
B11000,
B11000,
B11000,
B11000,
B11000,
};
byte bar3[8] = {
B11100,
B11100,
B11100,
B11100,
B11100,
B11100,
B11100,
B11100,
};
byte bar4[8] = {
B11110,
B11110,
B11110,
B11110,
B11110,
B11110,
B11110,
B11110,
};
byte bar5[8] = {
B11111,
B11111,
B11111,
B11111,
B11111,
B11111,
B11111,
B11111,
};
byte up[8] = {
B00000,
B00100,
B01110,
B11111,
B11111,
B00000,
B00000,
};

byte down[8] = {
B00000,
B00000,
B11111,
B11111,
B01110,
B00100,
B00000,
};
lcd.createChar(0,bar1);
lcd.createChar(1,bar2);
lcd.createChar(2,bar3);
lcd.createChar(3,bar4);
lcd.createChar(4,bar5);
lcd.createChar(5,up);
lcd.createChar(6,down);
}

void loop(){
menuPrincipal();
}
void keypadEvent(KeypadEvent key){
switch (keypad.getState()){
case RELEASED:
switch (key){
case ‘d’: defusing=false;
break;
case ‘c’: cancelando=false;
break;
}
break;
case HOLD:
switch (key){
case ‘d’: defusing= true;
break;
case ‘c’: cancelando=true;
break;
}
break;
}
}

Well it's right. You are calling a function called menuPrincipal but in your code you haven't created any function by that name.

What do you expect this line to do?

  menuPrincipal();

In the future, to post code and/or error messages:

  1. Use CTRL-T in the Arduino IDE to autoformat your complete code.
  2. Paste the complete autoformatted code between code tags (the </> button)
    so that we can easily see and deal with your code.
  3. Paste the complete error message between code tags (the </> button)
    so that we can easily see and deal with your messages.
  4. If you already posted without code tags, you may add the code tags by
    editing your post. Do not change your existing posts in any other way.
    You may make additional posts as needed.
  5. Please provide links to any libraries that are used
    (look for statements in your code that look like #include ). Many libraries
    are named the same but have different contents.

Before posting again, you should read the three locked topics at the top of the Programming Questions forum, and any links to which these posts point.

If your project involves wiring, please provide a schematic and/or a wiring diagram and/or a clear photograph of the wiring.

Good Luck!

Nice question .... what do i expect that command to do .... i do not know i copied the code from who had already built it all
I do not know what to serve that command .... sorry so ..... https: //youtu.be/AbJjfZWwZbo this the link where I found the suitcase I build
If you can understand it ... I'm not capable of it ..... I'll understand if you'll look stupid .....
Sorry butter4088 next time I will try to do better .... sorry

REAL useful link is: http://www.instructables.com/id/ARDUINO-AIRSOFT-TIME-BOMB-GAME/
There is a zip file, all complete code ! What's the problem ?!?

The problem is that when I load that program I get the error I posted on
Sorry if I had posted in Italian .... I am Italian and more comfortable with the Italian .... I had posted before this mistake and before I notice the forum in Italian .... I will pay more attention

cosimo66: Cross-posting in Italian Forum, thread closed, continue in Italian.

Guglielmo