Problems importing APD CCR dive logs.
Anton Lundin
glance at acc.umu.se
Wed Apr 18 08:19:51 PDT 2018
On 18 April, 2018 - Willem Ferguson wrote:
> On 18/04/2018 16:05, Miika Turkia wrote:
> >On Wed, Apr 18, 2018 at 4:14 PM, Willem Ferguson
> ><willemferguson at zoology.up.ac.za
> ><mailto:willemferguson at zoology.up.ac.za>> wrote:
> >
> > Dear Miika,
> >
> > Would you by any chance be prepared to look at the attached APD
> > dive log? The setpoint data are there and correctly identified in
> > the import dialog. However, it is not written to xml. Consequently
> > the setpoint is erroneously shown as the same value as pO2. Can it
> > be user error (that is, me)?
> >
> >
> >Sure, I can take a look. I just need to know, how the setpoint
> >should be stored in the XML. Currently setpoint is stored to po2
> >attribute, and I just need to know where it should be saved to fix
> >this.
> >
> >miika
>
> Hi Miika,
>
> As far as I can see, the setpoint column in the .apd text file
> contains values around 0.7 and 1.3. However, the po2 attribute in
> the xml generated from that input does not contain values around 0.7
> and 1.3. That probably means that the po2 attribute was not assigned
> correctly. This worked correctly for a pretty long time since I have
> apd xml files with accurate setpoints, but I do not have their text
> import files any more. So I suspect some code thing has changed that
> breaks it??
>
This fixes it:
diff --git i/desktop-widgets/divelogimportdialog.cpp w/desktop-widgets/divelogimportdialog.cpp
index dc68865bb..f525ec436 100644
--- i/desktop-widgets/divelogimportdialog.cpp
+++ w/desktop-widgets/divelogimportdialog.cpp
@@ -780,7 +780,7 @@ int DiveLogImportDialog::setup_csv_params(QStringList r, char **params, int pnr)
params[pnr++] = intdup(r.indexOf(tr("Sample stopdepth")));
params[pnr++] = strdup("pressureField");
params[pnr++] = intdup(r.indexOf(tr("Sample pressure")));
- params[pnr++] = strdup("setpointFiend");
+ params[pnr++] = strdup("setpointField");
params[pnr++] = intdup(r.indexOf(tr("Sample setpoint")));
params[pnr++] = strdup("separatorIndex");
params[pnr++] = intdup(ui->CSVSeparator->currentIndex());
diff --git i/tests/testparse.cpp w/tests/testparse.cpp
index b7ee086fa..503e48aeb 100644
--- i/tests/testparse.cpp
+++ w/tests/testparse.cpp
@@ -203,7 +203,7 @@ void TestParse::testParseHUDC()
params[pnr++] = intdup(-1);
params[pnr++] = strdup("pressureField");
params[pnr++] = intdup(-1);
- params[pnr++] = strdup("setpointFiend");
+ params[pnr++] = strdup("setpointField");
params[pnr++] = intdup(-1);
params[pnr++] = strdup("separatorIndex");
params[pnr++] = intdup(2);
@@ -491,7 +491,7 @@ void TestParse::parseDL7()
params[pnr++] = intdup(-1);
params[pnr++] = strdup("pressureField");
params[pnr++] = intdup(-1);
- params[pnr++] = strdup("setpointFiend");
+ params[pnr++] = strdup("setpointField");
params[pnr++] = intdup(-1);
params[pnr++] = strdup("separatorIndex");
params[pnr++] = intdup(3);
A simple typo from 2015, 8e08fdcc85a95fa31f47478f20cb6fa9579162fb
//Anton
--
Anton Lundin +46702-161604
More information about the subsurface
mailing list