Time and Use of Accelerometer Data Rate

int prevTimer;  //get time of last reading
 ...
   prevTimer = millis(); //get a starting point for millisecond count

It is not a good idea to use int variables with millis(), because the time is returned as an unsigned long integer. Use unsigned long integer variables.