Index: trunk/demos/PidStandalone/simulator/CMakeLists.txt
===================================================================
--- trunk/demos/PidStandalone/simulator/CMakeLists.txt	(revision 44)
+++ trunk/demos/PidStandalone/simulator/CMakeLists.txt	(revision 105)
@@ -3,9 +3,9 @@
 
 SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)
-SET(FRAMEWORK_USE_SIMULATOR TRUE)
-SET(FRAMEWORK_USE_SIMULATOR_GL TRUE)
+SET(FLAIR_USE_SIMULATOR TRUE)
+SET(FLAIR_USE_SIMULATOR_GL TRUE)
 
-include($ENV{IGEP_ROOT}/uav_dev/cmake_modules/GlobalCmakeUAV.cmake)
-include(${FRAMEWORK_USE_FILE})
+include($ENV{FLAIR_ROOT}/flair-dev/cmake-modules/GlobalCmakeFlair.cmake)
+include(${FLAIR_USE_FILE})
 
 SET(SRC_FILES
@@ -13,10 +13,6 @@
 )
 
-LINK_DIRECTORIES (
-	${FRAMEWORK_LIBRARY_DIR}
-)
-
 INCLUDE_DIRECTORIES(
-	${FRAMEWORK_INCLUDE_DIR}
+	${FLAIR_INCLUDE_DIR}
 )
 
@@ -26,5 +22,5 @@
 )
 
-TARGET_LINK_LIBRARIES(${PROJECT_NAME}_rt ${FRAMEWORK_LIBRARIES_RT})
+TARGET_LINK_LIBRARIES(${PROJECT_NAME}_rt ${FLAIR_LIBRARIES_RT})
 
 #non real time executable
@@ -33,3 +29,3 @@
 )
 
-TARGET_LINK_LIBRARIES(${PROJECT_NAME}_nrt ${FRAMEWORK_LIBRARIES_NRT})
+TARGET_LINK_LIBRARIES(${PROJECT_NAME}_nrt ${FLAIR_LIBRARIES_NRT})
Index: trunk/demos/PidStandalone/simulator/src/main.cpp
===================================================================
--- trunk/demos/PidStandalone/simulator/src/main.cpp	(revision 44)
+++ trunk/demos/PidStandalone/simulator/src/main.cpp	(revision 105)
@@ -26,6 +26,6 @@
 using namespace TCLAP;
 using namespace std;
-using namespace framework::simulator;
-using namespace framework::sensor;
+using namespace flair::simulator;
+using namespace flair::sensor;
 
 int port;
Index: trunk/demos/PidStandalone/uav/CMakeLists.txt
===================================================================
--- trunk/demos/PidStandalone/uav/CMakeLists.txt	(revision 44)
+++ trunk/demos/PidStandalone/uav/CMakeLists.txt	(revision 105)
@@ -3,11 +3,11 @@
 
 SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)
-SET(FRAMEWORK_USE_FILTER TRUE)
-SET(FRAMEWORK_USE_SENSOR_ACTUATOR TRUE)
-SET(FRAMEWORK_USE_META TRUE)
-SET(FRAMEWORK_USE_OPTITRACK TRUE)
+SET(FLAIR_USE_FILTER TRUE)
+SET(FLAIR_USE_SENSOR_ACTUATOR TRUE)
+SET(FLAIR_USE_META TRUE)
+SET(FLAIR_USE_VRPN TRUE)
 
-include($ENV{IGEP_ROOT}/uav_dev/cmake_modules/GlobalCmakeUAV.cmake)
-include(${FRAMEWORK_USE_FILE})
+include($ENV{FLAIR_ROOT}/flair-dev/cmake-modules/GlobalCmakeFlair.cmake)
+include(${FLAIR_USE_FILE})
 
 SET(SRC_FILES
@@ -16,10 +16,6 @@
 )
 
-LINK_DIRECTORIES (
-	${FRAMEWORK_LIBRARY_DIR}
-)
-
 INCLUDE_DIRECTORIES(
-	${FRAMEWORK_INCLUDE_DIR}
+	${FLAIR_INCLUDE_DIR}
 )
 
@@ -29,5 +25,5 @@
 )
 
-TARGET_LINK_LIBRARIES(${PROJECT_NAME}_rt ${FRAMEWORK_LIBRARIES_RT})
+TARGET_LINK_LIBRARIES(${PROJECT_NAME}_rt ${FLAIR_LIBRARIES_RT})
 
 #non real time executable
