Giter Club home page Giter Club logo

Comments (12)

nicostudt avatar nicostudt commented on August 16, 2024 1

Hey,
it might be possible that the message definitions of our app and your compiled ROS version are different. I'll take a close look and test it again.

from ros-mobile-android.

nicostudt avatar nicostudt commented on August 16, 2024 1

Okay, I took a closer look on it.
We're currently depend on the message definitions of Melodic. In the BatteryState msg (Noetic) there is an additional field "temperature".

So there are several possibilities now:

  1. We have to include a new feature, where you could choose the ROS version in the app. This would be a huge pain thinking about the current implementation of ROSjava.
  2. You could change the message definition of BatteryState in Noetic to exclude "temperature".

from ros-mobile-android.

nicostudt avatar nicostudt commented on August 16, 2024 1

I've found a discussion about the changed BatteryState Msg. Apparently it seems that you can republish the BatteryState in the old format, but I'll have to take another look at it.

from ros-mobile-android.

nicostudt avatar nicostudt commented on August 16, 2024

We are eagerly waiting for an update of ROSjava to fix most of the problems here ... but unfortunately nothing happens for years.

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

I tried to change the BatteryState.h message to fix the error (Although, not recommended but just for testing). The error got fixed, but ROS Mobile app got crashed.

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

Yes, Thank you for your support.

I think, It's much better to go with 2nd option.
with second option do you mean, change the BatteryState.msg in /opt/ros/noetic or use a Custom msg based on BatteryState.msg without the temperature field.

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

Hi,

So, I defined BatteryState.msg as a custom msg in my_package without the temperature field (as you recommended). All the errors are gone and the app is also running fine.

But I am again unable to see any data on battery GUI.

This is the code for publishing the battery data:

          #include <my_package/BatteryState.h>

          ros::Publisher battery_pub = nh.advertise<my_package::BatteryState>("battery", 10);
          my_package::BatteryState batt_msgs;


          batt_msgs.header.stamp = ros::Time::now();
          batt_msgs.present = true;
          batt_msgs.percentage = percentage_cap;
          batt_msgs.voltage = voltage; 
          batt_msgs.current = current;

          battery_pub.publish(batt_msgs);

This is the msg definition: msg file

@nicostudt

from ros-mobile-android.

nicostudt avatar nicostudt commented on August 16, 2024

Mhh, do you use the Play Store version of the app or the custom build from this repo? My question would be if you have access to the logs and if there is an error issued.

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

I'm using the play Store version of the app.

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

So I tried to change the message definition of BatteryState in noetic to exclude the temperature field.
I used the rqt_graph to see the node communication. This is what I found,

  1. When I use sensor_msgs/BatteryState to publish the /battery topic. The battery node created by ROS Mobile is communicating with the battery topic. But I don't see the data on GUI.

  2. When I use my_package/BatteryState to publish the /battery topic. The battery node created by ROS Mobile is NOT communicating with the battery topic. And of course, I don't see the data on GUI.

have you tried the app with removing the temperature field withnoetic ?

from ros-mobile-android.

amjack0 avatar amjack0 commented on August 16, 2024

So, I tried the solution suggested in above discussion.
I wrote a node in between the GUI and BatteryState publisher, Which converts noetic msgs to melodic. It did not help either !
can you provide some help. I am out of options now ;(

from ros-mobile-android.

Chick92 avatar Chick92 commented on August 16, 2024

Having the same issue, any update on this?

from ros-mobile-android.

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.