From ec7a984b42f5f7e6192963f0c09340227fdfa829 Mon Sep 17 00:00:00 2001 From: ntfreak Date: Tue, 23 Dec 2008 12:52:14 +0000 Subject: [PATCH] - add missing svn props from r1270 commit - change mime-type for png files to image/png git-svn-id: svn://svn.berlios.de/openocd/trunk@1273 b42882b7-edfa-0310-969c-e2dbd0fdcd60 --- src/server/httpd/Stylizer.class | Bin src/server/httpd/Stylizer.java | 0 src/server/httpd/browsemem.tcl | 908 +++++++------- src/server/httpd/build.sh | 0 src/server/httpd/downloadmem.tcl | 732 +++++------ src/server/httpd/editconfigs.tcl | 924 +++++++------- src/server/httpd/editfile.tcl | 872 +++++++------- src/server/httpd/erase.tcl | 774 ++++++------ src/server/httpd/flash.tcl | 918 +++++++------- src/server/httpd/flashinfo.tcl | 764 ++++++------ src/server/httpd/guiupload.tcl | 672 +++++------ src/server/httpd/html2tcl.sh | 0 src/server/httpd/httpd.tcl | 226 ++-- src/server/httpd/index.tcl | 752 ++++++------ src/server/httpd/log.tcl | 686 +++++------ src/server/httpd/menu.xml | 1944 +++++++++++++++--------------- src/server/httpd/menu.xsl | 596 ++++----- src/server/httpd/menuweb.css | 264 ++-- src/server/httpd/openocd.tcl | 710 +++++------ src/server/httpd/preconfig.tcl | 858 ++++++------- src/server/httpd/production.tcl | 784 ++++++------ src/server/httpd/readme.txt | 48 +- src/server/httpd/reload.tcl | 644 +++++----- src/server/httpd/run.tcl | 764 ++++++------ src/server/httpd/support.tcl | 862 ++++++------- src/server/httpd/targets.tcl | 1120 ++++++++--------- src/server/httpd/terminal.tcl | 728 +++++------ src/server/httpd/upgrade.tcl | 836 ++++++------- 28 files changed, 9193 insertions(+), 9193 deletions(-) mode change 100644 => 100755 src/server/httpd/Stylizer.class mode change 100644 => 100755 src/server/httpd/Stylizer.java mode change 100644 => 100755 src/server/httpd/build.sh mode change 100644 => 100755 src/server/httpd/html2tcl.sh diff --git a/src/server/httpd/Stylizer.class b/src/server/httpd/Stylizer.class old mode 100644 new mode 100755 diff --git a/src/server/httpd/Stylizer.java b/src/server/httpd/Stylizer.java old mode 100644 new mode 100755 diff --git a/src/server/httpd/browsemem.tcl b/src/server/httpd/browsemem.tcl index 566643aafd..cef8408af8 100644 --- a/src/server/httpd/browsemem.tcl +++ b/src/server/httpd/browsemem.tcl @@ -1,454 +1,454 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Browse / Edit Memory

