Add EfikaMX smarttop board support
[openocd/cortex.git] / src / server / httpd / terminal.tcl
blobc6cc05f62ae9d041dde2dd6fa4afed8090876102
1 # converted to .tcl by html2tcl.tcl
2 set buffer ""
3 append buffer {
57 <html xmlns="http://www.w3.org/TR/REC-html40">
58 <head>
59 <title>OpenOCD debugger</title>
60 <meta charset="utf-8" content="text/html" http-equiv="Content-Type"/>
61 <link type="text/css" rel="stylesheet" href="menuweb.css"/>
62 </head>
65 set console ""
66 set upload_filename /ram/upload
68 append buffer {
69 <body style="margin:0px;">
70 <div style="width:974px;height:85px;">
71 <div style="float:left;position:relative;left:32px;width:478px;">
72 <a href="/">
73 OpenOCD
74 </a>
75 </div>
76 <div style="float:left;position:relative;height:26px; width:278px;left:122px;background-image:url('menu_cuts/top_right.png');">
77 <div style="position:relative;left:15px;top:4px;" class="textlight">
79 append buffer [capture version]
80 append buffer {
81 </div>
82 </div>
83 </div>
84 <table style="padding:0px;border-collapse:collapse;">
85 <tr>
86 <td style="width:33px;">
87 <div style="width:20px;height:510px;">
88 &nbsp;
89 </div>
90 </td>
91 <td style="vertical-align:top;height:100%;width:140px;padding:0px;">
92 <table style="padding:0px;border-collapse:collapse;height:100%;width:140px;">
93 <tr style="height:59px;">
94 <td/>
95 </tr>
96 <tr>
97 <td style="width:140px;height:38px;background-image:url('menu_cuts/v_tab.png');background-repeat: no-repeat;">
98 <div style="position:relative;left:10px;top:10px;font-weight:bold;">
99 <a href="index.tcl" style="">Target Status</a>
100 </div>
101 </td>
102 </tr>
103 <tr>
104 <td style="width:140px;height:35px;background-image:url('menu_cuts/v_1.png')"/>
105 </tr>
106 <tr>
107 <td style="width:140px;background-image:url('menu_cuts/v_2_tile.png')"/>
108 </tr>
109 <tr>
110 <td style="width:140px;height:140px;background-image:url('menu_cuts/v_3.png')"/>
111 </tr>
112 </table>
113 </td>
114 <td style="vertical-align:top;padding:0px;height:100%">
115 <table style="padding:0px;border-collapse:collapse;height:100%;">
116 <tr>
117 <td>
118 <table style="padding:0px;border-collapse:collapse;">
119 <tr>
120 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab1_selected.png');background-repeat: no-repeat;">
121 <div style="position:relative;top:7px;font-weight:bold;text-align:center;width:100px;">
122 <a href="index.tcl" style="font-weight: bold;">Config Target</a>
123 </div>
124 </td>
125 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab1.png');background-repeat: no-repeat;">
126 <div style="position:relative;top:7px;font-weight:bold;text-align:center;width:100px;">
127 <a href="flashinfo.tcl">Flash</a>
128 </div>
129 </td>
130 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab1.png');background-repeat: no-repeat;">
131 <div style="position:relative;top:7px;font-weight:bold;text-align:center;width:100px;">
132 <a href="browsemem.tcl">Memory</a>
133 </div>
134 </td>
135 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab1.png');background-repeat: no-repeat;">
136 <div style="position:relative;top:7px;font-weight:bold;text-align:center;width:100px;">
137 <a href="openocd.tcl">OpenOCD</a>
138 </div>
139 </td>
140 </tr>
141 </table>
142 </td>
143 </tr>
144 <tr>
145 <td style="height:30px;width:535px;background-image:url('menu_cuts/center_top.png');background-repeat: no-repeat;background-position:top right;" colspan="6">
146 <div style="width:500px;background-color:#ffffff;height:100%;">
147 &nbsp;
148 </div>
149 </td>
150 </tr>
151 <tr>
152 <td style="background-color:#ffffff;text-indent:30px;height:40px;" colspan="6">
153 <H1>UART forwarding</H1>
154 </td>
155 </tr>
156 <tr style="height:100%;">
157 <td style="background-color:#ffffff;padding-left:30px;padding-right:30px;width=535px;height:100%;" colspan="6">
160 set form_baudrate [formfetch form_baudrate]
161 if {[string length $form_baudrate]==0} {
162 set form_baudrate [ocd_uart]
163 set form_baudrate [string range $form_baudrate 0 [expr [string length $form_baudrate]-2]]
165 set form_action [formfetch form_action]
167 append buffer {
168 <form action="terminal.tcl" method="post">
169 Target baudrate:
170 <select name="form_baudrate">
173 foreach i {9600 19200 38400 57600 115200} {
175 append buffer {
176 <option }
177 if {[string compare $form_baudrate $i]==0} { append buffer {selected="selected"} }
178 append buffer {
179 value ="}
180 append buffer $i
181 append buffer {">}
182 append buffer $i
183 append buffer {</option>
188 append buffer {
189 </select>
191 <p>
192 <input type="submit" name="form_action" value="Set baudrate" >
193 </form>
196 if {[string compare $form_action "Set baudrate"]==0} {
197 append console [encode [ocd_uart $form_baudrate]]
200 append buffer {
202 <h2>Simple UART</h2>
203 This terminal window is purely for illustrative purposes. Use telnet or a terminal program
204 to talk to the target over TCP/IP for anything but trivial case of reading/writing a few
205 lines of texts in simple tests.
207 </td>
208 </tr>
212 set toggle_details [formfetch toggle_details]
213 if {[string length $toggle_details]==0} {
214 set toggle_details 0
216 set show_details [load_var show_details]
217 if {[string length $show_details]==0} {
218 set show_details 0
220 if {$toggle_details==1} {
221 set show_details [expr 1-$show_details]
222 save_var show_details $show_details
225 if {[string length $console]!=0} {
227 append buffer {
228 <tr style="height:100%;">
229 <td style="height:100%;background-color:red;" colspan="6">
230 <table style="padding:0px;border-collapse:collapse;background-color:#ffffff;width:100%" class="textgray">
231 <td style="width:25px;">&nbsp;</td>
234 if {$show_details==1} {
235 append buffer <
236 append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"}
237 append buffer >
238 } else {
239 append buffer <
240 append buffer {td style="background-image:url('menu_cuts/h_tab_free.png');width:110px;height:29px;background-repeat: no-repeat;background-position:top left;"}
241 append buffer >
244 append buffer {
245 <a class="openocd" href="terminal.tcl?toggle_details=1">
248 if {$show_details==1} {
249 append buffer "Hide details"
250 append buffer <br/>
251 } else {
252 append buffer {<div style="position:relative;top:7px;text-align:center;">}
253 append buffer "Show details"
254 append buffer {</div>}
257 append buffer {
258 </a>
261 if {$show_details==1} {
262 append buffer $console
265 append buffer {</td>}
267 if {$show_details!=1} {
268 append buffer {<td>&nbsp;</td>}
271 append buffer {
272 <td style="width:25px;">&nbsp;</td>
273 </table>
274 </td>
275 </tr>
280 append buffer {
281 <tr>
282 <td style="height:30px;background-image:url('menu_cuts/center_bottom.png');background-repeat: no-repeat;background-position:top right;" colspan="6">
283 <div style="width:500px;background-color:#ffffff;height:100%;">
284 &nbsp;
285 </div>
286 </td>
287 </tr>
288 </table>
289 </td>
290 <td style="width:6px;"/>
291 <td style="width:245px;height:100%">
292 <table style="padding:0px;border-collapse:collapse;height:100%;">
293 <tr>
294 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab2_selected.png');background-repeat: no-repeat;">
295 <div style="position:relative;top:7px;;font-weight:bold;text-align:center;width:100px;" class="textgray">
296 Documentation
297 </div>
298 </td>
299 <td width="40px">
300 &nbsp;
301 </td>
302 <td/>
303 </tr>
304 <tr>
305 <td style="height:10px;width:245px;background-image:url('menu_cuts/right_top_small.png');" colspan="3"/>
306 </tr>
307 <tr>
308 <td style="background-color:#d8d7d7;width:245px;padding-left:10px;padding-buttom:10px;line-height:17px;" colspan="3">
309 <a target="_blank" href="http://openocd.berlios.de/doc/openocd.pdf">OpenOCD Manual</a>
310 <br/>
311 </td>
312 </tr>
313 <tr>
314 <td style="background-color:#d8d7d7;height:15px;" colspan="3"/>
315 </tr>
316 <tr>
317 <td colspan="3">
318 <table style="padding:0px;border-collapse:collapse;">
319 <td style="background-color:#d8d7d7;width:10px;height:1px"/>
320 <td style="background-color:#999999;width:225px; height:1px;"/>
321 <td style="background-color:#d8d7d7;width:10px;height:1px"/>
322 </table>
323 </td>
324 </tr>
325 <tr>
326 <td style="background-color:#d8d7d7;height:15px;" colspan="3"/>
327 </tr>
328 <tr style="height:100%;">
329 <td style="height:100%;background-color:#d8d7d7;padding-left:10px;padding-right:10px;" colspan="3" class="textgray">
331 Serial port data to target is forwarded(both directions) in the simple terminal window
332 to the left. Alternatively you can <b>telnet }
333 append buffer [ip]
334 append buffer { 5555</b>
335 or connect via TCP/IP from e.g. HyperTerminal.
337 Type "help uart" in telnet for information on how to set uart speed for target. Normally
338 the uart speed is set from the target configuration script by adding an "uart N", where
339 N is the baudrate.
341 </td>
342 </tr>
343 <tr>
344 <td style="height:30px;background-image:url('menu_cuts/right_bottom.png');" colspan="3">
345 &nbsp;
346 </td>
347 </tr>
348 </table>
349 </td>
350 </tr>
351 </table>
352 </body>
353 </html>
361 start_chunked "html"
362 write_chunked $buffer
363 end_chunked