1<html xml:lang="en-US" lang="en-US" xmlns="http://www.w3.org/1999/xhtml">
2<head>
3<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4<meta http-equiv="Content-Style-Type" content="text/css" />
5<title>ctr_loadrun</title>
6<style type="text/css">
7<!--
8body {
9/*
10    font-size       : 10pt;
11*/
12    font-weight     : normal;
13    color           : #000000;
14    margin          : 8px;
15}
16
17div {
18    width           : 98%;
19    white-space     : nowrap;
20}
21
22div.title {
23    text-align      : left;
24    font-weight     : bold;
25/*
26    font-size       : 16pt;
27*/
28    font-size       : 150%;
29    color           : #202020;
30    border-style    : double;
31    border-width    : 8px;
32    /* タイトルを囲む枠線の色を指定 */
33    border-color    : #CD202C;
34
35    /* RVLプラットフォーム系列 */
36/*
37    border-color    : #34beed;
38*/
39
40    /* TWLプラットフォーム系列 */
41/*
42    border-color    : #ff458f;
43*/
44
45    margin          : 4px;
46    padding         : 4px;
47}
48H1 {
49  font-size		: 150%;
50  font-family		: Arial;
51  border-bottom-width	: 5px;
52  border-bottom-style	: solid;
53  border-bottom-color	: #CD202C;
54  padding-bottom		: 1px;
55  margin-bottom		: 20px;
56  letter-spacing		: normal;
57  font-weight		: bold;
58}
59
60h2 {
61    font-weight     : bold;
62/*
63    font-size       : 16pt;
64*/
65    font-size       : 150%;
66    border-style    : none none solid double;
67    border-width    : 0px 0px 2px 8px;
68    /* 見出しの線の色を指定 */
69    border-color    : #CD202C;
70
71    /* RVLプラットフォーム系列 */
72/*
73    border-color    : #34beed;
74*/
75
76    /* TWLプラットフォーム系列 */
77/*
78    border-color    : #ff458f;
79*/
80
81    margin-left     : 2px;
82    padding-left    : 4px;
83}
84CODE {
85  font-family		: "Courier New", monospace;
86  position		: normal;
87  left			: 12px;
88  font-size		: 10pt;
89}
90table {
91  margin-top        : 2pt;
92  margin-bottom     : 2pt;
93  margin-left       : 0pt;
94  margin-right      : 0pt;
95  padding-left      : 0pt;
96  padding-right     : 0pt;
97  position          : relative;
98  left              : 12px;
99  font-family       : Arial;
100  font-size         : 10pt;
101  border-style      : none none none none;
102}
103td,th {
104  padding           : 2pt;
105  border-width      : 2pt;
106  border-style      : none none none none;
107  font-style        : normal;
108  text-align        : left;
109}
110td {
111  background        : #e8f4f4;
112  font-weight       : normal;
113}
114th {
115  background        : #c0d8d8;
116  font-weight       : bold;
117}
118
119p {
120    margin-left     : 4px;
121}
122p.code {
123  font-family		: "Courier New", monospace;
124  position		: normal;
125  left			: 12px;
126  font-size		: 10pt;
127  background            : #e8f4f4;
128}
129
130-->
131</style>
132</head>
133  <body>
134<h1>ctr_loadrun</h1>
135<h2>Description</h2>
136      <p>
137The <CODE>ctr_loadrun</CODE> tool is used to run specified programs in a debugger (such as PARTNER-CTR). It can be used to run programs from the command line without requiring any debugger operations.
138
139      </p>
140<h3>Limitations</h3>
141The following limitations apply when using <CODE>ctr_loadrun</CODE>.
142        <ul>
143<li> If multiple instances of <CODE>ctr_loadrun</CODE> are started for a single debugger, they cannot be used at the same time.</li>
144<li> <CODE>ctr_loadrun</CODE> cannot be used at the same time as Visual Studio Integration for CTR (VSI-CTR) for a single debugger.</li>
145        </ul>
146<h3>Program Arguments Passed to CTR Applications</h3>
147    <p>
148<CODE>ctr_loadrun</CODE> can pass program arguments to CTR applications. This provides a way of changing how the CTR application acts, without adding any changes to the application.
149    </p>
150    <p>
151The arguments that can be passed using the <CODE>-a</CODE> and <CODE>-args</CODE> options can be obtained from interfaces such as <CODE>nn::dbg::CTR::GetArgc</CODE> and <CODE>nn::dbg::CTR::GetArgv</CODE>. File data to be passed with the <CODE>-ba</CODE> option can be obtained from <CODE>nn::dbg::CTR::GetArgBinary</CODE>.
152    </p>
153    <p>
154The buffer for passing program parameters to CTR applications is limited. Internally, it is limited to 4 KB, so the data that can be passed from <CODE>ctr_loadrun</CODE> must be smaller than that.
155    </p>
156
157<h2>How to Use</h2>
158<h3>Format</h3>
159    <pre> $ ctr_loadrun32.exe [CciFile] [options...] </pre>
160<h3>Options</h3>
161    <div class="section">
162      <p>
163        <table class="table"><tbody>
164<tr><th>Options</th> <th>Arguments</th><th>Description</th></tr>
165          <tr>
166<td><CODE>-h (--help)</CODE></td>
167             <td></td>
168<td>Displays help.</td>
169          </tr>
170          <tr>
171<td><CODE>-l (--devicelist)</CODE></td>
172            <td></td>
173<td>Displays the connected devices.</td>
174          </tr>
175          <tr>
176<td><CODE>-t (--timeout)</CODE></td>
177<td><CODE>TIMEOUT-SECONDS</CODE></td>
178<td>Sets the timeout from startup to exit.</td>
179          </tr>
180          <tr>
181<td><CODE>-e (--exit-pattern)</CODE></td>
182<td><CODE>EXIT-PATTERN</CODE></td>
183<td>Exits upon output of a string that matches the regular expression specified by <CODE>EXIT-PATTERN</CODE>.<br />The regular expression syntax conforms with the .NET Framework's <CODE>System.Text.RegularExpressions</CODE> namespace.
184            </td>
185          </tr>
186          <tr>
187<td><CODE>-c (--command)</CODE></td>
188<td><CODE>COMMAND</CODE></td>
189<td>Specifies the command to run before loading the image file.</td>
190          </tr>
191          <tr>
192<td><CODE>-m (--macro)</CODE></td>
193<td><CODE>MACROFILE</CODE></td>
194<td>Specifies the macro file to run before loading the image file.</td>
195          </tr>
196          <tr>
197<td><CODE>-d (--device)</CODE></td>
198<td><CODE>SERIALNUMBER</CODE></td>
199<td>Specifies which device to use by its serial number.</td>
200          </tr>
201          <tr>
202<td><CODE>-nw (--no-wait)</CODE></td>
203            <td></td>
204<td>Exits <CODE>loadrun</CODE> when it is confirmed that all commands have been sent.</td>
205          </tr>
206          <tr>
207<td><CODE>-ns (--no-start)</CODE></td>
208            <td></td>
209<td>Normally the <CODE>G</CODE> command, which runs the program, is sent after the program has been loaded.<br />With this option, the <CODE>G</CODE> command is not sent.</td>
210          </tr>
211          <tr>
212<td><CODE>-a (--argument)</CODE></td>
213<td>ARGUMENT-STRING</td>
214<td>Sets one argument to be passed to the CTR application. Can be specified multiple times.</td>
215          </tr>
216          <tr>
217<td><CODE>-ba (--binary-argument)</CODE></td>
218<td>ARGUMENT-FILE</td>
219<td>Sets a file to be passed as data to the CTR application.</td>
220          </tr>
221          <tr>
222<td><CODE>-args (--arguments)</CODE></td>
223<td>ARGUMENTS ...</td>
224<td>Of the program arguments passed to <CODE>loadrum</CODE>, this option sets all subsequent parameters as those to be passed to the CTR application.</td>
225          </tr>
226          <tr>
227<td><CODE>--systray</CODE></td>
228            <td></td>
229<td>Hides the debugger in the system tray when the debugger launches.</td>
230          </tr>
231          <tr>
232<td><CODE>--exit-debugger</CODE></td>
233            <td></td>
234<td>Exits the debugger when <CODE>ctr_loadrun</CODE> terminates, for example when the termination string pattern appears or when there is a timeout.</td>
235          </tr>
236        </tbody></table>
237      </p>
238    </div>
239<h2>Location</h2>
240    <pre> $CTRSDK_ROOT/tools/ComandlineTools/ctr_loadrun32.exe </pre>
241<h2>Revision History</h2>
242    <div class="section">
243      <dl class="history">
244        <dt>2011/12/29</dt>
245<dd> The feature for hiding the debugger in the system tray when it launches has been changed to the <CODE>--systray</CODE> option, and the normal behavior has been changed for the debugger to launch in a displayed window.<br />The feature for exiting the debugger when <CODE>ctr_loadrun32</CODE> terminates has been changed to the <CODE>--exit-debugger</CODE> option, and the normal behavior has been changed for the debugger to not recover.<br />
246        </dd>
247        <dt>2011/12/19</dt>
248<dd> Added functionality to pass program arguments to CTR applications.<br />
249        </dd>
250        <dt>2011/01/28</dt>
251<dd> Added that multiple executables cannot be used with a single debugger. <br />
252        </dd>
253        <dt>2010/11/23</dt>
254<dd>Changed the location of the document.<br />
255        </dd>
256        <dt>2010/10/25</dt>
257<dd>Initial version.<br />
258        </dd>
259      </dl>
260    </div>
261  <hr><p>CONFIDENTIAL</p></body>
262</html>