-
- - - - } - - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_type [formfetch form_type] - set form_action [formfetch form_action] - set form_value [formfetch form_value] - - if {[string compare $form_length ""]==0} { - set form_length 0 - } - if {$form_length<=0} { - set form_length 0x80 - } - if {$form_length>0x1000} { - set form_length 0x1000 - } - - if {[string compare $form_type ""]==0} { - set form_type mdw - } - - if {[string compare $form_type "mdw"]==0} { - set wordsize 4 - set modify_cmd mww - } - if {[string compare $form_type "mdh"]==0} { - set wordsize 2 - set modify_cmd mwh - } - if {[string compare $form_type "mdb"]==0} { - set wordsize 1 - set modify_cmd mwb - } - - - - - if {[string compare $form_address ""]!=0} { - if {[string compare $form_action "Previous"]==0} { - # Kludge! Work around problems parsing hex in Jim Tcl expressions - incr form_address ; set form_address [expr $form_address-1] - if {$form_address-$form_length>0} { - set form_address "0x[tohex [expr $form_address-$form_length]]" - } else { - set form_address "0x0" - } - } - if {[string compare $form_action "Next"]==0} { - # Kludge! Work around problems parsing hex in Jim Tcl expressions - incr form_address ; set form_address [expr $form_address-1] - set form_address "0x[tohex [expr $form_address+$form_length]]" - } - if {[string compare $form_action "Modify"]==0} { - append console [capture_catch "$modify_cmd $form_address $form_value"] - } - if {[string compare $form_action "Fill"]==0} { - append console [capture_catch "$modify_cmd $form_address $form_value $form_length"] - } - } - - - -append buffer { - -
- - - - - - - -
Address
Length
Value  
Type - - -
- - - - -
 
 
- - - - - -
  
-
- -
-

-

Memory:

- - } - - if {[string compare $form_address ""]!=0} { - append console [encode [capture_catch halt]] - append buffer [encode [capture_catch "$form_type $form_address [expr $form_length]"]] - } - -append buffer { - - - - - - -

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Browse and edit target memory.
- Length is in bytes, maximum 4096 bytes.

-

An error message is shown when trying to browse or edit memory which cases a CPU fault.

-

CPU will be halted if required.

-

Modify - Will modify only one byte, half-word or word starting at Address.

-

Fill - Will fill the specified region with the specified value.

-

Refresh - Display the content of the specified memory area.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Browse / Edit Memory

+
+ + + + } + + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_type [formfetch form_type] + set form_action [formfetch form_action] + set form_value [formfetch form_value] + + if {[string compare $form_length ""]==0} { + set form_length 0 + } + if {$form_length<=0} { + set form_length 0x80 + } + if {$form_length>0x1000} { + set form_length 0x1000 + } + + if {[string compare $form_type ""]==0} { + set form_type mdw + } + + if {[string compare $form_type "mdw"]==0} { + set wordsize 4 + set modify_cmd mww + } + if {[string compare $form_type "mdh"]==0} { + set wordsize 2 + set modify_cmd mwh + } + if {[string compare $form_type "mdb"]==0} { + set wordsize 1 + set modify_cmd mwb + } + + + + + if {[string compare $form_address ""]!=0} { + if {[string compare $form_action "Previous"]==0} { + # Kludge! Work around problems parsing hex in Jim Tcl expressions + incr form_address ; set form_address [expr $form_address-1] + if {$form_address-$form_length>0} { + set form_address "0x[tohex [expr $form_address-$form_length]]" + } else { + set form_address "0x0" + } + } + if {[string compare $form_action "Next"]==0} { + # Kludge! Work around problems parsing hex in Jim Tcl expressions + incr form_address ; set form_address [expr $form_address-1] + set form_address "0x[tohex [expr $form_address+$form_length]]" + } + if {[string compare $form_action "Modify"]==0} { + append console [capture_catch "$modify_cmd $form_address $form_value"] + } + if {[string compare $form_action "Fill"]==0} { + append console [capture_catch "$modify_cmd $form_address $form_value $form_length"] + } + } + + + +append buffer { + +
+ + + + + + + +
Address
Length
Value  
Type + + +
+ + + + +
 
 
+ + + + + +
  
+
+ +
+

+

Memory:

+ + } + + if {[string compare $form_address ""]!=0} { + append console [encode [capture_catch halt]] + append buffer [encode [capture_catch "$form_type $form_address [expr $form_length]"]] + } + +append buffer { + + + + + + +

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Browse and edit target memory.
+ Length is in bytes, maximum 4096 bytes.

+

An error message is shown when trying to browse or edit memory which cases a CPU fault.

+

CPU will be halted if required.

+

Modify - Will modify only one byte, half-word or word starting at Address.

+

Fill - Will fill the specified region with the specified value.

+

Refresh - Display the content of the specified memory area.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/build.sh b/src/server/httpd/build.sh old mode 100644 new mode 100755 diff --git a/src/server/httpd/downloadmem.tcl b/src/server/httpd/downloadmem.tcl index 6e9d00fb87..e6127aeafd 100644 --- a/src/server/httpd/downloadmem.tcl +++ b/src/server/httpd/downloadmem.tcl @@ -1,366 +1,366 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Download Memory Range

-
- } - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_action [formfetch form_action] - -append buffer { -
- - - - -
Address
Length
- - - - - -
 
 
- - - - -
- } - - if {[string compare $form_action "Download"]==0} { - append console [encode [capture_catch "reset init"]] - append console [encode [capture_catch "dump_image /tmp/dump.bin $form_address $form_length"]] - -append buffer { -
- -
- } - - } - - -append buffer { - - - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- - Download memory from target.
- Note that download memory can take - a long time(potentially minutes for megabytes at low JTAG clk speeds). -

- Once the memory is downloaded a link is available on the page to download - the file to your PC. - -

-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Download Memory Range

+
+ } + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_action [formfetch form_action] + +append buffer { +
+ + + + +
Address
Length
+ + + + + +
 
 
+ + + + +
+ } + + if {[string compare $form_action "Download"]==0} { + append console [encode [capture_catch "reset init"]] + append console [encode [capture_catch "dump_image /tmp/dump.bin $form_address $form_length"]] + +append buffer { +
+ +
+ } + + } + + +append buffer { + + + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ + Download memory from target.
+ Note that download memory can take + a long time(potentially minutes for megabytes at low JTAG clk speeds). +

+ Once the memory is downloaded a link is available on the page to download + the file to your PC. + +

+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/editconfigs.tcl b/src/server/httpd/editconfigs.tcl index 13e3910628..e27bc0535c 100644 --- a/src/server/httpd/editconfigs.tcl +++ b/src/server/httpd/editconfigs.tcl @@ -1,462 +1,462 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Edit Target Configurations

-
-
- } - - set form_edittext [formfetch form_edittext] - set form_action [formfetch form_action] - set form_filename [formfetch form_filename] - set form_selected [formfetch form_selected] - - if {[string compare $form_action "Load"]==0} { - set form_filename $form_selected - } - - if {[string compare $form_action "Delete"]==0} { - capture_catch "rm /config/settings/$form_selected" - } - - if {[string compare $form_action "Save"]==0} { - save_var $form_filename [from_textarea $form_edittext] - append buffer "Wrote file $form_filename
" - } - - set form_edittext "" - - # load original or script saved on disk. - if {[string compare $form_action "Show default"]==0} { - set form_edittext [load_file "/rom/$form_selected"] - set form_filename $form_selected - } else { - set form_edittext [load_config $form_filename] - } - - set form_edittext_subst [to_textarea $form_edittext] - - - proc prepend { val list } { - set res "" - foreach value $list { - set t $val - append t $value - lappend res $t - } - return $res - } - - set files [prepend target/ [ls /rom/target]] - set files [lunion $files [prepend event/ [ls /config/settings/event]]] - set files [lunion $files [prepend target/ [ls /config/settings/target]]] - set files [lsort $files] - - -append buffer { - - - - - - - - -
   
- - - } - - append buffer {\n" - append buffer {
} "\n" - append buffer {
File 
} "\n" - -append buffer { -
-
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
- -

Here you can edit predefined target configurations, restore predefined configurations to - default state and create new target configurations.

-

Typically when creating a new target configuration, you would take an existing - configuration that resembles the most your needs and modify it for your - purposes and save it under a different name.

-

Load - Loads a configuration file into the editor.

-

Show default - Loads the firmware included version of the - configuration file (if any), into the editor.
- Note that the editor content is not saved.

-

Delete - Deletes a custom created configuration file.
- Note that firmware included configuration files can not be deleted.

-

Save - Save the edited file under the a new or the same name.

- -
-   -
-
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Edit Target Configurations

+
+
+ } + + set form_edittext [formfetch form_edittext] + set form_action [formfetch form_action] + set form_filename [formfetch form_filename] + set form_selected [formfetch form_selected] + + if {[string compare $form_action "Load"]==0} { + set form_filename $form_selected + } + + if {[string compare $form_action "Delete"]==0} { + capture_catch "rm /config/settings/$form_selected" + } + + if {[string compare $form_action "Save"]==0} { + save_var $form_filename [from_textarea $form_edittext] + append buffer "Wrote file $form_filename
" + } + + set form_edittext "" + + # load original or script saved on disk. + if {[string compare $form_action "Show default"]==0} { + set form_edittext [load_file "/rom/$form_selected"] + set form_filename $form_selected + } else { + set form_edittext [load_config $form_filename] + } + + set form_edittext_subst [to_textarea $form_edittext] + + + proc prepend { val list } { + set res "" + foreach value $list { + set t $val + append t $value + lappend res $t + } + return $res + } + + set files [prepend target/ [ls /rom/target]] + set files [lunion $files [prepend event/ [ls /config/settings/event]]] + set files [lunion $files [prepend target/ [ls /config/settings/target]]] + set files [lsort $files] + + +append buffer { + + + + + + + + +
   
+ + + } + + append buffer {\n" + append buffer {
} "\n" + append buffer {
File 
} "\n" + +append buffer { +
+
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+ +

Here you can edit predefined target configurations, restore predefined configurations to + default state and create new target configurations.

+

Typically when creating a new target configuration, you would take an existing + configuration that resembles the most your needs and modify it for your + purposes and save it under a different name.

+

Load - Loads a configuration file into the editor.

+

Show default - Loads the firmware included version of the + configuration file (if any), into the editor.
+ Note that the editor content is not saved.

+

Delete - Deletes a custom created configuration file.
+ Note that firmware included configuration files can not be deleted.

+

Save - Save the edited file under the a new or the same name.

+ +
+   +
+
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/editfile.tcl b/src/server/httpd/editfile.tcl index 8838e69f76..6a393263e9 100644 --- a/src/server/httpd/editfile.tcl +++ b/src/server/httpd/editfile.tcl @@ -1,436 +1,436 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- - - -
-
-
-   -
-
-

Edit File

-
-} - - - -#Read a text file, edit it and write it back. Useful for interactive debugging -#of tcl scripts - -set data "" -append buffer {
} "\n" - -set err ""; - -set form_edittext [formfetch form_edittext]; -set form_action [formfetch form_action]; -set form_filename [formfetch form_filename]; - -puts Action $form_action - -if {[string compare $form_action "Load"]==0} { - - set form_edittext "" - catch { - set fp [aio.open $form_filename r]; - set form_edittext [$fp read]; - $fp close; - } err -} -if {[string compare $form_action "Delete"]==0} { - capture "rm $form_filename" -} - -set form_edittext_subst [to_textarea $form_edittext] - - -if {[string compare $form_action "Save"]==0} { - if {[catch { - set fp [aio.open $form_filename w]; - $fp puts [from_textarea $form_edittext] - $fp close - append buffer "Wrote file $form_filename
" - } err]} { - append buffer "Could not write $form_filename
" - } -} - - - - -append buffer {\n" -append buffer {} "\n" -append buffer {
File   
} "\n" -append buffer {
} - -append buffer {
} - -append buffer { } "\n" - - - -append buffer { - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
- - Edit any file on the ZY1000 by typing in the - filename and pressing Load. -

- - -
Browse files on /ram
- Browse files on /config
- Browse files on /rom
- -
-   -
-
- - -
- - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ + + +
+
+
+   +
+
+

Edit File

+
+} + + + +#Read a text file, edit it and write it back. Useful for interactive debugging +#of tcl scripts + +set data "" +append buffer {} "\n" + +set err ""; + +set form_edittext [formfetch form_edittext]; +set form_action [formfetch form_action]; +set form_filename [formfetch form_filename]; + +puts Action $form_action + +if {[string compare $form_action "Load"]==0} { + + set form_edittext "" + catch { + set fp [aio.open $form_filename r]; + set form_edittext [$fp read]; + $fp close; + } err +} +if {[string compare $form_action "Delete"]==0} { + capture "rm $form_filename" +} + +set form_edittext_subst [to_textarea $form_edittext] + + +if {[string compare $form_action "Save"]==0} { + if {[catch { + set fp [aio.open $form_filename w]; + $fp puts [from_textarea $form_edittext] + $fp close + append buffer "Wrote file $form_filename
" + } err]} { + append buffer "Could not write $form_filename
" + } +} + + + + +append buffer {\n" +append buffer {} "\n" +append buffer {
File   
} "\n" +append buffer {
} + +append buffer {
} + +append buffer { } "\n" + + + +append buffer { + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+ + Edit any file on the ZY1000 by typing in the + filename and pressing Load. +

+ + +
Browse files on /ram
+ Browse files on /config
+ Browse files on /rom
+ +
+   +
+
+ + +
+ + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/erase.tcl b/src/server/httpd/erase.tcl index fa9210736d..a63ef37b9f 100644 --- a/src/server/httpd/erase.tcl +++ b/src/server/httpd/erase.tcl @@ -1,387 +1,387 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
-
-Info -
-
-
-Erase -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Erase Flash

-
- - - - } - - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_action [formfetch form_action] - - if {[string compare $form_length ""]==0} { - set form_length 0x10000 - } - if {[string compare $form_address ""]==0} { - if {[catch {[first_flash_base]} result]==0} { - set form_address "0x[tohex $result]" - } - } - - - if {[string compare $form_address ""]!=0} { - if {[string compare $form_action "Erase"]==0} { - append buffer "" - append console [encode [capture_catch { - reset init - flash erase_address $form_address $form_length}]] - append buffer - } - } - - - -append buffer { - - - - - - -
Address
Length
- - - - -
 
 
- -
- - - - - - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Note that flash programming will erase flash if required.

-

Reset and init CPU, then erase address range.

-

The length field is specified in number of bytes.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+
+Info +
+
+
+Erase +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Erase Flash

+
+ + + + } + + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_action [formfetch form_action] + + if {[string compare $form_length ""]==0} { + set form_length 0x10000 + } + if {[string compare $form_address ""]==0} { + if {[catch {[first_flash_base]} result]==0} { + set form_address "0x[tohex $result]" + } + } + + + if {[string compare $form_address ""]!=0} { + if {[string compare $form_action "Erase"]==0} { + append buffer "" + append console [encode [capture_catch { + reset init + flash erase_address $form_address $form_length}]] + append buffer + } + } + + + +append buffer { + +
+ + + + +
Address
Length
+ + + + +
 
 
+ +
+ + +
+ + + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Note that flash programming will erase flash if required.

+

Reset and init CPU, then erase address range.

+

The length field is specified in number of bytes.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/flash.tcl b/src/server/httpd/flash.tcl index 6fd1cb16c2..3ad9772f27 100644 --- a/src/server/httpd/flash.tcl +++ b/src/server/httpd/flash.tcl @@ -1,459 +1,459 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
-
-Info -
-
-
-Erase -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Program / Verify Flash

-
- - } - - - set form_offset [formfetch form_offset] - set form_action [formfetch form_action] - set form_type [formfetch form_type] - - - set post "" - catch {set post $post_data} err - - if {[string compare $form_offset ""]==0} { - set form_offset 0 - } - if {[string compare $form_type ""]==0} { - set form_type "" - } - - -append buffer {} - - - set data "" - append buffer {
} - - set action_reset [expr {[string length $form_action]!=0}] - set action_flash [expr {[string compare $form_action "Flash"]==0 || [string compare $form_action "Flash and verify"]==0}] - set action_verify [expr {[string compare $form_action "Verify"]==0 || [string compare $form_action "Flash and verify"]==0}] - - if {$action_reset} { - append console [encode [capture_catch "reset init"]] - } - -append buffer { - } - - - append buffer {} - append buffer {} - append buffer "" - - -append buffer { - - - - - -
File
Offset
Type - -
- - - - - -
 
 
- - - - - -
- -

- } - - - if {$action_flash||$action_verify} { - catch {writeform form_filecontent $upload_filename} result - append console [encode $result] - } - append buffer "
" - if {$action_flash} { - append console [encode [capture_catch "halt"]] - append buffer "" - if {[catch {capture_catch {eval "flash write_image erase $upload_filename $form_offset $form_type"}} result]} { - append buffer "Flash write failed
" - append console [encode $result] - } else { - append buffer [encode $result] - append buffer "Flash write succeed
" - } - append buffer "
" - } - if {$action_verify} { - append console [encode [capture_catch "halt"]] - append buffer "" - if {[catch {capture_catch {eval "verify_image $upload_filename $form_offset $form_type"}} result]} { - append buffer "Verify failed
" - append console [encode $result] - } else { - append buffer [encode $result] - append buffer "Verify succeed
" - } - append buffer "
" - } - -append buffer { - -

- -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Program and/or verify the flash on your target.

-

Flash - Halt CPU, automatically erase flash if required and program flash with image.

-

Flash and verify - Programs the flash and verifies the programmed flash content is correct.

-

Verify - Halt CPU and verify image in flash or RAM.

-

Offset - This value is added to the address of the image.
- Binary images start at address 0 by default, whereas elf and ihex have addresses encoded into the image.
- Typically 0 for elf/ihex and the address to write the image to for binary files.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+
+Info +
+
+
+Erase +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Program / Verify Flash

+
+ + } + + + set form_offset [formfetch form_offset] + set form_action [formfetch form_action] + set form_type [formfetch form_type] + + + set post "" + catch {set post $post_data} err + + if {[string compare $form_offset ""]==0} { + set form_offset 0 + } + if {[string compare $form_type ""]==0} { + set form_type "" + } + + +append buffer {} + + + set data "" + append buffer {
} + + set action_reset [expr {[string length $form_action]!=0}] + set action_flash [expr {[string compare $form_action "Flash"]==0 || [string compare $form_action "Flash and verify"]==0}] + set action_verify [expr {[string compare $form_action "Verify"]==0 || [string compare $form_action "Flash and verify"]==0}] + + if {$action_reset} { + append console [encode [capture_catch "reset init"]] + } + +append buffer { + } + + + append buffer {} + append buffer {} + append buffer "" + + +append buffer { + + + + + +
File
Offset
Type + +
+ + + + + +
 
 
+ + + + + +
+ +

+ } + + + if {$action_flash||$action_verify} { + catch {writeform form_filecontent $upload_filename} result + append console [encode $result] + } + append buffer "
" + if {$action_flash} { + append console [encode [capture_catch "halt"]] + append buffer "" + if {[catch {capture_catch {eval "flash write_image erase $upload_filename $form_offset $form_type"}} result]} { + append buffer "Flash write failed
" + append console [encode $result] + } else { + append buffer [encode $result] + append buffer "Flash write succeed
" + } + append buffer "
" + } + if {$action_verify} { + append console [encode [capture_catch "halt"]] + append buffer "" + if {[catch {capture_catch {eval "verify_image $upload_filename $form_offset $form_type"}} result]} { + append buffer "Verify failed
" + append console [encode $result] + } else { + append buffer [encode $result] + append buffer "Verify succeed
" + } + append buffer "
" + } + +append buffer { + +

+ +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Program and/or verify the flash on your target.

+

Flash - Halt CPU, automatically erase flash if required and program flash with image.

+

Flash and verify - Programs the flash and verifies the programmed flash content is correct.

+

Verify - Halt CPU and verify image in flash or RAM.

+

Offset - This value is added to the address of the image.
+ Binary images start at address 0 by default, whereas elf and ihex have addresses encoded into the image.
+ Typically 0 for elf/ihex and the address to write the image to for binary files.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/flashinfo.tcl b/src/server/httpd/flashinfo.tcl index 7a208636c9..8e9f3e25b5 100644 --- a/src/server/httpd/flashinfo.tcl +++ b/src/server/httpd/flashinfo.tcl @@ -1,382 +1,382 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
-
-Info -
-
-
-Erase -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Flash Information

-
- -
Configured flash banks:
-

- - } - - set flash_return [ocd_flash_banks] - if {[llength $flash_return]!=0} { - append buffer [encode [flash banks]] - - set form_action [formfetch form_action] - if {[string compare $form_action "Reset CPU and probe flash"]==0} { - append console [encode [capture_catch "reset init"]] - append buffer [encode [capture_catch "flash probe 0"]] - append buffer [encode [capture_catch "flash info 0"]] - } - } else { - append buffer "No flash bank configured." - } - -append buffer { -

-

- - - } - - foreach a [ocd_flash_banks] { - append buffer "Flash bank at [format "0x%08x size 0x%08x" $a(base) $a(size)]: " - -append buffer { -
- - - - -
-
- } - - } - -append buffer { -
- - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Here you will find information about the flash chips that you have - in your configuration.

-

Reset CPU and probe flash - This will reset the CPU and show - you more detailed information about your flash. This includes information about - the different sectors in the flash, and the flash driver used.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+
+Info +
+
+
+Erase +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Flash Information

+
+ +
Configured flash banks:
+

+ + } + + set flash_return [ocd_flash_banks] + if {[llength $flash_return]!=0} { + append buffer [encode [flash banks]] + + set form_action [formfetch form_action] + if {[string compare $form_action "Reset CPU and probe flash"]==0} { + append console [encode [capture_catch "reset init"]] + append buffer [encode [capture_catch "flash probe 0"]] + append buffer [encode [capture_catch "flash info 0"]] + } + } else { + append buffer "No flash bank configured." + } + +append buffer { +

+

+ + + } + + foreach a [ocd_flash_banks] { + append buffer "Flash bank at [format "0x%08x size 0x%08x" $a(base) $a(size)]: " + +append buffer { +
+ + + + +
+
+ } + + } + +append buffer { +
+ + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Here you will find information about the flash chips that you have + in your configuration.

+

Reset CPU and probe flash - This will reset the CPU and show + you more detailed information about your flash. This includes information about + the different sectors in the flash, and the flash driver used.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/guiupload.tcl b/src/server/httpd/guiupload.tcl index 1911510cc9..804bfe4205 100644 --- a/src/server/httpd/guiupload.tcl +++ b/src/server/httpd/guiupload.tcl @@ -1,336 +1,336 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Upload File

-
- - } - - set form_filename [formfetch form_filename]; - set form_action [formfetch form_action]; - #set form_filecontent [formfetch form_filecontent]; - - append buffer {
} - append buffer
- if {[string compare $form_action "Upload"]==0} { - if {[catch {writeform form_filecontent $form_filename} result]==0} { - append buffer [encode $result] - } else { - append buffer Wrote $form_filename - } - } - - append buffer {} - append buffer {
Filename on OpenOCD machine
File to upload
} - append buffer {
 
 
} - append buffer {
} - append buffer {
} - - -append buffer { - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
-
-   -
-
- - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Upload File

+
+ + } + + set form_filename [formfetch form_filename]; + set form_action [formfetch form_action]; + #set form_filecontent [formfetch form_filecontent]; + + append buffer {
} + append buffer
+ if {[string compare $form_action "Upload"]==0} { + if {[catch {writeform form_filecontent $form_filename} result]==0} { + append buffer [encode $result] + } else { + append buffer Wrote $form_filename + } + } + + append buffer {} + append buffer {
Filename on OpenOCD machine
File to upload
} + append buffer {
 
 
} + append buffer {
} + append buffer {
} + + +append buffer { + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+
+   +
+
+ + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/html2tcl.sh b/src/server/httpd/html2tcl.sh old mode 100644 new mode 100755 diff --git a/src/server/httpd/httpd.tcl b/src/server/httpd/httpd.tcl index a8bce16286..a2fee129d4 100644 --- a/src/server/httpd/httpd.tcl +++ b/src/server/httpd/httpd.tcl @@ -1,113 +1,113 @@ -# some dummy proc's to get things going for test purposes - - - -proc ip {} { -return 10.0.0.55 -} - -proc start_chunked {a} { - global httpdata - global httpmime - set httpmime $a - set httpdata "" -} - -proc write_chunked {a} { - global httpdata - append httpdata $a -} - -proc end_chunked {} { -} - - - -#proc formfetch {a} { -# global httppostdata - #catch { -# echo "$a=$httppostdata($a)" - #return $httppostdata($a) - #} -# - #return "" -#} - - - - -proc tohex {a} { - set r "" - while 1 { - - set rem [expr $a%16] - set a [expr $a/16] - set r [string index "0123456789abcdef" $rem]$r - if ($a==0) then break - } - return $r -} - -# encode text -proc encode {a} { - return [string map {\n
{ } { } \t {        } > > < < / /} $a] -} - -#stubs that can be overriden to save between sessions -proc load_var {a} { - global glob_var - catch { - return $glob_var($a) - } - return "" -} -#stubs that can be overriden to save between sessions -proc save_var {a b} { - catch { - set glob_var($a) $b - return "" - } err - set glob_var($a) "" - return "" -} - - - -proc to_textarea {a} { - return [string map {& & > > < < / /} $a] -} - -proc from_textarea {a} { - return [string map {> > < < & & / /} $a] -} - -proc lunion {a b} { - foreach e $a { - set x($e) {} - } - foreach e $b { - if {![info exists x($e)]} { - lappend a $e - } - } - return $a -} - - -# encode text -proc encode {a} { - return [string map {\n
{ } { } \t {        } > > < < / /} $a] -} - -# catch any exceptions, capture output and return it -proc capture_catch {a} { - catch { - capture {uplevel $a} - } result - return $result -} - -proc first_flash_base {} { - set t [lindex 0 [ocd_flash_banks]] - return $t(base) -} +# some dummy proc's to get things going for test purposes + + + +proc ip {} { +return 10.0.0.55 +} + +proc start_chunked {a} { + global httpdata + global httpmime + set httpmime $a + set httpdata "" +} + +proc write_chunked {a} { + global httpdata + append httpdata $a +} + +proc end_chunked {} { +} + + + +#proc formfetch {a} { +# global httppostdata + #catch { +# echo "$a=$httppostdata($a)" + #return $httppostdata($a) + #} +# + #return "" +#} + + + + +proc tohex {a} { + set r "" + while 1 { + + set rem [expr $a%16] + set a [expr $a/16] + set r [string index "0123456789abcdef" $rem]$r + if ($a==0) then break + } + return $r +} + +# encode text +proc encode {a} { + return [string map {\n
{ } { } \t {        } > > < < / /} $a] +} + +#stubs that can be overriden to save between sessions +proc load_var {a} { + global glob_var + catch { + return $glob_var($a) + } + return "" +} +#stubs that can be overriden to save between sessions +proc save_var {a b} { + catch { + set glob_var($a) $b + return "" + } err + set glob_var($a) "" + return "" +} + + + +proc to_textarea {a} { + return [string map {& & > > < < / /} $a] +} + +proc from_textarea {a} { + return [string map {> > < < & & / /} $a] +} + +proc lunion {a b} { + foreach e $a { + set x($e) {} + } + foreach e $b { + if {![info exists x($e)]} { + lappend a $e + } + } + return $a +} + + +# encode text +proc encode {a} { + return [string map {\n
{ } { } \t {        } > > < < / /} $a] +} + +# catch any exceptions, capture output and return it +proc capture_catch {a} { + catch { + capture {uplevel $a} + } result + return $result +} + +proc first_flash_base {} { + set t [lindex 0 [ocd_flash_banks]] + return $t(base) +} diff --git a/src/server/httpd/index.tcl b/src/server/httpd/index.tcl index f450ce0f63..35c5cc79d5 100644 --- a/src/server/httpd/index.tcl +++ b/src/server/httpd/index.tcl @@ -1,376 +1,376 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - OpenOCD - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - -
-
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

