Hi everyone, I am using MX106T(2.0) connected to OpenCM904 and using Arduino IDE to upload the Dynamixel2Arduino library example codes.
I want to set/limit the velocity always constant, under the Current-based Position Control Mode. For that, Profile Velocity can be used. However the problem is; suppose using the compliant motion of DYNAMIXEL if I stop the servo rotation by an external force it stops which is great, but after removing that force the velocity varies and it exceeds the Profile Velocity to achieve the Goal Position.
The example code is attached here;
// Current Based Postion Contorl Mode in protocol2.0 (MX106)
dxl.torqueOff(DXL_ID);
dxl.setOperatingMode(DXL_ID, OP_CURRENT_BASED_POSITION);
dxl.torqueOn(DXL_ID);
dxl.writeControlTableItem(GOAL_CURRENT, DXL_ID, 20); //for Mx(2.0)
dxl.writeControlTableItem(PROFILE_VELOCITY, DXL_ID, 20); //for Mx(2.0)
if(dxl.setGoalPosition(DXL_ID, 8192)){
delay(5000);
DEBUG_SERIAL.print("Present Current Based Position : ");
DEBUG_SERIAL.println(dxl.getPresentPosition(DXL_ID)); DEBUG_SERIAL.println();
}
Is it possible or is there any way to keep the velocity not exceeding the Profile Velocity under the Current-based Position Control Mode when the resisting/stopping force is removed from the DYNAMIXEL?
Thanks a lot.