Repository navigation
Conversation
Built
|
| Artifact | Board | Core | Tests | RAM | Sketches | Warnings | Errors |
|---|---|---|---|---|---|---|---|
✅ zephyr_contrib |
ek_ra8d1
| 2 🏷️ | ✅ |
12.0% |
2 | - | - |
frdm_mcxn947
| 7 🏷️ | ✅ |
53.4% |
2 | - | - | |
frdm_rw612
| 3 🏷️ | ✅ |
74.6% |
2 | - | - | |
✅* zephyr_main |
giga
| 10 🏷️ | ✅* |
45.9% |
86 | 2 | - |
nano33ble
| 5 🏷️ | ✅ |
79.2% |
44 | - | - | |
nano_connect
| 6 🏷️ | ✅* |
69.5% |
38 | 8 | - | |
nano_matter
| 3 🏷️ | ✅ |
|
22 | - | - | |
nicla_sense
| 3 🏷️ | ✅ |
|
18 | - | - | |
nicla_vision
| 11 🏷️ | ✅ |
40.4% |
68 | - | - | |
opta
| 11 🏷️ | ✅ |
42.3% |
76 | - | - | |
portentac33
| 6 🏷️ | ✅ |
|
72 | - | - | |
portentah7
| 10 🏷️ | ✅* |
51.2% |
102 | 2 | - | |
✅ zephyr_unoq |
unoq
| 2 🏷️ | ✅ |
43.5% |
56 | - | - |
ventunoq
| 5 🏷️ | ✅ |
23.7% |
48 | - | - |
Legend
Board Test Status description 🔥 🔥 Test run failed to complete. ❌ 🔴 Test completed with unexpected errors. ⁉️ ⁉️ Test was expected to fail but passed; exception entry is outdated. ✔️* 🚫 Test completed with errors, but all are known/expected. ✅* 🟡 Test completed with some warnings; no errors detected. ✅ 🟢 Test passed successfully, with no warnings or errors. 🌑 🌑 Test was skipped.
pennam
requested changes
Oct 21, 2026
pennam
left a comment
There was a problem hiding this comment.
Hi @KurtE, thanks for the contribution!
In addition to your changes, could we also remove the WIRE_HOWMANY definition in the nano_connect variant and add a fallback to arduino_i2c? This would keep it consistent with the approach used in Wire.cpp
diff --git a/libraries/Wire/Wire.h b/libraries/Wire/Wire.h
index 49ca362..ac8c331 100644
--- a/libraries/Wire/Wire.h
+++ b/libraries/Wire/Wire.h
@@ -93,4 +93,13 @@ DT_FOREACH_PROP_ELEM(DT_PATH(zephyr_user), i2cs, DECLARE_EXTERN_WIRE_N)
extern arduino::ZephyrI2C Wire;
#endif
+/* Number of Wire instances, matching the instantiation logic in Wire.cpp */
+#if DT_NODE_HAS_PROP(DT_PATH(zephyr_user), i2cs)
+#define WIRE_HOWMANY DT_PROP_LEN(DT_PATH(zephyr_user), i2cs)
+#elif DT_NODE_EXISTS(DT_NODELABEL(arduino_i2c))
+#define WIRE_HOWMANY 1
+#else
+#define WIRE_HOWMANY 0
+#endif
+
typedef arduino::ZephyrI2C TwoWire;
diff --git a/variants/arduino_nano_connect_rp2040/variant.h b/variants/arduino_nano_connect_rp2040/variant.h
index 66281ed..fd1614e 100644
--- a/variants/arduino_nano_connect_rp2040/variant.h
+++ b/variants/arduino_nano_connect_rp2040/variant.h
@@ -97,8 +97,6 @@ static const uint8_t SCK = PIN_SPI_SCK;
// Wire (I2C)
// ----------
-#define WIRE_HOWMANY (1)
-
#define PIN_WIRE_SDA (18u)
#define PIN_WIRE_SCL (19u)
There are times when a sketch wants to know how many Wire objects there are. Example wire scanner app. In the MBED wire library this was defined as WIRE_HOWMANY So simply defined it from DT_NODE_HAS_PROP(DT_PATH(zephyr_user), i2cs)
Author
|
Pushed up the changes... |
Built
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Artifact | Board | Core | Tests | RAM | Sketches | Warnings | Errors | |
|---|---|---|---|---|---|---|---|---|
🔥 zephyr_contrib |
ek_ra8d1
| 🔥 | Core build failed! | |||||
frdm_mcxn947
| 7 🏷️ | ✅ |
53.4% |
2 | - | - | ||
frdm_rw612
| 8 🏷️ | ✅ |
73.4% |
2 | - | - | ||
🔥 zephyr_main |
giga
| 🔥 | Core build failed! | |||||
nano33ble
| 5 🏷️ | ✅ |
79.2% |
44 | - | - | ||
nano_connect
| 6 🏷️ | ✅ |
69.5% |
38 | - | - | ||
nano_matter
| 🔥 | Core build failed! | ||||||
nicla_sense
| 3 🏷️ | ✅ |
|
18 | - | - | ||
nicla_vision
| 🔥 | Core build failed! | ||||||
opta
| 11 🏷️ | ✅ |
42.3% |
76 | - | - | ||
portentac33
| 6 🏷️ | ✅ |
|
72 | - | - | ||
portentah7
| 10 🏷️ | ✅* |
51.2% |
100 | 2 | - | ||
🔥 zephyr_unoq |
unoq
| 🔥 | Core build failed! | |||||
ventunoq
| 🔥 | Core build failed! | ||||||
Legend
Board Test Status description 🔥 🔥 Test run failed to complete. ❌ 🔴 Test completed with unexpected errors. ⁉️ ⁉️ Test was expected to fail but passed; exception entry is outdated. ✔️* 🚫 Test completed with errors, but all are known/expected. ✅* 🟡 Test completed with some warnings; no errors detected. ✅ 🟢 Test passed successfully, with no warnings or errors. 🌑 🌑 Test was skipped.
Caution
zephyr_contrib is blocked due to failures on ek_ra8d1!
Caution
zephyr_main is blocked due to failures on giga, nano_matter, nicla_vision!
Caution
zephyr_unoq is blocked due to failures on unoq, ventunoq!
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
There are times when a sketch wants to know how many Wire objects there are. Example wire scanner app.
In the MBED wire library this was defined as WIRE_HOWMANY
So simply defined it from DT_NODE_HAS_PROP(DT_PATH(zephyr_user), i2cs)
Here is an example sketch, that can make use of it. Note: I put more or less the same zephyr stuff in it, such
that it does it on it's own.
zephyr_wire_scanner-261020a.zip