Experimental Physics and Industrial Control System
If you want to create a state set as Tim Mooney suggested (I would
prefer this solution) May be this script for a automatic snl-file
generation could be helpful. You can run it to understand what happens,
but it has to be adapted to your requirements.
regards
Bernhard Kuner
--
---------------------------------------------------------------
-- [email protected] ------- Bessy Gmbh -----------------
-- +49 30 6392 4981 -------------- Albert Einstein Strasse 15 -
---------------------------------- 12489 Berlin ---------------
program PPTMOD
int stt[14];
int miscOn;
int coolingOn;
assign miscOn to "PPTMOD:miscOn";
assign coolingOn to "PPTMOD:coolingOn";
/*sorted in alphabetical order of signals*/
assign stt[5] to "PPTMOD:BodyWaFlSw";
assign stt[0] to "PPTMOD:CabDoorSw";
assign stt[6] to "PPTMOD:CavyWaFlSw";
assign stt[7] to "PPTMOD:CircWaFlSw";
assign stt[8] to "PPTMOD:CollWaFlSw";
assign stt[1] to "PPTMOD:EarthSw";
assign stt[2] to "PPTMOD:EmergSw";
assign stt[4] to "PPTMOD:GndRod";
assign stt[9] to "PPTMOD:LoadWaFlSw";
assign stt[11] to "PPTMOD:MagnWaFlSw";
assign stt[10] to "PPTMOD:MagnetTempSw";
assign stt[12] to "PPTMOD:TankTempSw";
assign stt[13] to "PPTMOD:TankWaFlSw";
assign stt[3] to "PPTMOD:eoLineMax";
monitor stt;
ss miscStates
{
state st_miscInit
{ when()
{ miscOn=1;
pvPut(miscOn);
} state st_miscOn
}
state st_miscOff
{ when(stt[0]||stt[1]||stt[2]||stt[3]||stt[4])
{ miscOn = TRUE;
pvPut(miscOn);
} state st_miscOn
}
state st_miscOn
{ when(!stt[0]&&!stt[1]&&!stt[2]&&!stt[3]&&!stt[4])
{ miscOn = FALSE;
pvPut(miscOn);
} state st_miscOff
}
}
ss coolingStates
{
state st_coolingInit
{ when()
{ coolingOn=1;
pvPut(coolingOn);
} state st_coolingOn
}
state st_coolingOff
{ when(stt[5]||stt[6]||stt[7]||stt[8]||stt[9]||stt[10]||stt[11]||stt[12]||stt[13])
{ coolingOn = TRUE;
pvPut(coolingOn);
} state st_coolingOn
}
state st_coolingOn
{ when(!stt[5]&&!stt[6]&&!stt[7]&&!stt[8]&&!stt[9]&&!stt[10]&&!stt[11]&&!stt[12]&&!stt[13])
{ coolingOn = FALSE;
pvPut(coolingOn);
} state st_coolingOff
}
}
- Navigate by Date:
- Prev:
Re: Maximum (Minimum) Value of a Set of Readback PVs kuner
- Next:
Setting TZ for RTEMS so that local time is correct Allison, Stephanie
- 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: Waveform calaulation for each element Singleton, SJ (Steve)
- Next:
Re: Maximum (Minimum) Vaue of a Set of Readback PVs kuner
- 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