Skip to content

Commit 8f32ff9

Browse files
Add multithread to CI (backport #238) (#239)
* Add multithread to CI (#238) * Add multithread to CI Signed-off-by: Pablo Garrido <[email protected]> * Fix multithread example * Override esp_macros fro micro-ROS build --------- Signed-off-by: Pablo Garrido <[email protected]> (cherry picked from commit 8d6b8d4) * Fix --------- Co-authored-by: Pablo Garrido <[email protected]>
1 parent 80436ea commit 8f32ff9

File tree

6 files changed

+38
-0
lines changed

6 files changed

+38
-0
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,17 @@ jobs:
8080
idf.py set-target ${{ matrix.idf_target }}
8181
idf.py build
8282
83+
- name: Build sample - multithread_publisher
84+
shell: bash
85+
run: |
86+
. $IDF_PATH/export.sh
87+
cd micro_ros_espidf_component
88+
make -f libmicroros.mk clean
89+
sed -i 's/DRMW_UXRCE_TRANSPORT=udp/DRMW_UXRCE_TRANSPORT=custom/' colcon.meta
90+
cd examples/multithread_publisher
91+
idf.py set-target ${{ matrix.idf_target }}
92+
idf.py build
93+
8394
- name: EmbeddedRTPS
8495
shell: bash
8596
run: |

.github/workflows/nightly.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,14 @@ jobs:
6565
idf.py set-target ${{ matrix.idf_target }}
6666
idf.py build
6767
68+
- name: Build sample - handle_static_types
69+
shell: bash
70+
run: |
71+
. $IDF_PATH/export.sh
72+
cd micro_ros_espidf_component/examples/handle_static_types
73+
idf.py set-target ${{ matrix.idf_target }}
74+
idf.py build
75+
6876
- name: Build sample - int32_publisher_custom_transport
6977
shell: bash
7078
run: |
@@ -76,6 +84,17 @@ jobs:
7684
idf.py set-target ${{ matrix.idf_target }}
7785
idf.py build
7886
87+
- name: Build sample - multithread_publisher
88+
shell: bash
89+
run: |
90+
. $IDF_PATH/export.sh
91+
cd micro_ros_espidf_component
92+
make -f libmicroros.mk clean
93+
sed -i 's/DRMW_UXRCE_TRANSPORT=udp/DRMW_UXRCE_TRANSPORT=custom/' colcon.meta
94+
cd examples/multithread_publisher
95+
idf.py set-target ${{ matrix.idf_target }}
96+
idf.py build
97+
7998
- name: EmbeddedRTPS
8099
if: ${{ matrix.branch == 'humble' }}
81100
shell: bash

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ foreach(package ${PACKAGES})
4343
string(REPLACE ";" "" ${package}_includes_string "${${package}_includes}")
4444
endforeach()
4545

46+
# Workaround for https://github.com/ros2/rosidl/pull/739
47+
string(APPEND IDF_INCLUDES "-I${COMPONENT_DIR}/include_override")
48+
4649
# Create a string with all packages with a for loop
4750
foreach(package ${PACKAGES})
4851
string(APPEND IDF_INCLUDES "${${package}_includes_string}")

include_override/FreeRTOS.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
// Include proper path to FreeRTOS header file
2+
#include "freertos/FreeRTOS.h"

include_override/esp_macros.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
// This is very overkill, but it's a workaround for the fact that the ESP_STATIC_ASSERT fails when building micro-ROS in IDF >v5.0.0

include_override/semphr.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
// Include proper path to FreeRTOS header file
2+
#include "freertos/semphr.h"

0 commit comments

Comments
 (0)