run("RFscan/phase_scan_data.py") for station in station_list: req = caget(station + "-RSYS:PHASE-SCAN-REQUIRED") if req == "True": bpm_ch = station_list[station]["bpm_ch"] bpm_field = bpm_list[bpm_ch]["bpm_field"] print(station + "-RSYS:PHASE-SCAN-REQUIRED", 0)