GithubHelp home page GithubHelp logo

Comments (7)

stonier avatar stonier commented on July 19, 2024

Taking the simple loop program here and throwing in a ecl::SigSlotsManager<>::printStatistics(); at the end of the constructor I get:

Topics
  Name: /kobuki/controller_info
    # Subscribers: 0
    # Publishers : 1
  Name: /kobuki/stream_data
    # Subscribers: 1
    # Publishers : 1

Possible problems:

  1. You're not calling kobuki.init(parameters) anywhere
  2. The parameters are invalid (init will return with an exception, see here)

from kobuki_core.

hanxia312 avatar hanxia312 commented on July 19, 2024

I'm going crazy, when i'm in kobuki.cpp
Kobuki :: init (Parameters & parameters) {
...
Thread.start (& Kobuki :: spin, * this);
Ecl :: SigSlotsManager <> :: printStatistics ();
}
The print value is:
Topics
Name: / kobuki / controller_info
# Subscribers: 0
# Publishers: 1
Name: / kobuki / stream_data
# Subscribers: 0
# Publishers: 1
But when i am in simple_loop.cpp

Kobuki.init (parameters);
ecl :: SigSlotsManager <> :: printStatistics ();
prints the result:
Topics

The parameters are valid in kobuki.cpp, but in simple_loop.cpp call Kobuki.init(parameters) function, Topics did not print. Looking forward to your reply, thank you
By the way, this kobuki project is my cross compiler arm so library running on the development board.
Cross-compilation steps:
cd ~ / kobuki_core
export PATH = ~ / kobuki_core / src / catkin / bin /: $ {PATH}
catkin_make -DCMAKE_TOOLCHAIN_FILE = ~ / kobuki_core / src / catkin / catkin.toolchain.cmake
cd build;make install

catkin.toolchain.cmake:
SET (CMAKE_SYSTEM_NAME Linux)
SET (CMAKE_C_COMPILER "/ usr / bin / my-ndk-toolchain / bin / arm-linux-androideabi-gcc")
SET (CMAKE_CXX_COMPILER "/ usr / bin / my-ndk-toolchain / bin / arm-linux-androideabi-g ++")
SET (CMAKE_FIND_ROOT_PATH "/ usr / bin / my-ndk-toolchain / sysroot /")

from kobuki_core.

stonier avatar stonier commented on July 19, 2024

Try without the cross compiler. This shouldn't have any relation, but first thing to do when you have a problem that has no immediate leads - simplify what you are doing until something comes up.

Which branches of ecl and kobuki are you using?

from kobuki_core.

hanxia312 avatar hanxia312 commented on July 19, 2024

thank you very much for your reply! without cross compile and run simple_loop.cpp this project is successful. How do I run this project using cross compilation? Is there a problem with my cross-compilation steps? Ecl and kobuk's branch is downloaded at :
http://yujinrobot.github.io/kobuki/doxygen/enInstallationLinuxGuide.html

https://raw.githubusercontent.com/yujinrobot/kobuki_core/hydro/kobuki_core.rosinstall

Kobuki Core / Yujin stacks

Looking forward to your reply!

from kobuki_core.

stonier avatar stonier commented on July 19, 2024

Ach, pretty old sources. Yujin hasn't had anyone updating those...

All of those libraries are very stable, but there has been a few bugfixes over the years...I'd try the latest releases (used in ROS kinetic):

Looks like you're using the ndk cross compiler - making an android app based on the c++ lib? I think you're the first to try that I know of. Another company made a very simple java driver at one point but this should be better if it works. At any rate, it looks like sigslot publishers are not working for some reason. These are not rocket science though, but it might be that the NDK is having trouble with some of the template programming.

Can you create a very simple program that creates a signal and prints the statistics? Verify that it works on the non-cross compile and that it fails on the cross-compile. Then we can dig further there. I'd like to reproduce it here, but I don't have all of the infra/know how to get that running and to test it.

from kobuki_core.

stonier avatar stonier commented on July 19, 2024

That rosinstall has been updated... https://raw.githubusercontent.com/yujinrobot/kobuki_core/devel/kobuki_core.rosinstall

from kobuki_core.

stonier avatar stonier commented on July 19, 2024

Original problem has been resolved earlier in the thread.

from kobuki_core.

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.