当前位置:网站首页>ROS package NMEA_ navsat_ Driver reads GPS and Beidou Positioning Information Notes
ROS package NMEA_ navsat_ Driver reads GPS and Beidou Positioning Information Notes
2022-04-23 17:53:00 【ppipp1109】
Hardware :ATGM332D + Serial debugging tools + GPS The antenna
Software : ubunutu 18.04 + ros
1. A serial port Reading data
sudo apt install cutecom
sudo cutecom // Set up Baud rate 9600 You can see the feedback data
2. nmea_navsat_driver Use of the bag
sudo apt-get install ros-melodic-nmea-navsat-driver libgps-dev
Be careful :nmea_navsat_driver Provide four nodes :nmea_topic_driver,
nmea_serial_driver,nmea_topic_serial_reader and nmea_socket_drivernmea_topic_serial_reader node
This node reads... From the serial port GPS data , And then it's packaged as nmea_msgs/Sentence data format , Post topics nmea_sentence.
nmea_topic_driver node
This node subscribes to topic nmea_sentence, And then according to NMEA0184 Protocol analysis , And publish the parsed data , The release topic is : Longitude and latitude /fix, Speed /vel,gps Time /time_reference And heading angle /heading.
nmea_serial_driver node
This node reads data from the serial port , Directly analyze the published data , amount to nmea_topic_driver Nodes and nmea_topic_serial_reader A combination of nodes .
github Source code :https://github.com/ros-drivers/nmea_navsat_driver
3. Open new Terminal The window opens ROS System ( relevant ROS The environment create 、ROS Package compilation and other basic knowledge must be checked on the Internet first ), Input
roscore
Open another new Terminal Window Publishing (Publish) Locate module information , Input
rosrun nmea_navsat_driver nmea_topic_serial_reader _port:=/dev/ttyUSB0 _baud:=9600
When publishing positioning module information , The window will not look like cutecom Keep displaying the latest positioning data as in , Will prompt SyntaxWarning: The publisher should be created with an explicit keyword argument 'queue_size'., Can be ignored . The ROS The packet passes the data through /nmea_sentence This Topic released , To verify that the location data is published successfully , Let's open a new Terminal Window read /nmea_sentence Information in , Input
rostopic echo /nmea_sentence
4. function nmea_serial_driver node ;
It is necessary to close the second 3 All terminals in this section ,
roscd nmea_navsat_driver/launch/
sudo vim nmea_serial_driver.launch
The baud rate is modified as follows 9600
<launch>
<!-- A simple launch file for the nmea_serial_driver node. -->
<arg name="port" default="/dev/ttyUSB0" />
<arg name="baud" default="9600" />
<arg name="frame_id" default="gps" />
<arg name="use_GNSS_time" default="False" />
<arg name="time_ref_source" default="gps" />
<arg name="useRMC" default="False" />
<node name="nmea_serial_driver_node" pkg="nmea_navsat_driver" type="nmea_serial_driver" output="screen">
<param name="port" value="$(arg port)"/>
<param name="baud" value="$(arg baud)" />
<param name="frame_id" value="$(arg frame_id)" />
<param name="use_GNSS_time" value="$(arg use_GNSS_time)" />
<param name="time_ref_source" value="$(arg time_ref_source)" />
<param name="useRMC" value="$(arg useRMC)" />
</node>
Open a terminal usb assignment , start-up launch file
sudo chmod 777 /dev/ttyUSB0
roslaunch nmea_navsat_driver nmea_serial_driver.launch
Open a new terminal , View the current gps Information
rostopic echo /fix
Reference link :
2. # Call sensor data _ROS Of sensors GPS practice _glietwx The blog of -CSDN Blog
3.(1)GNSS drive nmea_navsat_driver Use of feature packs _Qi Xiang Qi Xiang's blog -CSDN Blog
4. week50 nmea_navsat_driver Read GNSS Location information - Simple books
版权声明
本文为[ppipp1109]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230549075769.html
边栏推荐
- Some questions some questions some questions some questions
- Double pointer advanced -- leetcode title -- container with the most water
- JS interview question: FN call. call. call. Call (FN2) parsing
- Leak detection and vacancy filling (VIII)
- Examination question bank and online simulation examination of the third batch (main person in charge) of special operation certificate of safety officer a certificate in Guangdong Province in 2022
- [appium] write scripts by designing Keyword Driven files
- ES6 face test questions (reference documents)
- Flask项目的部署详解
- 圆环回原点问题-字节跳动高频题
- Sword finger offer 03 Duplicate number in array
猜你喜欢
随机推荐
394. String decoding - auxiliary stack
JS forms the items with the same name in the array object into the same array according to the name
The JS timestamp of wechat applet is converted to / 1000 seconds. After six hours and one day, this Friday option calculates the time
Uniapp custom search box adaptation applet alignment capsule
Utilisation de la liste - Ajouter, supprimer et modifier la requête
cartographer_ There is no problem compiling node, but running the bug that hangs directly
C1 notes [task training part 2]
Kubernetes service discovery monitoring endpoints
Exercise: even sum, threshold segmentation and difference (two basic questions of list object)
MySQL进阶学习之SQL优化【插入,主键,排序,分组,分页,计数】
Operation of 2022 mobile crane driver national question bank simulation examination platform
Add animation to the picture under V-for timing
Summary of common server error codes
Hcip fifth experiment
Read software engineering at Google (15)
Add drag and drop function to El dialog
开源按键组件Multi_Button的使用,含测试工程
MySQL advanced index [classification, performance analysis, use, design principles]
[binary number] maximum depth of binary tree + maximum depth of n-ary tree
102. 二叉树的层序遍历