From 856ec092b73acc8bc7942beb2e040647c848a354 Mon Sep 17 00:00:00 2001 From: Anton Lundin Date: Mon, 20 Oct 2014 22:58:25 +0200 Subject: Configure support for OSTC, Mk.2/2N/2C First out is firmware updates. Signed-off-by: Anton Lundin Signed-off-by: Dirk Hohndel --- configuredivecomputerthreads.cpp | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'configuredivecomputerthreads.cpp') diff --git a/configuredivecomputerthreads.cpp b/configuredivecomputerthreads.cpp index a96548e0f..7856a150f 100644 --- a/configuredivecomputerthreads.cpp +++ b/configuredivecomputerthreads.cpp @@ -690,12 +690,22 @@ void FirmwareUpdateThread::run() dc_status_t rc; rc = dc_device_open(&m_data->device, m_data->context, m_data->descriptor, m_data->devname); if (rc == DC_STATUS_SUCCESS) { + switch (dc_device_get_type(m_data->device)) { #if DC_VERSION_CHECK(0, 5, 0) - if (dc_device_get_type(m_data->device) == DC_FAMILY_HW_OSTC3) { - supported = true; + case DC_FAMILY_HW_OSTC3: + //Not Yet supported + //supported = true; //hw_ostc3_device_fwupdate(m_data->device, m_fileName.toUtf8().data()); - } + break; #endif // divecomputer 0.5.0 + case DC_FAMILY_HW_OSTC: + supported = true; + hw_ostc_device_fwupdate(m_data->device, m_fileName.toUtf8().data()); + break; + default: + supported = false; + break; + } dc_device_close(m_data->device); if (!supported) { -- cgit v1.2.3-70-g09d2