Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ROS 2 husarion UGV #457

Merged
merged 129 commits into from
Dec 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
129 commits
Select commit Hold shift + click to select a range
a3a3656
driver state update
KmakD Aug 19, 2024
6862926
Ros2 lynx description (#390)
KmakD Aug 20, 2024
2b250a9
roboteq driver abstract class
KmakD Aug 20, 2024
c00c9a4
canopen controller abstraction
KmakD Aug 20, 2024
8921526
simplify canopen controller
KmakD Aug 21, 2024
f7fae9d
fix make
KmakD Aug 21, 2024
2162292
update roboteq_driver tests
KmakD Aug 21, 2024
cf7531f
move test files
KmakD Aug 21, 2024
368cb1a
Merge branch 'ros2-lynx-devel' of https://github.com/husarion/panther…
KmakD Aug 21, 2024
2683a91
update msgs names
KmakD Aug 22, 2024
baca331
update
KmakD Aug 22, 2024
28f0611
review fixes
KmakD Aug 22, 2024
61ea75d
update roboteq driver
KmakD Aug 23, 2024
860c013
rename canopen controller to manager
KmakD Aug 23, 2024
3df7dee
small fixes
KmakD Aug 23, 2024
f046a75
add roboteq driver boot tests
KmakD Aug 23, 2024
bf2b230
update roboteq tests
KmakD Aug 23, 2024
412b810
update panther_msgs version
KmakD Aug 23, 2024
3b4157a
Merge pull request #392 from husarion/ros2-driver-state-refactor
KmakD Aug 23, 2024
c2b4909
Merge branch 'ros2-lynx-devel' of https://github.com/husarion/panther…
KmakD Aug 23, 2024
2ed9521
rename motors_controller to robot_driver
KmakD Aug 26, 2024
30eb97a
add panther robot driver tests
KmakD Aug 26, 2024
0d52315
robot driver abstraction and panther implementation
KmakD Aug 26, 2024
beb6010
update roboteq data converter
KmakD Aug 26, 2024
3e7ce38
move data converters and error filter tests
KmakD Aug 27, 2024
fd3182d
remove bad prints
KmakD Aug 27, 2024
36d1ebd
review fixes
KmakD Aug 27, 2024
4140d11
mock first
KmakD Aug 27, 2024
16ee91b
Merge branch 'ros2-canopen-controller-abstraction' of https://github.…
KmakD Aug 27, 2024
da2da07
fix merge
KmakD Aug 27, 2024
f142baa
add lynx robot driver
KmakD Aug 27, 2024
6b465b1
move panther robot driver to separate file
KmakD Aug 27, 2024
ccb1a43
Merge branch 'ros2-devel' into ros2-lynx-sim
rafal-gorecki Aug 30, 2024
670137f
Save work
rafal-gorecki Aug 30, 2024
0c4ea85
ROS 2 canopen manager and roboteq driver refactor (#396)
KmakD Sep 2, 2024
7836eb3
Merge branch 'ros2-lynx-devel' of https://github.com/husarion/panther…
KmakD Sep 2, 2024
9769bbc
merge tests
KmakD Sep 2, 2024
e11b9ea
Save work
rafal-gorecki Sep 3, 2024
c056820
Ros2 lynx gpio tests (#401)
pawelirh Sep 4, 2024
b1a2bff
driver definition
KmakD Sep 4, 2024
1d8a416
Merge branch 'ros2-lynx-devel' into ros2-lynx-sim
rafal-gorecki Sep 4, 2024
bc80dae
CANopenSettings update
KmakD Sep 4, 2024
1f6cce9
uncomment cmakelists
KmakD Sep 4, 2024
30bc345
Merge branch 'ros2-lynx-devel' of https://github.com/husarion/panther…
KmakD Sep 4, 2024
5a20fe0
add roboteq robot driver abstraction
KmakD Sep 4, 2024
6b0cfe1
data timeout method
KmakD Sep 4, 2024
973ea36
Save work
rafal-gorecki Sep 5, 2024
40e3c17
update briefs
KmakD Sep 9, 2024
aece921
review fixes
KmakD Sep 10, 2024
ae591b3
fix test name
KmakD Sep 11, 2024
8e96e4e
test remove getters
KmakD Sep 11, 2024
fefc794
apply review suggestions
KmakD Sep 11, 2024
d47271b
Merge pull request #404 from husarion/ros2-lynx-robot-driver
KmakD Sep 12, 2024
25102d1
Working loading arguments from robot_configuration YAML (#413)
rafal-gorecki Sep 17, 2024
dbda457
Merge branch 'ros2-devel' into ros2-lynx-devel
rafal-gorecki Sep 17, 2024
a15858e
Merge branch 'ros2-devel' into ros2-lynx-sim
rafal-gorecki Sep 17, 2024
9c37f48
Merge branch 'ros2-lynx-devel' into ros2-lynx-sim
rafal-gorecki Sep 17, 2024
4904c3f
Update panther_gazebo/config/configuration.yaml
rafal-gorecki Sep 17, 2024
c4ec3c9
Ros2 lynx system (#412)
KmakD Sep 17, 2024
0fd544a
Update readme
rafal-gorecki Sep 17, 2024
c626efa
Merge branch 'ros2-lynx-devel' into ros2-lynx-sim
rafal-gorecki Sep 17, 2024
511214e
Add add_world_transform arg
rafal-gorecki Sep 17, 2024
2e481d0
Remove yaml with arg
rafal-gorecki Sep 18, 2024
6487785
Clean up changes
rafal-gorecki Sep 18, 2024
c1321bf
docs update
rafal-gorecki Sep 18, 2024
441a9fe
Z arg set to 0.0
rafal-gorecki Sep 18, 2024
fbc8d4c
push unsaved
rafal-gorecki Sep 18, 2024
c36470c
Add suggestions
rafal-gorecki Sep 19, 2024
7ac55f3
Readme
rafal-gorecki Sep 19, 2024
6aaa52f
Delete panther_version argument and fix controller launch to use robo…
rafal-gorecki Sep 19, 2024
2430738
Merge pull request #414 from husarion/ros2-lynx-sim
KmakD Sep 20, 2024
77ad3f6
Merge branch 'ros2-lynx-devel' into ros2-lynx-remove-version
rafal-gorecki Sep 20, 2024
21570ee
panther-verion -> use_adc_battery
rafal-gorecki Sep 20, 2024
c4b2b12
push unsaved
rafal-gorecki Sep 20, 2024
5f64694
Fix test
rafal-gorecki Sep 20, 2024
3aa73ef
Add lynx_description to pkg xml
rafal-gorecki Sep 20, 2024
6778b07
Fix wheel type path
rafal-gorecki Sep 20, 2024
340bacc
Delete param
rafal-gorecki Sep 20, 2024
9c0a8c1
Dawid suggestion
rafal-gorecki Sep 20, 2024
08ec819
Merge pull request #415 from husarion/ros2-lynx-remove-version
KmakD Sep 20, 2024
62e8436
Unify arguments and config names (#416)
rafal-gorecki Sep 30, 2024
f6531cf
New format of launch args
rafal-gorecki Oct 4, 2024
1abf58a
Add Lynx light animations (#418)
rafal-gorecki Oct 4, 2024
08c0a33
Revert unnecessary changes
rafal-gorecki Oct 4, 2024
fc14d19
Move use_ekf to localization.launch.py
rafal-gorecki Oct 4, 2024
fe544e1
Merge branch 'ros2-lynx-devel' into ros2-args-new-format
rafal-gorecki Oct 4, 2024
f2b0458
Push unsaved file
rafal-gorecki Oct 4, 2024
352a9ba
Merge pull request #420 from husarion/ros2-args-new-format
BOOTCFG Oct 7, 2024
5e66827
fix wheel radius
KmakD Oct 8, 2024
4912720
Merge pull request #423 from husarion/ros2-lynx-fix-wheel-radius
KmakD Oct 8, 2024
996baba
Add docs_new build check to workflow (#419)
rafal-gorecki Oct 9, 2024
07aa9af
Rename panther_can to user_can (#421)
rafal-gorecki Oct 10, 2024
85b72ff
Ros2 husarion ugv v2 (#422)
rafal-gorecki Oct 10, 2024
caaa60e
Update gpio controller (#425)
KmakD Oct 14, 2024
552a4c8
Merge branch 'ros2-devel' into ros2-lynx-devel
rafal-gorecki Oct 18, 2024
380f181
Add RViz launch
rafal-gorecki Oct 31, 2024
db610e8
pre-commit fix
rafal-gorecki Oct 31, 2024
b9420f5
Hide visualization
rafal-gorecki Nov 6, 2024
a2a9ee9
Move RViz arg
rafal-gorecki Nov 7, 2024
1ea46a0
Merge pull request #433 from husarion/ros2-add-rviz-launch
KmakD Nov 7, 2024
76df718
Update package.xml
rafal-gorecki Nov 7, 2024
77a1469
Update package.xml
rafal-gorecki Nov 7, 2024
2b40097
Merge pull request #437 from husarion/rafal-gorecki-patch-1
BOOTCFG Nov 7, 2024
be607f2
Generate node parameters from yaml files
miloszlagan Nov 7, 2024
66de8ed
Overwriting robot description (#440)
BOOTCFG Nov 8, 2024
b0600b3
Parameter type casts and typo fixes
miloszlagan Nov 19, 2024
8faab9c
Rework moving average logic
miloszlagan Nov 19, 2024
3c3a3ac
use configs from /config dir
KmakD Nov 20, 2024
9d5be9f
component file
KmakD Nov 21, 2024
993a8a3
Change lights BT param types
miloszlagan Nov 21, 2024
93b18fa
Change param type
miloszlagan Nov 22, 2024
46320ab
Merge pull request #438 from husarion/ros2-param-gen
miloszlagan Nov 22, 2024
b891a89
Review changes
miloszlagan Nov 22, 2024
72554b8
Use normal accumulation and division for MA calculation
miloszlagan Nov 22, 2024
9ba0c4e
Merge pull request #442 from husarion/ros2-battery-temp-fix
miloszlagan Nov 25, 2024
1c29f54
fix example
KmakD Nov 25, 2024
92f56ba
fix CHRG_DISABLE init state (#447)
KmakD Nov 28, 2024
5ff7a67
change error to warn
KmakD Nov 28, 2024
c05d73d
Merge pull request #444 from husarion/ros2-config-dir
KmakD Nov 29, 2024
c308444
Merge branch 'ros2-devel' of https://github.com/husarion/panther_ros …
KmakD Nov 29, 2024
bfaa42c
Merge pull request #448 from husarion/ros2-battery-warn
miloszlagan Nov 29, 2024
a80dfe5
Merge branch 'ros2-devel' of https://github.com/husarion/panther_ros …
KmakD Dec 4, 2024
450e189
use ROBOT_MODEL_NAME env
KmakD Dec 4, 2024
f09439a
Better battery estimation (#452)
KmakD Dec 5, 2024
b01865e
fix tests
KmakD Dec 5, 2024
99a62b5
Merge pull request #455 from husarion/ros2-lynx-merge
KmakD Dec 6, 2024
3045193
change panther_msgs branch
KmakD Dec 6, 2024
5855b70
change panther_msgs branch
KmakD Dec 6, 2024
05aab48
decrease cmd_vel_timeout
KmakD Dec 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 0 additions & 4 deletions .docs/panther_ros2_api.drawio.svg

This file was deleted.

4 changes: 4 additions & 0 deletions .docs/ros2_system_design.drawio.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 17 additions & 7 deletions .github/workflows/release-candidate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,31 @@ on:
workflow_dispatch:
inputs:
version:
description: Release candidate version. IMPORTANT - required format `X.X.X`, eg `2.0.1`.
description: Release candidate version (format `X.X.X`, e.g. `2.0.1`).
required: true
date:
description: Release candidate date stamp. IMPORTANT - required format `YYYYMMDD`, eg `20240430`.
description: Release candidate date stamp (format `YYYYMMDD`, e.g. `20240430`).
required: true

env:
RC_BRANCH_NAME: ${{ github.event.inputs.version }}-${{ github.event.inputs.date }}

jobs:
# TODO: Add unit testing for panther_ros when ready
check_docs:
name: Check docs build
runs-on: ubuntu-22.04
steps:
- name: Trigger repository build workflow
uses: convictional/[email protected]
with:
owner: husarion
repo: docs_new
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: test-release.yml
ref: master
client_payload: '{"husarion_ugv_branch": "ros2-devel"}'

# TODO: Add unit testing for panther_ros when ready
unit_test_panther_ros:
name: Run unit tests for panther_ros
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -55,7 +69,6 @@ jobs:
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: update-tags-in-compose.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"branch_name": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -76,7 +89,6 @@ jobs:
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: ros-docker-image.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"panther_codebase_version": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -98,7 +110,6 @@ jobs:
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: build_and_deploy_image.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"dev_image": "true",
Expand All @@ -121,7 +132,6 @@ jobs:
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: build_and_deploy_flash_os_image.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"image_tag": "${{ github.event.inputs.version }}"
Expand Down
77 changes: 21 additions & 56 deletions .github/workflows/release-project.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: Release Panther project
name: Release project

on:
workflow_dispatch:
Expand Down Expand Up @@ -30,19 +30,18 @@ env:
MAIN_BRANCH: ros2

jobs:
release_panther_msgs:
name: Release panther_msgs repository
release_project:
name: Release Husarion UGV project
runs-on: ubuntu-22.04
steps:
- name: Trigger repository release workflow
- name: Release panther_msgs repository
uses: convictional/[email protected]
with:
owner: husarion
repo: panther_msgs
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: release-repository.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"release_candidate": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -52,21 +51,14 @@ jobs:
"prerelease": "${{ github.event.inputs.prerelease }}"
}

release_panther_ros:
name: Release panther_ros repository
needs:
- release_panther_msgs
runs-on: ubuntu-22.04
steps:
- name: Trigger panther_ros release workflow
- name: Release panther_ros repository
uses: convictional/[email protected]
with:
owner: husarion
repo: panther_ros
github_token: ${{ secrets.GITHUB_TOKEN }} # Use the default GITHUB_TOKEN for local repository
workflow_file_name: release-repository.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"release_candidate": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -76,43 +68,29 @@ jobs:
"prerelease": "${{ github.event.inputs.prerelease }}"
}

rebuild_and_push_docker_images:
name: Rebuild panther docker images with new version
runs-on: ubuntu-22.04
needs:
- release_panther_ros
steps:
- name: Trigger repository build workflow
- name: Rebuild panther docker images with new version
uses: convictional/[email protected]
with:
owner: husarion
repo: panther-docker
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: ros-docker-image.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"panther_codebase_version": "${{ github.event.inputs.version }}",
"build_type": "development",
"target_distro": "humble"
}

release_panther_docker:
name: Release panther-docker repository
needs:
- rebuild_and_push_docker_images
runs-on: ubuntu-22.04
steps:
- name: Trigger repository release workflow
- name: Release panther-docker repository
uses: convictional/[email protected]
with:
owner: husarion
repo: panther-docker
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: release-repository.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"release_candidate": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -122,22 +100,14 @@ jobs:
"prerelease": "${{ github.event.inputs.prerelease }}"
}

release_panther_rpi_os_image:
name: Release panther-rpi-os-img repository
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }}
needs:
- release_panther_docker
runs-on: ubuntu-22.04
steps:
- name: Trigger repository release workflow
- name: Release panther-rpi-os-img repository
uses: convictional/[email protected]
with:
owner: husarion
repo: panther-rpi-os-img
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: release-repository.yaml
ref: ${{ env.RC_BRANCH_NAME }}
wait_interval: 10
client_payload: |
{
"release_candidate": "${{ env.RC_BRANCH_NAME }}",
Expand All @@ -147,46 +117,41 @@ jobs:
"prerelease": "${{ github.event.inputs.prerelease }}"
}

build_and_publish_rpi_image:
name: Build panther system image
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }}
needs:
- release_panther_rpi_os_image
runs-on: ubuntu-22.04
steps:
- name: Trigger repository build workflow
- name: Build panther system image
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }}
uses: convictional/[email protected]
with:
owner: husarion
repo: panther-rpi-os-img
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: build_and_deploy_image.yaml
ref: ${{ env.MAIN_BRANCH }}
wait_interval: 10
client_payload: |
{
"dev_image": "false",
"panther_codebase_version": "${{ github.event.inputs.version }}",
"image_tag": "${{ github.event.inputs.version }}"
}

build_and_publish_rpi_flash_os_image:
name: Build panther flash OS image
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }}
needs:
- build_and_publish_rpi_image
runs-on: ubuntu-22.04
steps:
- name: Trigger repository build workflow
- name: Build panther flash OS image
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }}
uses: convictional/[email protected]
with:
owner: husarion
repo: panther-rpi-os-img
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: build_and_deploy_flash_os_image.yaml
ref: ${{ env.MAIN_BRANCH }}
wait_interval: 10
client_payload: |
{
"image_tag": "${{ github.event.inputs.version }}"
}

