source: flair-src/trunk/lib/FlairSimulator/src/X8.h @ 157

Last change on this file since 157 was 157, checked in by Sanahuja Guillaume, 4 years ago

iadded isready to iodevice:
avoid problem of imu not ready in ardrone2

File size: 1.8 KB
RevLine 
[10]1// %flair:license{
[15]2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
[10]4// %flair:license}
[8]5//  created:    2014/04/03
6//  filename:   X8.h
7//
8//  author:     Majd Saied, Guillaume Sanahuja
9//              Copyright Heudiasyc UMR UTC/CNRS 7253
10//
11//  version:    $Id: $
12//
13//  purpose:    classe definissant un X8
14//
15/*********************************************************************/
16
17#ifndef X8_H
18#define X8_H
19
20#include <Model.h>
21
[15]22namespace flair {
23namespace core {
24class Mutex;
[8]25}
[15]26namespace gui {
27class DoubleSpinBox;
28}
29namespace actuator {
30class SimuBldc;
31}
32}
[8]33
34#ifdef GL
[15]35namespace irr {
36namespace scene {
37class IMesh;
[8]38}
[15]39}
[8]40#endif
41
[15]42namespace flair {
43namespace simulator {
44class Simulator;
45class Blade;
46class MeshSceneNode;
[8]47
[15]48class X8 : public Model {
49public:
50  X8(const Simulator *parent, std::string name, int dev_id);
51  ~X8();
52  virtual void Draw(void);
53  virtual void ExtraDraw(void){};
54
55protected:
[8]56#ifdef GL
[15]57  irr::scene::IMesh *red_arm, *black_arm, *motor;
58  MeshSceneNode *fl_arm, *fr_arm, *rl_arm, *rr_arm;
59  MeshSceneNode *tfl_motor, *tfr_motor, *trl_motor, *trr_motor;
60  MeshSceneNode *bfl_motor, *bfr_motor, *brl_motor, *brr_motor;
61  Blade *tfl_blade, *tfr_blade, *trl_blade, *trr_blade;
62  Blade *bfl_blade, *bfr_blade, *brl_blade, *brr_blade;
[8]63#endif
[15]64private:
65  void CalcModel(void);
66#ifdef GL
67  void AnimateModel(void);
68  size_t dbtSize(void) const;
69  void WritedbtBuf(char *dbtbuf);
70  void ReaddbtBuf(char *dbtbuf);
71  core::Mutex *motor_speed_mutex;
72#endif
[8]73
[15]74  actuator::SimuBldc *motors;
75  float motor_speed[8];
76  gui::DoubleSpinBox *m, *arm_length, *l_cg;
77  gui::DoubleSpinBox *k_mot, *c_mot;
78  gui::DoubleSpinBox *f_air_vert, *f_air_lat;
79  gui::DoubleSpinBox *j_roll, *j_pitch, *j_yaw;
80  gui::DoubleSpinBox *j_r, *sigma, *S;
81};
[8]82} // end namespace simulator
83} // end namespace flair
84#endif // X8_H
Note: See TracBrowser for help on using the repository browser.