426 Commits

Author SHA1 Message Date
Jef Driesen
e96a007451 Discard garbage bytes when opening the session. 2010-09-12 21:05:35 +02:00
Jef Driesen
a0bb840169 Use only 12 bits for the depth.
The depth is stored with only 12 bits, which results in a maximum depth
of 99.9 meters. The remaining 4 bits are yet unknown, but one of those
bits appears to indicate a larger sample.
2010-08-29 15:08:28 +02:00
Jef Driesen
180321029a Fixed a small mistake in the previous commit. 2010-08-29 15:04:44 +02:00
Jef Driesen
1dc9704a24 Avoid reading outside the ringbuffer area.
Since the total amount of profile data is not necessary a multiple of
the maximum packet size, the code may attempt to read outside the
ringbuffer area in some cases. Because the device supports a variable
packet size, the problem can simply be avoided by adjusting the packet
size.

As a side effect of this fix, the code will now also detect when the
profile ringbuffer is filling up faster than the logbook ringbuffer, and
the progress events are improved as well.
2010-08-28 22:58:55 +02:00
Jef Driesen
2fca7914b6 Implement the foreach and fingerprint support for the Zeagle N2iTiON3. 2010-08-28 22:53:55 +02:00
Jef Driesen
c060f268be Add support for the Zeagle N2iTiON3. 2010-08-28 22:53:48 +02:00
Jef Driesen
87226652df Fix the year offset for some models. 2010-08-09 17:05:01 +02:00
Jef Driesen
79dfa4becb Mark the last memory page on an Aeris Epic as unreadable. 2010-08-06 13:30:42 +02:00
Jef Driesen
911513c578 Use the correct number of alarm bytes for each model. 2010-07-29 13:39:52 +02:00
Jef Driesen
0f5b6028ef Copy missing sample values from the previous sample.
The Uwatec Smart stores a sample value only when it's diffent from the
previous value. While this compressed format does save some space on the
device, it is less practical for use in an application. The original
uncompressed data can easily be obtained by copying missing sample
values from the previous sample.

The implementation uses a two pass approach. In the first pass, all
sample values that are explicitly stored in the profile date are
collected. Any sample value that is not present, will automatically
retain the value from the previous sample. In the second pass, all
sample values are passed back to the application. The presence of an
absolute value is used to decide which sample types are present in the
data.
2010-07-29 13:36:43 +02:00
Jef Driesen
10377f969a Keep only a single type for both absolute and delta values. 2010-07-28 16:47:25 +02:00
Jef Driesen
9b8ccb99fb Increase the packet size if more data is immediately available. 2010-07-28 16:47:25 +02:00
Jef Driesen
a722d50f03 Mark the last memory page on a Sherwood Wisdom 2 as unreadable. 2010-07-28 08:36:49 +02:00
Jef Driesen
82a0fc97a0 Add support for the Mares Nemo Apneist.
The total memory size is hardcoded again because the protocol does not
allow to retrieve the correct memory layout in advance. As long as there
is no device with a different amount of memory, that should be fine.
2010-07-27 13:38:56 +02:00
Jef Driesen
8d0acf3e9e Parse the tank pressure for the Mares Puck Air. 2010-07-15 16:01:08 +02:00
Jef Driesen
5875941641 Add support for the Mares Puck Air. 2010-07-13 09:09:14 +02:00
Jef Driesen
aca36ad344 Add a parser for the Mares Icon HD. 2010-06-29 11:42:00 +02:00
Jef Driesen
620775af25 Add support for the Mares Icon HD. 2010-04-12 10:19:38 +02:00
Jef Driesen
f4d3747e94 Mark the last memory page on an Oceanic Atom 2 as unreadable.
When trying to read the last memory page from an Oceanic Atom 2, the
device does not respond. Strangely, other compatible devices are not
affected by this problem.
2010-06-23 15:01:51 +02:00
Jef Driesen
a37bf20493 Fix the temperature and pressure for the Oceanic Atom 2. 2010-06-23 13:33:16 +02:00
Jef Driesen
8dd1647ede The Solution Nitrox/Vario stores nitrox data, not tank pressure. 2010-05-27 00:15:59 +02:00
Jef Driesen
f569f402f2 Fix the decoding of negative temperatures. 2010-05-22 22:19:34 +02:00
Jef Driesen
d7c2fbbf18 Introduce surface samples for the pressure and temperature data.
The Suunto Vyper, Spyder and Eon store a surface event after the last
depth sample. Adding an artificial zero depth sample avoids the problem
of having an incomplete sample without a depth measurement.

Because these devices also store the tank pressure and/or the
temperature at the begin/end of the dive, these measurements are
associated with the new surface samples.
2010-05-22 22:11:52 +02:00
Jef Driesen
fd9390e8a8 Associate the events with the correct sample timestamp. 2010-05-21 23:12:24 +02:00
Jef Driesen
441aad3a40 Add support for the Uwatec Aladin Tec 2G. 2010-05-19 20:01:44 +02:00
Jef Driesen
13d1badf29 Migrate from Subversion to Git. 2010-05-10 11:30:25 +02:00
Jef Driesen
f94d2b295f Fix the 64bit integer type for the mingw compiler.
The mingw native 64bit integer type is long long. The msvc __int64 type
is supported for compatibility reasons, but requires including one of
the standard C header files.
2010-05-06 08:35:45 +00:00
Jef Driesen
04f1c1422b Include the stddef.h header for the size_t type. 2010-05-06 08:35:33 +00:00
Jef Driesen
4e5c9ad8a3 Remove all debugging code. 2010-05-06 06:21:59 +00:00
Jef Driesen
bec8c5581e Prepare the libtool shared library versioning. 2010-05-03 22:09:52 +00:00
Jef Driesen
b92deee33c Support automatic fingerprint management using a cache directory. 2010-05-03 18:26:41 +00:00
Jef Driesen
6641dda617 Add a parser for the Cressi Edy. 2010-05-03 18:02:43 +00:00
Jef Driesen
60249d075d Implement some missing features for the Cressi Edy.
The internal memory appears to contain two separate areas. One for the
normal dives and one for the freedives. Currently, only the freedive
section is processed.
2010-05-03 18:02:23 +00:00
Jef Driesen
996bfb2b48 Move the subversion revision number to a private header. 2010-05-03 14:20:05 +00:00
Jef Driesen
2cd09fd525 Add a more convenient method for compile/run-time version checks. 2010-04-29 09:21:05 +00:00
Jef Driesen
fed4e562ee Return the version info as a string. 2010-04-29 09:20:51 +00:00
Jef Driesen
0976932501 Add a function to retrieve the run-time version info. 2010-04-27 14:00:53 +00:00
Jef Driesen
e803369364 Fix the datetime parsing for the Oceanic OC1. 2010-04-27 11:34:05 +00:00
Jef Driesen
6503ff2351 Use an extra bit for the pointers in the logbook entries.
Due to the larger memory capacity, the Oceanic OC1 needs an additional
bit to be able to address memory pages above 64K.
2010-04-27 11:33:53 +00:00
Jef Driesen
61f9603131 Autodetect the Oceanic OC1 layout at runtime. 2010-04-27 11:33:41 +00:00
Jef Driesen
e87385850b Use independent settings for the global and logbook pointer modes. 2010-04-27 11:33:29 +00:00
Jef Driesen
76db1e6f44 Locate the header marker correctly in a longer sequence of zero bytes.
If the first few bytes of the timestamp are equal to zero, they were
incorrectly identified as part of the header marker. The correct header
marker is located a the start of this zero byte sequence, not the end.
2010-04-26 08:09:22 +00:00
Jef Driesen
5dcfe111de Fix the temperature and pressure for the Oceanic Geo and Datamask. 2010-04-24 06:57:05 +00:00
Jef Driesen
711ce88583 Add support for dives with a depth based sample interval.
Because the sample data contains a timestamp with a limited resolution
of only one minute, there can be consecutive samples with identical
timestamps. To deal with this situation, samples with identical
timestamps are distributed evenly inside the one minute interval. All
resulting non-integer timestamps are rounded to the nearest second.

For dives with a time based interval, the timestamps are now validated.
2010-04-21 14:08:17 +00:00
Jef Driesen
fb9976d24f Add a parser for the Heinrichs Weikamp OSTC. 2010-04-19 13:53:38 +00:00
Jef Driesen
b0f82da28f Implement some missing features for the Heinrichs Weikamp OSTC. 2010-04-19 13:53:23 +00:00
Jef Driesen
85dd9d8bd3 Add the subversion revision number to the version info. 2010-04-15 14:25:16 +00:00
Jef Driesen
caa3be8307 Delay the resending of a command after an error. 2010-04-15 12:25:52 +00:00
Jef Driesen
a734f40604 Limit the init response to 13 bytes.
Not all devices appear to send the last zero byte, resulting in a
timeout. If a device does send this zero byte, it is automatically
flushed when sending the next command.
2010-04-15 12:25:42 +00:00
Jef Driesen
0faf2bf815 Use the correct printf format for 64 bit integers. 2010-04-02 13:04:53 +00:00