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


Ignore:
Timestamp:
Feb 7, 2018, 5:49:27 PM (7 years ago)
Author:
Sanahuja Guillaume
Message:

matrix

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

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairSensorActuator/src/AfroBldc_impl.cpp

    r15 r214  
    2222#include <SpinBox.h>
    2323#include <Label.h>
    24 #include <cvmatrix.h>
     24#include <Matrix.h>
    2525#include <string.h>
    2626
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2_impl.cpp

    r15 r214  
    2323#include <SpinBox.h>
    2424#include <Label.h>
    25 #include <cvmatrix.h>
     25#include <Matrix.h>
    2626#include <string.h>
    2727
     
    9696
    9797  // on prend une fois pour toute le mutex et on fait des accès directs
    98   cvmatrix *output = self->output;
     98  Matrix *output = self->output;
    9999  output->GetMutex();
    100100  for (int i = 0; i < nb_mot; i++)
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2_x4_speed.cpp

    r170 r214  
    2525#include <ComboBox.h>
    2626#include <PushButton.h>
    27 #include <cvmatrix.h>
     27#include <Matrix.h>
    2828#include <Mutex.h>
    2929#include <FrameworkManager.h>
     
    119119  pas->AddItem("inverse");
    120120
    121   input = new cvmatrix((IODevice *)this, 8, 1, floatType);
     121  input = new Matrix((IODevice *)this, 8, 1, floatType);
    122122
    123123  cvmatrix_descriptor *desc = new cvmatrix_descriptor(4, 2);
     
    131131  desc->SetElementName(2, 1, "cons avant droite");
    132132  desc->SetElementName(3, 1, "cons arriere gauche");
    133   output = new cvmatrix((IODevice *)this, desc, floatType);
     133  output = new Matrix((IODevice *)this, desc, floatType);
    134134  delete desc;
    135135 
  • trunk/lib/FlairSensorActuator/src/BlCtrlV2_x4_speed.h

    r137 r214  
    2424namespace flair {
    2525namespace core {
    26 class cvmatrix;
     26class Matrix;
    2727class I2cPort;
    2828}
     
    9797
    9898  // matrix
    99   core::cvmatrix *input;
    100   core::cvmatrix *output;
     99  core::Matrix *input;
     100  core::Matrix *output;
    101101
    102102  int tested_motor;
  • trunk/lib/FlairSensorActuator/src/Bldc.cpp

    r157 r214  
    1818#include "Bldc.h"
    1919#include "Bldc_impl.h"
    20 #include <cvmatrix.h>
     20#include <Matrix.h>
    2121#include <DoubleSpinBox.h>
    2222#include <sstream>
     
    5353  }
    5454
    55   output = new cvmatrix(this, desc, floatType);
     55  output = new Matrix(this, desc, floatType);
    5656  delete desc;
    5757  AddDataToLog(output);
     
    8181uint8_t Bldc::MotorsCount(void) const { return pimpl_->motors_count; }
    8282
    83 cvmatrix *Bldc::Output(void) const { return output; }
     83Matrix *Bldc::Output(void) const { return output; }
    8484
    8585bool Bldc::AreEnabled(void) const { return pimpl_->are_enabled; }
  • trunk/lib/FlairSensorActuator/src/Bldc.h

    r170 r214  
    1919namespace flair {
    2020namespace core {
    21 class cvmatrix;
     21class Matrix;
    2222}
    2323namespace gui {
     
    9696  *
    9797  */
    98   core::cvmatrix *Output(void) const;
     98  core::Matrix *Output(void) const;
    9999
    100100  /*!
     
    161161
    162162protected:
    163   core::cvmatrix *output;
     163  core::Matrix *output;
    164164
    165165private:
  • trunk/lib/FlairSensorActuator/src/Bldc_impl.cpp

    r137 r214  
    2020#include <GroupBox.h>
    2121#include <DoubleSpinBox.h>
    22 #include <cvmatrix.h>
     22#include <Matrix.h>
    2323#include <Label.h>
    2424#include <PushButton.h>
     
    110110
    111111void Bldc_impl::UpdateFrom(const io_data *data) {
    112   cvmatrix *input = (cvmatrix *)data;
     112  Matrix *input = (Matrix *)data;
    113113  bool is_motor_running = false;
    114114
  • trunk/lib/FlairSensorActuator/src/Camera.cpp

    r169 r214  
    119119                if(logFormat==LogFormat::JPG) {
    120120                        data->GetMutex();
    121                         IplImage *img=((cvimage*)data)->img;
     121      //IplImage *img=((cvimage*)data)->img;
     122      const cvimage* input = dynamic_cast<const cvimage*>(data);
     123      if (!input) {
     124          Warn("casting %s to cvimage failed\n",data->ObjectName().c_str());
     125          return;
     126      }
     127                        IplImage *img=input->img;
     128     
    122129                        string filename=getFrameworkManager()->GetLogPath()+"/"+ObjectName()+"_"+std::to_string(data->DataTime())+".jpg";
    123130                        switch(((cvimage*)data)->GetDataType().GetFormat()) {
  • trunk/lib/FlairSensorActuator/src/EmulatedController.cpp

    r202 r214  
    1717#include <cstring>
    1818#include <string>
    19 #include <cvmatrix.h>
     19#include <Matrix.h>
    2020#include <stdexcept>
    2121
     
    4646}
    4747
    48 template<typename T> void EmulatedController::fillVectorNoMutex(cvmatrix &vector,T data[],unsigned int size) {
     48template<typename T> void EmulatedController::fillVectorNoMutex(Matrix &vector,T data[],unsigned int size) {
    4949    for (unsigned int i=0; i<size; i++) {
    5050        vector.SetValueNoMutex(i,0,data[i]);
     
    5252}
    5353
    54 void EmulatedController::fillVectorNoMutex(cvmatrix &destination,cvmatrix &source,unsigned int size) {
     54void EmulatedController::fillVectorNoMutex(Matrix &destination,Matrix &source,unsigned int size) {
    5555    for (unsigned int i=0; i<size; i++) {
    5656        destination.SetValueNoMutex(i,0,source.Value(i,0));
     
    6969
    7070void EmulatedController::AddStep(unsigned int durationMs,string description,uint16_t buttonPressed, float leftAxisX, float leftAxisY, float rightAxisX, float rightAxisY) {
    71     cvmatrix *axisMatrix=new cvmatrix((IODevice *)this,4,1,floatType);
     71    Matrix *axisMatrix=new Matrix((IODevice *)this,4,1,floatType);
    7272    axisMatrix->SetValueNoMutex(0,0,leftAxisX);
    7373    axisMatrix->SetValueNoMutex(1,0,leftAxisY);
     
    7575    axisMatrix->SetValueNoMutex(3,0,rightAxisY);
    7676
    77     cvmatrix *buttonMatrix=new cvmatrix((IODevice *)this,16,1,SignedIntegerType(8));
     77    Matrix *buttonMatrix=new Matrix((IODevice *)this,16,1,SignedIntegerType(8));
    7878    if (buttonPressed&(uint16_t)ButtonType::start) buttonMatrix->SetValueNoMutex(0,0,1);
    7979    if (buttonPressed&(uint16_t)ButtonType::select) buttonMatrix->SetValueNoMutex(1,0,1);
     
    9898}
    9999
    100 void EmulatedController::ComputeControllerData(DataType dataType, cvmatrix &data) {
     100void EmulatedController::ComputeControllerData(DataType dataType, Matrix &data) {
    101101    static Time startStepTime=GetTime();
    102102
     
    130130}
    131131
    132 void EmulatedController::AcquireAxisData(core::cvmatrix &axis) {
     132void EmulatedController::AcquireAxisData(core::Matrix &axis) {
    133133    ComputeControllerData(DataType::axis,axis);
    134134}
    135135
    136 void EmulatedController::AcquireButtonData(core::cvmatrix &button) {
     136void EmulatedController::AcquireButtonData(core::Matrix &button) {
    137137    ComputeControllerData(DataType::button,button);
    138138}
  • trunk/lib/FlairSensorActuator/src/EmulatedController.h

    r137 r214  
    2121namespace flair {
    2222    namespace core {
    23         class cvmatrix;
     23        class Matrix;
    2424    }
    2525    namespace gui {
     
    5252        bool ProcessMessage(core::Message *msg);
    5353        bool IsDataFrameReady();
    54         void AcquireAxisData(core::cvmatrix &axis); //responsible for getting the axis data from the hardware
    55         void AcquireButtonData(core::cvmatrix &button); //responsible for getting the button data from the hardware
     54        void AcquireAxisData(core::Matrix &axis); //responsible for getting the axis data from the hardware
     55        void AcquireButtonData(core::Matrix &button); //responsible for getting the button data from the hardware
    5656        bool ControllerInitialization();
    5757
    5858    private:
    5959        enum class DataType { axis,button };
    60         void ComputeControllerData(DataType dataType, core::cvmatrix &data);
    61         template<typename T> void fillVectorNoMutex(core::cvmatrix &vector,T data[],unsigned int size);
    62         void fillVectorNoMutex(core::cvmatrix &destination,core::cvmatrix &source,unsigned int size);
     60        void ComputeControllerData(DataType dataType, core::Matrix &data);
     61        template<typename T> void fillVectorNoMutex(core::Matrix &vector,T data[],unsigned int size);
     62        void fillVectorNoMutex(core::Matrix &destination,core::Matrix &source,unsigned int size);
    6363        struct StepData {
    6464            unsigned int durationMs; //milliseconds
    65             core::cvmatrix *axisData;
    66             core::cvmatrix *buttonData;
     65            core::Matrix *axisData;
     66            core::Matrix *buttonData;
    6767            std::string description;
    6868            void Print();
  • trunk/lib/FlairSensorActuator/src/HokuyoUTM30Lx.cpp

    r170 r214  
    2121#include <FrameworkManager.h>
    2222#include <RangeFinderPlot.h>
    23 #include <cvmatrix.h>
     23#include <Matrix.h>
    2424#include <Tab.h>
    2525#include <sstream>
     
    4040  main_tab = new Tab(getFrameworkManager()->GetTabWidget(), name);
    4141  cvmatrix_descriptor *desc = new cvmatrix_descriptor(1081, 1);
    42   output = new cvmatrix((IODevice *)this, desc, SignedIntegerType(16));
     42  output = new Matrix((IODevice *)this, desc, SignedIntegerType(16));
    4343  delete desc;
    4444
     
    246246#endif
    247247}
    248 cvmatrix *HokuyoUTM30Lx::getDatas() { return output; }
     248Matrix *HokuyoUTM30Lx::getDatas() { return output; }
    249249
    250250void HokuyoUTM30Lx::UseDefaultPlot(void) {
  • trunk/lib/FlairSensorActuator/src/HokuyoUTM30Lx.h

    r170 r214  
    2323namespace flair {
    2424namespace core {
    25 class cvmatrix;
     25class Matrix;
    2626class SerialPort;
    2727class Mutex;
     
    5656  void getMesure(int startStep, int endStep, int clusterCount, int interval,
    5757                 int scanNumber = 0);
    58   core::cvmatrix *getDatas(void);
     58  core::Matrix *getDatas(void);
    5959
    6060  /*!
     
    7878
    7979  // matrix
    80   core::cvmatrix *output;
     80  core::Matrix *output;
    8181
    8282  std::queue<std::string> bufRet;
  • trunk/lib/FlairSensorActuator/src/HostEthController.cpp

    r178 r214  
    1818#include "HostEthController.h"
    1919#include <Controller.h>
    20 #include <cvmatrix.h>
     20#include <Matrix.h>
    2121#include <Tab.h>
    2222#include <TabWidget.h>
  • trunk/lib/FlairSensorActuator/src/HostEthController.h

    r178 r214  
    2626namespace flair {
    2727namespace core {
    28 class cvmatrix;
     28class Matrix;
    2929class TcpSocket;
    3030class UdpSocket;
     
    8181  GetAxisData() = 0; // responsible for getting the axis data from the hardware
    8282  unsigned int axisNumber;
    83   core::cvmatrix *axis;
     83  core::Matrix *axis;
    8484  gui::DataPlot1D **axisPlot;
    8585  uint32_t bitsPerAxis;
     
    9090                                    // from the hardware
    9191  unsigned int buttonNumber;
    92   core::cvmatrix *button;
     92  core::Matrix *button;
    9393  uint8_t buttonOffset;
    9494  bool meaningfulDataAvailable;
  • trunk/lib/FlairSensorActuator/src/LaserRangeFinder.cpp

    r148 r214  
    1717
    1818#include "LaserRangeFinder.h"
    19 #include <cvmatrix.h>
     19#include <Matrix.h>
    2020#include <Tab.h>
    2121#include <TabWidget.h>
     
    3838    : IODevice(getFrameworkManager(), name) {
    3939  cvmatrix_descriptor *desc = new cvmatrix_descriptor(360, 1);
    40   output = new cvmatrix(this, desc, floatType);
     40  output = new Matrix(this, desc, floatType);
    4141  delete desc;
    4242  AddDataToLog(output);
  • trunk/lib/FlairSensorActuator/src/LaserRangeFinder.h

    r170 r214  
    1919namespace core {
    2020class FrameworkManager;
    21 class cvmatrix;
     21class Matrix;
    2222}
    2323namespace gui {
     
    102102      * \return output matrix
    103103      */
    104   core::cvmatrix *output;
     104  core::Matrix *output;
    105105
    106106  /*!
  • trunk/lib/FlairSensorActuator/src/NmeaGps.cpp

    r206 r214  
    176176
    177177  int result;
    178 Printf("%s\n",frame);
    179 Printf("%x %x\n",&parser,parser.buffer);
    180178  result = nmea_parse(&parser, frame, frame_size, &info);
    181   Printf("%x %x\n",&parser,parser.buffer);
     179 
    182180  if (result != 1) {
    183181    Warn("unrecognized nmea sentence: %s\n",frame);
    184182    return;
    185183  }
    186 Printf("3\n");
    187 Printf("%x %x\n",&parser,parser.buffer);
     184
    188185  result = nmea_parse_GPGGA(frame, frame_size, &pack);
    189 Printf("%x %x\n",&parser,parser.buffer);
     186
    190187  if (result == 1) {
    191     Printf("%x %x\n",&parser,parser.buffer);
    192188    nmea_info2pos(&info, &pos);
    193      Printf("%x %x\n",&parser,parser.buffer);
    194189   //  Printf("nb:%i fix:%i lat:%f long:%f alt:%f vel:%f angle:%f\n",pack.satinuse,pack.sig,info.lat,info.lon,info.elv,info.speed*1000./3600.,info.direction);
    195190//Printf("lat:%f long:%f\n",pos.lat,pos.lon);
  • trunk/lib/FlairSensorActuator/src/RadioReceiver.cpp

    r157 r214  
    2020#include <TabWidget.h>
    2121#include <FrameworkManager.h>
    22 #include <cvmatrix.h>
     22#include <Matrix.h>
    2323#include <sstream>
    2424
     
    4444    desc->SetElementName(i, 0, channel_name.str());
    4545  }
    46   output = new cvmatrix(this, desc, floatType, name);
     46  output = new Matrix(this, desc, floatType, name);
    4747  delete desc;
    4848
  • trunk/lib/FlairSensorActuator/src/RadioReceiver.h

    r137 r214  
    1919namespace flair {
    2020namespace core {
    21 class cvmatrix;
     21class Matrix;
    2222}
    2323namespace gui {
     
    8787  void UpdateFrom(const core::io_data *data){};
    8888
    89   core::cvmatrix *output;
     89  core::Matrix *output;
    9090  bool is_connected;
    9191  unsigned int nb_channels;
  • trunk/lib/FlairSensorActuator/src/SimuBldc.cpp

    r158 r214  
    2121#include <GroupBox.h>
    2222#include <SharedMem.h>
    23 #include <cvmatrix.h>
     23#include <Matrix.h>
    2424#include <sstream>
     25#include <string.h>
    2526
    2627using std::string;
     
    3637    : Bldc(parent, layout, name, motors_count) {
    3738  shmem =
    38       new SharedMem(this, ShMemName(modelId, deviceId), motors_count * sizeof(float));
     39      new SharedMem(this, ShMemName(modelId, deviceId), motors_count * sizeof(float)+sizeof(Time));
    3940
    4041  GroupBox *groupbox = new GroupBox(layout->NewRow(), "simubldc");
    4142  k = new DoubleSpinBox(groupbox->NewRow(), "k driver:", 0, 10000, 1);
    4243 
     44  buf=(char*)malloc(motors_count * sizeof(float)+sizeof(Time));
     45  if(buf==NULL) {
     46    Err("error creating buffer\n");
     47    return;
     48  }
    4349  SetIsReady(true);
    4450}
     
    4854    : Bldc(parent, name, motors_count) {
    4955  shmem =
    50       new SharedMem(this, ShMemName(modelId, deviceId), motors_count * sizeof(float));
     56      new SharedMem(this, ShMemName(modelId, deviceId), motors_count * sizeof(float)+sizeof(Time));
     57     
     58  buf=(char*)malloc(motors_count * sizeof(float)+sizeof(Time));
     59  if(buf==NULL) {
     60    Err("error creating buffer\n");
     61    return;
     62  }
     63 
     64  // reset values
     65  float *values=(float*)buf;
     66  for (int i = 0; i < motors_count; i++) values[i] = 0;
     67  Time time=GetTime();
     68  memcpy(buf+motors_count * sizeof(float),&time,sizeof(Time));
    5169
    52   // reset values
    53   float values[motors_count];
    54   for (int i = 0; i < motors_count; i++)
    55     values[i] = 0;
    56 
    57   shmem->Write((char *)&values, motors_count * sizeof(float));
     70  shmem->Write(buf, motors_count * sizeof(float)+sizeof(Time));
    5871 
    5972  SetIsReady(true);
    6073}
    6174
    62 SimuBldc::~SimuBldc() {}
     75SimuBldc::~SimuBldc() {
     76  if(buf!=NULL) free(buf);
     77}
    6378
    6479string SimuBldc::ShMemName(uint32_t modelId,uint32_t deviceId) {
     
    6984
    7085void SimuBldc::SetMotors(float *value) {
    71   float values[MotorsCount()];
     86  float *values=(float*)buf;
     87  for (int i = 0; i < MotorsCount(); i++) values[i] = k->Value() * value[i];
     88  Time time=GetTime();
     89  memcpy(buf+MotorsCount() * sizeof(float),&time,sizeof(Time));
    7290
    73   for (int i = 0; i < MotorsCount(); i++)
    74     values[i] = k->Value() * value[i];
    75 
    76   shmem->Write((char *)&values, MotorsCount() * sizeof(float));
     91  shmem->Write(buf, MotorsCount() * sizeof(float)+sizeof(Time));
    7792
    7893  // on prend une fois pour toute le mutex et on fait des accès directs
    7994  output->GetMutex();
    80   for (int i = 0; i < MotorsCount(); i++)
     95  for (int i = 0; i < MotorsCount(); i++) {
    8196    output->SetValueNoMutex(i, 0, values[i]);
     97  }
    8298  output->ReleaseMutex();
    8399}
    84100
    85 void SimuBldc::GetSpeeds(float *value) const {
    86   float values[MotorsCount()];
    87   shmem->Read((char *)&values, MotorsCount() * sizeof(float));
     101void SimuBldc::GetSpeeds(float *value,Time* time) const {
     102  float *values=(float*)buf;
     103  shmem->Read(buf, MotorsCount() * sizeof(float)+sizeof(Time));
     104  memcpy(time,buf+MotorsCount() * sizeof(float),sizeof(Time));
    88105
    89   for (int i = 0; i < MotorsCount(); i++)
     106  for (int i = 0; i < MotorsCount(); i++) {
    90107    value[i] = values[i];
     108  }
    91109}
    92110
  • trunk/lib/FlairSensorActuator/src/SimuBldc.h

    r158 r214  
    2020class SharedMem;
    2121class IODevice;
    22 class cvmatrix;
     22class Matrix;
    2323}
    2424namespace gui {
     
    7878  *
    7979  * \param value array to store motors speeds
     80  * \param time time when shared memory was written
    8081  */
    81   void GetSpeeds(float *value) const;
     82  void GetSpeeds(float *value,core::Time* time) const;
    8283
    8384  /*!
     
    113114  core::SharedMem *shmem;
    114115  gui::DoubleSpinBox *k;
     116  char *buf;
     117
    115118};
    116119} // end namespace actuator
  • trunk/lib/FlairSensorActuator/src/SimuGps.cpp

    r206 r214  
    2525#include <GroupBox.h>
    2626#include <Euler.h>
    27 #include <cvmatrix.h>
     27#include <Matrix.h>
    2828#include <sstream>
    2929#include "geodesie.h"
     
    8080void SimuGps::UpdateFrom(const io_data *data) {
    8181  if (data != NULL) {
    82     cvmatrix *input = (cvmatrix *)data;
     82    Matrix *input = (Matrix *)data;
    8383    gps_states_t state;
    8484
     
    109109  vtg.spk_k='K';
    110110  vtg.spn_n='N';
     111  gga.elv_units='M';
     112  gga.diff_units='M';
    111113
    112114  if (dataRate == NULL) {
     
    152154    gga.satinuse=numberOfSatellites->Value();
    153155
    154     nmea_gen_GPGGA(buf,sizeof(buf),&gga);
    155     Printf("1\n");
    156     parseFrame(buf,sizeof(buf));
    157 
     156    int size=nmea_gen_GPGGA(buf,sizeof(buf),&gga);
     157    parseFrame(buf,size);
     158   
    158159    vtg.dir=90-Euler::ToDegree(atan2f(state.vn,state.ve));
    159160    vtg.spk=sqrtf(state.ve*state.ve+state.vn*state.vn)*3600./1000.;
    160     nmea_gen_GPVTG(buf,sizeof(buf),&vtg);
    161     Printf("2\n");
    162     parseFrame(buf,sizeof(buf));
     161    size=nmea_gen_GPVTG(buf,sizeof(buf),&vtg);
     162    parseFrame(buf,size);
    163163  }
    164164
  • trunk/lib/FlairSensorActuator/src/SimuImu.cpp

    r202 r214  
    2121#include <SpinBox.h>
    2222#include <GroupBox.h>
    23 #include <cvmatrix.h>
     23#include <Matrix.h>
    2424#include <SharedMem.h>
    2525#include <AhrsData.h>
     
    7070void SimuImu::UpdateFrom(const io_data *data) {
    7171  if (data != NULL) {
    72     cvmatrix *input = (cvmatrix *)data;
     72    Matrix *input = (Matrix *)data;
    7373    imu_states_t state;
    7474
  • trunk/lib/FlairSensorActuator/src/SimuLaser.cpp

    r158 r214  
    2020#include <SpinBox.h>
    2121#include <GroupBox.h>
    22 #include <cvmatrix.h>
     22#include <Matrix.h>
    2323#include <SharedMem.h>
    2424#include <sstream>
  • trunk/lib/FlairSensorActuator/src/SimuUs.cpp

    r158 r214  
    2020#include <SpinBox.h>
    2121#include <GroupBox.h>
    22 #include <cvmatrix.h>
     22#include <Matrix.h>
    2323#include <SharedMem.h>
    2424#include <sstream>
  • trunk/lib/FlairSensorActuator/src/Srf08.cpp

    r157 r214  
    2121#include <GroupBox.h>
    2222#include <SpinBox.h>
    23 #include <cvmatrix.h>
     23#include <Matrix.h>
    2424#include <string.h>
    2525#include <errno.h>
  • trunk/lib/FlairSensorActuator/src/TargetController.cpp

    r202 r214  
    2020#include <Tab.h>
    2121#include <FrameworkManager.h>
    22 #include <cvmatrix.h>
     22#include <Matrix.h>
    2323
    2424#include <cstring>
     
    122122  } else {
    123123
    124     axis = new cvmatrix((IODevice *)this, axisNumber, 1, floatType);
     124    axis = new Matrix((IODevice *)this, axisNumber, 1, floatType);
    125125    button =
    126         new cvmatrix((IODevice *)this, buttonNumber, 1, SignedIntegerType(8));
     126        new Matrix((IODevice *)this, buttonNumber, 1, SignedIntegerType(8));
    127127
    128128    while (!ToBeStopped()) {
  • trunk/lib/FlairSensorActuator/src/TargetController.h

    r137 r214  
    2727namespace core {
    2828class FrameworkManager;
    29 class cvmatrix;
     29class Matrix;
    3030class Socket;
    3131class io_data;
     
    8282  // axis stuff
    8383  unsigned int axisNumber;
    84   core::cvmatrix *axis = NULL;
    85   virtual void AcquireAxisData(core::cvmatrix &axis) = 0; // responsible for
     84  core::Matrix *axis = NULL;
     85  virtual void AcquireAxisData(core::Matrix &axis) = 0; // responsible for
    8686                                                          // getting the axis
    8787                                                          // data from the
     
    9090  // button stuff
    9191  unsigned int buttonNumber;
    92   core::cvmatrix *button = NULL;
    93   virtual void AcquireButtonData(core::cvmatrix &button) = 0; // responsible for
     92  core::Matrix *button = NULL;
     93  virtual void AcquireButtonData(core::Matrix &button) = 0; // responsible for
    9494                                                              // getting the
    9595                                                              // button data
  • trunk/lib/FlairSensorActuator/src/TargetEthController.cpp

    r202 r214  
    2424#include <cstring>
    2525#include <string>
    26 #include <cvmatrix.h>
     26#include <Matrix.h>
    2727#include <stdexcept>
    2828
     
    150150}
    151151
    152 void TargetEthController::AcquireAxisData(core::cvmatrix &axis) {
     152void TargetEthController::AcquireAxisData(core::Matrix &axis) {
    153153  axis.GetMutex();
    154154  // char testFrameBuffer[3]={(char)0x09,(char)0x59,(char)0xB8};
     
    166166}
    167167
    168 void TargetEthController::AcquireButtonData(core::cvmatrix &button) {
     168void TargetEthController::AcquireButtonData(core::Matrix &button) {
    169169  uint8_t buttonValue;
    170170  int currentButton = 0;
  • trunk/lib/FlairSensorActuator/src/TargetEthController.h

    r178 r214  
    2727namespace core {
    2828class FrameworkManager;
    29 class cvmatrix;
     29class Matrix;
    3030class TcpSocket;
    3131class UdpSocket;
     
    6262
    6363  bool IsDataFrameReady();
    64   void AcquireAxisData(core::cvmatrix &axis);     // responsible for getting the
     64  void AcquireAxisData(core::Matrix &axis);     // responsible for getting the
    6565                                                  // axis data from the hardware
    66   void AcquireButtonData(core::cvmatrix &button); // responsible for getting the
     66  void AcquireButtonData(core::Matrix &button); // responsible for getting the
    6767                                                  // button data from the
    6868                                                  // hardware
  • trunk/lib/FlairSensorActuator/src/UsRangeFinder.cpp

    r148 r214  
    2323#include <Layout.h>
    2424#include <DataPlot1D.h>
    25 #include <cvmatrix.h>
     25#include <Matrix.h>
    2626
    2727using std::string;
     
    3838  cvmatrix_descriptor *desc = new cvmatrix_descriptor(1, 1);
    3939  desc->SetElementName(0, 0, name);
    40   output = new cvmatrix(this, desc, floatType);
     40  output = new Matrix(this, desc, floatType);
    4141  delete desc;
    4242  AddDataToLog(output);
  • trunk/lib/FlairSensorActuator/src/UsRangeFinder.h

    r137 r214  
    1717
    1818namespace flair {
    19 namespace core {
    20 class cvmatrix;
    21 }
    22 namespace gui {
    23 class Tab;
    24 class TabWidget;
    25 class GroupBox;
    26 class Layout;
    27 class DataPlot1D;
    28 }
     19  namespace core {
     20    class Matrix;
     21  }
     22  namespace gui {
     23    class Tab;
     24    class TabWidget;
     25    class GroupBox;
     26    class Layout;
     27    class DataPlot1D;
     28  }
    2929}
    3030
     
    119119  * \return output matrix
    120120  */
    121   core::cvmatrix *output;
     121  core::Matrix *output;
    122122
    123123  /*!
  • trunk/lib/FlairSensorActuator/src/VrpnObject.cpp

    r167 r214  
    2020#include "VrpnClient.h"
    2121#include <string.h>
    22 
    23 #include <cvmatrix.h>
     22#include <Matrix.h>
    2423
    2524using std::string;
     
    5352}
    5453
    55 cvmatrix *VrpnObject::Output(void) const { return pimpl_->output; }
     54Matrix *VrpnObject::Output(void) const { return pimpl_->output; }
    5655
    57 cvmatrix *VrpnObject::State(void) const { return pimpl_->state; }
     56Matrix *VrpnObject::State(void) const { return pimpl_->state; }
    5857
    5958Tab *VrpnObject::GetPlotTab(void) const { return pimpl_->plot_tab; }
  • trunk/lib/FlairSensorActuator/src/VrpnObject.h

    r167 r214  
    2121namespace flair {
    2222        namespace core {
    23                 class cvmatrix;
     23                class Matrix;
    2424                class Quaternion;
    2525        }
     
    126126  * \return Output matrix
    127127  */
    128   core::cvmatrix *Output(void) const;
     128  core::Matrix *Output(void) const;
    129129
    130130  /*!
     
    139139  * \return State matrix
    140140  */
    141   core::cvmatrix *State(void) const;
     141  core::Matrix *State(void) const;
    142142
    143143  /*!
  • trunk/lib/FlairSensorActuator/src/VrpnObject_impl.cpp

    r167 r214  
    2525#include <unistd.h>
    2626#include <vrpn_Connection.h>
    27 #include <cvmatrix.h>
     27#include <Matrix.h>
    2828#include <Tab.h>
    2929#include <TabWidget.h>
     
    6565  desc->SetElementName(5, 0, "y");
    6666  desc->SetElementName(6, 0, "z");
    67   output = new cvmatrix(self, desc, floatType);
     67  output = new Matrix(self, desc, floatType);
    6868  delete desc;
    6969
     
    7272  desc->SetElementName(1, 0, "pitch");
    7373  desc->SetElementName(2, 0, "yaw");
    74   state = new cvmatrix(self, desc, floatType);
     74  state = new Matrix(self, desc, floatType);
    7575  delete desc;
    7676
  • trunk/lib/FlairSensorActuator/src/XBldc_impl.cpp

    r15 r214  
    1919#include "XBldc.h"
    2020#include <I2cPort.h>
    21 #include <cvmatrix.h>
     21#include <Matrix.h>
    2222#include <string.h>
    2323
  • trunk/lib/FlairSensorActuator/src/unexported/VrpnObject_impl.h

    r167 r214  
    2828namespace flair {
    2929        namespace core {
    30                 class cvmatrix;
     30                class Matrix;
    3131        }
    3232        namespace gui {
     
    5858  flair::gui::DataPlot1D *y_plot;
    5959  flair::gui::DataPlot1D *z_plot;
    60   flair::core::cvmatrix *output, *state;
     60  flair::core::Matrix *output, *state;
    6161
    6262  static void VRPN_CALLBACK handle_pos(void *userdata, const vrpn_TRACKERCB t);
Note: See TracChangeset for help on using the changeset viewer.