Skip to content

Commit 53a0bd5

Browse files
committed
Update HWM handling in dfmux DAQ code
* Include only boards from the HWM that are found to be online in DAQ stream * More efficient filtering by bolometer state Neither of these features are used in normal SPT-3G operation, but may be used for testing.
1 parent 2837b28 commit 53a0bd5

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

dfmux/onlinescripts/record_bolodata.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
unit='Data Acquisition')
6868
import pydfmux
6969
hwm = pydfmux.load_session(open(args.hardware_map, 'r'))['hardware_map']
70-
boards = hwm.query(pydfmux.Dfmux)
70+
boards = hwm.query(pydfmux.Dfmux).get_online()
7171
boards.resolve()
7272
boards = boards.serial
7373

dfmux/python/HardwareMapTools.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,8 @@ def __init__(self, pydfmux_hwm, pathstring=None, state=[]):
4747
chan_map_query = pydfmux_hwm.query(pydfmux.ChannelMapping)
4848

4949
if len(state) > 0:
50-
for bolo in pydfmux_hwm.query(pydfmux.Bolometer):
51-
if bolo.readout_channel:
52-
bolo.state = bolo.retrieve_bolo_state().state
53-
pydfmux_hwm.commit()
50+
bolos = pydfmux_hwm.query(pydfmux.Bolometer)
51+
bolos.load_bolo_states(commit=True)
5452
chan_map_query = chan_map_query.join(pydfmux.ChannelMapping, pydfmux.Bolometer).filter(pydfmux.Bolometer.state._in(state))
5553

5654
for bolo in chan_map_query:

0 commit comments

Comments
 (0)