- name: Trigger repository build workflow
uses: convictional/[email protected]
with:
owner: husarion
repo: docs_new
github_token: ${{ secrets.GH_PAT }}
workflow_file_name: build.yml
ref: master
12 changes: 6 additions & 6 deletions .github/workflows/run-unit-tests.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: Run panther unit tests
name: Run unit tests

on:
workflow_dispatch:
Expand Down Expand Up @@ -28,12 +28,12 @@ jobs:
uses: actions/checkout@v3
with:
ref: ${{ github.ref }}
path: ros2_ws/src/panther_ros
path: ros2_ws/src/husarion_ugv

- name: Resolve dependencies
working-directory: ros2_ws
run: |
vcs import < src/panther_ros/panther/panther_hardware.repos src
vcs import < src/husarion_ugv/husarion_ugv/hardware_deps.repos src
sudo apt update
rosdep update --rosdistro $ROS_DISTRO
rosdep install -i --from-path src --rosdistro $ROS_DISTRO -y
Expand All @@ -43,15 +43,15 @@ jobs:
run: |
source /opt/ros/$ROS_DISTRO/setup.bash
if [ -f install/setup.bash ]; then source install/setup.bash; fi
colcon build --symlink-install --parallel-workers $(nproc) --packages-up-to panther --cmake-args -DCMAKE_CXX_FLAGS='-fprofile-arcs -ftest-coverage'
colcon build --symlink-install --parallel-workers $(nproc) --packages-up-to husarion_ugv --cmake-args -DCMAKE_CXX_FLAGS='-fprofile-arcs -ftest-coverage'

