mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 14:38:30 -04:00
84b5555a1a
This commit changes the way libraries headers are included in source files: - If the header is in the same directory the source belongs to, so the notation '#include ""' is used with the path relative to the directory containing the source. - If the header is outside the directory containing the source, then we use the notation '#include <>' with the path relative to libraries folder. Some of the advantages of such approach: - Only one search path for libraries headers. - OSs like Windows may have a better lookup time.
25 lines
595 B
C++
25 lines
595 B
C++
#ifndef REPLAY_DATAFLASHREADER_H
|
|
#define REPLAY_DATAFLASHREADER_H
|
|
|
|
#include <DataFlash/DataFlash.h>
|
|
|
|
class DataFlashFileReader
|
|
{
|
|
public:
|
|
bool open_log(const char *logfile);
|
|
bool update(char type[5]);
|
|
|
|
virtual bool handle_log_format_msg(const struct log_Format &f) = 0;
|
|
virtual bool handle_msg(const struct log_Format &f, uint8_t *msg) = 0;
|
|
|
|
protected:
|
|
int fd = -1;
|
|
bool done_format_msgs = false;
|
|
virtual void end_format_msgs(void) {}
|
|
|
|
#define LOGREADER_MAX_FORMATS 255 // must be >= highest MESSAGE
|
|
struct log_Format formats[LOGREADER_MAX_FORMATS] {};
|
|
};
|
|
|
|
#endif
|