Abstract

AbstractReactive programming is an alternative to callback-based programming. This tutorial chapter first discusses the problems of asynchronous programming with callbacks and locks—the standard ROS 2 API—and then presents a way to overcome them using the reactive programming paradigm. We introduce RxROS: a new API for implementing ROS nodes, based on the paradigm of reactive programming. We demonstrate advantages on small code examples in a tutorial style using simple nodes written in RxROS for ROS 2, and show the results of performance experiments indicating that RxROS does not introduce any significant performance overhead. RxROS is available under a BSD license, with bindings for both ROS 1 and ROS 2, in both Python and C\(++\). The implementation of RxROS for ROS 2 is available at https://github.com/rosin-project/rxros2.KeywordsROS 2Reactive programmingRxCppRxPyTutorialsBasics & foundationsContributed ros packages

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.