68 Commits
Author SHA1 Message Date
John Henry BealeandClaude Opus 5.5 a3edcf7dca rename 'event trigger' to 'labelling event' (main page and preferences)
Only the displayed label: the settings key event_trigger and the JFJ
header key trigger_event are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 10:51:50 +02:00
John Henry BealeandClaude Opus 5.5 6c898059fd chip type, motion, delay and run time on the experimental parameters page
- chip type (same selection as the Fix Target type), motion mode 4..7,
  wait in pulses (mode 5/7) and section size (mode 6/7): these edit their
  keys in the Fix Target parameter text box and follow it when typed;
  text box and chip type are kept in the settings
- tmove is fixed to one FEL pulse (fel_per ms for mode 5, 1 shot for
  mode 7): not editable, set at the collection for every object
- the collection refuses objects with a mode other than 4..7
- laser delay PV readback and the calculated laser to X-ray delay
- estimated run time of the chip from the CTA sequence lengths
  (motion_run_pulses), including the checks that would abort it
- orange warning for twait not a multiple of tmove or an invalid ssz
- ModuleFixTarget: parse_param/format_param for the parameter text

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 08:36:07 +02:00
John Henry BealeandClaude Opus 5.5 4be0f03437 record chip type, motion mode and laser delay in the JFJ header
- header_appendix: chip_type, motion_mode, motion_param, fel_per_ms,
  delay_pulses, laser_delay_ns and total_delay_ns, taken from the job
  that actually runs (Jungfrau.config), not from the GUI
- laser delay read from SLAAR03-LTIM-PDLY:DELAYNS_SLOW (ns, negative:
  laser before the X-rays); total = laser - delay_pulses * fel_per;
  trigger_delay now holds the total delay
- motion_delay_pulses(): trigger to X-ray pulses per mode, same rules as
  the CTA sequences (mode 6/7 nominal)
- remove the unused manual laser_delay from the run parameters
- fix laser_pulse_energy, which was written with the trigger delay

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 08:24:38 +02:00
John Henry BealeandClaude Opus 5.5 a2873056c3 editable DAQ fields on the main page, kept in sync with the preferences
- data storage: pgroup, protein and prefix are editable (letters, digits
  and _ only); last run and last path stay read only
- experimental parameters (was empty): incident energy, event trigger,
  triggered, unit cell a b c alpha beta gamma and space group
- every change is saved immediately (no Enter needed: the Collect button
  takes no focus, so editingFinished would not fire before a collection)
- the preferences window is a single instance; main page and preferences
  update each other, so the preferences no longer write back stale group
  values; pgroup/energy/event trigger changes force a new jungfrau object
- the fields are locked during collections and motor sequences (left tabs)
- lower case labels

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 14:10:59 +02:00
John Henry BealeandClaude Opus 5.5 5a584fb7de keep edited BS/PV channel lists across restarts
The 'if not in keys' guards of the channel list defaults were commented
out, so both lists were reset to the built-in defaults at every start
(and logged as 'not defined'). The defaults are now only used when no
list is saved yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 13:19:38 +02:00
John Henry BealeandClaude Opus 5.5 c260c60888 edit the BS and PV channel lists in a separate dialog
The channel lists were one very long line in the preferences tree. They
are now buttons ("edit beam-sync channels (N)...") opening a dialog with
one channel per line; OK saves the list (empty lines and duplicates
removed, space separated pastes work) and forces a new jungfrau object.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 13:11:57 +02:00
John Henry BealeandClaude Opus 5.5 f811cf286e store absolute post sample tube out positions
The out position was one x and one y delta added to the upstream and
downstream in positions, and "use current position as out" computed the
deltas from the upstream motors only, so a downstream out position could
not be stored.

- preferences: out X/Y upstream and downstream (absolute) replace the out
  deltas; "use current position as out" stores all five axes
- existing settings: the absolute out positions are created once from
  in + delta
- the deltas are still written (upstream out - in) for older SwissMX
  versions sharing the settings file
- move_post_tube uses the absolute out positions (falls back to in+delta)

The collimator already stores absolute out positions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 13:05:51 +02:00
John Henry BealeandClaude Opus 5.5 5358424aa4 show beam position, energy and unit cell with full precision in preferences
pyqtgraph's 'decimals' is the number of significant figures: beam_x/beam_y
(decimals 2) showed 1613.25 as 1.6e+03, and energy/unit cell (decimals 3)
showed 12.398 as 12.4 and 109.47 as 109. Editing such a field stored the
rounded value. Use 6 significant figures (2-3 decimal places).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 12:57:13 +02:00
John Henry BealeandClaude Opus 5.5 eab83c0fae fix mixed sim modes, camera parameter parsing and silent Collect
- pv_monitor_add skips simulated motor widgets one by one instead of
  asserting sim&0x10 (mixed modes such as --sim 0x0ef crashed at startup)
- preferences: roi/binning numbers written as decimals (8.0) are parsed as
  one number and rounded; a roi without 4 or binning without 2 values is
  not saved (8.0 used to become 8,0 and corrupt the camera roi)
