From a14a1ba8e4a0cae89f3f3cd604b522e62d3bf6b6 Mon Sep 17 00:00:00 2001 From: Gilberto Conti Date: Wed, 17 Jun 2026 15:02:11 +0200 Subject: [PATCH 001/162] tools: zephyr-sketch-tool: bump go version for binary.Encode Signed-off-by: Gilberto Conti --- tools/zephyr-sketch-tool/go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/zephyr-sketch-tool/go.mod b/tools/zephyr-sketch-tool/go.mod index 1cb9dca3a..797a75ed7 100644 --- a/tools/zephyr-sketch-tool/go.mod +++ b/tools/zephyr-sketch-tool/go.mod @@ -1,3 +1,3 @@ module github.com/arduino/zephyr-sketch-tool -go 1.22.5 +go 1.23 From 5d2d309b4f44ded88561d21cd7c688d64677d50e Mon Sep 17 00:00:00 2001 From: pennam Date: Tue, 30 Jun 2026 10:36:15 +0200 Subject: [PATCH 002/162] json: unoq: update Arduino_RouterBridge to 0.4.3 Arduino_RouterBridge 0.4.3 fixes maximum buffer size for udp and tcp client implementations --- extra/artifacts/zephyr_unoq.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extra/artifacts/zephyr_unoq.json b/extra/artifacts/zephyr_unoq.json index 53a3537c5..cb1af7c25 100644 --- a/extra/artifacts/zephyr_unoq.json +++ b/extra/artifacts/zephyr_unoq.json @@ -3,7 +3,7 @@ "architecture": "zephyr", "category": "Arduino", "libraryDependencies": [ - { "name":"Arduino_RouterBridge", "version":"0.4.2" }, + { "name":"Arduino_RouterBridge", "version":"0.4.3" }, { "name":"Arduino_RPClite", "version":"0.3.0" }, { "name":"MsgPack", "version":"0.4.2" }, { "name":"DebugLog", "version":"0.8.4" }, From a40ccdf638d5ba038dae7e0846a40cf28b657e16 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 15 May 2026 10:04:19 +0000 Subject: [PATCH 003/162] build(deps): bump tools/sync-zephyr-artifacts deps Squash change that includes PRs #482 #483 #484 #485 #486. Signed-off-by: dependabot[bot] Signed-off-by: Luca Burelli --- tools/sync-zephyr-artifacts/go.mod | 29 +++------ tools/sync-zephyr-artifacts/go.sum | 98 +++--------------------------- 2 files changed, 18 insertions(+), 109 deletions(-) diff --git a/tools/sync-zephyr-artifacts/go.mod b/tools/sync-zephyr-artifacts/go.mod index 219f76727..97d68d1c0 100644 --- a/tools/sync-zephyr-artifacts/go.mod +++ b/tools/sync-zephyr-artifacts/go.mod @@ -1,6 +1,6 @@ module github.com/arduino/sync-zephyr-artifacts -go 1.24.1 +go 1.25.0 require ( github.com/codeclysm/extract/v4 v4.0.0 @@ -8,31 +8,18 @@ require ( ) require ( - dario.cat/mergo v1.0.0 // indirect - github.com/Microsoft/go-winio v0.6.2 // indirect - github.com/ProtonMail/go-crypto v1.1.5 // indirect - github.com/cloudflare/circl v1.6.0 // indirect - github.com/cyphar/filepath-securejoin v0.4.1 // indirect - github.com/emirpasic/gods v1.18.1 // indirect - github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect - github.com/go-git/go-billy/v5 v5.6.2 // indirect - github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/h2non/filetype v1.1.3 // indirect - github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5 // indirect github.com/juju/loggo v1.0.0 // indirect - github.com/kevinburke/ssh_config v1.2.0 // indirect github.com/klauspost/compress v1.15.13 // indirect + github.com/kr/pretty v0.3.1 // indirect github.com/otiai10/mint v1.6.3 // indirect - github.com/pjbgf/sha1cd v0.3.2 // indirect - github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect - github.com/skeema/knownhosts v1.3.1 // indirect - github.com/ulikunitz/xz v0.5.12 // indirect - github.com/xanzy/ssh-agent v0.3.3 // indirect - golang.org/x/crypto v0.35.0 // indirect - golang.org/x/net v0.36.0 // indirect + github.com/rogpeppe/go-internal v1.14.1 // indirect + github.com/stretchr/testify v1.11.1 // indirect + github.com/ulikunitz/xz v0.5.14 // indirect golang.org/x/sync v0.8.0 // indirect - golang.org/x/sys v0.30.0 // indirect + golang.org/x/sys v0.43.0 // indirect + gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22 // indirect - gopkg.in/warnings.v0 v0.1.2 // indirect + gopkg.in/yaml.v2 v2.4.0 // indirect ) diff --git a/tools/sync-zephyr-artifacts/go.sum b/tools/sync-zephyr-artifacts/go.sum index a3f530735..54515a9ba 100644 --- a/tools/sync-zephyr-artifacts/go.sum +++ b/tools/sync-zephyr-artifacts/go.sum @@ -1,47 +1,12 @@ -dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= -dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= -github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= -github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= -github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= -github.com/ProtonMail/go-crypto v1.1.5 h1:eoAQfK2dwL+tFSFpr7TbOaPNUbPiJj4fLYwwGE1FQO4= -github.com/ProtonMail/go-crypto v1.1.5/go.mod h1:rA3QumHc/FZ8pAHreoekgiAbzpNsfQAosU5td4SnOrE= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be h1:9AeTilPcZAjCFIImctFaOjnTIavg87rW78vTPkQqLI8= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be/go.mod h1:ySMOLuWl6zY27l47sB3qLNK6tF2fkHG55UZxx8oIVo4= github.com/arduino/go-paths-helper v1.12.1 h1:WkxiVUxBjKWlLMiMuYy8DcmVrkxdP7aKxQOAq7r2lVM= github.com/arduino/go-paths-helper v1.12.1/go.mod h1:jcpW4wr0u69GlXhTYydsdsqAjLaYK5n7oWHfKqOG6LM= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/cloudflare/circl v1.6.0 h1:cr5JKic4HI+LkINy2lg3W2jF8sHCVTBncJr5gIIq7qk= -github.com/cloudflare/circl v1.6.0/go.mod h1:uddAzsPgqdMAYatqJ0lsjX1oECcQLIlRpzZh3pJrofs= github.com/codeclysm/extract/v4 v4.0.0 h1:H87LFsUNaJTu2e/8p/oiuiUsOK/TaPQ5wxsjPnwPEIY= github.com/codeclysm/extract/v4 v4.0.0/go.mod h1:SFju1lj6as7FvUgalpSct7torJE0zttbJUWtryPRG6s= -github.com/cyphar/filepath-securejoin v0.4.1 h1:JyxxyPEaktOD+GAnqIqTf9A8tHyAG22rowi7HkoSU1s= -github.com/cyphar/filepath-securejoin v0.4.1/go.mod h1:Sdj7gXlvMcPZsbhwhQ33GguGLDGQL7h7bg04C/+u9jI= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/elazarl/goproxy v1.7.2 h1:Y2o6urb7Eule09PjlhQRGNsqRfPmYI3KKQLFpCAV3+o= -github.com/elazarl/goproxy v1.7.2/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= -github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= -github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= -github.com/gliderlabs/ssh v0.3.8 h1:a4YXD1V7xMF9g5nTkdfnja3Sxy1PVDCj1Zg4Wb8vY6c= -github.com/gliderlabs/ssh v0.3.8/go.mod h1:xYoytBv1sV0aL3CavoDuJIQNURXkkfPA/wxQ1pL1fAU= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= -github.com/go-git/go-billy/v5 v5.6.2 h1:6Q86EsPXMa7c3YZ3aLAQsMA0VlWmy43r6FHqa/UNbRM= -github.com/go-git/go-billy/v5 v5.6.2/go.mod h1:rcFC2rAsp/erv7CMz9GczHcuD0D32fWzH+MJAU+jaUU= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399 h1:eMje31YglSBqCdIqdhKBW8lokaMrL3uTkpGYlE2OOT4= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399/go.mod h1:1OCfN199q1Jm3HZlxleg+Dw/mwps2Wbk9frAWm+4FII= -github.com/go-git/go-git/v5 v5.14.0 h1:/MD3lCrGjCen5WfEAzKg00MJJffKhC8gzS80ycmCi60= -github.com/go-git/go-git/v5 v5.14.0/go.mod h1:Z5Xhoia5PcWA3NF8vRLURn9E5FRhSl7dGj9ItW3Wk5k= -github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 h1:f+oWsMOmNPc8JmEHVZIycC7hBoQxHH9pNKQORJNozsQ= -github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8/go.mod h1:wcDNUvekVysuuOpQKo3191zZyTpiI6se1N1ULghS0sw= -github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= -github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/h2non/filetype v1.1.3 h1:FKkx9QbD7HR/zjK1Ia5XiBsq9zdLi5Kf3zGyFTAFkGg= github.com/h2non/filetype v1.1.3/go.mod h1:319b3zT68BvV+WRj7cwy856M2ehB3HqNOt6sy1HndBY= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= github.com/juju/ansiterm v0.0.0-20180109212912-720a0952cc2a/go.mod h1:UJSiEoRfvx3hP73CvoARgeLjaIOjybY9vj8PUPPFGeU= github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5 h1:rhqTjzJlm7EbkELJDKMTU7udov+Se0xZkWmugr6zGok= github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5/go.mod h1:W54LbzXuIE0boCoNJfwqpmkKJ1O4TCTZMetAt6jGk7Q= @@ -49,11 +14,9 @@ github.com/juju/loggo v1.0.0 h1:Y6ZMQOGR9Aj3BGkiWx7HBbIx6zNwNkxhVNOHU2i1bl0= github.com/juju/loggo v1.0.0/go.mod h1:NIXFioti1SmKAlKNuUwbMenNdef59IF52+ZzuOmHYkg= github.com/juju/testing v0.0.0-20200510222523-6c8c298c77a0 h1:+WWUkhnTjV6RNOxkcwk79qrjeyHEHvBzlneueBsatX4= github.com/juju/testing v0.0.0-20200510222523-6c8c298c77a0/go.mod h1:hpGvhGHPVbNBraRLZEhoQwFLMrjK8PSlO4D3nDjKYXo= -github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= -github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= github.com/klauspost/compress v1.15.13 h1:NFn1Wr8cfnenSJSA46lLq4wHCcBzKTSjnBIexDMMOV0= github.com/klauspost/compress v1.15.13/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= +github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= @@ -63,71 +26,30 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/lunixbochs/vtclean v0.0.0-20160125035106-4fbf7632a2c6/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= github.com/mattn/go-colorable v0.0.6/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-isatty v0.0.0-20160806122752-66b8e73f3f5c/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/onsi/gomega v1.34.1 h1:EUMJIKUjM8sKjYbtxQI9A4z2o+rruxnzNvpknOXie6k= -github.com/onsi/gomega v1.34.1/go.mod h1:kU1QgUvBDLXBJq618Xvm2LUX6rSAfRaFRTcdOeDLwwY= github.com/otiai10/copy v1.14.1 h1:5/7E6qsUMBaH5AnQ0sSLzzTg1oTECmcCmT6lvF45Na8= github.com/otiai10/copy v1.14.1/go.mod h1:oQwrEDDOci3IM8dJF0d8+jnbfPDllW6vUjNc3DoZm9I= github.com/otiai10/mint v1.6.3 h1:87qsV/aw1F5as1eH1zS/yqHY85ANKVMgkDrf9rcxbQs= github.com/otiai10/mint v1.6.3/go.mod h1:MJm72SBthJjz8qhefc4z1PYEieWmy8Bku7CjcAqyUSM= -github.com/pjbgf/sha1cd v0.3.2 h1:a9wb0bp1oC2TGwStyn0Umc/IGKQnEgF0vVaZ8QF8eo4= -github.com/pjbgf/sha1cd v0.3.2/go.mod h1:zQWigSxVmsHEZow5qaLtPYxpcKMMQpa09ixqBxuCS6A= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0tI/otEQ= github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/skeema/knownhosts v1.3.1 h1:X2osQ+RAjK76shCbvhHHHVl3ZlgDm8apHEHFqRjnBY8= -github.com/skeema/knownhosts v1.3.1/go.mod h1:r7KTdC8l4uxWRyK2TpQZ/1o5HaSzh06ePQNxPwTcfiY= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= -github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= -github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/ulikunitz/xz v0.5.12 h1:37Nm15o69RwBkXM0J6A5OlE67RZTfzUxTj8fB3dfcsc= -github.com/ulikunitz/xz v0.5.12/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= -github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= -github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= -golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.35.0 h1:b15kiHdrGCHrP6LvwaQ3c03kgNhhiMgvlhxHQhmg2Xs= -golang.org/x/crypto v0.35.0/go.mod h1:dy7dXNW32cAb/6/PRuTNsix8T+vJAqvuIy5Bli/x0YQ= -golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 h1:2dVuKD2vS7b0QIHQbpyTISPd0LeHDbnYEryqj5Q1ug8= -golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56/go.mod h1:M4RDyNAINzryxdtnbRXRL/OHtkFuWGRjvuhBJpk2IlY= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.35.0 h1:T5GQRQb2y08kTAByq9L4/bz8cipCdA8FbRTXewonqY8= -golang.org/x/net v0.35.0/go.mod h1:EglIi67kWsHKlRzzVMUD93VMSWGFOMSZgxFjparz1Qk= -golang.org/x/net v0.36.0 h1:vWF2fRbw4qslQsQzgFqZff+BItCvGFQqKzKIzx1rmoA= -golang.org/x/net v0.36.0/go.mod h1:bFmbeoIPfrw4sMHNhb4J9f6+tPziuGjq7Jk/38fxi1I= +github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= +github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= +github.com/ulikunitz/xz v0.5.14 h1:uv/0Bq533iFdnMHZdRBTOlaNMdb1+ZxXIlHDZHIHcvg= +github.com/ulikunitz/xz v0.5.14/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.30.0 h1:QjkSwP/36a20jFYWkSue1YwXzLmsV5Gfq7Eiy72C1uc= -golang.org/x/sys v0.30.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/term v0.29.0 h1:L6pJp37ocefwRRtYPKSWOWzOtWSxVajvz2ldH/xi3iU= -golang.org/x/term v0.29.0/go.mod h1:6bl4lRlvVuDgSf3179VpIxBF0o10JUpXWOnI7nErv7s= -golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.22.0 h1:bofq7m3/HAFvbF51jz3Q9wLg3jkvSPuiZu/pD1XwgtM= -golang.org/x/text v0.22.0/go.mod h1:YRoo4H8PVmsu+E3Ou7cqLVH8oXWIHVoX0jqUWALQhfY= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/sys v0.43.0 h1:Rlag2XtaFTxp19wS8MXlJwTvoh8ArU6ezoyFsMyCTNI= +golang.org/x/sys v0.43.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20160105164936-4f90aeace3a2/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22 h1:VpOs+IwYnYBaFnrNAeB8UUWtL3vEUnzSCL1nVjPhqrw= gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= -gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= -gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= From ff7cf379517480f57bd49d4c62178a1121f9cb09 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Tue, 30 Jun 2026 12:45:02 +0200 Subject: [PATCH 004/162] fix(tools/sync-zephyr-artifacts): update xz dependency to v0.5.15 Force a version update of the xz dependency to v0.5.15 in the go.mod file of the sync-zephyr-artifacts tool to fix the following issue with v0.5.14 when building on darwin/arm64: lzma/reader.go:33:15: cannot use 1 << 31 (untyped int constant 2147483648) as int value in assignment (overflows) See https://github.com/ulikunitz/xz/issues/65 . --- tools/sync-zephyr-artifacts/go.mod | 2 +- tools/sync-zephyr-artifacts/go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/sync-zephyr-artifacts/go.mod b/tools/sync-zephyr-artifacts/go.mod index 97d68d1c0..04799094f 100644 --- a/tools/sync-zephyr-artifacts/go.mod +++ b/tools/sync-zephyr-artifacts/go.mod @@ -5,6 +5,7 @@ go 1.25.0 require ( github.com/codeclysm/extract/v4 v4.0.0 github.com/otiai10/copy v1.14.1 + github.com/ulikunitz/xz v0.5.15 ) require ( @@ -16,7 +17,6 @@ require ( github.com/otiai10/mint v1.6.3 // indirect github.com/rogpeppe/go-internal v1.14.1 // indirect github.com/stretchr/testify v1.11.1 // indirect - github.com/ulikunitz/xz v0.5.14 // indirect golang.org/x/sync v0.8.0 // indirect golang.org/x/sys v0.43.0 // indirect gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect diff --git a/tools/sync-zephyr-artifacts/go.sum b/tools/sync-zephyr-artifacts/go.sum index 54515a9ba..1ad89c900 100644 --- a/tools/sync-zephyr-artifacts/go.sum +++ b/tools/sync-zephyr-artifacts/go.sum @@ -38,8 +38,8 @@ github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0t github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= -github.com/ulikunitz/xz v0.5.14 h1:uv/0Bq533iFdnMHZdRBTOlaNMdb1+ZxXIlHDZHIHcvg= -github.com/ulikunitz/xz v0.5.14/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= +github.com/ulikunitz/xz v0.5.15 h1:9DNdB5s+SgV3bQ2ApL10xRc35ck0DuIX/isZvIk+ubY= +github.com/ulikunitz/xz v0.5.15/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.43.0 h1:Rlag2XtaFTxp19wS8MXlJwTvoh8ArU6ezoyFsMyCTNI= From ae534659b9f8093a0d0ce7b984a396b29ded814e Mon Sep 17 00:00:00 2001 From: Michal Gora Date: Wed, 8 Jul 2026 13:35:11 +0200 Subject: [PATCH 005/162] docs: correct typos and improve clarity in documentation files --- documentation/arduino_libs.md | 4 +- documentation/dynamic_pinmux.md | 78 ++++++++++++++++---------------- documentation/variants.md | 80 +++++++++++++++++---------------- 3 files changed, 83 insertions(+), 79 deletions(-) diff --git a/documentation/arduino_libs.md b/documentation/arduino_libs.md index 9118575c4..779161598 100644 --- a/documentation/arduino_libs.md +++ b/documentation/arduino_libs.md @@ -18,11 +18,11 @@ Let's assume the structure of your application for simplicity to be, Paste your library's source files like ``ADXL345.h`` and ``ADXL345.cpp`` in your project's src folder. ## Update CMakeLists -As we can see, there is a Top-level CMakelists which needs to be updated with your external library's source files. +As we can see, there is a Top-level CMakeLists.txt which needs to be updated with your external library's source files. For example, we add `target_sources(app PRIVATE src/ADXL345.cpp)` to CMakeLists.txt. ## Update main.cpp -Finally, paste your required code using the library in ``main.c`` and include that library's header using +Finally, paste your required code using the library in ``main.cpp`` and include that library's header using ```c #include "ADXL345.h" ``` diff --git a/documentation/dynamic_pinmux.md b/documentation/dynamic_pinmux.md index 350d80ec8..993057f91 100644 --- a/documentation/dynamic_pinmux.md +++ b/documentation/dynamic_pinmux.md @@ -29,7 +29,7 @@ PINCTRL_STATE_SLEEP = 1 PINCTRL_STATE_PRIV_START = 2 ``` -Custom state name arduino is defined in devicetree and mapped to PINCTRL_STATE_ARDUINO. +The custom state name `arduino` is defined in devicetree and mapped to `PINCTRL_STATE_ARDUINO`. Typical mapping: @@ -37,67 +37,67 @@ Typical mapping: - sleep: optional low-power/disconnected state (not used) - arduino: custom channel list used for per-pin restore (mainly ADC/PWM/DAC) -## Runtime Infrastructure in zephyrPinctrl.cpp +## Runtime Infrastructure in `zephyrPinctrl.cpp` The core builds a runtime map between devices and pinctrl configs. -Selection rule for nodes included in the map is node is zephyr,deferred-init. -Because the Zephyr logging UART is intentionally not marked with zephyr,deferred-init for easier debugging, it is added to the pinctrl map via a dedicated mapping entry. +The selection rule for nodes included in the map is that the node has `zephyr,deferred-init`. +Because the Zephyr logging UART is intentionally not marked with `zephyr,deferred-init` for easier debugging, it is added to the pinctrl map via a dedicated mapping entry. The map is then used by APIs: -- init_dev_apply_pinctrl(dev) -- init_dev_apply_channel_pinctrl(dev, state_pin_idx) +- `init_dev_apply_pinctrl(dev)` +- `init_dev_apply_channel_pinctrl(dev, state_pin_idx)` If a device has no known pinctrl config in the map: -- init_dev_apply_channel_pinctrl(...) returns -ENOTSUP, -- init_dev_apply_pinctrl(...) still initializes the device/dependencies but skips pinctrl apply for entries +- `init_dev_apply_channel_pinctrl(...)` returns `-ENOTSUP`, +- `init_dev_apply_pinctrl(...)` still initializes the device/dependencies but skips pinctrl apply for entries not present in the map. ## Dynamic Pinmux APIs and Runtime Flow -### init_dev_apply_pinctrl(dev) +### `init_dev_apply_pinctrl(dev)` Purpose: initialize the target device and its dependencies, then apply the whole pinctrl -PINCTRL_STATE_DEFAULT state where pinctrl configuration is known. +`PINCTRL_STATE_DEFAULT` state where pinctrl configuration is known. Used for full peripheral remux, to restore the default state. -SPI (SPI.begin), I2C (Wire.begin) and UART (ZephyrSerial::begin) calls init_dev_apply_pinctrl(dev), without taking care of device readiness/init. +SPI (`SPI.begin`), I2C (`Wire.begin`) and UART (`ZephyrSerial::begin`) call `init_dev_apply_pinctrl(dev)`, without taking care of device readiness/init. Behavior details: - recursively initializes required dependencies first, - initializes each device on first use if needed, -- applies PINCTRL_STATE_DEFAULT from known device pinctrl configs, -- treats -ENOENT from pinctrl_apply_state as non-fatal (for empty/default-less states). +- applies `PINCTRL_STATE_DEFAULT` from known device pinctrl configs, +- treats `-ENOENT` from `pinctrl_apply_state` as non-fatal (for empty/default-less states). -### init_dev_apply_channel_pinctrl(dev, state_pin_idx) +### `init_dev_apply_channel_pinctrl(dev, state_pin_idx)` -Purpose: apply only one pin from the device arduino state. +Purpose: apply only one pin from the device `arduino` state. -Used for channel-based peripherals (ADC/PWM/DAC) in the analogRead and analogWrite functions, allowing a single channel can be remuxed without touching sibling channels. +Used for channel-based peripherals (ADC/PWM/DAC) in the `analogRead` and `analogWrite` functions, allowing a single channel to be remuxed without touching sibling channels. Behavior details: - initializes the device on first use if needed, -- resolves PINCTRL_STATE_ARDUINO, -- applies only one pin entry (state_pin_idx), with bounds checking. +- resolves `PINCTRL_STATE_ARDUINO`, +- applies only one pin entry (`state_pin_idx`), with bounds checking. Implementation pattern: - resolve analog/pwm index from pin, -- compute a per-device ordinal index with state_pin_index_from_spec_index(arduino_adc/arduino_pwm, idx), -- call init_dev_apply_channel_pinctrl(dev, per_dev_idx), +- compute a per-device ordinal index with `state_pin_index_from_spec_index(arduino_adc/arduino_pwm, idx)`, +- call `init_dev_apply_channel_pinctrl(dev, per_dev_idx)`, -How state_pin_index_from_spec_index works: +How `state_pin_index_from_spec_index` works: -- spec_idx is the global position in the zephyr,user array (io-channels for ADC or pwms for PWM). For example, A1/D1 maps to spec_idx = 1 (second entry); -- state_pin_index_from_spec_index(...) scans previous entries [0..spec_idx-1] and counts only those that reference the same device (i.e. the same PWM/ADC controller instance, such as pwm4); -- the resulting count is the per-device ordinal (0, 1, 2, ...) used as state_pin_idx in the device arduino pinctrl state. +- `spec_idx` is the global position in the `zephyr,user` array (`io-channels` for ADC or `pwms` for PWM). For example, A1/D1 maps to `spec_idx = 1` (second entry); +- `state_pin_index_from_spec_index(...)` scans previous entries `[0..spec_idx-1]` and counts only those that reference the same device (i.e. the same PWM/ADC controller instance, such as `pwm4`); +- the resulting count is the per-device ordinal (0, 1, 2, ...) used as `state_pin_idx` in the device `arduino` pinctrl state. -Example (GIGA PWM list in zephyr,user): +Example (GIGA PWM list in `zephyr,user`): ```dts pwms = <&pwm1 3 PWM_HZ(12000000) PWM_POLARITY_NORMAL>, @@ -116,14 +116,14 @@ pwms = <&pwm1 3 PWM_HZ(12000000) PWM_POLARITY_NORMAL>, <&pwm1 1 PWM_HZ(5000) PWM_POLARITY_NORMAL>; ``` -If analogWrite() resolves to spec_idx = 8 (9th entry, `&pwm4 4`): +If `analogWrite()` resolves to `spec_idx = 8` (9th entry, `&pwm4 4`): -- device = pwm4 -- previous pwm4 entries are at spec_idx 5 and 7 +- device = `pwm4` +- previous `pwm4` entries are at `spec_idx` 5 and 7 - count of previous same-device entries = 2 -- state_pin_idx = 2 (zero-based) +- `state_pin_idx = 2` (zero-based) -Then init_dev_apply_channel_pinctrl(pwm4, 2) selects the 3rd entry of pwm4 `pinctrl-2`. +Then `init_dev_apply_channel_pinctrl(pwm4, 2)` selects the 3rd entry of `pwm4` `pinctrl-2`. ```dts pwm4: pwm { @@ -140,7 +140,7 @@ In this example, the selected pin is `tim4_ch4_pb9`. Effect: -- only the requested ADC pad or PWM pad is remuxed to analog function. +- only the requested ADC pad or PWM pad is remuxed to its target peripheral function. ## Devicetree Requirements @@ -158,17 +158,17 @@ Use deferred init and provide usual default/sleep states. }; ``` -Same pattern applies to i2cX and uartX. +Same pattern applies to `i2cX` and `uartX`. Note: the runtime map explicitly includes the node selected as `zephyr,console` even when it is -not deferred-init. +not `deferred-init`. -Recommendation: keep the UART used for early logs available from boot; if it is deferred-init, +Recommendation: keep the UART used for early logs available from boot; if it is `deferred-init`, early error logs generated during system startup or sketch load may not be visible. ### For channel-based ADC/PWM/DAC nodes -Use deferred init and keep channel pads in pinctrl-2 and name it arduino. +Use deferred init and keep channel pads in `pinctrl-2` and name it `arduino`. ```dts &periphN { @@ -185,16 +185,16 @@ Use deferred init and keep channel pads in pinctrl-2 and name it arduino. For each ADC/PWM device, ordering must match between: -- zephyr,user spec arrays (io-channels or pwms), and -- that device arduino pin list (pinctrl-2). +- `zephyr,user` spec arrays (`io-channels` or `pwms`), and +- that device `arduino` pin list (`pinctrl-2`). -state_pin_index_from_spec_index() assumes this ordinal alignment to map a logical channel entry to the correct pin in the arduino state. +`state_pin_index_from_spec_index()` assumes this ordinal alignment to map a logical channel entry to the correct pin in the `arduino` state. ## Known limitation - Nordic nRF On Nordic nRF targets, switching a pin from PWM back to another peripheral may leave PWM still affecting that pin unless PWM is explicitly stopped first. -The reason is architectural: in the nRF pinctrl/driver model, pin routing is programmed per peripheral by writing that peripheral’s PSEL registers. Reconfiguring the new peripheral (i.e. SPI) updates SPI’s PSEL, but it does not automatically clear PWM’s PSEL ownership for the same physical pin. +The reason is architectural: in the nRF pinctrl/driver model, pin routing is programmed per peripheral by writing that peripheral’s `PSEL` registers. Reconfiguring the new peripheral (i.e. SPI) updates SPI’s `PSEL`, but it does not automatically clear PWM’s `PSEL` ownership for the same physical pin. In our current core flow, we do not keep global runtime ownership tracking across peripherals for each pin, so we cannot reliably force-release the previous owner in all cases. This limitation is relevant only when the same pin was previously configured/driven by PWM and is now being reassigned to another peripheral. diff --git a/documentation/variants.md b/documentation/variants.md index 300c6a17a..5f5ff6e60 100644 --- a/documentation/variants.md +++ b/documentation/variants.md @@ -1,10 +1,10 @@ -# Adding custom boards/ variants +# Adding custom boards/variants - Boards already supported by Zephyr can be added to the variants folder as outlined in this documentation. -- Custom boards can first by added by following the [official Zephyr porting guide](https://docs.zephyrproject.org/latest/hardware/porting/board_porting.html). +- Custom boards can first be added by following the [official Zephyr porting guide](https://docs.zephyrproject.org/latest/hardware/porting/board_porting.html). Once completed, continue here by adding a variant for your custom board. -## Suppored Boards/variants +## Supported Boards/variants - [X] Arduino Nano ble sense 33 - [X] Arduino Nano ble 33 @@ -26,7 +26,7 @@ target board. To add board support: 1. This project is structured in a way so as to isolate the variants from the core API. Thus, whenever a new board needs to be added it needs to be done in the `variants/` folder. Add a folder inside of the variants folder that matches the name of your board. -2. Add an overlay file file that match the name of the board. +2. Add an overlay file that matches the name of the board. 3. Add a `variant.h` file. An example of this structure is shown below. @@ -45,13 +45,19 @@ variants/ The Arduino API requires pin mapping definitions to use Arduino-style pin numbers (pin numbers printed on the board, not GPIO numbers). The pin-mapping node is under the `zephyr,user` node of DTS. -`digital-pin-gpios` defines digital input/output pins that is D0, D1, .., -`adc-pin-gpios` defines analog input pins that is A0, A1, ... . +`digital-pin-gpios` defines digital input/output pins, i.e. D0, D1, ..., +`adc-pin-gpios` defines analog input pins, i.e. A0, A1, etc. `pwm-pin-gpios` defines PWM pins. Each pin specifies in the form of a GPIO cell. Usually, it is in the form of `<[port] [pin-number] [flag]>`. You can also use the Arduino header node definition here. +> [!NOTE] +> For phandle-array properties like these (`digital-pin-gpios`, `adc-pin-gpios`, +> `pwm-pin-gpios`, `serials`, `i2cs`, etc.), both `<&dev1 &dev2>` (multiple entries in a +> single bracket group) and `<&dev1>, <&dev2>` (separate bracket groups joined by commas) +> are valid DTS syntax. However, `<&dev1, &dev2>` is **invalid**. + ### Overlays using previously-defined Arduino headers When an Arduino header exists in a board's in-tree DTS file it can easily be @@ -66,18 +72,17 @@ uses [the Arduino header definitions](https://github.com/zephyrproject-rtos/zeph ``` / { zephyr,user { - digital-pin-gpios = <&arduino_header 6 0>, /* Digital */ - <&arduino_header 7 0>; - ... - <&arduino_header 19 0>; - <&arduino_header 0 0>; /* Analog */ - <&arduino_header 1 0>; - ... - <&arduino_header 5 0>; - <&arduino_header 20 0>; /* SDA */ - <&arduino_header 21 0>; /* SCL */ - <&gpio0 13 GPIO_ACTIVE_LOW>; /* LED0 */ - }; + digital-pin-gpios = <&arduino_header 6 0>, /* Digital */ + <&arduino_header 7 0>, + ... + <&arduino_header 19 0>, + <&arduino_header 0 0>, /* Analog */ + <&arduino_header 1 0>, + ... + <&arduino_header 5 0>, + <&arduino_header 20 0>, /* SDA */ + <&arduino_header 21 0>, /* SCL */ + <&gpio0 13 GPIO_ACTIVE_LOW>; /* LED0 */ }; }; ``` @@ -85,15 +90,15 @@ uses [the Arduino header definitions](https://github.com/zephyrproject-rtos/zeph ### Configure Serial devices The `serials` node defines the Serial devices to use. -It instantiate the `Serial` with the UART device that contained in the node. -Also instantiate as `Serial1`, `Serial2`, .. `SerialN` with the devices that is -after the second in the case of the array contains plural devices. +It instantiates `Serial` with the UART device contained in the node. +Also instantiates `Serial1`, `Serial2`, ... `SerialN` with the devices +after the first when the array contains more than one device. -If the `serials` node is not defined, Use the node labeled `arduino-serial`. +If the `serials` node is not defined, use the node labeled `arduino-serial`. Boards with Arduino-shield style connectors usually label `arduino-serial` for UART port exposed in header or frequently used UART port. -If even 'arduino_serial' does not define, it uses the stub implementation +If even `arduino_serial` is not defined, it uses the stub implementation that redirects to printk(). The following example instantiates `Serial` and `Serial1` with each `uart0` and `uart1`. @@ -101,7 +106,7 @@ The following example instantiates `Serial` and `Serial1` with each `uart0` and ``` / { zephyr,user { - serials = <&uart0, &uart1>; + serials = <&uart0>, <&uart1>; }; }; ``` @@ -109,20 +114,20 @@ The following example instantiates `Serial` and `Serial1` with each `uart0` and ### Configure I2C devices The `i2cs` node defines the I2C devices to use. -It instantiate the `Wire` with the i2c device that contained in the node. -Also instantiate as `Wire1`, `Wire2`, .. `WireN` with the devices -that is after the second in the case of the array contains plural devices. +It instantiates `Wire` with the i2c device contained in the node. +Also instantiates `Wire1`, `Wire2`, ... `WireN` with the devices +after the first when the array contains more than one device. -If the `i2cs` node is not defined, Use the node labeled `arduino-i2c`. +If the `i2cs` node is not defined, use the node labeled `arduino-i2c`. Boards with Arduino-shield style connectors usually label `arduino-i2c` to i2c exposed in the connector. -The following example instantiates `Wire` and `Wire2` with each `i2c0` and `i2c1`. +The following example instantiates `Wire` and `Wire1` with each `i2c0` and `i2c1`. ``` / { zephyr,user { - i2cs = <&i2c0, &i2c1>; + i2cs = <&i2c0 &i2c1>; }; }; ``` @@ -135,16 +140,15 @@ array to find the index of the pin. The node is phandle-array, which uses the format same as `digital-pin-gpios`. -It set the digital pin number to the `LED_BUILTIN` if found the pin -that defined in `builtin-led-gpios` from `digital-pin-gpios`. +It sets the digital pin number to `LED_BUILTIN` if the pin +defined in `builtin-led-gpios` is found in `digital-pin-gpios`. -If the `builtin-led-gpios` is not defined, Use the node aliased as `led0` +If the `builtin-led-gpios` is not defined, use the node aliased as `led0` to define `LED_BUILTIN`. -The `LED_BUILTIN` does not define here if it has not found both nodes or -defined `LED_BUILTIN` already. +`LED_BUILTIN` is not defined if neither node is found or `LED_BUILTIN` is already defined. -For example, in the case of the 13th digital pins connected to the onboard LED, +For example, in the case of the 13th digital pin connected to the onboard LED, define `builtin-led-gpios` as follows. ``` @@ -160,7 +164,7 @@ define `builtin-led-gpios` as follows. You can see in the example above that there is no mapping for `LED0` in the board's Arduino header definition so it has been added using the Zephyr `gpios` syntax (port, pin, flags). When creating an overlay file that doesn't have an -Arduino header defined, you should follow this syntax for adding all pins +Arduino header defined, you should follow this syntax for adding all pins. ### You control the pin mapping @@ -168,7 +172,7 @@ Zephyr [chooses to map Arduino headers beginning with the Analog pins](https://docs.zephyrproject.org/latest/build/dts/api/bindings/gpio/arduino-header-r3.html), but the overlay file example above begins with the digital pins. This is to match user -expectation that issuing `pinMode(0,OUTPUT);` should control digital pin 0 (and +expectations that issuing `pinMode(0,OUTPUT);` should control digital pin 0 (and not pin 6). In the same way, the Analog 0 pin was mapped to D14 as this is likely what a shield made for the Arduino Uno R3 header would expect. From f388a11306e46e70fef12533e91b8152eb977aa2 Mon Sep 17 00:00:00 2001 From: Martino Facchin Date: Thu, 9 Jul 2026 11:28:00 +0200 Subject: [PATCH 006/162] unoq: silence bogus error if loader/sketch needs reflashing --- variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg b/variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg index 2cce017de..9e32a69cd 100644 --- a/variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg +++ b/variants/arduino_uno_q_stm32u585xx/flash_sketch.cfg @@ -2,16 +2,26 @@ # SPDX-License-Identifier: Apache-2.0 reset_config srst_only srst_nogate srst_push_pull connect_assert_srst +if {$::tcl_platform(platform) eq "windows"} { + set null_device NUL +} else { + set null_device /dev/null +} init reset halt flash info 0 +log_output $null_device if {[catch {flash verify_image ${filename0}}] != 0} { + log_output default flash write_image erase ${filename0} } +log_output $null_device if {[catch {flash verify_image ${filename1} 0x8100000 bin}] != 0} { + log_output default flash write_image erase ${filename1} 0x8100000 bin } +log_output default reset sleep 100 mww 0x40036400 0xCAFFEEEE From 01ff44b73c9db9a64661748350ea4aca55dad6d2 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Tue, 14 Jul 2026 10:40:44 +0200 Subject: [PATCH 007/162] tools: require arduino/scripting-tools 0.0.7 Needed for automatic loader updates on USB-based boards. --- extra/artifacts/_common.json | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/extra/artifacts/_common.json b/extra/artifacts/_common.json index 9d9723469..4e4fa1cc2 100644 --- a/extra/artifacts/_common.json +++ b/extra/artifacts/_common.json @@ -67,6 +67,11 @@ "packager": "arduino", "name": "bin2uf2", "version": "0.1.0" + }, + { + "packager": "arduino", + "name": "scripting-tools", + "version": "0.0.7" } ] } From 7c12faba1f16a54c3166b12d259206493cb00888 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Wed, 8 Jul 2026 16:19:31 +0200 Subject: [PATCH 008/162] get_board_details.sh: add proper escaping to input fields Escape double quotes and backslashes everywhere in the JSON output of get_board_details.sh to ensure that the output is a valid JSON. --- extra/get_board_details.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extra/get_board_details.sh b/extra/get_board_details.sh index cbe1a1178..a70d8b8b0 100755 --- a/extra/get_board_details.sh +++ b/extra/get_board_details.sh @@ -6,13 +6,13 @@ set -e get_boards() { - cat boards.txt | sed -e 's/\s*#.*//' | grep -E '^.*\.build\.variant=' | sed -e 's/\.build\.variant=.*//' + cat boards.txt | sed -e 's/\s*#.*//' | grep -E '^.*\.build\.variant=' | sed -e 's/\.build\.variant=.*//' -e 's/["\\]/\\&/g' } get_board_field() { board=$1 field=$2 - cat boards.txt | sed -e 's/\s*#.*//' | grep -E "^$board\\.$field=" | cut -d '=' -f2- | sed -e 's/"/\"/g' + cat boards.txt | sed -e 's/\s*#.*//' | grep -E "^$board\\.$field=" | cut -d '=' -f2- | sed -e 's/["\\]/\\&/g' } for BOARD in $(get_boards); do From 4c6b12daa3b7edbbbccd30af697e0c04017bb592 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Wed, 8 Jul 2026 18:56:00 +0200 Subject: [PATCH 009/162] get_core_version.sh: export components to Zephyr VERSION file Rewrite get_core_version.sh to properly separate each version component during processing. Export a Zephyr-compatible VERSION file if a filename is provided as the first argument. --- extra/get_core_version.sh | 84 +++++++++++++++++++++++++++------------ 1 file changed, 59 insertions(+), 25 deletions(-) diff --git a/extra/get_core_version.sh b/extra/get_core_version.sh index 51171cee6..a75eddb1f 100755 --- a/extra/get_core_version.sh +++ b/extra/get_core_version.sh @@ -47,6 +47,9 @@ # environments the correct commit is used, even in pull requests where HEAD # might be a temporary detached commit. +# The computed version is also written to a file in the Zephyr-compatible +# VERSION format if a filename is provided as the first argument. + # Determine pre-release label based on build context if [ -z "$GITHUB_ACTIONS" ]; then # local build, highest precedence @@ -66,36 +69,67 @@ else exit 1 fi -VERSION=$(git describe --tags --exact-match --exclude '*/*' 2>/dev/null) -if [ -z "$VERSION" ]; then - DESCRIBE=$(git describe --tags --exclude '*/*' 2>/dev/null) - if [[ "$DESCRIBE" =~ ^([0-9]+\.[0-9]+\.)([0-9]+)(-.*)?-([0-9]+)-g ]]; then - maj_min="${BASH_REMATCH[1]}" - patch="${BASH_REMATCH[2]}" - prerel="${BASH_REMATCH[3]}" # optional - count="${BASH_REMATCH[4]}" -# echo "Git describe: maj_min='$maj_min' patch='$patch' prerel='$prerel' count='$count'" >&2 - if [ "$KIND" == "tag" ] ; then - # number of commits since tag is irrelevant for a tag push - label="${KIND}.${NAME}" - else - label="${KIND}.${NAME}.${count}" - fi - if [ -z "$prerel" ]; then - STEM="${maj_min}$((patch+1))-0.${label}" - else - STEM="${maj_min}${patch}${prerel}.${label}" - fi +# Get the current version from git describe. +exact_version=$(git describe --tags --exact-match --exclude '*/*' 2>/dev/null) +if [ -n "$exact_version" ] ; then + # must match ..(-) + if [[ $exact_version =~ ^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)? ]] ; then + v_maj="${BASH_REMATCH[1]}" + v_min="${BASH_REMATCH[2]}" + v_patch="${BASH_REMATCH[3]#-}" + v_extra="${BASH_REMATCH[4]}" # optional else - echo "Warning: unexpected git describe output '$DESCRIBE'" >&2 + echo "Error: unexpected tag '$exact_version'" >&2 + exit 1 fi - if [ -z "$STEM" ]; then - # no tags: build in a fork or locally, use a maxed out version with date+hash - STEM="9.9.9-$(date '+%Y%m%d-%H%M%S')" + + # no additional information + v_tweak="" +else + version_from_git=$(git describe --tags --long --exclude '*/*' 2>/dev/null) + # must match ..(-)--g + if [[ $version_from_git =~ ^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)?-([0-9]+)-g.* ]]; then + v_maj="${BASH_REMATCH[1]}" + v_min="${BASH_REMATCH[2]}" + v_patch="${BASH_REMATCH[3]#-}" + v_extra="${BASH_REMATCH[4]}" # optional + count="${BASH_REMATCH[5]}" + else + echo "Error: unexpected git describe output '$version_from_git'" >&2 + exit 1 + fi + + if [ -z "${v_extra}" ]; then + v_patch=$((v_patch+1)) + v_extra="-0" + fi + + if [ "$KIND" == "tag" ] ; then + # number of commits since tag is irrelevant for a tag push + v_extra="${v_extra}.${KIND}.${NAME}" + else + v_extra="${v_extra}.${KIND}.${NAME}.${count}" fi # If HEAD_REF is not set, we're not in CI but in a local clone. Use the # implicit HEAD and include --dirty to test for uncommitted changes. - VERSION="${STEM}+$(git describe --always ${HEAD_REF:---dirty})" + v_tweak="+$(git describe --always ${HEAD_REF:---dirty})" fi + +VERSION="${v_maj}.${v_min}.${v_patch}${v_extra}${v_tweak}" echo $VERSION + +if [ -n "$1" ]; then + # Write the version components to a file in Zephyr-compatible format, + # removing leading separators from EXTRAVERSION and VERSION_TWEAK. + cat > $1 << EOF +# This file is auto-generated by get_core_version.sh. Do not edit. +# Generated from version string: ${VERSION} + +VERSION_MAJOR = ${v_maj} +VERSION_MINOR = ${v_min} +PATCHLEVEL = ${v_patch} +EXTRAVERSION = ${v_extra#-} +VERSION_TWEAK = ${v_tweak#+} +EOF +fi From 1cb49bd09436d129cc0cbea65bedf18ceaaa45e1 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Wed, 8 Jul 2026 19:01:07 +0200 Subject: [PATCH 010/162] build.sh: support writing to platform.local.txt Add the possibility of writing to platform.local.txt instead of boards.local.txt when the board variable is not set. This allows for global configuration settings that are not specific to any particular board to be saved. --- .gitignore | 1 + extra/build.sh | 45 ++++++++++++++++++++++++++------------------- 2 files changed, 27 insertions(+), 19 deletions(-) diff --git a/.gitignore b/.gitignore index 53a2144bc..2c2e2269f 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,7 @@ /firmwares/* /venv/ /boards.local.txt +/platform.local.txt llext-edk/ cflags.txt diff --git a/extra/build.sh b/extra/build.sh index 72396c924..ab084a1f2 100755 --- a/extra/build.sh +++ b/extra/build.sh @@ -138,41 +138,48 @@ update_local_field() { local field=$1 local value="$2" local comment="$3" - local full_field_name="${board}.${field}" + + if [ -z "$board" ]; then + local file="platform.local.txt" + local full_field_name="${field}" + else + local file="boards.local.txt" + local full_field_name="${board}.${field}" + fi local match_regexp="${full_field_name//./\\.}" # escape dots + if [ ! -f $file ] ; then + cat << EOF > $file +######################################################################################### +# +# AUTO GENERATED FILE - DO NOT EDIT +# This file is manipulated by extra/build.sh; manual changes may be overwritten. +# +######################################################################################### + +EOF + fi + if [ -n "$comment" ]; then # if there's a comment, add/update it as a commented-out line above the actual field - if grep -qE "^# ${match_regexp}:" boards.local.txt; then - sed -i -e "s/^# ${match_regexp}:.*/# ${full_field_name}: ${comment}/" boards.local.txt + if grep -qE "^# ${match_regexp}:" $file; then + sed -i -e "s/^# ${match_regexp}:.*/# ${full_field_name}: ${comment}/" $file else - echo "# ${full_field_name}: ${comment}" >> boards.local.txt + echo "# ${full_field_name}: ${comment}" >> $file fi fi # update the actual field line - if grep -qE "^${match_regexp}" boards.local.txt; then - sed -i -e "s/^${match_regexp}=.*/${full_field_name}=${value}/" boards.local.txt + if grep -qE "^${match_regexp}" $file; then + sed -i -e "s/^${match_regexp}=.*/${full_field_name}=${value}/" $file else - echo "${full_field_name}=${value}" >> boards.local.txt + echo "${full_field_name}=${value}" >> $file fi } # update properties on boards.local.txt from the generated files if [ ! -z "$board" ]; then - if [ ! -f boards.local.txt ] ; then - cat << EOF > boards.local.txt -######################################################################################### -# -# AUTO GENERATED FILE - DO NOT EDIT -# This file is manipulated by extra/build.sh; manual changes may be overwritten. -# -######################################################################################### - -EOF - fi - # sketch load address: start of sketch partition, hex (exact) CODE_ADDR=$(get_value_from_text_file variants/${variant}/syms-static.ld '_sketch_start') if [ -z "$upload_offset" ] ; then From d0f9b72d13fa504edcb412c1cc33865b8c6dede0 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Wed, 8 Jul 2026 19:04:57 +0200 Subject: [PATCH 011/162] build.sh: store per-board and global build version The build.sh script now saves the build version to loader/VERSION (so it is picked up by the Zephyr build system) and updates the version field in both platform.local.txt and boards.local.txt. To ensure multiple boards share the same version, the build_all.sh script exports a global PINNED_CORE_VERSION environment variable so that get_core_version.sh can use it instead of generating a new version for each run. --- extra/build.sh | 11 +++++ extra/build_all.sh | 3 ++ extra/get_core_version.sh | 88 +++++++++++++++++++++++---------------- extra/package_core.sh | 2 + 4 files changed, 69 insertions(+), 35 deletions(-) diff --git a/extra/build.sh b/extra/build.sh index ab084a1f2..3ab542027 100755 --- a/extra/build.sh +++ b/extra/build.sh @@ -68,7 +68,11 @@ else fi fi +# Save the build version to loader/VERSION and for later use in local files +build_version=$(extra/get_core_version.sh loader/VERSION) + echo +echo "Build version: $build_version" echo "Build target: $target $args" # Get the variant name (NORMALIZED_BOARD_TARGET in Zephyr) @@ -180,6 +184,13 @@ EOF # update properties on boards.local.txt from the generated files if [ ! -z "$board" ]; then + # save version to both platform.local.txt and boards.local.txt: + # - the platform one is reported by the IDE as _the_ core version; + # - the board-specific one is used by the auto-update-loader feature + # (when developing, each board build should be tracked separately). + board="" update_local_field "version" "$build_version" + update_local_field "version" "$build_version" + # sketch load address: start of sketch partition, hex (exact) CODE_ADDR=$(get_value_from_text_file variants/${variant}/syms-static.ld '_sketch_start') if [ -z "$upload_offset" ] ; then diff --git a/extra/build_all.sh b/extra/build_all.sh index 38c4174e1..70ddf5c1f 100755 --- a/extra/build_all.sh +++ b/extra/build_all.sh @@ -27,6 +27,9 @@ if [ ! -z "$GITHUB_STEP_SUMMARY" ] ; then echo "### Variant build results:" >> "$GITHUB_STEP_SUMMARY" fi +# This will force all boards to share the same build version +export PINNED_CORE_VERSION=$(extra/get_core_version.sh) + final_result=0 while read -r item; do board=$(jq -cr '.board' <<< "$item") diff --git a/extra/get_core_version.sh b/extra/get_core_version.sh index a75eddb1f..5c2b2e913 100755 --- a/extra/get_core_version.sh +++ b/extra/get_core_version.sh @@ -69,51 +69,69 @@ else exit 1 fi -# Get the current version from git describe. -exact_version=$(git describe --tags --exact-match --exclude '*/*' 2>/dev/null) -if [ -n "$exact_version" ] ; then - # must match ..(-) - if [[ $exact_version =~ ^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)? ]] ; then +if [ -n "$PINNED_CORE_VERSION" ] ; then + # If PINNED_CORE_VERSION is set, use it as the version (extract fields) + # must match ..(-)(+) + pattern='^([0-9]+)\.([0-9]+)\.([0-9]+)(-[^+]*)?(\+.*)?' + if [[ $PINNED_CORE_VERSION =~ $pattern ]]; then v_maj="${BASH_REMATCH[1]}" v_min="${BASH_REMATCH[2]}" - v_patch="${BASH_REMATCH[3]#-}" - v_extra="${BASH_REMATCH[4]}" # optional + v_patch="${BASH_REMATCH[3]}" + v_extra="${BASH_REMATCH[4]}" # optional, lead - + v_tweak="${BASH_REMATCH[5]}" # optional, lead + else - echo "Error: unexpected tag '$exact_version'" >&2 + echo "Error: unexpected pinned ver '$PINNED_CORE_VERSION'" >&2 exit 1 fi - - # no additional information - v_tweak="" else - version_from_git=$(git describe --tags --long --exclude '*/*' 2>/dev/null) - # must match ..(-)--g - if [[ $version_from_git =~ ^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)?-([0-9]+)-g.* ]]; then - v_maj="${BASH_REMATCH[1]}" - v_min="${BASH_REMATCH[2]}" - v_patch="${BASH_REMATCH[3]#-}" - v_extra="${BASH_REMATCH[4]}" # optional - count="${BASH_REMATCH[5]}" + exact_version=$(git describe --tags --exact-match --exclude '*/*' 2>/dev/null) + if [ -n "$exact_version" ] ; then + # this is a tagged build, extract the version components from the tag + # must match ..(-) + pattern='^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)?' + if [[ $exact_version =~ $pattern ]]; then + v_maj="${BASH_REMATCH[1]}" + v_min="${BASH_REMATCH[2]}" + v_patch="${BASH_REMATCH[3]}" + v_extra="${BASH_REMATCH[4]}" # optional, lead - + else + echo "Error: unexpected tag '$exact_version'" >&2 + exit 1 + fi + + # no additional information + v_tweak="" else - echo "Error: unexpected git describe output '$version_from_git'" >&2 - exit 1 - fi + version_from_git=$(git describe --tags --long --exclude '*/*' 2>/dev/null) + # must match ..(-)--g + pattern='^([0-9]+)\.([0-9]+)\.([0-9]+)(-.*)?-([0-9]+)-g.*' + if [[ $version_from_git =~ $pattern ]]; then + v_maj="${BASH_REMATCH[1]}" + v_min="${BASH_REMATCH[2]}" + v_patch="${BASH_REMATCH[3]}" + v_extra="${BASH_REMATCH[4]}" # optional, lead - + count="${BASH_REMATCH[5]}" + else + echo "Error: unexpected git describe output '$version_from_git'" >&2 + exit 1 + fi - if [ -z "${v_extra}" ]; then - v_patch=$((v_patch+1)) - v_extra="-0" - fi + if [ -z "${v_extra}" ]; then + v_patch=$((v_patch+1)) + v_extra="-0" + fi - if [ "$KIND" == "tag" ] ; then - # number of commits since tag is irrelevant for a tag push - v_extra="${v_extra}.${KIND}.${NAME}" - else - v_extra="${v_extra}.${KIND}.${NAME}.${count}" - fi + if [ "$KIND" == "tag" ] ; then + # number of commits since tag is irrelevant for a tag push + v_extra="${v_extra}.${KIND}.${NAME}" + else + v_extra="${v_extra}.${KIND}.${NAME}.${count}" + fi - # If HEAD_REF is not set, we're not in CI but in a local clone. Use the - # implicit HEAD and include --dirty to test for uncommitted changes. - v_tweak="+$(git describe --always ${HEAD_REF:---dirty})" + # If HEAD_REF is not set, we're not in CI but in a local clone. Use the + # implicit HEAD and include --dirty to test for uncommitted changes. + v_tweak="+$(git describe --always ${HEAD_REF:---dirty})" + fi fi VERSION="${v_maj}.${v_min}.${v_patch}${v_extra}${v_tweak}" diff --git a/extra/package_core.sh b/extra/package_core.sh index d1c4179d8..77b431480 100755 --- a/extra/package_core.sh +++ b/extra/package_core.sh @@ -54,6 +54,8 @@ for board in $EXCLUDED_BOARDS ; do # remove (even commented) lines for excluded boards sed -i "/^\(\s*#\s*\)\?${board}\./d" $TEMP_BOARDS done +# remove any per-board version lines +sed -i '/^\S*\.version=/d' $TEMP_BOARDS # remove multiple empty lines sed -i '/^$/N;/^\n$/D' $TEMP_BOARDS From ecb59dc8f3abc2f135cdca41e18d1fc13a4a35f5 Mon Sep 17 00:00:00 2001 From: Martino Facchin Date: Fri, 17 Apr 2026 17:17:55 +0200 Subject: [PATCH 012/162] usb: pass Zephyr core version in USB descriptor as iConfig This is step 1. for automatic flash of the loader if the onboard version is different from the one shipped with the core: passing the current build version in the USB descriptor as iConfig, so that it is available on the host side to check if the loader needs to be reflashed. For the legacy USB stack, the version is passed to USB drivers directly via the Kconfig option CONFIG_USB_CONFIGURATION_STRING_DESC. Boards using the new USB stack, like the Portenta C33, set this value via the USBD_DESC_CONFIG_DEFINE macro instead. --- cores/arduino/usb_device_descriptor.c | 5 +++-- loader/Kconfig | 3 +++ loader/prj.conf | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/cores/arduino/usb_device_descriptor.c b/cores/arduino/usb_device_descriptor.c index 646bd84d7..0643c69ca 100644 --- a/cores/arduino/usb_device_descriptor.c +++ b/cores/arduino/usb_device_descriptor.c @@ -11,6 +11,7 @@ #include #include +#include #ifdef CONFIG_USB_DEVICE_STACK_NEXT @@ -32,8 +33,8 @@ USBD_DESC_PRODUCT_DEFINE(sample_product, CONFIG_USB_DEVICE_PRODUCT); USBD_DESC_SERIAL_NUMBER_DEFINE(sample_sn); /* doc string instantiation end */ -USBD_DESC_CONFIG_DEFINE(fs_cfg_desc, "FS Configuration"); -USBD_DESC_CONFIG_DEFINE(hs_cfg_desc, "HS Configuration"); +USBD_DESC_CONFIG_DEFINE(fs_cfg_desc, APP_VERSION_EXTENDED_STRING); +USBD_DESC_CONFIG_DEFINE(hs_cfg_desc, APP_VERSION_EXTENDED_STRING); /* doc configuration instantiation start */ static const uint8_t attributes = 0; diff --git a/loader/Kconfig b/loader/Kconfig index 216d0d959..9965f3757 100644 --- a/loader/Kconfig +++ b/loader/Kconfig @@ -7,6 +7,9 @@ config PINCTRL select PINCTRL_NON_STATIC +config USB_CONFIGURATION_STRING_DESC + default "$(APP_VERSION_EXTENDED_STRING)" + source "Kconfig.zephyr" config LLEXT_HEAP_REGION diff --git a/loader/prj.conf b/loader/prj.conf index 0b48b8ca1..ce28c9433 100644 --- a/loader/prj.conf +++ b/loader/prj.conf @@ -51,3 +51,5 @@ CONFIG_RTC_UPDATE=y CONFIG_RTC_CALIBRATION=y CONFIG_DEVICE_DEPS=y + +CONFIG_USB_CONFIGURATION_STRING_DESC_ENABLE=y From fdcb9be3404e63fcd43b8f49a0d679075bdee94c Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Thu, 9 Jul 2026 11:02:55 +0200 Subject: [PATCH 013/162] platform: add upload.artifacts variables, cleanup Add generic 'upload.artifacts.loader' and 'upload.artifacts.sketch' variables to platform.txt to allow for cleaner upload patterns and explicit file dependencies. Remove 'stm32flash' and 'adb' upload patterns, as they are not used by any of the supported boards. Also remove any '.erase' patterns, as all of them were empty anyway. --- platform.txt | 88 +++++++++++++++++----------------------------------- 1 file changed, 29 insertions(+), 59 deletions(-) diff --git a/platform.txt b/platform.txt index 9c541554c..b066724ea 100644 --- a/platform.txt +++ b/platform.txt @@ -164,64 +164,51 @@ pluggable_monitor.required.serial=builtin:serial-monitor # Uploader tools # -------------- +# No erase command is needed for Zephyr targets +erase.pattern= + +# Generated files used at upload time +upload.artifacts.loader={runtime.platform.path}/firmwares/{bootloader.file} +upload.artifacts.sketch={build.path}/{build.project_name}.{upload.extension} + + # # OpenOCD # + tools.openocd.path={runtime.tools.openocd-0.12.0-arduino1-static.path} tools.openocd.cmd=bin/openocd tools.openocd.cmd.windows=bin/openocd.exe tools.openocd.upload.params.verbose=-d2 tools.openocd.upload.params.quiet=-d0 -tools.openocd.upload.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{runtime.platform.path}/firmwares/{bootloader.file}"" -c "set filename1 "{build.path}/{build.project_name}.{upload.extension}"" -c "set offset {upload.address}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" +tools.openocd.upload.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{upload.artifacts.loader}"" -c "set filename1 "{upload.artifacts.sketch}"" -c "set offset {upload.address}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" tools.openocd.program.params.verbose=-d2 tools.openocd.program.params.quiet=-d0 -tools.openocd.upload.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{runtime.platform.path}/firmwares/{bootloader.file}"" -c "set filename1 "{build.path}/{build.project_name}.{upload.extension}"" -c "set offset {upload.address}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" - -tools.openocd.erase.params.verbose=-d2 -tools.openocd.erase.params.quiet=-d0 -tools.openocd.erase.pattern= +tools.openocd.program.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{upload.artifacts.loader}"" -c "set filename1 "{upload.artifacts.sketch}"" -c "set offset {upload.address}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" tools.openocd.bootloader.params.verbose=-d2 tools.openocd.bootloader.params.quiet=-d0 -tools.openocd.bootloader.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{runtime.platform.path}/firmwares/{bootloader.file}"" -f "{build.variant.path}/flash_bootloader.cfg" "{upload.verbose}" +tools.openocd.bootloader.pattern="{path}/{cmd}" -s "{path}/share/openocd/scripts/" {upload.programmer} {upload.config} -c "set filename0 "{upload.artifacts.loader}"" -f "{build.variant.path}/flash_bootloader.cfg" "{upload.verbose}" + # # BOSSA # + tools.bossac.path={runtime.tools.bossac-1.9.1-arduino2.path} tools.bossac.cmd=bossac tools.bossac.cmd.windows=bossac.exe tools.bossac.upload.params.verbose=-d tools.bossac.upload.params.quiet= -tools.bossac.upload.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{build.path}/{build.project_name}.{upload.extension}" --offset {upload.address} -R +tools.bossac.upload.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.sketch}" --offset {upload.address} -R tools.bossac.bootloader.params.verbose=-d tools.bossac.bootloader.params.quiet= -tools.bossac.bootloader.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{runtime.platform.path}/firmwares/{bootloader.file}" --offset {bootloader.address} -R - -tools.bossac.erase.params.verbose= -tools.bossac.erase.params.quiet= -tools.bossac.erase.pattern= +tools.bossac.bootloader.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.loader}" --offset {bootloader.address} -R -# -# STM32FLASH -# -tools.stm32flash.cmd=stm32flash -tools.stm32flash.path={runtime.platform.path}/tools/windows -tools.stm32flash.path.macosx={runtime.platform.path}/tools/macosx -tools.stm32flash.path.linux={runtime.platform.path}/tools/linux -tools.stm32flash.upload.params.verbose=-v -tools.stm32flash.upload.params.quiet= -tools.stm32flash.upload.pattern="{path}/{cmd}" {serial.port} -e 1024 -b 2400 -w "{build.path}/{build.project_name}.bin" -tools.stm32flash.program.params.verbose=-v -tools.stm32flash.program.params.quiet= -tools.stm32flash.program.pattern="{path}/{cmd}" {serial.port} -e 1024 -b 2400 -w "{build.path}/{build.project_name}.bin" -tools.stm32flash.erase.params.verbose=-v -tools.stm32flash.erase.params.quiet= -tools.stm32flash.erase.pattern="{path}/{cmd}" {serial.port} -e 1024 -b 2400 # # DFU_UTIL @@ -234,32 +221,27 @@ tools.dfu-util.path={runtime.tools.dfu-util.path} tools.dfu-util.cmd=dfu-util tools.dfu-util.upload.params.verbose=-d tools.dfu-util.upload.params.quiet= -tools.dfu-util.upload.pattern="{path}/{cmd}" --device ,{upload.vid}:{upload.pid} -D "{build.path}/{build.project_name}.{upload.extension}" -a{upload.interface} {upload.dfuse} +tools.dfu-util.upload.pattern="{path}/{cmd}" --device ,{upload.vid}:{upload.pid} -D "{upload.artifacts.sketch}" -a{upload.interface} {upload.dfuse} tools.dfu-util.bootloader.params.verbose=-d tools.dfu-util.bootloader.params.quiet= -tools.dfu-util.bootloader.pattern="{path}/{cmd}" --device ,{bootloader.vid}:{bootloader.pid} -D "{runtime.platform.path}/firmwares/{bootloader.file}" -a{bootloader.interface} {bootloader.dfuse} +tools.dfu-util.bootloader.pattern="{path}/{cmd}" --device ,{bootloader.vid}:{bootloader.pid} -D "{upload.artifacts.loader}" -a{bootloader.interface} {bootloader.dfuse} -tools.dfu-util.erase.params.verbose= -tools.dfu-util.erase.params.quiet= -tools.dfu-util.erase.pattern= # # PICOTOOL # + tools.picotool.path={runtime.tools.rp2040tools.path} tools.picotool.cmd=rp2040load tools.picotool.upload.params.verbose=-v tools.picotool.upload.params.quiet= -tools.picotool.upload.pattern="{path}/{cmd}" {upload.verbose} -D "{build.path}/{build.project_name}" - -tools.picotool.erase.params.verbose= -tools.picotool.erase.params.quiet= -tools.picotool.erase.pattern= +tools.picotool.upload.pattern="{path}/{cmd}" {upload.verbose} -D "{upload.artifacts.sketch}" tools.picotool.bootloader.params.verbose=-v tools.picotool.bootloader.params.quiet= -tools.picotool.bootloader.pattern="{path}/{cmd}" {upload.verbose} -D "{runtime.platform.path}/firmwares/{bootloader.file}" +tools.picotool.bootloader.pattern="{path}/{cmd}" {upload.verbose} -D "{upload.artifacts.loader}" + # # IMGTOOL @@ -269,29 +251,20 @@ tools.imgtool.path={runtime.tools.imgtool.path} tools.imgtool.cmd=imgtool tools.imgtool.flags=sign --key "{build.keys.keychain}/{build.keys.sign_key}" --encrypt "{build.keys.keychain}/{build.keys.encrypt_key}" "{build.path}/{build.project_name}.bin" "{build.path}/{build.project_name}.bin" --align {build.alignment} --max-align {build.alignment} --version {build.version} --header-size {build.header_size} --pad-header --slot-size {build.slot_size} -# -# ADB WRAPPER -# - -tools.adb.path={runtime.tools.adb.path} -tools.adb.cmd=adb -tools.adb.upload.params.verbose=-v -tools.adb.upload.params.quiet= -tools.adb.upload.pattern="{path}/{cmd}" push "{build.path}/{build.project_name}.elf" "/tmp/arduino/m4-user-sketch.elf" # # REMOTEOCD # + tools.remoteocd.path={runtime.tools.remoteocd.path} tools.remoteocd.cmd=remoteocd tools.remoteocd.upload.params.verbose=--verbose tools.remoteocd.upload.params.quiet= -tools.remoteocd.upload.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{runtime.platform.path}/firmwares/{bootloader.file}" "{build.path}/{build.project_name}.{upload.extension}" +tools.remoteocd.upload.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{upload.artifacts.loader}" "{upload.artifacts.sketch}" tools.remoteocd.bootloader.params.verbose=--verbose tools.remoteocd.bootloader.params.quiet= -tools.remoteocd.erase.pattern= -tools.remoteocd.bootloader.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/flash_bootloader.cfg" "{upload.verbose}" "{runtime.platform.path}/firmwares/{bootloader.file}" +tools.remoteocd.bootloader.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/flash_bootloader.cfg" "{upload.verbose}" "{upload.artifacts.loader}" tools.remoteocd_network.upload.protocol=network tools.remoteocd_network.upload.field.password=Password @@ -300,7 +273,8 @@ tools.remoteocd_network.path={runtime.tools.remoteocd.path} tools.remoteocd_network.cmd=remoteocd tools.remoteocd_network.upload.params.verbose=--verbose tools.remoteocd_network.upload.params.quiet= -tools.remoteocd_network.upload.pattern="{path}/{cmd}" upload -a "{upload.port.address}" --password "{upload.field.password}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{runtime.platform.path}/firmwares/{bootloader.file}" "{build.path}/{build.project_name}.{upload.extension}" +tools.remoteocd_network.upload.pattern="{path}/{cmd}" upload -a "{upload.port.address}" --password "{upload.field.password}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{upload.artifacts.loader}" "{upload.artifacts.sketch}" + # # PYOCD WRAPPER @@ -312,15 +286,11 @@ tools.pyocd.path= tools.pyocd.cmd=pyocd tools.pyocd.upload.params.verbose= tools.pyocd.upload.params.quiet= -tools.pyocd.upload.pattern="{cmd}" load --target {upload.target} {build.path}/{build.project_name}.{upload.extension}@{upload.address} +tools.pyocd.upload.pattern="{cmd}" load --target {upload.target} {upload.artifacts.sketch}@{upload.address} tools.pyocd.bootloader.params.verbose= tools.pyocd.bootloader.params.quiet= -tools.pyocd.bootloader.pattern="{cmd}" load --target {bootloader.target} "{runtime.platform.path}/firmwares/{bootloader.file}" - -tools.pyocd.erase.params.verbose= -tools.pyocd.erase.params.quiet= -tools.pyocd.erase.pattern= +tools.pyocd.bootloader.pattern="{cmd}" load --target {bootloader.target} "{upload.artifacts.loader}" # From 5a85971d8e0d58838094c368def49041377ca77c Mon Sep 17 00:00:00 2001 From: Martino Facchin Date: Wed, 15 Jul 2026 12:38:19 +0200 Subject: [PATCH 014/162] boards: c33: update bootloader binary tracks https://github.com/arduino/arduino-renesas-bootloader/tree/zephyr_alt , allows consecutive uploads (loader+sketch) --- loader/blobs/c33_bl.bin | Bin 17724 -> 18435 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/loader/blobs/c33_bl.bin b/loader/blobs/c33_bl.bin index 40688c78d19ce05fbddbafabfddeb6e92fa9867b..f93f1a5658b3011776a3c6f60975081b88a46c4e 100755 GIT binary patch literal 18435 zcmeIaZCF!R)-b&HIr)SrfuMzedXfVz5YY%)Q9CszaQKJ{6+3O!X%9r(1K66X?WA90 z5N%7|+x~8qlPr>6ph74eLOui= zgt-tBlM$K&@k|J>F$j%;zFTAnU8Qg9=>JdtUxPsSfB0u^Nm#I7cwE@|M5c?*Z1Caf zD$g!!@~Nd&CzXqRv^a@A-Y>J!naZvtb&ZJWg4X6%ina6RHd@rs`bnkM(s={HT~>Sw znXUwAwl7F}L49GfivKoz{0N$ug(_ZESQp^OYIb1A14SD2s{rDU2%P zK=6nXG0~Vxvt6#%sr>3rlpgO>GYTfbW*Klp3-!&uXSUQ-$+#%)ac+~R{t}HgLinOe z|70Scz?D~R$#1So^1KFlH4x}S<~9@eeNb+1HYTD4~Mla;ZP`?X@_z|Rh)WuRsV7N)aotLRE846be2anVgp@qW_399=WtT@7AZr! zMVicPwWj+|w&HY+Z;O;>-Xf)&k%6iRtcD((TO^Yi&vC;q)HLI4H~fY}ABEd4X)WQ< zVQ7)5#bQ`C%|m5e43M@qz@>i$S?*krsze!=ATJZznk~o_@1qPfjIZ&WS=|;Cjb~tl zdKWGJ2VL)M3GS&w44MD$!r{*@}!DR=l8*SX_{rZ2dCFa(-7*~vRYpmW^e}OV+{I=t*gHcmOQhgVo7D~Vtpl^ ztuJ3viL;iJe+#XqXsbPo41v|ySRg!+i zY6LgFK;4+NM(WT|2it9u5kU#$t6DG@4xJwH^*{0|He%>yy~VDU74X>>iDlX@sVpie z@Ai?p#RIR~bS=1^7G#{>W%bk##-ecOUtw0LAJjprD_nHVZH%%vOBUKqZKw z4r$wPquzrX@oc=UFIYS<TJm5%4A*uk2e1ve56p+)2}+~R;-YZqtk0QGXcQZjFuu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ajyH^LgmL5?BXr0^tghBg(v z)sTfiKh%zNSNswVd~aZ`MqPYsO(nd9X;53SUE@%It`q4d5-)2j&Q@fkxQ2aR$n%Er zM8OFD`Gw<^>+~>=x5*&0ukFoStZrS~yLd5JBsa>frrs0Tra{4!;=0du-nGY-Qhi_b z%hjL4O$d2NeL{x_#(^6Wtnk{>X6CQIxI_XTzD^6*#FD|~W)*0p^9`1(7+&IEe|d@j zS1&Jt&dEF@@BTlAcmIwSvNLkqSGT#eZ}Q}S0Z@jBmq$|`_)b8%eiZ`mwoo8Hh-M~w z7>?W*)iACOaYt565%Fc~Hc!+sA~i3hMZy~*d3*IL;8j^n+9!gIClr_ia6$og90Hjq zYC@RIb;oN6=eAZ?Po1#MjeJHA!%zrEh9xE06l zX^FEI4F08{S-b=m?6=0-iR}|g$Xlyi*smJ#J9FXH(1xgDbMGH=z|YtPZ+ymk+XuZ} z43GG0!cSn02!2REMD|z?dPNcs!2v?zO>oGNxSt$06HzDzhi*7YBAjv^oJ&0bLyc77 s3{ruHK=k$G537(eDx8Y^WCARr&sRerx)G9lqpl-T>;L?h^iAOX57|%=-2eap From fc600c7db37603511194c6fa670e72844854f302 Mon Sep 17 00:00:00 2001 From: Martino Facchin Date: Wed, 15 Jul 2026 16:37:03 +0200 Subject: [PATCH 015/162] boards: c33: add feedback on bootloader reflash ok Switching to this core requires an updated bootloader. Since it will be flashed only if needed, the procedure is now: * Double click reset to enter bootloader mode * Burn bootloader * Wait until the blue led starts flashing * Double click reset to enter bootloader mode again * Upload sketch --- loader/fixups.c | 8 ++++++++ .../arduino_portenta_c33_r7fa6m5bh3cfc.conf | 2 ++ 2 files changed, 10 insertions(+) diff --git a/loader/fixups.c b/loader/fixups.c index 5903c20e7..a9335ae6f 100644 --- a/loader/fixups.c +++ b/loader/fixups.c @@ -6,6 +6,7 @@ #include #include +#include #ifndef CONFIG_CPP void __cxa_pure_virtual() { @@ -189,6 +190,13 @@ int maybe_flash_bootloader(void) { printk("Failed to write flash area, rc %d\n", rc); return rc; } + struct led_dt_spec ledb = LED_DT_SPEC_GET(DT_NODELABEL(led3)); + while (1) { + led_on_dt(&ledb); + k_msleep(100); + led_off_dt(&ledb); + k_msleep(100); + } } return 0; } diff --git a/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf b/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf index c8dd6b230..248bf700e 100644 --- a/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf +++ b/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf @@ -140,3 +140,5 @@ CONFIG_FS_FATFS_CUSTOM_MOUNT_POINT_COUNT=3 CONFIG_FS_FATFS_CUSTOM_MOUNT_POINTS="wlan,ota,SD" CONFIG_DYNAMIC_INTERRUPTS=n + +CONFIG_LED=y \ No newline at end of file From 0a8c83a877829ad3e132622ecfb3af054ac4e750 Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Wed, 8 Jul 2026 15:53:18 +0200 Subject: [PATCH 016/162] platform: automatic loader reflash for bossac USB boards For boards that have soft USB, use the new 'scripting-tools' tool to check the USB configuration string reported by the board. If it does not match the expected version, reflash the bootloader before uploading the sketch. Refactor loader and sketch commands so they can be reused in both the bootloader and upload patterns. Note that {loader.cmd} should leave the target waiting for the sketch upload, and additional arguments are passed to the loader command depending on whether the sketch will be flashed in the same session or not. Convert the bossac tool to use the new loader/sketch commands, and remove the old upload/bootloader patterns. --- platform.txt | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/platform.txt b/platform.txt index b066724ea..1ed43bb28 100644 --- a/platform.txt +++ b/platform.txt @@ -171,11 +171,23 @@ erase.pattern= upload.artifacts.loader={runtime.platform.path}/firmwares/{bootloader.file} upload.artifacts.sketch={build.path}/{build.project_name}.{upload.extension} +# Expects a {loader.cmd} and a {sketch.cmd} to be defined in the tool's +# section. The loader is flashed if it does not match the current (maybe +# board-specific) core version. The sketch is then flashed in any case. +# Extra arguments are passed to the loader command depending on whether +# the sketch will be flashed in the same session or not. +empty= +loader.args.with_sketch={empty} +loader.args.without_sketch={empty} +tools.patterns.flash-loader-and-sketch="{runtime.tools.scripting-tools.path}/scripting-tools" if not eq "v{upload.port.properties.configuration}" "v{version}" {loader.cmd}{loader.args.with_sketch} :: run {sketch.cmd} +tools.patterns.flash-loader-only={loader.cmd}{loader.args.without_sketch} # # OpenOCD # +# Special handling of loader and sketch via cfg file + tools.openocd.path={runtime.tools.openocd-0.12.0-arduino1-static.path} tools.openocd.cmd=bin/openocd tools.openocd.cmd.windows=bin/openocd.exe @@ -201,13 +213,17 @@ tools.bossac.path={runtime.tools.bossac-1.9.1-arduino2.path} tools.bossac.cmd=bossac tools.bossac.cmd.windows=bossac.exe +tools.bossac.sketch.cmd="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.sketch}" --offset {upload.address} -R +tools.bossac.loader.cmd="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.loader}" --offset {bootloader.address} +tools.bossac.loader.args.without_sketch={empty} -R + tools.bossac.upload.params.verbose=-d tools.bossac.upload.params.quiet= -tools.bossac.upload.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.sketch}" --offset {upload.address} -R +tools.bossac.upload.pattern={tools.patterns.flash-loader-and-sketch} tools.bossac.bootloader.params.verbose=-d tools.bossac.bootloader.params.quiet= -tools.bossac.bootloader.pattern="{path}/{cmd}" {upload.verbose} --port={serial.port.file} -U -i -e -w "{upload.artifacts.loader}" --offset {bootloader.address} -R +tools.bossac.bootloader.pattern={tools.patterns.flash-loader-only} # @@ -256,6 +272,8 @@ tools.imgtool.flags=sign --key "{build.keys.keychain}/{build.keys.sign_key}" --e # REMOTEOCD # +# Special handling of loader and sketch via upload command + tools.remoteocd.path={runtime.tools.remoteocd.path} tools.remoteocd.cmd=remoteocd tools.remoteocd.upload.params.verbose=--verbose From 85288b2d31be9de61cac634848f7c9418cb10de8 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Thu, 16 Jul 2026 13:18:36 +0200 Subject: [PATCH 017/162] platform: convert dfu-tool for automatic loader reflash --- boards.txt | 7 +++++-- platform.txt | 14 ++++++++++---- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/boards.txt b/boards.txt index e7b6325a1..01ca51242 100644 --- a/boards.txt +++ b/boards.txt @@ -484,14 +484,17 @@ portentac33.upload.interface=1 portentac33.upload.use_1200bps_touch=true portentac33.upload.wait_for_upload_port=false portentac33.upload.native_usb=true -portentac33.upload.dfuse=-Q -w +portentac33.upload.dfuse=-w portentac33.bootloader.tool=dfu-util portentac33.bootloader.tool.default=dfu-util portentac33.bootloader.file=zephyr-{build.variant}.bin portentac33.bootloader.interface=0 portentac33.bootloader.address=0x10000 -portentac33.bootloader.dfuse=-Q +portentac33.bootloader.dfuse= + +# the space before -Q is important +portentac33.leave.dfuse={empty} -Q ########################################################################################## diff --git a/platform.txt b/platform.txt index 1ed43bb28..ef7422cd6 100644 --- a/platform.txt +++ b/platform.txt @@ -230,18 +230,24 @@ tools.bossac.bootloader.pattern={tools.patterns.flash-loader-only} # DFU_UTIL # -upload.dfuse=--dfuse-address={upload.address}:leave -bootloader.dfuse=--dfuse-address={bootloader.address}:leave +# overridable by boards.txt +leave.dfuse=:leave +upload.dfuse=--dfuse-address={upload.address} +bootloader.dfuse=--dfuse-address={bootloader.address} tools.dfu-util.path={runtime.tools.dfu-util.path} tools.dfu-util.cmd=dfu-util +tools.dfu-util.sketch.cmd="{path}/{cmd}" --device ,{upload.vid}:{upload.pid} -D "{upload.artifacts.sketch}" -a{upload.interface} {upload.dfuse}{leave.dfuse} +tools.dfu-util.loader.cmd="{path}/{cmd}" --device ,{bootloader.vid}:{bootloader.pid} -D "{upload.artifacts.loader}" -a{bootloader.interface} {bootloader.dfuse} +tools.dfu-util.loader.args.without_sketch={leave.dfuse} + tools.dfu-util.upload.params.verbose=-d tools.dfu-util.upload.params.quiet= -tools.dfu-util.upload.pattern="{path}/{cmd}" --device ,{upload.vid}:{upload.pid} -D "{upload.artifacts.sketch}" -a{upload.interface} {upload.dfuse} +tools.dfu-util.upload.pattern={tools.patterns.flash-loader-and-sketch} tools.dfu-util.bootloader.params.verbose=-d tools.dfu-util.bootloader.params.quiet= -tools.dfu-util.bootloader.pattern="{path}/{cmd}" --device ,{bootloader.vid}:{bootloader.pid} -D "{upload.artifacts.loader}" -a{bootloader.interface} {bootloader.dfuse} +tools.dfu-util.bootloader.pattern={loader.cmd}{leave.dfuse} # From 2d1531147dd759cc068fd12513af62689de607c7 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Thu, 16 Jul 2026 13:20:40 +0200 Subject: [PATCH 018/162] platform: convert picotool for automatic loader reflash Requires a new version of rp2040tool that: - includes the option to skip the final RESET of the CPU - accepts .uf2 files without always adding the extension Add missing artifact with the new version. --- boards.txt | 5 +++-- extra/artifacts/_common.json | 5 +++++ platform.txt | 10 +++++++--- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/boards.txt b/boards.txt index 01ca51242..f8eedf220 100644 --- a/boards.txt +++ b/boards.txt @@ -692,7 +692,8 @@ nano_connect.compiler.zephyr.arch.define= nano_connect.build.float-abi=-mfloat-abi=soft nano_connect.build.extra_flags= nano_connect.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit -nano_connect.recipe.hooks.objcopy.postobjcopy.3.pattern="{runtime.tools.bin2uf2.path}/bin2uf2" {upload.address} {upload.familyid} "{build.path}/{build.project_name}.{upload.extension}" "{build.path}/{build.project_name}.uf2" +nano_connect.recipe.hooks.objcopy.postobjcopy.3.pattern="{runtime.tools.bin2uf2.path}/bin2uf2" {upload.address} {upload.familyid} "{build.path}/{build.project_name}.{upload.extension}" "{build.path}/{build.project_name}.{upload.extension}.uf2" +nano_connect.upload.artifacts.sketch={build.path}/{build.project_name}.{upload.extension}.uf2 nano_connect.build.board=NANO_RP2040_CONNECT nano_connect.compiler.zephyr= nano_connect.vid.0=0x2341 @@ -721,7 +722,7 @@ nano_connect.bootloader.tool.default=picotool nano_connect.bootloader.vid=0x2341 nano_connect.bootloader.pid=0x005E nano_connect.bootloader.interface=0 -nano_connect.bootloader.file=zephyr-{build.variant} +nano_connect.bootloader.file=zephyr-{build.variant}.uf2 nano_connect.debug.tool=gdb nano_connect.debug.server.openocd.scripts.0=interface/{programmer.protocol}.cfg diff --git a/extra/artifacts/_common.json b/extra/artifacts/_common.json index 4e4fa1cc2..fcaab910c 100644 --- a/extra/artifacts/_common.json +++ b/extra/artifacts/_common.json @@ -72,6 +72,11 @@ "packager": "arduino", "name": "scripting-tools", "version": "0.0.7" + }, + { + "packager": "arduino", + "name": "rp2040tools", + "version": "1.1.0-rc1" } ] } diff --git a/platform.txt b/platform.txt index ef7422cd6..a6bba27f2 100644 --- a/platform.txt +++ b/platform.txt @@ -247,22 +247,26 @@ tools.dfu-util.upload.pattern={tools.patterns.flash-loader-and-sketch} tools.dfu-util.bootloader.params.verbose=-d tools.dfu-util.bootloader.params.quiet= -tools.dfu-util.bootloader.pattern={loader.cmd}{leave.dfuse} +tools.dfu-util.bootloader.pattern={tools.patterns.flash-loader-only} # # PICOTOOL # +tools.picotool.sketch.cmd="{path}/{cmd}" {upload.verbose} -n -D "{upload.artifacts.sketch}" +tools.picotool.loader.cmd="{path}/{cmd}" {upload.verbose} -n -D "{upload.artifacts.loader}" +tools.picotool.loader.args.with_sketch={empty} -R + tools.picotool.path={runtime.tools.rp2040tools.path} tools.picotool.cmd=rp2040load tools.picotool.upload.params.verbose=-v tools.picotool.upload.params.quiet= -tools.picotool.upload.pattern="{path}/{cmd}" {upload.verbose} -D "{upload.artifacts.sketch}" +tools.picotool.upload.pattern={tools.patterns.flash-loader-and-sketch} tools.picotool.bootloader.params.verbose=-v tools.picotool.bootloader.params.quiet= -tools.picotool.bootloader.pattern="{path}/{cmd}" {upload.verbose} -D "{upload.artifacts.loader}" +tools.picotool.bootloader.pattern={tools.patterns.flash-loader-only} # From 4eb6af019e3b677d5475685d3ebdbd3e2047c7c8 Mon Sep 17 00:00:00 2001 From: pennam Date: Tue, 30 Jun 2026 10:47:39 +0200 Subject: [PATCH 019/162] boards.txt: remove dfu-specific data from boards not using it Bootloader VID/PID and upload/bootloader interfaces are not used if the upload tool is not DFU, so remove those extra fields. --- boards.txt | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/boards.txt b/boards.txt index f8eedf220..c7bfcb711 100644 --- a/boards.txt +++ b/boards.txt @@ -112,7 +112,6 @@ nano33ble.upload.protocol= nano33ble.upload.transport= nano33ble.upload.vid=0x2341 nano33ble.upload.pid=0x005a -nano33ble.upload.interface=0 nano33ble.upload.use_1200bps_touch=true nano33ble.upload.wait_for_upload_port=true nano33ble.upload.native_usb=true @@ -120,9 +119,6 @@ nano33ble.upload.offset=0x10000 # bootloader skips its own partition nano33ble.bootloader.tool=bossac nano33ble.bootloader.tool.default=bossac -nano33ble.bootloader.vid=0x2341 -nano33ble.bootloader.pid=0x035b -nano33ble.bootloader.interface=0 nano33ble.bootloader.file=zephyr-{build.variant}.bin nano33ble.bootloader.address=0x0000 @@ -171,7 +167,6 @@ ek_ra8d1.upload.protocol= ek_ra8d1.upload.transport= ek_ra8d1.upload.vid=0x2341 ek_ra8d1.upload.pid=0x0366 -ek_ra8d1.upload.interface=0 ek_ra8d1.upload.use_1200bps_touch=false ek_ra8d1.upload.wait_for_upload_port=false ek_ra8d1.upload.native_usb=true @@ -219,7 +214,6 @@ frdm_mcxn947.upload.protocol= frdm_mcxn947.upload.transport= frdm_mcxn947.upload.vid=0x1fc9 frdm_mcxn947.upload.pid=0x0143 -frdm_mcxn947.upload.interface=0 frdm_mcxn947.upload.use_1200bps_touch=false frdm_mcxn947.upload.wait_for_upload_port=false frdm_mcxn947.upload.native_usb=true @@ -378,7 +372,6 @@ frdm_rw612.upload.protocol= frdm_rw612.upload.transport= frdm_rw612.upload.vid=0x1fc9 frdm_rw612.upload.pid=0x0143 -frdm_rw612.upload.interface=0 frdm_rw612.upload.use_1200bps_touch=false frdm_rw612.upload.wait_for_upload_port=false frdm_rw612.upload.native_usb=true @@ -422,7 +415,6 @@ nicla_sense.upload.config=-f target/nrf52.cfg nicla_sense.upload.programmer=-f interface/cmsis-dap.cfg nicla_sense.upload.vid=0x2341 nicla_sense.upload.pid=0x0060 -nicla_sense.upload.interface=0 nicla_sense.upload.use_1200bps_touch=false nicla_sense.upload.wait_for_upload_port=false nicla_sense.upload.native_usb=false @@ -430,9 +422,6 @@ nicla_sense.upload.target=nrf52 nicla_sense.bootloader.tool=openocd nicla_sense.bootloader.tool.default=openocd -nicla_sense.bootloader.vid=0x2341 -nicla_sense.bootloader.pid=0x0360 -nicla_sense.bootloader.interface=0 nicla_sense.bootloader.file=zephyr-{build.variant}.hex nicla_sense.bootloader.target=nrf52 @@ -591,9 +580,6 @@ nano_matter.upload.native_usb=false nano_matter.bootloader.tool=openocd nano_matter.bootloader.tool.default=openocd -nano_matter.bootloader.vid=0x2341 -nano_matter.bootloader.pid=0x0072 -nano_matter.bootloader.interface=0 nano_matter.bootloader.file=zephyr-{build.variant}.hex nano_matter.bootloader.target=arduino_nano_matter @@ -653,7 +639,6 @@ unoq.upload.protocol= unoq.upload.transport= unoq.upload.vid=0x2341 unoq.upload.pid=0x0078 -unoq.upload.interface=0 unoq.upload.use_1200bps_touch=false unoq.upload.wait_for_upload_port=false unoq.upload.native_usb=true @@ -707,7 +692,6 @@ nano_connect.upload.protocol= nano_connect.upload.transport= nano_connect.upload.vid=0x2341 nano_connect.upload.pid=0x005E -nano_connect.upload.interface=0 nano_connect.upload.use_1200bps_touch=true nano_connect.upload.wait_for_upload_port=false nano_connect.upload.native_usb=true @@ -719,9 +703,6 @@ nano_connect.upload.familyid=0xe48bff56 nano_connect.bootloader.tool=picotool nano_connect.bootloader.tool.default=picotool -nano_connect.bootloader.vid=0x2341 -nano_connect.bootloader.pid=0x005E -nano_connect.bootloader.interface=0 nano_connect.bootloader.file=zephyr-{build.variant}.uf2 nano_connect.debug.tool=gdb From fbb58887878b0b90d79d4ce22ae6dab450d77f47 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Tue, 21 Jul 2026 14:42:53 +0200 Subject: [PATCH 020/162] boards.txt: fix invalid USB VID/PIDs - nicla_vision: 0x005b was copied from portenta H7 - portentac33: add bootloader USB information - ek_ra8d1: use VID/PID from Renesas bootloader mode - frdm_mcxn947, frdm_rw612: set open source VID/PIDs --- boards.txt | 12 +++++++----- .../frdm_mcxn947_mcxn947_cpu0.conf | 4 ++-- variants/frdm_rw612_rw612/frdm_rw612_rw612.conf | 4 ++-- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/boards.txt b/boards.txt index c7bfcb711..a2fc01708 100644 --- a/boards.txt +++ b/boards.txt @@ -156,10 +156,10 @@ ek_ra8d1.build.board=EK_RA8D1 #ek_ra8d1.recipe.hooks.objcopy.postobjcopy.4.pattern=cp {build.variant.path}/flasher.jlink "{build.path}/flasher.jlink" #ek_ra8d1.recipe.hooks.objcopy.postobjcopy.5.pattern=sed -i 's|SKETCH|"{build.path}/{build.project_name}.llext.dfu.bin"|g' "{build.path}/flasher.jlink" -ek_ra8d1.vid.0=0x2341 -ek_ra8d1.pid.0=0x0077 -ek_ra8d1.upload_port.0.vid=0x2341 -ek_ra8d1.upload_port.0.pid=0x0077 +ek_ra8d1.vid.0=0x045b +ek_ra8d1.pid.0=0x0261 +ek_ra8d1.upload_port.0.vid=0x045b +ek_ra8d1.upload_port.0.pid=0x0261 ek_ra8d1.upload.tool=pyocd ek_ra8d1.upload.tool.default=pyocd @@ -306,7 +306,7 @@ nicla_vision.build.extra_flags= nicla_vision.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nicla_vision.build.board=NICLA_VISION nicla_vision.vid.0=0x2341 -nicla_vision.pid.0=0x005b +nicla_vision.pid.0=0x005f nicla_vision.upload_port.0.vid=0x2341 nicla_vision.upload_port.0.pid=0x025f @@ -480,6 +480,8 @@ portentac33.bootloader.tool.default=dfu-util portentac33.bootloader.file=zephyr-{build.variant}.bin portentac33.bootloader.interface=0 portentac33.bootloader.address=0x10000 +portentac33.bootloader.vid=0x2341 +portentac33.bootloader.pid=0x0368 portentac33.bootloader.dfuse= # the space before -Q is important diff --git a/variants/frdm_mcxn947_mcxn947_cpu0/frdm_mcxn947_mcxn947_cpu0.conf b/variants/frdm_mcxn947_mcxn947_cpu0/frdm_mcxn947_mcxn947_cpu0.conf index 38bc10d5c..79f2ca64d 100644 --- a/variants/frdm_mcxn947_mcxn947_cpu0/frdm_mcxn947_mcxn947_cpu0.conf +++ b/variants/frdm_mcxn947_mcxn947_cpu0/frdm_mcxn947_mcxn947_cpu0.conf @@ -11,8 +11,8 @@ CONFIG_FLASH=y CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Freedom MCXN947" CONFIG_USB_DEVICE_MANUFACTURER="NXP" -CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x0078 +CONFIG_USB_DEVICE_VID=0x1209 +CONFIG_USB_DEVICE_PID=0x0001 CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n CONFIG_USB_CDC_ACM=y diff --git a/variants/frdm_rw612_rw612/frdm_rw612_rw612.conf b/variants/frdm_rw612_rw612/frdm_rw612_rw612.conf index ff70365bb..7f8171128 100644 --- a/variants/frdm_rw612_rw612/frdm_rw612_rw612.conf +++ b/variants/frdm_rw612_rw612/frdm_rw612_rw612.conf @@ -10,8 +10,8 @@ CONFIG_FLASH=y CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Freedom RW612" CONFIG_USB_DEVICE_MANUFACTURER="NXP" -CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x0079 +CONFIG_USB_DEVICE_VID=0x1209 +CONFIG_USB_DEVICE_PID=0x0002 CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n CONFIG_USB_CDC_ACM=y From acb8d8f62ab198329b1b115a44a3ff06160e9f16 Mon Sep 17 00:00:00 2001 From: pennam Date: Wed, 1 Jul 2026 07:14:10 +0200 Subject: [PATCH 021/162] boards: switch to zephyr pids --- boards.txt | 30 +++++++++---------- .../arduino_giga_r1_stm32h747xx_m7.conf | 2 +- .../arduino_nano_33_ble_nrf52840_sense.conf | 2 +- .../arduino_nano_connect_rp2040.conf | 2 +- .../arduino_nicla_vision_stm32h747xx_m7.conf | 2 +- .../arduino_opta_stm32h747xx_m7.conf | 2 +- .../arduino_portenta_c33_r7fa6m5bh3cfc.conf | 2 +- .../arduino_portenta_h7_stm32h747xx_m7.conf | 2 +- 8 files changed, 22 insertions(+), 22 deletions(-) diff --git a/boards.txt b/boards.txt index a2fc01708..3f22be315 100644 --- a/boards.txt +++ b/boards.txt @@ -46,9 +46,9 @@ giga.build.extra_flags= giga.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit giga.build.board=GIGA giga.vid.0=0x2341 -giga.pid.0=0x0066 +giga.pid.0=0x0666 giga.upload_port.0.vid=0x2341 -giga.upload_port.0.pid=0x0066 +giga.upload_port.0.pid=0x0666 giga.upload.tool=dfu-util giga.upload.tool.default=dfu-util @@ -102,9 +102,9 @@ nano33ble.build.extra_flags= nano33ble.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nano33ble.build.board=NANO33BLE nano33ble.vid.0=0x2341 -nano33ble.pid.0=0x035a +nano33ble.pid.0=0x065a nano33ble.upload_port.0.vid=0x2341 -nano33ble.upload_port.0.pid=0x005a +nano33ble.upload_port.0.pid=0x065a nano33ble.upload.tool=bossac nano33ble.upload.tool.default=bossac @@ -250,9 +250,9 @@ portentah7.build.extra_flags= portentah7.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit portentah7.build.board=PORTENTA_H7_M7 portentah7.vid.0=0x2341 -portentah7.pid.0=0x005b +portentah7.pid.0=0x065b portentah7.upload_port.0.vid=0x2341 -portentah7.upload_port.0.pid=0x035b +portentah7.upload_port.0.pid=0x065b portentah7.upload.tool=dfu-util portentah7.upload.tool.default=dfu-util @@ -306,9 +306,9 @@ nicla_vision.build.extra_flags= nicla_vision.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nicla_vision.build.board=NICLA_VISION nicla_vision.vid.0=0x2341 -nicla_vision.pid.0=0x005f +nicla_vision.pid.0=0x065f nicla_vision.upload_port.0.vid=0x2341 -nicla_vision.upload_port.0.pid=0x025f +nicla_vision.upload_port.0.pid=0x065f nicla_vision.upload.tool=dfu-util nicla_vision.upload.tool.default=dfu-util @@ -404,7 +404,7 @@ nicla_sense.build.extra_flags= nicla_sense.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nicla_sense.build.board=NICLA_SENSE_ME nicla_sense.vid.0=0x2341 -nicla_sense.pid.0=0x0360 +nicla_sense.pid.0=0x0060 nicla_sense.upload_port.0.vid=0x2341 nicla_sense.upload_port.0.pid=0x0060 @@ -458,9 +458,9 @@ portentac33.build.extra_flags= portentac33.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit portentac33.build.board=PORTENTA_C33 portentac33.vid.0=0x2341 -portentac33.pid.0=0x0068 +portentac33.pid.0=0x0668 portentac33.upload_port.0.vid=0x2341 -portentac33.upload_port.0.pid=0x0068 +portentac33.upload_port.0.pid=0x0668 portentac33.upload.target=portentac33 portentac33.upload.tool=dfu-util @@ -513,9 +513,9 @@ opta.build.extra_flags= opta.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit opta.build.board=OPTA opta.vid.0=0x2341 -opta.pid.0=0x0064 +opta.pid.0=0x0664 opta.upload_port.0.vid=0x2341 -opta.upload_port.0.pid=0x0364 +opta.upload_port.0.pid=0x0664 opta.upload.tool=dfu-util opta.upload.tool.default=dfu-util @@ -684,9 +684,9 @@ nano_connect.upload.artifacts.sketch={build.path}/{build.project_name}.{upload.e nano_connect.build.board=NANO_RP2040_CONNECT nano_connect.compiler.zephyr= nano_connect.vid.0=0x2341 -nano_connect.pid.0=0x005E +nano_connect.pid.0=0x065E nano_connect.upload_port.0.vid=0x2341 -nano_connect.upload_port.0.pid=0x005E +nano_connect.upload_port.0.pid=0x065E nano_connect.upload.tool=picotool nano_connect.upload.tool.default=picotool diff --git a/variants/arduino_giga_r1_stm32h747xx_m7/arduino_giga_r1_stm32h747xx_m7.conf b/variants/arduino_giga_r1_stm32h747xx_m7/arduino_giga_r1_stm32h747xx_m7.conf index 5b6b2a9c1..ad29fdbfd 100644 --- a/variants/arduino_giga_r1_stm32h747xx_m7/arduino_giga_r1_stm32h747xx_m7.conf +++ b/variants/arduino_giga_r1_stm32h747xx_m7/arduino_giga_r1_stm32h747xx_m7.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino GIGA R1" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x0066 +CONFIG_USB_DEVICE_PID=0x0666 CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n CONFIG_USB_CDC_ACM=y diff --git a/variants/arduino_nano_33_ble_nrf52840_sense/arduino_nano_33_ble_nrf52840_sense.conf b/variants/arduino_nano_33_ble_nrf52840_sense/arduino_nano_33_ble_nrf52840_sense.conf index e3d44fe6d..ba735aaf8 100644 --- a/variants/arduino_nano_33_ble_nrf52840_sense/arduino_nano_33_ble_nrf52840_sense.conf +++ b/variants/arduino_nano_33_ble_nrf52840_sense/arduino_nano_33_ble_nrf52840_sense.conf @@ -19,7 +19,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino Nano 33 BLE" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x035A +CONFIG_USB_DEVICE_PID=0x065A CONFIG_USB_CDC_ACM=y CONFIG_USB_CDC_ACM_RINGBUF_SIZE=1024 diff --git a/variants/arduino_nano_connect_rp2040/arduino_nano_connect_rp2040.conf b/variants/arduino_nano_connect_rp2040/arduino_nano_connect_rp2040.conf index e7b896244..6a6be4b44 100644 --- a/variants/arduino_nano_connect_rp2040/arduino_nano_connect_rp2040.conf +++ b/variants/arduino_nano_connect_rp2040/arduino_nano_connect_rp2040.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino Nano RP2040 Connect" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x005E +CONFIG_USB_DEVICE_PID=0x065E CONFIG_USB_CDC_ACM=y CONFIG_USB_CDC_ACM_RINGBUF_SIZE=1024 diff --git a/variants/arduino_nicla_vision_stm32h747xx_m7/arduino_nicla_vision_stm32h747xx_m7.conf b/variants/arduino_nicla_vision_stm32h747xx_m7/arduino_nicla_vision_stm32h747xx_m7.conf index c6f12a70d..969a130f0 100644 --- a/variants/arduino_nicla_vision_stm32h747xx_m7/arduino_nicla_vision_stm32h747xx_m7.conf +++ b/variants/arduino_nicla_vision_stm32h747xx_m7/arduino_nicla_vision_stm32h747xx_m7.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino Nicla Vision" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x005b +CONFIG_USB_DEVICE_PID=0x065f CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n CONFIG_USB_CDC_ACM=y diff --git a/variants/arduino_opta_stm32h747xx_m7/arduino_opta_stm32h747xx_m7.conf b/variants/arduino_opta_stm32h747xx_m7/arduino_opta_stm32h747xx_m7.conf index c7c37ae20..308807962 100644 --- a/variants/arduino_opta_stm32h747xx_m7/arduino_opta_stm32h747xx_m7.conf +++ b/variants/arduino_opta_stm32h747xx_m7/arduino_opta_stm32h747xx_m7.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino Opta" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x0064 +CONFIG_USB_DEVICE_PID=0x0664 CONFIG_USB_CDC_ACM=y CONFIG_USB_CDC_ACM_RINGBUF_SIZE=1024 diff --git a/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf b/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf index 248bf700e..5fdc92bbd 100644 --- a/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf +++ b/variants/arduino_portenta_c33_r7fa6m5bh3cfc/arduino_portenta_c33_r7fa6m5bh3cfc.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK_NEXT=y CONFIG_USB_DEVICE_PRODUCT="Arduino Portenta C33" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x0068 +CONFIG_USB_DEVICE_PID=0x0668 CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n #CONFIG_UPDATE_BOOTLOADER=y diff --git a/variants/arduino_portenta_h7_stm32h747xx_m7/arduino_portenta_h7_stm32h747xx_m7.conf b/variants/arduino_portenta_h7_stm32h747xx_m7/arduino_portenta_h7_stm32h747xx_m7.conf index 7cfb2b771..3d5faaaa9 100644 --- a/variants/arduino_portenta_h7_stm32h747xx_m7/arduino_portenta_h7_stm32h747xx_m7.conf +++ b/variants/arduino_portenta_h7_stm32h747xx_m7/arduino_portenta_h7_stm32h747xx_m7.conf @@ -5,7 +5,7 @@ CONFIG_USB_DEVICE_STACK=y CONFIG_USB_DEVICE_PRODUCT="Arduino Portenta H7" CONFIG_USB_DEVICE_MANUFACTURER="Arduino" CONFIG_USB_DEVICE_VID=0x2341 -CONFIG_USB_DEVICE_PID=0x005b +CONFIG_USB_DEVICE_PID=0x065b CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n CONFIG_USB_CDC_ACM=y From 3b298e6aeca6aad27721ec29b1ead358da5e77a9 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Tue, 21 Jul 2026 14:44:01 +0200 Subject: [PATCH 022/162] boards.txt: USB cleanup - Remove redundant legacy .vid/pid entries (in IDE 2.x they are used as a fallback for when the new .upload_port.0.vid/pid for pluggable discovery aren't defined). - To minimize the repetitions, define a set of default values in platform.txt that can be overridden by the boards: - {bootloader.vid/pid} is set to {upload_port.0.vid/pid}, for boards that do not switch to a different state after the connection - {upload.vid/pid} is set to {bootloader.vid/pid}, because that is the most common case where flashing is done by the bootloader. This requires boards to only provide the upload_port.0.vid/pid values, and optionally override the {bootloader.pid} values if it differs. - Remove entries that duplicate the above defaults. --- boards.txt | 55 ---------------------------------------------------- platform.txt | 6 ++++++ 2 files changed, 6 insertions(+), 55 deletions(-) diff --git a/boards.txt b/boards.txt index 3f22be315..dbd16123a 100644 --- a/boards.txt +++ b/boards.txt @@ -45,8 +45,6 @@ giga.build.artifact=zephyr_main giga.build.extra_flags= giga.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit giga.build.board=GIGA -giga.vid.0=0x2341 -giga.pid.0=0x0666 giga.upload_port.0.vid=0x2341 giga.upload_port.0.pid=0x0666 @@ -54,8 +52,6 @@ giga.upload.tool=dfu-util giga.upload.tool.default=dfu-util giga.upload.protocol= giga.upload.transport= -giga.upload.vid=0x2341 -giga.upload.pid=0x0366 giga.upload.interface=0 giga.upload.use_1200bps_touch=true giga.upload.wait_for_upload_port=true @@ -63,7 +59,6 @@ giga.upload.native_usb=true giga.bootloader.tool=dfu-util giga.bootloader.tool.default=dfu-util -giga.bootloader.vid=0x2341 giga.bootloader.pid=0x0366 giga.bootloader.interface=0 giga.bootloader.file=zephyr-{build.variant}.bin @@ -101,8 +96,6 @@ nano33ble.build.variant=arduino_nano_33_ble_nrf52840_sense nano33ble.build.extra_flags= nano33ble.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nano33ble.build.board=NANO33BLE -nano33ble.vid.0=0x2341 -nano33ble.pid.0=0x065a nano33ble.upload_port.0.vid=0x2341 nano33ble.upload_port.0.pid=0x065a @@ -110,8 +103,6 @@ nano33ble.upload.tool=bossac nano33ble.upload.tool.default=bossac nano33ble.upload.protocol= nano33ble.upload.transport= -nano33ble.upload.vid=0x2341 -nano33ble.upload.pid=0x005a nano33ble.upload.use_1200bps_touch=true nano33ble.upload.wait_for_upload_port=true nano33ble.upload.native_usb=true @@ -156,8 +147,6 @@ ek_ra8d1.build.board=EK_RA8D1 #ek_ra8d1.recipe.hooks.objcopy.postobjcopy.4.pattern=cp {build.variant.path}/flasher.jlink "{build.path}/flasher.jlink" #ek_ra8d1.recipe.hooks.objcopy.postobjcopy.5.pattern=sed -i 's|SKETCH|"{build.path}/{build.project_name}.llext.dfu.bin"|g' "{build.path}/flasher.jlink" -ek_ra8d1.vid.0=0x045b -ek_ra8d1.pid.0=0x0261 ek_ra8d1.upload_port.0.vid=0x045b ek_ra8d1.upload_port.0.pid=0x0261 @@ -165,8 +154,6 @@ ek_ra8d1.upload.tool=pyocd ek_ra8d1.upload.tool.default=pyocd ek_ra8d1.upload.protocol= ek_ra8d1.upload.transport= -ek_ra8d1.upload.vid=0x2341 -ek_ra8d1.upload.pid=0x0366 ek_ra8d1.upload.use_1200bps_touch=false ek_ra8d1.upload.wait_for_upload_port=false ek_ra8d1.upload.native_usb=true @@ -202,8 +189,6 @@ frdm_mcxn947.build.variant=frdm_mcxn947_mcxn947_cpu0 frdm_mcxn947.build.extra_flags= frdm_mcxn947.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit frdm_mcxn947.build.board=FRDM_MCXN947 -frdm_mcxn947.vid.0=0x1fc9 -frdm_mcxn947.pid.0=0x0143 frdm_mcxn947.upload_port.0.vid=0x1fc9 frdm_mcxn947.upload_port.0.pid=0x0143 frdm_mcxn947.upload.target=mcxn947vdf @@ -212,8 +197,6 @@ frdm_mcxn947.upload.tool=pyocd frdm_mcxn947.upload.tool.default=pyocd frdm_mcxn947.upload.protocol= frdm_mcxn947.upload.transport= -frdm_mcxn947.upload.vid=0x1fc9 -frdm_mcxn947.upload.pid=0x0143 frdm_mcxn947.upload.use_1200bps_touch=false frdm_mcxn947.upload.wait_for_upload_port=false frdm_mcxn947.upload.native_usb=true @@ -249,8 +232,6 @@ portentah7.build.variant=arduino_portenta_h7_stm32h747xx_m7 portentah7.build.extra_flags= portentah7.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit portentah7.build.board=PORTENTA_H7_M7 -portentah7.vid.0=0x2341 -portentah7.pid.0=0x065b portentah7.upload_port.0.vid=0x2341 portentah7.upload_port.0.pid=0x065b @@ -258,8 +239,6 @@ portentah7.upload.tool=dfu-util portentah7.upload.tool.default=dfu-util portentah7.upload.protocol= portentah7.upload.transport= -portentah7.upload.vid=0x2341 -portentah7.upload.pid=0x035b portentah7.upload.interface=0 portentah7.upload.use_1200bps_touch=true portentah7.upload.wait_for_upload_port=true @@ -267,7 +246,6 @@ portentah7.upload.native_usb=true portentah7.bootloader.tool=dfu-util portentah7.bootloader.tool.default=dfu-util -portentah7.bootloader.vid=0x2341 portentah7.bootloader.pid=0x035b portentah7.bootloader.interface=0 portentah7.bootloader.file=zephyr-{build.variant}.bin @@ -305,8 +283,6 @@ nicla_vision.build.variant=arduino_nicla_vision_stm32h747xx_m7 nicla_vision.build.extra_flags= nicla_vision.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nicla_vision.build.board=NICLA_VISION -nicla_vision.vid.0=0x2341 -nicla_vision.pid.0=0x065f nicla_vision.upload_port.0.vid=0x2341 nicla_vision.upload_port.0.pid=0x065f @@ -314,8 +290,6 @@ nicla_vision.upload.tool=dfu-util nicla_vision.upload.tool.default=dfu-util nicla_vision.upload.protocol= nicla_vision.upload.transport= -nicla_vision.upload.vid=0x2341 -nicla_vision.upload.pid=0x035f nicla_vision.upload.interface=0 nicla_vision.upload.use_1200bps_touch=true nicla_vision.upload.wait_for_upload_port=true @@ -323,7 +297,6 @@ nicla_vision.upload.native_usb=true nicla_vision.bootloader.tool=dfu-util nicla_vision.bootloader.tool.default=dfu-util -nicla_vision.bootloader.vid=0x2341 nicla_vision.bootloader.pid=0x035f nicla_vision.bootloader.interface=0 nicla_vision.bootloader.file=zephyr-{build.variant}.bin @@ -360,8 +333,6 @@ frdm_rw612.build.variant=frdm_rw612_rw612 frdm_rw612.build.extra_flags= frdm_rw612.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit frdm_rw612.build.board=FRDM_RW612 -frdm_rw612.vid.0=0x1fc9 -frdm_rw612.pid.0=0x0143 frdm_rw612.upload_port.0.vid=0x1fc9 frdm_rw612.upload_port.0.pid=0x0143 frdm_rw612.upload.target=rw612 @@ -370,8 +341,6 @@ frdm_rw612.upload.tool=pyocd frdm_rw612.upload.tool.default=pyocd frdm_rw612.upload.protocol= frdm_rw612.upload.transport= -frdm_rw612.upload.vid=0x1fc9 -frdm_rw612.upload.pid=0x0143 frdm_rw612.upload.use_1200bps_touch=false frdm_rw612.upload.wait_for_upload_port=false frdm_rw612.upload.native_usb=true @@ -403,8 +372,6 @@ nicla_sense.openocd_cfg=flash_sketch.cfg nicla_sense.build.extra_flags= nicla_sense.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nicla_sense.build.board=NICLA_SENSE_ME -nicla_sense.vid.0=0x2341 -nicla_sense.pid.0=0x0060 nicla_sense.upload_port.0.vid=0x2341 nicla_sense.upload_port.0.pid=0x0060 @@ -413,8 +380,6 @@ nicla_sense.upload.tool.default=openocd nicla_sense.upload.protocol= nicla_sense.upload.config=-f target/nrf52.cfg nicla_sense.upload.programmer=-f interface/cmsis-dap.cfg -nicla_sense.upload.vid=0x2341 -nicla_sense.upload.pid=0x0060 nicla_sense.upload.use_1200bps_touch=false nicla_sense.upload.wait_for_upload_port=false nicla_sense.upload.native_usb=false @@ -457,8 +422,6 @@ portentac33.build.variant=arduino_portenta_c33_r7fa6m5bh3cfc portentac33.build.extra_flags= portentac33.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit portentac33.build.board=PORTENTA_C33 -portentac33.vid.0=0x2341 -portentac33.pid.0=0x0668 portentac33.upload_port.0.vid=0x2341 portentac33.upload_port.0.pid=0x0668 portentac33.upload.target=portentac33 @@ -467,8 +430,6 @@ portentac33.upload.tool=dfu-util portentac33.upload.tool.default=dfu-util portentac33.upload.protocol= portentac33.upload.transport= -portentac33.upload.vid=0x2341 -portentac33.upload.pid=0x0368 portentac33.upload.interface=1 portentac33.upload.use_1200bps_touch=true portentac33.upload.wait_for_upload_port=false @@ -480,7 +441,6 @@ portentac33.bootloader.tool.default=dfu-util portentac33.bootloader.file=zephyr-{build.variant}.bin portentac33.bootloader.interface=0 portentac33.bootloader.address=0x10000 -portentac33.bootloader.vid=0x2341 portentac33.bootloader.pid=0x0368 portentac33.bootloader.dfuse= @@ -512,8 +472,6 @@ opta.build.variant=arduino_opta_stm32h747xx_m7 opta.build.extra_flags= opta.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit opta.build.board=OPTA -opta.vid.0=0x2341 -opta.pid.0=0x0664 opta.upload_port.0.vid=0x2341 opta.upload_port.0.pid=0x0664 @@ -521,8 +479,6 @@ opta.upload.tool=dfu-util opta.upload.tool.default=dfu-util opta.upload.protocol= opta.upload.transport= -opta.upload.vid=0x2341 -opta.upload.pid=0x0364 opta.upload.interface=0 opta.upload.use_1200bps_touch=true opta.upload.wait_for_upload_port=true @@ -530,7 +486,6 @@ opta.upload.native_usb=true opta.bootloader.tool=dfu-util opta.bootloader.tool.default=dfu-util -opta.bootloader.vid=0x2341 opta.bootloader.pid=0x0364 opta.bootloader.interface=0 opta.bootloader.file=zephyr-{build.variant}.bin @@ -565,8 +520,6 @@ nano_matter.openocd_cfg=flash_sketch.cfg nano_matter.build.extra_flags= nano_matter.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit nano_matter.build.board=ARDUINO_NANO_MATTER -nano_matter.vid.0=0x2341 -nano_matter.pid.0=0x0072 nano_matter.upload_port.0.vid=0x2341 nano_matter.upload_port.0.pid=0x0072 @@ -628,8 +581,6 @@ unoq.build.postbuild.cmd="{tools.imgtool.path}/{tools.imgtool.cmd}" exit unoq.build.board=UNO_Q unoq.build.zephyr_hals=hal_stm32 unoq.build.zephyr_toolchain=arm-zephyr-eabi -unoq.vid.0=0x2341 -unoq.pid.0=0x0078 unoq.upload_port.0.vid=0x2341 unoq.upload_port.0.pid=0x0078 unoq.upload.target=stm32u585zitxq @@ -639,8 +590,6 @@ unoq.upload.tool.default=remoteocd unoq.upload.tool.network=remoteocd_network unoq.upload.protocol= unoq.upload.transport= -unoq.upload.vid=0x2341 -unoq.upload.pid=0x0078 unoq.upload.use_1200bps_touch=false unoq.upload.wait_for_upload_port=false unoq.upload.native_usb=true @@ -683,8 +632,6 @@ nano_connect.recipe.hooks.objcopy.postobjcopy.3.pattern="{runtime.tools.bin2uf2. nano_connect.upload.artifacts.sketch={build.path}/{build.project_name}.{upload.extension}.uf2 nano_connect.build.board=NANO_RP2040_CONNECT nano_connect.compiler.zephyr= -nano_connect.vid.0=0x2341 -nano_connect.pid.0=0x065E nano_connect.upload_port.0.vid=0x2341 nano_connect.upload_port.0.pid=0x065E @@ -692,8 +639,6 @@ nano_connect.upload.tool=picotool nano_connect.upload.tool.default=picotool nano_connect.upload.protocol= nano_connect.upload.transport= -nano_connect.upload.vid=0x2341 -nano_connect.upload.pid=0x005E nano_connect.upload.use_1200bps_touch=true nano_connect.upload.wait_for_upload_port=false nano_connect.upload.native_usb=true diff --git a/platform.txt b/platform.txt index a6bba27f2..cc86ecf20 100644 --- a/platform.txt +++ b/platform.txt @@ -164,6 +164,12 @@ pluggable_monitor.required.serial=builtin:serial-monitor # Uploader tools # -------------- +# Shared defaults for all boards, unless overridden in boards.txt +bootloader.vid={upload_port.0.vid} +bootloader.pid={upload_port.0.pid} +upload.vid={bootloader.vid} +upload.pid={bootloader.pid} + # No erase command is needed for Zephyr targets erase.pattern= From f8cdd082646b980d0de58402770f8809d1fe88c7 Mon Sep 17 00:00:00 2001 From: pennam Date: Thu, 23 Jul 2026 15:10:27 +0200 Subject: [PATCH 023/162] loader: enable heap-based dynamic thread stacks Enable CONFIG_DYNAMIC_THREAD (+ its required CONFIG_THREAD_STACK_INFO dependency) with CONFIG_DYNAMIC_THREAD_ALLOC=y and no static pool, so runtime thread stacks (k_thread_stack_alloc) are allocated from the system heap (CONFIG_HEAP_MEM_POOL_SIZE) rather than a fixed build-time pool. --- loader/prj.conf | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/loader/prj.conf b/loader/prj.conf index ce28c9433..8a5d87a21 100644 --- a/loader/prj.conf +++ b/loader/prj.conf @@ -45,6 +45,10 @@ CONFIG_MAIN_THREAD_PRIORITY=14 CONFIG_EVENTS=y +CONFIG_THREAD_STACK_INFO=y +CONFIG_DYNAMIC_THREAD=y +CONFIG_DYNAMIC_THREAD_ALLOC=y + CONFIG_RTC=y CONFIG_RTC_ALARM=y CONFIG_RTC_UPDATE=y From 179f1191f10e3e42d66d5d946ede25d86801e66c Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Wed, 22 Jul 2026 14:14:03 +0200 Subject: [PATCH 024/162] README.md: cleanup and update for stable releases Freshen up the README to reflect the current state of the project and remove outdated information. Updated instructions for installation, first use, and troubleshooting. Added acknowledgments for contributors. --- README.md | 55 +++++++++++++++++++++++++++---------------------------- 1 file changed, 27 insertions(+), 28 deletions(-) diff --git a/README.md b/README.md index e8ab1b0a5..8ee150d65 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,9 @@ > [!IMPORTANT] -> This core is in **BETA**. 🧪 -> Features may change, and bugs may be present. Use for testing only and provide feedback to help us improve. +> This core is approaching a stable 1.0 release. Now is the time to test it and report any issues you find — your feedback helps us iron out the remaining bugs! > -> [![Default branch status](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml/badge.svg?branch=arduino&event=push)](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml) +> [![Default branch status](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml/badge.svg?branch=main&event=push)](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml) -# 🚧 Arduino Core for Zephyr +# 🪁 Arduino Core for Zephyr This repository is a downstream fork of the [Arduino Core for Zephyr RTOS-based boards](https://github.com/zephyrproject-rtos/arduino-core-zephyr) that @@ -13,6 +12,11 @@ by the [Arduino IDE](https://docs.arduino.cc/software/ide/), [Arduino CLI](https://docs.arduino.cc/arduino-cli/) and [Arduino App Lab](https://docs.arduino.cc/software/app-lab/). +This core is designed to replace the [mbed OS-based Arduino +Core](https://github.com/arduino/ArduinoCore-mbed) on all the devices it +supported, and to provide a more modern and flexible foundation for current and +future Arduino boards by allowing the use of Zephyr RTOS features and APIs. + ## 🧐 What is Zephyr? [Zephyr RTOS](https://zephyrproject.org/) is an open-source, real-time operating system designed for low-power, resource-constrained devices. It's modular, scalable, and supports multiple architectures. @@ -25,25 +29,31 @@ Install the core and its toolchains via Board Manager: * Download and install the latest [Arduino IDE](https://www.arduino.cc/en/software) (only versions `2.x.x` are supported). * Open the *'Settings / Preferences'* window. * Open the *'Boards Manager'* from the side menu and search for *'Zephyr'*. - * If it doesn’t appear, add the following URL to the *'Additional Boards Manager URLs'* field: `https://downloads.arduino.cc/packages/package_zephyr_index.json` (if you have multiple URLs, separate them with a comma). -* Install the `Arduino Zephyr Boards` platform. +* Install the *'Arduino Zephyr Boards'* platform (or the *'Arduino Uno Q Board'* platform if you have an Arduino UNO Q). -Alternatively, to install the core using the command line, run the following command with the Arduino CLI: +## 🏗️ First Use -```bash -arduino-cli core install arduino:zephyr --additional-urls https://downloads.arduino.cc/packages/package_zephyr_index.json -``` +The first time you use a Zephyr board, the *Zephyr loader* must be installed on +the board. Since release 0.90.0 this procedure is fully automated and the +loader will be installed automatically when you upload your first sketch. -## 🏗️ First Use +[!NOTE] +> The Arduino Portenta C33 needs a full bootloader update to work with the +> Zephyr core. For this board, the update *must be performed manually* the +> first time. Follow the instructions in this post to properly update the +> bootloader on your Portenta C33. + +To manually force a loader update, follow these steps: -To get started with your board: * Put the board in bootloader mode by double-clicking the RESET button. * Run the `Burn Bootloader` option from the IDE/CLI. * Note that due to limitations in the Arduino IDE, you may need to select any programmer from the `Programmers` menu. * Once the bootloader is installed, you can load your first sketch by placing the board into bootloader mode again. > [!NOTE] -> After the initial setup, future sketches will be loaded automatically without needing to reset the board. +> After the initial setup, future sketches will be loaded automatically without +> needing to reset the board. Each sketch update will also reflash the loader +> if a different version is detected. ## 🔧 Troubleshooting @@ -65,7 +75,7 @@ To get started with your board: --- #### **Q: I get an OS crash, like ` os: ***** USAGE FAULT *****`** -**A:** This is usually due to a buffer overflow or coding error in the user's own code. However, since the project is still in beta 🧪, a [good bug report](#-bug-reporting) could help identify any issues in our code. +**A:** This is usually due to a buffer overflow or coding error in the user's own code. However, a [good bug report](#-bug-reporting) could help identify any issues in the loader or Zephyr itself. --- @@ -134,13 +144,6 @@ The most important components of this project are: ## 🛠️ Setup a Zephyr build environment -> [!WARNING] -> If you checked out this repo before 0.3.2 was released, please note that -> development has switched to the `main` branch; the old `arduino` branch will -> be removed in the short future. Please follow this -> [migration guide](https://github.com/arduino/ArduinoCore-zephyr/issues/163) -> to update your local branches and outstanding PRs. - In this section, we’ll guide you through setting up your environment to work on and update the Zephyr core. Shell scripts are available to simplify the installation process (Windows is not directly supported at the moment 😔, but there are some tricks - see below). @@ -317,7 +320,7 @@ mv ~/Arduino/hardware/arduino/zephyr ~/Arduino/hardware/arduino/zephyr.disable > ```bash > . venv/bin/activate > west config -d manifest.project-filter -> west sdk install --version 0.17.0 +> west sdk install > west update > ``` @@ -349,18 +352,14 @@ To report a bug, open the [issues](/../../issues) and follow the instructions. A Contributions are always welcome. The preferred way to receive code contribution is by submitting a [Pull request](/../../pulls). -> [!WARNING] -> At this stage of development, we only accept Pull requests for bug fixes and features. We do **not** accept support for new targets. - ## 📌 Upcoming features - [ ] USB: switch to `USB_DEVICE_STACK_NEXT` to support PluggableUSB -- [x] Relocate RODATA in flash to accommodate sketches with large assets - [ ] Provide better error reporting for failed llext operations - [ ] Replace [`llext_exports.c`](/loader/llext_exports.c) with proper symbols generation (via includes) -- [ ] Fix corner cases with `std::` includes (like ``) - [ ] Get rid of all warnings ## 🌟 Acknowledgments -This effort would have been very hard without the [GSoC project](/README.gsoc.md) and the Zephyr community. +This effort would have been very hard without the [GSoC project](/README.gsoc.md), the Zephyr community and all the contributors to this repo. +Thanks to everyone who has contributed to this project! From bf74a5662f9cef6afc0c33c6c66235f493edc617 Mon Sep 17 00:00:00 2001 From: pennam Date: Fri, 24 Jul 2026 15:01:53 +0200 Subject: [PATCH 025/162] json: remove BETA label --- extra/artifacts/zephyr_contrib.json | 2 +- extra/artifacts/zephyr_main.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/extra/artifacts/zephyr_contrib.json b/extra/artifacts/zephyr_contrib.json index b2fa095dd..58fb1bc85 100644 --- a/extra/artifacts/zephyr_contrib.json +++ b/extra/artifacts/zephyr_contrib.json @@ -1,5 +1,5 @@ { - "name": "Zephyr Community Boards (BETA)", + "name": "Zephyr Community Boards", "architecture": "zephyr_contrib", "category": "Contributed" } diff --git a/extra/artifacts/zephyr_main.json b/extra/artifacts/zephyr_main.json index b36cef34b..6c15f125c 100644 --- a/extra/artifacts/zephyr_main.json +++ b/extra/artifacts/zephyr_main.json @@ -1,5 +1,5 @@ { - "name": "Arduino Zephyr Boards (BETA)", + "name": "Arduino Zephyr Boards", "architecture": "zephyr_main", "category": "Arduino" } From b57ba26bea9207ef728ec3d5270e3beb51b13c5f Mon Sep 17 00:00:00 2001 From: pennam Date: Fri, 24 Jul 2026 15:48:47 +0200 Subject: [PATCH 026/162] platform: remove BETA label --- platform.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/platform.txt b/platform.txt index cc86ecf20..97aad00d8 100644 --- a/platform.txt +++ b/platform.txt @@ -1,9 +1,9 @@ -# Arduino Zephyr (BETA) Core and platform. +# Arduino Zephyr Core and platform. # # For more info: # https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification -name=Arduino Zephyr Boards (BETA) +name=Arduino Zephyr Boards version=9.9.9 # Compile variables From 86b8b8b59268bc1f558640e639fdf10f0c402f3b Mon Sep 17 00:00:00 2001 From: pennam Date: Fri, 24 Jul 2026 15:54:39 +0200 Subject: [PATCH 027/162] docs: README phrasing tweak --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8ee150d65..8bc68ad74 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ > [!IMPORTANT] -> This core is approaching a stable 1.0 release. Now is the time to test it and report any issues you find — your feedback helps us iron out the remaining bugs! +> This core is approaching a 1.0 release. Now is the time to use it and report any issues you find — your feedback helps us iron out the remaining bugs! > > [![Default branch status](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml/badge.svg?branch=main&event=push)](https://github.com/arduino/ArduinoCore-zephyr/actions/workflows/package_core.yml) From 297b93ffb4063b598e354c2392c362516df41557 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Mon, 27 Jul 2026 10:27:51 +0200 Subject: [PATCH 028/162] README: add link to Help Center article Now that the page is up, link to it from the README to make it easier for users to find the instructions. --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8bc68ad74..9ed4e1774 100644 --- a/README.md +++ b/README.md @@ -40,8 +40,9 @@ loader will be installed automatically when you upload your first sketch. [!NOTE] > The Arduino Portenta C33 needs a full bootloader update to work with the > Zephyr core. For this board, the update *must be performed manually* the -> first time. Follow the instructions in this post to properly update the -> bootloader on your Portenta C33. +> first time. Make sure to follow the instructions in [this Help Center +> article](https://support.arduino.cc/hc/en-us/articles/29180434600476-Install-the-Zephyr-loader-on-your-board) +> to properly update the bootloader on your Portenta C33. To manually force a loader update, follow these steps: From 2e77eabaa12fc9f2d416afa471e354366058993f Mon Sep 17 00:00:00 2001 From: Tedd OKANO Date: Tue, 28 Jul 2026 05:26:05 +0900 Subject: [PATCH 029/162] loader: exports: add missing float (32-bit) AEABI helpers double arithmetic/comparisons/conversions are fully exported for llext sketches, but float was only partially covered (fcmple/fcmpun and int64<->float only), missing float add/sub/mul/div entirely and int32<->float conversions. Using plain `float` arithmetic in a sketch therefore failed to link with undefined reference errors. Add the missing __aeabi_fadd/fsub/fmul/fdiv, the remaining float comparison helpers (fcmpeq/fcmplt/fcmpgt/fcmpge), and int32<->float conversions (i2f/ui2f/f2iz/f2uiz), mirroring the existing double support in both llext_exports.c (loader-side export) and llext_wrappers.c (naked trampoline, matching pattern from the double helpers added in b32825c1). --- cores/arduino/llext_wrappers.c | 13 +++++++++++++ loader/llext_exports.c | 13 +++++++++++++ 2 files changed, 26 insertions(+) diff --git a/cores/arduino/llext_wrappers.c b/cores/arduino/llext_wrappers.c index 8a307ead6..a1d8982ca 100644 --- a/cores/arduino/llext_wrappers.c +++ b/cores/arduino/llext_wrappers.c @@ -195,8 +195,17 @@ VN(__aeabi_dcmple) VN(__aeabi_dcmpgt) VN(__aeabi_dcmpge) VN(__aeabi_dcmpun) +/* float arithmetic */ +VN(__aeabi_fadd) +VN(__aeabi_fsub) +VN(__aeabi_fmul) +VN(__aeabi_fdiv) /* float comparisons */ +VN(__aeabi_fcmpeq) +VN(__aeabi_fcmplt) VN(__aeabi_fcmple) +VN(__aeabi_fcmpgt) +VN(__aeabi_fcmpge) VN(__aeabi_fcmpun) /* double <-> integer conversions */ VN(__aeabi_d2iz) @@ -209,6 +218,10 @@ VN(__aeabi_ul2d) /* float <-> double / integer conversions */ VN(__aeabi_d2f) VN(__aeabi_f2d) +VN(__aeabi_i2f) +VN(__aeabi_ui2f) +VN(__aeabi_f2iz) +VN(__aeabi_f2uiz) VN(__aeabi_l2f) VN(__aeabi_ul2f) /* integer division */ diff --git a/loader/llext_exports.c b/loader/llext_exports.c index d9fe04ecc..7803abeb0 100644 --- a/loader/llext_exports.c +++ b/loader/llext_exports.c @@ -360,8 +360,17 @@ EXPORT_AEABI_SYM(__aeabi_dcmple); EXPORT_AEABI_SYM(__aeabi_dcmpgt); EXPORT_AEABI_SYM(__aeabi_dcmpge); EXPORT_AEABI_SYM(__aeabi_dcmpun); +/* float arithmetic */ +EXPORT_AEABI_SYM(__aeabi_fadd); +EXPORT_AEABI_SYM(__aeabi_fsub); +EXPORT_AEABI_SYM(__aeabi_fmul); +EXPORT_AEABI_SYM(__aeabi_fdiv); /* float comparisons */ +EXPORT_AEABI_SYM(__aeabi_fcmpeq); +EXPORT_AEABI_SYM(__aeabi_fcmplt); EXPORT_AEABI_SYM(__aeabi_fcmple); +EXPORT_AEABI_SYM(__aeabi_fcmpgt); +EXPORT_AEABI_SYM(__aeabi_fcmpge); EXPORT_AEABI_SYM(__aeabi_fcmpun); /* double <-> integer conversions */ EXPORT_AEABI_SYM(__aeabi_d2iz); @@ -374,6 +383,10 @@ EXPORT_AEABI_SYM(__aeabi_ul2d); /* float <-> double / integer conversions */ EXPORT_AEABI_SYM(__aeabi_d2f); EXPORT_AEABI_SYM(__aeabi_f2d); +EXPORT_AEABI_SYM(__aeabi_i2f); +EXPORT_AEABI_SYM(__aeabi_ui2f); +EXPORT_AEABI_SYM(__aeabi_f2iz); +EXPORT_AEABI_SYM(__aeabi_f2uiz); EXPORT_AEABI_SYM(__aeabi_l2f); EXPORT_AEABI_SYM(__aeabi_ul2f); /* integer division */ From 16fb4f5d43bdd57e702189d49947feaef28c8a0d Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Thu, 25 Jun 2026 17:48:57 +0200 Subject: [PATCH 030/162] ci: fix: use base_ref to get the target branch CORE_BRANCH is supposed to be the branch that triggered the workflow, not the branch with the PR changes (that one is not accessible from the ci-builds repo). When a PR is merged, the workflow is triggered on the target branch, so we should use base_ref instead of head_ref to get the correct branch also at PR time. --- .github/workflows/package_core.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/package_core.yml b/.github/workflows/package_core.yml index 4c64c8b37..fde330121 100644 --- a/.github/workflows/package_core.yml +++ b/.github/workflows/package_core.yml @@ -88,7 +88,7 @@ jobs: [[ -n "$BRANCH" ]] || { echo "::error::No branch found containing tag ${{ github.ref_name }}"; exit 1; } echo "CORE_BRANCH=${BRANCH}" >> "$GITHUB_ENV" else - echo "CORE_BRANCH=${{ github.head_ref || github.ref_name }}" >> "$GITHUB_ENV" + echo "CORE_BRANCH=${{ github.base_ref || github.ref_name }}" >> "$GITHUB_ENV" fi echo "ALL_BOARD_FQBNS=$(jq -c 'map((. + {link_mode: "static"}), (. + {link_mode: "dynamic"}))' <<< ${ALL_BOARD_DATA})" >> "$GITHUB_ENV" echo "ARTIFACTS=$(jq -c '["zephyr"] + (map(.artifact) | unique)' <<< ${ALL_BOARD_DATA})" >> "$GITHUB_ENV" From 8dd8171b04fc67ea2fb75a6941216a1d6f6d9d5f Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Fri, 26 Jun 2026 10:17:17 +0200 Subject: [PATCH 031/162] ci: refact: export build environment variables early Prepare the build environment variables early in the workflow so that the lengthy Zephyr install process takes place after the variables are set up. This allows for easier quick inspection of the build state and better organization of the workflow. --- .github/workflows/package_core.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/package_core.yml b/.github/workflows/package_core.yml index fde330121..ab621bba5 100644 --- a/.github/workflows/package_core.yml +++ b/.github/workflows/package_core.yml @@ -69,10 +69,8 @@ jobs: persist-credentials: false fetch-tags: true # needed for get_core_version.sh - - name: Initialize Zephyr environment + - name: Identify current version and board set run: | - # Install Zephyr as a core user would, but faster - yes | ./extra/bootstrap.sh -o=--filter=tree:0 # Set up basic environment for later steps echo "CORE_HASH=$(git describe --always $HEAD_REF)" >> "$GITHUB_ENV" echo "ALL_BOARD_DATA=$(extra/get_board_details.sh | jq -c 'sort_by(.variant)')" >> "$GITHUB_ENV" @@ -93,6 +91,11 @@ jobs: echo "ALL_BOARD_FQBNS=$(jq -c 'map((. + {link_mode: "static"}), (. + {link_mode: "dynamic"}))' <<< ${ALL_BOARD_DATA})" >> "$GITHUB_ENV" echo "ARTIFACTS=$(jq -c '["zephyr"] + (map(.artifact) | unique)' <<< ${ALL_BOARD_DATA})" >> "$GITHUB_ENV" echo "SUB_ARCHES=$(jq -c 'map(.subarch) | unique' <<< ${ALL_BOARD_DATA})" >> "$GITHUB_ENV" + + - name: Initialize Zephyr environment + run: | + # Install Zephyr as a core user would, but faster + yes | ./extra/bootstrap.sh -o=--filter=tree:0 # Archive the build environment for later jobs (cd && tar cphf - .cmake work zephyr-sdk-* | zstd > build-env.tar.zstd) # The API is only needed for packaging, not for building, so it's separate From a01712d1d010ec280343345c8f8830f65f6cc01b Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Thu, 25 Jun 2026 15:27:31 +0200 Subject: [PATCH 032/162] ci: use latest ci-builds JSON as a reference On pull requests and pushes to the official ArduinoCore-zephyr repo, use the latest ci-builds JSON as a reference for building the core, if available. This allows to install the current set of tools required by the branch sources, instead of using those from the latest release. If the ci-builds JSON is not available for the current branch, the branch that is closest to the current one will be used instead, with a warning. --- .github/workflows/package_core.yml | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/.github/workflows/package_core.yml b/.github/workflows/package_core.yml index ab621bba5..70a1dab17 100644 --- a/.github/workflows/package_core.yml +++ b/.github/workflows/package_core.yml @@ -53,6 +53,8 @@ jobs: ARTIFACTS: ${{ env.ARTIFACTS }} # List of architectures the artifacts will be built for SUB_ARCHES: ${{ env.SUB_ARCHES }} + # URL of the latest ci-builds index for this branch, if any + CI_BUILDS_URL: ${{ env.CI_BUILDS_URL }} steps: - name: Install OS dependencies @@ -101,6 +103,25 @@ jobs: # The API is only needed for packaging, not for building, so it's separate tar cphf - cores/arduino/api | zstd > arduino-api.tar.zstd + - name: Get ci-builds package index link + if: ${{ github.repository == 'arduino/ArduinoCore-zephyr' }} + run: | + # for pull requests and pushes to the official Arduino repo, use the latest ci-built core as a reference + CI_BUILDS_URL="https://arduino.github.io/core-ci-builds/package_arduino_zephyr_${CORE_BRANCH}_ci_index.json" + if ! wget -q --method=HEAD "$CI_BUILDS_URL" >& /dev/null ; then + CLOSEST_BRANCH=$(git branch -r | grep -vE "HEAD|/$(git branch --show-current)$" | while read -r b; do \ + echo "$(git rev-list --count $b..HEAD) $b" ; \ + done | sort -n | head -n 1 | awk '{print $2}' | cut -d / -f 2) + [ -z "$CLOSEST_BRANCH" ] && CLOSEST_BRANCH="main" + echo "::warning::No ci-builds index found for branch $CORE_BRANCH, using $CLOSEST_BRANCH" + CI_BUILDS_URL="https://arduino.github.io/core-ci-builds/package_arduino_zephyr_${CLOSEST_BRANCH}_ci_index.json" + if ! wget -q --method=HEAD "$CI_BUILDS_URL" >& /dev/null ; then + echo "::warning::No ci-builds index found for branch $CLOSEST_BRANCH, using main" + CI_BUILDS_URL="https://arduino.github.io/core-ci-builds/package_arduino_zephyr_main_ci_index.json" + fi + fi + echo "CI_BUILDS_URL=$CI_BUILDS_URL" >> "$GITHUB_ENV" + - name: Download test data run: | extra/ci_fetch_tests.sh @@ -353,6 +374,7 @@ jobs: FQBN: arduino:${{ matrix.subarch }}:${{ matrix.board }}:link_mode=${{ matrix.link_mode }} CORE_ARTIFACT: ArduinoCore-${{ matrix.artifact }}-${{ needs.build-env.outputs.CORE_HASH }}.tar.bz2 ARTIFACT_TAG: ${{ needs.build-env.outputs.CORE_HASH }}-${{ matrix.board }}-${{ matrix.link_mode }} + CI_BUILDS_URL: ${{ needs.build-env.outputs.CI_BUILDS_URL }} if: ${{ !cancelled() && needs.build-env.result == 'success' }} steps: @@ -389,7 +411,8 @@ jobs: - name: Compile tests for ${{ matrix.board }} uses: pillo79/compile-sketches@next with: - fqbn: ${{ env.FQBN }} + # Use ci-builds core, if possible, to use the exact set of tools required by the source + fqbn: ${{ env.FQBN }} ${{ env.CI_BUILDS_URL }} platforms: | # Use Board Manager version first to install the tools - name: ${{ env.PLAT }} From 1c104b6feecd7699a7767a896558c1c5044f21a2 Mon Sep 17 00:00:00 2001 From: Luca Burelli Date: Mon, 13 Jul 2026 16:45:34 +0200 Subject: [PATCH 033/162] get_core_version: add date-time to PR version codes Replace the current count-from-tag value with a timestap in the PR build version string to ensure it is always monotonically increasing. This way, builds can be reliably sorted and the newest is always selected. The number of commits since the last tag is now only appended when a proper branch push is detected. --- extra/get_core_version.sh | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/extra/get_core_version.sh b/extra/get_core_version.sh index 5c2b2e913..ab24abaaf 100755 --- a/extra/get_core_version.sh +++ b/extra/get_core_version.sh @@ -15,7 +15,7 @@ # # A bash regex extracts the components and produces: # -# ..-0.