Giter Club home page Giter Club logo

Comments (3)

AlgoryxJosef avatar AlgoryxJosef commented on September 17, 2024 1

Thanks for the feedback, I'll create a PR and link it from here soon.
Remark: I am not entirely sure how much time I will be able to spend on this, so if it halts, feel free to close this issue in the future if nothing happens. I will try to remeber to keep it updated though.

from ros2-for-unity.

adamdbrw avatar adamdbrw commented on September 17, 2024

I think that it is a reasonable justification for having an option for the user. The Asset is of course just a suggestion on how to use underlying ros2cs API.

As I see it, this is more of an option where to run the execution than a separate entity. I would opt for code reuse, as much as possible, perhaps the entire thing can be handled by a component parameter (a thread will be created by default, but if the parameter is set, we instead call the Tick() function directly from FixedUpdate). What do you think?

In any case, please feel welcome to submit a PR, we can discuss design in there.

from ros2-for-unity.

AlgoryxJosef avatar AlgoryxJosef commented on September 17, 2024

I'm actually going to close this issue since I currently have no plan on creating a PR; it has since the time of creating this issue become apparent that main threaded ROS2 polling (SpinOnce) has some big drawbacks, and for us we ditched the idea completelty. It had to do with the fact that Unitys FixedUpdate() is not executed "evenly". If set to 1000hz, it will typically execute a batch of FixedUpdate() as quickly as possible, and then do nothing until the next Update() cycle. In other words; it will not run once every millisecond. It may run 10 times in 1 millisecond, do nothing for 9 milliseconds, and then start over again. This article touches on this: https://johnaustin.io/articles/2019/fix-your-unity-timestep

from ros2-for-unity.

Related Issues (20)

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.