Test harness; improved driver API; bugfixing - #109
Open
ivmarkov wants to merge 51 commits into
Open
Conversation
…sk drivers to report their sensitivity floor
…cified, explicit sleep/receive APIs
ivmarkov
force-pushed
the
test-harness
branch
4 times, most recently
from
August 13, 2026 13:54
a22c19f to
47f9e4e
Compare
ivmarkov
force-pushed
the
test-harness
branch
2 times, most recently
from
August 14, 2026 07:18
12b954c to
3c11414
Compare
ivmarkov
marked this pull request as ready for review
August 14, 2026 18:56
Collaborator
Author
|
@bjoernQ This is ready now. |
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.
This (large) PR introduces the capability to run the upstream OpenThread functional (Python), timing (Python) and expect (TCL dsl) end-to-end tests on binaries built with the
openthreadcrate.The benefit of running these end-to-end tests on top of
openthread-derived binaries is that this way we can properly test the twoopenthreadaspects which are not just a trivial "safe Rust API for C OpenThread":openthread(theotPlat*functions) that revolves around the async Radio trait, the async alarms (embassy-time) and so on.Radiodriver implementation which is compiled in theopenthread-derived binary.The tests can run in the following mode of operation:
SimRadioinopenthread/tests; it goes over UDP);VtRadioinopenthread/tests)SpinelRadioand a realot_rcphardware dongle. This is a HIL test but it does NOT test ourRadiodrivers, as the Spinel radio instead works with the standardot_rcpESP-IDF or NRF52 firmware flashed on the controller which is used as a USB dongle; this setup however DOES test the Spinel radio driver itself, of course, which is just as importantEspRadioorNrfRadioand then flashed withespflashorprobe-rsUPDATE: or any other, like the nrf-802154 as long as it has a compliantcli_nodetest driver binary; DOES test the actual radio. Needs a manual step for flashingIn terms of changes:
openthread/testsThe majority. A brand new sub-project tree, whose purpose is to contain
openthread-derived binaries which can be driven with OT CLI commands over a serial protocol.Similar to
rs-matter/tests.openthread/xtaskExtended with an
itestsub-module and corresponding command line args, which is the way to invoke the E2E tests.Similar to
rs-matter/xtask. Check.github/itest/ymlfor more infoopenthreadThe crate DID see some changes and bugfixes as a result of running the tests. In particular:
Safe wrappers for the OpenThread CLI API
openthread-derived binaries now have a small type-safe API for supporting a "console".Necessary, or else our binaries cannot be commanded by the E2E tests what to do, which goes via the OT CLI.
Over what protocol the console goes is platform specific of course and up to the user to wire;
openthread/tests/espuses USB-serial. The Spinel radios - as they run on the host itself - just use their stdin/out.radio.rsmodule cleanupThis is the most obtrusive change, sorry. The
radio.rsmodule was already sitting at 2K+ lines and after some additions / bugfixes crossed the 3K line. It is now split into sub-modules.Support for rssi /
otPlatRadioGetRssiWe now report the last RSSI/LQI received by the last incoming frame
Support for
otPlatRadio*SrcMatchThese platform callbacks allow OpenThread to tell the 802.15.4 driver which children have data (which determines the setting/clearing of the pending bit as per esp-rs/esp-hal#6090