Kasemir,
thank you for your answer. Let me tell our story:
We saw in CS-Studio a good opportunity to beamline's staff to build
their own screens because of the user friendly interface. The problem is
that beamline's staff are full of good idea and desires, but have poor
programming skills. So, we prepared a 2 days course as they could start
to use CS-Studio in a basic way. Even with few programming skills they
could build beautiful and useful screens to use the IOCs we developed
for them.
For complex tasks we created a python framework called py4syn that
they use in parallel with CS-Studio.
The problem is that some of them adventure themselves to develop
complex python scripts and embedded them in BOY widgets. The result is
that sometimes CS-Studio freezes because of script issues and the
biggest derived problem is that their wrong perception is that CS-Studio
is not a good tool. This way, two of our beamlines decided to migrate to
MEDM, even when we tried to show that the problem was not caused by the
tool.
For us in LNLS it is a good strategy to give some freedom to
beamline's staff to build some pieces of software in the EPICS client
layer, but due to lack of programming skills we don't think it's a good
idea to allow them to build their own IOCs.
I agree that the best way to work is not to put those scripts
inside BOY, but could I suggest to put some protection mechanisms that
allow CS-Studio to run smoothly even if an embedded script runs in an
accidental continuous loop?
Thank you again,
--
Márcio Paduan Donadio
Computer Engineer - Beamline Operation Software
Laboratório Nacional de Luz Síncrotron – (LNLS)
Centro Nacional de Pesquisa em Energia e Materiais (CNPEM)
+ 55 (19) 3512-3520 - [email protected]
www.lnls.cnpem.br
On 28-07-2015 12:53, Kasemir, Kay wrote:
>> On Jul 28, 2015, at 10:29 AM, Márcio Paduan Donadio <[email protected]> wrote:
>>
>>
>> Dear Folks,
>>
>> is there a way to run a python script in a BOY widget in a thread
>> separate from BOY? We are facing CS-Studio freezing by scripts that take
>> too much time to run.
> See BOY Examples/5_6_UseThreadInScript.opi
>
> The use of scripts, however, is discouraged in general.
> The script API is not guaranteed to stay as it is.
> In fact any attempt to improve the BOY performance (https://github.com/ControlSystemStudio/cs-studio/issues/1230) is almost guaranteed to break your scripts.
> Don’t implement any processing logic in a script which should really be on an IOC.
> If you have to ask how to do things in a script, you’re likely to cause more trouble than good.
>
> Thanks,
> Kay
- Replies:
- Re: Multi-threading in BOY Python scripts Pete Jemian
- Re: Multi-threading in BOY Python scripts Kasemir, Kay
- References:
- Multi-threading in BOY Python scripts Márcio Paduan Donadio
- Re: Multi-threading in BOY Python scripts Kasemir, Kay
- Navigate by Date:
- Prev:
Passing a raw byte value from st.cmd to a StreamDevice proto file Michael Ritzert
- Next:
Re: MVME-5500 Universe II Amit Chauhan
- 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: Multi-threading in BOY Python scripts Kasemir, Kay
- Next:
Re: Multi-threading in BOY Python scripts Pete Jemian
- 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
|