// This example reads the X- and Y-axis G-forces via analog // input pins 0 and 1, and sends them over the serial port. // They can be displayed using the "Serial Monitor" or // processed by an application running on the computer. // (based on Wiring example code by Hernando Barragán) void setup() { Serial.begin(9600); // start serial comm at 9600 bps } void loop() { Serial.print(analogRead(0), DEC); // print analog input 0 Serial.print(", "); Serial.print(analogRead(1), DEC); // print analog input 1 Serial.println(); // print newline character delay(100); // wait 100ms }