ua-sista / ua-ros-pkg

Automatically exported from code.google.com/p/ua-ros-pkg
0 stars 1 forks source link

controller_manager.py exception and joint controller not working after ROS upgrade #37

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
After upgrading my system, dynamixel_motor stopped working. First I get a 
division by zero exception. After I fixed this in the source, joint controller 
does not work.

When I start controller_manager.py, I get :

[INFO] [WallTime: 1366616184.935567] [0.000000] servo12_port: Pinging motor IDs 
1 through 2...
[INFO] [WallTime: 1366616184.995282] [0.000000] servo12_port: Found 2 motors - 
2 AX-12 [1, 2], initialization complete.
Exception in thread Thread-4:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 551, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 504, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/opt/ros/groovy/stacks/dynamixel_motor/dynamixel_driver/src/dynamixel_driver/dynamixel_serial_proxy.py", line 250, in __update_motor_states
    rates.append(1.0 / (current_time - last_time).to_sec())
ZeroDivisionError: float division by zero

I wonder why didn't I have the same error before. Perhaps resolution of 
rospy.Time.now() decreased. I fixed this problem by adding if to check if 
current > latest_time. After this the controller_manager did not fail anymore.

But now my jointcontroller does not communicate with the servos anymore. I see 
no serial traffic and the /state topic does not publish either.

This happened with latest binary for ROS Groovy/Ubuntu Precise

Original issue reported on code.google.com by ronald.t...@gmail.com on 22 Apr 2013 at 7:42

GoogleCodeExporter commented 9 years ago
Perhaps it was not due to upgrading my system, but something else. I restarted 
roscore and the issue went away.

Original comment by ronald.t...@gmail.com on 22 Apr 2013 at 8:10

GoogleCodeExporter commented 9 years ago
Ok, so there seems to be no problem with dynamixel code, right?

Original comment by areb...@gmail.com on 30 Apr 2013 at 7:31

GoogleCodeExporter commented 9 years ago

Original comment by areb...@gmail.com on 26 Jul 2013 at 9:23