state machine calibrate working!