byte const butt1 = 2;
byte const butt2 = 3;
byte const butt3 = 4;
byte const butt4 = 5;
byte const butt5 = 6;
byte const vertY = A0;
byte const horzX = A1;
boolean butt1val = 0;
boolean butt2val = 0;
boolean butt3val = 0;
boolean butt4val = 0;
boolean butt5val = 0;
int vertYval = 0;
int horzXval = 0;
void setup(){
Serial.begin(9600);
}
void loop(){
vertYval = analogRead(vertY);
Serial.print("Valore asse Y: ");
Serial.println(vertYval);
horzXval = analogRead(horzX);
Serial.print("Valore asse X: ");
Serial.println(horzXval);
delay(300);
butt1val = analogRead(butt1);
Serial.print("Valore butt 1: ");
Serial.println(butt1val);
butt2val = analogRead(butt2);
Serial.print("Valore asse 2: ");
Serial.println(butt2val);
butt3val = analogRead(butt3);
Serial.print("Valore butt 3: ");
Serial.println(butt3val);
butt4val = analogRead(butt4);
Serial.print("Valore asse 4: ");
Serial.println(butt4val);
delay(300);
}