Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic PV creation #87

Open
zkuplj opened this issue Nov 24, 2022 · 3 comments
Open

Dynamic PV creation #87

zkuplj opened this issue Nov 24, 2022 · 3 comments

Comments

@zkuplj
Copy link

zkuplj commented Nov 24, 2022

Hi all,

I am working on an application, where I would need to create a PV dynamically inside the server (by itself or triggered from the outside).

I am aware of the dynamic_pv.py example which creates a new PV at "$ caget" command, but I would like to know if there is a function or an example that allows me to dynamically create a PV on the server? That is, after the server is started, I would like to create additional PVs when desired.
The PV would ideally be of a similar structure as if the function SimpleServer.createPV() created it. I would then use "caget" and "caput" to modify its value from outside or I would modify the PV value from inside the server.

@mennodoor
Copy link

Hi zkuplj,

it may not be exactly what you are looking for, but a little more than the dynamic PV example:

https://github.com/mennodoor/epics-relay

Cheers
menno

@xiaoqiangwang
Copy link
Collaborator

The connection between SimpleServer.createPV created PVs and Driver class is only established once when in Driver.init. This limited can be overcome.

But it still would not be as dynamic as @mennodoor's implementation does. There the PVs are created on demand, not proactively by the server.

@zkuplj
Copy link
Author

zkuplj commented Nov 29, 2022

Thank you, this is really helpful!
I think with a bit of modification, @mennodoor's implementation can do approximately what I need.

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

No branches or pull requests

3 participants