<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _update_state(self, change):

 """ Keep position and direction in sync with axis """

        self._block_updates = True
        try:
            self.position = self.axis.Location()
            self.direction = self.axis.Direction()
        finally:
            self._block_updates = False