Am Fri, 3 Nov 2023 17:05:38 +0100
schrieb Gerrit Kühn via Tech-talk <tech-talk at aps.anl.gov>:
> > > Another issue I have been running into with this is the order of
> > > record initialisation.
> > For this (within one IOC) you can use the PHAS field of a record.
> > Records with smaller PHAS values are processed before records with
> > higher values.
> Great, thanks for the pointer. I hadn't seen that one before.
Unfortunately, setting PHAS did not help with the issue I am trying to
resolve. Probably I did not describe the situation with enough details:
I have a mbbo record that is using streamdevice. The protocol doing the
setting part has an @init handler that should use input from a different
channel via redirection. This channel is not initialised at that point
(empty).
It looks like @init is happening too early. Even setting the redirected
record to PHAS=0 and the initialising one to PHAS=10 does not change this.
Loading the needed records with a separate dbLoadRecords statement in
st.cmd does not help, either.
PHAS is honored by the mechanisms in Base, mainly PINI processing and periodic scan threads. What device support modules do is not in the scope of Base, making
Is there a way to have selected records initialised before @init is being
run?
a tricky question, possibly StreamDevice related, at least partially.
Is the referenced record also linked to StreamDevice - that would make it a Stream-internal issue - or is that a race between record initialization by Base (PINI/PHAS) and StreamDevice (@init)?
Cheers,
~Ralph