Lines Matching refs:child
698 #define TMC5041_SHAFT_CONFIG(child) \ argument
699 (DT_PROP(child, invert_direction) << TMC5041_GCONF_SHAFT_SHIFT(DT_REG_ADDR(child))) |
701 #define TMC5041_STEPPER_CONFIG_DEFINE(child) \ argument
702 COND_CODE_1(DT_PROP_EXISTS(child, stallguard_threshold_velocity), \
703 BUILD_ASSERT(DT_PROP(child, stallguard_threshold_velocity), \
705 IF_ENABLED(CONFIG_STEPPER_ADI_TMC5041_RAMP_GEN, (CHECK_RAMP_DT_DATA(child))); \
706 static const struct tmc5041_stepper_config tmc5041_stepper_config_##child = { \
707 .controller = DEVICE_DT_GET(DT_PARENT(child)), \
708 .default_micro_step_res = DT_PROP(child, micro_step_res), \
709 .index = DT_REG_ADDR(child), \
710 .sg_threshold = DT_PROP(child, stallguard2_threshold), \
711 .sg_threshold_velocity = DT_PROP(child, stallguard_threshold_velocity), \
712 .sg_velocity_check_interval_ms = DT_PROP(child, \
714 .is_sg_enabled = DT_PROP(child, activate_stallguard2), \
716 (.default_ramp_config = TMC_RAMP_DT_SPEC_GET(child))) };
718 #define TMC5041_STEPPER_DATA_DEFINE(child) \ argument
719 static struct tmc5041_stepper_data tmc5041_stepper_data_##child = { \
720 .stepper = DEVICE_DT_GET(child),};
722 #define TMC5041_STEPPER_API_DEFINE(child) \ argument
723 static DEVICE_API(stepper, tmc5041_stepper_api_##child) = { \
736 #define TMC5041_STEPPER_DEFINE(child) \ argument
737 DEVICE_DT_DEFINE(child, tmc5041_stepper_init, NULL, &tmc5041_stepper_data_##child, \
738 &tmc5041_stepper_config_##child, POST_KERNEL, \
739 CONFIG_STEPPER_INIT_PRIORITY, &tmc5041_stepper_api_##child);