From b53937239f18f708ab20dd927458d80a8b4ce39a Mon Sep 17 00:00:00 2001 From: Jilay Pandya Date: Thu, 3 Apr 2025 21:29:17 +0200 Subject: [PATCH] doc: stepper: add information about stepper test suite Add brief information about how stepper api test suites could be used Signed-off-by: Jilay Pandya --- doc/hardware/peripherals/stepper.rst | 39 ++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/doc/hardware/peripherals/stepper.rst b/doc/hardware/peripherals/stepper.rst index cd5bc6635f7..16d103421dd 100644 --- a/doc/hardware/peripherals/stepper.rst +++ b/doc/hardware/peripherals/stepper.rst @@ -48,6 +48,45 @@ is open to all. .. _stepper-api-reference: +Stepper API Test Suite +====================== + +The stepper API test suite provides a set of tests that can be used to verify the functionality of +stepper drivers. + +.. zephyr-app-commands:: + :zephyr-app: tests/drivers/stepper/stepper_api + :board: + :west-args: --extra-dtc-overlay + :goals: build flash + +Sample Output +============= + +Below is a snippet of the test output for the tmc50xx stepper driver. Since +:c:func:`stepper_set_microstep_interval` is not implemented by the driver the corresponding tests +have been skipped. + +.. code-block:: console + + =================================================================== + TESTSUITE stepper succeeded + + ------ TESTSUITE SUMMARY START ------ + + SUITE PASS - 100.00% [stepper]: pass = 4, fail = 0, skip = 2, total = 6 duration = 0.069 seconds + - PASS - [stepper.test_actual_position] duration = 0.016 seconds + - PASS - [stepper.test_get_micro_step_res] duration = 0.013 seconds + - SKIP - [stepper.test_set_micro_step_interval_invalid_zero] duration = 0.007 seconds + - PASS - [stepper.test_set_micro_step_res_incorrect] duration = 0.010 seconds + - PASS - [stepper.test_stop] duration = 0.016 seconds + - SKIP - [stepper.test_target_position_w_fixed_step_interval] duration = 0.007 seconds + + ------ TESTSUITE SUMMARY END ------ + + =================================================================== + PROJECT EXECUTION SUCCESSFUL + API Reference *************