Commit 83375274 authored by Wenxi XU's avatar Wenxi XU
Browse files

添加两种设备树属性

parent 477d2290
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -92,6 +92,8 @@
		.is_dm_motor = DT_PROP(node, is_dm_motor),                                         \
		.dm_i_max = DT_STRING_UNQUOTED_OR(node, dm_i_max, 0.0f),                           \
		.dm_torque_ratio = DT_STRING_UNQUOTED_OR(node, dm_torque_ratio, 0.0f),             \
		.minor_arc = DT_PROP(node, minor_arc),                                             \
		.inverse = DT_PROP(node, inverse),                                                 \
		.follow = DEVICE_DT_GET_OR_NULL(CONFIG_GET_FOLLOW(node)),                          \
	};

+3 −0
Original line number Diff line number Diff line
@@ -103,6 +103,9 @@ struct dji_motor_config {
	float dm_i_max;
	float dm_torque_ratio;
	const struct device *follow;

	bool minor_arc;
	bool inverse;
};

// 全局变量声明