source: epicsdf/doc/build/html/epics/index.html @ 1046

Last change on this file since 1046 was 1046, checked in by jemian, 10 years ago

refs #12, provides the publishing tool and changed the URL to point to the new location

  • Property svn:executable set to *
  • Property svn:mime-type set to text/html
File size: 14.3 KB
Line 
1
2
3<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
6
7<html xmlns="http://www.w3.org/1999/xhtml">
8  <head>
9    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
10   
11    <title>EPICS IOC support documentation &mdash; epicsdf 1.0 documentation</title>
12   
13    <link rel="stylesheet" href="../_static/sphinxdoc.css" type="text/css" />
14    <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
15   
16    <script type="text/javascript">
17      var DOCUMENTATION_OPTIONS = {
18        URL_ROOT:    '../',
19        VERSION:     '1.0',
20        COLLAPSE_INDEX: false,
21        FILE_SUFFIX: '.html',
22        HAS_SOURCE:  true
23      };
24    </script>
25    <script type="text/javascript" src="../_static/jquery.js"></script>
26    <script type="text/javascript" src="../_static/underscore.js"></script>
27    <script type="text/javascript" src="../_static/doctools.js"></script>
28    <link rel="top" title="epicsdf 1.0 documentation" href="../index.html" />
29    <link rel="up" title="Contents" href="../contents.html" />
30    <link rel="next" title="Host computer support documentation" href="../host/index.html" />
31    <link rel="prev" title="Installation Instructions for Pilatus Detectors" href="../installation.html" /> 
32  </head>
33  <body>
34    <div class="related">
35      <h3>Navigation</h3>
36      <ul>
37        <li class="right" style="margin-right: 10px">
38          <a href="../genindex.html" title="General Index"
39             accesskey="I">index</a></li>
40        <li class="right" >
41          <a href="../py-modindex.html" title="Python Module Index"
42             >modules</a> |</li>
43        <li class="right" >
44          <a href="../host/index.html" title="Host computer support documentation"
45             accesskey="N">next</a> |</li>
46        <li class="right" >
47          <a href="../installation.html" title="Installation Instructions for Pilatus Detectors"
48             accesskey="P">previous</a> |</li>
49        <li><a href="../index.html">epicsdf 1.0 documentation</a> &raquo;</li>
50          <li><a href="../contents.html" accesskey="U">Contents</a> &raquo;</li> 
51      </ul>
52    </div>
53      <div class="sphinxsidebar">
54        <div class="sphinxsidebarwrapper">
55  <h3><a href="../index.html">Table Of Contents</a></h3>
56  <ul>
57<li><a class="reference internal" href="#">EPICS IOC support documentation</a><ul>
58<li><a class="reference internal" href="#goals">goals</a></li>
59<li><a class="reference internal" href="#database">database</a><ul>
60<li><a class="reference internal" href="#macro-parameters">macro parameters</a></li>
61<li><a class="reference internal" href="#process-variables">process variables</a></li>
62</ul>
63</li>
64<li><a class="reference internal" href="#alarm-calculation">alarm calculation</a></li>
65<li><a class="reference internal" href="#medm-client">MEDM client</a><ul>
66<li><a class="reference internal" href="#id1">macro parameters</a></li>
67</ul>
68</li>
69</ul>
70</li>
71</ul>
72
73  <h4>Previous topic</h4>
74  <p class="topless"><a href="../installation.html"
75                        title="previous chapter">Installation Instructions for Pilatus Detectors</a></p>
76  <h4>Next topic</h4>
77  <p class="topless"><a href="../host/index.html"
78                        title="next chapter">Host computer support documentation</a></p>
79  <h3>This Page</h3>
80  <ul class="this-page-menu">
81    <li><a href="../_sources/epics/index.txt"
82           rel="nofollow">Show Source</a></li>
83  </ul>
84<div id="searchbox" style="display: none">
85  <h3>Quick search</h3>
86    <form class="search" action="../search.html" method="get">
87      <input type="text" name="q" />
88      <input type="submit" value="Go" />
89      <input type="hidden" name="check_keywords" value="yes" />
90      <input type="hidden" name="area" value="default" />
91    </form>
92    <p class="searchtip" style="font-size: 90%">
93    Enter search terms or a module, class or function name.
94    </p>
95</div>
96<script type="text/javascript">$('#searchbox').show(0);</script>
97        </div>
98      </div>
99
100    <div class="document">
101      <div class="documentwrapper">
102        <div class="bodywrapper">
103          <div class="body">
104           
105  <div class="section" id="epics-ioc-support-documentation">
106<h1>EPICS IOC support documentation<a class="headerlink" href="#epics-ioc-support-documentation" title="Permalink to this headline">¶</a></h1>
107<p>The EPICS IOC support package consists of an EPICS database,
108an autosave request file to support the database,
109an example EPICS softIOC to run the database,
110a MEDM screen, and some test code to demonstrate
111the routine operations.</p>
112<div class="section" id="goals">
113<h2>goals<a class="headerlink" href="#goals" title="Permalink to this headline">¶</a></h2>
114<ul class="simple">
115<li>uses EPICS alarms</li>
116<li>sends email whenever alarm PV changes</li>
117<li>alarm PV changes based on its calculation</li>
118<li>default calculation watches .SEVR of free and avail</li>
119<li>trip points set by user</li>
120<li>default trip points are 500 (minor) and 50 (major) MB remaining on either free or avail</li>
121<li>disk PV will be reset to previous value if new value is empty or path does not exist</li>
122<li>period PV will be reset if it is not a number or if it is below 1.0</li>
123<li>update is forced early when certain PVs change (successfully): disk and period</li>
124</ul>
125</div>
126<div class="section" id="database">
127<h2>database<a class="headerlink" href="#database" title="Permalink to this headline">¶</a></h2>
128<p>Supports client-side software that watches disk space
129on a single partition and generates alarms as the free
130space grows small.  EPICS Alarms are used to signal
131for attention.  Client-side software will be used to send
132email when $(P)$(D)df:alarm changes its value.
133Trip points for the alarms are in .HIGH and .HIHI fields
134of the &#8220;ao&#8221; records.</p>
135<div class="section" id="macro-parameters">
136<h3>macro parameters<a class="headerlink" href="#macro-parameters" title="Permalink to this headline">¶</a></h3>
137<blockquote>
138<div><table border="1" class="docutils">
139<colgroup>
140<col width="9%" />
141<col width="25%" />
142<col width="66%" />
143</colgroup>
144<thead valign="bottom">
145<tr class="row-odd"><th class="head">macro</th>
146<th class="head">typical value</th>
147<th class="head">meaning</th>
148</tr>
149</thead>
150<tbody valign="top">
151<tr class="row-even"><td>P</td>
152<td>prj:</td>
153<td>IOC prefix</td>
154</tr>
155<tr class="row-odd"><td>D</td>
156<td>p300:</td>
157<td>specific device supported</td>
158</tr>
159</tbody>
160</table>
161</div></blockquote>
162<dl class="docutils">
163<dt>This database can be run in an EPICS softIoc (usually for development).</dt>
164<dd><p class="first">See the source project for file <tt class="docutils literal"><span class="pre">epics/start_ioc.sh</span></tt>.:</p>
165<div class="last highlight-python"><pre>softIoc -m P=prj:,D=p300: -d epicsdf.db</pre>
166</div>
167</dd>
168</dl>
169<table class="docutils field-list" frame="void" rules="none">
170<col class="field-name" />
171<col class="field-body" />
172<tbody valign="top">
173<tr class="field-odd field"><th class="field-name">note:</th><td class="field-body">softIoc is one of the tools built in EPICS base and
174can be found on the path
175<tt class="docutils literal"><span class="pre">${EPICS_BASE}/bin/${EPICS_HOST_ARCH}/softIoc</span></tt></td>
176</tr>
177</tbody>
178</table>
179</div>
180<div class="section" id="process-variables">
181<h3>process variables<a class="headerlink" href="#process-variables" title="Permalink to this headline">¶</a></h3>
182<p>The support database creates process variables to hold various values.
183The waveform PVs hold string values up to 1024 characters in length.</p>
184<blockquote>
185<div><table border="1" class="docutils">
186<colgroup>
187<col width="31%" />
188<col width="19%" />
189<col width="50%" />
190</colgroup>
191<thead valign="bottom">
192<tr class="row-odd"><th class="head">name</th>
193<th class="head">type</th>
194<th class="head">meaning</th>
195</tr>
196</thead>
197<tbody valign="top">
198<tr class="row-even"><td>$(P)$(D)df:disk</td>
199<td>waveform</td>
200<td>disk partition being watched</td>
201</tr>
202<tr class="row-odd"><td>$(P)$(D)df:message</td>
203<td>waveform</td>
204<td>message to be sent by email</td>
205</tr>
206<tr class="row-even"><td>$(P)$(D)df:email_list</td>
207<td>waveform</td>
208<td>list of email addresses</td>
209</tr>
210<tr class="row-odd"><td>$(P)$(D)df:total</td>
211<td>ao</td>
212<td>total space on the partition (MB)</td>
213</tr>
214<tr class="row-even"><td>$(P)$(D)df:free</td>
215<td>ao</td>
216<td>free space (MB)</td>
217</tr>
218<tr class="row-odd"><td>$(P)$(D)df:avail</td>
219<td>ao</td>
220<td>available space</td>
221</tr>
222<tr class="row-even"><td>$(P)$(D)df:used</td>
223<td>ao</td>
224<td>disk space in use (computed)</td>
225</tr>
226<tr class="row-odd"><td>$(P)$(D)df:free:pct</td>
227<td>ao</td>
228<td>percentage free space</td>
229</tr>
230<tr class="row-even"><td>$(P)$(D)df:used:pct</td>
231<td>ao</td>
232<td>percentage used space</td>
233</tr>
234<tr class="row-odd"><td>$(P)$(D)df:avail:pct</td>
235<td>ao</td>
236<td>percentage available space</td>
237</tr>
238<tr class="row-even"><td>$(P)$(D)df:period</td>
239<td>ao</td>
240<td>time between updates (s)</td>
241</tr>
242<tr class="row-odd"><td>$(P)$(D)df:alarm</td>
243<td>calcout</td>
244<td>calculated alarm condition</td>
245</tr>
246</tbody>
247</table>
248</div></blockquote>
249<p><strong>Note:</strong> To use either command line <tt class="docutils literal"><span class="pre">caget</span></tt> or <tt class="docutils literal"><span class="pre">caput</span></tt> with the
250waveform strings, it is necessary to use the <tt class="docutils literal"><span class="pre">-S</span></tt> option to
251indicate the use of a waveform string.  Here are examples:</p>
252<div class="highlight-python"><pre>$ caget -S 15iddLAX:p100:df:disk
253/mnt/data
254$ caput -S 15iddLAX:p100:df:disk /
255Old : 15iddLAX:p100:df:disk          /mnt/data
256New : 15iddLAX:p100:df:disk          /</pre>
257</div>
258</div>
259</div>
260<div class="section" id="alarm-calculation">
261<h2>alarm calculation<a class="headerlink" href="#alarm-calculation" title="Permalink to this headline">¶</a></h2>
262<p>The alarm calculation uses a calcout record.
263The calcout records allows the user to reprogram the behavior as desired.
264In the default configuration,
265if the value of the $(P)$(D)df:alarm PV is non-zero, then
266disk space is running low.</p>
267<p>The alarm calculation watches
268the .SEVR field on the &#8220;free: and &#8220;avail&#8221; PVs.  These PVs have alarm
269trip points for .LOW (minor) and .LOLO (major) alarms.
270By default, the trip points are set at 500 MB (minor) and 50 MB (major)
271space remaining with a hysteresis (.HYST) field of 5 MB. All these fields
272can be changed by users at run-time.  Any change in either the
273&#8220;free: or &#8220;avail&#8221; PV will trigger a recalculation of the &#8220;alarm&#8221; PV
274through the forward link (.FLNK) fields of the &#8220;ao&#8221; record.</p>
275<table class="docutils field-list" frame="void" rules="none">
276<col class="field-name" />
277<col class="field-body" />
278<tbody valign="top">
279<tr class="field-odd field"><th class="field-name">note:</th><td class="field-body">The present MEDM interface does not have entry boxes for changing the
280trip points now, nor for editing the calcout record.  Changes to all these
281may be made from the command line through the caput command.</td>
282</tr>
283</tbody>
284</table>
285<p>database fragment:</p>
286<div class="highlight-python"><pre>record(ao, "$(P)$(D)df:free")
287{
288        field(DESC, "free space")
289        field(EGU,  "MB")
290        field(PREC, "3")
291        field(HYST, "5")
292        field(LOW,  "500")
293        field(LOLO, "50")
294        field(LSV,  "MINOR")
295        field(LLSV, "MAJOR")
296        field(FLNK, "$(P)$(D)df:alarm")
297}
298record(ao, "$(P)$(D)df:avail")
299{
300        field(DESC, "available space")
301        field(EGU,  "MB")
302        field(PREC, "3")
303        field(HYST, "5")
304        field(LOW,  "500")
305        field(LOLO, "50")
306        field(LSV,  "MINOR")
307        field(LLSV, "MAJOR")
308        field(FLNK, "$(P)$(D)df:alarm")
309}
310record(calcout, "$(P)$(D)df:alarm")
311{
312        field(DESC, "any alarms will trigger this")
313        field(CALC, "A&gt;B?A:B")
314        field(INPA, "$(P)$(D)df:free.SEVR  NPP NMS")
315        field(INPB, "$(P)$(D)df:avail.SEVR  NPP NMS")
316        field(EGU,  "boolean")
317        field(HOPR, "2")
318        field(HIHI, "2")
319        field(HIGH, "1")
320        field(HHSV, "MAJOR")
321        field(HSV,  "MINOR")
322}</pre>
323</div>
324</div>
325<div class="section" id="medm-client">
326<h2>MEDM client<a class="headerlink" href="#medm-client" title="Permalink to this headline">¶</a></h2>
327<p>The MEDM screen has been created to support the users and the code developer.
328It could be improved with user feedback.</p>
329<p>The macro parameters are defined the same as for the database.
330The support screen is typically started with a command such as:</p>
331<div class="highlight-python"><pre>medm -x -macro P=15iddLAX:,D=p100: epicsdf.adl &amp;</pre>
332</div>
333<div class="section" id="id1">
334<h3>macro parameters<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h3>
335<blockquote>
336<div><table border="1" class="docutils">
337<colgroup>
338<col width="9%" />
339<col width="25%" />
340<col width="66%" />
341</colgroup>
342<thead valign="bottom">
343<tr class="row-odd"><th class="head">macro</th>
344<th class="head">example value</th>
345<th class="head">meaning</th>
346</tr>
347</thead>
348<tbody valign="top">
349<tr class="row-even"><td>P</td>
350<td>15iddLAX:</td>
351<td>IOC prefix</td>
352</tr>
353<tr class="row-odd"><td>D</td>
354<td>p100:</td>
355<td>specific device supported</td>
356</tr>
357</tbody>
358</table>
359</div></blockquote>
360<img alt="example MEDM screen for &lt;tt&gt;epicsdf&lt;/tt&gt;" src="../_images/epicsdf_medm.jpg" />
361</div>
362</div>
363</div>
364
365
366          </div>
367        </div>
368      </div>
369      <div class="clearer"></div>
370    </div>
371    <div class="related">
372      <h3>Navigation</h3>
373      <ul>
374        <li class="right" style="margin-right: 10px">
375          <a href="../genindex.html" title="General Index"
376             >index</a></li>
377        <li class="right" >
378          <a href="../py-modindex.html" title="Python Module Index"
379             >modules</a> |</li>
380        <li class="right" >
381          <a href="../host/index.html" title="Host computer support documentation"
382             >next</a> |</li>
383        <li class="right" >
384          <a href="../installation.html" title="Installation Instructions for Pilatus Detectors"
385             >previous</a> |</li>
386        <li><a href="../index.html">epicsdf 1.0 documentation</a> &raquo;</li>
387          <li><a href="../contents.html" >Contents</a> &raquo;</li> 
388      </ul>
389    </div>
390    <div class="footer">
391        &copy; Copyright 2011, Pete Jemian.
392      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
393    </div>
394  </body>
395</html>
Note: See TracBrowser for help on using the repository browser.