Zephyr Project API 4.3.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
stepper_tmcm3216.h File Reference

Public API for ADI TMCM-3216 stepper motor controller. More...

Go to the source code of this file.

Data Structures

struct  tmcm3216_status
 Motor status structure for TMCM-3216. More...

Functions

int tmcm3216_set_max_velocity (const struct device *dev, uint32_t velocity)
 Set maximum velocity for TMCM-3216 motor.
int tmcm3216_get_max_velocity (const struct device *dev, uint32_t *velocity)
 Get maximum velocity for TMCM-3216 motor.
int tmcm3216_set_max_acceleration (const struct device *dev, uint32_t acceleration)
 Set maximum acceleration for TMCM-3216 motor.
int tmcm3216_get_actual_velocity (const struct device *dev, int32_t *velocity)
 Get actual velocity of TMCM-3216 motor.
int tmcm3216_get_status (const struct device *dev, struct tmcm3216_status *status)
 Get motor status of TMCM-3216.

Detailed Description

Public API for ADI TMCM-3216 stepper motor controller.

Function Documentation

◆ tmcm3216_get_actual_velocity()

int tmcm3216_get_actual_velocity ( const struct device * dev,
int32_t * velocity )

Get actual velocity of TMCM-3216 motor.

Parameters
devPointer to the stepper device
velocityPointer to store the actual velocity value
Returns
0 on success, negative errno on failure

◆ tmcm3216_get_max_velocity()

int tmcm3216_get_max_velocity ( const struct device * dev,
uint32_t * velocity )

Get maximum velocity for TMCM-3216 motor.

Parameters
devPointer to the stepper device
velocityPointer to store the maximum velocity value
Returns
0 on success, negative errno on failure

◆ tmcm3216_get_status()

int tmcm3216_get_status ( const struct device * dev,
struct tmcm3216_status * status )

Get motor status of TMCM-3216.

Parameters
devPointer to the stepper device
statusPointer to store the motor status
Returns
0 on success, negative errno on failure

◆ tmcm3216_set_max_acceleration()

int tmcm3216_set_max_acceleration ( const struct device * dev,
uint32_t acceleration )

Set maximum acceleration for TMCM-3216 motor.

Parameters
devPointer to the stepper device
accelerationMaximum acceleration value
Returns
0 on success, negative errno on failure

◆ tmcm3216_set_max_velocity()

int tmcm3216_set_max_velocity ( const struct device * dev,
uint32_t velocity )

Set maximum velocity for TMCM-3216 motor.

Parameters
devPointer to the stepper device
velocityMaximum velocity value
Returns
0 on success, negative errno on failure