diff --git a/commands.py b/commands.py index 4200759..1508a69 100644 --- a/commands.py +++ b/commands.py @@ -80,18 +80,13 @@ def frappy_start(**services): frappy_config = session.devices.get('frappy_config') for service in SERVICES: if services.get(service) == '': - seaconn = session.devices.get('seaconn') - if seaconn and seaconn._attached_secnode: - seaconn.communicate('frappy_remove %s' % service) + seaconn = session.devices.get('seaconn') + if seaconn and seaconn._attached_secnode: + seaconn.communicate('frappy_remove %s' % service) used_cfg = {} - # check for duplication of cfgs - for service in SERVICES: - cfginfo = services.get(service) - all_cfg = {} new_cfg = [] remove_cfg = [] - add_setups = [] for service in SERVICES: secnode = session.devices.get('se_' + service) cfginfo = services.get(service) @@ -103,9 +98,9 @@ def frappy_start(**services): else: if cfginfo: new_cfg.append((service, secnode, cfginfo)) - all_cfg[service] = cfginfo else: remove_cfg.append(secnode) + all_cfg[service] = cfginfo if secnode: secnode('') diff --git a/setups/frappy.py b/setups/frappy.py index d5cded1..3e73588 100644 --- a/setups/frappy.py +++ b/setups/frappy.py @@ -49,11 +49,11 @@ printinfo("===================================================================== printinfo("Welcome to the NICOS frappy secnode setup!") printinfo(" ") printinfo("Usage:") -printinfo(" frappy_main('
') # change main SE configuration (e.g. cryostat)") -printinfo(" frappy_stick('') # change sample-stick configuration") -printinfo(" frappy_stick('') # remove stick") -printinfo(" frappy_main('') # remove main SE apparatus") -printinfo(" frappy_main() # show the current SE configuration") +printinfo(" frappy('
') # change main SE configuration (e.g. cryostat)") +printinfo(" frappy('
', '') # change main and stick cfg") +printinfo(" frappy(stick='') # remove stick") +printinfo(" frappy('') # remove main SE apparatus") +printinfo(" frappy() # show the current SE configuration") printinfo("=======================================================================================") set_se_list() '''