Skip to content

Improve docs for set vs put and put_complete#72

Open
wakonig wants to merge 1 commit into
mainfrom
feature/put_complete
Open

Improve docs for set vs put and put_complete#72
wakonig wants to merge 1 commit into
mainfrom
feature/put_complete

Conversation

@wakonig
Copy link
Copy Markdown
Member

@wakonig wakonig commented May 10, 2026

closes #44

@github-actions
Copy link
Copy Markdown

Remaining TODOs in the docs:

docs/how-to/devices/add-an-epics-motor.md:<!-- TODO: Add video here -->
docs/getting-started/quick-start/04-run-your-first-scan.md:<!-- TODO: link to learn about signals -->
docs/getting-started/quick-start/01-open-bec.md:<!-- TODO: link to different application modes. -->
docs/getting-started/quick-start/01-open-bec.md:<!-- TODO: link to information about deployments. -->
docs/getting-started/next-steps/script-gui-interactions.md:TODO: Revisit as a dedicated, safety-reviewed scripting tutorial.

@wakonig wakonig requested review from a team and xiaoqiangwang May 10, 2026 14:28
@xiaoqiangwang
Copy link
Copy Markdown
Collaborator

Good digging. The description table of how put_complete affects set is accurate.

When comparing set and put, maybe make it clear that set calls put.

put is a direct wrapper of epics.PV.put. The only difference is that the use_complete defaults to put_complete if not specified.

@wakonig wakonig force-pushed the feature/put_complete branch from 55f1f44 to e45e9d8 Compare May 11, 2026 17:36
@wakonig wakonig marked this pull request as ready for review May 11, 2026 17:37
@xiaoqiangwang
Copy link
Copy Markdown
Collaborator

Another thought comes to my mind: the doc is about accessing the ophyd signals directly (RPC to device server or in the device server). When user is in BEC client, the proxy object takes over and has different signature.

@xiaoqiangwang
Copy link
Copy Markdown
Collaborator

xiaoqiangwang commented May 13, 2026

If you want to put an example how put_complete changes the wait behavior. The Acquire record in an areaDetector IOC (acquire signal in an areaDetector camera object, cam.acquire) calls back when acquisition finishes. e.g.

# without `put_complete=False` the status wait returns immediately
# because it checks the Acquire PV  value has changed to 1.
>> acquire = EpicsSignal('X04SA-ES3-EIGER:cam1:Acquire', name='acquire')
>> acquire.set(1).wait()

# with `put_complete=True` the status wait returns only when camera finishes acquisition.
>> acquire = EpicsSignal('X04SA-ES3-EIGER:cam1:Acquire', name='acquire', put_complete=True)
>> acquire.set(1).wait()

The same applies to the motor record .VAL field, .e.g. user_setpoint signal in EpicsMotor ophyd object.

Whether a potentially long process trigger record will callback depends on the underlying EPICS integration. The above example is an effective way to find out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Learn: set vs put or how-to choose between .set and .put

2 participants