From 96558b11c28052189547052af09ad9fd6f531e48 Mon Sep 17 00:00:00 2001 From: Ted Miller Date: Tue, 26 Nov 2024 16:14:14 -0500 Subject: [PATCH 1/2] Add note about `mpGetFBPulsePosEx` Clarify about why we may want to consider it for future usage. --- src/CtrlGroup.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/CtrlGroup.c b/src/CtrlGroup.c index 8a227ebe..a53788c0 100644 --- a/src/CtrlGroup.c +++ b/src/CtrlGroup.c @@ -336,6 +336,13 @@ BOOL Ros_CtrlGroup_GetFBPulsePos(CtrlGroup* ctrlGroup, long pulsePos[MAX_PULSE_A #ifndef DUMMY_SERVO_MODE // get raw (uncorrected/unscaled) joint positions LONG status = mpGetFBPulsePos (&sData,&pulse_data); + + //TODO: Consider using mpGetFBPulsePosEx. The `ex` version automatically applies + // any needed corrections, such as gravity compensation and cross-axis + // coupling. We're already (manually) applying those corrections, so we don't + // need the `ex` version. But if the next controller generation adds some new + // feature, then we should transition so that we don't have to worry about it. + if (0 != status) { Ros_Debug_BroadcastMsg("Failed to get pulse feedback position: %u", status); From 2b7cd8c95516b9c4f9416567a7be60ff903db8f3 Mon Sep 17 00:00:00 2001 From: "G.A. vd. Hoorn" Date: Wed, 27 Nov 2024 13:19:48 +0100 Subject: [PATCH 2/2] Link to issue with discussion --- src/CtrlGroup.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/CtrlGroup.c b/src/CtrlGroup.c index a53788c0..ff698f1d 100644 --- a/src/CtrlGroup.c +++ b/src/CtrlGroup.c @@ -342,6 +342,7 @@ BOOL Ros_CtrlGroup_GetFBPulsePos(CtrlGroup* ctrlGroup, long pulsePos[MAX_PULSE_A // coupling. We're already (manually) applying those corrections, so we don't // need the `ex` version. But if the next controller generation adds some new // feature, then we should transition so that we don't have to worry about it. + // See also yaskawa-global/motoros2#199. if (0 != status) {