OpenOCD debugger

-
- - - - - - -
 
 
- -

Target Status

- - - - - -
- } - - set form_address [formfetch form_address] - set form_action [formfetch form_action] - - if {[string compare $form_action "Halt"]==0} { - append console [encode [capture_catch "halt"]] - } - if {[string compare $form_action "Resume"]==0} { - append console [encode [capture_catch "resume"]] - } - - if {[string compare $form_action "Reset and run"]==0} { - append console [encode [capture_catch "reset run"]] - } - - if {[string compare $form_action "Power on"]==0} { - append console [encode [capture_catch "power on"]] - } - if {[string compare $form_action "Power off"]==0} { - append console [encode [capture_catch "power off"]] - } - -append buffer { - - } -append console [encode [capture_catch poll]] -append buffer { -
- -
- - - - - - -
- -
-
- -

-

-
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Target status shows that status of the connected target.

-

Current target - selected target configuration.
-

Startup - whether or not the target script ran to completion. Note - that even if the target is disconnected, powered down or unresponsive, the - startup script will still run to completion. Startup - OK does not mean - that the target is fully operational, simply that the configuration script - did not contain syntax errors for instance. - See log for details.
-

Target power - Detects power on target.
- If the JTAG cable is not connected, or the target has no power, then no target power will be detected.

-

Type "help power" in telnet for command to control power relay.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + OpenOCD + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + +
+
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

OpenOCD debugger

+
+ + + + + + +
 
 
+ +

Target Status

+ + + + + +
+ } + + set form_address [formfetch form_address] + set form_action [formfetch form_action] + + if {[string compare $form_action "Halt"]==0} { + append console [encode [capture_catch "halt"]] + } + if {[string compare $form_action "Resume"]==0} { + append console [encode [capture_catch "resume"]] + } + + if {[string compare $form_action "Reset and run"]==0} { + append console [encode [capture_catch "reset run"]] + } + + if {[string compare $form_action "Power on"]==0} { + append console [encode [capture_catch "power on"]] + } + if {[string compare $form_action "Power off"]==0} { + append console [encode [capture_catch "power off"]] + } + +append buffer { + + } +append console [encode [capture_catch poll]] +append buffer { +
+ +
+ + + + + + +
+ +
+
+ +

+

+
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Target status shows that status of the connected target.

+

Current target - selected target configuration.
+

Startup - whether or not the target script ran to completion. Note + that even if the target is disconnected, powered down or unresponsive, the + startup script will still run to completion. Startup - OK does not mean + that the target is fully operational, simply that the configuration script + did not contain syntax errors for instance. + See log for details.
+

Target power - Detects power on target.
+ If the JTAG cable is not connected, or the target has no power, then no target power will be detected.

+

Type "help power" in telnet for command to control power relay.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/log.tcl b/src/server/httpd/log.tcl index c5794512bd..703a06d373 100644 --- a/src/server/httpd/log.tcl +++ b/src/server/httpd/log.tcl @@ -1,343 +1,343 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

View Tail of Log

-
- } - - append buffer "" - append buffer [encode [log]] - append buffer {

} - append buffer {Refresh} - append buffer {

} - append buffer ""; - -append buffer { - -

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
-
-   -
-
- - -
- - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

View Tail of Log

+
+ } + + append buffer "" + append buffer [encode [log]] + append buffer {

} + append buffer {Refresh} + append buffer {

} + append buffer ""; + +append buffer { + +

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+
+   +
+
+ + +
+ + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/menu.xml b/src/server/httpd/menu.xml index 26ecf7a91c..ef1d4ec8a0 100644 --- a/src/server/httpd/menu.xml +++ b/src/server/httpd/menu.xml @@ -1,973 +1,973 @@ - - - - - - - - index.tcl - Config Target - index.tcl - OpenOCD debugger - index.tcl - - - - - - -   - -   - - -

Target Status

- - - - - -
- - set form_address [formfetch form_address] - set form_action [formfetch form_action] - - if {[string compare $form_action "Halt"]==0} { - append console [encode [capture_catch "halt"]] - } - if {[string compare $form_action "Resume"]==0} { - append console [encode [capture_catch "resume"]] - } - - if {[string compare $form_action "Reset and run"]==0} { - append console [encode [capture_catch "reset run"]] - } - - if {[string compare $form_action "Power on"]==0} { - append console [encode [capture_catch "power on"]] - } - if {[string compare $form_action "Power off"]==0} { - append console [encode [capture_catch "power off"]] - } - - - append console [encode [capture_catch poll]] -
- -
- - - - - - -
- -
-
- -

-

- ]]>
- - Target status shows that status of the connected target.

-

Current target - selected target configuration.
-

Startup - whether or not the target script ran to completion. Note - that even if the target is disconnected, powered down or unresponsive, the - startup script will still run to completion. Startup - OK does not mean - that the target is fully operational, simply that the configuration script - did not contain syntax errors for instance. - See log for details.
-

Target power - Detects power on target.
- If the JTAG cable is not connected, or the target has no power, then no target power will be detected.

-

Type "help power" in telnet for command to control power relay.

- ]]>
-
- -
-
- - - - - - targets.tcl - documentation.tcl - Target config quick start guide - - - The reset init script is crucial. It will set up e.g. MMU, chip - select registers, etc. after a reset. The init.cfg (reset init script) - is embedded into the openocd.cfg file in the sampls OpenOCD provides. -

- Writing an openocd.cfg from scratch is a non-trivial exercise, but - fortunally it only has to be done once for a target and afterwards it - rarely if ever needs to be changed. - - - ]]> - - - Quick start guide on how to configure a target. - - - - - - - - - - - flashinfo.tcl - Flash - flashinfo.tcl - Flash Information - flashinfo.tcl - - - - - - - - - - - Configured flash banks: -

- - - set flash_return [ocd_flash_banks] - if {[llength $flash_return]!=0} { - append buffer [encode [flash banks]] - - set form_action [formfetch form_action] - if {[string compare $form_action "Reset CPU and probe flash"]==0} { - append console [encode [capture_catch "reset init"]] - append buffer [encode [capture_catch "flash probe 0"]] - append buffer [encode [capture_catch "flash info 0"]] - } - } else { - append buffer "No flash bank configured." - } - -

-

- - - - foreach a [ocd_flash_banks] { - append buffer "Flash bank at [format "0x%08x size 0x%08x" $a(base) $a(size)]: " - -
- "> - "> - - -
-
- - } - -
- - - ]]>
- - Here you will find information about the flash chips that you have - in your configuration.

-

Reset CPU and probe flash - This will reset the CPU and show - you more detailed information about your flash. This includes information about - the different sectors in the flash, and the flash driver used.

- ]]> -
- -
-
- - - flash.tcl - flashinfo.tcl - Program / Verify Flash - - - - set form_offset [formfetch form_offset] - set form_action [formfetch form_action] - set form_type [formfetch form_type] - - - set post "" - catch {set post $post_data} err - - if {[string compare $form_offset ""]==0} { - set form_offset 0 - } - if {[string compare $form_type ""]==0} { - set form_type "" - } - - - - set data "" - append buffer {
} - - set action_reset [expr {[string length $form_action]!=0}] - set action_flash [expr {[string compare $form_action "Flash"]==0 || [string compare $form_action "Flash and verify"]==0}] - set action_verify [expr {[string compare $form_action "Verify"]==0 || [string compare $form_action "Flash and verify"]==0}] - - if {$action_reset} { - append console [encode [capture_catch "reset init"]] - } - - - - append buffer {} - append buffer {} - append buffer "" - - - - - - - -
File
Offset
Type - -
- - - - - -
 
 
- - - - - -
- -

- - - if {$action_flash||$action_verify} { - catch {writeform form_filecontent $upload_filename} result - append console [encode $result] - } - append buffer "
" - if {$action_flash} { - append console [encode [capture_catch "halt"]] - append buffer "" - if {[catch {capture_catch {eval "flash write_image erase $upload_filename $form_offset $form_type"}} result]} { - append buffer "Flash write failed
" - append console [encode $result] - } else { - append buffer [encode $result] - append buffer "Flash write succeed
" - } - append buffer "
" - } - if {$action_verify} { - append console [encode [capture_catch "halt"]] - append buffer "" - if {[catch {capture_catch {eval "verify_image $upload_filename $form_offset $form_type"}} result]} { - append buffer "Verify failed
" - append console [encode $result] - } else { - append buffer [encode $result] - append buffer "Verify succeed
" - } - append buffer "
" - } -
- -

- - ]]>
- - - Program and/or verify the flash on your target.

-

Flash - Halt CPU, automatically erase flash if required and program flash with image.

-

Flash and verify - Programs the flash and verifies the programmed flash content is correct.

-

Verify - Halt CPU and verify image in flash or RAM.

-

Offset - This value is added to the address of the image.
- Binary images start at address 0 by default, whereas elf and ihex have addresses encoded into the image.
- Typically 0 for elf/ihex and the address to write the image to for binary files.

- ]]> -
- - -
- -
- - - - - - production.tcl - flashinfo.tcl - Production - - - set form_action [formfetch form_action] - set form_serialnumber [formfetch form_serialnumber] - append buffer [production_info] - - -
- - - if {[string compare $form_action "Upload firmware"]==0} { - set wrotedata [catch {writeform form_filecontent $upload_filename} result] - append buffer [encode $result] - if {$wrotedata==0} { - append buffer "
Running production procedure

" - append buffer "
Reset and init:
" - - append console [encode [capture_catch {catch "production $upload_filename $form_serialnumber"}]] - } - } - if {[string compare $form_action "Test"]==0} { - append buffer "
Running production test. Output from first 10 seconds printed below.

" - - append console [encode [capture_catch {catch production_test}]] - } - if {[string compare $form_action "Power on"]==0} { - append console [encode [capture_catch "power on"]] - } - if {[string compare $form_action "Power off"]==0} { - append console [encode [capture_catch "power off"]] - } - - - - append buffer {

Firmware file(raw binary)

} - append buffer {

Serial number

} - - - - - - -
 
 
- - - - - -
    -
-

- - ]]>
- - - Upload firmware - Power cycle target, reset target and program raw binary file to flash bank 0, offset 0 and verify flash programming. Leave target powered on.

-

Test - Power up target, run 10 second target test. Output is provided via the DCC output channel.

-

Power on - Power on target.

-

Power off - Power off target.

-

Serial number - A target script can use this string in the production procedure. Type "help production" for more info.

- ]]> -
- - -
- -
- - - - - erase.tcl - erase.tcl - Erase Flash - flashinfo.tcl - - - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_action [formfetch form_action] - - if {[string compare $form_length ""]==0} { - set form_length 0x10000 - } - if {[string compare $form_address ""]==0} { - if {[catch {[first_flash_base]} result]==0} { - set form_address "0x[tohex $result]" - } - } - - - if {[string compare $form_address ""]!=0} { - if {[string compare $form_action "Erase"]==0} { - append buffer "" - append console [encode [capture_catch { - reset init - flash erase_address $form_address $form_length}]] - append buffer - } - } - - - - -
- - - - -
Address
Length
- - - - -
 
 
- -
- - -
- - - - ]]>
- - Note that flash programming will erase flash if required.

-

Reset and init CPU, then erase address range.

-

The length field is specified in number of bytes.

- ]]> -
- -
-
- - - - run.tcl - run.tcl - Run program - flashinfo.tcl - - - -set form_address [formfetch form_address] -set form_action [formfetch form_action] - -if {[string compare $form_action "Run from address"]==0} { - append console [encode [capture_catch "halt"]] - append console [encode [capture_catch "wait_halt"]] - append console [encode [capture_catch "resume $form_address"]] -} - -if {[string compare $form_action "Halt"]==0} { - append console [encode [capture_catch "halt"]] - append console [encode [capture_catch "wait_halt"]] -} - -if {[string compare $form_action "Reset and run"]==0} { - append console [encode [capture_catch "reset run"]] -} - -if {[string compare $form_action "Reset and init"]==0} { - append console [encode [capture_catch "reset init"]] -} - -append console [encode [capture_catch poll]] - - - -
- - - -
Address
- - - - -
 
 
- -
-
- - - - ]]>
- - Reset and run - reset CPU and let it run.

-

Halt - halt CPU.

-

Run from address - halt CPU and resume from address. Default is resume from current address.

-

Reset and init - reset CPU and run init script.

- ]]> -
- -
-
- - - - browsemem.tcl - Memory - browsemem.tcl - Browse / Edit Memory - browsemem.tcl - - - - - - - - - - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_type [formfetch form_type] - set form_action [formfetch form_action] - set form_value [formfetch form_value] - - if {[string compare $form_length ""]==0} { - set form_length 0 - } - if {$form_length<=0} { - set form_length 0x80 - } - if {$form_length>0x1000} { - set form_length 0x1000 - } - - if {[string compare $form_type ""]==0} { - set form_type mdw - } - - if {[string compare $form_type "mdw"]==0} { - set wordsize 4 - set modify_cmd mww - } - if {[string compare $form_type "mdh"]==0} { - set wordsize 2 - set modify_cmd mwh - } - if {[string compare $form_type "mdb"]==0} { - set wordsize 1 - set modify_cmd mwb - } - - - - - if {[string compare $form_address ""]!=0} { - if {[string compare $form_action "Previous"]==0} { - # Kludge! Work around problems parsing hex in Jim Tcl expressions - incr form_address ; set form_address [expr $form_address-1] - if {$form_address-$form_length>0} { - set form_address "0x[tohex [expr $form_address-$form_length]]" - } else { - set form_address "0x0" - } - } - if {[string compare $form_action "Next"]==0} { - # Kludge! Work around problems parsing hex in Jim Tcl expressions - incr form_address ; set form_address [expr $form_address-1] - set form_address "0x[tohex [expr $form_address+$form_length]]" - } - if {[string compare $form_action "Modify"]==0} { - append console [capture_catch "$modify_cmd $form_address $form_value"] - } - if {[string compare $form_action "Fill"]==0} { - append console [capture_catch "$modify_cmd $form_address $form_value $form_length"] - } - } - - - - -
- - - - - - - -
Address
Length">
Value  
Type - - -
- - - - -
 
 
- - - - - -
  
-
- -
-

-

Memory:

- - - if {[string compare $form_address ""]!=0} { - append console [encode [capture_catch halt]] - append buffer [encode [capture_catch "$form_type $form_address [expr $form_length]"]] - } - - - - - - - - ]]> - - Browse and edit target memory.
- Length is in bytes, maximum 4096 bytes.

-

An error message is shown when trying to browse or edit memory which cases a CPU fault.

-

CPU will be halted if required.

-

Modify - Will modify only one byte, half-word or word starting at Address.

-

Fill - Will fill the specified region with the specified value.

-

Refresh - Display the content of the specified memory area.

- ]]> - - -
-
- - - - - - downloadmem.tcl - browsemem.tcl - Download Memory Range - - - set form_address [formfetch form_address] - set form_length [formfetch form_length] - set form_action [formfetch form_action] - -
- - - - -
Address
Length
- - - - - -
 
 
- - - - -
- - if {[string compare $form_action "Download"]==0} { - append console [encode [capture_catch "reset init"]] - append console [encode [capture_catch "dump_image /tmp/dump.bin $form_address $form_length"]] - -
- -
- - } - - - - - - ]]>
- - - Note that download memory can take - a long time(potentially minutes for megabytes at low JTAG clk speeds). -

- Once the memory is downloaded a link is available on the page to download - the file to your PC. - ]]> - - - - - - - - - openocd.tcl - OpenOCD - openocd.tcl - Run Command - openocd.tcl - - - - - - - - - set form_command [formfetch form_command] - - set form_edittext "" - if {[string length $form_command]>0} { - set form_edittext [capture_catch {eval $form_command}] - } - - append buffer {

} "\n" - append buffer {Command
} - append buffer {
} - append buffer {
} - append buffer {
} - - append buffer {
} "\n" - - - - ]]> - - - Run tcl statement(s). Add "ocd_" prefix to OpenOCD commands otherwise - there will be no output, e.g. "reset init" use "ocd_reset init". -

-

Click here to download log.

-

To download log you can also use commands like "wget http://append buffer [ip]/ram/log", or - point your web browser to said address.

-

- You can also execute tcl commands using curl from your developer PC: -

- - curl --form form_command=ocd_version append buffer [ip]runtcl.tcl - - - ]]> -
-
-
- - - - - guiupload.tcl - openocd.tcl - Upload File - - - set form_filename [formfetch form_filename]; - set form_action [formfetch form_action]; - #set form_filecontent [formfetch form_filecontent]; - - append buffer {
} - append buffer
- if {[string compare $form_action "Upload"]==0} { - if {[catch {writeform form_filecontent $form_filename} result]==0} { - append buffer [encode $result] - } else { - append buffer Wrote $form_filename - } - } - - append buffer {} - append buffer {
Filename on OpenOCD machine
File to upload
} - append buffer {
 
 
} - append buffer {
} - append buffer {
} - - - - ]]>
-
- -
- - - - - targets.tcl - documentation.tcl - Target config quick start guide - - - The reset init script is crucial. It will set up e.g. MMU, chip - select registers, etc. after a reset. The init.cfg (reset init script) - is embedded into the openocd.cfg file in the sampls OpenOCD provides. -

- Writing an openocd.cfg from scratch is a non-trivial exercise, but - fortunally it only has to be done once for a target and afterwards it - rarely if ever needs to be changed. - - - ]]> - - - Quick start guide on how to configure a target. - - - - - - - - - - - - index.tcl - index.tcl - terminal.tcl - UART forwarding - - - set form_baudrate [formfetch form_baudrate] - if {[string length $form_baudrate]==0} { - set form_baudrate [ocd_uart] - set form_baudrate [string range $form_baudrate 0 [expr [string length $form_baudrate]-2]] - } - set form_action [formfetch form_action] - -

- Target baudrate: - - -

- -

- - if {[string compare $form_action "Set baudrate"]==0} { - append console [encode [ocd_uart $form_baudrate]] - } - - -

Simple UART

- This terminal window is purely for illustrative purposes. Use telnet or a terminal program - to talk to the target over TCP/IP for anything but trivial case of reading/writing a few - lines of texts in simple tests. -

- ]]> - - telnet append buffer [ip] 5555 - or connect via TCP/IP from e.g. HyperTerminal. -

- Type "help uart" in telnet for information on how to set uart speed for target. Normally - the uart speed is set from the target configuration script by adding an "uart N", where - N is the baudrate. - ]]> - - - - - - - - - + + + + + + + + index.tcl + Config Target + index.tcl + OpenOCD debugger + index.tcl + + + + + + +   + +   + + +

Target Status

+ + + + + +
+ + set form_address [formfetch form_address] + set form_action [formfetch form_action] + + if {[string compare $form_action "Halt"]==0} { + append console [encode [capture_catch "halt"]] + } + if {[string compare $form_action "Resume"]==0} { + append console [encode [capture_catch "resume"]] + } + + if {[string compare $form_action "Reset and run"]==0} { + append console [encode [capture_catch "reset run"]] + } + + if {[string compare $form_action "Power on"]==0} { + append console [encode [capture_catch "power on"]] + } + if {[string compare $form_action "Power off"]==0} { + append console [encode [capture_catch "power off"]] + } + + + append console [encode [capture_catch poll]] +
+ +
+ + + + + + +
+ +
+
+ +

+

+ ]]>
+ + Target status shows that status of the connected target.

+

Current target - selected target configuration.
+

Startup - whether or not the target script ran to completion. Note + that even if the target is disconnected, powered down or unresponsive, the + startup script will still run to completion. Startup - OK does not mean + that the target is fully operational, simply that the configuration script + did not contain syntax errors for instance. + See log for details.
+

Target power - Detects power on target.
+ If the JTAG cable is not connected, or the target has no power, then no target power will be detected.

+

Type "help power" in telnet for command to control power relay.

+ ]]>
+
+ +
+
+ + + + + + targets.tcl + documentation.tcl + Target config quick start guide + + + The reset init script is crucial. It will set up e.g. MMU, chip + select registers, etc. after a reset. The init.cfg (reset init script) + is embedded into the openocd.cfg file in the sampls OpenOCD provides. +

+ Writing an openocd.cfg from scratch is a non-trivial exercise, but + fortunally it only has to be done once for a target and afterwards it + rarely if ever needs to be changed. + + + ]]> + + + Quick start guide on how to configure a target. + + + + + + + + + + + flashinfo.tcl + Flash + flashinfo.tcl + Flash Information + flashinfo.tcl + + + + + + + + + + + Configured flash banks: +

+ + + set flash_return [ocd_flash_banks] + if {[llength $flash_return]!=0} { + append buffer [encode [flash banks]] + + set form_action [formfetch form_action] + if {[string compare $form_action "Reset CPU and probe flash"]==0} { + append console [encode [capture_catch "reset init"]] + append buffer [encode [capture_catch "flash probe 0"]] + append buffer [encode [capture_catch "flash info 0"]] + } + } else { + append buffer "No flash bank configured." + } + +

+

+ + + + foreach a [ocd_flash_banks] { + append buffer "Flash bank at [format "0x%08x size 0x%08x" $a(base) $a(size)]: " + +
+ "> + "> + + +
+
+ + } + +
+ + + ]]>
+ + Here you will find information about the flash chips that you have + in your configuration.

+

Reset CPU and probe flash - This will reset the CPU and show + you more detailed information about your flash. This includes information about + the different sectors in the flash, and the flash driver used.

+ ]]> +
+ +
+
+ + + flash.tcl + flashinfo.tcl + Program / Verify Flash + + + + set form_offset [formfetch form_offset] + set form_action [formfetch form_action] + set form_type [formfetch form_type] + + + set post "" + catch {set post $post_data} err + + if {[string compare $form_offset ""]==0} { + set form_offset 0 + } + if {[string compare $form_type ""]==0} { + set form_type "" + } + + + + set data "" + append buffer {
} + + set action_reset [expr {[string length $form_action]!=0}] + set action_flash [expr {[string compare $form_action "Flash"]==0 || [string compare $form_action "Flash and verify"]==0}] + set action_verify [expr {[string compare $form_action "Verify"]==0 || [string compare $form_action "Flash and verify"]==0}] + + if {$action_reset} { + append console [encode [capture_catch "reset init"]] + } + + + + append buffer {} + append buffer {} + append buffer "" + + + + + + + +
File
Offset
Type + +
+ + + + + +
 
 
+ + + + + +
+ +

+ + + if {$action_flash||$action_verify} { + catch {writeform form_filecontent $upload_filename} result + append console [encode $result] + } + append buffer "
" + if {$action_flash} { + append console [encode [capture_catch "halt"]] + append buffer "" + if {[catch {capture_catch {eval "flash write_image erase $upload_filename $form_offset $form_type"}} result]} { + append buffer "Flash write failed
" + append console [encode $result] + } else { + append buffer [encode $result] + append buffer "Flash write succeed
" + } + append buffer "
" + } + if {$action_verify} { + append console [encode [capture_catch "halt"]] + append buffer "" + if {[catch {capture_catch {eval "verify_image $upload_filename $form_offset $form_type"}} result]} { + append buffer "Verify failed
" + append console [encode $result] + } else { + append buffer [encode $result] + append buffer "Verify succeed
" + } + append buffer "
" + } +
+ +

+ + ]]>
+ + + Program and/or verify the flash on your target.

+

Flash - Halt CPU, automatically erase flash if required and program flash with image.

+

Flash and verify - Programs the flash and verifies the programmed flash content is correct.

+

Verify - Halt CPU and verify image in flash or RAM.

+

Offset - This value is added to the address of the image.
+ Binary images start at address 0 by default, whereas elf and ihex have addresses encoded into the image.
+ Typically 0 for elf/ihex and the address to write the image to for binary files.

+ ]]> +
+ + +
+ +
+ + + + + + production.tcl + flashinfo.tcl + Production + + + set form_action [formfetch form_action] + set form_serialnumber [formfetch form_serialnumber] + append buffer [production_info] + + +
+ + + if {[string compare $form_action "Upload firmware"]==0} { + set wrotedata [catch {writeform form_filecontent $upload_filename} result] + append buffer [encode $result] + if {$wrotedata==0} { + append buffer "
Running production procedure

" + append buffer "
Reset and init:
" + + append console [encode [capture_catch {catch "production $upload_filename $form_serialnumber"}]] + } + } + if {[string compare $form_action "Test"]==0} { + append buffer "
Running production test. Output from first 10 seconds printed below.

" + + append console [encode [capture_catch {catch production_test}]] + } + if {[string compare $form_action "Power on"]==0} { + append console [encode [capture_catch "power on"]] + } + if {[string compare $form_action "Power off"]==0} { + append console [encode [capture_catch "power off"]] + } + + + + append buffer {

Firmware file(raw binary)

} + append buffer {

Serial number

} + + + + + + +
 
 
+ + + + + +
    +
+

+ + ]]>
+ + + Upload firmware - Power cycle target, reset target and program raw binary file to flash bank 0, offset 0 and verify flash programming. Leave target powered on.

+

Test - Power up target, run 10 second target test. Output is provided via the DCC output channel.

+

Power on - Power on target.

+

Power off - Power off target.

+

Serial number - A target script can use this string in the production procedure. Type "help production" for more info.

+ ]]> +
+ + +
+ +
+ + + + + erase.tcl + erase.tcl + Erase Flash + flashinfo.tcl + + + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_action [formfetch form_action] + + if {[string compare $form_length ""]==0} { + set form_length 0x10000 + } + if {[string compare $form_address ""]==0} { + if {[catch {[first_flash_base]} result]==0} { + set form_address "0x[tohex $result]" + } + } + + + if {[string compare $form_address ""]!=0} { + if {[string compare $form_action "Erase"]==0} { + append buffer "" + append console [encode [capture_catch { + reset init + flash erase_address $form_address $form_length}]] + append buffer + } + } + + + + +
+ + + + +
Address
Length
+ + + + +
 
 
+ +
+ + +
+ + + + ]]>
+ + Note that flash programming will erase flash if required.

+

Reset and init CPU, then erase address range.

+

The length field is specified in number of bytes.

+ ]]> +
+ +
+
+ + + + run.tcl + run.tcl + Run program + flashinfo.tcl + + + +set form_address [formfetch form_address] +set form_action [formfetch form_action] + +if {[string compare $form_action "Run from address"]==0} { + append console [encode [capture_catch "halt"]] + append console [encode [capture_catch "wait_halt"]] + append console [encode [capture_catch "resume $form_address"]] +} + +if {[string compare $form_action "Halt"]==0} { + append console [encode [capture_catch "halt"]] + append console [encode [capture_catch "wait_halt"]] +} + +if {[string compare $form_action "Reset and run"]==0} { + append console [encode [capture_catch "reset run"]] +} + +if {[string compare $form_action "Reset and init"]==0} { + append console [encode [capture_catch "reset init"]] +} + +append console [encode [capture_catch poll]] + + + +
+ + + +
Address
+ + + + +
 
 
+ +
+
+ + + + ]]>
+ + Reset and run - reset CPU and let it run.

+

Halt - halt CPU.

+

Run from address - halt CPU and resume from address. Default is resume from current address.

+

Reset and init - reset CPU and run init script.

+ ]]> +
+ +
+
+ + + + browsemem.tcl + Memory + browsemem.tcl + Browse / Edit Memory + browsemem.tcl + + + + + + + + + + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_type [formfetch form_type] + set form_action [formfetch form_action] + set form_value [formfetch form_value] + + if {[string compare $form_length ""]==0} { + set form_length 0 + } + if {$form_length<=0} { + set form_length 0x80 + } + if {$form_length>0x1000} { + set form_length 0x1000 + } + + if {[string compare $form_type ""]==0} { + set form_type mdw + } + + if {[string compare $form_type "mdw"]==0} { + set wordsize 4 + set modify_cmd mww + } + if {[string compare $form_type "mdh"]==0} { + set wordsize 2 + set modify_cmd mwh + } + if {[string compare $form_type "mdb"]==0} { + set wordsize 1 + set modify_cmd mwb + } + + + + + if {[string compare $form_address ""]!=0} { + if {[string compare $form_action "Previous"]==0} { + # Kludge! Work around problems parsing hex in Jim Tcl expressions + incr form_address ; set form_address [expr $form_address-1] + if {$form_address-$form_length>0} { + set form_address "0x[tohex [expr $form_address-$form_length]]" + } else { + set form_address "0x0" + } + } + if {[string compare $form_action "Next"]==0} { + # Kludge! Work around problems parsing hex in Jim Tcl expressions + incr form_address ; set form_address [expr $form_address-1] + set form_address "0x[tohex [expr $form_address+$form_length]]" + } + if {[string compare $form_action "Modify"]==0} { + append console [capture_catch "$modify_cmd $form_address $form_value"] + } + if {[string compare $form_action "Fill"]==0} { + append console [capture_catch "$modify_cmd $form_address $form_value $form_length"] + } + } + + + + +
+ + + + + + + +
Address
Length">
Value  
Type + + +
+ + + + +
 
 
+ + + + + +
  
+
+ +
+

+

Memory:

+ + + if {[string compare $form_address ""]!=0} { + append console [encode [capture_catch halt]] + append buffer [encode [capture_catch "$form_type $form_address [expr $form_length]"]] + } + + + + + + + + ]]> + + Browse and edit target memory.
+ Length is in bytes, maximum 4096 bytes.

+

An error message is shown when trying to browse or edit memory which cases a CPU fault.

+

CPU will be halted if required.

+

Modify - Will modify only one byte, half-word or word starting at Address.

+

Fill - Will fill the specified region with the specified value.

+

Refresh - Display the content of the specified memory area.

+ ]]> + + +
+
+ + + + + + downloadmem.tcl + browsemem.tcl + Download Memory Range + + + set form_address [formfetch form_address] + set form_length [formfetch form_length] + set form_action [formfetch form_action] + +
+ + + + +
Address
Length
+ + + + + +
 
 
+ + + + +
+ + if {[string compare $form_action "Download"]==0} { + append console [encode [capture_catch "reset init"]] + append console [encode [capture_catch "dump_image /tmp/dump.bin $form_address $form_length"]] + +
+ +
+ + } + + + + + + ]]>
+ + + Note that download memory can take + a long time(potentially minutes for megabytes at low JTAG clk speeds). +

+ Once the memory is downloaded a link is available on the page to download + the file to your PC. + ]]> + + + + + + + + + openocd.tcl + OpenOCD + openocd.tcl + Run Command + openocd.tcl + + + + + + + + + set form_command [formfetch form_command] + + set form_edittext "" + if {[string length $form_command]>0} { + set form_edittext [capture_catch {eval $form_command}] + } + + append buffer {

} "\n" + append buffer {Command
} + append buffer {
} + append buffer {
} + append buffer {
} + + append buffer {
} "\n" + + + + ]]> + + + Run tcl statement(s). Add "ocd_" prefix to OpenOCD commands otherwise + there will be no output, e.g. "reset init" use "ocd_reset init". +

