Skip to content

Commit

Permalink
RSDK-7670 Fix flaking test (viamrobotics#3981)
Browse files Browse the repository at this point in the history
  • Loading branch information
biotinker authored May 21, 2024
1 parent 27086ab commit 646fc61
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion components/base/kinematicbase/execution.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func (ptgk *ptgBaseKinematics) GoToInputs(ctx context.Context, inputSteps ...[]r

defer func() {
ptgk.inputLock.Lock()
ptgk.currentState.currentInputs = zeroInput
ptgk.currentState = baseState{currentInputs: zeroInput}
ptgk.inputLock.Unlock()
}()

Expand Down
6 changes: 4 additions & 2 deletions components/base/kinematicbase/fake_kinematics.go
Original file line number Diff line number Diff line change
Expand Up @@ -268,9 +268,11 @@ func (fk *fakePTGKinematics) GoToInputs(ctx context.Context, inputSteps ...[]ref

fk.inputLock.Lock()
fk.currentIndex = i
fk.currentInput = []referenceframe.Input{inputs[0], inputs[1], inputs[2], inputs[2]}
fk.currentInput, err = fk.frame.Interpolate(zeroInput, inputs, 0)
fk.inputLock.Unlock()

if err != nil {
return err
}
finalPose, err := fk.frame.Transform(inputs)
if err != nil {
return err
Expand Down

0 comments on commit 646fc61

Please sign in to comment.