Skip to content

keivanzavari/ros-threading-model

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

threading-model

A repo to test the threading model in ros. The files are taken from the answer here.

C++

* rosrun threading_model cpp_publisher_node A
* rosrun threading_model cpp_publisher_node B

* rosrun threading_model cpp_subscriber_node C
* rosrun threading_model cpp_subscriber_node D

Python

* rosrun threading_model python_publisher_node A
* rosrun threading_model python_publisher_node B

* rosrun threading_model python_subscriber_node C
* rosrun threading_model python_subscriber_node D

results

If node A & B publish to the same topic and C listens,

  • in python there are two threads for the messages of A & B
  • in C++ there is only one thread per subscriber, so node C is running on one single thread listening to both messages of A & B. If you create a node D that also listens to this topic, then you get a new thread.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published