#define xval A0
#define yval A1
#define button 2
void setup() {
// put your setup code here, to run once:
pinMode(button, INPUT_PULLUP);
Serial.begin(9600);
}
void loop() {
// put your main code here, to run repeatedly:
int x = analogRead(xval);
int y = analogRead(yval);
int sw = digitalRead(button);
Serial.print(x);
Serial.print(",");
Serial.print(y);
Serial.print(",");
Serial.println(sw);
delay(10);
}