Hi,
I had the same problem, and I realised that putting the dynamixel in wheel mode is the same as setting CW angle and CCW angle to 0:
rosrun dynamixel_driver set_servo_config.py 1 --cw-angle-limit=0 --ccw-angle-limit=0
"1" states for your motor ID. If you get the following message, then your motor is set to wheel mode:
Configuring Dynamixel motor with ID 1
Setting CW angle limit to 0
Setting CCW angle limit to 0
done
However, I found that there are some issues in this mode for AX-12A: for the range of angle values that are not available in standard mode, the velocity and load values are all wrong. Here are some values I get:
current load: 0.03515625
current vel = 0.79042471074
current load: 0.03515625
current vel = 0.79042471074
current load: 0.10546875
current vel = 0.37196456976
current load: 0.10546875
current vel = 0.37196456976
current load: 0.10546875
current vel = 0.37196456976
current load: 0.16796875
current vel = 0.0
current load: 0.16796875
current vel = 0.0
current load: 0.82421875
current vel = -27.7229843399
current load: 0.82421875
current vel = -27.7229843399
current load: 0.82421875
current vel = -27.7229843399
current load: 0.50390625
current vel = -7.96236657142
current load: 0.50390625
current vel = -7.96236657142
current load: 0.50390625
current vel = -7.96236657142
current load: 0.16796875
current vel = 0.0
current load: 0.16796875
current vel = 0.0
current load: 0.14453125
current vel = 0.13948671366
current load: 0.14453125
current vel = 0.13948671366
current load: 0.14453125
current vel = 0.13948671366
current load: 0.05078125
current vel = 0.6974335683
current load: 0.05078125
current vel = 0.6974335683
The range [0.03 0.05] for the load and [0.69 0.79] for the velocity are correct, but then they take unexpected values, such as 0.82 for the load and -27 for the velocity. Did anyone encountered such issue? I think the problem might be in the joint_position_controller.py file in the dynamixel_controller package, when state is defined with the function filter:
def process_motor_states(self, state_list):
if self.running:
state = filter(lambda state: state.id == self.motor_id, state_list.motor_states)
if state:
state = state[0]
self.joint_state.motor_temps = [state.temperature]
self.joint_state.goal_pos = self.raw_to_rad(state.goal, self.initial_position_raw, self.flipped, self.RADIANS_PER_ENCODER_TICK)
self.joint_state.current_pos = self.raw_to_rad(state.position, self.initial_position_raw, self.flipped, self.RADIANS_PER_ENCODER_TICK)
self.joint_state.error = state.error * self.RADIANS_PER_ENCODER_TICK
self.joint_state.velocity = state.speed * self.VELOCITY_PER_TICK
self.joint_state.load = state.load
self.joint_state.is_moving = state.moving
self.joint_state.header.stamp = rospy.Time.from_sec(state.timestamp)
self.joint_state_pub.publish(self.joint_state)
I just cannot find any description of this filter function to look into it.
If anyone has an answer for this, it would be very helpful.
Did u managed to apply torque control?