sot-talos-balance
2.0.5
Collection of dynamic-graph entities aimed at implementing balance control on talos.
boolean-identity.cpp
Go to the documentation of this file.
1
/*
2
* Copyright 2018, Gepetto team, LAAS-CNRS
3
*
4
* This file is part of sot-talos-balance.
5
* sot-talos-balance is free software: you can redistribute it and/or
6
* modify it under the terms of the GNU Lesser General Public License
7
* as published by the Free Software Foundation, either version 3 of
8
* the License, or (at your option) any later version.
9
* sot-talos-balance is distributed in the hope that it will be
10
* useful, but WITHOUT ANY WARRANTY; without even the implied warranty
11
* of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU Lesser General Public License for more details. You should
13
* have received a copy of the GNU Lesser General Public License along
14
* with sot-talos-balance. If not, see <http://www.gnu.org/licenses/>.
15
*/
16
17
#include "
sot/talos_balance/boolean-identity.hh
"
18
19
#include <dynamic-graph/all-commands.h>
20
#include <dynamic-graph/factory.h>
21
22
#include <sot/core/debug.hh>
23
24
namespace
dynamicgraph
{
25
namespace
sot
{
26
namespace
talos_balance {
27
namespace
dg
= ::dynamicgraph;
28
using namespace
dg
;
29
using namespace
dg::command;
30
31
#define INPUT_SIGNALS m_sinSIN
32
33
#define OUTPUT_SIGNALS m_soutSOUT
34
37
typedef
BooleanIdentity
EntityClassName
;
38
39
/* --- DG FACTORY ---------------------------------------------------- */
40
DYNAMICGRAPH_FACTORY_ENTITY_PLUGIN
(BooleanIdentity,
"BooleanIdentity"
);
41
42
/* ------------------------------------------------------------------- */
43
/* --- CONSTRUCTION -------------------------------------------------- */
44
/* ------------------------------------------------------------------- */
45
BooleanIdentity::BooleanIdentity
(
const
std::string&
name
)
46
: Entity(
name
),
47
CONSTRUCT_SIGNAL_IN(sin, bool),
48
CONSTRUCT_SIGNAL_OUT(sout, bool,
INPUT_SIGNALS
) {
49
Entity::signalRegistration(
INPUT_SIGNALS
<<
OUTPUT_SIGNALS
);
50
51
/* Commands. */
52
addCommand(
"init"
,
53
makeCommandVoid0(*
this
, &
BooleanIdentity::init
,
54
docCommandVoid0(
"Initialize the entity."
)));
55
}
56
57
/* ------------------------------------------------------------------- */
58
/* --- SIGNALS ------------------------------------------------------- */
59
/* ------------------------------------------------------------------- */
60
61
DEFINE_SIGNAL_OUT_FUNCTION
(sout,
bool
) {
62
s = m_sinSIN(iter);
63
return
s;
64
}
65
66
/* ------------------------------------------------------------------- */
67
/* --- ENTITY -------------------------------------------------------- */
68
/* ------------------------------------------------------------------- */
69
70
void
BooleanIdentity::display
(std::ostream& os)
const
{
71
os <<
"BooleanIdentity "
<< getName();
72
// try
73
// {
74
// getProfiler().report_all(3, os);
75
// }
76
// catch (ExceptionSignal e) {}
77
}
78
79
}
// namespace talos_balance
80
}
// namespace sot
81
}
// namespace dynamicgraph
INPUT_SIGNALS
#define INPUT_SIGNALS
Definition:
boolean-identity.cpp:31
sot_talos_balance.test.appli_admittance_end_effector.sot
sot
Definition:
appli_admittance_end_effector.py:117
dynamicgraph
Definition:
treeview.dox:24
dynamicgraph::sot::talos_balance::BooleanIdentity::BooleanIdentity
EIGEN_MAKE_ALIGNED_OPERATOR_NEW BooleanIdentity(const std::string &name)
Definition:
boolean-identity.cpp:45
dynamicgraph::sot::talos_balance::DEFINE_SIGNAL_OUT_FUNCTION
DEFINE_SIGNAL_OUT_FUNCTION(dq, dynamicgraph::Vector)
Definition:
admittance-controller-end-effector.cpp:210
dynamicgraph::sot::talos_balance::BooleanIdentity::init
void init()
Definition:
boolean-identity.hh:61
OUTPUT_SIGNALS
#define OUTPUT_SIGNALS
Definition:
boolean-identity.cpp:33
dynamicgraph::sot::talos_balance::DYNAMICGRAPH_FACTORY_ENTITY_PLUGIN
DYNAMICGRAPH_FACTORY_ENTITY_PLUGIN(AdmittanceControllerEndEffector, "AdmittanceControllerEndEffector")
boolean-identity.hh
dynamicgraph::sot::talos_balance::EntityClassName
AdmittanceControllerEndEffector EntityClassName
Definition:
admittance-controller-end-effector.cpp:46
sot_talos_balance.test.appli_dcm_zmp_control.name
name
Definition:
appli_dcm_zmp_control.py:298
dynamicgraph::sot::talos_balance::BooleanIdentity::display
virtual void display(std::ostream &os) const
Definition:
boolean-identity.cpp:70
src
boolean-identity.cpp
Generated by
1.8.17