Hi Ben,
> ----- On 30 Nov, 2016, at 19:40, Benjamin Franksen [email protected] wrote:
>
> Hi Kevin
>
>>> I assume that all the SNL code is executed within some 'main' thread of the
>>> sequencer.
>>> Maybe the call out to python hangs, so the core SNL thread is stuck and no
>>> longer updating anything.
>
> No this is not the case as you found out. A separate thread is spawned
> for each state set.
>
> Does you Python program use CA? If yes, then I have a theory: the
> problem comes from the Python program trying to create a CA client
> context, but ending up re-using the one from the state thread. And when
> the Python ends, the context is destroyed, effectively disabling the
> state thread's CA capability.
Yes, the Python program uses pyEpics's epics.caget, but there are some complications here:
1. The Python context is created in the sequencer's global entry block and shut down in the global exit block (the PyObject's are initialised there and re-used in subsequent State entry calls).
2. How would the Python process EPICS get ahold of the calling-sequencer's C EPICS context?
3. The susceptible sequencer still works fine if I stop one of the *other* sequencers (that updates two of the PVs) used, above.
> To test this, replace the Python program with a very simple program that
> does not import any CA stuff. If the problem persists this means my
> guess was wrong.
When testing I could get the sequencer to work by commenting out only *some* (and leaving in others) of the epics.caget(xxx) calls.
Regards,
Kevin
--
Kevin Meyer
Cosylab, Ljubljana, Slovenia
Telephone: +386-(0)1-320-47-82 Mobile: +386-(0)70-260-321
- Replies:
- Re: SNL sequencer apparently losing connection to underlying network Benjamin Franksen
- References:
- Re: SNL sequencer apparently losing connection to underlying network Kevin Meyer
- Re: SNL sequencer apparently losing connection to underlying network Benjamin Franksen
- Navigate by Date:
- Prev:
RE: sscan module difficulties with EPICS 3.15 base Mark Rivers
- Next:
Automatic flat db generation Luca Cavalli
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
<2016>
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Re: SNL sequencer apparently losing connection to underlying network Benjamin Franksen
- Next:
Re: SNL sequencer apparently losing connection to underlying network Benjamin Franksen
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
<2016>
2017
2018
2019
2020
2021
2022
2023
2024
|