703a06d373c722ced108c429639433fb656b1036
[openocd.git] / src / server / httpd / log.tcl
1 # converted to .tcl by html2tcl.tcl
2 set buffer ""
3 append buffer {
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48 <html xmlns="http://www.w3.org/TR/REC-html40">
49 <head>
50 <title>Zylin ZY1000 JTAG debugger</title>
51 <meta charset="utf-8" content="text/html" http-equiv="Content-Type"/>
52 <link type="text/css" rel="stylesheet" href="menuweb.css"/>
53 </head>
54 }
55
56 set console ""
57 set upload_filename /ram/upload
58
59 append buffer {
60 <body style="margin:0px;">
61 <div style="width:974px;height:85px;">
62 <div style="float:left;position:relative;left:32px;width:478px;">
63 <a href="/">
64 <img src="menu_cuts/logo_top.png" style="border:0px;"/>
65 </a>
66 </div>
67 <div style="float:left;position:relative;height:26px; width:278px;left:122px;background-image:url('menu_cuts/top_right.png');">
68 <div style="position:relative;left:15px;top:4px;" class="textlight">
69 }
70 append buffer [capture version]
71 append buffer {
72 </div>
73 </div>
74 </div>
75 <table style="padding:0px;border-collapse:collapse;">
76 <tr>
77 <td style="width:33px;">
78 <div style="width:20px;height:510px;">
79 &nbsp;
80 </div>
81 </td>
82 <td style="vertical-align:top;height:100%;width:140px;padding:0px;">
83 <table style="padding:0px;border-collapse:collapse;height:100%;width:140px;">
84 <tr style="height:59px;">
85 <td/>
86 </tr>
87 <tr>
88 <td style="width:140px;height:38px;background-image:url('menu_cuts/v_tab.png');background-repeat: no-repeat;">
89 <div style="position:relative;left:10px;top:10px;font-weight:bold;">
90 <a href="openocd.tcl" style="">Run Command</a>
91 </div>
92 </td>
93 </tr>
94 <tr>
95 <td style="width:140px;height:38px;background-image:url('menu_cuts/v_tab.png');background-repeat: no-repeat;">
96 <div style="position:relative;left:10px;top:10px;font-weight:bold;">
97 <a href="guiupload.tcl" style="">Upload File to ZY1000</a>
98 </div>
99 </td>
100 </tr>
101 <tr>
102 <td style="width:140px;height:38px;background-image:url('menu_cuts/v_tab_selected.png');background-repeat: no-repeat;">
103 <div style="position:relative;left:10px;top:10px;font-weight:bold;">
104 <a href="log.tcl#tail" style="">View Tail of Log</a>
105 </div>
106 </td>
107 </tr>
108 <tr>
109 <td style="width:140px;height:35px;background-image:url('menu_cuts/v_1.png')"/>
110 </tr>
111 <tr>
112 <td style="width:140px;background-image:url('menu_cuts/v_2_tile.png')"/>
113 </tr>
114 <tr>
115 <td style="width:140px;height:140px;background-image:url('menu_cuts/v_3.png')"/>
116 </tr>
117 </table>
118 </td>
119 <td style="vertical-align:top;padding:0px;height:100%">
120 <table style="padding:0px;border-collapse:collapse;height:100%;">
121 <tr>
122 <td>
123 <table style="padding:0px;border-collapse:collapse;">
124 <tr>
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="index.tcl">Config Target</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="flashinfo.tcl">Flash</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="browsemem.tcl">Memory</a>
138 </div>
139 </td>
140 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab1_selected.png');background-repeat: no-repeat;">
141 <div style="position:relative;top:7px;font-weight:bold;text-align:center;width:100px;">
142 <a href="openocd.tcl" style="font-weight: bold;">OpenOCD</a>
143 </div>
144 </td>
145 </tr>
146 </table>
147 </td>
148 </tr>
149 <tr>
150 <td style="height:30px;width:535px;background-image:url('menu_cuts/center_top.png');background-repeat: no-repeat;background-position:top right;" colspan="6">
151 <div style="width:500px;background-color:#ffffff;height:100%;">
152 &nbsp;
153 </div>
154 </td>
155 </tr>
156 <tr>
157 <td style="background-color:#ffffff;text-indent:30px;height:40px;" colspan="6">
158 <H1>View Tail of Log</H1>
159 </td>
160 </tr>
161 <tr style="height:100%;">
162 <td style="background-color:#ffffff;padding-left:30px;padding-right:30px;width=535px;height:100%;" colspan="6">
163 }
164
165 append buffer "<code style=\"white-space: nowrap;\">"
166 append buffer [encode [log]]
167 append buffer {<p><p><p><a name="tail"/>}
168 append buffer {<a href="log.tcl}
169 append buffer "?rnd=[rand]"
170 append buffer {#tail">Refresh</a>}
171 append buffer {<p>}
172 append buffer "</code>";
173
174 append buffer {
175
176 </td>
177 </tr>
178 }
179
180
181 set toggle_details [formfetch toggle_details]
182 if {[string length $toggle_details]==0} {
183 set toggle_details 0
184 }
185 set show_details [load_var show_details]
186 if {[string length $show_details]==0} {
187 set show_details 0
188 }
189 if {$toggle_details==1} {
190 set show_details [expr 1-$show_details]
191 save_var show_details $show_details
192 }
193
194 if {[string length $console]!=0} {
195
196 append buffer {
197 <tr style="height:100%;">
198 <td style="height:100%;background-color:red;" colspan="6">
199 <table style="padding:0px;border-collapse:collapse;background-color:#ffffff;width:100%" class="textgray">
200 <td style="width:25px;">&nbsp;</td>
201 }
202
203 if {$show_details==1} {
204 append buffer <
205 append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"}
206 append buffer >
207 } else {
208 append buffer <
209 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;"}
210 append buffer >
211 }
212
213 append buffer {
214 <a class="openocd" href="log.tcl?toggle_details=1">
215 }
216
217 if {$show_details==1} {
218 append buffer "Hide details"
219 append buffer <br/>
220 } else {
221 append buffer {<div style="position:relative;top:7px;text-align:center;">}
222 append buffer "Show details"
223 append buffer {</div>}
224 }
225
226 append buffer {
227 </a>
228 }
229
230 if {$show_details==1} {
231 append buffer $console
232 }
233
234 append buffer {</td>}
235
236 if {$show_details!=1} {
237 append buffer {<td>&nbsp;</td>}
238 }
239
240 append buffer {
241 <td style="width:25px;">&nbsp;</td>
242 </table>
243 </td>
244 </tr>
245 }
246
247 }
248
249 append buffer {
250 <tr>
251 <td style="height:30px;background-image:url('menu_cuts/center_bottom.png');background-repeat: no-repeat;background-position:top right;" colspan="6">
252 <div style="width:500px;background-color:#ffffff;height:100%;">
253 &nbsp;
254 </div>
255 </td>
256 </tr>
257 </table>
258 </td>
259 <td style="width:6px;"/>
260 <td style="width:245px;height:100%">
261 <table style="padding:0px;border-collapse:collapse;height:100%;">
262 <tr>
263 <td style="width:103px;height:29px;background-image:url('menu_cuts/h_tab2_selected.png');background-repeat: no-repeat;">
264 <div style="position:relative;top:7px;;font-weight:bold;text-align:center;width:100px;" class="textgray">
265 Documentation
266 </div>
267 </td>
268 <td width="40px">
269 &nbsp;
270 </td>
271 <td/>
272 </tr>
273 <tr>
274 <td style="height:10px;width:245px;background-image:url('menu_cuts/right_top_small.png');" colspan="3"/>
275 </tr>
276 <tr>
277 <td style="background-color:#d8d7d7;width:245px;padding-left:10px;padding-buttom:10px;line-height:17px;" colspan="3">
278 <a target="_blank" href="http://www.zylin.com/zy1000/ZY1000_Quick_Start_Guide.pdf">Quick Start Manual</a>
279 <br/>
280 <a target="_blank" href="http://www.zylin.com/zy1000/openocd.pdf">OpenOCD Manual</a>
281 <br/>
282 <a target="_blank" href="http://www.zylin.com/zy1000_contact.html">Contact Zylin AS</a>
283 </td>
284 </tr>
285 <tr>
286 <td style="background-color:#d8d7d7;height:15px;" colspan="3"/>
287 </tr>
288 <tr>
289 <td colspan="3">
290 <table style="padding:0px;border-collapse:collapse;">
291 <td style="background-color:#d8d7d7;width:10px;height:1px"/>
292 <td style="background-color:#999999;width:225px; height:1px;"/>
293 <td style="background-color:#d8d7d7;width:10px;height:1px"/>
294 </table>
295 </td>
296 </tr>
297 <tr>
298 <td style="background-color:#d8d7d7;height:15px;" colspan="3"/>
299 </tr>
300 <tr style="height:100%;">
301 <td style="height:100%;background-color:#d8d7d7;padding-left:10px;padding-right:10px;" colspan="3" class="textgray"/>
302 </tr>
303 <tr>
304 <td style="height:30px;background-image:url('menu_cuts/right_bottom.png');" colspan="3">
305 &nbsp;
306 </td>
307 </tr>
308 </table>
309 </td>
310 </tr>
311 <tr>
312 <td/>
313 <td>
314 <img border="0" src="menu_cuts/logo_bottom.png"/>
315 </td>
316 </tr>
317 </table>
318 </body>
319 </html>
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338 }
339
340 start_chunked "html"
341 write_chunked $buffer
342 end_chunked
343