- name: Test
working-directory: ros2_ws
run: |
source install/setup.bash
colcon test --packages-up-to panther --retest-until-pass 10 --event-handlers console_cohesion+ --return-code-on-test-failure
colcon test --packages-up-to husarion_ugv --retest-until-pass 10 --event-handlers console_cohesion+ --return-code-on-test-failure
echo "result=$?" >> ${{ runner.temp }}/${{ env.TEST_RESULT_FILENAME }}
colcon lcov-result --packages-up-to panther --verbose >> ${{ runner.temp }}/${{ env.COVERAGE_RESULT_FILENAME }}
colcon lcov-result --packages-up-to husarion_ugv --verbose >> ${{ runner.temp }}/${{ env.COVERAGE_RESULT_FILENAME }}
lines_cov=$(cat ${{ runner.temp }}/${{ env.COVERAGE_RESULT_FILENAME }} | grep -E 'lines' | head -1)
functions_cov=$(cat ${{ runner.temp }}/${{ env.COVERAGE_RESULT_FILENAME }} | grep -E 'functions' | head -1)
branches_cov=$(cat ${{ runner.temp }}/${{ env.COVERAGE_RESULT_FILENAME }} | grep -E 'branches' | head -1)
Expand Down
6 changes: 2 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
devel/
logs/
build/
log/
install/
bin/
lib/
msg_gen/
Expand All @@ -13,8 +13,6 @@ msg/*Feedback.msg
msg/*Goal.msg
msg/*Result.msg
msg/_*.py
build_isolated/
devel_isolated/

# Generated by dynamic reconfigure
*.cfgc
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ repos:
entry: codespell
args:
[
"--exclude-file=panther_hardware_interfaces/config/roboteq_motor_controllers_v80_21a.eds",
"--exclude-file=husarion_ugv_hardware_interfaces/config/roboteq_motor_controllers_v80_21a.eds",
"--ignore-words-list",
"ned" # north, east, down (NED)
]
Expand Down
Loading
Loading