Changeset 137 in flair-src for trunk/lib/FlairSensorActuator


Ignore:
Timestamp:
Feb 14, 2017, 3:06:20 PM (8 years ago)
Author:
Sanahuja Guillaume
Message:

singleton manager

Location:
trunk/lib/FlairSensorActuator/src
Files:
50 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairSensorActuator/src/AfroBldc.h

    r15 r137  
    1818namespace flair {
    1919namespace core {
    20 class FrameworkManager;
    2120class I2cPort;
    2221}
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2.h

    r15 r137  
    1818namespace flair {
    1919namespace core {
    20 class FrameworkManager;
    2120class I2cPort;
    2221}
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2_x4_speed.cpp

    r15 r137  
    4040namespace flair {
    4141namespace actuator {
    42 BlCtrlV2_x4_speed::BlCtrlV2_x4_speed(FrameworkManager *parent, string name,
    43                                      I2cPort *i2cport, uint8_t base_address,
     42BlCtrlV2_x4_speed::BlCtrlV2_x4_speed(string name,I2cPort *i2cport, uint8_t base_address,
    4443                                     uint8_t priority)
    45     : Thread(parent, name, priority), IODevice(parent, name) {
     44    : Thread(getFrameworkManager(), name, priority), IODevice(getFrameworkManager(), name) {
    4645  this->i2cport = i2cport;
    4746  slave_address = base_address;
     
    6968
    7069  // station sol
    71   main_tab = new Tab(parent->GetTabWidget(), name);
     70  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    7271  tab = new TabWidget(main_tab->NewRow(), name);
    7372  Tab *sensor_tab = new Tab(tab, "Reglages");
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2_x4_speed.h

    r15 r137  
    2525namespace core {
    2626class cvmatrix;
    27 class FrameworkManager;
    2827class I2cPort;
    2928}
     
    4443
    4544public:
    46   BlCtrlV2_x4_speed(core::FrameworkManager *parent, std::string name,
     45  BlCtrlV2_x4_speed(std::string name,
    4746                    core::I2cPort *i2cport, uint8_t base_address,
    4847                    uint8_t priority);
  • trunk/lib/FlairSensorActuator/src/Bldc.h

    r15 r137  
    1919namespace flair {
    2020namespace core {
    21 class FrameworkManager;
    2221class cvmatrix;
    2322}
  • trunk/lib/FlairSensorActuator/src/Bldc_impl.cpp

    r15 r137  
    2626#include <TabWidget.h>
    2727#include <Tab.h>
    28 #include <FrameworkManager.h>
    2928#include <sstream>
    3029
  • trunk/lib/FlairSensorActuator/src/Camera.cpp

    r128 r137  
    3535namespace sensor {
    3636
    37 Camera::Camera(const FrameworkManager *parent, string name, uint16_t width,
     37Camera::Camera(string name, uint16_t width,
    3838               uint16_t height, cvimage::Type::Format format)
    39     : IODevice(parent, name) {
     39    : IODevice(getFrameworkManager(), name) {
    4040  plot_tab = NULL;
    4141        logFormat=LogFormat::NONE;
     
    4545       
    4646  // station sol
    47   main_tab = new Tab(parent->GetTabWidget(), name);
     47  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4848  tab = new TabWidget(main_tab->NewRow(), name);
    4949  sensor_tab = new Tab(tab, "Setup");
  • trunk/lib/FlairSensorActuator/src/Camera.h

    r128 r137  
    4343  *
    4444  * Construct a Camera.
    45   *
    46   * \param parent parent
     45  * It will be child of the FrameworkManager.
     46        *
    4747  * \param name name
    4848  * \param width width
     
    5050  * \param format image format
    5151  */
    52   Camera(const core::FrameworkManager *parent, std::string name, uint16_t width,
     52  Camera(std::string name, uint16_t width,
    5353         uint16_t height, core::cvimage::Type::Format format);
    5454
  • trunk/lib/FlairSensorActuator/src/EmulatedController.cpp

    r38 r137  
    1313#include "EmulatedController.h"
    1414#include <Controller.h>
    15 #include <FrameworkManager.h>
    1615#include <TcpSocket.h>
    1716#include <Socket.h>
     
    2928namespace flair { namespace sensor {
    3029
    31 EmulatedController::EmulatedController(const FrameworkManager* parent,string name,uint8_t priority) :
    32     TargetController(parent,name,priority) {
     30EmulatedController::EmulatedController(string name,uint8_t priority) :
     31    TargetController(name,priority) {
    3332}
    3433
  • trunk/lib/FlairSensorActuator/src/EmulatedController.h

    r38 r137  
    2121namespace flair {
    2222    namespace core {
    23         class FrameworkManager;
    2423        class cvmatrix;
    2524    }
     
    3938    class EmulatedController : public TargetController {
    4039    public:
    41         EmulatedController(const core::FrameworkManager* parent,std::string name,uint8_t priority=0);
     40        EmulatedController(std::string name,uint8_t priority=0);
    4241        ~EmulatedController();
    4342        enum class ButtonType : uint16_t {
  • trunk/lib/FlairSensorActuator/src/Gx3_25_imu.cpp

    r103 r137  
    2828namespace sensor {
    2929
    30 Gx3_25_imu::Gx3_25_imu(const FrameworkManager *parent, string name,
     30Gx3_25_imu::Gx3_25_imu(string name,
    3131                       SerialPort *serialport, Command_t command,
    3232                       uint8_t priority)
    33     : Imu(parent, name), Thread(parent, name, priority) {
     33    : Imu(name), Thread(getFrameworkManager(), name, priority) {
    3434  pimpl_ = new Gx3_25_imu_impl(this, name, serialport, command, GetGroupBox());
    3535
  • trunk/lib/FlairSensorActuator/src/Gx3_25_imu.h

    r102 r137  
    5050  * \brief Constructor
    5151  *
    52   * Construct a Gx3_25_imu.
     52  * Construct a Gx3_25_imu. It will be child of the FrameworkManager.
    5353  *
    54   * \param parent parent
    5554  * \param name name
    5655  * \param serialport SerialPort
     
    5857  * \param priority priority of the Thread
    5958  */
    60   Gx3_25_imu(const core::FrameworkManager *parent, std::string name,
     59  Gx3_25_imu(std::string name,
    6160             core::SerialPort *serialport, Command_t command, uint8_t priority);
    6261
  • trunk/lib/FlairSensorActuator/src/HokuyoUTM30Lx.cpp

    r15 r137  
    3535namespace sensor {
    3636
    37 HokuyoUTM30Lx::HokuyoUTM30Lx(const FrameworkManager *parent, string name,
     37HokuyoUTM30Lx::HokuyoUTM30Lx(string name,
    3838                             SerialPort *serialport, uint8_t priority)
    39     : LaserRangeFinder(parent, name), Thread(parent, name, priority) {
    40   main_tab = new Tab(parent->GetTabWidget(), name);
     39    : LaserRangeFinder(name), Thread(getFrameworkManager(), name, priority) {
     40  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4141  cvmatrix_descriptor *desc = new cvmatrix_descriptor(1081, 1);
    4242  output = new cvmatrix((IODevice *)this, desc, SignedIntegerType(16));
  • trunk/lib/FlairSensorActuator/src/HokuyoUTM30Lx.h

    r15 r137  
    2424namespace core {
    2525class cvmatrix;
    26 class FrameworkManager;
    2726class SerialPort;
    2827class Mutex;
     
    4746 *
    4847 * Construct a Hokuyo UTM30-Lx.
    49  *
    50  * \param parent parent
     48 * It will be child of the FrameworkManage
     49 *
    5150 * \param name name
    5251 * \param serialport serialport
    5352 * \param priority priority of the Thread
    5453 */
    55   HokuyoUTM30Lx(const core::FrameworkManager *parent, std::string name,
     54  HokuyoUTM30Lx(std::string name,
    5655                core::SerialPort *serialport, uint8_t priority);
    5756  void getMesure(int startStep, int endStep, int clusterCount, int interval,
  • trunk/lib/FlairSensorActuator/src/HostEthController.cpp

    r15 r137  
    4141namespace sensor {
    4242
    43 HostEthController::HostEthController(const FrameworkManager *parent,
    44                                      string name, string _address, int _port,
     43HostEthController::HostEthController(string name, string _address, int _port,
    4544                                     uint32_t period, uint32_t _bitsPerAxis,
    4645                                     uint8_t priority)
    47     : Thread(parent, name, priority), IODevice(parent, name),
    48       tab(new Tab(parent->GetTabWidget(), name)), axisNumber(0),
     46    : Thread(getFrameworkManager(), name, priority), IODevice(getFrameworkManager(), name),
     47      tab(new Tab(getFrameworkManager()->GetTabWidget(), name)), axisNumber(0),
    4948      buttonNumber(0), targetAddress(_address), targetPort(_port),
    5049      bitsPerAxis(_bitsPerAxis), dataFrameBuffer(NULL),
  • trunk/lib/FlairSensorActuator/src/HostEthController.h

    r15 r137  
    2626namespace flair {
    2727namespace core {
    28 class FrameworkManager;
    2928class cvmatrix;
    3029class TcpSocket;
     
    5655class HostEthController : public core::Thread, public core::IODevice {
    5756public:
    58   HostEthController(const core::FrameworkManager *parent, std::string name,
     57  HostEthController(std::string name,
    5958                    std::string address, int port, uint32_t period = 10,
    6059                    uint32_t _bitsPerAxis = 7, uint8_t priority = 0);
  • trunk/lib/FlairSensorActuator/src/Imu.cpp

    r99 r137  
    3333namespace sensor {
    3434
    35 Imu::Imu(const FrameworkManager *parent, string name) : IODevice(parent, name) {
     35Imu::Imu(string name) : IODevice(getFrameworkManager(), name) {
    3636  imuData = new ImuData(this);
    3737
    3838  // station sol
    39   mainTab = new Tab(parent->GetTabWidget(), name);
     39  mainTab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4040  tab = new TabWidget(mainTab->NewRow(), name);
    4141  sensorTab = new Tab(tab, "Reglages");
     
    4444}
    4545
    46 Imu::Imu(const IODevice *parent, std::string name) : IODevice(parent, name) {
     46Imu::Imu(const IODevice *parent,std::string name) : IODevice(parent, name) {
    4747  imuData = new ImuData(this);
    4848  mainTab = NULL;
  • trunk/lib/FlairSensorActuator/src/Imu.h

    r99 r137  
    4949  *
    5050  * Construct an Imu.
     51        * It will be child of the FrameworkManager.
    5152  *
    52   * \param parent parent
    5353  * \param name name
    5454  */
    55   Imu(const core::FrameworkManager *parent, std::string name);
     55  Imu(std::string name);
    5656
    5757  /*!
  • trunk/lib/FlairSensorActuator/src/LaserRangeFinder.cpp

    r15 r137  
    3535namespace sensor {
    3636
    37 LaserRangeFinder::LaserRangeFinder(const FrameworkManager *parent, string name)
    38     : IODevice(parent, name) {
     37LaserRangeFinder::LaserRangeFinder(string name)
     38    : IODevice(getFrameworkManager(), name) {
    3939  cvmatrix_descriptor *desc = new cvmatrix_descriptor(360, 1);
    4040  output = new cvmatrix(this, desc, floatType);
     
    4242
    4343  // station sol
    44   main_tab = new Tab(parent->GetTabWidget(), name);
     44  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4545  tab = new TabWidget(main_tab->NewRow(), name);
    4646  sensor_tab = new Tab(tab, "Reglages");
  • trunk/lib/FlairSensorActuator/src/LaserRangeFinder.h

    r15 r137  
    4242  *
    4343  * Construct a Laser Range Finder.
     44        * It will be child of the FrameworkManager
    4445  *
    45   * \param parent parent
    4646  * \param name name
    4747  */
    48   LaserRangeFinder(const core::FrameworkManager *parent, std::string name);
     48  LaserRangeFinder(std::string name);
    4949  /*!
    5050  * \brief Constructor
  • trunk/lib/FlairSensorActuator/src/Mb800.cpp

    r51 r137  
    2727namespace sensor {
    2828
    29 Mb800::Mb800(const FrameworkManager *parent, string name,
     29Mb800::Mb800(string name,
    3030             SerialPort *serialport, NmeaGps::NMEAFlags_t NMEAFlags,
    3131             uint8_t priority)
    32     : NmeaGps(parent, name, NMEAFlags), Thread(parent, name, priority) {
     32    : NmeaGps(name, NMEAFlags), Thread(getFrameworkManager(), name, priority) {
    3333  this->serialport = serialport;
    3434  serialport->SetRxTimeout(100000000);
  • trunk/lib/FlairSensorActuator/src/Mb800.h

    r51 r137  
    1919namespace flair {
    2020namespace core {
    21 class FrameworkManager;
    2221class SerialPort;
    2322}
     
    3635  *
    3736  * Construct a Mb800.
    38   *
    39   * \param parent parent
     37  * It will be child of the FrameworkManager.
     38        *
    4039  * \param name name
    4140  * \param serialport serialport
     
    4342  * \param priority priority of the Thread
    4443  */
    45   Mb800(const core::FrameworkManager *parent, std::string name,
     44  Mb800(std::string name,
    4645        core::SerialPort *serialport, NmeaGps::NMEAFlags_t NMEAFlags,
    4746        uint8_t priority);
  • trunk/lib/FlairSensorActuator/src/NmeaGps.cpp

    r68 r137  
    4141namespace sensor {
    4242
    43 NmeaGps::NmeaGps(const FrameworkManager *parent, string name, NMEAFlags_t NMEAFlags)
    44     : IODevice(parent, name) {
     43NmeaGps::NmeaGps(string name, NMEAFlags_t NMEAFlags)
     44    : IODevice(getFrameworkManager(), name) {
    4545  this->NMEAFlags = NMEAFlags;
    4646
     
    5454
    5555  // station sol
    56   mainTab = new Tab(parent->GetTabWidget(), name);
     56  mainTab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    5757  tab = new TabWidget(mainTab->NewRow(), name);
    5858  sensorTab = new Tab(tab, "Setup");
  • trunk/lib/FlairSensorActuator/src/NmeaGps.h

    r55 r137  
    5959  *
    6060  * Construct a NmeaGps.
    61   *
    62   * \param parent parent
     61  *     It will be child of the FrameworkManager.
     62        *
    6363  * \param name name
    6464  * \param NMEAFlags NMEA sentances to enable
    6565  */
    66   NmeaGps(const core::FrameworkManager *parent, std::string name,
     66  NmeaGps(std::string name,
    6767      NMEAFlags_t NMEAFlags);
    6868
  • trunk/lib/FlairSensorActuator/src/Novatel.cpp

    r51 r137  
    2727namespace sensor {
    2828
    29 Novatel::Novatel(const FrameworkManager *parent, string name,
     29Novatel::Novatel(string name,
    3030                 SerialPort *serialport, NmeaGps::NMEAFlags_t NMEAFlags,
    3131                 uint8_t priority)
    32     : NmeaGps(parent, name, NMEAFlags), Thread(parent, name, priority) {
     32    : NmeaGps(name, NMEAFlags), Thread(getFrameworkManager(), name, priority) {
    3333  this->serialport = serialport;
    3434}
  • trunk/lib/FlairSensorActuator/src/Novatel.h

    r51 r137  
    3636  *
    3737  * Construct a Novatel.
     38        * It will be child of the FrameworkManager.
    3839  *
    39   * \param parent parent
    4040  * \param name name
    4141  * \param serialport serialport
     
    4343  * \param priority priority of the Thread
    4444  */
    45   Novatel(const core::FrameworkManager *parent, std::string name,
     45  Novatel(std::string name,
    4646          core::SerialPort *serialport, NmeaGps::NMEAFlags_t NMEAFlags,
    4747          uint8_t priority);
  • trunk/lib/FlairSensorActuator/src/Ps3Eye.cpp

    r15 r137  
    1717
    1818#include "Ps3Eye.h"
    19 #include <GroupBox.h>
    20 #include <DoubleSpinBox.h>
    21 #include <CheckBox.h>
    22 #include <GridLayout.h>
    23 #include <cvimage.h>
    24 #include <FrameworkManager.h>
    25 #include <stdio.h>
    2619
    2720using std::string;
    2821using namespace flair::core;
    29 using namespace flair::gui;
    3022
    3123namespace flair {
    3224namespace sensor {
    3325
    34 Ps3Eye::Ps3Eye(const FrameworkManager *parent, string name, int camera_index,
     26Ps3Eye::Ps3Eye(string name, int camera_index,
    3527               uint8_t priority)
    36     : V4LCamera(parent, name, camera_index, 320, 240,
     28    : V4LCamera( name, camera_index, 320, 240,
    3729                cvimage::Type::Format::YUYV, priority) {}
    3830
  • trunk/lib/FlairSensorActuator/src/Ps3Eye.h

    r15 r137  
    1717
    1818namespace flair {
    19 namespace core {
    20 class cvimage;
    21 class FrameworkManager;
    22 }
    23 namespace gui {
    24 class GridLayout;
    25 class DoubleSpinBox;
    26 class CheckBox;
    27 }
    28 }
    29 
    30 namespace flair {
    3119namespace sensor {
    3220/*! \class Ps3Eye
     
    4129  *
    4230  * Construct a Ps3Eye.
     31        * It will be child of the FrameworkManager.
    4332  *
    44   * \param parent parent
    4533  * \param name name
    4634  * \param camera_index index of the camera, ie /dev/videox
    4735  * \param priority priority of the Thread
    4836  */
    49   Ps3Eye(const core::FrameworkManager *parent, std::string name,
     37  Ps3Eye(std::string name,
    5038         int camera_index, uint8_t priority);
    5139
  • trunk/lib/FlairSensorActuator/src/RadioReceiver.cpp

    r15 r137  
    3131namespace sensor {
    3232
    33 RadioReceiver::RadioReceiver(const FrameworkManager *parent, string name,
     33RadioReceiver::RadioReceiver(string name,
    3434                             unsigned int nb_channels)
    35     : IODevice(parent, name) {
     35    : IODevice(getFrameworkManager(), name) {
    3636  is_connected = false;
    3737  this->nb_channels = nb_channels;
     
    4747
    4848  // station sol
    49   main_tab = new Tab(parent->GetTabWidget(), name);
     49  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    5050  tab = new TabWidget(main_tab->NewRow(), name);
    5151  setup_tab = new Tab(tab, "Setup");
  • trunk/lib/FlairSensorActuator/src/RadioReceiver.h

    r15 r137  
    1919namespace flair {
    2020namespace core {
    21 class FrameworkManager;
    2221class cvmatrix;
    2322}
     
    4140  *
    4241  * Construct a RadioReceiver.
     42        * It will be child of the FrameworkManager.
    4343  *
    44   * \param parent parent
    4544  * \param name name
    4645  * \param nb_channels number of supported channels
    4746  */
    48   RadioReceiver(const core::FrameworkManager *parent, std::string name,
     47  RadioReceiver(std::string name,
    4948                unsigned int nb_channels);
    5049
  • trunk/lib/FlairSensorActuator/src/SimuCamera.cpp

    r15 r137  
    1818#include "SimuCamera.h"
    1919#include <FrameworkManager.h>
     20#include <GroupBox.h>
    2021#include <SpinBox.h>
    21 #include <GroupBox.h>
    22 #include <cvimage.h>
     22//#include <cvimage.h>
    2323#include <SharedMem.h>
    2424#include <sstream>
     
    3232namespace sensor {
    3333
    34 SimuCamera::SimuCamera(const FrameworkManager *parent, string name,
     34SimuCamera::SimuCamera(string name,
    3535                       uint16_t width, uint16_t height, uint8_t channels,
    3636                       uint32_t dev_id, uint8_t priority)
    37     : Thread(parent, name, priority),
    38       Camera(parent, name, width, height, cvimage::Type::Format::BGR) {
     37    : Thread(getFrameworkManager(), name, priority),
     38      Camera(name, width, height, cvimage::Type::Format::BGR) {
    3939  data_rate =
    4040      new SpinBox(GetGroupBox()->NewRow(), "data rate", " Hz", 1, 100, 1, 50);
     
    5252SimuCamera::SimuCamera(const IODevice *parent, string name, uint16_t width,
    5353                       uint16_t height, uint8_t channels, uint32_t dev_id)
    54     : Thread(parent, name, 0), Camera(parent, name) {
     54    : Thread(parent, name, 0), Camera(parent,name) {
    5555  data_rate = NULL;
    5656
  • trunk/lib/FlairSensorActuator/src/SimuCamera.h

    r15 r137  
    3939  *
    4040  * Construct a SimuCamera. Control part.
     41        * It will be child of the FrameworkManager.
    4142  *
    42   * \param parent parent
    4343  * \param name name
    4444  * \param width width
     
    4848  * \param priority priority of the Thread
    4949  */
    50   SimuCamera(const core::FrameworkManager *parent, std::string name,
     50  SimuCamera(std::string name,
    5151             uint16_t width, uint16_t height, uint8_t channels, uint32_t dev_id,
    5252             uint8_t priority);
  • trunk/lib/FlairSensorActuator/src/SimuGps.cpp

    r68 r137  
    3838namespace sensor {
    3939
    40 SimuGps::SimuGps(const FrameworkManager *parent, string name,
     40SimuGps::SimuGps(string name,
    4141                 NmeaGps::NMEAFlags_t NMEAFlags, uint32_t deviceId,uint8_t priority)
    42     : NmeaGps(parent, name, NMEAFlags),Thread(parent, name, priority) {
     42    : NmeaGps(name, NMEAFlags),Thread(getFrameworkManager(), name, priority) {
    4343
    4444  dataRate = new SpinBox(GetGroupBox()->NewRow(), "data rate", " Hz", 1, 500, 1, 200);
  • trunk/lib/FlairSensorActuator/src/SimuGps.h

    r68 r137  
    1919namespace flair {
    2020  namespace core {
    21     class FrameworkManager;
    2221    class SharedMem;
    2322  }
     
    4039  *
    4140  * Construct a simulation GPS. Control part.
    42   *
    43   * \param parent parent
     41  * It will be child of the FrameworkManager.
     42        *
    4443  * \param name name
    4544  * \param NMEAFlags NMEA sentances to enable
     
    4746  * \param priority priority of the Thread
    4847  */
    49   SimuGps(const core::FrameworkManager *parent, std::string name,
     48  SimuGps(std::string name,
    5049          NmeaGps::NMEAFlags_t NMEAFlags, uint32_t deviceId,uint8_t priority);
    5150
  • trunk/lib/FlairSensorActuator/src/SimuImu.cpp

    r55 r137  
    3434namespace sensor {
    3535
    36 SimuImu::SimuImu(const FrameworkManager *parent, string name, uint32_t dev_id,
     36SimuImu::SimuImu(string name, uint32_t dev_id,
    3737                 uint8_t priority)
    38     : Imu(parent, name), Thread(parent, name, priority) {
     38    : Imu(name), Thread(getFrameworkManager(), name, priority) {
    3939  dataRate =
    4040      new SpinBox(GetGroupBox()->NewRow(), "data rate", " Hz", 1, 500, 1, 200);
     
    4848
    4949SimuImu::SimuImu(const IODevice *parent, string name, uint32_t dev_id)
    50     : Imu(parent, name), Thread(parent, name, 0) {
     50    : Imu(parent,name), Thread(parent, name, 0) {
    5151  dataRate = NULL;
    5252
  • trunk/lib/FlairSensorActuator/src/SimuImu.h

    r55 r137  
    3939  *
    4040  * Construct a SimuImu. Control part.
     41        * It will be child of the FrameworkManager.
    4142  *
    42   * \param parent parent
    4343  * \param name name
    4444  * \param dev_id device id
    4545  * \param priority priority of the Thread
    4646  */
    47   SimuImu(const core::FrameworkManager *parent, std::string name,
     47  SimuImu(std::string name,
    4848          uint32_t dev_id, uint8_t priority);
    4949
  • trunk/lib/FlairSensorActuator/src/SimuLaser.cpp

    r15 r137  
    3232namespace sensor {
    3333
    34 SimuLaser::SimuLaser(const FrameworkManager *parent, string name,
     34SimuLaser::SimuLaser(string name,
    3535                     uint32_t dev_id, uint8_t priority)
    36     : Thread(parent, name, priority), LaserRangeFinder(parent, name) {
     36    : Thread(getFrameworkManager(), name, priority), LaserRangeFinder(name) {
    3737  data_rate =
    3838      new SpinBox(GetGroupBox()->NewRow(), "data rate", " Hz", 1, 500, 1, 50);
  • trunk/lib/FlairSensorActuator/src/SimuLaser.h

    r15 r137  
    3838  *
    3939  * Construct a SimuUs. Control part.
     40        * It will be child of the FrameworkManager.
    4041  *
    41   * \param parent parent
    4242  * \param name name
    4343  * \param dev_id device id
    4444  * \param priority priority of the Thread
    4545  */
    46   SimuLaser(const core::FrameworkManager *parent, std::string name,
     46  SimuLaser(std::string name,
    4747            uint32_t dev_id, uint8_t priority);
    4848
  • trunk/lib/FlairSensorActuator/src/SimuUs.cpp

    r15 r137  
    3232namespace sensor {
    3333
    34 SimuUs::SimuUs(const FrameworkManager *parent, string name, uint32_t dev_id,
     34SimuUs::SimuUs(string name, uint32_t dev_id,
    3535               uint8_t priority)
    36     : Thread(parent, name, priority), UsRangeFinder(parent, name) {
     36    : Thread(getFrameworkManager(), name, priority), UsRangeFinder( name) {
    3737  data_rate =
    3838      new SpinBox(GetGroupBox()->NewRow(), "data rate", " Hz", 1, 500, 1, 50);
     
    4444
    4545SimuUs::SimuUs(const IODevice *parent, string name, uint32_t dev_id)
    46     : Thread(parent, name, 0), UsRangeFinder(parent, name) {
     46    : Thread(parent, name, 0), UsRangeFinder(parent,name) {
    4747  data_rate = NULL;
    4848
  • trunk/lib/FlairSensorActuator/src/SimuUs.h

    r15 r137  
    3838  *
    3939  * Construct a SimuUs. Control part.
     40        * It will be child of the FrameworkManager.
    4041  *
    41   * \param parent parent
    4242  * \param name name
    4343  * \param dev_id device id
    4444  * \param priority priority of the Thread
    4545  */
    46   SimuUs(const core::FrameworkManager *parent, std::string name,
     46  SimuUs(std::string name,
    4747         uint32_t dev_id, uint8_t priority);
    4848
  • trunk/lib/FlairSensorActuator/src/Srf08.cpp

    r51 r137  
    3333namespace sensor {
    3434
    35 Srf08::Srf08(const FrameworkManager *parent, string name, I2cPort *i2cport,
     35Srf08::Srf08(string name, I2cPort *i2cport,
    3636             uint16_t address, uint8_t priority)
    37     : Thread(parent, name, priority), UsRangeFinder(parent, name) {
     37    : Thread(getFrameworkManager(), name, priority), UsRangeFinder(name) {
    3838  is_init = false;
    3939
  • trunk/lib/FlairSensorActuator/src/Srf08.h

    r51 r137  
    1919namespace flair {
    2020namespace core {
    21 class FrameworkManager;
    2221class I2cPort;
    2322}
    2423namespace gui {
    2524class SpinBox;
    26 ;
    2725}
    2826}
     
    4139  *
    4240  * Construct a SRF08 sensor
     41        * It will be child of the FrameworkManager.
    4342  *
    44   * \param parent parent
    4543  * \param name name
    4644  * \param i2cport i2c port
     
    4846  * \param priority priority of the Thread
    4947  */
    50   Srf08(const core::FrameworkManager *parent, std::string name,
     48  Srf08(std::string name,
    5149        core::I2cPort *i2cport, uint16_t address, uint8_t priority);
    5250
  • trunk/lib/FlairSensorActuator/src/TargetController.cpp

    r42 r137  
    3434namespace sensor {
    3535
    36 TargetController::TargetController(const FrameworkManager* parent,string name,uint8_t priority) :
    37     Thread(parent,name,priority),IODevice(parent,name) {
     36TargetController::TargetController(string name,uint8_t priority) :
     37    Thread(getFrameworkManager(),name,priority),IODevice(getFrameworkManager(),name) {
    3838    main_tab=new Tab(getFrameworkManager()->GetTabWidget(),name);
    3939    TabWidget* tab=new TabWidget(main_tab->NewRow(),name);
  • trunk/lib/FlairSensorActuator/src/TargetController.h

    r15 r137  
    4949class TargetController : public core::Thread, public core::IODevice {
    5050public:
    51   TargetController(const core::FrameworkManager *parent, std::string name,
    52                    uint8_t priority = 0);
     51  TargetController(std::string name,uint8_t priority = 0);
    5352  ~TargetController();
    5453  // void DrawUserInterface();
  • trunk/lib/FlairSensorActuator/src/TargetEthController.cpp

    r38 r137  
    3636namespace sensor {
    3737
    38 TargetEthController::TargetEthController(const FrameworkManager *parent,
    39                                          string name, uint16_t _port,
     38TargetEthController::TargetEthController(string name, uint16_t _port,
    4039                                         uint8_t priority)
    41     : TargetController(parent, name, priority), listeningPort(_port),
     40    : TargetController(name, priority), listeningPort(_port),
    4241      receiveCurrentPosition(0) {
    4342  const bool blocking = true;
    4443  listeningSocket =
    45       new TcpSocket(parent, "TEC_listening_socket", blocking, blocking);
     44      new TcpSocket(getFrameworkManager(), "TEC_listening_socket", blocking, blocking);
    4645  dataSocket =
    47       new Socket(parent, "TEC_data_socket", _port + 1); // receiving side
     46      new Socket(getFrameworkManager(), "TEC_data_socket", _port + 1); // receiving side
    4847}
    4948
  • trunk/lib/FlairSensorActuator/src/TargetEthController.h

    r16 r137  
    4747class TargetEthController : public TargetController {
    4848public:
    49   TargetEthController(const core::FrameworkManager *parent, std::string name,
     49  TargetEthController(std::string name,
    5050                      uint16_t port, uint8_t priority = 0);
    5151  ~TargetEthController();
  • trunk/lib/FlairSensorActuator/src/UsRangeFinder.cpp

    r15 r137  
    3232namespace sensor {
    3333
    34 UsRangeFinder::UsRangeFinder(const FrameworkManager *parent, string name)
    35     : IODevice(parent, name) {
     34UsRangeFinder::UsRangeFinder(string name)
     35    : IODevice(getFrameworkManager(), name) {
    3636  plot_tab = NULL;
    3737
     
    4242
    4343  // station sol
    44   main_tab = new Tab(parent->GetTabWidget(), name);
     44  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4545  tab = new TabWidget(main_tab->NewRow(), name);
    4646  sensor_tab = new Tab(tab, "Reglages");
  • trunk/lib/FlairSensorActuator/src/UsRangeFinder.h

    r15 r137  
    4444  *
    4545  * Construct a UsRangeFinder. Control part.
    46   *
    47   * \param parent parent
     46        * It will be child of the FrameworkManager.
     47        *
    4848  * \param name name
    4949  */
    50   UsRangeFinder(const core::FrameworkManager *parent, std::string name);
     50  UsRangeFinder(std::string name);
    5151
    5252  /*!
  • trunk/lib/FlairSensorActuator/src/V4LCamera.cpp

    r124 r137  
    2020#include <DoubleSpinBox.h>
    2121#include <CheckBox.h>
    22 #include <GridLayout.h>
    2322#include <Label.h>
    2423#include <cvimage.h>
     
    3332namespace sensor {
    3433
    35 V4LCamera::V4LCamera(const FrameworkManager *parent, string name,
     34V4LCamera::V4LCamera(string name,
    3635                     uint8_t camera_index, uint16_t width, uint16_t height,
    3736                     cvimage::Type::Format format, uint8_t priority)
    38     : Thread(parent, name, priority),
    39       Camera(parent, name, width, height, format) {
     37    : Thread(getFrameworkManager(), name, priority),
     38      Camera(name, width, height, format) {
    4039  capture = cvCaptureFromCAM(camera_index); // a mettre apres l'init dsp
    4140
  • trunk/lib/FlairSensorActuator/src/V4LCamera.h

    r15 r137  
    2121namespace core {
    2222class cvimage;
    23 class FrameworkManager;
    2423}
    2524namespace gui {
    26 class GridLayout;
    2725class DoubleSpinBox;
    2826class CheckBox;
     
    4341  *
    4442  * Construct a Camera.
     43        * It will be child of the FrameworkManager.
    4544  *
    46   * \param parent parent
    4745  * \param name name
    4846  * \param camera_index camera index
     
    5250  * \param priority priority of the Thread
    5351  */
    54   V4LCamera(const core::FrameworkManager *parent, std::string name,
     52  V4LCamera(std::string name,
    5553            uint8_t camera_index, uint16_t width, uint16_t height,
    5654            core::cvimage::Type::Format format, uint8_t priority);
Note: See TracChangeset for help on using the changeset viewer.