flexivrobotics / flexiv_rdk

RDK (robotic development kit) for Flexiv robots. Supports C++ and Python. Compatible with Linux, macOS, and Windows.
Apache License 2.0
58 stars 18 forks source link

[BUG] Multi-thread race condition in flexiv::Gripper API #25

Closed pzhu-flexiv closed 8 months ago

pzhu-flexiv commented 1 year ago

Version information

Describe the bug When calling functions in flexiv::Gripper to send gripper commands while calling flexiv::Gripper::getGripperStates() in a separate thread, there's a chance a race condition happens in the communication resources and cause one of the function calls to fail.

Steps to reproduce

  1. Run example/basics6_gripper_control.cpp OR example_py/basics6_gripper_control.py for several times.
  2. Error can be triggered with probability.

Expected behavior No multi-thread race condition happens.

pzhu-flexiv commented 1 year ago

Will be fixed in v0.9.