lbr-stack / lbr_fri_ros2_stack

ROS 1/2 integration for KUKA LBR IIWA 7/14 and Med 7/14
https://lbr-stack.readthedocs.io/en/latest/
Apache License 2.0
121 stars 34 forks source link

Potential Error in CommandGuard #175

Closed StephanSchwarz96 closed 1 month ago

StephanSchwarz96 commented 1 month ago

Hello everyone,

I recently run into some issues with the received robot state data which lead me to digging into the lbr_fri_ros2 package. I am not sure, but i might found an error within the code in command_guard.cpp in line 53:

for (std::size_t i = 0; i < lbr_command.joint_position[i]; ++i) {

Unlike the other checks (for position or torque limits), this does not iterate over the size() but the value, which in my case always stops after the first iteration since my joint_1 was lower than 1. Am I missing something here?

Thanks for feedback :)

mhubii commented 1 month ago

oh this looks fishy :O, where in the code can this be found?

mhubii commented 1 month ago

thank you so much for sharing this @StephanSchwarz96 . This is now fixed, please pull the changes.

There are some changes on the way, which will make this system a bit more capable.

mhubii commented 1 month ago

closing this for now as resolved. Thank you again very much! Please feel free to reach out if you have any questions / re-open the issue etc

mhubii commented 1 month ago

hi @StephanSchwarz96 , this should now be fully resolved. Let me know if you have any other questions

If you could give some feedback on whether it works well now, that would be awesome, too!