Error was not declared in this scope

Hola un saludo antes de todo, quiero aclarar que estoy comenzando con la programacion en arduino.

Pues desarrollando este programa me surgio este error, y por mas que trato de buscar la solucion no doy.

int bot []= {1,2,3};
int led[]= {4,5,6,7,8,9,10,11,12,13};
int numbots=3;
int numleds=10;
int tiemporet=400;
int tiemporetociosa=200;
int estepin;
int cuenta_alto=0;
int cuenta_der=0;
int cuenta_izq=0;
int cuenta_ocio;


boolean bot_alto=LOW;
boolean bot_derecha=LOW;
boolean bot_izquierda=LOW;


void setup() {

  for(estepin=0; estepin<numbots; estepin++)
  {
    pinMode(bot[estepin],INPUT);
  }

for(estepin=0; estepin<numleds; estepin++)
  {
    pinMode(led[estepin],OUTPUT);
  }
}


void loop() {

  for(estepin=0; estepin<numleds; estepin++)
  {
    digitalWrite (led[estepin],LOW);
  }

  bot_derecha = digitalRead (bot[0]);
  bot_alto = digitalRead (bot[1]);
  bot_izquierda = digitalRead (bot[2]); 
 
 if (bot_derecha==HIGH)
 {
  Derecha ();
 }
 else if (bot_alto==HIGH)
 {
  Alto ();
 }
 else if (bot_izquierda==HIGH)
 {
  Izquierda ();
 }
 else 
 {
  ociosa ();
 }
}

void alto() {

 if (cuenta:alto==1)
 {
  for (estepin=0;estepin<numleds;estepin++)
  {
    digitalWrite(led[estepin], HIGH); 
  }
 }
else
{
  for(estepin=0;estepin<numleds;estepin++)
  {
    digitalWrite(led[estepin], LOW);
  }
}
  delay(tiemporet);
  cuenta_alto++;
  if (cuenta_alto>1)
  {
    cuenta_alto=0;
  }
}

void izquierda() {

  switch(cuenta_izq)
  {
    case 0:

    digitalWrite(led[2], HIGH);
    digitalWrite(led[9], HIGH);
    digitalWrite(led[4], HIGH);
    break;

    case 1:

    digitalWrite(led[1], HIGH);
    digitalWrite(led[8], HIGH);
    digitalWrite(led[5], HIGH);
    break;

    case 2:

    digitalWrite(led[0], HIGH);
    digitalWrite(led[7], HIGH);
    digitalWrite(led[6], HIGH);
    break;
    default:
    ;// no hay instrucciones a realizar
  }
}
  delay(tiemporet);
  cuenta_izq++;
  if (cuenta_izq>3)
  {
    cuenta_izq=0;
  }
}

void derecha ()
{
 switch (cuenta_der)
 {
 case 0:
 digitalWrite (led[0],HIGH);
 digitalWrite (led[8],HIGH);
 digitalWrite (led[6],HIGH);
 break;
 case 1:
 digitalWrite (led[1],HIGH);
 digitalWrite (led[9],HIGH);
 digitalWrite (led[5],HIGH);
 break;
 case 2:
 digitalWrite (led[2],HIGH);
 digitalWrite (led[3],HIGH);
 digitalWrite (led[4],HIGH);
 break;
 default:
 ;
 }
 delay (tiempoRet);
 cuenta_der++;
 if (cuenta_der > 3)
 {
 cuenta_der = 0;
 }
 }

 void ociosa ()
 {
  digitalWrite (led[cuenta_ocio],HIGH);
  digitalWrite (led[cuenta_ocio+4],HIGH);
  delay (tiemporetociosa);
  digitalWrite(led[cuenta_ocio],LOW); 
  digitalWrite(led[cuenta_ocio],LOW);
  cuenta_ocio++;
  if (cuenta_ocio>3)
  {
    cuenta_ocio=0;
  }
  }

El error que manda es ¨derecha¨ was not declared in this scope

Espero algunos consejos de que puede ser, ya lo puse como int derecha pero sale otro error mas adelante en

derecha () ;

Con la mismo error, gracias espero su ayuda.

Fijate que has cerrado las llaves de la funcion izquierda antes de tiempo:

void izquierda() { // <- AQUI EMPIEZA

  switch(cuenta_izq)
  {
    case 0:

    digitalWrite(led[2], HIGH);
    digitalWrite(led[9], HIGH);
    digitalWrite(led[4], HIGH);
    break;

    case 1:

    digitalWrite(led[1], HIGH);
    digitalWrite(led[8], HIGH);
    digitalWrite(led[5], HIGH);
    break;

    case 2:

    digitalWrite(led[0], HIGH);
    digitalWrite(led[7], HIGH);
    digitalWrite(led[6], HIGH);
    break;
    default:
    ;// no hay instrucciones a realizar
  }
} // AQUI ACABA El RESTO DEL CODIGO QUEDA HUERFANO Y TIRA DE ERROR 
  // EN EL RESTO DE FUNCIONES.
  delay(tiemporet);
  cuenta_izq++;
  if (cuenta_izq>3)
  {
    cuenta_izq=0;
  }
}

