ctit introduction motivation
play

CTIT Introduction Motivation Two trends in robotics Conflicting! - PowerPoint PPT Presentation

Connecting Two Robot-Software Communication Architectures: ROS and LUNA Communicating Process Architectures 2016, Copenhagen, DK W. Mathijs van der Wer ff , Jan F . Broenink University of Twente CTIT institute, Robotics & Mechatronics


  1. Connecting Two Robot-Software Communication Architectures: ROS and LUNA Communicating Process Architectures 2016, Copenhagen, DK W. Mathijs van der Wer ff , Jan F . Broenink University of Twente CTIT institute, Robotics & Mechatronics Enschede, Netherlands CTIT

  2. Introduction — Motivation • Two trends in robotics — Conflicting! • More complex algorithms - Computer vision, area mapping, planning • More light weight, energy efficiency - Mobile robots, unmanned aerial vehicles (drones) • Possible Solution • Offloading algorithms to base station - Development of algorithms easier - More resources, like computer power - Easier upgradable • Connection between two environments needed - Algorithms Robotic Operating System – ROS - - Loop Controllers, i.e. hard-real time code LUNA Universal Network Architecture -- LUNA - 2 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  3. Introduction — Some Background • Hard real time • Controlling robots, i.e. fast mechanics • LUNA run-time framework • Hard real-time execution, precompiled • Design Flow - Graphically designed CSP processes in TERRA, and verified - Code generated, linked to LUNA lib • ROS – Robot Operating System • Open source / large community • Publisher - Subscriber pattern: nodes and messages • Design Flow - Design algorithms and message types - Connect nodes via message exchange - (re) compile 3 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  4. Introduction — Prototype, earlier made • Prototype ROS-LUNA bridge made • Algorithms in ROS and hard real-time controllers in LUNA • Problem: ros :: Publisher pub = n. advertise <template T>(”topic”, 10); - so source-code level in ROS to be connected to precompiled library in LUNA • Bezemer et al. at ETFA 2015 • Prototype Resource-rich Platform Embedded Platform Plant • Based on ShapeShifter class LUNA comm mgr comm mgr • Integer LUNA → ROS luna-bridge Actuators app TCP/IP • Limited support messagetypes node PID - only basic datatypes Sensors raw msgs lib Hard Real-Time parameter setpoint topics topics ROS core Algorithm Environment 4 node Sensors W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  5. Design and Implementation • Essential Requirements • Versatile / Reusable ChannelManager Actuators LUNA bridge • Compiled program TCP/IP ROS- ROS LUNA application Complex algorithms Loop controllers/ CSP • SRT - HRT connection Sensors - Asynchronous data connection • Overview ROS network LUNA application ROS-LUNA bridge Robotic setup (User configured) (User configured) • Communication Embedded system Base station • LUNA • ROS 5 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  6. ROS-LUNA Bridge Architecture • Overview • Communication Subscriber ... ... Topic Listener • LUNA ROSChannelManager Subscriber LUNA application ROSChannels • ROS ROS network LUNA bridge (CSP) (Wireless) network Publisher Runtime Bind- ... connection ing Publisher Publisher ... Runtime Binding Helper Service ROS network LUNA application ROS-LUNA bridge ROS-LUNA bridge Network (User configured) (User configured) ROS-side LUNA-side Embedded system Base station 6 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  7. Implementation — Communication • Communication Protocol • Serialise, Deserialise Subscriber ... ... Topic Listener - to fill up TCP/IP packets ROSChannelManager Subscriber LUNA application use bandwidth effectively - ROSChannels ROS network LUNA bridge - tailored solution (CSP) (Wireless) network Publisher Runtime Bind- reduce overhead - ... connection ing Publisher • Extendible Publisher ... Listener ROSChannelManager • ROS channels ... Runtime Binding ROSChannels A bridge - >> Helper Service (CSP) (Wireless) network Runtime Bind- connection Publisher ROS network LUNA application ROS-LUNA bridge ROS-LUNA bridge Network (User configured) (User configured) ROS-side LUNA-side ... Runtime Binding Embedded system Base station Helper Service LUN A bridge ROS-LUNA bridge Network OS-side LUNA-side 7 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  8. Implementation — specific channels in LUNA • LUNA — ROS channels • Allows modeling in TERRA ... • Channel modifications ROSChannelManager LUNA application ROSChannels • non-blocking write to ROS (CSP) (Wireless) network - from HRT to SRT connection - 2 data buffers • blocking read from ROS ROSChannelManager LUNA application ... - synchronisation… Received Decode ROSChannel’s Read buffer TCP packet structure reader activation • Non-blocking read Buffer empty • using ALT: ROSread [] SKIP LUNA application ROS-LUNA bridge Decode Block Network (User configured) next field LUNA-side context Buffer empty Find Callback callback Dataleft Wait new Activate next Copy data Call callback TCP packet component Dataleft 8 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  9. Implementation — ROS topic listeners… • ROS — Topic Listeners • topic = data to transport Subscriber ... ... Topic Listener • run-time topic binding ROSChannelManager Subscriber LUNA application - specific Publisher ROSChannels ROS network LUNA bridge (CSP) • specific configuration (Wireless) network Publisher Runtime Bind- ... connection - through the network ing Publisher Publisher Subscriber ... Topic Listener ... Runtime Binding Subscriber • Implementation ROS network Helper Service LUNA bridge • ShapeShifter class (Wireless) network Publisher Runtime Bind- ... - publish & subscribe connection ROS network LUNA application ROS-LUNA bridge ing Publisher ROS-LUNA bridge Network Publisher (User configured) (User configured) ROS-side LUNA-side - without specifying data type • Needs specific Embedded system Base station Runtime Binding Helper Service - serialiser, deserialiser - RuntimeBindingPublisher ROS network ROS-LUNA bridge ROS-LUN - extended TopicListener Network (User configured) ROS-side Base station 9 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  10. Testing • Initial Tests • on bandwidth • packet loss • Verification, Performance • RBP - RuntimeBindingPublisher • Performance - Publishers - Subscribers • Demonstration • timing • robotic system 10 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  11. Initial Tests Additional traffic • Packet loss PC • to mimic WiFi • Additional traffic PC Switch PC104 • network sharing Data 20 Average Average 600 15 Response time (ms) Response time (ms) 400 10 200 5 0 0 0 10 20 30 40 50 0 5 10 11 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA (MiB/s) Loss(%) Additional traffic (MiB)

  12. Verification tests • Verify RuntimeBindingPublisher • correct serializing / deserializing • auto-generated ROS structure of test • time stamp test: 12 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  13. Performance Tests - Publishers • Five different implementations of ROS publishers • generic ROS Publisher in C++ • generic ROS Publisher in Python • RuntimeBindingPublisher with prior msg info • RuntimeBindingPublisher without prior msg info • simplified RuntimeBindingPublisher in Python • Tests • average of 100 tests • per test 50 x init and publishing of 100 samples • 10 tests in 1 run - 100 tests in 1 run makes ROS core crash • On intel i5@2.53 GHz, 4 GB RAM, Ubuntu 15.10, ROS Jade 13 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  14. Publishers Initialization Publish 4 83 . 66 • Initialisation 3 . 21 81 . 82 90 • RBPc++ slowest 3 2 . 45 - due to external Python helper node 2 . 25 Time(ms) - RBPc++2: Time(us) 60 2 not needed as used from previous call 1 . 61 - 1 . 58 • Python slower than C++ 30 . 47 29 . 91 - RBPPython slower than Python 30 17 . 51 1 additional fu calls needed - • Runtime • RBPs are comparable 0 0 - only initialisation is different Generic C ++ • RBP slower than C++ RBP C ++ - due to additional var name look ups RBP C ++ , 2 • Python slowest RBP P ython Generic P ython 14 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

  15. Performance Tests - Subscribers • Four different implementations of ROS subscribers • normal subscribers in C++ / Python • extended TopicListener in C++ / simple runtime binding in Python • Tests • custom type: header and 2 float64 • average of 100 test, for initialisation • 6,000 msg @ 200 Hz: - time stamp send as float64 - published over 4 topics, connected to 2 nodes 1 node C++, 1 node Python - both have runtime binding and normal node code - - received data elapsed time is measured and put in 2nd float64 - - analysed in analysis node - - delay: publisher + network + subscriber network delay can be subtracted as common factor - 15 W. Math ij s van der Werff, Jan F. Broenink Connecting ROS to LUNA

Recommend


More recommend