ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

nmea_topic_driver is not publishing anything

asked 2018-01-23 15:05:09 -0500

taihu gravatar image

updated 2018-01-26 13:23:08 -0500

Hi, I created a rosbag that contains NMEA messages (nmea_msgs/Sentence), and I would like to generate sensor_msgs/NavSatFix messages.

I am working on simulating time, so I run:

rosparam set use_sim_time true

Then, I play the rosbag thats contains the NMEA messages

rosbag play --clock nmea_gps.bag

Then, I start the nmea_topic_driver to generate publish sensor_msgs/NavSatFix on /fix topic:

rosrun nmea_navsat_driver nmea_topic_driver

Finally, when I check with rostopic if there are message on /fix topic

rostopic echo /fix

WARNING: no messages received and simulated time is active.
Is /clock being published?

Any, idea of what is going on?

I check if nmea_topic_driver was subscribed to the NMEA messages properly, and it looks fine:

rostopic info /nmea_sentence 
Type: nmea_msgs/Sentence

Publishers: 
 * /play_1516740862743383627 (http://MS-7A15:46035/)

Subscribers: 
 * /nmea_topic_driver (http://MS-7A15:46775/)

I also checked if the NMEA messages were right, and they look fine too:

rostopic echo /nmea_sentence 

header: 
  seq: 0
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPRMC,152545.80,A,3301.9913392,S,06053.0775644,W,0.12,0.00,261217,0.0,E,D*3F\r\n"
---
header: 
  seq: 1
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPGGA,152545.80,3301.9913392,S,06053.0775644,W,5,09,1.0,52.356,M,17.442,M,0.2,*72\r\
  \n"
---
header: 
  seq: 2
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPGSA,A,3,02,12,24,25,29,,,,,,,,12.0,1.7,11.8,1*29\r\n"
---
header: 
  seq: 3
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GLGSA,A,3,75,76,86,87,,,,,,,,,43.1,15.6,40.1,2*03\r\n"
---
header: 
  seq: 4
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPGSV,2,1,05,02,52,107,35,12,61,145,38,24,49,007,37,25,48,217,36,1*6A\r\n"
---
header: 
  seq: 5
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPGSV,2,2,05,29,47,283,41,,,,,,,,,,,,,1*55\r\n"
---
header: 
  seq: 6
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GLGSV,1,1,04,75,42,053,37,76,75,160,36,86,72,178,39,87,41,315,35,1*7F\r\n"
---
header: 
  seq: 7
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPGST,152545.80,0.090,,,,0.081,0.061,0.194*78\r\n"
---
header: 
  seq: 8
  stamp: 
    secs: 1514301945
    nsecs: 488000000
  frame_id: "GPS-RTK"
sentence: "$GPVTG,0.00,T,0.00,M,0.12,N,0.06,K,A*26\r\n"
---

UPDATED: 01/24/2018

The output of rosnode info /nmea_topic_driver is:

rosnode info /nmea_topic_driver

Node [/nmea_topic_driver]
Publications: 
 * /fix [sensor_msgs/NavSatFix]
 * /rosout [rosgraph_msgs/Log]
 * /time_reference [sensor_msgs/TimeReference]
 * /vel [geometry_msgs/TwistStamped]

Subscriptions: 
 * /clock [rosgraph_msgs/Clock]
 * /nmea_sentence [nmea_msgs/Sentence]

Services: 
 * /nmea_topic_driver/get_loggers
 * /nmea_topic_driver/set_logger_level


contacting node http://MS-7A15:34339/ ...
Pid: 28973
Connections:
 * topic: /rosout
    * to: /rosout
    * direction: outbound
    * transport: TCPROS
 * topic: /nmea_sentence
    * to: /play_1516817666576416404 (http://MS-7A15:38155/)
    * direction: inbound
    * transport: TCPROS
 * topic: /clock
    * to: /play_1516817666576416404 (http://MS-7A15:38155/)
    * direction: inbound
    * transport: TCPROS

Thanks in advance

edit retag flag offensive close merge delete

Comments

You've done a good job of debugging things so far, could you also add the output of rosnode info /nmea_topic_driver so I can compare it with what I'm getting?

M@t gravatar image M@t  ( 2018-01-23 18:39:00 -0500 )edit

did you make DEB install? if so, delete the current package and install from source. it will help.

0xd1ma gravatar image 0xd1ma  ( 2018-01-24 00:56:53 -0500 )edit

@0xd1ma: could you clarify a bit why the debian pkg is not working? That would help future readers decide whether your advice still applies if/when the issues you see get fixed.

gvdhoorn gravatar image gvdhoorn  ( 2018-01-24 03:39:35 -0500 )edit

Thanks guys for the quickly response. I updated the question with the information that you asked me. I also to remove the DEB version and installed it from source and it neither work. Any other suggestion? Is the nmea sentence that I posted correct?

taihu gravatar image taihu  ( 2018-01-24 12:56:56 -0500 )edit

upload your bag file to the public repository

0xd1ma gravatar image 0xd1ma  ( 2018-01-25 01:58:19 -0500 )edit

Here is the gps_rtk_rosbag.

taihu gravatar image taihu  ( 2018-01-25 11:40:04 -0500 )edit

There's definitely something odd going on with your setup/bagfile. I can run nmea_topic_driver over bagfiles I've collected, and it works just fine, but when I try running it on yours, I don't get any output on /fix, just as you've described.

M@t gravatar image M@t  ( 2018-01-25 13:42:53 -0500 )edit

That is good, so there is a bug in the script that I am using for the creation of the rosbag from the nmea raw sentences (I upload the code of the script). Could you send me a few seconds of your rosbag? so I can figure it out what is going on?

taihu gravatar image taihu  ( 2018-01-26 05:27:09 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
-1

answered 2018-01-26 13:23:58 -0500

taihu gravatar image

The issue was solved when we removed the CR (Carriage Return) and the LF (Line Feed) control characters from the nmea sentences.

edit flag offensive delete link more

Comments

Could you please clarify how you removed those characters from the messages?

minipixel gravatar image minipixel  ( 2018-04-29 11:40:17 -0500 )edit

I just deleted the characters in the gps.log file that I used to create the rosbag file.

taihu gravatar image taihu  ( 2018-04-29 13:05:39 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2018-01-23 15:05:09 -0500

Seen: 1,193 times

Last updated: Jan 26 '18