@@ -36,3 +32,3 @@
 )
 
-TARGET_LINK_LIBRARIES(${PROJECT_NAME}_nrt ${FRAMEWORK_LIBRARIES_NRT})
+TARGET_LINK_LIBRARIES(${PROJECT_NAME}_nrt ${FLAIR_LIBRARIES_NRT})
Index: trunk/demos/PidStandalone/uav/src/PidUav.cpp
===================================================================
--- trunk/demos/PidStandalone/uav/src/PidUav.cpp	(revision 44)
+++ trunk/demos/PidStandalone/uav/src/PidUav.cpp	(revision 105)
@@ -29,9 +29,9 @@
 
 using namespace std;
-using namespace framework::core;
-using namespace framework::sensor;
-using namespace framework::gui;
-using namespace framework::filter;
-using namespace framework::meta;
+using namespace flair::core;
+using namespace flair::sensor;
+using namespace flair::gui;
+using namespace flair::filter;
+using namespace flair::meta;
 
 /*
@@ -41,86 +41,91 @@
 ** ===================================================================
 */
-PidUav::PidUav(Uav* uav,TargetController *controller): behaviourMode(BehaviourMode_t::Default),UavStateMachine(uav,controller) {
-    my_uRoll=new Pid(setupLawTab->At(1,1),"custom uRoll");
-    my_uRoll->UseDefaultPlot(graphLawTab->LastRowLastCol());
-    my_uPitch=new Pid(setupLawTab->At(1,0),"custom uPitch");
-    my_uPitch->UseDefaultPlot(graphLawTab->NewRow());
+PidUav::PidUav(Uav *uav, TargetController *controller)
+    : behaviourMode(BehaviourMode_t::Default),
+      UavStateMachine(uav, controller) {
+  my_uRoll = new Pid(setupLawTab->At(1, 1), "custom uRoll");
+  my_uRoll->UseDefaultPlot(graphLawTab->LastRowLastCol());
+  my_uPitch = new Pid(setupLawTab->At(1, 0), "custom uPitch");
+  my_uPitch->UseDefaultPlot(graphLawTab->NewRow());
 }
 
 void PidUav::SignalEvent(Event_t event) {
-    UavStateMachine::SignalEvent(event);
-    switch(event) {
-    case Event_t::TakingOff:
-        //always take off in default mode
-        behaviourMode=BehaviourMode_t::Default;
-        break;
-    case Event_t::EnteringFailSafeMode:
-        //return to default mode
-        Thread::Info("Entering failSafe mode\n");
-        behaviourMode=BehaviourMode_t::Default;
-        break;
-    }
+  UavStateMachine::SignalEvent(event);
+  switch (event) {
+  case Event_t::TakingOff:
+    // always take off in default mode
+    behaviourMode = BehaviourMode_t::Default;
+    break;
+  case Event_t::EnteringFailSafeMode:
+    // return to default mode
+    Thread::Info("Entering failSafe mode\n");
+    behaviourMode = BehaviourMode_t::Default;
+    break;
+  }
 }
 
 bool PidUav::StartCustomMode() {
-    //ask UavStateMachine to enter in custom torques
-    if (SetTorqueMode(TorqueMode_t::Custom)) {
-        Thread::Info("CustomTorques: start\n");
-        my_uPitch->Reset();
-        my_uRoll->Reset();
-        return true;
-    } else {
-        Thread::Warn("CustomTorques: could not start\n");
-        return false;
-    }
+  // ask UavStateMachine to enter in custom torques
+  if (SetTorqueMode(TorqueMode_t::Custom)) {
+    Thread::Info("CustomTorques: start\n");
+    my_uPitch->Reset();
+    my_uRoll->Reset();
+    return true;
+  } else {
+    Thread::Warn("CustomTorques: could not start\n");
+    return false;
+  }
 }
 
 void PidUav::StartOscillatingMode() {
-    if (behaviourMode==BehaviourMode_t::Default) {
-        if (!StartCustomMode()) return;
-    }
-    behaviourMode=BehaviourMode_t::Oscillating;
-    Thread::Info("Entering oscillating mode\n");
-    //remove the 'D' effect with a strong 'P'
-
+  if (behaviourMode == BehaviourMode_t::Default) {
+    if (!StartCustomMode())
+      return;
+  }
+  behaviourMode = BehaviourMode_t::Oscillating;
+  Thread::Info("Entering oscillating mode\n");
+  // remove the 'D' effect with a strong 'P'
 }
 
 void PidUav::ExtraCheckJoystick(void) {
-    static bool wasOscillatingModeButtonPressed=false;
-    // controller button R1 enters optical flow mode
-    if(GetJoystick()->IsButtonPressed(9)) { // R1
-        if (!wasOscillatingModeButtonPressed) {
-            wasOscillatingModeButtonPressed=true;
-            if (behaviourMode!=BehaviourMode_t::Oscillating) StartOscillatingMode();
-        }
-    } else {
-        wasOscillatingModeButtonPressed=false;
+  static bool wasOscillatingModeButtonPressed = false;
+  // controller button R1 enters optical flow mode
+  if (GetJoystick()->IsButtonPressed(9)) { // R1
+    if (!wasOscillatingModeButtonPressed) {
+      wasOscillatingModeButtonPressed = true;
+      if (behaviourMode != BehaviourMode_t::Oscillating)
+        StartOscillatingMode();
     }
+  } else {
+    wasOscillatingModeButtonPressed = false;
+  }
 }
 
 void PidUav::ComputeCustomTorques(Euler &torques) {
-    ComputeDefaultTorques(torques);
-    //overload default torques calculation for pitch and roll
-    const AhrsData *refOrientation=GetDefaultReferenceOrientation();
-    Quaternion refQuaternion;
-    Vector3D refAngularRates;
-    refOrientation->GetQuaternionAndAngularRates(refQuaternion,refAngularRates);
-    Euler refAngles=refQuaternion.ToEuler();
+  ComputeDefaultTorques(torques);
+  // overload default torques calculation for pitch and roll
+  const AhrsData *refOrientation = GetDefaultReferenceOrientation();
+  Quaternion refQuaternion;
+  Vector3D refAngularRates;
+  refOrientation->GetQuaternionAndAngularRates(refQuaternion, refAngularRates);
+  Euler refAngles = refQuaternion.ToEuler();
 
-    const AhrsData *currentOrientation=GetDefaultOrientation();
-    Quaternion currentQuaternion;
-    Vector3D currentAngularRates;
-    currentOrientation->GetQuaternionAndAngularRates(currentQuaternion,currentAngularRates);
-    Euler currentAngles=currentQuaternion.ToEuler();
+  const AhrsData *currentOrientation = GetDefaultOrientation();
+  Quaternion currentQuaternion;
+  Vector3D currentAngularRates;
+  currentOrientation->GetQuaternionAndAngularRates(currentQuaternion,
+                                                   currentAngularRates);
+  Euler currentAngles = currentQuaternion.ToEuler();
 
-    my_uRoll->SetValues(currentAngles.roll-refAngles.roll,currentAngularRates.x);
-    my_uRoll->Update(GetTime());
-    torques.roll=my_uRoll->Output();
+  my_uRoll->SetValues(currentAngles.roll - refAngles.roll,
+                      currentAngularRates.x);
+  my_uRoll->Update(GetTime());
+  torques.roll = my_uRoll->Output();
 
-    my_uPitch->SetValues(currentAngles.pitch-refAngles.pitch,currentAngularRates.y);
-    my_uPitch->Update(GetTime());
-    torques.pitch=my_uPitch->Output();
+  my_uPitch->SetValues(currentAngles.pitch - refAngles.pitch,
+                       currentAngularRates.y);
+  my_uPitch->Update(GetTime());
+  torques.pitch = my_uPitch->Output();
 }
 
-PidUav::~PidUav() {
-}
+PidUav::~PidUav() {}
Index: trunk/demos/PidStandalone/uav/src/PidUav.h
===================================================================
--- trunk/demos/PidStandalone/uav/src/PidUav.h	(revision 44)
+++ trunk/demos/PidStandalone/uav/src/PidUav.h	(revision 105)
@@ -17,39 +17,37 @@
 #include <UavStateMachine.h>
 
-namespace framework {
-    namespace core {
-        class FrameworkManager;
-        class cvmatrix;
-    }
-    namespace gui {
-        class GroupBox;
-        class DoubleSpinBox;
-    }
-    namespace filter {
-        class Pid;
-    }
-    namespace sensor {
-        class TargetController;
-    }
+namespace flair {
+  namespace core {
+    class cvmatrix;
+  }
+  namespace gui {
+    class GroupBox;
+    class DoubleSpinBox;
+  }
+  namespace filter {
+    class Pid;
+  }
+  namespace sensor {
+    class TargetController;
+  }
 }
 
-class PidUav : public framework::meta::UavStateMachine {
-    public:
-        PidUav(framework::meta::Uav* uav, framework::sensor::TargetController *controller);
-        ~PidUav();
+class PidUav : public flair::meta::UavStateMachine {
+public:
+  PidUav(flair::meta::Uav *uav,
+         flair::sensor::TargetController *controller);
+  ~PidUav();
 
-    protected:
-        void SignalEvent(Event_t event);
-        void ExtraCheckJoystick(void);
-    private:
-        void ComputeCustomTorques(framework::core::Euler &torques);
-        bool StartCustomMode();
-        void StartOscillatingMode();
-        framework::filter::Pid *my_uPitch,*my_uRoll;
-        enum class BehaviourMode_t {
-            Default,
-            Oscillating
-        };
-        BehaviourMode_t behaviourMode;
+protected:
+  void SignalEvent(Event_t event);
+  void ExtraCheckJoystick(void);
+
+private:
+  void ComputeCustomTorques(flair::core::Euler &torques);
+  bool StartCustomMode();
+  void StartOscillatingMode();
+  flair::filter::Pid *my_uPitch, *my_uRoll;
+  enum class BehaviourMode_t { Default, Oscillating };
+  BehaviourMode_t behaviourMode;
 };
 
Index: trunk/demos/PidStandalone/uav/src/main.cpp
===================================================================
--- trunk/demos/PidStandalone/uav/src/main.cpp	(revision 44)
+++ trunk/demos/PidStandalone/uav/src/main.cpp	(revision 105)
@@ -22,7 +22,7 @@
 using namespace TCLAP;
 using namespace std;
-using namespace framework::core;
-using namespace framework::meta;
-using namespace framework::sensor;
+using namespace flair::core;
+using namespace flair::meta;
+using namespace flair::sensor;
 
 string uav_type;
@@ -35,75 +35,87 @@
 string address;
 
-void parseOptions(int argc, char** argv);
+void parseOptions(int argc, char **argv);
 
+int main(int argc, char *argv[]) {
+  parseOptions(argc, argv);
 
-int main(int argc, char* argv[]) {
-    parseOptions(argc,argv);
+  FrameworkManager *manager;
+  manager = new FrameworkManager(name);
+  if (!headless) {
+    manager->SetupConnection(address, port);
+  }
+  manager->SetupUserInterface(xml_file);
+  manager->SetupLogger(log_path);
 
-    FrameworkManager *manager;
-    manager= new FrameworkManager(name);
-    if (!headless) {
-        manager->SetupConnection(address,port);
-    }
-    manager->SetupUserInterface(xml_file);
-    manager->SetupLogger(log_path);
+  Uav *drone = CreateUav(manager, name, uav_type);
+  TargetEthController *controller =
+      new TargetEthController(manager, "Dualshock3", 20000);
+  // EmulatedController *controller=new EmulatedController(manager,"Emulated
+  // Controller");
+  //    controller->AddStep(10000,"Waiting for AHRS
+  //    stabilization",0,0.,0.,0.,0.);
+  //    controller->AddStep(500,"Takeoff",(uint16_t)EmulatedController::ButtonType::start,0.,0.,0.,0.);
+  //    controller->AddStep(3000,"Waiting for flight
+  //    stabilization",0,0.,0.,0.,0.);
+  /*    controller->AddStep(2000,"fly left",0,-0.3,0.,0.,0.);
+      controller->AddStep(1000,"fly right",0,0.3,0.,0.,0.);*/
+  //    controller->AddStep(500,"Land",(uint16_t)EmulatedController::ButtonType::start,0.,0.,0.,0.);
+  //    controller->AddStep(3000,"Waiting for landing",0,0.,0.,0.,0.);
+  //    controller->AddStep(500,"Stop",(uint16_t)EmulatedController::ButtonType::select,0.,0.,0.,0.);
+  PidUav *app = new PidUav(drone, controller);
 
-    Uav* drone=CreateUav(manager,name,uav_type);
-    TargetEthController *controller=new TargetEthController(manager,"Dualshock3",20000);
-    //EmulatedController *controller=new EmulatedController(manager,"Emulated Controller");
-//    controller->AddStep(10000,"Waiting for AHRS stabilization",0,0.,0.,0.,0.);
-//    controller->AddStep(500,"Takeoff",(uint16_t)EmulatedController::ButtonType::start,0.,0.,0.,0.);
-//    controller->AddStep(3000,"Waiting for flight stabilization",0,0.,0.,0.,0.);
-/*    controller->AddStep(2000,"fly left",0,-0.3,0.,0.,0.);
-    controller->AddStep(1000,"fly right",0,0.3,0.,0.,0.);*/
-//    controller->AddStep(500,"Land",(uint16_t)EmulatedController::ButtonType::start,0.,0.,0.,0.);
-//    controller->AddStep(3000,"Waiting for landing",0,0.,0.,0.,0.);
-//    controller->AddStep(500,"Stop",(uint16_t)EmulatedController::ButtonType::select,0.,0.,0.,0.);
-    PidUav* app=new PidUav(drone,controller);
+  app->Start();
+  app->Join();
 
-    app->Start();
-    app->Join();
-
-    delete manager;
+  delete manager;
 }
 
-void parseOptions(int argc, char** argv) {
-	try {
+void parseOptions(int argc, char **argv) {
+  try {
 
-        CmdLine cmd("Command description message", ' ', "0.1");
+    CmdLine cmd("Command description message", ' ', "0.1");
 
-        ValueArg<string> nameArg("n","name","uav name",true,"x4","string");
-        cmd.add( nameArg );
+    ValueArg<string> nameArg("n", "name", "uav name", true, "x4", "string");
+    cmd.add(nameArg);
 
-        ValueArg<string> typeArg("t","type","uav type: ardrone2, hds_x4, hds_x8, hds_xufo, hds_simu or hds_simux (with x the number of the simulated uav)",true,"hds_x4","string");
-        cmd.add( typeArg );
+    ValueArg<string> typeArg(
+        "t", "type", "uav type: ardrone2, hds_x4, hds_x8, hds_xufo, hds_simu "
+                     "or hds_simux (with x the number of the simulated uav)",
+        true, "hds_x4", "string");
+    cmd.add(typeArg);
 
-        ValueArg<string> xmlArg("x","xml","fichier xml",true,"./reglages.xml","string");
-        cmd.add( xmlArg );
+    ValueArg<string> xmlArg("x", "xml", "fichier xml", true, "./reglages.xml",
+                            "string");
+    cmd.add(xmlArg);
 
-        ValueArg<string> logsArg("l","logs","repertoire des logs",true,"/media/ram","string");
-        cmd.add( logsArg );
+    ValueArg<string> logsArg("l", "logs", "repertoire des logs", true,
+                             "/media/ram", "string");
+    cmd.add(logsArg);
 
-        ValueArg<int> portArg("p","port","port pour station sol",true,9000,"int");
-        cmd.add( portArg );
+    ValueArg<int> portArg("p", "port", "port pour station sol", true, 9000,
+                          "int");
+    cmd.add(portArg);
 
-        ValueArg<string> addressArg("a","address","addresse station sol",true,"127.0.0.1","string");
-        cmd.add( addressArg );
+    ValueArg<string> addressArg("a", "address", "addresse station sol", true,
+                                "127.0.0.1", "string");
+    cmd.add(addressArg);
 
-        SwitchArg headlessArg("e","headless","headless mode", false);
-        cmd.add( headlessArg );
+    SwitchArg headlessArg("e", "headless", "headless mode", false);
+    cmd.add(headlessArg);
 
-        cmd.parse( argc, argv );
+    cmd.parse(argc, argv);
 
-        // Get the value parsed by each arg.
-        uav_type=typeArg.getValue();
-        log_path = logsArg.getValue();
-        port=portArg.getValue();
-        xml_file = xmlArg.getValue();
-        name=nameArg.getValue();
-        address=addressArg.getValue();
-        headless=headlessArg.getValue();
+    // Get the value parsed by each arg.
+    uav_type = typeArg.getValue();
+    log_path = logsArg.getValue();
+    port = portArg.getValue();
+    xml_file = xmlArg.getValue();
+    name = nameArg.getValue();
+    address = addressArg.getValue();
+    headless = headlessArg.getValue();
 
-	} catch (ArgException &e)  // catch any exceptions
-	{ cerr << "error: " << e.error() << " for arg " << e.argId() << endl; }
+  } catch (ArgException &e) // catch any exceptions
+  {
+    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
+  }
 }
