Skip to content

ci(idf): Use included IDF examples in CI#11240

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

Merged
merged 5 commits into from
Apr 28, 2025

Conversation

lucasssvaz
Copy link
Collaborator

@lucasssvazlucasssvaz commented Apr 11, 2025

Description of Change

Add compilation test of our existing ESP-IDF examples to CI

Tests scenarios

CI

@github-actionsGitHub Actions
Copy link
Contributor

github-actionsbot commented Apr 11, 2025

Messages
📖🎉 Good Job! All checks are passing!

👋 Hello lucasssvaz, we appreciate your contribution to this project!


📘 Please review the project's Contributions Guide for key guidelines on code, documentation, testing, and more.

🖊️ Please also make sure you have read and signed the Contributor License Agreement for this project.

Click to see more instructions ...


This automated output is generated by the PR linter DangerJS, which checks if your Pull Request meets the project's requirements and helps you fix potential issues.

DangerJS is triggered with each push event to a Pull Request and modify the contents of this comment.

Please consider the following:
- Danger mainly focuses on the PR structure and formatting and can't understand the meaning behind your code or changes.
- Danger is not a substitute for human code reviews; it's still important to request a code review from your colleagues.
- To manually retry these Danger checks, please navigate to the Actions tab and re-run last Danger workflow.

Review and merge process you can expect ...


We do welcome contributions in the form of bug reports, feature requests and pull requests.

1. An internal issue has been created for the PR, we assign it to the relevant engineer.
2. They review the PR and either approve it or ask you for changes or clarifications.
3. Once the GitHub PR is approved we do the final review, collect approvals from core owners and make sure all the automated tests are passing.
- At this point we may do some adjustments to the proposed change, or extend it by adding tests or documentation.
4. If the change is approved and passes the tests it is merged into the default branch.

Generated by 🚫 dangerJS against 128bc3f

@lucasssvazlucasssvazforce-pushed the ci/idf_examples branch 2 times, most recently from e111001 to 53d8c55CompareApril 14, 2025 12:57
@github-actionsGitHub Actions
Copy link
Contributor

github-actionsbot commented Apr 14, 2025

Test Results

 76 files   76 suites   12m 46s ⏱️
 38 tests  38 ✅ 0 💤 0 ❌
241 runs  241 ✅ 0 💤 0 ❌

Results for commit 128bc3f.

♻️ This comment has been updated with latest results.

@lucasssvazlucasssvazforce-pushed the ci/idf_examples branch 3 times, most recently from c994244 to d67a19bCompareApril 14, 2025 15:48
@lucasssvazlucasssvazforce-pushed the ci/idf_examples branch 2 times, most recently from 3e4f23e to d9a0e9cCompareApril 15, 2025 12:37
@lucasssvazlucasssvaz marked this pull request as ready for review April 15, 2025 12:59
@lucasssvazlucasssvaz self-assigned this Apr 15, 2025
@lucasssvazlucasssvaz added Type: CI & Testing Area: Arduino as ESP-IDF component Issues about Arduino used as component in ESP-IDF labels Apr 15, 2025
@SuGlider
Copy link
Collaborator

@lucasssvaz - what is the reason for removing matter_light specific target default sdkconfig? Those are examples.

@SuGlider
Copy link
Collaborator

@lucasssvaz - what is the reason for removing matter_light specific target default sdkconfig? Those are examples.

We already talked about it - question answered.

Copy link
Collaborator

@SuGliderSuGlider left a comment

Choose a reason for hiding this comment

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

LGTM

@Jason2866
Copy link
Collaborator

@SuGlider Is it planned to adopt the example to work with actual Arduino Core 3.2.0?
Currently it is only for Arduino Core ~3.0.5

@SuGlider
Copy link
Collaborator

@SuGlider Is it planned to adopt the example to work with actual Arduino Core 3.2.0? Currently it is only for Arduino Core ~3.0.5

@Jason2866 - Could you please share your findings about this issue? Thanks!

@SuGlider
Copy link
Collaborator

SuGlider commented Apr 24, 2025

