On Apr 4, 2012, at 9:42 AM, Pavel Masloff wrote:
> I would like to implement a simple command record, the idea of which is to switch its VAL to 1 and then back to 0. Let's assume we have got the following record:
>
> record (bo,"cmd:valve_trigger")
> {
> field(PINI, "YES")
> field(DTYP, "S7plc")
> field(OUT, "@plc/0 T=UINT8 B=0")
> field(SCAN, "I/O Intr")
> field(ONAM, "ONE")
> field(ZNAM, "ZERO")
> }
>
> Is there any straightforward solution?
Yes . . .
field(HIGH,"0.5")
where "0.5" is a floating point value representing the number of seconds to hold the VAL to 1 before resetting it back to 0.
(And you probably don't want the bo record to scan on I/O interrupt. More typically, output records are Passive.)
--
Steven Hartman
[email protected]
- References:
- [db] simple command ? Pavel Masloff
- Navigate by Date:
- Prev:
Re: Inspect Samples of CSS shows inconsistent SEVR Burkhard Kolb
- Next:
Re: [db] simple command ? Tim Mooney
- 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:
[db] simple command ? Pavel Masloff
- Next:
Re: [db] simple command ? Tim Mooney
- 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
|