def odom_cb(self, msg): self.pose = msg.pose.pose if not self.tmr: self.tmr = rospy.Timer( rospy.Duration(0.1), self.check_activity )