@SuGlider Is it planned to adopt the example to work with actual Arduino Core 3.2.0? Currently it is only for Arduino Core ~3.0.5

I guess this is about https://github.com/espressif/arduino-esp32/blob/master/idf_component_examples/esp_matter_light/main/idf_component.yml

dependencies: espressif/esp_matter: version: "^1.3.0" # Adds Arduino Core from GitHub repository using main branch espressif/arduino-esp32: version: "^3.0.5" override_path: "../../../" pre_release: true # testing - using Arduino from the repository # version: "master" # branch or commit # git: https://github.com/espressif/arduino-esp32.git 

That shall be solved with the changes:

dependencies: espressif/esp_matter: version: ">=1.3.0" # Adds Arduino Core from GitHub repository using main branch espressif/arduino-esp32: version: ">=3.0.5" override_path: "../../../" pre_release: true 
@Jason2866
Copy link
Collaborator

@SuGlider Try to compile. Compile errors come up when trying with Core 3.2.0 and IDF 5.4.1+

@SuGlider
Copy link
Collaborator

@SuGlider Try to compile. Compile errors come up when trying with Core 3.2.0 and IDF 5.4.1+

I have done it. I was able to build the Matter application for the ESP32 using Core 3.2.0, IDF5.4.1 and Matter 1.4.0.

I have checkout this PR, installed IDF v5.4 and imported the Arduino as Component Matter Light project from the repository.
I have modified the main/idf_component.yml file to comment out the last 2 lines (override_path: "../../../" and pre_release: true). I have run idf.py set-target esp32 and then idf.py build. All good.

@SuGlider
Copy link
Collaborator

SuGlider commented Apr 25, 2025

@SuGlider Dont get it going with branch master and IDF 5.4.1+ from 25.04.11 https://github.com/pioarduino/platform-espressif32/actions/runs/14667529394/job/41165941836 used example https://github.com/pioarduino/platform-espressif32/tree/refs/heads/test_matter/examples/espidf-arduino-matter-light

This error is related std::to_underlying it needs C++ 23.
I have changed the CMakeLists.txt file in this PR to use C++ 2a.
d8e7a91

Try that change within pioarduino and let me know.

@SuGlider
Copy link
Collaborator

@Jason2866
Copy link
Collaborator

@SuGlider Will do. Needs a pio python script to change the used c++ version.

@Jason2866
Copy link
Collaborator

Jason2866 commented Apr 25, 2025

Just noticed we need to fix the Arduino Lib Builder pioarduino script.
There is this entry

CXXFLAGS=[ "-march=rv32imc_zicsr_zifencei", "-std=gnu++2b", "-fexceptions", "-fno-rtti", "-fuse-cxa-atexit", "-std=gnu++2a" ], 

I guess it fetches the different settings from normal run and the Matter run. Similar issue than adding the ndebug entry.
I can't override correctly when two set here.

@Jason2866
Copy link
Collaborator

This weird setup does work:

build_unflags = -std=c++17 -std=gnu++2b build_flags = -std=gnu++2a 
@SuGlider
Copy link
Collaborator

This weird setup does work:

build_unflags = -std=c++17 -std=gnu++2b build_flags = -std=gnu++2a 

does this setup build it for pioarduino?
I have tried 2b but it fails with Matter 1.4
2a is the best ESP Matter can go.

@Jason2866
Copy link
Collaborator

Jason2866 commented Apr 26, 2025

Yes, this setup does build successfully. It uses Matter v1.4. and ++2a

https://github.com/pioarduino/platform-espressif32/actions/runs/14669953811/job/41173950292

Thx for your help!

@lucasssvazlucasssvaz added the Status: Pending Merge Pull Request is ready to be merged label Apr 27, 2025
@me-no-devme-no-dev merged commit 5262f5a into espressif:masterApr 28, 2025
72 checks passed
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Arduino as ESP-IDF componentIssues about Arduino used as component in ESP-IDFStatus: Pending MergePull Request is ready to be mergedType: CI & Testing
5 participants
@lucasssvaz@SuGlider@Jason2866@P-R-O-C-H-Y@me-no-dev
close