Code Monkey home page Code Monkey logo

rgbd's People

Contributors

matthijsburgh avatar svddries avatar reinzor avatar petervdooren avatar rayman avatar ar13pit avatar jlunenburg avatar dependabot[bot] avatar gustavodcc avatar larsjanssen1 avatar larsjanssentue avatar loyvanbeek avatar lfbferreira avatar p-ict0 avatar thijsbeurskenstue avatar timple avatar alberth avatar

Watchers

Tim de Jager avatar  avatar James Cloos avatar Kwin van der Veen avatar  avatar Erik Geerts avatar Max Baeten avatar Robin Soetens avatar  avatar Rokus Ottervanger avatar Tim Assman avatar  avatar Alex Andriën avatar TheToolman avatar  avatar Bob avatar Sam Aleksandrov avatar  avatar  avatar

rgbd's Issues

Shared Memory behaviour

If a client is created before a server, THAT client will reconnect to any server, if servers are closed and opened again. Any client that connects to an existing server, will not reconnect to another server, if the original server is closed.

Build fails

I am not sure if something in the build chain has changed, but using the newest docker image from osrf/ros kinetic-full I am getting build errors:

CMakeFiles/rgbd.dir/src/View.cpp.o: In function `main':
View.cpp:(.text+0x0): multiple definition of `main'
CMakeFiles/rgbd.dir/src/Server.cpp.o:Server.cpp:(.text+0x721): first defined here
collect2: error: ld returned 1 exit status
make[2]: *** [/build/devel/.private/rgbd/lib/librgbd.so] Error 1
make[1]: *** [CMakeFiles/rgbd.dir/all] Error 2
make: *** [all] Error 2

Removing say View.cpp from library rgbd in CMakeLists.txt results in linker errors. I am also getting linking errors in macOS.

Add proper testing

We should add proper testing of the rgbd system considering how often it breaks.
Currently the test file rgbd/test/serialization_gtest.cpp is symbolic at best.

Things that should be tested:

  • creating shared memory. verify memory with the specified name exists after creation
  • writing a new image to shared memory. verify the content of the shared memory is updated
  • reading shared memory when none exist. verify correct behaviour.
  • reading an image from shared memory. verify that the send image is identical to the received image.
  • destruction of shared memory.

Robust lifecycle of Sever/Client

Issues

  1. Server can't create new SHM, so server doesn't boot
  2. Clients don't switch between SHM and topic mode.
    • If in topic mode, don't switch to SHM if it comes online
    • If in SHM, doesn't switch to topic mode if SHM isn't written anymore.
  3. Server doesn't reconnect to ROS. (ROScore is rebooted)

Constraints

2 Needs to be solved before 1 as clients don't close the SHM at the moment. So the server can't create a new SHM. Because the old SHM is still open.
3 can be solved seperatly.

Proposed solutions

  1. Will be solved if clients close their SHM in case the old server dies.
  2. Servers will publish their hostname on a string topic with a frequency X. Clients will use SHM as long as hostname is published on the topic less than Y seconds ago. Otherwise client will switch to topic mode. Client will switch back in case the hostname is published again.
    Client will check for the hostname on a fixed rate, not on the nextImage call. So the SHM is closed quickly after the server is died and not on a nextImage call, which is not called with any fixed rate.
  • Server publishes hostname on string topic, in case ServerSHM is initialized. fb5b7b6, bb3a25c and b680941
  • ServerSHM opens SHM on initialization, but can only fill the header on first image
  • ClientSHM connects to an SHM with empty header
  • Client listens to hostname topic on a fixed (Wall)Rate and switches to and from SHM
  1. Check on a fixed rate if master is still ok,
if (!ros::master::check())
{
    // Make sure node will die
}

Make sure the node will restart in the service/launch file

  • Check master on a fixed rate, implemented in e2e000c
  • Make sure nodes restart in service/launch files

Tests

  • Standalone testing
  • Reconnecting to ROS
  • Client switching from SHM to topic mode
  • Client switching from topic mode to SHM
  • Robust reboot of Server, which requires that old SHM is closed before new server start.

Will fix #15

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.