diff mbox series

[meta-oe] canopenterm: update to release version 2.02

Message ID 20260415110857.28317-1-mail@michael-fitzmayer.de
State Under Review
Headers show
Series [meta-oe] canopenterm: update to release version 2.02 | expand

Commit Message

Michael Fitzmayer April 15, 2026, 11:08 a.m. UTC
- Introduced a new API function: print_result()
- Added support for configuring a dynamic number of filters when executing replay.lua
- Added script to interact with the STM32 CAN bootloader (stm32.lua)
- Add Unified Diagnostic Services (ISO 14229-1) script written in Lua (uds.lua)
- Various updates and fixes required by the Debian package and to be able to get certified by Microsoft
- Added manpages

Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
---
 ...-C-include-path-for-pocketpy-headers.patch | 135 ++++++++++++++++++
 ...e-search-paths-in-Findpocketpy.cmake.patch |  57 ++++++++
 ...anopenterm_2.01.bb => canopenterm_2.02.bb} |   9 +-
 3 files changed, 198 insertions(+), 3 deletions(-)
 create mode 100644 meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
 create mode 100644 meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
 rename meta-oe/recipes-extended/canopenterm/{canopenterm_2.01.bb => canopenterm_2.02.bb} (76%)

Comments

Khem Raj April 15, 2026, 10:07 p.m. UTC | #1
Seeing a patch fuzz. Did you do a build test ?

https://autobuilder.yoctoproject.org/valkyrie/#/builders/81/builds/1470/steps/15/logs/errors

On Wed, Apr 15, 2026 at 4:09 AM Michael Fitzmayer via lists.openembedded.org
<mail=michael-fitzmayer.de@lists.openembedded.org> wrote:

