Skip to content

Commit 79d6294

Browse files
Irockasingranitekartben
authored andcommitted
drivers: stepper: Add driver for DRV8424 stepper motor controller
Adds a step/dir stepper driver for the drv8424 stepper driver. Signed-off-by: Sarah Renkhoff <[email protected]>
1 parent b65a97e commit 79d6294

File tree

8 files changed

+825
-0
lines changed

8 files changed

+825
-0
lines changed

drivers/stepper/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ zephyr_syscall_header(${ZEPHYR_BASE}/include/zephyr/drivers/stepper.h)
55

66
# zephyr-keep-sorted-start
77
add_subdirectory_ifdef(CONFIG_STEPPER_ADI_TMC adi_tmc)
8+
add_subdirectory_ifdef(CONFIG_STEPPER_TI ti)
89
# zephyr-keep-sorted-stop
910

1011
zephyr_library()

drivers/stepper/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ comment "Stepper Drivers"
3535
rsource "Kconfig.fake"
3636
rsource "Kconfig.gpio"
3737
rsource "adi_tmc/Kconfig"
38+
rsource "ti/Kconfig"
3839
# zephyr-keep-sorted-stop
3940

4041
endif

drivers/stepper/ti/CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2024 Navimatix GmbH
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
zephyr_library()
5+
zephyr_library_property(ALLOW_EMPTY TRUE)
6+
7+
zephyr_library_sources_ifdef(CONFIG_DRV8424 drv8424.c)

drivers/stepper/ti/Kconfig

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2024 Navimatix GmbH
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config STEPPER_TI
5+
bool "TI Stepper Controller"
6+
depends on STEPPER
7+
default y
8+
help
9+
Enable ti stepper controller
10+
11+
if STEPPER_TI
12+
13+
comment "TI Stepper Drivers"
14+
15+
rsource "Kconfig.drv8424"
16+
17+
endif # STEPPER_TI

drivers/stepper/ti/Kconfig.drv8424

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2024 Navimatix GmbH
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config DRV8424
5+
bool "TI DRV8424 stepper motor driver"
6+
default y
7+
depends on DT_HAS_TI_DRV8424_ENABLED
8+
select COUNTER
9+
help
10+
Enable driver for TI DRV8424 stepper motor driver.
11+
12+
if DRV8424
13+
14+
config DRV8424_EVENT_QUEUE_LEN
15+
int "Maximum number of pending stepper events"
16+
default 4
17+
help
18+
The maximum number of stepper events that can be pending before new events
19+
are dropped.
20+
21+
endif # DRV8424

0 commit comments

Comments
 (0)