+

Click here to download log.

+

To download log you can also use commands like "wget http://append buffer [ip]/ram/log", or + point your web browser to said address.

+

+ You can also execute tcl commands using curl from your developer PC: +

+ + curl --form form_command=ocd_version append buffer [ip]runtcl.tcl + + + ]]> +
+
+
+ + + + + guiupload.tcl + openocd.tcl + Upload File + + + set form_filename [formfetch form_filename]; + set form_action [formfetch form_action]; + #set form_filecontent [formfetch form_filecontent]; + + append buffer {
} + append buffer
+ if {[string compare $form_action "Upload"]==0} { + if {[catch {writeform form_filecontent $form_filename} result]==0} { + append buffer [encode $result] + } else { + append buffer Wrote $form_filename + } + } + + append buffer {} + append buffer {
Filename on OpenOCD machine
File to upload
} + append buffer {
 
 
} + append buffer {
} + append buffer {
} + + + + ]]>
+
+ +
+ + + + + targets.tcl + documentation.tcl + Target config quick start guide + + + The reset init script is crucial. It will set up e.g. MMU, chip + select registers, etc. after a reset. The init.cfg (reset init script) + is embedded into the openocd.cfg file in the sampls OpenOCD provides. +

+ Writing an openocd.cfg from scratch is a non-trivial exercise, but + fortunally it only has to be done once for a target and afterwards it + rarely if ever needs to be changed. + + + ]]> + + + Quick start guide on how to configure a target. + + + + + + + + + + + + index.tcl + index.tcl + terminal.tcl + UART forwarding + + + set form_baudrate [formfetch form_baudrate] + if {[string length $form_baudrate]==0} { + set form_baudrate [ocd_uart] + set form_baudrate [string range $form_baudrate 0 [expr [string length $form_baudrate]-2]] + } + set form_action [formfetch form_action] + +

+ Target baudrate: + + +

+ +

+ + if {[string compare $form_action "Set baudrate"]==0} { + append console [encode [ocd_uart $form_baudrate]] + } + + +

Simple UART

+ This terminal window is purely for illustrative purposes. Use telnet or a terminal program + to talk to the target over TCP/IP for anything but trivial case of reading/writing a few + lines of texts in simple tests. +

+ ]]> + + telnet append buffer [ip] 5555 + or connect via TCP/IP from e.g. HyperTerminal. +

+ Type "help uart" in telnet for information on how to set uart speed for target. Normally + the uart speed is set from the target configuration script by adding an "uart N", where + N is the baudrate. + ]]> + + + + + + + + + \ No newline at end of file diff --git a/src/server/httpd/menu.xsl b/src/server/httpd/menu.xsl index 320d5e2483..7b47d9e07e 100644 --- a/src/server/httpd/menu.xsl +++ b/src/server/httpd/menu.xsl @@ -1,298 +1,298 @@ - -]> - - - - - - - - - - - - - - OpenOCD debugger - - - - - - - - set console "" - set upload_filename /ram/upload - - - -

- -
-
- append buffer [capture version] -
-
-
- - - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - -
- - - width:140px;height:38px;background-image:url('menu_cuts/v_tab_selected.png');background-repeat: no-repeat; - - - width:140px;height:38px;background-image:url('menu_cuts/v_tab.png');background-repeat: no-repeat; - - - -
- -
- -
- -
-
- - - - - - - - - - - - - - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - - - - - - } - - - - -
- - - - - - - - -
- - - width:103px;height:29px;background-image:url('menu_cuts/h_tab1_selected.png');background-repeat: no-repeat; - - - width:103px;height:29px;background-image:url('menu_cuts/h_tab1.png');background-repeat: no-repeat; - - - -
-
-
-   -
-
-

-
- -
- - - - if {$show_details==1} { - append buffer - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer ]]> - } else { - append buffer - 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;"} - append buffer ]]> - } - - - ?toggle_details=1 - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } -
-
- - if {$show_details==1} { - append buffer $console - } - - /td]]> - - if {$show_details!=1} { - append buffer {} - } - - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
- OpenOCD Manual
-
- - - - -
-
- - - - - - - - -
-   -
- -
- - - - - + +]> + + + + + + + + + + + + + + OpenOCD debugger + + + + + + + + set console "" + set upload_filename /ram/upload + + + +
+ +
+
+ append buffer [capture version] +
+
+
+ + + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + +
+ + + width:140px;height:38px;background-image:url('menu_cuts/v_tab_selected.png');background-repeat: no-repeat; + + + width:140px;height:38px;background-image:url('menu_cuts/v_tab.png');background-repeat: no-repeat; + + + +
+ +
+ +
+ +
+
+ + + + + + + + + + + + + + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + + + + + + } + + + + +
+ + + + + + + + +
+ + + width:103px;height:29px;background-image:url('menu_cuts/h_tab1_selected.png');background-repeat: no-repeat; + + + width:103px;height:29px;background-image:url('menu_cuts/h_tab1.png');background-repeat: no-repeat; + + + +
+
+
+   +
+
+

