Commit 81856579 authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files
parent 96a6637a
......@@ -244,52 +244,6 @@ namespace dynamicgraph
}
catch (ExceptionSignal e) {}
}
void ControllerPD::
commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os )
{
if( cmdLine == "help" )
{
os << "sotControlPD:\n"
<< " - size <arg>\t\tset the size of the vector.\n"
<< " - stdGain \t\tset the input vector gains according to the size for HRP2.\n"
<< " - velocityonly <arg>\t\tset Kp = 0.\n"
<< std::endl;
}
else if( cmdLine == "size" )
{
cmdArgs >> std::ws;
if( cmdArgs.good() )
{
unsigned int i; cmdArgs >> i ;
size(i);
}
else
{
os << "size = " << size() << std::endl;
}
}
else if( cmdLine == "velocityonly" )
{ setGainVelocityOnly(); }
else if( cmdLine == "stdGain" )
{
std::string config = "high";
cmdArgs >> std::ws; if( cmdArgs.good() ) cmdArgs >> config;
setStandardGains( config );
}
else
{
Entity::commandLine(cmdLine,cmdArgs,os);
}
}
} // namespace dyninv
} // namespace sot
} // namespace dynamicgraph
......
......@@ -74,10 +74,6 @@ namespace dynamicgraph {
virtual void display( std::ostream& os ) const;
virtual void commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os );
public: /* --- SIGNALS --- */
DECLARE_SIGNAL_IN(Kp,dg::Vector);
......
......@@ -342,31 +342,6 @@ namespace dynamicgraph
{
os << "DynamicIntegrator "<<getName() << ". " << std::endl;
}
void DynamicIntegrator::
commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os )
{
if( cmdLine == "help" )
{
os << "DynamicIntegrator:" << std::endl
<< " - inc [dt]" << std::endl;
}
else if( cmdLine == "inc" )
{
if( cmdArgs >> std::ws, cmdArgs.good() )
{
double dt; cmdArgs >> dt; dtSIN = dt;
}
integrateFromSignals();
}
else
{
Entity::commandLine( cmdLine,cmdArgs,os );
}
}
} // namespace dyninv
} // namespace sot
} // namespace dynamicgraph
......
......@@ -61,10 +61,6 @@ namespace dynamicgraph {
virtual void display( std::ostream& os ) const;
virtual void commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os );
public: /* --- SIGNALS --- */
DECLARE_SIGNAL_IN( acceleration,dg::Vector );
......
......@@ -218,55 +218,6 @@ namespace dynamicgraph
{
os << "PseudoRobotDynamic "<<getName() << ". " << std::endl;
}
void PseudoRobotDynamic::
commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os )
{
sotDEBUGIN(15);
if( cmdLine == "help" )
{
os << "PseudoRobotDynamic:" << std::endl
<< " - replace <OpenHRP> [plug]" << std::endl;
}
else if( cmdLine == "replace" )
{
if( cmdArgs >> std::ws, cmdArgs.good() )
{
std::string repName; cmdArgs >> repName >> std::ws;
bool plug = cmdArgs.good();
replaceSimulatorEntity( repName,plug );
}
}
else if( cmdLine=="sbs" || cmdLine=="play" || cmdLine =="withForces"
|| cmdLine == "periodicCall" || cmdLine == "periodicCallBefore"
|| cmdLine == "periodicCallAfter" )
{
formerOpenHRP ->commandLine( cmdLine,cmdArgs,os );
}
else if( cmdLine=="root" )
{
if( cmdArgs >> std::ws, cmdArgs.good() )
{
dg::Matrix M; cmdArgs >> M ; setRoot(M);
std::ostringstream osback;
osback << M.data(); cmdArgs.str(osback.str());
formerOpenHRP ->commandLine( cmdLine,cmdArgs,os );
}
else
{
os << "TODO" << std::endl;
}
}
else
{
Entity::commandLine( cmdLine,cmdArgs,os );
}
sotDEBUGOUT(15);
}
} // namespace dyninv
} // namespace sot
} // namespace dynamicgraph
......
......@@ -71,10 +71,6 @@ namespace dynamicgraph {
virtual void display( std::ostream& os ) const;
virtual void commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os );
typedef ::dynamicgraph::EntityHelper<PseudoRobotDynamic>::EntityClassName
EntityClassName;
......
......@@ -89,24 +89,6 @@ namespace dynamicgraph
{
os << "ZmpEstimator "<<getName() << "." << std::endl;
}
void ZmpEstimator::
commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os )
{
if( cmdLine == "help" )
{
os << "ZmpEstimator:\n"
<< "\t- ." << std::endl;
Entity::commandLine( cmdLine,cmdArgs,os );
}
else
{
Entity::commandLine( cmdLine,cmdArgs,os );
}
}
} // namespace dyninv
} // namespace sot
} // namespace dynamicgraph
......
......@@ -60,10 +60,6 @@ namespace dynamicgraph {
virtual void display( std::ostream& os ) const;
virtual void commandLine( const std::string& cmdLine,
std::istringstream& cmdArgs,
std::ostream& os );
public: /* --- SIGNALS --- */
DECLARE_SIGNAL_IN(fn,dg::Vector);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment