444 Commits

Author SHA1 Message Date
Jef Driesen
f8e8bd3b54 Discard the additional bytes inside the init function. 2010-11-04 21:52:14 +01:00
Jef Driesen
57ae6b2c13 Eliminate some duplicated code. 2010-11-04 20:49:14 +01:00
Jef Driesen
608df2c4c1 Fixed a typo in the autodetection of the Oceanic OC1. 2010-11-01 20:21:11 +01:00
Jef Driesen
e0860923e0 Check the ringbuffer pointers for invalid values.
If a logbook entry contains an invalid ringbuffer pointer, the error is
not returned immediately, but delayed until the end of the download.
With this approach we can download at least the dives before the
problematic logbook entry.
2010-10-30 23:10:28 +02:00
Jef Driesen
ca126e9af6 Add support for the new surface samples. 2010-10-24 17:43:34 +02:00
Jef Driesen
448300cc82 Adjust the header size for the Oceanic Veo 3. 2010-10-24 17:42:57 +02:00
Jef Driesen
a9ede19d51 Reset the complete state at the correct place. 2010-10-23 22:41:23 +02:00
Jef Driesen
72ae3b9a86 Add a function to query the state of the serial lines. 2010-10-04 23:08:52 +02:00
Jef Driesen
887d744e6d Use a more consistent typedef in the serial and irda backends. 2010-10-04 23:08:39 +02:00
Jef Driesen
d4766904f5 Add progress events for writing the user data segment. 2010-10-04 23:08:27 +02:00
Jef Driesen
12a918bacc Improve the error recovery during the handshaking phase.
The handshaking is now automatically restarted whenever a non-fatal
error (such as a timeout or a protocol violation) is encountered.
Previously, only corrupt handshake packets where handled.
2010-10-04 23:08:15 +02:00
Jef Driesen
15bad40976 Add a devinfo event for the Mares Icon HD. 2010-10-04 23:08:02 +02:00
Jef Driesen
55c4212dae Add support for the Tusa Zen Air. 2010-10-04 21:33:08 +02:00
Jef Driesen
4b374f2632 Add support for the Oceanic Veo 3. 2010-10-04 21:16:14 +02:00
Jef Driesen
2abc371abb Mark the last memory page on an Geo 2 and Pro Plus 2.1 as unreadable. 2010-09-30 20:58:34 +02:00
Jef Driesen
4ec8578a3e Add support for the Oceanic Geo 2 and Veo 2. 2010-09-30 20:35:33 +02:00
Jef Driesen
bae20d75a3 Adjust the baudrate for Unix systems.
The termios interface does not support setting a baudrate of 256000 bps,
but using the nearest supported baudrate appears to work fine too.
2010-09-19 15:31:50 +02:00
Jef Driesen
a24fd313ae Add the foreach function for the Mares Icon HD.
Note that this implementation will fail if the ringbuffer doesn't start
at the fixed address 0xA000. This is very likely to occur once the
ringbuffer is filled completely and the device starts to overwrite old
data.
2010-09-19 15:22:11 +02:00
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