Skip to content

Commit

Permalink
Merge pull request #64 from ROBOTIS-GIT/ros2-devel
Browse files Browse the repository at this point in the history
Ros2 devel
  • Loading branch information
ROBOTIS-Will authored Apr 16, 2021
2 parents a97dfe1 + b0e30eb commit e007b20
Show file tree
Hide file tree
Showing 8 changed files with 81 additions and 45 deletions.
57 changes: 57 additions & 0 deletions .github/workflows/ros-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: ros2-devel

# Controls when the action will run. Triggers the workflow on push or pull request
on:
push:
branches: [ ros2-devel ]
pull_request:
branches: [ ros2-devel ]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
ros2-devel-ci:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ros_distribution:
# - dashing
# - foxy
# - galactic
- rolling
include:
# Dashing Diademata (May 2019 - May 2021)
# - docker_image: ubuntu:bionic
# ros_distribution: dashing
# ros_version: 2
# Foxy Fitzroy (June 2020 - May 2023)
# - docker_image: ubuntu:focal
# ros_distribution: foxy
# ros_version: 2
# Galactic Geochelone (May 2021)
# - docker_image: ubuntu:focal
# ros_distribution: galactic
# ros_version: 2
# Rolling
- docker_image: ubuntu:focal
ros_distribution: rolling
ros_version: 2
container:
image: ${{ matrix.docker_image }}
steps:
- name: Setup directories
run: mkdir -p ros_ws/src
- name: checkout
uses: actions/checkout@v2
with:
path: ros_ws/src
- name: Setup ROS environment
uses: ros-tooling/[email protected]
with:
required-ros-distributions: ${{ matrix.ros_distribution }}
- name: Build and Test
uses: ros-tooling/[email protected]
with:
package-name: turtlebot3
target-ros2-distro: ${{ matrix.ros_distribution }}
vcs-repo-file-url: ""
29 changes: 0 additions & 29 deletions .travis.yml

This file was deleted.

6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog for package hls_lfcd_lds_driver
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.0.2 (2021-04-15)
------------------
* fix laserscan bug
* rename nav2 params
* Contributors: Will Son

2.0.1 (2020-07-13)
------------------
* ROS 2 Eloquent Elusor supported
Expand Down
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# HLDS HLS-LFCD-LDS (LDS-01)
<img src="http://emanual.robotis.com/assets/images/platform/turtlebot3/appendix_lds/lds.png" width="400">

## ROS 1 Packages for LDS-01 Driver
|develop|master|Kinetic + Ubuntu Xenial|Melodic + Ubuntu Bionic|Noetic + Ubuntu Focal|
|:---:|:---:|:---:|:---:|:---:|
|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=develop)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=master)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=kinetic-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=melodic-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=noetic-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|
## ROS 2 Packages for LDS-01 Driver
|ros2-devel|ros2|Dashing + Ubuntu Bionic|Eloquent + Ubuntu Bionic|Foxy + Ubuntu Foxy|
|:---:|:---:|:---:|:---:|:---:|
|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=ros2-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=ros2)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=dashing-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=eloquent-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|[![Build Status](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver.svg?branch=foxy-devel)](https://travis-ci.org/ROBOTIS-GIT/hls_lfcd_lds_driver)|
[![kinetic-devel Status](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/workflows/kinetic-devel/badge.svg)](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/tree/kinetic-devel)

[![melodic-devel Status](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/workflows/melodic-devel/badge.svg)](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/tree/melodic-devel)

[![noetic-devel Status](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/workflows/noetic-devel/badge.svg)](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/tree/noetic-devel)

[![dashing-devel Status](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/workflows/dashing-devel/badge.svg)](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/tree/dashing-devel)

[![foxy-devel Status](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/workflows/foxy-devel/badge.svg)](https://github.com/ROBOTIS-GIT/hls_lfcd_lds_driver/tree/foxy-devel)

## ROBOTIS e-Manual for TurtleBot3 and LDS-01
- [ROBOTIS e-Manual for TurtleBot3 and LDS-01](http://turtlebot3.robotis.com/)
Expand Down
4 changes: 2 additions & 2 deletions launch/hlds_laser.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ def generate_launch_description():

Node(
package='hls_lfcd_lds_driver',
node_executable='hlds_laser_publisher',
node_name='hlds_laser_publisher',
executable='hlds_laser_publisher',
name='hlds_laser_publisher',
parameters=[{'port': port, 'frame_id': frame_id}],
output='screen'),
])
4 changes: 2 additions & 2 deletions launch/view_hlds_laser.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ def generate_launch_description():
return LaunchDescription([
Node(
package='rviz2',
node_executable='rviz2',
node_name='rviz2',
executable='rviz2',
name='rviz2',
arguments=['-d', rviz_config_dir],
output='screen'),
])
2 changes: 1 addition & 1 deletion package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>hls_lfcd_lds_driver</name>
<version>2.0.1</version>
<version>2.0.2</version>
<description>
ROS package for LDS(HLS-LFCD2).
The LDS (Laser Distance Sensor) is a sensor sending the data to Host for the simultaneous localization and mapping (SLAM). Simultaneously the detecting obstacle data can also be sent to Host. HLDS(Hitachi-LG Data Storage) is developing the technology for the moving platform sensor such as Robot Vacuum Cleaners, Home Robot, Robotics Lawn Mower Sensor, etc.
Expand Down
7 changes: 4 additions & 3 deletions src/hlds_laser_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ void LFCDLaser::poll(sensor_msgs::msg::LaserScan::SharedPtr scan)
{
good_sets++;
motor_speed += (raw_bytes[i+3] << 8) + raw_bytes[i+2]; //accumulate count for avg. time increment
rpms=(raw_bytes[i+3]<<8|raw_bytes[i+2])/10;

for(uint16_t j = i+4; j < i+40; j=j+6)
{
Expand All @@ -121,7 +120,9 @@ void LFCDLaser::poll(sensor_msgs::msg::LaserScan::SharedPtr scan)
}
}

scan->time_increment = motor_speed/good_sets/1e8;
rpms=motor_speed / good_sets / 10;
scan->time_increment = (float)(1.0 / (rpms*6));
scan->scan_time = scan->time_increment * 360;
}
else
{
Expand Down Expand Up @@ -172,7 +173,7 @@ int main(int argc, char **argv)

return 0;
}
catch (boost::system::system_error ex)
catch (boost::system::system_error& ex)
{
//ROS_ERROR("An exception was thrown: %s", ex.what());
return -1;
Expand Down

0 comments on commit e007b20

Please sign in to comment.