adding code for serial communication with the arduino