> - Introduced a new API function: print_result()
> - Added support for configuring a dynamic number of filters when executing
> replay.lua
> - Added script to interact with the STM32 CAN bootloader (stm32.lua)
> - Add Unified Diagnostic Services (ISO 14229-1) script written in Lua
> (uds.lua)
> - Various updates and fixes required by the Debian package and to be able
> to get certified by Microsoft
> - Added manpages
>
> Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
> ---
>  ...-C-include-path-for-pocketpy-headers.patch | 135 ++++++++++++++++++
>  ...e-search-paths-in-Findpocketpy.cmake.patch |  57 ++++++++
>  ...anopenterm_2.01.bb => canopenterm_2.02.bb} |   9 +-
>  3 files changed, 198 insertions(+), 3 deletions(-)
>  create mode 100644
> meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
>  create mode 100644
> meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
>  rename meta-oe/recipes-extended/canopenterm/{canopenterm_2.01.bb =>
> canopenterm_2.02.bb} (76%)
>
> diff --git
> a/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
> b/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
> new file mode 100644
> index 0000000000..b76ba44166
> --- /dev/null
> +++
> b/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
> @@ -0,0 +1,135 @@
> +From 9a7a39e6cb1e5683d6354c33e74894b58829cc12 Mon Sep 17 00:00:00 2001
> +From: Michael Fitzmayer <mail@michael-fitzmayer.de>
> +Date: Wed, 15 Apr 2026 11:57:58 +0200
> +Subject: [PATCH] Fix C include path for pocketpy headers
> +Upstream-Status: Submitted [
> https://github.com/CANopenTerm/CANopenTerm/commit/cbe8d8e6d5787636a32862b20f7c7cf342bb764b
> ]
> +
> +Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
> +---
> + src/api/python_can.c         | 2 +-
> + src/api/python_dbc.c         | 2 +-
> + src/api/python_misc.c        | 2 +-
> + src/api/python_nmt.c         | 2 +-
> + src/api/python_pdo.c         | 2 +-
> + src/api/python_sdo.c         | 2 +-
> + src/api/python_test_report.c | 2 +-
> + src/api/python_widget.c      | 2 +-
> + src/core/scripts.c           | 2 +-
> + 9 files changed, 9 insertions(+), 9 deletions(-)
> +
> +diff --git a/src/api/python_can.c b/src/api/python_can.c
> +index d1c5c6a..c6ee023 100644
> +--- a/src/api/python_can.c
> ++++ b/src/api/python_can.c
> +@@ -11,7 +11,7 @@
> + #include "core.h"
> + #include "dict.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +
> +diff --git a/src/api/python_dbc.c b/src/api/python_dbc.c
> +index f688796..3f3e3d3 100644
> +--- a/src/api/python_dbc.c
> ++++ b/src/api/python_dbc.c
> +@@ -10,7 +10,7 @@
> + #include "core.h"
> + #include "dbc.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +
> +diff --git a/src/api/python_misc.c b/src/api/python_misc.c
> +index a71c39d..da14c01 100644
> +--- a/src/api/python_misc.c
> ++++ b/src/api/python_misc.c
> +@@ -10,7 +10,7 @@
> + #include "python_misc.h"
> + #include "core.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> + #include "scripts.h"
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +diff --git a/src/api/python_nmt.c b/src/api/python_nmt.c
> +index 293d2e1..8e467fe 100644
> +--- a/src/api/python_nmt.c
> ++++ b/src/api/python_nmt.c
> +@@ -11,7 +11,7 @@
> + #include "core.h"
> + #include "nmt.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +
> +diff --git a/src/api/python_pdo.c b/src/api/python_pdo.c
> +index fe34bc9..a307b0d 100644
> +--- a/src/api/python_pdo.c
> ++++ b/src/api/python_pdo.c
> +@@ -10,7 +10,7 @@
> + #include "core.h"
> + #include "os.h"
> + #include "pdo.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +
> +diff --git a/src/api/python_sdo.c b/src/api/python_sdo.c
> +index 3378fc2..2d7b583 100644
> +--- a/src/api/python_sdo.c
> ++++ b/src/api/python_sdo.c
> +@@ -10,7 +10,7 @@
> + #include "core.h"
> + #include "dict.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> + #include "sdo.h"
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +diff --git a/src/api/python_test_report.c b/src/api/python_test_report.c
> +index 59cc7b1..3ca7536 100644
> +--- a/src/api/python_test_report.c
> ++++ b/src/api/python_test_report.c
> +@@ -10,7 +10,7 @@
> + #include "core.h"
> + #include "eds.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> + #include "test_report.h"
> +
> + typedef bool (*py_CFunction)(int argc, py_Ref argv);
> +diff --git a/src/api/python_widget.c b/src/api/python_widget.c
> +index 92891c0..c176ca8 100644
> +--- a/src/api/python_widget.c
> ++++ b/src/api/python_widget.c
> +@@ -13,7 +13,7 @@
> + #include "core.h"
> + #include "led.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> + #include "tachometer.h"
> + #include "window.h"
> +
> +diff --git a/src/core/scripts.c b/src/core/scripts.c
> +index 4dbdac3..1f37b7c 100644
> +--- a/src/core/scripts.c
> ++++ b/src/core/scripts.c
> +@@ -14,7 +14,7 @@
> + #include "lua.h"
> + #include "lualib.h"
> + #include "os.h"
> +-#include "pocketpy.h"
> ++#include <pocketpy.h>
> + #include "table.h"
> +
> + extern const uint8 max_script_search_paths;
> diff --git
> a/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
> b/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
> new file mode 100644
> index 0000000000..9d26a10e34
> --- /dev/null
> +++
> b/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
> @@ -0,0 +1,57 @@
> +From ba48c303e12d6b546fd852527b4b954e28f889f7 Mon Sep 17 00:00:00 2001
> +From: Michael Fitzmayer <mail@michael-fitzmayer.de>
> +Date: Wed, 15 Apr 2026 12:31:17 +0200
> +Subject: [PATCH] Update search paths in Findpocketpy.cmake
> +Upstream-Status: Submitted [
> https://github.com/CANopenTerm/CANopenTerm/commit/7a9466029a6e88345e65e794ff1779f778c9358a
> ]
> +
> +
> +Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
> +---
> + cmake/Findpocketpy.cmake | 30 ++++++++++++++++++++++++------
> + 1 file changed, 24 insertions(+), 6 deletions(-)
> +
> +diff --git a/cmake/Findpocketpy.cmake b/cmake/Findpocketpy.cmake
> +index 459160f..8083270 100644
> +--- a/cmake/Findpocketpy.cmake
> ++++ b/cmake/Findpocketpy.cmake
> +@@ -3,18 +3,36 @@ cmake_minimum_required(VERSION 3.16)
> + # Findpocketpy.cmake
> + # Locate pocketpy library and include directories
> +
> +-find_path(pocketpy_INCLUDE_DIR NAMES pocketpy/pocketpy.h PATHS
> /usr/include)
> +-find_library(pocketpy_LIBRARY NAMES libpocketpy.so PATHS /usr/lib)
> ++find_path(pocketpy_INCLUDE_DIR
> ++  NAMES pocketpy.h
> ++  PATH_SUFFIXES pocketpy
> ++  PATHS
> ++    /usr/include
> ++    /usr/local/include
> ++    /opt/local/include
> ++    /opt/homebrew/include
> ++)
> ++
> ++find_library(pocketpy_LIBRARY
> ++  NAMES pocketpy
> ++  PATHS
> ++    /usr/lib
> ++    /usr/local/lib
> ++    /opt/local/lib
> ++    /opt/homebrew/lib
> ++)
> +
> + message(STATUS "pocketpy_INCLUDE_DIR: ${pocketpy_INCLUDE_DIR}")
> + message(STATUS "pocketpy_LIBRARY: ${pocketpy_LIBRARY}")
> +
> +-if (pocketpy_INCLUDE_DIR AND pocketpy_LIBRARY)
> +-  set(pocketpy_FOUND TRUE)
> ++include(FindPackageHandleStandardArgs)
> ++find_package_handle_standard_args(pocketpy
> ++  REQUIRED_VARS pocketpy_LIBRARY pocketpy_INCLUDE_DIR
> ++)
> ++
> ++if (pocketpy_FOUND)
> +   set(pocketpy_INCLUDE_DIRS ${pocketpy_INCLUDE_DIR})
> +   set(pocketpy_LIBRARIES ${pocketpy_LIBRARY})
> +-else()
> +-  set(pocketpy_FOUND FALSE)
> + endif()
> +
> + mark_as_advanced(pocketpy_INCLUDE_DIR pocketpy_LIBRARY)
> diff --git a/meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb
> b/meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
> similarity index 76%
> rename from meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb
> rename to meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
> index f44312a6e4..a83d3bee69 100644
> --- a/meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb
> +++ b/meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
> @@ -15,13 +15,16 @@ LIC_FILES_CHKSUM =
> "file://LICENSE.md;md5=bd2edc721b4a0289efe949bdbe7dda79"
>
>  DEPENDS = "canvenient cjson isocline libinih libsdl3 lua pocketpy"
>
> -SRC_URI = "git://
> github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v${PV}
> <http://github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v$%7BPV%7D>
> "
> -SRCREV  = "4196097f71c7e59b27e9d8ac3c6cf58f44fa9f19"
> +SRC_URI = "git://
> github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v${PV}
> <http://github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v$%7BPV%7D>
> \
> +           file://0001-Fix-C-include-path-for-pocketpy-headers.patch \
> +           file://0002-Update-search-paths-in-Findpocketpy.cmake.patch \
> +           "
> +SRCREV  = "a6a9cd4fdbfaffea01b3eeeaf3c4830d4ee4b313"
>
>
>  inherit cmake ptest
>
> -EXTRA_OECMAKE += "-DBUILD_YOCTO=ON"
> +EXTRA_OECMAKE += "-DUSE_SYSTEM_LIBS=ON"
>
>  FILES:${PN} += "${bindir}/CANopenTerm ${bindir}/codb2json ${datadir}"
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#126354):
> https://lists.openembedded.org/g/openembedded-devel/message/126354
> Mute This Topic: https://lists.openembedded.org/mt/118838261/1997914
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [
> raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
Michael Fitzmayer April 16, 2026, 1:14 a.m. UTC | #2
> On 16. Apr 2026, at 00:08, Khem Raj <raj.khem@gmail.com> wrote:
> 
> Seeing a patch fuzz. Did you do a build test ?
> 

I manually edited the upstream status after patchtest reported a problem, but yes.

I built it and ran qemu afterwards to see if everything works as expected.

What can I do to resolve this problem?
Khem Raj April 16, 2026, 1:41 a.m. UTC | #3
On Wed, Apr 15, 2026 at 6:14 PM Michael Fitzmayer via lists.openembedded.org
<mail=michael-fitzmayer.de@lists.openembedded.org> wrote:

>
>
> > On 16. Apr 2026, at 00:08, Khem Raj <raj.khem@gmail.com> wrote:
> > 
> > Seeing a patch fuzz. Did you do a build test ?
> >
>
> I manually edited the upstream status after patchtest reported a problem,
> but yes.
>
> I built it and ran qemu afterwards to see if everything works as expected.
>
> What can I do to resolve this problem?
>

bitbake recipe -ccleanall
bitbake recipe

>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#126374):
> https://lists.openembedded.org/g/openembedded-devel/message/126374
> Mute This Topic: https://lists.openembedded.org/mt/118838261/1997914
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [
> raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
Gyorgy Sarvari April 16, 2026, 7:18 a.m. UTC | #4
On 4/16/26 08:35, Michael Fitzmayer via lists.openembedded.org wrote:
> 
>> On 16. Apr 2026, at 03:43, Khem Raj <raj.khem@gmail.com> wrote:
>>
>> On Wed, Apr 15, 2026 at 6:14 PM Michael Fitzmayer via
>> lists.openembedded.org <http://lists.openembedded.org> <mail=michael-
>> fitzmayer.de@lists.openembedded.org <mailto:michael-
>> fitzmayer.de@lists.openembedded.org>> wrote:
>>
>>
>>     What can I do to resolve this problem?
>>
>>
>> bitbake recipe -ccleanall
>> bitbake recipe 
>>
>>
> 
> Thanks, I was able to reproduce the issue. I'm not sure what went wrong,
> and I'll try to be a little more careful in the future.
> 
> Sent a new/updated patch.
> 

As I can see these patches basically move the recipe to the tip of the
main branch. In the future, if there would be such cases, where there
are extra commits after a tag that need to be included in the recipe,
you can just set the SRCREV to the correct revision, if there are no
commits that need to be skipped. You can just add `PV .= "+git"` to the
recipe to indicate that there are some extra goodies included also after
the tag (and maybe add a quick note in the commit message about it).
That avoids messing with patches and makes the intent also clearer.

I wouldn't send a new version because of this, but it might be useful
for the next time.
Michael Fitzmayer April 17, 2026, 4:37 p.m. UTC | #5
-----Original Message-----
From: Gyorgy Sarvari <skandigraun@gmail.com> 
Sent: 16 April 2026 09:19
To: mail@michael-fitzmayer.de; openembedded-devel@lists.openembedded.org
Subject: Re: [oe] [meta-oe][PATCH] canopenterm: update to release version 2.02

< As I can see these patches basically move the recipe to the tip of the main branch. In the future, if there would be such cases, where there are extra commits after a tag that need to be included in the recipe, you can just set the SRCREV to the correct revision, if there are no commits that need to be skipped. You can just add `PV .= "+git"` to the recipe to indicate that there are some extra goodies included also after the tag (and maybe add a quick note in the commit message about it).
That avoids messing with patches and makes the intent also clearer.

< I wouldn't send a new version because of this, but it might be useful for the next time.

Understood! I will add `PV .= "+git"` in case I have a similar scenario in the future. Is it fine for the time being?

Thanks!
Gyorgy Sarvari April 17, 2026, 4:53 p.m. UTC | #6
On 4/17/26 18:37, Michael Fitzmayer via lists.openembedded.org wrote:
> -----Original Message-----
> From: Gyorgy Sarvari <skandigraun@gmail.com> 
> Sent: 16 April 2026 09:19
> To: mail@michael-fitzmayer.de; openembedded-devel@lists.openembedded.org
> Subject: Re: [oe] [meta-oe][PATCH] canopenterm: update to release version 2.02
> 
> < As I can see these patches basically move the recipe to the tip of the main branch. In the future, if there would be such cases, where there are extra commits after a tag that need to be included in the recipe, you can just set the SRCREV to the correct revision, if there are no commits that need to be skipped. You can just add `PV .= "+git"` to the recipe to indicate that there are some extra goodies included also after the tag (and maybe add a quick note in the commit message about it).
> That avoids messing with patches and makes the intent also clearer.
> 
> < I wouldn't send a new version because of this, but it might be useful for the next time.
> 
> Understood! I will add `PV .= "+git"` in case I have a similar scenario in the future. Is it fine for the time being?
> 

For me it is fine... but Khem disagrees :) [1]
On the master branch he has the last word - I'm afraid you will need to
update the patch.

[1]: https://lists.openembedded.org/g/openembedded-devel/message/126445

> Thanks!
> 
> 
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#126447): https://lists.openembedded.org/g/openembedded-devel/message/126447
> Mute This Topic: https://lists.openembedded.org/mt/118838261/6084445
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [skandigraun@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
diff mbox series

Patch

diff --git a/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch b/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
new file mode 100644
index 0000000000..b76ba44166
--- /dev/null
+++ b/meta-oe/recipes-extended/canopenterm/canopenterm/0001-Fix-C-include-path-for-pocketpy-headers.patch
@@ -0,0 +1,135 @@ 
+From 9a7a39e6cb1e5683d6354c33e74894b58829cc12 Mon Sep 17 00:00:00 2001
+From: Michael Fitzmayer <mail@michael-fitzmayer.de>
+Date: Wed, 15 Apr 2026 11:57:58 +0200
+Subject: [PATCH] Fix C include path for pocketpy headers
+Upstream-Status: Submitted [https://github.com/CANopenTerm/CANopenTerm/commit/cbe8d8e6d5787636a32862b20f7c7cf342bb764b]
+
+Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
+---
+ src/api/python_can.c         | 2 +-
+ src/api/python_dbc.c         | 2 +-
+ src/api/python_misc.c        | 2 +-
+ src/api/python_nmt.c         | 2 +-
+ src/api/python_pdo.c         | 2 +-
+ src/api/python_sdo.c         | 2 +-
+ src/api/python_test_report.c | 2 +-
+ src/api/python_widget.c      | 2 +-
+ src/core/scripts.c           | 2 +-
+ 9 files changed, 9 insertions(+), 9 deletions(-)
+
+diff --git a/src/api/python_can.c b/src/api/python_can.c
+index d1c5c6a..c6ee023 100644
+--- a/src/api/python_can.c
++++ b/src/api/python_can.c
+@@ -11,7 +11,7 @@
+ #include "core.h"
+ #include "dict.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+ 
+diff --git a/src/api/python_dbc.c b/src/api/python_dbc.c
+index f688796..3f3e3d3 100644
+--- a/src/api/python_dbc.c
++++ b/src/api/python_dbc.c
+@@ -10,7 +10,7 @@
+ #include "core.h"
+ #include "dbc.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+ 
+diff --git a/src/api/python_misc.c b/src/api/python_misc.c
+index a71c39d..da14c01 100644
+--- a/src/api/python_misc.c
++++ b/src/api/python_misc.c
+@@ -10,7 +10,7 @@
+ #include "python_misc.h"
+ #include "core.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ #include "scripts.h"
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+diff --git a/src/api/python_nmt.c b/src/api/python_nmt.c
+index 293d2e1..8e467fe 100644
+--- a/src/api/python_nmt.c
++++ b/src/api/python_nmt.c
+@@ -11,7 +11,7 @@
+ #include "core.h"
+ #include "nmt.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+ 
+diff --git a/src/api/python_pdo.c b/src/api/python_pdo.c
+index fe34bc9..a307b0d 100644
+--- a/src/api/python_pdo.c
++++ b/src/api/python_pdo.c
+@@ -10,7 +10,7 @@
+ #include "core.h"
+ #include "os.h"
+ #include "pdo.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+ 
+diff --git a/src/api/python_sdo.c b/src/api/python_sdo.c
+index 3378fc2..2d7b583 100644
+--- a/src/api/python_sdo.c
++++ b/src/api/python_sdo.c
+@@ -10,7 +10,7 @@
+ #include "core.h"
+ #include "dict.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ #include "sdo.h"
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+diff --git a/src/api/python_test_report.c b/src/api/python_test_report.c
+index 59cc7b1..3ca7536 100644
+--- a/src/api/python_test_report.c
++++ b/src/api/python_test_report.c
+@@ -10,7 +10,7 @@
+ #include "core.h"
+ #include "eds.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ #include "test_report.h"
+ 
+ typedef bool (*py_CFunction)(int argc, py_Ref argv);
+diff --git a/src/api/python_widget.c b/src/api/python_widget.c
+index 92891c0..c176ca8 100644
+--- a/src/api/python_widget.c
++++ b/src/api/python_widget.c
+@@ -13,7 +13,7 @@
+ #include "core.h"
+ #include "led.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ #include "tachometer.h"
+ #include "window.h"
+ 
+diff --git a/src/core/scripts.c b/src/core/scripts.c
+index 4dbdac3..1f37b7c 100644
+--- a/src/core/scripts.c
++++ b/src/core/scripts.c
+@@ -14,7 +14,7 @@
+ #include "lua.h"
+ #include "lualib.h"
+ #include "os.h"
+-#include "pocketpy.h"
++#include <pocketpy.h>
+ #include "table.h"
+ 
+ extern const uint8 max_script_search_paths;
diff --git a/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch b/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
new file mode 100644
index 0000000000..9d26a10e34
--- /dev/null
+++ b/meta-oe/recipes-extended/canopenterm/canopenterm/0002-Update-search-paths-in-Findpocketpy.cmake.patch
@@ -0,0 +1,57 @@ 
+From ba48c303e12d6b546fd852527b4b954e28f889f7 Mon Sep 17 00:00:00 2001
+From: Michael Fitzmayer <mail@michael-fitzmayer.de>
+Date: Wed, 15 Apr 2026 12:31:17 +0200
+Subject: [PATCH] Update search paths in Findpocketpy.cmake
+Upstream-Status: Submitted [https://github.com/CANopenTerm/CANopenTerm/commit/7a9466029a6e88345e65e794ff1779f778c9358a]
+
+
+Signed-off-by: Michael Fitzmayer <mail@michael-fitzmayer.de>
+---
+ cmake/Findpocketpy.cmake | 30 ++++++++++++++++++++++++------
+ 1 file changed, 24 insertions(+), 6 deletions(-)
+
+diff --git a/cmake/Findpocketpy.cmake b/cmake/Findpocketpy.cmake
+index 459160f..8083270 100644
+--- a/cmake/Findpocketpy.cmake
++++ b/cmake/Findpocketpy.cmake
+@@ -3,18 +3,36 @@ cmake_minimum_required(VERSION 3.16)
+ # Findpocketpy.cmake
+ # Locate pocketpy library and include directories
+ 
+-find_path(pocketpy_INCLUDE_DIR NAMES pocketpy/pocketpy.h PATHS /usr/include)
+-find_library(pocketpy_LIBRARY NAMES libpocketpy.so PATHS /usr/lib)
++find_path(pocketpy_INCLUDE_DIR
++  NAMES pocketpy.h
++  PATH_SUFFIXES pocketpy
++  PATHS
++    /usr/include
++    /usr/local/include
++    /opt/local/include
++    /opt/homebrew/include
++)
++
++find_library(pocketpy_LIBRARY
++  NAMES pocketpy
++  PATHS
++    /usr/lib
++    /usr/local/lib
++    /opt/local/lib
++    /opt/homebrew/lib
++)
+ 
+ message(STATUS "pocketpy_INCLUDE_DIR: ${pocketpy_INCLUDE_DIR}")
+ message(STATUS "pocketpy_LIBRARY: ${pocketpy_LIBRARY}")
+ 
+-if (pocketpy_INCLUDE_DIR AND pocketpy_LIBRARY)
+-  set(pocketpy_FOUND TRUE)
++include(FindPackageHandleStandardArgs)
++find_package_handle_standard_args(pocketpy
++  REQUIRED_VARS pocketpy_LIBRARY pocketpy_INCLUDE_DIR
++)
++
++if (pocketpy_FOUND)
+   set(pocketpy_INCLUDE_DIRS ${pocketpy_INCLUDE_DIR})
+   set(pocketpy_LIBRARIES ${pocketpy_LIBRARY})
+-else()
+-  set(pocketpy_FOUND FALSE)
+ endif()
+ 
+ mark_as_advanced(pocketpy_INCLUDE_DIR pocketpy_LIBRARY)
diff --git a/meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb b/meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
similarity index 76%
rename from meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb
rename to meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
index f44312a6e4..a83d3bee69 100644
--- a/meta-oe/recipes-extended/canopenterm/canopenterm_2.01.bb
+++ b/meta-oe/recipes-extended/canopenterm/canopenterm_2.02.bb
@@ -15,13 +15,16 @@  LIC_FILES_CHKSUM = "file://LICENSE.md;md5=bd2edc721b4a0289efe949bdbe7dda79"
 
 DEPENDS = "canvenient cjson isocline libinih libsdl3 lua pocketpy"
 
-SRC_URI = "git://github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v${PV}"
-SRCREV  = "4196097f71c7e59b27e9d8ac3c6cf58f44fa9f19"
+SRC_URI = "git://github.com/CANopenTerm/CANopenTerm.git;protocol=https;branch=main;tag=v${PV} \
+           file://0001-Fix-C-include-path-for-pocketpy-headers.patch \
+           file://0002-Update-search-paths-in-Findpocketpy.cmake.patch \
+           "
+SRCREV  = "a6a9cd4fdbfaffea01b3eeeaf3c4830d4ee4b313"
 
 
 inherit cmake ptest
 
-EXTRA_OECMAKE += "-DBUILD_YOCTO=ON"
+EXTRA_OECMAKE += "-DUSE_SYSTEM_LIBS=ON"
 
 FILES:${PN} += "${bindir}/CANopenTerm ${bindir}/codb2json ${datadir}"