[PATCH 2/2] Cochran: Added support for EMC-14
John Van Ostrand
john at vanostrand.com
Sun Dec 7 10:17:52 PST 2014
Added detection of EMC 14 model and tested.
Signed-off-by: John Van Ostrand <john at vanostrand.com>
---
src/cochran_commander.c | 17 +++++++++++++++++
src/descriptor.c | 5 +++--
2 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/src/cochran_commander.c b/src/cochran_commander.c
index dc9b3d5..895c859 100644
--- a/src/cochran_commander.c
+++ b/src/cochran_commander.c
@@ -378,6 +378,23 @@ cochran_commander_get_config (const unsigned char *model,
conf->address_length = COCHRAN_ADDRESS_LENGTH_32;
conf->high_baud = 825600;
}
+ else if (memcmp(model, "AM7303\x8b\x43", 8) == 0)
+ {
+ conf->model = COCHRAN_MODEL_EMC_14;
+ conf->log_size = 512;
+ conf->sample_memory_start_address = 0x94000;
+ conf->dive_num_ptr = 0x56;
+ conf->dive_count_ptr = 0xD2;
+ conf->dive_count_endian = COCHRAN_LE_TYPE;
+ conf->sample_end_ptr = 256;
+ conf->log_pre_dive_ptr = 30;
+ conf->log_end_dive_ptr = 256;
+ conf->last_interdive_ptr = 233;
+ conf->last_entry_ptr = 194;
+ conf->date_format = COCHRAN_DATE_FORMAT_SMHDMY;
+ conf->address_length = COCHRAN_ADDRESS_LENGTH_32;
+ conf->high_baud = 825600;
+ }
else if (memcmp(model, "AM\x11""2212\x02", 8) == 0)
{
conf->model = COCHRAN_MODEL_COMMANDER_AIR_NITROX;
diff --git a/src/descriptor.c b/src/descriptor.c
index e69ec12..196ee1d 100644
--- a/src/descriptor.c
+++ b/src/descriptor.c
@@ -227,8 +227,9 @@ static const dc_descriptor_t g_descriptors[] = {
/* Dive Rite NiTek Q */
{"Dive Rite", "NiTek Q", DC_FAMILY_DIVERITE_NITEKQ, 0},
{"Cochran", "Commander", DC_FAMILY_COCHRAN_COMMANDER, 0},
- {"Cochran", "EMC-16", DC_FAMILY_COCHRAN_COMMANDER, 1},
- {"Cochran", "EMC-20H", DC_FAMILY_COCHRAN_COMMANDER, 2},
+ {"Cochran", "EMC-14", DC_FAMILY_COCHRAN_COMMANDER, 1},
+ {"Cochran", "EMC-16", DC_FAMILY_COCHRAN_COMMANDER, 2},
+ {"Cochran", "EMC-20H", DC_FAMILY_COCHRAN_COMMANDER, 3},
};
typedef struct dc_descriptor_iterator_t {
--
1.9.3
More information about the devel
mailing list