Skip to content

Commit

Permalink
updates for release v1.16
Browse files Browse the repository at this point in the history
resolved: pulse-shape data loading has been skipped
  • Loading branch information
dpscience committed May 4, 2021
1 parent 502d41e commit 35ffacd
Show file tree
Hide file tree
Showing 6 changed files with 120 additions and 8 deletions.
2 changes: 1 addition & 1 deletion DDRS4PALS.pro
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ QT += core gui concurrent script printsupport network

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

TARGET = DDRS4PALS_1_0_15
TARGET = DDRS4PALS_1_0_16
TEMPLATE = app

RC_FILE = softwareIcon.rc
Expand Down
54 changes: 54 additions & 0 deletions GUI/drs4blinkinglight.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,57 @@
/****************************************************************************
**
** DDRS4PALS, a software for the acquisition of lifetime spectra using the
** DRS4 evaluation board of PSI: https://www.psi.ch/drs/evaluation-board
**
** Copyright (C) 2016-2021 Danny Petschke
**
** This program is free software: you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation, either version 3 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program. If not, see http://www.gnu.org/licenses/.
**
*****************************************************************************
**
** @author: Danny Petschke
** @contact: [email protected]
**
*****************************************************************************
**
** related publications:
**
** when using DDRS4PALS for your research purposes please cite:
**
** DDRS4PALS: A software for the acquisition and simulation of lifetime spectra using the DRS4 evaluation board:
** https://www.sciencedirect.com/science/article/pii/S2352711019300676
**
** and
**
** Data on pure tin by Positron Annihilation Lifetime Spectroscopy (PALS) acquired with a semi-analog/digital setup using DDRS4PALS
** https://www.sciencedirect.com/science/article/pii/S2352340918315142?via%3Dihub
**
** when using the integrated simulation tool /DLTPulseGenerator/ of DDRS4PALS for your research purposes please cite:
**
** DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018300530
**
** Update (v1.1) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018300694
**
** Update (v1.2) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018301092
**
** Update (v1.3) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S235271101930038X
**/

#include "drs4blinkinglight.h"
#include "ui_drs4blinkinglight.h"

Expand Down
54 changes: 54 additions & 0 deletions GUI/drs4blinkinglight.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,57 @@
/****************************************************************************
**
** DDRS4PALS, a software for the acquisition of lifetime spectra using the
** DRS4 evaluation board of PSI: https://www.psi.ch/drs/evaluation-board
**
** Copyright (C) 2016-2021 Danny Petschke
**
** This program is free software: you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation, either version 3 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program. If not, see http://www.gnu.org/licenses/.
**
*****************************************************************************
**
** @author: Danny Petschke
** @contact: [email protected]
**
*****************************************************************************
**
** related publications:
**
** when using DDRS4PALS for your research purposes please cite:
**
** DDRS4PALS: A software for the acquisition and simulation of lifetime spectra using the DRS4 evaluation board:
** https://www.sciencedirect.com/science/article/pii/S2352711019300676
**
** and
**
** Data on pure tin by Positron Annihilation Lifetime Spectroscopy (PALS) acquired with a semi-analog/digital setup using DDRS4PALS
** https://www.sciencedirect.com/science/article/pii/S2352340918315142?via%3Dihub
**
** when using the integrated simulation tool /DLTPulseGenerator/ of DDRS4PALS for your research purposes please cite:
**
** DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018300530
**
** Update (v1.1) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018300694
**
** Update (v1.2) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S2352711018301092
**
** Update (v1.3) to DLTPulseGenerator: A library for the simulation of lifetime spectra based on detector-output pulses
** https://www.sciencedirect.com/science/article/pii/S235271101930038X
**/

#ifndef DRS4BLINKINGLIGHT_H
#define DRS4BLINKINGLIGHT_H

Expand Down
12 changes: 8 additions & 4 deletions drs4settingsmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ DRS4PulseShapeFilterData& DRS4PulseShapeFilterData::operator=(const DRS4PulseSha
if (copy.m_stdDevTraceDataYArray)
memcpy(m_stdDevTraceDataYArray, copy.m_stdDevTraceDataYArray, __PULSESHAPEFILTER_SPLINE_TRACE_NUMBER*sizeof(float));


return *this;
}

Expand Down Expand Up @@ -1089,7 +1088,8 @@ bool DRS4SettingsManager::load(const QString &path)
parsePulseShapeData(m_pulseShapeFilter_meanDataA_Node, &meanData);
parsePulseShapeData(m_pulseShapeFilter_stddevDataA_Node, &stdDevData);

if (meanData.isEmpty() || stdDevData.isEmpty()) {
if (meanData.isEmpty()
|| stdDevData.isEmpty()) {
setPulseShapeFilterDataA(DRS4PulseShapeFilterData(), false);

m_pulseShapeFilterEnabledA_Node->setValue(false);
Expand All @@ -1102,6 +1102,8 @@ bool DRS4SettingsManager::load(const QString &path)

m_pulseShapeFilterEnabledA_Node->setValue(pPulseShapeFilterSettingsTag.getValueAt(m_pulseShapeFilterEnabledA_Node, &ok));
if (!ok) m_pulseShapeFilterEnabledA_Node->setValue(m_pulseShapeFilterEnabledA);


}
}
}
Expand Down Expand Up @@ -2591,10 +2593,11 @@ void DRS4SettingsManager::setPulseShapeFilterStdDevLowerFractionB(double value)

void DRS4SettingsManager::setPulseShapeFilterDataA(const DRS4PulseShapeFilterData &data, bool lockMutex)
{
if (lockMutex)
if (lockMutex) {
#ifndef __DISABLE_MUTEX_LOCKER
QMutexLocker locker(&m_mutex);
#endif
}

m_pulseShapeFilterDataA = data;

Expand All @@ -2612,10 +2615,11 @@ void DRS4SettingsManager::setPulseShapeFilterDataA(const DRS4PulseShapeFilterDat

void DRS4SettingsManager::setPulseShapeFilterDataB(const DRS4PulseShapeFilterData &data, bool lockMutex)
{
if (lockMutex)
if (lockMutex) {
#ifndef __DISABLE_MUTEX_LOCKER
QMutexLocker locker(&m_mutex);
#endif
}

m_pulseShapeFilterDataB = data;

Expand Down
2 changes: 1 addition & 1 deletion drs4settingsmanager.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@

#define __PULSESHAPEFILTER_SPLINE_TRACE_NUMBER 4381

#define __DISABLE_MUTEX_LOCKER
// #define __DISABLE_MUTEX_LOCKER

struct DRS4PulseShapeFilterRecordScheme {
enum Scheme : int {
Expand Down
4 changes: 2 additions & 2 deletions dversion.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@
/* change here before releasing a new version **/
#define NAME QString("DDRS4PALS")
#define MAJOR_VERSION QString("1")
#define MINOR_VERSION QString("15")
#define MINOR_VERSION QString("16")
#define VERSION_EXTENSION QString("- official -")
#define DATE_EXTENSION QString("2021-04-30")
#define DATE_EXTENSION QString("2021-05-04")

/* streaming on external storage device */
#define DATA_STREAM_VERSION 1
Expand Down

0 comments on commit 35ffacd

Please sign in to comment.