Skip to content

Commit 01c106e

Browse files
committed
Rename into couplingXCubHandMk5
1 parent fcb5c23 commit 01c106e

File tree

4 files changed

+34
-34
lines changed

4 files changed

+34
-34
lines changed

src/modules/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@
77
if(COMPILE_ergoCubEmotions)
88
add_subdirectory(ergoCubEmotions)
99
endif()
10-
add_subdirectory(handMk5CouplingHandler)
10+
add_subdirectory(couplingXCubHandMk5)

src/modules/handMk5CouplingHandler/CMakeLists.txt renamed to src/modules/couplingXCubHandMk5/CMakeLists.txt

+11-11
Original file line numberDiff line numberDiff line change
@@ -8,29 +8,29 @@ find_package(YARP 3.9.0 REQUIRED)
88

99
yarp_configure_plugins_installation(ergocub-software)
1010

11-
yarp_prepare_plugin(couplingHandMk5
11+
yarp_prepare_plugin(couplingXCubHandMk5
1212
CATEGORY device
13-
TYPE HandMk5CouplingHandler
14-
INCLUDE HandMk5CouplingHandler.h
13+
TYPE CouplingXCubHandMk5
14+
INCLUDE CouplingXCubHandMk5.h
1515
DEFAULT OFF)
1616

17-
if(ENABLE_couplingHandMk5)
17+
if(ENABLE_couplingXCubHandMk5)
1818

19-
yarp_add_plugin(yarp_couplingHandMk5)
19+
yarp_add_plugin(yarp_couplingXCubHandMk5)
2020

2121
if(MSVC)
2222
add_definitions(-D_USE_MATH_DEFINES)
2323
endif()
2424

25-
target_sources(yarp_couplingHandMk5 PRIVATE HandMk5CouplingHandler.cpp
26-
HandMk5CouplingHandler.h)
25+
target_sources(yarp_couplingXCubHandMk5 PRIVATE CouplingXCubHandMk5.cpp
26+
CouplingXCubHandMk5.h)
2727

28-
target_link_libraries(yarp_couplingHandMk5 PRIVATE YARP::YARP_os
29-
YARP::YARP_dev)
28+
target_link_libraries(yarp_couplingXCubHandMk5 PRIVATE YARP::YARP_os
29+
YARP::YARP_dev)
3030
list(APPEND YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS YARP_os
3131
YARP_dev)
3232

33-
yarp_install(TARGETS yarp_couplingHandMk5
33+
yarp_install(TARGETS yarp_couplingXCubHandMk5
3434
EXPORT YARP_${YARP_PLUGIN_MASTER}
3535
COMPONENT ${YARP_PLUGIN_MASTER}
3636
LIBRARY DESTINATION ${YARP_DYNAMIC_PLUGINS_INSTALL_DIR}
@@ -39,5 +39,5 @@ if(ENABLE_couplingHandMk5)
3939

4040
set(YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS ${YARP_${YARP_PLUGIN_MASTER}_PRIVATE_DEPS} PARENT_SCOPE)
4141

42-
set_property(TARGET yarp_couplingHandMk5 PROPERTY FOLDER "Plugins/Device")
42+
set_property(TARGET yarp_couplingXCubHandMk5 PROPERTY FOLDER "Plugins/Device")
4343
endif()

src/modules/handMk5CouplingHandler/HandMk5CouplingHandler.cpp renamed to src/modules/couplingXCubHandMk5/CouplingXCubHandMk5.cpp

+15-15
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* BSD-3-Clause license. See the accompanying LICENSE file for details.
77
*/
88

9-
#include "HandMk5CouplingHandler.h"
9+
#include "CouplingXCubHandMk5.h"
1010
#include <yarp/os/LogStream.h>
1111
#include <yarp/os/LogComponent.h>
1212
#include <cmath>
@@ -15,7 +15,7 @@
1515
YARP_DECLARE_LOG_COMPONENT(HANDMK5COUPLINGHANDLER)
1616

1717

18-
double HandMk5CouplingHandler::evaluateCoupledJoint(const double& q1, const std::string& finger_name)
18+
double CouplingXCubHandMk5::evaluateCoupledJoint(const double& q1, const std::string& finger_name)
1919
{
2020
/**
2121
* Coupling law taken from from https://icub-tech-iit.github.io/documentation/hands/hands_mk5_coupling
@@ -43,7 +43,7 @@ double HandMk5CouplingHandler::evaluateCoupledJoint(const double& q1, const std:
4343
}
4444

4545

46-
double HandMk5CouplingHandler::evaluateCoupledJointJacobian(const double& q1, const std::string& finger_name)
46+
double CouplingXCubHandMk5::evaluateCoupledJointJacobian(const double& q1, const std::string& finger_name)
4747
{
4848
/**
4949
* Coupling law jacobian taken from from https://icub-tech-iit.github.io/documentation/hands/hands_mk5_coupling
@@ -72,14 +72,14 @@ double HandMk5CouplingHandler::evaluateCoupledJointJacobian(const double& q1, co
7272
}
7373

7474

75-
HandMk5CouplingHandler::HandMk5CouplingHandler()
75+
CouplingXCubHandMk5::CouplingXCubHandMk5()
7676
{
7777
m_couplingSize = 12;
7878
}
7979

8080

8181

82-
bool HandMk5CouplingHandler::parseFingerParameters(yarp::os::Searchable& config)
82+
bool CouplingXCubHandMk5::parseFingerParameters(yarp::os::Searchable& config)
8383
{
8484

8585
yarp::os::Bottle& hand_params = config.findGroup("COUPLING_PARAMS");
@@ -119,7 +119,7 @@ bool HandMk5CouplingHandler::parseFingerParameters(yarp::os::Searchable& config)
119119
return true;
120120
}
121121

122-
bool HandMk5CouplingHandler::parseCouplingParameters(yarp::os::Searchable& config) {
122+
bool CouplingXCubHandMk5::parseCouplingParameters(yarp::os::Searchable& config) {
123123
yarp::sig::VectorOf<size_t> coupled_physical_joints{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11};
124124
yarp::sig::VectorOf<size_t> coupled_actuated_axes{0, 1, 2, 3, 4, 5};
125125
std::vector<std::string> physical_joint_names;
@@ -197,7 +197,7 @@ bool HandMk5CouplingHandler::parseCouplingParameters(yarp::os::Searchable& confi
197197
return true;
198198
}
199199

200-
bool HandMk5CouplingHandler::open(yarp::os::Searchable& config) {
200+
bool CouplingXCubHandMk5::open(yarp::os::Searchable& config) {
201201

202202
// TODO INVOKE ImplementCoupling::initialise()
203203
bool ok = parseFingerParameters(config);
@@ -215,7 +215,7 @@ bool HandMk5CouplingHandler::open(yarp::os::Searchable& config) {
215215
return ok;
216216
}
217217

218-
bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesPos(const yarp::sig::Vector& physJointsPos, yarp::sig::Vector& actAxesPos) {
218+
bool CouplingXCubHandMk5::convertFromPhysicalJointsToActuatedAxesPos(const yarp::sig::Vector& physJointsPos, yarp::sig::Vector& actAxesPos) {
219219
size_t nrOfPhysicalJoints;
220220
size_t nrOfActuatedAxes;
221221
auto ok = getNrOfPhysicalJoints(nrOfPhysicalJoints);
@@ -244,7 +244,7 @@ bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesPos(const ya
244244
return true;
245245
}
246246

247-
bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesVel(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, yarp::sig::Vector& actAxesVel) {
247+
bool CouplingXCubHandMk5::convertFromPhysicalJointsToActuatedAxesVel(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, yarp::sig::Vector& actAxesVel) {
248248
size_t nrOfPhysicalJoints;
249249
size_t nrOfActuatedAxes;
250250
auto ok = getNrOfPhysicalJoints(nrOfPhysicalJoints);
@@ -273,16 +273,16 @@ bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesVel(const ya
273273
}
274274

275275

276-
bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesAcc(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, const yarp::sig::Vector& physJointsAcc, yarp::sig::Vector& actAxesAcc) {
276+
bool CouplingXCubHandMk5::convertFromPhysicalJointsToActuatedAxesAcc(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, const yarp::sig::Vector& physJointsAcc, yarp::sig::Vector& actAxesAcc) {
277277
return false;
278278
}
279279

280-
bool HandMk5CouplingHandler::convertFromPhysicalJointsToActuatedAxesTrq(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsTrq, yarp::sig::Vector& actAxesTrq) {
280+
bool CouplingXCubHandMk5::convertFromPhysicalJointsToActuatedAxesTrq(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsTrq, yarp::sig::Vector& actAxesTrq) {
281281
return false;
282282
}
283283

284284

285-
bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsPos(const yarp::sig::Vector& actAxesPos, yarp::sig::Vector& physJointsPos) {
285+
bool CouplingXCubHandMk5::convertFromActuatedAxesToPhysicalJointsPos(const yarp::sig::Vector& actAxesPos, yarp::sig::Vector& physJointsPos) {
286286
size_t nrOfPhysicalJoints;
287287
size_t nrOfActuatedAxes;
288288
auto ok = getNrOfPhysicalJoints(nrOfPhysicalJoints);
@@ -319,7 +319,7 @@ bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsPos(const ya
319319
}
320320

321321

322-
bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsVel(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesVel, yarp::sig::Vector& physJointsVel) {
322+
bool CouplingXCubHandMk5::convertFromActuatedAxesToPhysicalJointsVel(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesVel, yarp::sig::Vector& physJointsVel) {
323323
size_t nrOfPhysicalJoints;
324324
size_t nrOfActuatedAxes;
325325
auto ok = getNrOfPhysicalJoints(nrOfPhysicalJoints);
@@ -372,9 +372,9 @@ bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsVel(const ya
372372
return true;
373373
}
374374

375-
bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsAcc(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesVel, const yarp::sig::Vector& actAxesAcc, yarp::sig::Vector& physJointsAcc) {
375+
bool CouplingXCubHandMk5::convertFromActuatedAxesToPhysicalJointsAcc(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesVel, const yarp::sig::Vector& actAxesAcc, yarp::sig::Vector& physJointsAcc) {
376376
return false;
377377
}
378-
bool HandMk5CouplingHandler::convertFromActuatedAxesToPhysicalJointsTrq(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesTrq, yarp::sig::Vector& physJointsTrq) {
378+
bool CouplingXCubHandMk5::convertFromActuatedAxesToPhysicalJointsTrq(const yarp::sig::Vector& actAxesPos, const yarp::sig::Vector& actAxesTrq, yarp::sig::Vector& physJointsTrq) {
379379
return false;
380380
}

src/modules/handMk5CouplingHandler/HandMk5CouplingHandler.h renamed to src/modules/couplingXCubHandMk5/CouplingXCubHandMk5.h

+7-7
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
* BSD-3-Clause license. See the accompanying LICENSE file for details.
77
*/
88

9-
#ifndef HANDMK5COUPLINGHANDLER_H
10-
#define HANDMK5COUPLINGHANDLER_H
9+
#ifndef COUPLINGXCUBHANDMK5_H
10+
#define COUPLINGXCUBHANDMK5_H
1111

1212
#include <yarp/dev/DeviceDriver.h>
1313
#include <yarp/dev/ImplementJointCoupling.h>
@@ -18,11 +18,11 @@
1818

1919
/** TBD
2020
*/
21-
class HandMk5CouplingHandler : public yarp::dev::DeviceDriver,
22-
public yarp::dev::ImplementJointCoupling {
21+
class CouplingXCubHandMk5 : public yarp::dev::DeviceDriver,
22+
public yarp::dev::ImplementJointCoupling {
2323
public:
24-
HandMk5CouplingHandler();
25-
~HandMk5CouplingHandler() override;
24+
CouplingXCubHandMk5();
25+
~CouplingXCubHandMk5() override;
2626
bool convertFromPhysicalJointsToActuatedAxesPos(const yarp::sig::Vector& physJointsPos, yarp::sig::Vector& actAxesPos) override;
2727
bool convertFromPhysicalJointsToActuatedAxesVel(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, yarp::sig::Vector& actAxesVel) override;
2828
bool convertFromPhysicalJointsToActuatedAxesAcc(const yarp::sig::Vector& physJointsPos, const yarp::sig::Vector& physJointsVel, const yarp::sig::Vector& physJointsAcc, yarp::sig::Vector& actAxesAcc) override;
@@ -83,4 +83,4 @@ class HandMk5CouplingHandler : public yarp::dev::DeviceDriver,
8383
bool parseCouplingParameters(yarp::os::Searchable& config);
8484
};
8585

86-
#endif // HANDMK5COUPLINGHANDLER_H
86+
#endif // COUPLINGXCUBHANDMK5_H

0 commit comments

Comments
 (0)