Ignore:
Timestamp:
04/08/16 15:40:57 (8 years ago)
Author:
Bayard Gildas
Message:

sources reformatted with flair-format-dir script

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairSensorActuator/src/unexported/BlCtrlV2_impl.h

    r3 r15  
    1616/*********************************************************************/
    1717
    18 
    1918#ifndef BLCTRLV2_IMPL_H
    2019#define BLCTRLV2_IMPL_H
     
    2524#define MAX_MOTORS 8
    2625
    27 namespace flair
    28 {
    29     namespace core
    30     {
    31         class I2cPort;
    32     }
    33     namespace gui
    34     {
    35         class SpinBox;
    36         class GroupBox;
    37         class Layout;
    38     }
    39     namespace actuator
    40     {
    41         class BlCtrlV2;
    42     }
    43     namespace sensor
    44     {
    45         class BatteryMonitor;
    46     }
     26namespace flair {
     27namespace core {
     28class I2cPort;
     29}
     30namespace gui {
     31class SpinBox;
     32class GroupBox;
     33class Layout;
     34}
     35namespace actuator {
     36class BlCtrlV2;
     37}
     38namespace sensor {
     39class BatteryMonitor;
     40}
    4741}
    4842
    49 class BlCtrlV2_impl
    50 {
    51     public:
    52         BlCtrlV2_impl(flair::actuator::BlCtrlV2* self,flair::gui::Layout *layout,flair::core::I2cPort* i2cport);
    53         ~BlCtrlV2_impl();
    54         void SetMotors(float* value);
    55         flair::sensor::BatteryMonitor *battery;
    56         flair::gui::SpinBox *poles;
     43class BlCtrlV2_impl {
     44public:
     45  BlCtrlV2_impl(flair::actuator::BlCtrlV2 *self, flair::gui::Layout *layout,
     46                flair::core::I2cPort *i2cport);
     47  ~BlCtrlV2_impl();
     48  void SetMotors(float *value);
     49  flair::sensor::BatteryMonitor *battery;
     50  flair::gui::SpinBox *poles;
    5751
    58     private:
    59         void WriteValue(uint16_t value);//I2cPort mutex must be taken before calling this function
    60         void DetectMotors(void);
    61         void GetCurrentSpeedAndVoltage(float &current,float &speed,float &voltage);//I2cPort mutex must be taken before calling this function
    62         void GetCurrentAndSpeed(float &current,float &speed);//I2cPort mutex must be taken before calling this function
    63         flair::core::Time last_voltage_time;
    64         int nb_mot;
    65         flair::core::I2cPort* i2cport;
    66         flair::actuator::BlCtrlV2* self;
     52private:
     53  void WriteValue(uint16_t value); // I2cPort mutex must be taken before calling
     54                                   // this function
     55  void DetectMotors(void);
     56  void GetCurrentSpeedAndVoltage(float &current, float &speed,
     57                                 float &voltage); // I2cPort mutex must be taken
     58                                                  // before calling this
     59                                                  // function
     60  void GetCurrentAndSpeed(
     61      float &current,
     62      float &speed); // I2cPort mutex must be taken before calling this function
     63  flair::core::Time last_voltage_time;
     64  int nb_mot;
     65  flair::core::I2cPort *i2cport;
     66  flair::actuator::BlCtrlV2 *self;
    6767};
    6868
Note: See TracChangeset for help on using the changeset viewer.