- docs/did_you_know/: one short tip per feature added since May 2026 (<date>-<slug>.md, YAML front matter: added/tags/details), listed newest first; index.md describes the format for adding more. - New pages for features that had none: launching, command_history, tab_completion, live_gui, tweak, scanning, status_server, channel_access, shared_files, schematic_panels. Wired into index.rst together with the existing queues page. - Fix archiver_stripchart/listening_monitor: the method is archiver.strip_plot (strip_chart does not exist on DataHub); document the per-device .strip_plot(). - NAMESPACE_MONITOR_FORMAT.md: scan monitoring is wired into Daq's scan callbacks since 2026-09-09. - scripts/eco-docs (+ -install-user-service): build the docs from an own clone and serve them over HTTP as user systemd units, rebuilt by a timer; a failed build never replaces the served site.
2.3 KiB
Tweaking with live detector readout
tweak moves an adjustable step by step from the keyboard. It can now record
detectors at every step and plot them live, tweak up to four axes at once, and
run as a panel in notebooks and the desktop.
Tweak and watch a signal
mot.tweak(0.1, detectors=[mon_opt.intensity])
Use the arrow keys to move (left/right) and to double or halve the step
(up/down). s returns to the start position and q ends the tweak. While
you tweak, the detectors are read at every position (averaged while the
position stays put) and plotted live against the position. Afterwards the data
is still there:
mot._tweak_instance.recorder.to_dataframe() # Adjustables
mot._tweak_recorder.to_dataframe() # EPICS motor records
When the tweak ends it prints the number of points recorded and where to find them.
Several axes: stacked keyboard rows
from eco.elements.adjustable import Tweak
Tweak((m1, 0.1), (m2, 0.1), (m3, 0.05), detectors=mon_opt.intensity).tweak()
One adjustable uses the arrow keys and two use the arrows as x/y. Three or four adjustables each get a keyboard row (first adjustable lowest):
| Adjustable | neg dir | step × 2 | step / 2 | pos dir |
|---|---|---|---|---|
| 1st | j |
k |
l |
; |
| 2nd | u |
i |
o |
p |
| 3rd | 7 |
8 |
9 |
0 |
With four adjustables the rows shift down one: the 1st uses m , . /,
and the others take the rows above. stacked=True forces this layout for one
or two adjustables too. With several axes the detector plot is stacked over the
step number.
Front-ends: terminal, Qt panel, notebook panel
eco picks the front-end automatically. In a terminal you get the keyboard loop
above; in a notebook or the desktop console you get a tweak panel with buttons
and the same keys under "keypress control". Force one with ui=:
mot.tweak(0.1, detectors=[diode], ui="terminal") # or "qt", "ipy"
While a terminal tweak waits for keys, other open GUI windows (live plots, camera viewers) keep updating.
No display? Plots in the terminal
Over plain ssh without X, or with ECO_NO_X=1 set, no Qt windows are opened
and the detector plot is drawn as text right in the terminal. See
{doc}terminal_plots.