Commit graph

18 commits

Author SHA1 Message Date
Berthold Stoeger
9ec7aa7fd7 Fix typo: LENGHT -> LENGTH 2017-11-17 15:29:42 +01:00
Dirk Hohndel
abc6c7d2b3 Assignment instead of test for equality
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-08-26 12:17:19 -07:00
Linus Torvalds
6554e4f21e Update the OSTC dive computer configuration to use the generic 'timesync' interface
Jef made the OSTC interface be a generic 'dc_device_timesync()' and so
the old OSTC-specific code doesn't exist any more.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-08-20 21:03:52 -07:00
Anton Lundin
d77de11a1d configure ostc3: Correct code for right button
Back when I wrote this code I made a typo. This fixes it.

Reported-By: Alexander Gottwald <jugendtrainingtsck@gmail.com>
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-08-04 09:50:44 -07:00
Dirk Hohndel
9e45999a01 Fix some warnings
Two unused variables and one case of sign confusion.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-05-06 11:12:28 -07:00
Anton Lundin
f14ad7f183 Implement OSTC4 specific settings
Signed-off-by: Anton Lundin <glance@acc.umu.se>
2017-05-04 10:50:15 -07:00
Anton Lundin
5a4e1a5586 Connect up all the OSTC4 common settings
Connect up all the settings that are the same, and remove those who are
not, and correct those who only are minor differences.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
2017-05-04 10:50:15 -07:00
Anton Lundin
527763f306 Start to read/write and present some OSTC4 settings
This is mostly copy-paste from the ostc3 case, but there are some minor
differences. Some minor things have different meaning, and there's a
slightly different command set, but I couldn't figure out a sane way of
joining them.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
2017-05-04 10:50:15 -07:00
Anton Lundin
4cbf64bf99 Wire up a skeleton for configure OSTC 4
Signed-off-by: Anton Lundin <glance@acc.umu.se>
2017-05-04 10:50:15 -07:00
Dirk Hohndel
b368ecd5aa Add SPDX header to remaining core files
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-04-29 13:32:55 -07:00
Jef Driesen
f8203b8efe Cleanup some unnecessary include statements
Some of these header files are no longer necessary, and will be removed
from libdivecomputer in the near future.

Signed-off-by: Jef Driesen <jef@libdivecomputer.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-04-13 18:02:47 -07:00
Jeremie Guichard
597539ce39 Fix double to int truncation in C++ code
Wfloat-conversion enabled for C++ part of the code
Fix warnings raised by the flag using lrint

Original issue reported on the mailing list:
The ascent/descent rates are sometimes not what is expected.
E.g. setting the ascent rate to 10m/min results in an actual
ascent rate of 9m/min.
This is due to truncating the ascent rate preference,
then effectively rounding up the time to reach each stop to 2s intervals.
The result being that setting the ascent rate to 10m/min
results in 20s to ascend 3m (9m/min), when it should be exactly 18s.

Reported-by: John Smith <noseygit@hotmail.com>
Reported-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Jeremie Guichard <djebrest@gmail.com>
2017-03-24 09:39:25 -07:00
Martin Měřinský
95d5771513 We use 'setpoint' in UI. Use it also for documentation and comments. No semantic change. 2017-03-11 08:09:07 -08:00
Anton Lundin
3b884c2e7c Use get_descriptor instead of hard-coded switch's
This starts using the newly lifted out get_descriptor in configure dive
computer, instead of previously hard-coded out of date
switch-statements.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2016-12-28 22:40:18 -08:00
Anton Lundin
2497ecf16d configure ostc3: Correct typos
This fixes a copy-paste error made by me that caused
tempSensorOffset to first be set the wrong way and then overridden by
pressureSensorOffset.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2016-11-07 21:08:28 -08:00
Anton Lundin
ffa3c48593 Rewrite libdivecomputer custom serial code
This rewrites the custom serial code to use the new api which I
implemented in the Subsurface-branch of libdivecomputer.

This is a bit to big patch but I haven't had the time to break it down
into more sensible patches.

This rewrite enables us to support more ftdi based divecomputer
communication and is tested with both a OSTC3, OSTC2N and a Suunto
Vyper, all over the libftdi driver.

The bluetooth code paths are tested to, and should work as before.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2016-09-17 15:47:37 -07:00
Rick Walsh
62b989979e Fix broken Bluetooth support
This partially reverts Commit 39313c5

Reported-and-analyzed-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2016-04-18 06:01:01 -07:00
Dirk Hohndel
7be962bfc2 Move subsurface-core to core and qt-mobile to mobile-widgets
Having subsurface-core as a directory name really messes with
autocomplete and is obviously redundant. Simmilarly, qt-mobile caused an
autocomplete conflict and also was inconsistent with the desktop-widget
name for the directory containing the "other" UI.

And while cleaning up the resulting change in the path name for include
files, I decided to clean up those even more to make them consistent
overall.

This could have been handled in more commits, but since this requires a
make clean before the build, it seemed more sensible to do it all in one.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2016-04-04 22:33:58 -07:00
Renamed from subsurface-core/configuredivecomputerthreads.cpp (Browse further)