diff --git a/include/sot-dynamic/waist-attitude-from-sensor.h b/include/sot-dynamic/waist-attitude-from-sensor.h
index 0d7a2fbc264b6799f30ce13ba46ed7af8b7a5af2..adeb65831bb3bb2e94bbacd305eefd5d3e741ce1 100644
--- a/include/sot-dynamic/waist-attitude-from-sensor.h
+++ b/include/sot-dynamic/waist-attitude-from-sensor.h
@@ -98,7 +98,14 @@ class SOTWAISTATTITUDEFROMSENSOR_EXPORT WaistPoseFromSensorAndContact
   static const std::string CLASS_NAME;
 
  protected:
-  bool fromSensor;
+  void fromSensor(const bool& inFromSensor) {
+    fromSensor_ = inFromSensor;
+  }
+  bool fromSensor() const {
+    return fromSensor_;
+  }
+ private:
+  bool fromSensor_;
 
  public: /* --- CONSTRUCTION --- */
 
diff --git a/src/waist-attitude-from-sensor.cpp b/src/waist-attitude-from-sensor.cpp
index 783d906b81c2982f10e7ddf08ca4c19334945af1..239a67299517a036ee3d2017e6e1353b093f1f7b 100644
--- a/src/waist-attitude-from-sensor.cpp
+++ b/src/waist-attitude-from-sensor.cpp
@@ -22,6 +22,10 @@
 #include <sot-core/debug.h>
 #include <dynamic-graph/factory.h>
 
+#include <dynamic-graph/command.h>
+#include <dynamic-graph/command-setter.h>
+#include <dynamic-graph/command-getter.h>
+
 using namespace sot;
 using namespace dynamicgraph;
 DYNAMICGRAPH_FACTORY_ENTITY_PLUGIN(WaistAttitudeFromSensor,"WaistAttitudeFromSensor");
@@ -105,7 +109,7 @@ DYNAMICGRAPH_FACTORY_ENTITY_PLUGIN(WaistPoseFromSensorAndContact,
 WaistPoseFromSensorAndContact::
 WaistPoseFromSensorAndContact( const std::string & name ) 
   :WaistAttitudeFromSensor(name)
-   ,fromSensor(false)
+   ,fromSensor_(false)
    ,positionContactSIN(NULL,"sotWaistPoseFromSensorAndContact("+name+")::input(matrixHomo)::contact")
    ,positionWaistSOUT( boost::bind(&WaistPoseFromSensorAndContact::computePositionWaist,this,_1,_2),
 		       attitudeWaistSOUT<<positionContactSIN,
@@ -115,6 +119,29 @@ WaistPoseFromSensorAndContact( const std::string & name )
 
   signalRegistration( positionContactSIN<<positionWaistSOUT );
 
+  // Commands
+  std::string docstring;
+  docstring = "    \n"
+    "    Set flag specifying whether angles are measured from sensors or simulated.\n"
+    "    \n"
+    "      Input:\n"
+    "        - a boolean value.\n"
+    "    \n";
+  addCommand("setFromSensor",
+	     new ::dynamicgraph::command::Setter
+	     <WaistPoseFromSensorAndContact, bool>
+	     (*this, &WaistPoseFromSensorAndContact::fromSensor, docstring));
+
+    "    Get flag specifying whether angles are measured from sensors or simulated.\n"
+    "    \n"
+    "      No input,\n"
+    "      return a boolean value.\n"
+    "    \n";
+  addCommand("getFromSensor",
+	     new ::dynamicgraph::command::Getter
+	     <WaistPoseFromSensorAndContact, bool>
+	     (*this, &WaistPoseFromSensorAndContact::fromSensor, docstring));
+
   sotDEBUGOUT(5);
 }
 
@@ -144,7 +171,7 @@ computePositionWaist( ml::Vector& res,
   for( unsigned int i=0;i<3;++i ) 
     { res(i)=contactMwaist(i,3); }
 
-  if(fromSensor)
+  if(fromSensor_)
     {
       const VectorRollPitchYaw & worldrwaist = attitudeWaistSOUT( time );
       for( unsigned int i=0;i<3;++i ) 
@@ -191,9 +218,9 @@ commandLine( const std::string& cmdLine,
       std::string val; cmdArgs>>val; 
       if( ("true"==val)||("false"==val) )
 	{
-	  fromSensor = ( val=="true" ); 
+	  fromSensor_ = ( val=="true" ); 
 	} else {
-	  os << "fromSensor = " << (fromSensor?"true":"false") << std::endl;
+	  os << "fromSensor = " << (fromSensor_?"true":"false") << std::endl;
 	}
     }
   else { WaistAttitudeFromSensor::commandLine( cmdLine,cmdArgs,os); }