File tree Expand file tree Collapse file tree 4 files changed +79
-0
lines changed Expand file tree Collapse file tree 4 files changed +79
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : RotorS PX4 Build Test
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - ' master'
7
+ pull_request :
8
+ branches :
9
+ - ' *'
10
+
11
+ jobs :
12
+ build :
13
+ runs-on : ubuntu-latest
14
+ strategy :
15
+ fail-fast : false
16
+ matrix :
17
+ container :
18
+ - ' px4io/px4-dev-simulation-bionic:2020-11-18' # Gazebo 9
19
+ container :
20
+ image : ${{ matrix.container }}
21
+ options : --privileged --ulimit core=-1 --security-opt seccomp=unconfined
22
+ steps :
23
+ - uses : actions/checkout@v1
24
+ with :
25
+ token : ${{ secrets.ACCESS_TOKEN }}
26
+ - name : Prepare ccache timestamp
27
+ id : ccache_cache_timestamp
28
+ shell : cmake -P {0}
29
+ run : |
30
+ string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
31
+ message("::set-output name=timestamp::${current_date}")
32
+ - name : ccache cache files
33
+ uses : actions/cache@v2
34
+ with :
35
+ path : ~/.ccache
36
+ key : rotors_tests-RelWithDebInfo-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
37
+ restore-keys : rotors_tests-RelWithDebInfo-ccache-
38
+ - name : setup ccache
39
+ run : |
40
+ mkdir -p ~/.ccache
41
+ echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
42
+ echo "compression = true" >> ~/.ccache/ccache.conf
43
+ echo "compression_level = 5" >> ~/.ccache/ccache.conf
44
+ echo "max_size = 100M" >> ~/.ccache/ccache.conf
45
+ ccache -s
46
+ ccache -z
47
+ - name : Install glog
48
+ run : apt update && apt install -y libgoogle-glog-dev libyaml-cpp-dev
49
+ - name : Build PX4 RotorS
50
+ env :
51
+ PX4_CMAKE_BUILD_TYPE : RelWithDebInfo
52
+ DONT_RUN : 1
53
+ run : make px4_sitl rotors
54
+ - name : ccache post-run px4/firmware
55
+ run : ccache -s
Original file line number Diff line number Diff line change 63
63
[submodule "src/drivers/uavcannode_gps_demo/libcanard "]
64
64
path = src/drivers/uavcannode_gps_demo/libcanard
65
65
url = https://github.com/UAVCAN/libcanard
66
+ [submodule "Tools/rotors_simulator "]
67
+ path = Tools/rotors_simulator
68
+ url = https://github.com/ethz-asl/rotors_simulator.git
Original file line number Diff line number Diff line change @@ -85,11 +85,29 @@ ExternalProject_Add(jsbsim_bridge
85
85
BUILD_ALWAYS 1
86
86
)
87
87
88
+ px4_add_git_submodule(TARGET git_rotors PATH "${PX4_SOURCE_DIR} /Tools/rotors_simulator" )
89
+ ExternalProject_Add(rotors_simulator
90
+ SOURCE_DIR ${PX4_SOURCE_DIR} /Tools/rotors_simulator/rotors_gazebo_plugins
91
+ CMAKE_ARGS
92
+ -DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}
93
+ -DNO_ROS=true
94
+ BINARY_DIR ${PX4_BINARY_DIR} /build_rotors
95
+ INSTALL_COMMAND ""
96
+ DEPENDS
97
+ git_rotors
98
+ USES_TERMINAL_CONFIGURE true
99
+ USES_TERMINAL_BUILD true
100
+ EXCLUDE_FROM_ALL true
101
+ BUILD_ALWAYS 1
102
+ BUILD_COMMAND ${CMAKE_COMMAND} --build <BINARY_DIR> -- -j1
103
+ )
104
+
88
105
# create targets for each viewer/model/debugger combination
89
106
set (viewers
90
107
none
91
108
jmavsim
92
109
gazebo
110
+ rotors
93
111
)
94
112
95
113
set (debuggers
@@ -178,6 +196,8 @@ foreach(viewer ${viewers})
178
196
add_dependencies (${_targ_name} px4 sitl_gazebo)
179
197
elseif (viewer STREQUAL "jmavsim" )
180
198
add_dependencies (${_targ_name} px4 git_jmavsim)
199
+ elseif (viewer STREQUAL "rotors" )
200
+ add_dependencies (${_targ_name} px4 rotors_simulator)
181
201
endif ()
182
202
else ()
183
203
if (viewer STREQUAL "gazebo" )
You can’t perform that action at this time.
0 commit comments