frappy_psi: Added support for changing the observation frequency & number of scans. Further, added an automatic dashboard load on file setup, and a template dashboard for the Scout device.

This commit is contained in:
2025-06-13 07:58:25 +02:00
parent 365f0a2374
commit 2fce39c381
4 changed files with 110 additions and 44 deletions

View File

@@ -31,9 +31,18 @@ def get_single_pulse_block(name, pulse_width, pulse_height, relaxation_time, pha
a dictionary which can be updated with others to generate a larger, more complex sequence.
'''
if(relaxation_time.strip()[-1] == 'u'):
relax_time = float(relaxation_time.strip()[:-1])
elif(relaxation_time.strip()[-1] == 'n'):
relax_time = float(relaxation_time.strip()[:-1]) * 1000
if(relaxation_time.strip()[-1] == 'm'):
relax_time = float(relaxation_time.strip()[:-1]) / 1e3
if(relaxation_time.strip()[-1] == 's'):
relax_time = float(relaxation_time.strip()[:-1]) / 1e6
ph = name + '_phase'
rl = name + '_relaxation'
block = se.generate_default_sequence([ ph, rl ], [ pulse_width, relaxation_time ])
block = se.generate_default_sequence([ ph, rl ] if relax_time > 0 else [ ph ], [ pulse_width, relaxation_time ] if relax_time > 0 else [pulse_width])
# COLUMNNS
# PH column
@@ -41,9 +50,11 @@ def get_single_pulse_block(name, pulse_width, pulse_height, relaxation_time, pha
block['columns'][ph]['Delay'] = str(pulse_width)
block['columns'][ph]['F1_UnBlank']['value'] = '1'
block['columns'][ph]['Rx_Blank']['value'] = '1'
# relaxation column
block['columns'][rl]['F1_UnBlank']['value'] = '1'
block['columns'][rl]['Rx_Blank']['value'] = '1'
if(relax_time > 0):
# relaxation column
block['columns'][rl]['F1_UnBlank']['value'] = '1'
block['columns'][rl]['Rx_Blank']['value'] = '1'
if(phase_cycle != ''):
table_name = f'ph_{name}'