Skip to content

Commit

Permalink
Beamline test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
noemifrisina committed Dec 10, 2024
1 parent 6e26b21 commit fb09094
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,7 @@ def start_i24(
raise ValueError(msg)

# Open the hutch shutter
# SSX_LOGGER.warning("TESTING, not opening shutter!")
yield from bps.abs_set(shutter, ShutterDemand.OPEN, wait=True)

return start_time
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -240,14 +240,16 @@ def save_screen_map() -> MsgGenerator:

SSX_LOGGER.info(f"Saving {litemap_path.as_posix()} currentchip.map")
with open(litemap_path / "currentchip.map", "w") as f:
SSX_LOGGER.debug("File opened for writing")
SSX_LOGGER.debug("Printing only blocks with block_val == 1")
for x in range(1, 82):
block_str = "ME14E-MO-IOC-01:GP%i" % (x + 10)
block_val = int(caget(block_str))
if block_val == 1:
SSX_LOGGER.info("%s %d" % (block_str, block_val))
SSX_LOGGER.info(f"{block_str} {block_val}")
line = "%02dstatus P3%02d1 \t%s\n" % (x, x, block_val)
f.write(line)
SSX_LOGGER.debug(f"Should have written line {line}")
yield from bps.null()


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def _params_file_location() -> Path:
else:
filepath = INTERNAL_FILES_PATH

print(f"CREATING PARAM FOLDER IN: {filepath}")
filepath.mkdir(parents=True, exist_ok=True)

return filepath
Expand Down
4 changes: 3 additions & 1 deletion src/mx_bluesky/beamlines/i24/serial/write_nexus.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
ExtruderParameters,
FixedTargetParameters,
)
from mx_bluesky.beamlines.i24.serial.parameters.constants import LITEMAP_PATH
from mx_bluesky.beamlines.i24.serial.setup_beamline import Eiger, caget, cagetstring


Expand All @@ -34,7 +35,8 @@ def call_nexgen(
):
# NOTE Nexgen server is still on nexgen v0.7.2 (fully working for ssx)
# Will need to be updated, for correctness sake map needs to be None.
current_chip_map = "/dls_sw/i24/scripts/fastchips/litemaps/currentchip.map"
current_chip_map = (LITEMAP_PATH / "currentchip.map").as_posix()
# current_chip_map = "/dls_sw/i24/scripts/fastchips/litemaps/currentchip.map"
pump_status = bool(parameters.pump_repeat)
total_numb_imgs = parameters.total_num_images
elif expt_type == "extruder" and isinstance(parameters, ExtruderParameters):
Expand Down

0 comments on commit fb09094

Please sign in to comment.