source: flair-src/trunk/lib/FlairSensorActuator/src/SimuGps.h@ 147

Last change on this file since 147 was 137, checked in by Sanahuja Guillaume, 7 years ago

singleton manager

File size: 2.0 KB
RevLine 
[3]1// %flair:license{
[15]2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
[3]4// %flair:license}
5/*!
6 * \file SimuGps.h
7 * \brief Class for a simulation GPS
8 * \author Guillaume Sanahuja, Copyright Heudiasyc UMR UTC/CNRS 7253
9 * \date 2013/08/23
10 * \version 4.0
11 */
12
13#ifndef SIMUGPS_H
14#define SIMUGPS_H
15
16#include <Thread.h>
[51]17#include <NmeaGps.h>
[3]18
[15]19namespace flair {
[55]20 namespace core {
21 class SharedMem;
22 }
23 namespace gui {
24 class SpinBox;
25 class DoubleSpinBox;
26 }
[3]27}
28
[15]29namespace flair {
30namespace sensor {
31/*! \class SimuGps
32*
33* \brief Class for a simulation GPS
34*/
[51]35class SimuGps : public core::Thread, public NmeaGps {
[15]36public:
37 /*!
38 * \brief Constructor
39 *
[55]40 * Construct a simulation GPS. Control part.
[137]41 * It will be child of the FrameworkManager.
42 *
[15]43 * \param name name
44 * \param NMEAFlags NMEA sentances to enable
[55]45 * \param deviceId device id
[15]46 * \param priority priority of the Thread
47 */
[137]48 SimuGps(std::string name,
[55]49 NmeaGps::NMEAFlags_t NMEAFlags, uint32_t deviceId,uint8_t priority);
[3]50
[15]51 /*!
[55]52 * \brief Constructor
53 *
54 * Construct a simulation GPS. Simulation part.\n
55 * The Thread of this class should not be run.
56 *
57 * \param parent parent
58 * \param name name
59 * \param deviceId device id
60 */
61 SimuGps(const core::IODevice *parent, std::string name, uint32_t deviceId);
62
63 /*!
[15]64 * \brief Destructor
65 *
66 */
67 ~SimuGps();
[3]68
[15]69private:
70 /*!
71 * \brief Update using provided datas
72 *
73 * Reimplemented from IODevice.
74 *
75 * \param data data from the parent to process
76 */
[55]77 void UpdateFrom(const core::io_data *data);
[3]78
[15]79 /*!
80 * \brief Run function
81 *
82 * Reimplemented from Thread.
83 *
84 */
85 void Run(void);
[55]86
87 typedef struct {
[68]88 float e;
89 float n;
90 float u;
91 float ve;
92 float vn;
[55]93 } gps_states_t;
94
95 core::SharedMem *shmem;
96 gui::SpinBox *dataRate,*fixQuality,*numberOfSatellites;
97 gui::DoubleSpinBox *latitudeRef,*longitudeRef,*altitudeRef;
[15]98};
[3]99} // end namespace sensor
100} // end namespace framewor
101#endif // SIMUGPS_H
Note: See TracBrowser for help on using the repository browser.