diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-10-25 07:25:03 -0400 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-10-25 04:34:51 -0700 |
commit | 7273161acf294b78a48e193d57088430aa5cf3da (patch) | |
tree | 84170f22d437e25f59458e11015d97531c686fe8 | |
parent | 96386fbcc12837740863f4ad724fee8eb4fbee2a (diff) | |
download | subsurface-7273161acf294b78a48e193d57088430aa5cf3da.tar.gz |
Mares: add BT discovery logic
We don't have the "show all dive computers" logic on mobile, so we need
something like this.
Possibly we should use the libdivecomputer matching code if it exists,
but that's a much bigger change, let's do this incremental one for now.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | core/btdiscovery.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/core/btdiscovery.cpp b/core/btdiscovery.cpp index 8db1e02cc..36c1b4b9c 100644 --- a/core/btdiscovery.cpp +++ b/core/btdiscovery.cpp @@ -71,11 +71,14 @@ static dc_descriptor_t *getDeviceType(QString btName) if (btName.startsWith("Aladin")) product = "Aladin Sport Matrix"; } - if (btName == "Mares bluelink pro") { + if (btName.startsWith("Mares")) { vendor = "Mares"; // we don't know which of the dive computers it is, // so let's just randomly pick one product = "Quad"; + // Some we can pick out directly + if (btName == "Mares Genius") + product = "Genius"; } // The Pelagic dive computers (generally branded as Oceanic or Aqualung) |