- camera.set_param refuses a roi/binning with the wrong number of values
- Collect warns when there is nothing to scan or the task is not fix target

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 08:34:13 +02:00
John Henry Beale 8dfd022d73 only alpha numerical characters to protein and prefix fields - removes wrong data path bug 2026-08-24 12:26:26 +02:00
John Henry Beale 5b4f7f3f2a made data storage fields active and display real values 2026-08-24 12:13:13 +02:00
John Henry Beale ed41dcf49e added YAG button to gui and YAG reference positions to preferences 2026-08-24 11:50:33 +02:00
John Henry Beale 644c23ac50 added new detector postion 'safe' so the detector tube clear position can be set and watched for. This is done with a new function 2026-08-24 11:18:09 +02:00
John Henry Beale 64d9ccacc7 add coarse-y to preferences 2026-08-24 11:05:09 +02:00
John Henry Beale 1a22e8300a saving to file bug fixed 2026-06-12 07:50:51 +02:00
John Henry Beale c3a92ff242 unsure of changes - sort after beamtime 2026-05-21 07:40:29 +02:00
zamofing_t 123f184074 fixing escape sequences, adding readme for mode 7 2026-05-13 16:39:06 +02:00
John Henry Beale 810e96fe6b fixed dict(map..) bug - .conf can now be updated 2026-05-13 13:36:19 +02:00
John Henry Beale c4c5ea6491 running changes made by M.Appleby and J.Beale. Mainly to update due to python 3.10 2025-11-10 10:47:31 +01:00
Appleby Martin Vears 5d4808e6a1 Changes to psi_device and app_config to add gui options for JFJoch. PSI-device now parses these messages in a message to JFJoch 2024-11-25 11:10:19 +01:00
zamofing_t 3fc4f50c15 optimize imports and cleanup code 2024-09-25 12:36:48 +02:00
zamofing_t e63c814662 SFELPHOTON-1128: debug stup-and-go motion 2024-05-23 16:33:43 +02:00
zamofing_t 153333f336 changes by the martin and John 2024-05-15 15:22:01 +02:00
zamofing_t c270467e44 towards cta 2024-01-22 16:01:55 +01:00
zamofing_t e41a3ed7ed fixing coordinate transformation 2023-12-12 17:06:25 +01:00
zamofing_t fd3d36396d changes of John and Martin 2023-11-28 12:01:11 +01:00
zamofing_t e910083b1a put try/catch for all monitor callbacks (suggestion Xiaoqiang) 2023-06-30 14:32:48 +02:00
zamofing_t 6b86a1c319 minor fixes 2023-06-23 14:57:32 +02:00
zamofing_t 0b63ebaa14 add missing files, fix coordinate transformation 2023-06-23 12:12:02 +02:00
zamofing_t 523a154cd7 major fixes 2023-05-24 17:37:51 +02:00
zamofing_t 6712251b9d change defaults and limits 2023-05-24 12:02:27 +02:00
zamofing_t c1a674c91b add gonio default positions 2023-05-24 11:53:41 +02:00
zamofing_t 816d06f7c4 change requests: SFELPHOTON-640 2022-11-23 13:19:53 +01:00
zamofing_t c75c2c1d33 use new ESB_MX module and better triggerSync 2022-10-04 17:27:13 +02:00
zamofing_t 7a67889992 fix in synchronization, add padding frames for JF 2022-09-28 16:56:32 +02:00
zamofing_t a186d256d3 various fixes (post_sample_tube, timing etc.) 2022-09-28 14:52:13 +02:00
zamofing_t 30a9c77230 add DAQ params, better autofocus 2022-09-27 11:11:38 +02:00
zamofing_t d8399e901c copy current SwissMX.conf, minor fixes 2022-09-21 16:11:03 +02:00
zamofing_t 1393269ceb add app_utils for motion_assert, contextMenu og GraphItem, further fixes 2022-09-21 11:06:10 +02:00
zamofing_t 158150a954 work on config, fiducial, autofocus 2022-09-20 12:33:41 +02:00
zamofing_t 33ce6c99f3 various stuff
update fiducial z when moved
autofocus param
camera settings
2022-09-16 17:04:12 +02:00
zamofing_t ba4f5feecb various fixes 2022-09-16 12:25:36 +02:00
zamofing_t 14260851cf enhance calibration + minor fixes 2022-09-14 09:44:57 +02:00
zamofing_t e215f3abea fix in trace and app config 2022-09-09 18:14:59 +02:00
zamofing_t 189c98951a cleanup 2022-09-09 15:54:18 +02:00
zamofing_t f70421d2f3 avoid blocking with matplotlib, parameter save stuff 2022-09-09 10:05:44 +02:00
zamofing_t 0a15899ee6 wip 2022-09-08 15:55:14 +02:00
zamofing_t 1d26a309e7 app config, tweakers, move_* functions 2022-09-07 18:16:59 +02:00
zamofing_t cbae02c597 rework graphic opbect and coordinate transformation 2022-09-06 10:07:11 +02:00
zamofing_t d263c09028 rework config/parameter setting part 2 2022-09-05 15:34:40 +02:00