added rest mode by shaking device left to right