File tree 4 files changed +11
-16
lines changed
4 files changed +11
-16
lines changed Original file line number Diff line number Diff line change 2
2
#define DYNAMIC_FIFO_H
3
3
4
4
#include < iostream>
5
-
5
+ # include " Shared.h "
6
6
7
7
template <class T >
8
8
class DynamicFifo { // / essentially a circular fifo
@@ -14,11 +14,6 @@ class DynamicFifo { /// essentially a circular fifo
14
14
15
15
16
16
public:
17
- enum Fifo_STATUS {
18
- Fifo_FULL,
19
- Fifo_EMPTY,
20
- Fifo_GOOD
21
- };
22
17
/* *
23
18
* @brief Construct a new Fifo object
24
19
* @param s
@@ -164,7 +159,7 @@ class DynamicFifo { /// essentially a circular fifo
164
159
~DynamicFifo () { delete[] elem; } // destructor
165
160
};
166
161
167
- #include " dynamicFifo .tpp" // implementation file
162
+ #include " DynamicFifo .tpp" // implementation file
168
163
169
164
170
165
#endif // DYNAMIC_FIFO_H
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ T& DynamicFifo<T>::atFifoIndex(int i) const{
49
49
50
50
51
51
template <class T >
52
- typename DynamicFifo<T>:: Fifo_STATUS DynamicFifo<T>::push(const T& item) {
52
+ Fifo_STATUS DynamicFifo<T>::push(const T& item) {
53
53
if (fifo_status ()==Fifo_STATUS::Fifo_FULL) {
54
54
// throw std::length_error("NA"); // throw does not work with arduino :(
55
55
return Fifo_STATUS::Fifo_FULL; // status code
@@ -121,7 +121,7 @@ T DynamicFifo<T>::peekFront(int i) const {
121
121
}
122
122
123
123
template <class T >
124
- typename DynamicFifo<T>:: Fifo_STATUS DynamicFifo<T>::fifo_status() const {
124
+ Fifo_STATUS DynamicFifo<T>::fifo_status() const {
125
125
if (nextFree==endPointer) {
126
126
return Fifo_STATUS::Fifo_EMPTY; // fifo empty
127
127
}
Original file line number Diff line number Diff line change 2
2
#define FIFO_H
3
3
4
4
#include < iostream>
5
-
6
-
5
+ #include " Shared.h"
7
6
8
7
9
8
template <class T , unsigned int sz>
@@ -16,11 +15,6 @@ class Fifo { /// essentially a circular fifo
16
15
17
16
18
17
public:
19
- enum Fifo_STATUS {
20
- Fifo_FULL,
21
- Fifo_EMPTY,
22
- Fifo_GOOD
23
- };
24
18
/* *
25
19
* @brief Construct a new Fifo object
26
20
* @param s
Original file line number Diff line number Diff line change 5
5
#ifndef ARDUINO_LSM6DSO32_SHARED_H
6
6
#define ARDUINO_LSM6DSO32_SHARED_H
7
7
8
+ enum Fifo_STATUS {
9
+ Fifo_FULL ,
10
+ Fifo_EMPTY ,
11
+ Fifo_GOOD
12
+ };
13
+
8
14
#endif //ARDUINO_LSM6DSO32_SHARED_H
You can’t perform that action at this time.
0 commit comments