Hi Tim,
One problem that occurs with many EPICS devices that are on a fieldbus like Ethernet, USB, serial, etc. is how to handle the case when the device is power-cycled or otherwise
reset and one does not want to reboot the IOC. In many cases what the user wants is to be able to push the most recent settings down to the device so that it is “in-sync” with the EPICS output PVs. This has come up most often in the context of GigE cameras
that get power-cycled, but it is much more general.
It seems like this is something that we can use autosave to do, without needing to write any new code. I am trying to figure out if the best
way to implement this is to use configMenu
https://htmlpreview.github.io/?https://github.com/epics-modules/autosave/blob/master/documentation/autoSaveRestore.html#configMenu
or to add some code to the base class driver that calls:
int fdbrestoreX(char *filename, char *macrostring, callbackFunc callbackFunction, void *puser)
I would like to do the following for areaDetector IOCs.
-
Currently there is a single auto_settings.req file that generates auto_settings.save for all PVs in the IOC, i.e. those that are specific to the camera and all the rest
which are for the plugins, scan record, etc.
-
I would like to break this up into 2 monitor request files:
o
camera_settings.req The settings that are specific to the camera
o
auto_settings.req All of the other settings
-
I want to present the user with a PV that allows them to read camera_settings.sav and push those values to the camera, for example after it has been reset.
-
I don’t want the user to be required to manually save the save_set, I want it to happen automatically with a monitor set.
configMenu looks easier and more powerful, but I have never used it and I am not sure it can do what I want. First, as I understand it configMenu only supports manual
saving of configurations, not monitor sets? Second, it appears to only read .cfg files and not the .sav files written by monitor sets?
I guess I could do what I want with configMenu if the user first pressed Save, which will write the current values of the output PVs to the .cfg file. Then they can
press Load which will push them to the camera. The only problem is that if they forget to press Save first they will load a stale configuration, and then they are in trouble. But I could wrap the Save then Load in a sequence record to prevent that.
I’d appreciate your advice on this.
Thanks,
Mark