feat(can_open_node): Added canopen protocol for twai driver (IEC-500)#704
feat(can_open_node): Added canopen protocol for twai driver (IEC-500)#704wanckl wants to merge 4 commits intoespressif:masterfrom
Conversation
There was a problem hiding this comment.
Pull request overview
Adds an ESP-IDF component that integrates CANopenNode with the ESP32 TWAI driver and provides initial target/driver scaffolding.
Changes:
- Introduces ESP32 target definitions (
CO_driver_target.h) and a TWAI-backed CANopenNode driver (CO_driver_esp32.c) - Adds component metadata/build configuration (
idf_component.yml,CMakeLists.txt) and initial documentation/license - Adds CANopenNode as a git submodule
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
| esp_canopennode/src/CO_driver_target.h | ESP32/CANopenNode target types, macros, and synchronization placeholders |
| esp_canopennode/src/CO_driver_esp32.c | TWAI receive callback + CANopenNode CAN module init/send APIs |
| esp_canopennode/idf_component.yml | Component registry metadata and ESP-IDF dependency constraint |
| esp_canopennode/README.md | Component overview and placeholder quick start |
| esp_canopennode/LICENSE | Apache-2.0 license file |
| esp_canopennode/CMakeLists.txt | Component build wiring + CANopenNode sources inclusion |
| esp_canopennode/CANopenNode | Adds CANopenNode submodule pointer |
| .gitmodules | Registers CANopenNode submodule |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
57b7b9a to
be95521
Compare
be95521 to
42e4dc7
Compare
There was a problem hiding this comment.
Pull request overview
This PR introduces a new canopennode ESP-IDF extra component which integrates the upstream CANopenNode stack (via submodule) with the ESP TWAI driver, and adds a minimal heartbeat example plus component metadata/CI wiring needed for publishing.
Changes:
- Added an ESP-IDF/TWAI-specific CANopenNode driver target header and ESP32 driver implementation.
- Added a heartbeat example project (generated OD files + app) and basic component scaffolding (LICENSE/README/Kconfig/SBOM/manifest).
- Registered the new component in repo automation/configuration (submodule + upload workflow + issue template component list).
Reviewed changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
canopennode/src/CO_driver_target.h |
Adds ESP-IDF/TWAI target types/macros and locking primitives for CANopenNode. |
canopennode/src/CO_driver_esp32.c |
Implements CAN module init, RX callbacks, TX buffering/sending, and processing hooks on top of TWAI. |
canopennode/sbom_canopennode.yml |
Adds SBOM metadata for the upstream CANopenNode dependency. |
canopennode/idf_component.yml |
Adds component manifest (version/IDF dependency/SBOM). |
canopennode/examples/heartbeat/main/idf_component.yml |
Adds example manifest and dependency on the new component. |
canopennode/examples/heartbeat/main/canopen_heartbeat.h |
Adds (currently minimal) example header scaffold. |
canopennode/examples/heartbeat/main/canopen_heartbeat.c |
Adds heartbeat demo app using TWAI on-chip node + CANopenNode init/process loop. |
canopennode/examples/heartbeat/main/OD.xpd |
Adds CANopenEditor project export for the example OD. |
canopennode/examples/heartbeat/main/OD.h |
Adds generated Object Dictionary header for the example. |
canopennode/examples/heartbeat/main/OD.c |
Adds generated Object Dictionary implementation for the example. |
canopennode/examples/heartbeat/main/CMakeLists.txt |
Adds example “main” component build definition. |
canopennode/examples/heartbeat/README.md |
Adds short description of the heartbeat example. |
canopennode/examples/heartbeat/CMakeLists.txt |
Adds top-level example project build file. |
canopennode/README.md |
Adds top-level component README stub. |
canopennode/LICENSE |
Adds Apache-2.0 license file for the component. |
canopennode/Kconfig |
Adds Kconfig option for OD build mode selection. |
canopennode/CMakeLists.txt |
Adds component build definition linking CANopenNode sources + TWAI dependency. |
.gitmodules |
Adds CANopenNode upstream as a git submodule under canopennode/CANopenNode. |
.github/workflows/upload_component.yml |
Adds canopennode to the upload workflow component list. |
.github/ISSUE_TEMPLATE/bug-report.yml |
Adds canopennode to the bug report component dropdown. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
39236a8 to
21e7368
Compare
|
@Dazza0 FYI, in case you're still interested in it. :😁 |
21e7368 to
d800bf2
Compare
d800bf2 to
76d70fb
Compare
Checklist
urlfield definedChange description
Please describe your change here