Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
dynamic_graph_bridge
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Stack Of Tasks
dynamic_graph_bridge
Commits
f968fbed
Commit
f968fbed
authored
1 year ago
by
Olivier Stasse
Browse files
Options
Downloads
Patches
Plain Diff
[ros_python_interpreter] Add the possibility to get the callback_group of reentrant type.
parent
baa5b68a
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
include/dynamic_graph_bridge/ros_python_interpreter_server.hpp
+4
-1
4 additions, 1 deletion
...de/dynamic_graph_bridge/ros_python_interpreter_server.hpp
src/ros_python_interpreter_server.cpp
+4
-3
4 additions, 3 deletions
src/ros_python_interpreter_server.cpp
with
8 additions
and
4 deletions
include/dynamic_graph_bridge/ros_python_interpreter_server.hpp
+
4
−
1
View file @
f968fbed
...
...
@@ -85,8 +85,11 @@ class RosPythonInterpreterServer {
/**
* @brief start_ros_service advertize the "run_python_command" and
* "run_python_scripts" ros services
* @param qos: Quality of Service
* @param callback_group: Callback group
*/
void
start_ros_service
();
void
start_ros_service
(
const
rclcpp
::
QoS
&
qos
=
rclcpp
::
ServicesQoS
(),
rclcpp
::
CallbackGroup
::
SharedPtr
group
=
nullptr
);
protected:
/**
...
...
This diff is collapsed.
Click to expand it.
src/ros_python_interpreter_server.cpp
+
4
−
3
View file @
f968fbed
...
...
@@ -25,12 +25,13 @@ RosPythonInterpreterServer::RosPythonInterpreterServer()
RosPythonInterpreterServer
::~
RosPythonInterpreterServer
()
{}
void
RosPythonInterpreterServer
::
start_ros_service
()
{
void
RosPythonInterpreterServer
::
start_ros_service
(
const
rclcpp
::
QoS
&
qos
,
rclcpp
::
CallbackGroup
::
SharedPtr
group
)
{
run_python_command_callback_t
runCommandCb
=
std
::
bind
(
&
RosPythonInterpreterServer
::
runCommandCallback
,
this
,
std
::
placeholders
::
_1
,
std
::
placeholders
::
_2
);
run_python_command_srv_
=
ros_node_
->
create_service
<
RunPythonCommandSrvType
>
(
"/dynamic_graph_bridge/run_python_command"
,
runCommandCb
);
"/dynamic_graph_bridge/run_python_command"
,
runCommandCb
,
qos
,
group
);
RCLCPP_INFO
(
rclcpp
::
get_logger
(
"dynamic_graph_bridge"
),
"RosPythonInterpreterServer::start_ros_service - run_python_command..."
);
...
...
@@ -39,7 +40,7 @@ void RosPythonInterpreterServer::start_ros_service() {
std
::
bind
(
&
RosPythonInterpreterServer
::
runPythonFileCallback
,
this
,
std
::
placeholders
::
_1
,
std
::
placeholders
::
_2
);
run_python_file_srv_
=
ros_node_
->
create_service
<
RunPythonFileSrvType
>
(
"/dynamic_graph_bridge/run_python_file"
,
runPythonFileCb
);
"/dynamic_graph_bridge/run_python_file"
,
runPythonFileCb
,
qos
,
group
);
RCLCPP_INFO
(
rclcpp
::
get_logger
(
"dynamic_graph_bridge"
),
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment