Skip to content

Commit e462b9e

Browse files
authored
Merge pull request #260 from BCDA-APS/bugfixes
bugfixes
2 parents fced530 + abdb556 commit e462b9e

File tree

4 files changed

+25
-4
lines changed

4 files changed

+25
-4
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,5 @@ issue*.py
1717
build_log.txt
1818

1919
.ipython_*.log*
20+
.vscode/
21+
.logs/

CHANGES.rst

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,21 @@
44
Change History
55
##############
66

7-
:1.1.15: expected by *tba* :
7+
:1.1.16: expected by *tba* :
8+
9+
:1.1.15: expected by *2019-11-29* : bug fixes
10+
11+
* `#259 <https://github.com/prjemian/spec2nexus/issues/259>`_
12+
resolve AssertionError from setup_lorentzian_swait
13+
14+
* `#258 <https://github.com/prjemian/spec2nexus/issues/258>`_
15+
swait record does not units, some other fields
16+
17+
* `#255 <https://github.com/prjemian/spec2nexus/issues/255>`_
18+
plans: resolve indentation error
19+
20+
* `#252 <https://github.com/prjemian/spec2nexus/issues/252>`_
21+
synApps: add asyn record support
822

923
:1.1.14: released *2019-09-03* : bug fixes, more synApps support
1024

apstools/plans.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ def addDeviceDataAsStream(devices, label):
7878
devices = [devices]
7979
for d in devices:
8080
yield from bps.read(d)
81-
yield from bps.save()
81+
yield from bps.save()
8282

8383

8484
def execute_command_list(filename, commands, md={}):

apstools/synApps/swait.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
DynamicDeviceComponent as DDC,
4747
FormattedComponent as FC)
4848
from ophyd import EpicsSignal, Signal
49+
from ophyd.signal import EpicsSignalBase
4950

5051
from ._common import EpicsRecordDeviceCommonAll, EpicsRecordFloatFields
5152
from .. import utils as APS_utils
@@ -90,7 +91,7 @@ def _swait_channels(channel_list):
9091
return defn
9192

9293

93-
class SwaitRecord(EpicsRecordFloatFields, EpicsRecordDeviceCommonAll):
94+
class SwaitRecord(EpicsRecordDeviceCommonAll):
9495
"""
9596
synApps swait record: used as $(P):userCalc$(N)
9697
@@ -99,6 +100,10 @@ class SwaitRecord(EpicsRecordFloatFields, EpicsRecordDeviceCommonAll):
99100
~reset
100101
101102
"""
103+
precision = Cpt(EpicsSignal, ".PREC")
104+
high_operating_range = Cpt(EpicsSignal, ".HOPR")
105+
low_operating_range = Cpt(EpicsSignal, ".LOPR")
106+
102107
calculated_value = Cpt(EpicsSignal, ".VAL")
103108
calculation = Cpt(EpicsSignal, ".CALC")
104109

@@ -224,7 +229,7 @@ def _setup_peak_swait_(calc, desc, swait, ref_signal, center=0, width=1, scale=1
224229
"""
225230
# consider a noisy background, as well (needs a couple calcs)
226231
assert(isinstance(swait, SwaitRecord))
227-
assert(isinstance(ref_signal, Signal))
232+
assert(isinstance(ref_signal, EpicsSignalBase))
228233
assert(width > 0)
229234
assert(0.0 <= noise <= 1.0)
230235
swait.reset()

0 commit comments

Comments
 (0)