###########################################################################
# Start IOC
cd "$(TOP)/iocBoot/$(IOC)"
iocInit
###############################################################################
# Standard post-startup commands
dbl >"$(IOC_INFO)/pvdata/$(IOC)"
###############################################################################
Then clients and other tools like IRMIS can get the list of names from that file.
Or, if you just want a record that contains the magnet number, you could have something like this in your startup script:
epicsEnvSet(MAG, "1")
.
.
.
.
dbLoadRecords("db/xxxxxx.db, "MAG=$(MAG)")
.
.
.
seq &sncExample, "mag=$(MAG)"
where the xxxxxx.db database file contains, say, a longin record with
field(VAL, "$(MAG)")
If you change the epicsEnvSet command to something like:
epicsEnvSet(MAG, "$(MAG=1")
you can even provide the MAG value from a shell environment variable at startup.
Hi everybody,
Thank you so much for all of your help. I cannot possibly explain how grateful I am. I now can successfully use one state set to operate on many different PVs, but I do have one more question. From outside the ioc, is there any way to determine what the value of mag is? In other words, is there some linux shell command that is equivalent to typing "seq sncExample, "mag=1"" in the epics shell? My first thought is to have mag=1 when some PV (perhaps one called magSelect) is equal to 1, but I am having trouble doing this.