Skip to content

Commit

Permalink
Merge pull request #40 from benmaidel/feature/configure_polling_rate
Browse files Browse the repository at this point in the history
configurable polling rate
  • Loading branch information
fmessmer authored Jul 17, 2024
2 parents 6bf72df + 22604d5 commit 1f96125
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion flexbe_core/src/flexbe_core/core/concurrency_container.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def __init__(self, conditions=dict(), *args, **kwargs):
super(ConcurrencyContainer, self).__init__(*args, **kwargs)
self._conditions = conditions
self._returned_outcomes = dict()
self._rate = rospy.Rate(100)
self._rate = rospy.Rate(200)

def sleep(self):
self.wait(seconds=self.sleep_duration)
Expand Down
3 changes: 2 additions & 1 deletion flexbe_core/src/flexbe_core/core/ros_state.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ class RosState(State):

def __init__(self, *args, **kwargs):
super(RosState, self).__init__(*args, **kwargs)
self._rate = rospy.Rate(10)
self._polling_rate = rospy.get_param_cached('/flexbe/polling_rate', 10)
self._rate = rospy.Rate(self._polling_rate)
self._is_controlled = False

self._pub = ProxyPublisher()
Expand Down

0 comments on commit 1f96125

Please sign in to comment.