Python Forum
[PyQt] Trying to do an interface for our Turtlebot robot
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[PyQt] Trying to do an interface for our Turtlebot robot
#4
Thank you very much! Gribouillis,

I have solved my problems with the tabulation but it has the same errors on both files.

Error:
[INFO] [1572298461.772443]: Go to (1.22, 2.56) pose Traceback (most recent call last): File “ejecutaprueba4.py”, line 94, in window = Ui() File “ejecutaprueba4.py”, line 16, in init self.button.clicked.connect(self.ir(1)) File “ejecutaprueba4.py”, line 80, in ir success = self.goto(position, quaternion) File “ejecutaprueba4.py”, line 43, in goto self.move_base.send_goal(goal) AttributeError: ‘Ui’ object has no attribute ‘move_base’
Error:
Traceback (most recent call last): File “ejecutaprueba5.py”, line 23, in window = Ui() File “ejecutaprueba5.py”, line 17, in init irPuntoMapa = GoToPose() File “/home/mubita/go_to_specific_point_on_map.py”, line 41, in init self.move_base.wait_for_server(rospy.Duration(5)) File “/opt/ros/kinetic/lib/python2.7/dist-packages/actionlib/simple_action_client.py”, line 67, in wait_for_server return self.action_client.wait_for_server(timeout) File “/opt/ros/kinetic/lib/python2.7/dist-packages/actionlib/action_client.py”, line 584, in wait_for_server timeout_time = rospy.get_rostime() + timeout File “/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/rostime.py”, line 190, in get_rostime raise rospy.exceptions.ROSInitException(“time is not initialized. Have you called init_node()?”) rospy.exceptions.ROSInitException: time is not initialized. Have you called init_node()?
I will keep looking for the erros but I know I'm going to need help.

Thanky you very much and regards



(Oct-29-2019, 03:46 PM)Gribouillis Wrote: It seems that some parts of your code are not properly indented. For example in ejecutaprueba4.py, it is probable that line 15 and 16 should be part of the __init__() method and therefore more indented than what is shown in the above post.

Make sure that your editor inserts 4 spaces when you hit the tabulation key and fix the wrongly indented lines in your files first.

There seems to be a similar problem in ejecutaprueba5.py and also in go_to_specific_point_on_map.py at line 33 and later or at line 47 and subsequent lines, etc.

All these errors are fatal to your program.
Reply


Messages In This Thread
RE: Trying to do an interface for our Turtlebot robot - by antoninovara - Oct-29-2019, 06:52 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020