# Turtlebot just stops moving even with the code executing

Hi! I am an Electrical Engineering student that really likes robotics. So I took up a class that tackled turtlebots. So below is a of my first code that in a given square space the bot would find the center. And I am using python as the programming language

Let me give a short explanation so basically I defined a function that would estimate values given a certain tolerance level. I know that python 3 already has a pre defined function that does exactly that but the OS(ubuntu) I was using somehow does not have that function, being a newbie I opt not meddle with the libraries and just decided to define a function. Any how the code estimates the distance in front of it and behind of it to tell whether to move forward. Also the code estimates the bots yaw to tell what direction to turn (towards the center).

if isclose(self.yaw,-1.56,0.0,0.3) or isclose(self.yaw,1.56,0.0,0.3) and not (isclose(self.yaw,0.0,0.0,0.3) or isclose(self.yaw,3.12,0.0,0.3)):
if not isclose(msg.ranges, msg.ranges,0.0, 0.2) and (isclose(self.yaw,0.0,0.0,0.15) or isclose(self.yaw,3.12,0.0,0.15) or isclose(self.yaw,-1.56,0.0,0.15) or isclose(self.yaw,1.56,0.0,0.15)):
print('WAT')
move.linear.x=0.1
move.angular.z=0.0
elif not isclose(msg.ranges, msg.ranges,0.0, 0.2) and isclose(self.yaw,-1.56,0.0,0.9) and msg.ranges > msg.ranges:
print('WAT1')
move.linear.x=0.0
elif not isclose(msg.ranges, msg.ranges,0.0, 0.2) and isclose(self.yaw,-1.56,0.0,0.9) and msg.ranges < msg.ranges:
print('WAT2')
move.linear.x=0.0
elif not isclose(msg.ranges, msg.ranges,0.0, 0.2) and isclose(self.yaw,1.56,0.0,0.9) and msg.ranges > msg.ranges:
print('WAT3')
move.linear.x=0.0
elif not isclose(msg.ranges, msg.ranges,0.0, 0.2) and isclose(self.yaw,1.56,0.0,0.9) and msg.ranges < msg.ranges:
print('WAT4')
move.linear.x=0.0