mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-01 06:30:26 +00:00
49401eec0b
I fixed up the decode and finished the parse for Cochran EMC, Commander and Gemini computers. I suspect that this code may only work with files from certain versions of Cochran Analyst. It works with my own CAN files and with the samples that came with Analyst v4.01v. A seemingly arbitrary offset of 0x4914 is needed to access data. The previous code uses 0x4a14 and 0x4b14. I suspect these are from different version of Analyst. [Dirk Hohndel: whitespace cleanup, add files to subsurface.pro, made sure this compiles without the corresponding patch to libdivecomputer (that isn't upstream, yet), cleaned up the usage of structs, removed a few unused variables] Signed-off-by: John Van Ostrand <john@vanostrand.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
20 lines
358 B
C
20 lines
358 B
C
#ifndef FILE_H
|
|
#define FILE_H
|
|
|
|
struct memblock {
|
|
void *buffer;
|
|
size_t size;
|
|
};
|
|
|
|
extern int try_to_open_cochran(const char *filename, struct memblock *mem);
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
extern int readfile(const char *filename, struct memblock *mem);
|
|
extern timestamp_t parse_date(const char *date);
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif // FILE_H
|