33Steppers
44########
55
6- The stepper driver API provides a set of functions for controlling and configuring stepper drivers.
6+ The stepper driver subsystem consists of two device driver APIs:
77
8- Configure Stepper Driver
9- ========================
8+ Stepper-DRV API
9+ ***************
10+
11+ The stepper driver API provides a common interface for stepper drivers.
12+
13+ - Configure **micro-stepping resolution ** using :c:func: `stepper_drv_set_micro_step_res `
14+ and :c:func: `stepper_drv_get_micro_step_res `.
15+ - **Enable ** the stepper driver using :c:func: `stepper_drv_enable `.
16+ - **Disable ** the stepper driver using :c:func: `stepper_drv_disable `.
17+ - Register an **event callback ** using :c:func: `stepper_drv_set_event_cb `.
18+
19+ Stepper API
20+ ***********
21+
22+ The stepper API provides a common interface for stepper controllers.
1023
11- - Configure **micro-stepping resolution ** using :c:func: `stepper_set_micro_step_res `
12- and :c:func: `stepper_get_micro_step_res `.
1324- Configure **reference position ** in microsteps using :c:func: `stepper_set_reference_position `
1425 and :c:func: `stepper_get_actual_position `.
1526- Set **step interval ** in nanoseconds between steps using :c:func: `stepper_set_microstep_interval `
16- - **Enable ** the stepper driver using :c:func: `stepper_enable `.
17- - **Disable ** the stepper driver using :c:func: `stepper_disable `.
18-
19- Control Stepper
20- ===============
21-
2227- **Move by ** +/- micro-steps also known as **relative movement ** using :c:func: `stepper_move_by `.
2328- **Move to ** a specific position also known as **absolute movement ** using :c:func: `stepper_move_to `.
2429- Run continuously with a **constant step interval ** in a specific direction until
@@ -27,30 +32,30 @@ Control Stepper
2732- Check if the stepper is **moving ** using :c:func: `stepper_is_moving `.
2833- Register an **event callback ** using :c:func: `stepper_set_event_callback `.
2934
35+ .. _stepper-device-tree :
36+
3037Device Tree
31- ===========
38+ ***********
3239
3340In the context of stepper controllers device tree provides the initial hardware
3441configuration for stepper drivers on a per device level. Each device must specify
3542a device tree binding in Zephyr, and ideally, a set of hardware configuration options
3643for things such as current settings, ramp parameters and furthermore. These can then
3744be used in a boards devicetree to configure a stepper driver to its initial state.
3845
39- See examples in:
46+ Driver Composition Scenarios
47+ ============================
4048
41- - :dtcompatible: `zephyr,h-bridge-stepper `
42- - :dtcompatible: `adi,tmc50xx `
49+ Below are two typical scenarios:
4350
44- Discord
45- =======
51+ .. toctree ::
52+ :maxdepth: 1
4653
47- Zephyr has a `stepper discord `_ channel for stepper related discussions, which
48- is open to all.
49-
50- .. _stepper-api-reference :
54+ integrated_controller_driver.rst
55+ individual_controller_driver.rst
5156
5257Stepper API Test Suite
53- ======================
58+ **********************
5459
5560The stepper API test suite provides a set of tests that can be used to verify the functionality of
5661stepper drivers.
@@ -91,8 +96,16 @@ have been skipped.
9196 API Reference
9297*************
9398
99+ .. _stepper-drv-api-reference :
100+
94101A common set of functions which should be implemented by all stepper drivers.
95102
103+ .. doxygengroup :: stepper_drv_interface
104+
105+ .. _stepper-api-reference :
106+
107+ A common set of functions which should be implemented by all stepper controllers.
108+
96109.. doxygengroup :: stepper_interface
97110
98111Stepper controller specific APIs
0 commit comments