1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
---|
2 | "http://www.w3.org/TR/REC-html40/loose.dtd"> |
---|
3 | <html> |
---|
4 | <head> |
---|
5 | <title>Description of machine2sim</title> |
---|
6 | <meta name="keywords" content="machine2sim"> |
---|
7 | <meta name="description" content="MACHINE2SIM - loads online machine configuration to AT configuration"> |
---|
8 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
---|
9 | <meta name="generator" content="m2html © 2003 Guillaume Flandin"> |
---|
10 | <meta name="robots" content="index, follow"> |
---|
11 | <link type="text/css" rel="stylesheet" href="../m2html.css"> |
---|
12 | </head> |
---|
13 | <body> |
---|
14 | <a name="_top"></a> |
---|
15 | <div><a href="../index.html">Home</a> > <a href="index.html">mml</a> > machine2sim.m</div> |
---|
16 | |
---|
17 | <!--<table width="100%"><tr><td align="left"><a href="../index.html"><img alt="<" border="0" src="../left.png"> Master index</a></td> |
---|
18 | <td align="right"><a href="index.html">Index for mml <img alt=">" border="0" src="../right.png"></a></td></tr></table>--> |
---|
19 | |
---|
20 | <h1>machine2sim |
---|
21 | </h1> |
---|
22 | |
---|
23 | <h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2> |
---|
24 | <div class="box"><strong>MACHINE2SIM - loads online machine configuration to AT configuration</strong></div> |
---|
25 | |
---|
26 | <h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2> |
---|
27 | <div class="box"><strong>function machine2sim(ZeroCMFlag) </strong></div> |
---|
28 | |
---|
29 | <h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2> |
---|
30 | <div class="fragment"><pre class="comment">MACHINE2SIM - loads online machine configuration to AT configuration |
---|
31 | machine2sim(ZeroCMFlag) |
---|
32 | |
---|
33 | ZeroCMFlag = 0 set the machine corrector setting to the simulator |
---|
34 | 1 zero the correctors in the simulator {Default} |
---|
35 | |
---|
36 | NOTES |
---|
37 | 1. The RF frequency of the simulator is not changed |
---|
38 | 2. Use ZeroCMFlag = 1 when you think the corrector magnets on the |
---|
39 | online machine are restoring the orbit to the design orbit (or close) |
---|
40 | |
---|
41 | See also <a href="sim2machine.html" class="code" title="function sim2machine">sim2machine</a>, <a href="golden2sim.html" class="code" title="function golden2sim(ZeroCMFlag)">golden2sim</a> |
---|
42 | |
---|
43 | Written by Greg Portmann</pre></div> |
---|
44 | |
---|
45 | <!-- crossreference --> |
---|
46 | <h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2> |
---|
47 | This function calls: |
---|
48 | <ul style="list-style-image:url(../matlabicon.gif)"> |
---|
49 | <li><a href="getam.html" class="code" title="function [AM, tout, DataTime, ErrorFlag] = getam(varargin)">getam</a> GETAM - Gets monitor channels</li><li><a href="gethcmfamily.html" class="code" title="function Family = gethcmfamily">gethcmfamily</a> GETHCMFAMILY - Returns the default horizontal corrector family</li><li><a href="getmachineconfig.html" class="code" title="function [ConfigSetpoint, ConfigMonitor, FileName] = getmachineconfig(varargin)">getmachineconfig</a> GETMACHINECONFIG - Returns or saves to file the present storage ring setpoints and monitors</li><li><a href="getvcmfamily.html" class="code" title="function Family = getvcmfamily">getvcmfamily</a> GETVCMFAMILY - Returns the default vertical corrector family</li><li><a href="isfamily.html" class="code" title="function [FamilyFlag, AO] = isfamily(Family, Field)">isfamily</a> ISFAMILY - True for family names</li><li><a href="setmachineconfig.html" class="code" title="function [ConfigSetpoint, FileName] = setmachineconfig(varargin)">setmachineconfig</a> SETMACHINECONFIG - Sets the storage ring setpoints from a file or configuration data structure</li><li><a href="setsp.html" class="code" title="function ErrorFlag = setsp(Family, varargin)">setsp</a> SETSP - Makes an absolute setpoint change to the 'Setpoint' field</li></ul> |
---|
50 | This function is called by: |
---|
51 | <ul style="list-style-image:url(../matlabicon.gif)"> |
---|
52 | </ul> |
---|
53 | <!-- crossreference --> |
---|
54 | |
---|
55 | |
---|
56 | <h2><a name="_source"></a>SOURCE CODE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2> |
---|
57 | <div class="fragment"><pre>0001 <a name="_sub0" href="#_subfunctions" class="code">function machine2sim(ZeroCMFlag)</a> |
---|
58 | 0002 <span class="comment">%MACHINE2SIM - loads online machine configuration to AT configuration</span> |
---|
59 | 0003 <span class="comment">% machine2sim(ZeroCMFlag)</span> |
---|
60 | 0004 <span class="comment">%</span> |
---|
61 | 0005 <span class="comment">% ZeroCMFlag = 0 set the machine corrector setting to the simulator</span> |
---|
62 | 0006 <span class="comment">% 1 zero the correctors in the simulator {Default}</span> |
---|
63 | 0007 <span class="comment">%</span> |
---|
64 | 0008 <span class="comment">% NOTES</span> |
---|
65 | 0009 <span class="comment">% 1. The RF frequency of the simulator is not changed</span> |
---|
66 | 0010 <span class="comment">% 2. Use ZeroCMFlag = 1 when you think the corrector magnets on the</span> |
---|
67 | 0011 <span class="comment">% online machine are restoring the orbit to the design orbit (or close)</span> |
---|
68 | 0012 <span class="comment">%</span> |
---|
69 | 0013 <span class="comment">% See also sim2machine, golden2sim</span> |
---|
70 | 0014 <span class="comment">%</span> |
---|
71 | 0015 <span class="comment">% Written by Greg Portmann</span> |
---|
72 | 0016 |
---|
73 | 0017 |
---|
74 | 0018 <span class="keyword">if</span> nargin < 1 |
---|
75 | 0019 ZeroCMFlag = 1; |
---|
76 | 0020 <span class="keyword">end</span> |
---|
77 | 0021 |
---|
78 | 0022 |
---|
79 | 0023 <span class="comment">% Get from the online machine</span> |
---|
80 | 0024 ConfigSetpoint = <a href="getmachineconfig.html" class="code" title="function [ConfigSetpoint, ConfigMonitor, FileName] = getmachineconfig(varargin)">getmachineconfig</a>(<span class="string">'Online'</span>); |
---|
81 | 0025 |
---|
82 | 0026 |
---|
83 | 0027 <span class="comment">% Set to the simulator (don't change the simulator RF)</span> |
---|
84 | 0028 <span class="keyword">if</span> <a href="isfamily.html" class="code" title="function [FamilyFlag, AO] = isfamily(Family, Field)">isfamily</a>(<span class="string">'RF'</span>) |
---|
85 | 0029 RFsim = <a href="getam.html" class="code" title="function [AM, tout, DataTime, ErrorFlag] = getam(varargin)">getam</a>(<span class="string">'RF'</span>, <span class="string">'Simulator'</span>); |
---|
86 | 0030 <span class="keyword">end</span> |
---|
87 | 0031 <span class="keyword">if</span> <a href="isfamily.html" class="code" title="function [FamilyFlag, AO] = isfamily(Family, Field)">isfamily</a>(<span class="string">'RF'</span>) |
---|
88 | 0032 <a href="setmachineconfig.html" class="code" title="function [ConfigSetpoint, FileName] = setmachineconfig(varargin)">setmachineconfig</a>(ConfigSetpoint, <span class="string">'Simulator'</span>); |
---|
89 | 0033 <a href="setsp.html" class="code" title="function ErrorFlag = setsp(Family, varargin)">setsp</a>(<span class="string">'RF'</span>, RFsim, <span class="string">'Simulator'</span>); |
---|
90 | 0034 <span class="keyword">end</span> |
---|
91 | 0035 |
---|
92 | 0036 <span class="keyword">if</span> ZeroCMFlag |
---|
93 | 0037 <a href="setsp.html" class="code" title="function ErrorFlag = setsp(Family, varargin)">setsp</a>(<a href="gethcmfamily.html" class="code" title="function Family = gethcmfamily">gethcmfamily</a>, 0, <span class="string">'Simulator'</span>); |
---|
94 | 0038 <a href="setsp.html" class="code" title="function ErrorFlag = setsp(Family, varargin)">setsp</a>(<a href="getvcmfamily.html" class="code" title="function Family = getvcmfamily">getvcmfamily</a>, 0, <span class="string">'Simulator'</span>); |
---|
95 | 0039 <span class="keyword">end</span> |
---|
96 | 0040</pre></div> |
---|
97 | <hr><address>Generated on Mon 21-May-2007 15:29:18 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/">m2html</a></strong> © 2003</address> |
---|
98 | </body> |
---|
99 | </html> |
---|