Draft
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds hardware-focused TCP/IP stress testing and generated packet/order validation examples, plus host-side automation scripts and documentation, to make the template project a more complete hardware validation base.
Changes:
- Introduces
ExampleTCPIP(firmware) and a host-side Python stress harness with quality-gate/soak runners. - Introduces
ExamplePackets(firmware) and a host-side checker driven by the active JSON packet schema. - Adds
tools/build-example.sh, expands docs, and gitignores generated packet headers.
Reviewed changes
Copilot reviewed 29 out of 30 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/run_example_tcpip_stress.sh | Wrapper to run the TCP/IP stress harness from repo root. |
| tools/run_example_tcpip_nucleo.sh | End-to-end build/flash/ping/gate runner for Nucleo Ethernet. |
| tools/example_tcpip_stress.py | Host-side TCP/UDP stress + validation harness for ExampleTCPIP. |
| tools/example_tcpip_soak_hours.sh | Multi-hour soak wrapper with pass-ratio summary. |
| tools/example_tcpip_soak.sh | Repeated stress-run soak engine with per-run logs. |
| tools/example_tcpip_quality_gate.sh | Strict base/aggressive run matrix and log capture. |
| tools/example_packets_check.py | Host-side schema-driven TCP/UDP parsing validator for ExamplePackets. |
| tools/build-example.sh | Helper to build named examples and select TEST_* variants. |
| docs/template-project/testing.md | Adds pointers to TCP/IP stress + packet validation flows. |
| docs/template-project/tcpip-change-manual.md | Deep-dive manual describing TCP/IP robustness changes and tooling. |
| docs/template-project/example-tcpip.md | Detailed guide for building/running/validating ExampleTCPIP. |
| docs/template-project/build-debug.md | Documents generated packet headers as build artifacts. |
| docs/examples/example-tcpip.md | Quick per-example guide for ExampleTCPIP. |
| docs/examples/example-packets.md | Quick per-example guide for ExamplePackets + schema dependency notes. |
| docs/examples/example-mpu.md | Adds/updates MPU example guide content. |
| docs/examples/example-linear-sensor-characterization.md | Documents schema incompatibility and how to restore/build the example. |
| docs/examples/example-hardfault.md | Adds hardfault example guide content. |
| docs/examples/example-exti.md | Adds EXTI example guide content. |
| docs/examples/example-ethernet.md | Adds Ethernet bring-up example guide content. |
| docs/examples/example-adc.md | Adds ADC example guide content. |
| docs/examples/README.md | New index and workflow notes for all examples. |
| deps/ST-LIB | Updates ST-LIB submodule to include TCP/IP robustness changes. |
| README.md | Adds links to per-example docs and notes about generated headers. |
| Core/Src/main.cpp | Switches default main guard to EXAMPLE_SELECTED. |
| Core/Src/Examples/ExampleTCPIP.cpp | Adds ExampleTCPIP firmware stress/telemetry example. |
| Core/Src/Examples/ExamplePackets.cpp | Adds ExamplePackets firmware schema-validation example. |
| Core/Inc/Code_generation/Packet_generation/Packet_descriptions.py | Extends numeric type correction for signed/unsigned ints. |
| Core/Inc/Code_generation/JSON_ADE | Updates JSON_ADE submodule to match new packet example/schema. |
| CMakeLists.txt | Changes default BOARD_NAME, tracks generator deps, and provides EXAMPLE_SELECTED. |
| .gitignore | Stops tracking generated packet headers as source. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
TCP/IP and Packet Validation Examples
Summary
This PR adds hardware-focused validation flows to the template project for both socket robustness and generated packet parsing.
ExampleTCPIP, a full Ethernet stress example covering TCP server/client, UDP traffic, reconnect behavior, bursts, and health telemetry.ExamplePackets, a generated packet/order validation example built onOrderPacketsandDataPackets.tools/build-example.shto simplify building examples and selecting namedTEST_*variants.DataPackets.hpp,OrderPackets.hpp) and documents them as build artifacts.Impact
This makes the template project much more usable as a hardware validation base: examples are easier to build, Ethernet behavior is easier to stress automatically, and generated packet parsing can be verified end-to-end against the active schema.
Validation
Validated with a Nucleo Development Board using repeated TCP/UDP stress runs, packet parsing checks, reconnect scenarios, and long-duration soak workflows (yes, thanks to Chatty to create those scripts)
Notes
Yes, I also made the fix of the fix of the fix of the fix of the fix of the fix of the fix of the fix "a puntito de caramelo" "ahora si que si chicos" "esta va confiar" "esta es la definitva" "3.0" @Cantonplas
The Packet generator is now parsing properly the int types, not only de uints