Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Recieve RTCM messages from NTRIP caster and get RTK solution for ZED-F9P

License

NotificationsYou must be signed in to change notification settings

Mil1ium/NTRIP_ROS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 

Repository files navigation

First time to upload my code here. This is abeta version for testing.

This program helps you get RTCM messages from NTRIP caster and get RTK solution:

  1. Recieve PVT topic fromublox_driver;
  2. Generate GPGGA string by PVT message;
  3. Send GPGGA string to NTRIP server(NTRIP caster) by httplib.HTTPConnection, and get RTCM data from response;
  4. Send recieved RTCM data to Ublox-F9P module via UART when the port is opened and single point position valid;
  5. Reconnect if network failed.

NTRIP_ROS

CSDN blog :https://blog.csdn.net/Millium/article/details/125837995?spm=1001.2014.3001.5502

Realtime test uploaded on Bilibili :https://www.bilibili.com/video/BV1CW4y117Du/

1. Prerequisites

1.1 ROS

ROS melodic (tested)

1.2 Python and 3rdparty library

Python 2.7 is required, NOT Python 3.

httplib (if not installed, runpip install to install this module).

1.3 Test information

I tested this program in Ubuntu 18.04 (with ROS melodic and Python 2.7), it seems to work well.

But in Ubuntu 20.04 (with ROS noetic, Python 3 and http.client), errors occurred.

I did a lot of research, I think the main reason may be thathttp.client in python 3 DOES NOT supportICY 200 OKresponse header sent by NTRIP caster, but the problem does not exist in httplib.HTTPConnection in Python 2.7 .

2. Build this program

Clone the code to your workspace and:

catkin_make

3. Run with you F9P module

3.1 Install u-center

The version I'm using is v21.09 , you can test NTRIP username and password inReciever-NTRIP Client.

3.2 Configure PORT and RATE of your F9P module

Firstly you need to correctly configure UART port of your F9P module inConfigure-PRT, such asBaudrate andProtocol in/out.

In my case, I use UART1 to sendUBX-RXM-RAWX,UBX-RXM-SFRBX andUBX-PVT message via USB-UART module to my laptop (and parsed byublox_driver, published as ROS topic), and send RTCM message to UART2 via USB-UART module to F9P, soUBX inPotocol out of UART1 is needed, andRTCM inPotocol in of UART2 is needed.

Message rate inConfigure-RATE may also be set, for example 10Hz.

After configuration, you can see messages printed inPacket Console.

3.3 Enable PVT message

Because I'm usingublox_driver, I need to enableUBX-RXM-RAWX,UBX-RXM-SFRBX andUBX-PVT message inu-center.

Actually,onlyUBX-PVTmessage is needed for RTK. You can use other ublox driver to extractPVT message and publish as ROS topic soRAWX andSFRBX is not needed anymore. Or you could use ublox driver which supports NMEA, then you just need to enable NMEA-GxGGA and subscribe NMEA message and send it to NTRIP caster.

3.4 Run with your Ublox-F9P

  1. Plug in your F9P's UART ports to your computer via USB-UART module, and check ports' name, like/dev/ttyUSB0, then change theport name and baudrate inntripclient.py (F9P's UART2, for sending RTCM data to module) anddriver_config.yaml (F9P's UART1, for recieve PVT message from module) ofublox_driver, don't forget to obtain r/w permissions of the ports.

  2. Launchublox_driver, androstopic echo topic/ublox_driver/receiver_pvt, remember tosource devel/setup.bash in your terminal in ublox_driver workspace.

  3. Run roscore in a terminal:

roscore
  1. In the other terminal, run this program in your workspace:
source devel/setup.bashrosrun ntrip_ros ntripclient.py

If your network is fine, UART successfully opened and GNSS single point position is fixed, the recieved RTCM data is sent to UART2 of F9P module.

Then, wait forcarr_solnof topic/ublox_driver/receiver_pvtturning to2, which means RTK fixed solution (0 means no RTK,1 means RTK float solution),and enjoy it.

Note that RTK solution is obtained in topic/ublox_driver/receiver_pvt.

3.5 Hardware configuration

In my case, I'm using

  1. Beitian BT-F9PK4 module;
  2. Beitian BT-345 antenna;
  3. Quectel EC20 4G module;
  4. CH340 USB to UART module made by myself;
  5. Lenovo laptop with i5-8265U.

4. Reference

4.1 Msg files

ROS message fileGnssPVTSolnMsg.msg andGnssTimeMsg.msg are copied fromublox_driver. Many thanks to Dr. Cao for his work.

4.2 Code reference

Thanks to these code contributors:

ntrip_ros by tilk;

ntrip_client by LORD-MicroStrain;

RTK-NTRIP-RTCM by Archfx;

ntrip_ros by MikHut;

ntrip_ros by Road-Balance.

5. TO DO

TCP method (send RTCM data to a given port toublox_driver, likestr2str inRTKLIB) is not supported yet.

Problem inhttp.client in Python 3 might be solved byntrip_ros_python3, need to check it out later.

And usingsocket instead ofhttp.client may be a good idea but script written by myself does not work correctly for now, need to work it out later.

About

Recieve RTCM messages from NTRIP caster and get RTK solution for ZED-F9P

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp