Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set the calibrationMeasurementToLink matrix to the initial when resetAll is called #421

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

This file documents notable changes to this project done before November 2023. For changes after that date, please refer to the release notes of each release at https://github.com/robotology/human-dynamics-estimation/releases.

## [Unreleased]

### Fixed
- Set the calibrationMeasurementToLink matrix to the initial when `resetAll` rpc command is called (https://github.com/robotology/human-dynamics-estimation/pull/421).

## [3.0.0] - 2023-11-09

### Changed
Expand Down
2 changes: 2 additions & 0 deletions devices/HumanStateProvider/HumanStateProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -787,6 +787,8 @@ bool HumanStateProvider::open(yarp::os::Searchable& config)
fixedRightRotation);
pImpl->wearableTargets[targetName].get()->calibrationMeasurementToLink.setPosition(
fixedRightPositionOffset);
pImpl->wearableTargets[targetName].get()->calibrationMeasurementToLinkInitial =
pImpl->wearableTargets[targetName].get()->calibrationMeasurementToLink;
yInfo()
<< LogPrefix << "Adding Fixed Rotation for " << targetName << "==>"
<< pImpl->wearableTargets[targetName].get()->calibrationMeasurementToLink.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ namespace hde {

iDynTree::Transform calibrationWorldToMeasurementWorld;
iDynTree::Transform calibrationMeasurementToLink;
iDynTree::Transform calibrationMeasurementToLinkInitial;
iDynTree::Vector3 positionScaleFactor;

// buffer variables
Expand Down Expand Up @@ -89,7 +90,7 @@ namespace hde {
{
std::lock_guard<std::mutex> lock(mutex);
calibrationWorldToMeasurementWorld = iDynTree::Transform::Identity();
calibrationMeasurementToLink = iDynTree::Transform::Identity();
calibrationMeasurementToLink = calibrationMeasurementToLinkInitial;
};

void clearWorldCalibrationMatrix()
Expand Down
Loading