-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from pika-spark/ros
Publish ROS sensor_msgs/Imu .
- Loading branch information
Showing
13 changed files
with
277 additions
and
134 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: ros2 | ||
|
||
on: | ||
push: | ||
paths: | ||
- ".github/workflows/ros2.yml" | ||
- "include/**" | ||
- "launch/**" | ||
- "src/**" | ||
- "CMakeLists.txt" | ||
- "package.xml" | ||
pull_request: | ||
paths: | ||
- ".github/workflows/ros2.yml" | ||
- "include/**" | ||
- "launch/**" | ||
- "src/**" | ||
- "CMakeLists.txt" | ||
- "package.xml" | ||
|
||
env: | ||
BUILD_TYPE: Release | ||
|
||
jobs: | ||
build: | ||
name: Build on ros2 ${{ matrix.ros_distro }} | ||
runs-on: ubuntu-22.04 | ||
strategy: | ||
matrix: | ||
ros_distro: [ humble ] | ||
|
||
steps: | ||
- uses: ros-tooling/setup-ros@v0.7 | ||
with: | ||
required-ros-distributions: ${{ matrix.ros_distro }} | ||
|
||
- name: Setup ros2 workspace | ||
run: | | ||
mkdir -p ${{github.workspace}}/ros2_ws/src | ||
- uses: actions/checkout@v4 | ||
with: | ||
path: 'ros2_ws/src/pika-spark-bno085-driver' | ||
submodules: true | ||
fetch-depth: 1 | ||
|
||
- name: colcon build | ||
run: | | ||
source /opt/ros/${{ matrix.ros_distro }}/setup.bash | ||
cd ${{github.workspace}}/ros2_ws | ||
colcon build --event-handlers console_direct+ |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,35 @@ | ||
<a href="https://pika-spark.io/"><img align="right" src="https://raw.githubusercontent.com/pika-spark/.github/main/logo/logo-pika-spark-bg-white.png" width="15%"></a> | ||
:sparkles: `pika-spark-bno085-driver` | ||
===================================== | ||
[![Smoke test status](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/smoke-test.yml/badge.svg)](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/smoke-test.yml) | ||
[![Build Status](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/ros2.yml/badge.svg)](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/ros2.yml) | ||
[![Spell Check status](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/spell-check.yml/badge.svg)](https://github.com/pika-spark/pika-spark-bno085-driver/actions/workflows/spell-check.yml) | ||
|
||
Linux user space driver for the [BNO085](https://www.ceva-dsp.com/wp-content/uploads/2019/10/BNO080_085-Datasheet.pdf) 9-DoF IMU driver. | ||
Linux user space ROS driver for the [BNO085](https://www.ceva-dsp.com/wp-content/uploads/2019/10/BNO080_085-Datasheet.pdf) 9-DoF IMU. | ||
|
||
**Note**: In order to run the BNO085 ROS driver on [Pika Spark](https://pika-spark.io/) take a look at ready-to-use build/run scripts at [pika-spark-container/ros-imu-bno085](https://github.com/pika-spark/pika-spark-containers/tree/main/ros-imu-bno085). | ||
|
||
<p align="center"> | ||
<a href="https://pika-spark.io/"><img src="https://raw.githubusercontent.com/pika-spark/.github/main/logo/logo-pika-spark-bg-white-github.png" width="40%"></a> | ||
</p> | ||
|
||
### How-to-build/run | ||
### How-to-build | ||
```bash | ||
cd $COLCON_WS/src | ||
git clone --recursive https://github.com/pika-spark/pika-spark-bno085-driver | ||
cd $COLCON_WS | ||
source /opt/ros/humble/setup.bash | ||
colcon build --packages-select pika_spark_bno085_driver | ||
``` | ||
|
||
#### How-to-run | ||
```bash | ||
cd $COLCON_WS | ||
. install/setup.bash | ||
ros2 launch pika_spark_bno085_driver imu.py | ||
``` | ||
|
||
#### How-to-visualize your IMU data | ||
```bash | ||
git clone https://github.com/pika-spark/pika-spark-bno085-driver && cd pika-spark-bno085-driver/docker | ||
./docker-build.sh | ||
sudo ./docker-run.sh | ||
sudo apt-get install ros-humble-imu-tools | ||
ros2 run rviz2 rviz2 | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import os | ||
from launch import LaunchDescription | ||
from launch_ros.actions import Node | ||
|
||
def generate_launch_description(): | ||
os.environ['RCUTILS_CONSOLE_OUTPUT_FORMAT'] = '[{severity}] [{time}]: {message}' | ||
|
||
return LaunchDescription([ | ||
Node( | ||
package='pika_spark_bno085_driver', | ||
executable='pika_spark_bno085_driver_node', | ||
name='pika_spark_bno085_driver', | ||
namespace='', | ||
output='screen', | ||
emulate_tty=True, | ||
parameters=[ | ||
{'imu_topic': 'imu'}, | ||
] | ||
) | ||
]) |
Oops, something went wrong.