Skip to content

Conversation

@aescolar
Copy link
Member

@aescolar aescolar commented Nov 15, 2019

Fetch HW models from a new west module.
And, remove all pre-west glue which was used to:

  • fetch them in CI
  • validate their vesion
  • Modify the include path and link to them

Signed-off-by: Alberto Escolar Piedras [email protected]

New west module provisional placement:
https://github.com/aescolar/nrf52_HW_models

@aescolar aescolar added Enhancement Changes/Updates/Additions to existing features platform: nRFx BSIM nrf5x_bsim labels Nov 15, 2019
@aescolar aescolar force-pushed the hwmodels_west_module branch 2 times, most recently from 124b6d0 to eca15ff Compare November 15, 2019 14:06
@aescolar aescolar changed the title nrf52_bsim: User HW models from new west module nrf52_bsim: Use HW models from new west module Nov 15, 2019
@aescolar aescolar force-pushed the hwmodels_west_module branch from eca15ff to 57112f6 Compare November 15, 2019 14:17
@aescolar aescolar force-pushed the hwmodels_west_module branch from 57112f6 to 7860c29 Compare November 15, 2019 14:20
@aescolar aescolar force-pushed the hwmodels_west_module branch from 7860c29 to b1a0fa1 Compare November 18, 2019 10:10
@aescolar aescolar marked this pull request as ready for review November 18, 2019 10:13
Copy link
Contributor

@mbolivar mbolivar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems fine, but I think that one cmake nit makes sense to clean up here.

@nashif
Copy link
Member

nashif commented Nov 18, 2019

if this fixes #20366, we should add a reference to the body.

With this change, do we still need the code in the docker image?

@aescolar
Copy link
Member Author

With this change, do we still need the code in the docker image?

Yes, the code in the docker image (the simulator base components) are akin to cmake, and cannot be built by Zephyr's build system.

@nashif
Copy link
Member

nashif commented Nov 18, 2019

Yes, the code in the docker image (the simulator base components) are akin to cmake, and cannot be built by Zephyr's build system.

ok, do we have documentation or instructions somewhere for how someone can get babblesim installed on their system to be able to run sanitycheck the same way it is run in CI?

@aescolar
Copy link
Member Author

aescolar commented Nov 18, 2019

ok, do we have documentation or instructions somewhere for how someone can get babblesim installed on their system to be able to run sanitycheck the same way it is run in CI?

Here:
https://docs.zephyrproject.org/latest/boards/posix/nrf52_bsim/doc/index.html#building-and-running
Though the exact sub-set of repos fetched when building the CI docker image is this manifest: https://github.com/BabbleSim/manifest/blob/master/zephyr_docker.xml

@nashif
Copy link
Member

nashif commented Nov 18, 2019

Here:
docs.zephyrproject.org/latest/boards/posix/nrf52_bsim/doc/index.html#building-and-running

This documentation would make more sense under doc/guides/test/ with reference to the board, can we move this and change it to explain how it would work with sanitycheck?

@aescolar
Copy link
Member Author

This documentation would make more sense

We could. If the plan is just to document how it is today and leave it at that. I was thinking of maybe including the simulator in the SDK, in which case it could be transparent for users.

@aescolar aescolar force-pushed the hwmodels_west_module branch from b1a0fa1 to e4d63d9 Compare November 19, 2019 08:49
@aescolar
Copy link
Member Author

aescolar commented Nov 19, 2019

Just cleaned up a bit more the run_ci.sh script as we do not need to re-trigger a (incremental) build of the simulator each time, because we do not fetch any component update for it.

diff --git a/scripts/ci/run_ci.sh b/scripts/ci/run_ci.sh
index 3f4080d107..8a3a85af17 100755
--- a/scripts/ci/run_ci.sh
+++ b/scripts/ci/run_ci.sh
@@ -115,14 +115,6 @@ function on_complete() {
        fi;
 }
 
-
-function build_btsim() {
-       pushd . ;
-       cd ${BSIM_OUT_PATH}
-       make everything -j 8 -s
-       popd ;
-}
-
 function run_bsim_bt_tests() {
        WORK_DIR=${ZEPHYR_BASE}/bsim_bt_out tests/bluetooth/bsim_bt/compile.sh
        RESULTS_FILE=${ZEPHYR_BASE}/${BSIM_BT_TEST_RESULTS_FILE} \
@@ -235,10 +227,7 @@ if [ -n "$MAIN_CI" ]; then
        $short_git_log
 
        if [ -n "${BSIM_OUT_PATH}" -a -d "${BSIM_OUT_PATH}" ]; then
-               echo "Build BT simulator tests"
-               # Build BT Simulator
-               build_btsim
-
+               echo "Build and run BT simulator tests"
                # Run BLE tests in simulator on the 1st CI instance:
                if [ "$MATRIX" = "1" ]; then
                        run_bsim_bt_tests

(and as a bonus we save ~50ms)

@wopu-ot wopu-ot removed their request for review November 20, 2019 07:14
@aescolar aescolar added this to the v2.2.0 milestone Nov 20, 2019
Fetch HW models from a new west module.
And, remove all pre-west glue which was used to:
 * Fetch them in CI
 * Validate their vesion
 * Modify the include path and link to them

Signed-off-by: Alberto Escolar Piedras <[email protected]>
@aescolar
Copy link
Member Author

aescolar commented Dec 11, 2019

Rebased due to run_ci.sh conflict (variables case change). No changes otherwise.

@carlescufi carlescufi merged commit dfed64c into zephyrproject-rtos:master Dec 11, 2019
@aescolar aescolar deleted the hwmodels_west_module branch December 11, 2019 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: Boards area: Modules Enhancement Changes/Updates/Additions to existing features platform: nRFx BSIM nrf5x_bsim

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants