Diferencia entre revisiones de «Mecanismo de exposición para Láminas - Matilde, Andrés, Carla, Alejandra»

De Casiopea
Sin resumen de edición
Sin resumen de edición
Línea 15: Línea 15:
|Alumnos=Carla Gómez Guerra, Matilde Croxatto Ullrich, Andrés Aliaga Chandía, Alejandra Witto Royo
|Alumnos=Carla Gómez Guerra, Matilde Croxatto Ullrich, Andrés Aliaga Chandía, Alejandra Witto Royo
}}
}}
==Código para probar la funcionalidad de los 2 botones==


/*
/*

Revisión del 16:26 27 may 2022





Titulin,
Palabras Claveobjetoeducativo


TítuloMecanismo de rieles de exposición para Láminas
Tipo de ProyectoProyecto de Curso
Palabras ClaveArduino, interacción, motor, exposición
Período2022-2022
AsignaturaInteracción y Performatividad
Del CursoInteracción y Performatividad 2022
CarrerasDiseño, Interacción y Servicios"Interacción y Servicios" is not in the list (Arquitectura, Diseño, Magíster, Otra) of allowed values for the "Carreras Relacionadas" property.
Alumno(s)Carla Gómez Guerra, Matilde Croxatto Ullrich, Andrés Aliaga Chandía, Alejandra Witto Royo
ProfesorRenzo Varela


Código para probar la funcionalidad de los 2 botones

/*

 DigitalReadSerial
 Reads a digital input on pin 2, prints the result to the Serial Monitor
 This example code is in the public domain.
 https://www.arduino.cc/en/Tutorial/BuiltInExamples/DigitalReadSerial
  • /

// digital pin 2 has a pushbutton attached to it. Give it a name: int pushButton1 = 2; int pushButton2 = 4;

// the setup routine runs once when you press reset: void setup() {

 // initialize serial communication at 9600 bits per second:
 Serial.begin(9600);
 // make the pushbutton's pin an input:
 pinMode(pushButton1, INPUT);
 pinMode(pushButton2, INPUT);

}

// the loop routine runs over and over again forever: void loop() {

 // read the input pin:
 int buttonState1 = digitalRead(pushButton1);
 int buttonState2 = digitalRead(pushButton2);
 // print out the state of the button:

/* Serial.print("boton 1: ");

 Serial.println(buttonState1);  
 Serial.print("boton 2: ");  
 Serial.println(buttonState2);
 delay(100);        // delay in between reads for stability
  • /
 if(buttonState1==1){
   Serial.println("mueve motor 1");
   }
 if(buttonState2==1){
   Serial.println("mueve motor 2");
   }

delay(100); }