1997 Commits

Author SHA1 Message Date
Jef Driesen
4d30b19251 Use the select() function instead of poll().
The poll() function does not support (serial) devices on Mac OS X.
2008-02-15 15:57:45 +00:00
Jef Driesen
4be1c33ca3 Added the initial implementation for the Suunto D6 and D9. 2008-02-13 15:55:16 +00:00
Jef Driesen
898b1479bc Set the fAbortOnError flag explicitly to FALSE.
This change prevents some unexpected errors.
2008-02-08 14:17:38 +00:00
Jef Driesen
0b5c63995f Added support for the Mac OS X operating system. 2008-02-08 09:02:36 +00:00
Jef Driesen
331ecf1a09 Added a function to change the delay between two commands.
Some dive computers do not work well with the default delay. But 
increasing the default delay would make the transfer unnecessary longer 
for all others.
2008-02-03 06:29:07 +00:00
Jef Driesen
fa20dbb87d Added the initial implementation for the Uwatec Memomouse. 2008-01-28 13:52:29 +00:00
Jef Driesen
0d800dba95 Do not return the checksum bytes to the user. 2008-01-24 10:48:11 +00:00
Jef Driesen
6ca4159149 Added the initial implementation for the Uwatec Aladin. 2008-01-10 09:20:11 +00:00
Jef Driesen
7f3382dfd7 Added code to transfer only the dive data from a Suunto Vyper2.
The dives are transfered in reverse order (newest dives first).
2008-01-08 15:58:19 +00:00
Jef Driesen
a004a94c2a Added utility functions to duplicate all output to a logfile. 2008-01-02 12:11:31 +00:00
Jef Driesen
8b52082a2f Updated the comments on the timings of the original Suunto interface. 2008-01-02 12:01:39 +00:00
Jef Driesen
bc229099af Added a missing function to the header file. 2007-12-29 19:06:23 +00:00
Jef Driesen
a63a1e4576 Added the initial implementation for the Suunto Vyper2. 2007-12-19 10:16:00 +00:00
Jef Driesen
50bc70d89a Use common error codes for all Suunto divecomputers. 2007-12-19 09:24:09 +00:00
Jef Driesen
ec04cc516c Prepare to add support for other Suunto dive computers. 2007-12-19 09:15:12 +00:00
Jef Driesen
e67d470c11 Return success when trying to close a NULL device. 2007-12-07 12:17:35 +00:00
Jef Driesen
4a8c15dafe Changed the default timeout to 1000ms. 2007-12-03 14:39:09 +00:00
Jef Driesen
3f22a2d3e5 Add extra debugging code when a null package is received. 2007-12-03 14:38:47 +00:00
Jef Driesen
d265228b26 Improved some code comments. 2007-12-03 13:56:22 +00:00
Jef Driesen
4d4b0f141f Do not detect the first package by means of the number of bytes.
If the first package was a null package and the transfer was not 
aborted, it does not work properly.
2007-12-03 13:54:21 +00:00
Jef Driesen
b9a43e3157 Do not flush the input and output buffers when configuring the device. 2007-11-29 09:08:25 +00:00
Jef Driesen
40835b8d80 Added a function to configure the size of the input and output buffers. 2007-11-27 15:09:38 +00:00
Jef Driesen
295c95ac03 Fixed include file. 2007-11-22 15:46:44 +00:00
Jef Driesen
ec0e90a738 Renamed the dumpfile to avoid confusion with the dumpfile from SDM. 2007-11-22 15:39:09 +00:00
Jef Driesen
b847086ad7 Do not attempt to read data if it's not required. 2007-11-17 09:40:24 +00:00
Jef Driesen
5e9279b99d Read the package length and header with a single read operation. 2007-11-17 08:53:54 +00:00
Jef Driesen
40e37e6675 Removed some unnecessary functions. 2007-11-16 15:37:50 +00:00
Jef Driesen
8f4ebf434c Reduced the amount of duplicated code. 2007-11-16 13:34:13 +00:00
Jef Driesen
7f158ff8f6 Use the SUUNTO_VYPER_PACKET_SIZE macro. 2007-11-16 11:28:48 +00:00
Jef Driesen
7747a6d4bd Use the result codes in the test application. 2007-11-13 09:48:59 +00:00
Jef Driesen
8b6db75873 Return more useful result codes from all public api functions. 2007-11-09 15:07:57 +00:00
Jef Driesen
84e76103c2 Updated the code comments on the timing of the echo cancellation.
I measured the echo is arrives after approximately 40ms.
2007-11-09 14:57:46 +00:00
Jef Driesen
7e75ee3831 Setting the RTS line is not really necessary when opening the device. 2007-11-09 14:41:33 +00:00
Jef Driesen
627ba48bc2 Use a macro for all warning messages. 2007-11-09 12:47:56 +00:00
Jef Driesen
07265e3571 Change the echo cancellation to match with Suunto Dive Manager 1.6.
Detection of the interface before reading or writing is not required 
anymore.
2007-11-08 14:46:10 +00:00
Jef Driesen
94ff25e8a4 Open the dump files in binary mode. 2007-11-08 08:55:03 +00:00
Jef Driesen
de3fb61c0a Handle null packages correctly.
Abort the transmission and discard the data if a null package is 
received at the end of the internal ring buffer.
2007-11-04 13:12:50 +00:00
Jef Driesen
e1f12108cb Handle timeouts while receiving the first package.
Instead of ending the transmission, an error is reported.
2007-11-03 20:27:14 +00:00
Jef Driesen
316ec12fef Added a test to dump the entire memory of the dive computer. 2007-11-03 20:00:14 +00:00
Jef Driesen
4875f9c2bb Added the initial implementation for the Suunto Vyper. 2007-10-31 15:25:44 +00:00
Jef Driesen
c5fc289cb2 Added missing break statements in the serial_flush() functions. 2007-10-29 10:54:40 +00:00
Jef Driesen
76e5f12094 Implemented the win32 serial_drain function using FlushFileBuffers. 2007-10-29 10:49:35 +00:00
Jef Driesen
21e9cf9739 Implemented the win32 serial_drain function using WaitCommEvent. 2007-10-29 10:45:35 +00:00
Jef Driesen
425efd1c0d Added a shorter implementation for the serial_set_status function. 2007-10-29 09:56:30 +00:00
Jef Driesen
0154674573 Attempt to read/write before waiting, instead of the other way around. 2007-10-29 09:52:28 +00:00
Jef Driesen
a3ae610b2e Replace termios VMIN=0 and VTIME=0 with O_NONBLOCK.
Enable O_NONBLOCK to be able to detect the difference between a timeout 
and a modem disconnect (EOF). With this change, it's also possible to 
implement write timeouts.
2007-10-29 09:37:26 +00:00
Jef Driesen
3f33f82bc2 Initial import. 2007-10-29 09:22:19 +00:00