+
+ +
+ + + + if {$show_details==1} { + append buffer + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer ]]> + } else { + append buffer + 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;"} + append buffer ]]> + } + + + ?toggle_details=1 + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } +
+
+ + if {$show_details==1} { + append buffer $console + } + + /td]]> + + if {$show_details!=1} { + append buffer {} + } + + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+ OpenOCD Manual
+
+ + + + +
+
+ + + + + + + + +
+   +
+ +
+ + + +
+
diff --git a/src/server/httpd/menuweb.css b/src/server/httpd/menuweb.css index 0a812a7a9b..ac87c85ec6 100644 --- a/src/server/httpd/menuweb.css +++ b/src/server/httpd/menuweb.css @@ -1,132 +1,132 @@ -a:link -{ - font-size: 12px; - color : #024d67; - font-weight:bold; - text-decoration : none; -} - -a:visited -{ - font-size: 12px; - color : #024d67; - font-weight:bold; - text-decoration : none; -} - -a:active -{ - font-size: 12px; - color : #024d67; - font-weight:bold; - text-decoration : none; -} - -a:hover -{ - font-size: 12px; - color : #555555; - font-weight:bold; - text-decoration : none; -} - -a.openocd:link -{ - font-size: 12px; - color : #555555; - font-weight:bold; - text-decoration : none; -} - -a.openocd:visited -{ - font-size: 12px; - color : #555555; - font-weight:bold; - text-decoration : none; -} - -a.openocd:active -{ - font-size: 12px; - color : #555555; - font-weight:bold; - text-decoration : none; -} - -a.openocd:hover -{ - font-size: 12px; - color : #024d67; - font-weight:bold; - text-decoration : none; -} - -body -{ - background-color : green; - background-color : #176e8c; - font-family : Arial; - font-size: 12px; - line-height: 15px; - color : #024d67; - -} - -h1 -{ - padding: 0px; - font-size: 18px; - font-weight:bold; - text-decoration : none; - margin-bottom: 8px; -} - -td -{ - padding: 0px; - font-size: 12px; - vertical-align:top; - -} - -.textlight -{ - color: #cccccc; - padding: 0px; - font-size: 12px; - vertical-align:top; - -} - -.fontbigger -{ - font-size:14px; -} - -.textgray -{ - color: #555555; -} - -.formtext -{ - padding-top: 4px; - font-size: 14px; - padding-right:10px; -} - -input -{ - font-size: 14px; -} - -.buttonspacelarge -{ - width:20px; -} - -.buttonspacesmall -{ - width:8px; -} +a:link +{ + font-size: 12px; + color : #024d67; + font-weight:bold; + text-decoration : none; +} + +a:visited +{ + font-size: 12px; + color : #024d67; + font-weight:bold; + text-decoration : none; +} + +a:active +{ + font-size: 12px; + color : #024d67; + font-weight:bold; + text-decoration : none; +} + +a:hover +{ + font-size: 12px; + color : #555555; + font-weight:bold; + text-decoration : none; +} + +a.openocd:link +{ + font-size: 12px; + color : #555555; + font-weight:bold; + text-decoration : none; +} + +a.openocd:visited +{ + font-size: 12px; + color : #555555; + font-weight:bold; + text-decoration : none; +} + +a.openocd:active +{ + font-size: 12px; + color : #555555; + font-weight:bold; + text-decoration : none; +} + +a.openocd:hover +{ + font-size: 12px; + color : #024d67; + font-weight:bold; + text-decoration : none; +} + +body +{ + background-color : green; + background-color : #176e8c; + font-family : Arial; + font-size: 12px; + line-height: 15px; + color : #024d67; + +} + +h1 +{ + padding: 0px; + font-size: 18px; + font-weight:bold; + text-decoration : none; + margin-bottom: 8px; +} + +td +{ + padding: 0px; + font-size: 12px; + vertical-align:top; + +} + +.textlight +{ + color: #cccccc; + padding: 0px; + font-size: 12px; + vertical-align:top; + +} + +.fontbigger +{ + font-size:14px; +} + +.textgray +{ + color: #555555; +} + +.formtext +{ + padding-top: 4px; + font-size: 14px; + padding-right:10px; +} + +input +{ + font-size: 14px; +} + +.buttonspacelarge +{ + width:20px; +} + +.buttonspacesmall +{ + width:8px; +} diff --git a/src/server/httpd/openocd.tcl b/src/server/httpd/openocd.tcl index 4fed387770..8607f18560 100644 --- a/src/server/httpd/openocd.tcl +++ b/src/server/httpd/openocd.tcl @@ -1,355 +1,355 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Run Command

-
- - } - - set form_command [formfetch form_command] - - set form_edittext "" - if {[string length $form_command]>0} { - set form_edittext [capture_catch {eval $form_command}] - } - - append buffer {
} "\n" - append buffer {Command
} - append buffer {
} - append buffer {
} - append buffer {
} - - append buffer {
} "\n" - - -append buffer { - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Run tcl statement(s). Add "ocd_" prefix to OpenOCD commands otherwise - there will be no output, e.g. "reset init" use "ocd_reset init". -

-

Click here to download log.

-

To download log you can also use commands like "wget http://} -append buffer [ip] -append buffer {/ram/log", or - point your web browser to said address.

-

- You can also execute tcl commands using curl from your developer PC: -

- - curl --form form_command=ocd_version } -append buffer [ip] -append buffer {runtcl.tcl - - - -
-   -
-
- - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Run Command

+
+ + } + + set form_command [formfetch form_command] + + set form_edittext "" + if {[string length $form_command]>0} { + set form_edittext [capture_catch {eval $form_command}] + } + + append buffer {
} "\n" + append buffer {Command
} + append buffer {
} + append buffer {
} + append buffer {
} + + append buffer {
} "\n" + + +append buffer { + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Run tcl statement(s). Add "ocd_" prefix to OpenOCD commands otherwise + there will be no output, e.g. "reset init" use "ocd_reset init". +

+

Click here to download log.

+

To download log you can also use commands like "wget http://} +append buffer [ip] +append buffer {/ram/log", or + point your web browser to said address.

+

+ You can also execute tcl commands using curl from your developer PC: +

+ + curl --form form_command=ocd_version } +append buffer [ip] +append buffer {runtcl.tcl + + + +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/preconfig.tcl b/src/server/httpd/preconfig.tcl index eaa184217a..8308deb411 100644 --- a/src/server/httpd/preconfig.tcl +++ b/src/server/httpd/preconfig.tcl @@ -1,429 +1,429 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Select Preconfigured Target

-
- - } - - - set form_target [formfetch form_target] - set form_action [formfetch form_action] - - append buffer {
} - if {[string compare $form_action "Select and reload"]==0} { - capture_catch "trunc /config/settings/openocd.cfg" - capture_catch "append_file /config/settings/openocd.cfg script target/$form_target" - reboot - } - - set form_target [load_target] - - set files [ls /rom/target] - set files [lunion $files [ls /config/settings/target]] - set files [lsort $files] - - if {[string compare $form_action "Select and reload"]!=0} { - -append buffer { - - - - -
- -   - - -      - Edit target configuration -
- } - - } else { - append buffer "Reloading setting(ca. 30 seconds)..." - } - -append buffer { - -
- -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
- -

ZY1000 comes with complete configurations for various targets.

-

These predefined configurations include reset init scripts and flash configuration.

-

Select and reload - Select configuration and reboot ZY1000 unit.

- -
-   -
-
- - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Select Preconfigured Target

+
+ + } + + + set form_target [formfetch form_target] + set form_action [formfetch form_action] + + append buffer {
} + if {[string compare $form_action "Select and reload"]==0} { + capture_catch "trunc /config/settings/openocd.cfg" + capture_catch "append_file /config/settings/openocd.cfg script target/$form_target" + reboot + } + + set form_target [load_target] + + set files [ls /rom/target] + set files [lunion $files [ls /config/settings/target]] + set files [lsort $files] + + if {[string compare $form_action "Select and reload"]!=0} { + +append buffer { + + + + +
+ +   + + +      + Edit target configuration +
+ } + + } else { + append buffer "Reloading setting(ca. 30 seconds)..." + } + +append buffer { + +
+ +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+ +

ZY1000 comes with complete configurations for various targets.

+

These predefined configurations include reset init scripts and flash configuration.

+

Select and reload - Select configuration and reboot ZY1000 unit.

+ +
+   +
+
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/production.tcl b/src/server/httpd/production.tcl index 8172800b3a..7c5ba6357a 100644 --- a/src/server/httpd/production.tcl +++ b/src/server/httpd/production.tcl @@ -1,392 +1,392 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
-
-Info -
-
-
-Erase -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Production

-
- } - - set form_action [formfetch form_action] - set form_serialnumber [formfetch form_serialnumber] - append buffer [production_info] - -append buffer { - -
- - } - - if {[string compare $form_action "Upload firmware"]==0} { - set wrotedata [catch {writeform form_filecontent $upload_filename} result] - append buffer [encode $result] - if {$wrotedata==0} { - append buffer "
Running production procedure

" - append buffer "
Reset and init:
" - - append console [encode [capture_catch {catch "production $upload_filename $form_serialnumber"}]] - } - } - if {[string compare $form_action "Test"]==0} { - append buffer "
Running production test. Output from first 10 seconds printed below.

" - - append console [encode [capture_catch {catch production_test}]] - } - if {[string compare $form_action "Power on"]==0} { - append console [encode [capture_catch "power on"]] - } - if {[string compare $form_action "Power off"]==0} { - append console [encode [capture_catch "power off"]] - } - -append buffer { - - } - - append buffer {

Firmware file(raw binary)

} - append buffer {

Serial number

} - -append buffer { - - - - - -
 
 
- - - - - -
    -
-

- -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- - The target script can implement the "production", "production_info" and "production_test" tcl proc's. These procedures - are used on this page. There are default implementations that do nothing. - -

Upload firmware - Power cycle target, reset target and program raw binary file to flash bank 0, offset 0 and verify flash programming. Leave target powered on.

-

Test - Power up target, run 10 second target test. Output is provided via the DCC output channel.

-

Power on - Power on target.

-

Power off - Power off target.

-

Serial number - A target script can use this string in the production procedure. Type "help production" for more info.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+
+Info +
+
+
+Erase +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Production

+
+ } + + set form_action [formfetch form_action] + set form_serialnumber [formfetch form_serialnumber] + append buffer [production_info] + +append buffer { + +
+ + } + + if {[string compare $form_action "Upload firmware"]==0} { + set wrotedata [catch {writeform form_filecontent $upload_filename} result] + append buffer [encode $result] + if {$wrotedata==0} { + append buffer "
Running production procedure

" + append buffer "
Reset and init:
" + + append console [encode [capture_catch {catch "production $upload_filename $form_serialnumber"}]] + } + } + if {[string compare $form_action "Test"]==0} { + append buffer "
Running production test. Output from first 10 seconds printed below.

" + + append console [encode [capture_catch {catch production_test}]] + } + if {[string compare $form_action "Power on"]==0} { + append console [encode [capture_catch "power on"]] + } + if {[string compare $form_action "Power off"]==0} { + append console [encode [capture_catch "power off"]] + } + +append buffer { + + } + + append buffer {

Firmware file(raw binary)

} + append buffer {

Serial number

} + +append buffer { + + + + + +
 
 
+ + + + + +
    +
+

+ +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ + The target script can implement the "production", "production_info" and "production_test" tcl proc's. These procedures + are used on this page. There are default implementations that do nothing. + +

Upload firmware - Power cycle target, reset target and program raw binary file to flash bank 0, offset 0 and verify flash programming. Leave target powered on.

+

Test - Power up target, run 10 second target test. Output is provided via the DCC output channel.

+

Power on - Power on target.

+

Power off - Power off target.

+

Serial number - A target script can use this string in the production procedure. Type "help production" for more info.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/readme.txt b/src/server/httpd/readme.txt index 960c0fe13e..bade32cbac 100644 --- a/src/server/httpd/readme.txt +++ b/src/server/httpd/readme.txt @@ -1,24 +1,24 @@ -work in progress... stay tuned.... - - -1. To build .tcl pages. This will convert menu.xml and menu.xsl into -lots of .html pages w/embedded tcl, which are then inverted into -tcl with embedded html. - -sh build.sh - -xalan.jar can be gotten from apache.org. - - -2. libmicrohttpd is a bit tricky to build under Cygwin: - -https://gnunet.org/mantis/view.php?id=1440 - -3. To test: - -../openocd/configure --enable-httpd --enable-dummy --enable-ioutil -make -make install -openocd -f httpd/httpd.tcl -c "interface dummy" -f target/at91eb40a.cfg - -4. Point browser to: http://localhost:8888 +work in progress... stay tuned.... + + +1. To build .tcl pages. This will convert menu.xml and menu.xsl into +lots of .html pages w/embedded tcl, which are then inverted into +tcl with embedded html. + +sh build.sh + +xalan.jar can be gotten from apache.org. + + +2. libmicrohttpd is a bit tricky to build under Cygwin: + +https://gnunet.org/mantis/view.php?id=1440 + +3. To test: + +../openocd/configure --enable-httpd --enable-dummy --enable-ioutil +make +make install +openocd -f httpd/httpd.tcl -c "interface dummy" -f target/at91eb40a.cfg + +4. Point browser to: http://localhost:8888 diff --git a/src/server/httpd/reload.tcl b/src/server/httpd/reload.tcl index 07c9198381..5d68ce325e 100644 --- a/src/server/httpd/reload.tcl +++ b/src/server/httpd/reload.tcl @@ -1,322 +1,322 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - -
-
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Reload Config Scripts

-
- - } - - set form_action [formfetch form_action] - - if {[string compare $form_action "Reload"]==0} { - append buffer "Reloading Config Scripts...

" - reboot - } - -append buffer { -

- -
- -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- Restart ZY1000 to reload selected target config script. -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + +
+
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Reload Config Scripts

+
+ + } + + set form_action [formfetch form_action] + + if {[string compare $form_action "Reload"]==0} { + append buffer "Reloading Config Scripts...

" + reboot + } + +append buffer { +

+ +
+ +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ Restart ZY1000 to reload selected target config script. +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/run.tcl b/src/server/httpd/run.tcl index 1ce781321d..689b1608ef 100644 --- a/src/server/httpd/run.tcl +++ b/src/server/httpd/run.tcl @@ -1,382 +1,382 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - -
-
-
-Info -
-
-
-Erase -
-
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Run program

-
- - - -} - - -set form_address [formfetch form_address] -set form_action [formfetch form_action] - -if {[string compare $form_action "Run from address"]==0} { - append console [encode [capture_catch "halt"]] - append console [encode [capture_catch "wait_halt"]] - append console [encode [capture_catch "resume $form_address"]] -} - -if {[string compare $form_action "Halt"]==0} { - append console [encode [capture_catch "halt"]] - append console [encode [capture_catch "wait_halt"]] -} - -if {[string compare $form_action "Reset and run"]==0} { - append console [encode [capture_catch "reset run"]] -} - -if {[string compare $form_action "Reset and init"]==0} { - append console [encode [capture_catch "reset init"]] -} - -append console [encode [capture_catch poll]] - - -append buffer { - -
- - - -
Address
- - - - -
 
 
- -
-
- - - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- -

Reset and run - reset CPU and let it run.

-

Halt - halt CPU.

-

Run from address - halt CPU and resume from address. Default is resume from current address.

-

Reset and init - reset CPU and run init script.

- -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + +
+
+
+Info +
+
+
+Erase +
+
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Run program

+
+ + + +} + + +set form_address [formfetch form_address] +set form_action [formfetch form_action] + +if {[string compare $form_action "Run from address"]==0} { + append console [encode [capture_catch "halt"]] + append console [encode [capture_catch "wait_halt"]] + append console [encode [capture_catch "resume $form_address"]] +} + +if {[string compare $form_action "Halt"]==0} { + append console [encode [capture_catch "halt"]] + append console [encode [capture_catch "wait_halt"]] +} + +if {[string compare $form_action "Reset and run"]==0} { + append console [encode [capture_catch "reset run"]] +} + +if {[string compare $form_action "Reset and init"]==0} { + append console [encode [capture_catch "reset init"]] +} + +append console [encode [capture_catch poll]] + + +append buffer { + +
+ + + +
Address
+ + + + +
 
 
+ +
+
+ + + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ +

Reset and run - reset CPU and let it run.

+

Halt - halt CPU.

+

Run from address - halt CPU and resume from address. Default is resume from current address.

+

Reset and init - reset CPU and run init script.

+ +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/support.tcl b/src/server/httpd/support.tcl index cf7a2b4464..31502197ae 100644 --- a/src/server/httpd/support.tcl +++ b/src/server/httpd/support.tcl @@ -1,431 +1,431 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture zy1000_version] -append buffer { -
-
-
- - - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- - - -
-
-
-   -
-
-

Submit Support Request

-
- Before contacting Zylin, please submit a support request with relevant information. - } - - - set form_config [load_config "target/[load_target]"] - set support_id [string range [rand] 0 7] - set form_log "" - append form_log "Version: [capture "zy1000_version zy1000"]" - append form_log "OpenOCD version: [capture "zy1000_version openocd"]" - append form_log "Version date: [capture "zy1000_version date"]" - append form_log [log] - -append buffer { - -
- - - - - - - - - - -
Support ID} -append buffer $support_id -append buffer {
Contact person
Phone
email
MAC address
-

- Summary: -

- -

- Description: -

- - -

- Log:

- -

- Config:

- -

-

-

-

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - append buffer {td style="background-image:url('/rom/menu_cuts/h_tab_free.png');width:110px;height:29px;background-repeat: no-repeat;background-position:top left;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
- - Before contacting Zylin with questions, please fill in and submit this form - and allow us time to review the information and answer by email if possible. -

- Note that you can see precisely what information is submitted to Zylin in the - form: the log and your config files. - -

-   -
-
- - - - Zylin AS, Auglendsdalen 78, N-4017 Stavanger, Norway - www.zylin.com -
- - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture zy1000_version] +append buffer { +
+
+
+ + + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ + + +
+
+
+   +
+
+

Submit Support Request

+
+ Before contacting Zylin, please submit a support request with relevant information. + } + + + set form_config [load_config "target/[load_target]"] + set support_id [string range [rand] 0 7] + set form_log "" + append form_log "Version: [capture "zy1000_version zy1000"]" + append form_log "OpenOCD version: [capture "zy1000_version openocd"]" + append form_log "Version date: [capture "zy1000_version date"]" + append form_log [log] + +append buffer { + +
+ + + + + + + + + + +
Support ID} +append buffer $support_id +append buffer {
Contact person
Phone
email
MAC address
+

+ Summary: +

+ +

+ Description: +

+ + +

+ Log:

+ +

+ Config:

+ +

+

+

+

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + append buffer {td style="background-image:url('/rom/menu_cuts/h_tab_free.png');width:110px;height:29px;background-repeat: no-repeat;background-position:top left;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+ + Before contacting Zylin with questions, please fill in and submit this form + and allow us time to review the information and answer by email if possible. +

+ Note that you can see precisely what information is submitted to Zylin in the + form: the log and your config files. + +

+   +
+
+ + + + Zylin AS, Auglendsdalen 78, N-4017 Stavanger, Norway - www.zylin.com +
+ + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/targets.tcl b/src/server/httpd/targets.tcl index f56746f8ef..4a12dde549 100644 --- a/src/server/httpd/targets.tcl +++ b/src/server/httpd/targets.tcl @@ -1,560 +1,560 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - -
-
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Target config quick start guide

-
- - A target needs an openocd.cfg file. This config file sets up - the CPU, flash and reset init script. Either OpenOCD ships with an - openocd.cfg file for your target or you need to take an existing - config file and modify it for your needs. -

- The reset init script is crucial. It will set up e.g. MMU, chip - select registers, etc. after a reset. The init.cfg (reset init script) - is embedded into the openocd.cfg file in the sampls OpenOCD provides. -

- Writing an openocd.cfg from scratch is a non-trivial exercise, but - fortunally it only has to be done once for a target and afterwards it - rarely if ever needs to be changed. - - -

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- - Quick start guide on how to configure a target. -
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - -
-
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

Target config quick start guide

-
- - A target needs an openocd.cfg file. This config file sets up - the CPU, flash and reset init script. Either OpenOCD ships with an - openocd.cfg file for your target or you need to take an existing - config file and modify it for your needs. -

- The reset init script is crucial. It will set up e.g. MMU, chip - select registers, etc. after a reset. The init.cfg (reset init script) - is embedded into the openocd.cfg file in the sampls OpenOCD provides. -

- Writing an openocd.cfg from scratch is a non-trivial exercise, but - fortunally it only has to be done once for a target and afterwards it - rarely if ever needs to be changed. - - -

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- - Quick start guide on how to configure a target. -
-   -
-
- - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + +
+
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Target config quick start guide

+
+ + A target needs an openocd.cfg file. This config file sets up + the CPU, flash and reset init script. Either OpenOCD ships with an + openocd.cfg file for your target or you need to take an existing + config file and modify it for your needs. +

+ The reset init script is crucial. It will set up e.g. MMU, chip + select registers, etc. after a reset. The init.cfg (reset init script) + is embedded into the openocd.cfg file in the sampls OpenOCD provides. +

+ Writing an openocd.cfg from scratch is a non-trivial exercise, but + fortunally it only has to be done once for a target and afterwards it + rarely if ever needs to be changed. + + +

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ + Quick start guide on how to configure a target. +
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + +
+
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

Target config quick start guide

+
+ + A target needs an openocd.cfg file. This config file sets up + the CPU, flash and reset init script. Either OpenOCD ships with an + openocd.cfg file for your target or you need to take an existing + config file and modify it for your needs. +

+ The reset init script is crucial. It will set up e.g. MMU, chip + select registers, etc. after a reset. The init.cfg (reset init script) + is embedded into the openocd.cfg file in the sampls OpenOCD provides. +

+ Writing an openocd.cfg from scratch is a non-trivial exercise, but + fortunally it only has to be done once for a target and afterwards it + rarely if ever needs to be changed. + + +

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ + Quick start guide on how to configure a target. +
+   +
+
+ + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/terminal.tcl b/src/server/httpd/terminal.tcl index 5032e124fe..c6cc05f62a 100644 --- a/src/server/httpd/terminal.tcl +++ b/src/server/httpd/terminal.tcl @@ -1,364 +1,364 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -OpenOCD debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
- -
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - -
-
-   -
-
- - - - - - - - - - - - -
-
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- -
-
-
-   -
-
-

UART forwarding

-
- } - - set form_baudrate [formfetch form_baudrate] - if {[string length $form_baudrate]==0} { - set form_baudrate [ocd_uart] - set form_baudrate [string range $form_baudrate 0 [expr [string length $form_baudrate]-2]] - } - set form_action [formfetch form_action] - -append buffer { -
- Target baudrate: - - -

- -

- } - - if {[string compare $form_action "Set baudrate"]==0} { - append console [encode [ocd_uart $form_baudrate]] - } - -append buffer { - -

Simple UART

- This terminal window is purely for illustrative purposes. Use telnet or a terminal program - to talk to the target over TCP/IP for anything but trivial case of reading/writing a few - lines of texts in simple tests. -

-

- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-OpenOCD Manual -
-
-
- -
- - -
-
-
- - Serial port data to target is forwarded(both directions) in the simple terminal window - to the left. Alternatively you can telnet } -append buffer [ip] -append buffer { 5555 - or connect via TCP/IP from e.g. HyperTerminal. -

- Type "help uart" in telnet for information on how to set uart speed for target. Normally - the uart speed is set from the target configuration script by adding an "uart N", where - N is the baudrate. - -

-   -
-
- - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +OpenOCD debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+ +
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + +
+
+   +
+
+ + + + + + + + + + + + +
+
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ +
+
+
+   +
+
+

UART forwarding

+
+ } + + set form_baudrate [formfetch form_baudrate] + if {[string length $form_baudrate]==0} { + set form_baudrate [ocd_uart] + set form_baudrate [string range $form_baudrate 0 [expr [string length $form_baudrate]-2]] + } + set form_action [formfetch form_action] + +append buffer { +
+ Target baudrate: + + +

+ +

+ } + + if {[string compare $form_action "Set baudrate"]==0} { + append console [encode [ocd_uart $form_baudrate]] + } + +append buffer { + +

Simple UART

+ This terminal window is purely for illustrative purposes. Use telnet or a terminal program + to talk to the target over TCP/IP for anything but trivial case of reading/writing a few + lines of texts in simple tests. +

+

+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+OpenOCD Manual +
+
+
+ +
+ + +
+
+
+ + Serial port data to target is forwarded(both directions) in the simple terminal window + to the left. Alternatively you can telnet } +append buffer [ip] +append buffer { 5555 + or connect via TCP/IP from e.g. HyperTerminal. +

+ Type "help uart" in telnet for information on how to set uart speed for target. Normally + the uart speed is set from the target configuration script by adding an "uart N", where + N is the baudrate. + +

+   +
+
+ + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + diff --git a/src/server/httpd/upgrade.tcl b/src/server/httpd/upgrade.tcl index c09cc8c184..11a73d3ef4 100644 --- a/src/server/httpd/upgrade.tcl +++ b/src/server/httpd/upgrade.tcl @@ -1,418 +1,418 @@ -# converted to .tcl by html2tcl.tcl -set buffer "" -append buffer { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -Zylin ZY1000 JTAG debugger - - - -} - - set console "" - set upload_filename /ram/upload - -append buffer { - -
-
- - - -
-
-
-} -append buffer [capture version] -append buffer { -
-
-
- - - - - - - - - - -
-
-   -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- -
- -
- -
- -
- -
-
-
-
-
- - - - - - - - - - - - - -} - - - set toggle_details [formfetch toggle_details] - if {[string length $toggle_details]==0} { - set toggle_details 0 - } - set show_details [load_var show_details] - if {[string length $show_details]==0} { - set show_details 0 - } - if {$toggle_details==1} { - set show_details [expr 1-$show_details] - save_var show_details $show_details - } - - if {[string length $console]!=0} { - -append buffer { - - - -} - - } - -append buffer { - - - -
- - - - - - - - -
- - -
-Flash -
-
-
-Memory -
-
- - - -
-
-
-   -
-
-

Upgrade ZY1000 Firmware

-
- - } - - set form_action [formfetch form_action]; - set form_filecontent [formfetch form_filecontent]; - - append buffer {
} - if {[string compare $form_action "Upload"]==0} { - - if [string match ZylinPhiFirmware* $form_filecontent]==1 { - set form_filename /config/firmware.phi - puts "Writing firmware to $form_filename" - set fp [aio.open $form_filename w]; - $fp puts -nonewline $form_filecontent - $fp close - puts "Done writing firmware to $form_filename" - append buffer "
Upgraded Zylin JTAG, rebooting (wait ca. 30 seconds)...

" - reboot - } else { - append buffer "
Not a valid Zylin JTAG firmware file.
" - } - } elseif {[string compare $form_action "Restore factory settings"]==0} { - proc rmdir { dir } { - set entries {} - catch {set entries [ls $dir]} err - foreach { entry } $entries { - rmdir $dir/$entry - rm $dir/$entry - } - } - rmdir /config/settings - reboot - append buffer "Restoring factory settings (wait ca. 30 seconds)...
" - } else { - append buffer {
Upgrade Zylin JTAG firmware + reboot.

} - append buffer {
} - append buffer {
 
 
} - append buffer {
} - append buffer {
} - append buffer {

} - } - -append buffer { - -
- - -} - - if {$show_details==1} { - append buffer < - append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} - append buffer > - } else { - append buffer < - 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;"} - append buffer > - } - -append buffer { - -} - - if {$show_details==1} { - append buffer "Hide details" - append buffer
- } else { - append buffer {
} - append buffer "Show details" - append buffer {
} - } - -append buffer { -
-} - - if {$show_details==1} { - append buffer $console - } - -append buffer {} - - if {$show_details!=1} { - append buffer {} - } - -append buffer { - -
   
-
-
-   -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - -
-
- Documentation -
-
-   - -
-
-Quick Start Manual -
-OpenOCD Manual -
-Contact Zylin AS -
-
- -
- - -
-
-
- - Upload new firmware file to ZY1000, verify that it is a valid ZY1000 firmware - file, and upgrade flash. -

- Restore factory settings restores all factory settings except the TCP/IP settings. -

- The current version of the firmware is visible at the top of the web page. -

- ZY1000 firmware can also be upgraded using serial port YModem upload. -

- Check for new firmware at http://www.zylin.com/zy1000.html - -

-   -
-
- - -
- - - - - - - - - - - - - - - - - - - - - - -} - -start_chunked "html" -write_chunked $buffer -end_chunked - +# converted to .tcl by html2tcl.tcl +set buffer "" +append buffer { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Zylin ZY1000 JTAG debugger + + + +} + + set console "" + set upload_filename /ram/upload + +append buffer { + +
+
+ + + +
+
+
+} +append buffer [capture version] +append buffer { +
+
+
+ + + + + + + + + + +
+
+   +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ +
+ +
+ +
+
+
+
+
+ + + + + + + + + + + + + +} + + + set toggle_details [formfetch toggle_details] + if {[string length $toggle_details]==0} { + set toggle_details 0 + } + set show_details [load_var show_details] + if {[string length $show_details]==0} { + set show_details 0 + } + if {$toggle_details==1} { + set show_details [expr 1-$show_details] + save_var show_details $show_details + } + + if {[string length $console]!=0} { + +append buffer { + + + +} + + } + +append buffer { + + + +
+ + + + + + + + +
+ + +
+Flash +
+
+
+Memory +
+
+ + + +
+
+
+   +
+
+

Upgrade ZY1000 Firmware

+
+ + } + + set form_action [formfetch form_action]; + set form_filecontent [formfetch form_filecontent]; + + append buffer {
} + if {[string compare $form_action "Upload"]==0} { + + if [string match ZylinPhiFirmware* $form_filecontent]==1 { + set form_filename /config/firmware.phi + puts "Writing firmware to $form_filename" + set fp [aio.open $form_filename w]; + $fp puts -nonewline $form_filecontent + $fp close + puts "Done writing firmware to $form_filename" + append buffer "
Upgraded Zylin JTAG, rebooting (wait ca. 30 seconds)...

" + reboot + } else { + append buffer "
Not a valid Zylin JTAG firmware file.
" + } + } elseif {[string compare $form_action "Restore factory settings"]==0} { + proc rmdir { dir } { + set entries {} + catch {set entries [ls $dir]} err + foreach { entry } $entries { + rmdir $dir/$entry + rm $dir/$entry + } + } + rmdir /config/settings + reboot + append buffer "Restoring factory settings (wait ca. 30 seconds)...
" + } else { + append buffer {
Upgrade Zylin JTAG firmware + reboot.

} + append buffer {
} + append buffer {
 
 
} + append buffer {
} + append buffer {
} + append buffer {

} + } + +append buffer { + +
+ + +} + + if {$show_details==1} { + append buffer < + append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} + append buffer > + } else { + append buffer < + 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;"} + append buffer > + } + +append buffer { + +} + + if {$show_details==1} { + append buffer "Hide details" + append buffer
+ } else { + append buffer {
} + append buffer "Show details" + append buffer {
} + } + +append buffer { +
+} + + if {$show_details==1} { + append buffer $console + } + +append buffer {} + + if {$show_details!=1} { + append buffer {} + } + +append buffer { + +
   
+
+
+   +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
+
+ Documentation +
+
+   + +
+
+Quick Start Manual +
+OpenOCD Manual +
+Contact Zylin AS +
+
+ +
+ + +
+
+
+ + Upload new firmware file to ZY1000, verify that it is a valid ZY1000 firmware + file, and upgrade flash. +

+ Restore factory settings restores all factory settings except the TCP/IP settings. +

+ The current version of the firmware is visible at the top of the web page. +

+ ZY1000 firmware can also be upgraded using serial port YModem upload. +

+ Check for new firmware at http://www.zylin.com/zy1000.html + +

+   +
+
+ + +
+ + + + + + + + + + + + + + + + + + + + + + +} + +start_chunked "html" +write_chunked $buffer +end_chunked + -- 2.30.2