summaryrefslogtreecommitdiffstats
path: root/core/libdivecomputer.c
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2017-06-18 15:50:37 +0900
committerGravatar Linus Torvalds <torvalds@linux-foundation.org>2017-06-22 08:43:47 -0700
commitadd253ca9eee79f97de5bfd25a456102f49bef86 (patch)
tree3f2d04b6786fb4e2b57d41bd1adef78bf5c2b5ff /core/libdivecomputer.c
parentfc8068c57446d6db54e8f32215d6aee6f295e28f (diff)
downloadsubsurface-add253ca9eee79f97de5bfd25a456102f49bef86.tar.gz
Convert to new libdivecomputer custom IO model
Instead of being "custom serial", it's a IO model that allows serial or packet modes, independently of each other (ie you can have a bluetooth device that does serial over BT rfcomm and packet-based communication over BLE GATT with the same serial operations that describe both cases). Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'core/libdivecomputer.c')
-rw-r--r--core/libdivecomputer.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/libdivecomputer.c b/core/libdivecomputer.c
index d6492d162..7f0a459fc 100644
--- a/core/libdivecomputer.c
+++ b/core/libdivecomputer.c
@@ -1078,14 +1078,14 @@ const char *do_libdivecomputer_import(device_data_t *data)
err = translate("gettextFromC", "Unable to open %s %s (%s)");
-#if defined(SSRF_CUSTOM_SERIAL)
+#if defined(SSRF_CUSTOM_IO)
if (data->bluetooth_mode) {
-#if defined(BT_SUPPORT) && defined(SSRF_CUSTOM_SERIAL)
- rc = dc_context_set_custom_serial(data->context, get_qt_serial_ops());
+#if defined(BT_SUPPORT) && defined(SSRF_CUSTOM_IO)
+ rc = dc_context_set_custom_io(data->context, get_qt_serial_ops());
#endif
#ifdef SERIAL_FTDI
} else if (!strcmp(data->devname, "ftdi")) {
- rc = dc_context_set_custom_serial(data->context, &serial_ftdi_ops);
+ rc = dc_context_set_custom_io(data->context, &serial_ftdi_ops);
INFO(0, "setting up ftdi ops");
#else
INFO(0, "FTDI disabled");