Commit graph

31 commits

Author SHA1 Message Date
Anton Lundin
5472036931 Connect up custom serial in dc configuration
This connects up the custom serial code in the configure dive computer
dialogs.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-09-12 14:02:32 -07:00
Anton Lundin
a42df06dbf Lift dis- and connect out from config operations
When working with ostc's via bluetooth, they will reboot and exit
bluetooth mode when you send the disconnect command. Thats kinda
inconvenient when you would like to read your settings, change something
and write it back, you need to start bluetooth mode on your device
twice.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-09-12 14:02:12 -07:00
Anton Lundin
c0c4b5c4b3 Configure divecomputers: add delegates for setpoint configuration
This adds delegates to simplify configuration of setpoint values in the
OSTC's.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-09-10 15:37:13 -07:00
Anton Lundin
865c4aedee Save settings in closeEvent, not destructor
This switches to use the closeEvent to save settings and cleanup instead
of the destructor.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-09-10 09:40:04 -07:00
Anton Lundin
b76a0f0b97 Wire gui for diagnostic logs from dc configuration
This copies peaces from the downloadfromdivecomputer dialog into the
configuredivecomputerdialog and connects them to be able to create a
logfile form the configuration of the divecomputer.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-05-27 15:37:50 -07:00
Dirk Hohndel
b2f4896f3c Whitespace cleanup
Plus removal of a few qDebug() calls I introduced earlier.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-28 21:02:28 -08:00
Dirk Hohndel
003f5d18b6 Automatic OSTC firmware update: download file and try to install
This successfully downloads the hex file.
The actuall update of the OSTC fails before it gets started with a crash
when the ConfigureDiveComputer object is created.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-28 10:22:46 -08:00
Dirk Hohndel
0be0cdb046 OSTC firmware update prompt: use the stable changelog files
Heinrichs Weikamp is giving us stable URLs from which we can get the
latest stable version. The parsing is a bit simplistic, but it seems to
work.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-28 07:37:11 -08:00
Dirk Hohndel
2461a731fc Progress towards automatic OSTC firmware updates
Better parsing of the website data, a simpe dialog that informs the user
that they should upgrade their firmware.

Still doen't call the right code path to DO the upgrade.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-28 06:39:30 -08:00
Dirk Hohndel
52084c80f7 Move OSTC firmware check around a bit
This rearranges the code so we can call it from the download dialog and
tell the user if there is a newer version of the firmware available.

This needs a proper dialog and needs to be hooked up so that the user can
accept the suggestion and go directly to the firmware update code.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-27 08:31:51 -08:00
Robert C. Helling
230ba7ace8 Read current version from H&W web page
This is only partial. It prints the current version string (to be
processed by a regex) via qDebug().

Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-27 07:14:31 -08:00
Anton Lundin
ac207ee5ff Emit the successful message the right way
The successful message was emitted in a some what older way then the
other messages so it was always emitted, even on error.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-08 08:38:50 -08:00
Anton Lundin
ee7c86f206 Create a delegate for depth and gas components
This creates a delegate to simplify the handling of gas components and
the change depth.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-27 15:41:55 -07:00
Anton Lundin
0e3a9328bc Create a delegate for gas type columns
This creates a delegate for the type column to choose the type value for
gases that is less confusing then the raw value.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-27 15:41:51 -07:00
Anton Lundin
eacf8fc623 Copy the configure OSTC3 ui to the OSTC UI
Just renumber the ui components. _3 for OSTC.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-27 14:40:09 -07:00
Anton Lundin
8f89d3cbec Remove now obsolete forward declaration
We now include the Ui header file, so we can remove the forward
declaration.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-27 14:35:50 -07:00
Anton Lundin
74f27a0a39 Add support to reset OSTC3 settings to default
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-18 15:22:22 -07:00
Anton Lundin
5a394aaff6 Make ConfigureDiveComputerDialog ui a class member
Almost all of our other classes have the ui class as a class member in
the controller code. This switches ConfigureDiveComputerDialog to that
model.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-16 11:08:18 +02:00
Anton Lundin
9c0e2fc823 Connect the Suunto Vyper Configuration ui
This code connects up the configuration ui with the backing
data structures thats gets read/written to/from the devices.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-12 12:32:21 -04:00
Joseph W. Joshua
a9b55d7f0d Change Dive Computer Configuration dialog
Changes the layout of the ConfigureDiveComputer dialog to use a
list of supported computers on the left, with a stacked widget
showing the configurable details.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:15 -07:00
Joseph W. Joshua
cc6c385f33 Start Work on Firmware Update
This patch implements the first step towards OSTC 3 firmware update.
Its not much, just file selection, but I will build up on it from there.

Implements a thread to initiate firmware updates. Currently, this is
for the OSTC 3.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:15 -07:00
Joseph W. Joshua
8ccf2e8f1d Change ConfigureDiveComputerDialog to use tabbed interface
Changes the dive computer configuration dialog to use a
tabbed interface. This will make it easier to add new
dive computer models to the interface.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:14 -07:00
Joseph W. Joshua
aad60ef6da Working XML Backup and Restore
The ConfigureDiveComputer class now has functions for complete
XML backup and restore. These dump the loaded settings on a
dive computer to an XML file, and there is an option to
restore them.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:14 -07:00
Joseph W. Joshua
e54d7d9178 Backup basic settings as XML
This patch enables XML backup. We can now save the settings
to an XML file. Currently this backs up just the basic stuff
such as custom text, language and brightness.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:14 -07:00
Joseph W. Joshua
20eb62a98a Polish up on classes
This patch polishes up on all classes added for dive computer
configuration to give a clean workflow. The classes can now
write and read data from the OSTC 3.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-13 10:48:11 -07:00
Joseph W. Joshua
4fc16b1674 Move divecomputer configuration code to different files
This splits the code in configuredivecomputer.cpp into multiple files.
The read and write threads are moved to configuredivecomputerthreads.h/cpp,
and the device details class is moved to devicedetails.h/.cpp

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 12:06:42 -03:00
Joseph W. Joshua
2432350064 Add brightness setting
Adds a setting to control the device's brightness. Currently I
have only the OSTC 3. Will add more afterwards.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 12:01:56 -03:00
Joseph W. Joshua
3e127a059f Create class to write settings to dive computer
Adds a class to write settings to dive computer, and modifies
the existing ones to integrate it.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 12:01:56 -03:00
Joseph W. Joshua
a7c9b25b05 Read basic details from dive computer
Added classes for reading data from dive computer. This is
at the basic level and I will expand it as I go along.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 12:01:54 -03:00
Joseph W. Joshua
791fbee260 Load vendor list and product list
Using code from 'downloadfromdivecomputer' class, this code
loads the vendors and products to the respective comboboxes.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 11:59:15 -03:00
Joseph W. Joshua
ec02737eda Create Dive Computer configuration dialog
Create a dialog for reading and writing settings to and
from dive computers, with a menu entry in MainWindow to
open the dialog.

I will build up on this dialog and change it as needed.

Signed-off-by: Joseph W. Joshua <joejoshw@gmail.com>
Signed-off-by: Thiago Macieira <thiago@macieira.org>
2014-08-09 11:50:14 -03:00