Arreglando el "}" y poniéndolo en su lugar, da varios errores, pero son varios nombres de variables que has cambiado y son fáciles de localizar.

Hi,
Adjunto tu sketch con los erroes que tenia. Tenia muchos errore con letras mayuscalas. El problema es que cuando tienes un error la mayoria de las veces apunta a otro sitio. Tienes que tener cuidado.Cundo tiens problemas haz con el control seleccionado y la letra t te pone el sketch todos los brackets en linea y pudes ver donde tienes el error. Los errores los marque <<<<<<<<<<< error <<<<<<. Cuando veas uno es un error. Compara el sketch correjido con el tuyo.Suerte.

int bot [] = {1, 2, 3};
int led[] = {4, 5, 6, 7, 8, 9, 10, 11, 12, 13};
int numbots = 3;
int numleds = 10;
int tiemporet = 400;
int tiemporetociosa = 200;
int estepin;
int cuenta_alto = 0;
int cuenta_der = 0;
int cuenta_izq = 0;
int cuenta_ocio;
boolean bot_alto = LOW;
boolean bot_derecha = LOW;
boolean bot_izquierda = LOW;

//*****************************************
void setup() {

  for (estepin = 0; estepin < numbots; estepin++)
  {
    pinMode(bot[estepin], INPUT);
  }

  for (estepin = 0; estepin < numleds; estepin++)
  {
    pinMode(led[estepin], OUTPUT);
  }
}

//*******************************************
void loop() {

  for (estepin = 0; estepin < numleds; estepin++)
  {
    digitalWrite (led[estepin], LOW);
  }

  bot_derecha = digitalRead (bot[0]);
  bot_alto = digitalRead (bot[1]);
  bot_izquierda = digitalRead (bot[2]);

  if (bot_derecha == HIGH)
  {
    derecha();//<<<<<<<<<<<<Derecha()<<<<<<<<<<<<<<<<<<<<
  }
  else if (bot_alto == HIGH)
  {
    alto();//<<<<<<<<<<<<<<<<<<Alto()<<<<<<<<<<<<<<<<<
  }
  else if (bot_izquierda == HIGH)
  {
    izquierda();//<<<<<<<<<<<<Izquierda()<<<<<<<<<<<<
  }
  else
  {
    ociosa();
  }
}
//**************************************************
void alto() {

  if (cuenta_alto == 1)
  {
    for (estepin = 0; estepin < numleds; estepin++)
    {
      digitalWrite(led[estepin], HIGH);
    }
  }
  else
  {
    for (estepin = 0; estepin < numleds; estepin++)
    {
      digitalWrite(led[estepin], LOW);
    }
  }
  delay(tiemporet);
  cuenta_alto++;
  if (cuenta_alto > 1)
  {
    cuenta_alto = 0;
  }
}
//***************************************************
void izquierda() {

  switch (cuenta_izq)
  {
    case 0:

      digitalWrite(led[2], HIGH);
      digitalWrite(led[9], HIGH);
      digitalWrite(led[4], HIGH);
      break;

    case 1:

      digitalWrite(led[1], HIGH);
      digitalWrite(led[8], HIGH);
      digitalWrite(led[5], HIGH);
      break;

    case 2:

      digitalWrite(led[0], HIGH);
      digitalWrite(led[7], HIGH);
      digitalWrite(led[6], HIGH);
      break;
    default:
      // no hay instrucciones a realizar
     break;//<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< no tenia break <<<<<<<<<<<<<<<
  }
  //} //<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<estaba de mas <<<<<<<<<<<<<<<<<<<
  delay(tiemporet);
  cuenta_izq++;
  if (cuenta_izq > 3)
  {
    cuenta_izq = 0;
  }
}
//*****************************************
void derecha() {
  switch (cuenta_der)
  {
    case 0:
      digitalWrite (led[0], HIGH);
      digitalWrite (led[8], HIGH);
      digitalWrite (led[6], HIGH);
      break;
    case 1:
      digitalWrite (led[1], HIGH);
      digitalWrite (led[9], HIGH);
      digitalWrite (led[5], HIGH);
      break;
    case 2:
      digitalWrite (led[2], HIGH);
      digitalWrite (led[3], HIGH);
      digitalWrite (led[4], HIGH);
      break;
    default:
      break;   //<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
  }
  delay (tiemporet);//<<<<<<<<<<<tiempRet<<<<<<<<<<<<<<<<<
  cuenta_der++;
  if (cuenta_der > 3)
  {
    cuenta_der = 0;
  }
}
//****************************************
void ociosa()
{
  digitalWrite (led[cuenta_ocio], HIGH);
  digitalWrite (led[cuenta_ocio + 4], HIGH);
  delay (tiemporetociosa);
  digitalWrite(led[cuenta_ocio], LOW);
  digitalWrite(led[cuenta_ocio], LOW);
  cuenta_ocio++;
  if (cuenta_ocio > 3)
  {
    cuenta_ocio = 0;
  }
}
//*******************************************

Muchas gracias disculpen la tardanza pero trabajo toda la semana, lo reviso y les comento, salu2

¡¡¡Ya quedo!!! gracias victorjam y tauro0221