Closed sam-golioth closed 7 months ago
Hi @sam-golioth, sorry for taking so long to reply.
There are 2 issues in there:
1) Current error exists due to missing bootloader files, which are built as external project in Zephyr. To solve this, one option would be removing the --prep-artifacts-for-testing
, which would add into the .tar file all the necessary files:
./scripts/twister --platform esp32_devkitc_wrover -T samples/hello_world --package-artifacts artifacts.tar
2) Twister is not able to run device tests in ESP32 due to serial port conflict. (flashing and reading log output). We have submitted a draft PR as a suggestion to fix it: #66534
Let me know if this works for you somehow.
Sylvio
This issue has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this issue will automatically be closed in 14 days. Note, that you can always re-open a closed issue at any time.
Describe the bug Twister has the ability to build tests on one machine and run them on another (useful in CI when building on a cloud-hosted machine and running on a local machine with hardware attached). This is accomplished by using
--prep-artifacts-for-testing --package-artifacts
when building the tests to produce a tar archive, moving the tar file to the test machine and extracting it, and then running twister with--test-only
. This works great for most platforms, but it fails when running on Espressif based platforms (e.g.esp32_devkitc_wrover
). There appear to be 2 related issues:runners.yaml
file generated during the build includes hardcoded absolute paths for the esp32 runner. When extracting the archive file on another machine or even in another folder, these paths are incorrect.--package-artifacts
argument in Twister doesn't package up the additional files that are required to flash Espressif targets, including the bootloader and partition table. So even if the path issue above was fixed, the actual files would be missing.This was tested on Zephyr v3.5.0
To Reproduce Steps to reproduce the behavior:
zephyr/scripts/twister --platform esp32_devkitc_wrover -T zephyr/samples/hello_world --prep-artifacts-for-testing --package-artifacts artifacts.tar
mkdir twister-test && mv artifacts.tar twister-test && cd twister-test && tar -xvf artifacts.tar
../zephyr/scripts/twister --test-only --platform esp32_devkitc_wrover -T ../zephyr/samples/hello_world --device-testing --device-serial <serial_port> --west-flash
This produce the following in
device.log
:Expected behavior Twister should be able run tests that were built on another machine on Espressif platforms.
Impact Our company develops an SDK on top of Zephyr and tests it against a variety of platforms. Because of this bug, we aren't testing against Espressif targets in CI, reducing our coverage.