From fdae51287cf55a039f3401ed92151dbf518e4e7f Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C3=98yvind=20Harboe?= Date: Thu, 11 Nov 2010 08:15:49 +0100 Subject: [PATCH] httpd: retire this server MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit this never panned out and there are enough mistakes in the code that probably nobody used this. Use the tcl server and implement a standalone http app instead works fine. Signed-off-by: Øyvind Harboe --- README | 2 - configure.in | 5 - doc/manual/server.txt | 14 - src/Makefile.am | 4 - src/openocd.c | 6 - src/server/Makefile.am | 24 +- src/server/httpd.c | 506 --------- src/server/httpd.h | 28 - src/server/httpd/Stylizer.class | Bin 4493 -> 0 bytes src/server/httpd/Stylizer.java | 114 -- src/server/httpd/browsemem.tcl | 454 -------- src/server/httpd/build.sh | 5 - src/server/httpd/downloadmem.tcl | 366 ------- src/server/httpd/editconfigs.tcl | 462 --------- src/server/httpd/editfile.tcl | 436 -------- src/server/httpd/erase.tcl | 387 ------- src/server/httpd/flash.tcl | 459 --------- src/server/httpd/flashinfo.tcl | 382 ------- src/server/httpd/guiupload.tcl | 336 ------ src/server/httpd/html2tcl.sh | 128 --- src/server/httpd/httpd.tcl | 100 -- src/server/httpd/index.tcl | 376 ------- src/server/httpd/log.tcl | 343 ------ src/server/httpd/menu.xml | 973 ------------------ src/server/httpd/menu.xsl | 298 ------ src/server/httpd/menu_cuts/center_bottom.png | Bin 309 -> 0 bytes src/server/httpd/menu_cuts/center_top.png | Bin 307 -> 0 bytes src/server/httpd/menu_cuts/h_tab1.png | Bin 364 -> 0 bytes .../httpd/menu_cuts/h_tab1_selected.png | Bin 310 -> 0 bytes src/server/httpd/menu_cuts/h_tab2.png | Bin 349 -> 0 bytes .../httpd/menu_cuts/h_tab2_selected.png | Bin 330 -> 0 bytes src/server/httpd/menu_cuts/h_tab_free.png | Bin 454 -> 0 bytes src/server/httpd/menu_cuts/logo_bottom.png | Bin 960 -> 0 bytes src/server/httpd/menu_cuts/logo_top.png | Bin 3082 -> 0 bytes src/server/httpd/menu_cuts/right_bottom.png | Bin 351 -> 0 bytes src/server/httpd/menu_cuts/right_top.png | Bin 281 -> 0 bytes .../httpd/menu_cuts/right_top_small.png | Bin 265 -> 0 bytes src/server/httpd/menu_cuts/top_right.png | Bin 352 -> 0 bytes src/server/httpd/menu_cuts/v_1.png | Bin 305 -> 0 bytes src/server/httpd/menu_cuts/v_2_tile.png | Bin 169 -> 0 bytes src/server/httpd/menu_cuts/v_3.png | Bin 2289 -> 0 bytes src/server/httpd/menu_cuts/v_tab.png | Bin 390 -> 0 bytes src/server/httpd/menu_cuts/v_tab_selected.png | Bin 357 -> 0 bytes src/server/httpd/menuweb.css | 132 --- src/server/httpd/openocd.tcl | 355 ------- src/server/httpd/preconfig.tcl | 429 -------- src/server/httpd/production.tcl | 392 ------- src/server/httpd/readme.txt | 24 - src/server/httpd/reload.tcl | 322 ------ src/server/httpd/run.tcl | 382 ------- src/server/httpd/support.tcl | 431 -------- src/server/httpd/targets.tcl | 560 ---------- src/server/httpd/terminal.tcl | 364 ------- src/server/httpd/upgrade.tcl | 418 -------- src/server/httpd_stubs.c | 33 - src/server/server.h | 4 +- 56 files changed, 3 insertions(+), 10051 deletions(-) delete mode 100644 src/server/httpd.c delete mode 100644 src/server/httpd.h delete mode 100755 src/server/httpd/Stylizer.class delete mode 100755 src/server/httpd/Stylizer.java delete mode 100644 src/server/httpd/browsemem.tcl delete mode 100755 src/server/httpd/build.sh delete mode 100644 src/server/httpd/downloadmem.tcl delete mode 100644 src/server/httpd/editconfigs.tcl delete mode 100644 src/server/httpd/editfile.tcl delete mode 100644 src/server/httpd/erase.tcl delete mode 100644 src/server/httpd/flash.tcl delete mode 100644 src/server/httpd/flashinfo.tcl delete mode 100644 src/server/httpd/guiupload.tcl delete mode 100755 src/server/httpd/html2tcl.sh delete mode 100644 src/server/httpd/httpd.tcl delete mode 100644 src/server/httpd/index.tcl delete mode 100644 src/server/httpd/log.tcl delete mode 100644 src/server/httpd/menu.xml delete mode 100644 src/server/httpd/menu.xsl delete mode 100644 src/server/httpd/menu_cuts/center_bottom.png delete mode 100644 src/server/httpd/menu_cuts/center_top.png delete mode 100644 src/server/httpd/menu_cuts/h_tab1.png delete mode 100644 src/server/httpd/menu_cuts/h_tab1_selected.png delete mode 100644 src/server/httpd/menu_cuts/h_tab2.png delete mode 100644 src/server/httpd/menu_cuts/h_tab2_selected.png delete mode 100644 src/server/httpd/menu_cuts/h_tab_free.png delete mode 100644 src/server/httpd/menu_cuts/logo_bottom.png delete mode 100644 src/server/httpd/menu_cuts/logo_top.png delete mode 100644 src/server/httpd/menu_cuts/right_bottom.png delete mode 100644 src/server/httpd/menu_cuts/right_top.png delete mode 100644 src/server/httpd/menu_cuts/right_top_small.png delete mode 100644 src/server/httpd/menu_cuts/top_right.png delete mode 100644 src/server/httpd/menu_cuts/v_1.png delete mode 100644 src/server/httpd/menu_cuts/v_2_tile.png delete mode 100644 src/server/httpd/menu_cuts/v_3.png delete mode 100644 src/server/httpd/menu_cuts/v_tab.png delete mode 100644 src/server/httpd/menu_cuts/v_tab_selected.png delete mode 100644 src/server/httpd/menuweb.css delete mode 100644 src/server/httpd/openocd.tcl delete mode 100644 src/server/httpd/preconfig.tcl delete mode 100644 src/server/httpd/production.tcl delete mode 100644 src/server/httpd/readme.txt delete mode 100644 src/server/httpd/reload.tcl delete mode 100644 src/server/httpd/run.tcl delete mode 100644 src/server/httpd/support.tcl delete mode 100644 src/server/httpd/targets.tcl delete mode 100644 src/server/httpd/terminal.tcl delete mode 100644 src/server/httpd/upgrade.tcl delete mode 100644 src/server/httpd_stubs.c diff --git a/README b/README index a683476c..fd0bd33d 100644 --- a/README +++ b/README @@ -255,8 +255,6 @@ options may be available there: --enable-ioutil Enable ioutil functions - useful for standalone OpenOCD implementations - --enable-httpd Enable builtin httpd server - useful for standalone - OpenOCD implementations --disable-doxygen-html Disable building Doxygen manual as HTML. --enable-doxygen-pdf Enable building Doxygen manual as PDF. diff --git a/configure.in b/configure.in index a15b80a6..70dddb95 100644 --- a/configure.in +++ b/configure.in @@ -420,10 +420,6 @@ AC_ARG_ENABLE(ioutil, AS_HELP_STRING([--enable-ioutil], [Enable ioutil functions - useful for standalone OpenOCD implementations]), [build_ioutil=$enableval], [build_ioutil=no]) -AC_ARG_ENABLE(httpd, - AS_HELP_STRING([--enable-httpd], [Enable builtin httpd server - useful for standalone OpenOCD implementations]), - [build_httpd=$enableval], [build_httpd=no]) - case "${host_cpu}" in arm*) AC_ARG_ENABLE(ep93xx, @@ -1039,7 +1035,6 @@ AM_CONDITIONAL(ECOSBOARD, test $build_ecosboard = yes) AM_CONDITIONAL(ZY1000, test $build_zy1000 = yes) AM_CONDITIONAL(ZY1000_MASTER, test $build_zy1000_master = yes) AM_CONDITIONAL(IOUTIL, test $build_ioutil = yes) -AM_CONDITIONAL(HTTPD, test $build_httpd = yes) AM_CONDITIONAL(AT91RM9200, test $build_at91rm9200 = yes) AM_CONDITIONAL(BITBANG, test $build_bitbang = yes) AM_CONDITIONAL(FT2232_LIBFTDI, test $build_ft2232_libftdi = yes) diff --git a/doc/manual/server.txt b/doc/manual/server.txt index f75f1d1d..f6a06700 100644 --- a/doc/manual/server.txt +++ b/doc/manual/server.txt @@ -309,17 +309,3 @@ This section needs to be expanded. */ -/** @page serverhttp OpenOCD HTTP Server API - - -Smoketest: - -configure --enable-httpd --enable-dummy --enable-ioutil - -openocd -s /usr/local/share/openocd -f httpd/httpd.tcl -f interface/dummy.cfg -f target/lpc2148.cfg - -Navigate to: http://localhost:8888/ - - - - */ diff --git a/src/Makefile.am b/src/Makefile.am index b54161c8..19a0ba96 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -101,10 +101,6 @@ libopenocd_la_LIBADD = \ $(top_builddir)/src/helper/libhelper.la \ $(FTDI2232LIB) $(MINGWLDADD) $(LIBUSB) -if HTTPD -libopenocd_la_LIBADD += -lmicrohttpd -endif - STARTUP_TCL_SRCS = \ $(srcdir)/helper/startup.tcl \ $(srcdir)/jtag/startup.tcl \ diff --git a/src/openocd.c b/src/openocd.c index 7347cad8..5ce01e82 100644 --- a/src/openocd.c +++ b/src/openocd.c @@ -42,7 +42,6 @@ #include #include -#include #ifdef HAVE_STRINGS_H #include @@ -337,9 +336,6 @@ int openocd_main(int argc, char *argv[]) if (ret != ERROR_OK) return EXIT_FAILURE; - if (httpd_start(cmd_ctx) != ERROR_OK) - return EXIT_FAILURE; - ret = server_init(cmd_ctx); if (ERROR_OK != ret) return EXIT_FAILURE; @@ -357,8 +353,6 @@ int openocd_main(int argc, char *argv[]) server_quit(); - httpd_stop(); - unregister_all_commands(cmd_ctx, NULL); /* free commandline interface */ diff --git a/src/server/Makefile.am b/src/server/Makefile.am index c6c946f0..ac24ebb5 100644 --- a/src/server/Makefile.am +++ b/src/server/Makefile.am @@ -8,15 +8,9 @@ noinst_LTLIBRARIES = libserver.la noinst_HEADERS = server.h telnet_server.h gdb_server.h libserver_la_SOURCES = server.c telnet_server.c gdb_server.c -if HTTPD -libserver_la_SOURCES += httpd.c -else -libserver_la_SOURCES += httpd_stubs.c if !ECOSBOARD libserver_la_SOURCES += server_stubs.c endif -endif -noinst_HEADERS += httpd.h libserver_la_CFLAGS = if IS_MINGW @@ -28,23 +22,7 @@ endif noinst_HEADERS += tcl_server.h libserver_la_SOURCES += tcl_server.c -if HTTPD -nobase_dist_pkgdata_DATA = \ - $(wildcard \ - $(srcdir)/httpd/*.tcl \ - $(srcdir)/httpd/*.css \ - $(srcdir)/httpd/menu_cuts/*.png \ - ) -endif - EXTRA_DIST = \ - startup.tcl \ - httpd/readme.txt \ - httpd/menu.xml \ - httpd/menu.xsl \ - httpd/build.sh \ - httpd/html2tcl.sh \ - httpd/Stylizer.java \ - httpd/Stylizer.class + startup.tcl MAINTAINERCLEANFILES = $(srcdir)/Makefile.in diff --git a/src/server/httpd.c b/src/server/httpd.c deleted file mode 100644 index af8c3c8b..00000000 --- a/src/server/httpd.c +++ /dev/null @@ -1,506 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2007,2008,2009 Øyvind Harboe * - * oyvind.harboe@zylin.com * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - * This program is distributed in the hope that it will be useful, * - * but WITHOUT ANY WARRANTY; without even the implied warranty of * - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * - * GNU General Public License for more details. * - * * - * You should have received a copy of the GNU General Public License * - * along with this program; if not, write to the * - * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * - ***************************************************************************/ - -/* some bits were copied from ahttpd which is under eCos license and - * copyright to FSF - */ -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#include "telnet_server.h" -#include - -#include -#include -#include - -#define PAGE_NOT_FOUND " File not found File not found" - -static pthread_mutex_t mutex; - -void openocd_sleep_prelude(void) -{ - pthread_mutex_unlock(&mutex); -} - -void openocd_sleep_postlude(void) -{ - pthread_mutex_lock(&mutex); -} - - - -int loadFile(const char *name, void **data, size_t *len); - -static const char *appendf(const char *prev, const char *format, ...) -{ - va_list ap; - va_start(ap, format); - char *string = alloc_vprintf(format, ap); - va_end(ap); - char *string2 = NULL; - - if (string != NULL) - { - string2 = alloc_printf("%s%s", (prev == NULL) ? "" : prev, string); - } - - if (prev != NULL) - { - free((void *)prev); - } - - if (string == NULL) - free(string); - - return string2; -} - -static const char *httpd_exec_cgi_tcl_error(Jim_Interp *interp) -{ - int len, i; - - const char *t = NULL; - t = appendf(t, "\n"); - - t = appendf(t, "Runtime error, file \"%s\", line %d:
", - interp->errorFileName, interp->errorLine); - t = appendf(t, " %s < br>", Jim_GetString(interp->result, NULL)); - Jim_ListLength(interp, interp->stackTrace, &len); - for (i = 0; i < len; i += 3) - { - Jim_Obj *objPtr; - const char *proc, *file, *line; - - Jim_ListIndex(interp, interp->stackTrace, i, &objPtr, JIM_NONE); - proc = Jim_GetString(objPtr, NULL); - Jim_ListIndex(interp, interp->stackTrace, i + 1, &objPtr, JIM_NONE); - file = Jim_GetString(objPtr, NULL); - Jim_ListIndex(interp, interp->stackTrace, i + 2, &objPtr, JIM_NONE); - line = Jim_GetString(objPtr, NULL); - t = appendf(t, "In procedure '%s' called at file \"%s\", line %s < br>", - proc, file, line); - } - t = appendf(t, "\n"); - - return t; -} - -static int httpd_Jim_Command_writeform(Jim_Interp *interp, int argc, - Jim_Obj * const *argv) -{ - if (argc != 3) - { - Jim_WrongNumArgs(interp, 1, argv, "method ?CMD_ARGV ...?"); - return JIM_ERR; - } - char *name = (char*) Jim_GetString(argv[1], NULL); - char *file = (char*) Jim_GetString(argv[2], NULL); - - // Find length - const char *data; - int actual; - int retcode; - const char *script = alloc_printf( - "set dummy_val $httppostdata(%s); set dummy_val", - name); - - retcode = Jim_Eval_Named(interp, script, __FILE__, __LINE__); - free((void *) script); - if (retcode != JIM_OK) - return retcode; - - data = Jim_GetString(Jim_GetResult(interp), &actual); - - FILE *f = fopen(file, "wb"); - if (NULL == f) - { - Jim_SetResultString(interp, "Could not create file", -1); - return JIM_ERR; - } - - int result = fwrite(data, 1, actual, f); - fclose(f); - - if (result != actual) - { - Jim_SetResultString(interp, "Could not write to file", -1); - return JIM_ERR; - } - return JIM_OK; -} - - -int -httpd_Jim_Command_formfetch(Jim_Interp *interp, - int argc, - Jim_Obj *const *argv) -{ - if (argc != 2) - { - Jim_WrongNumArgs(interp, 1, argv, "method ?CMD_ARGV ...?"); - return JIM_ERR; - } - - char *name = (char*)Jim_GetString(argv[1], NULL); - const char *script = alloc_printf( - "set dummy_val $httppostdata(%s); set dummy_val", - name); - int retcode = Jim_Eval_Named(interp, script, __FILE__, __LINE__); - - free((void *) script); - if (retcode != JIM_OK) - Jim_SetResult(interp, Jim_NewEmptyStringObj(interp)); - else - Jim_SetResult(interp, Jim_GetResult(interp)); - - return JIM_OK; -} - -struct httpd_request -{ - int post; - Jim_Interp *interp; - struct MHD_PostProcessor *postprocessor; - - //Jim_Obj *dict; - - int complete; /* did we receive the entire post ? */ - -}; - -static void request_completed(void *cls, struct MHD_Connection *connection, - void **con_cls, enum MHD_RequestTerminationCode toe) -{ - struct httpd_request *r = (struct httpd_request*) *con_cls; - - if (NULL == r) - return; - - if (r->postprocessor) - { - openocd_sleep_postlude(); - MHD_destroy_post_processor(r->postprocessor); - openocd_sleep_prelude(); - } - - free(r); - *con_cls = NULL; -} - -/* append to said key in dictionary */ -static void append_key(Jim_Interp *interp, - struct httpd_request *r, const char *key, - const char *data, size_t off, size_t size) -{ - Jim_Obj *keyObj = Jim_NewStringObj(interp, key, -1); - Jim_IncrRefCount(keyObj); - Jim_Obj *value = NULL; - - Jim_Obj *dict = Jim_GetVariableStr(interp, "httppostdata", 0); - - if (dict != NULL) - { - if (Jim_DictKey(interp, dict, keyObj, &value, 0) != JIM_OK) - { - value = NULL; - } - else - { - Jim_IncrRefCount(value); - } - } - - if (value == NULL) - { - value = Jim_NewStringObj(interp, "", -1); - Jim_IncrRefCount(value); - - } - - /* create a new object we append to and insert into this location */ - Jim_Obj *newObj = Jim_NewStringObj(interp, "", -1); - Jim_IncrRefCount(newObj); - Jim_AppendObj(interp, newObj, value); - Jim_AppendString(interp, newObj, data, size); - /* uhh... use name here of dictionary */ - dict = Jim_NewStringObj(interp, "httppostdata", -1); - Jim_IncrRefCount(dict); - Jim_SetDictKeysVector(interp, dict, &keyObj, 1, newObj); - Jim_DecrRefCount(interp, dict); - Jim_DecrRefCount(interp, value); - Jim_DecrRefCount(interp, newObj); - Jim_DecrRefCount(interp, keyObj); -} - -/* append data to each key */ -static int iterate_post(void *con_cls, enum MHD_ValueKind kind, - const char *key, const char *filename, const char *content_type, - const char *transfer_encoding, const char *data, uint64_t off, - size_t size) -{ - struct httpd_request *r = (struct httpd_request*) con_cls; - - append_key(r->interp, r, key, data, off, size); - - return MHD_YES; -} - -static int record_arg(void *cls, enum MHD_ValueKind kind, const char *key, - const char *value) -{ - struct httpd_request *r = (struct httpd_request*) cls; - append_key(r->interp, r, key, value, 0, strlen(value)); - return MHD_YES; -} - - -static int handle_request(Jim_Interp *interp, - struct MHD_Connection * connection, const char * url) -{ - struct MHD_Response * response; - - int ret; - const char *suffix; - suffix = strrchr(url, '.'); - if ((suffix != NULL) && (strcmp(suffix, ".tcl") == 0)) - { - printf("Run tcl %s\n", url); - - int retcode; - - const char *script = alloc_printf( - "global httpdata; source {%s}; set httpdata", url); - retcode = Jim_Eval_Named(interp, script, __FILE__, __LINE__); - free((void *) script); - - if (retcode != JIM_OK) - { - printf("Tcl failed\n"); - const char *t = httpd_exec_cgi_tcl_error(interp); - if (t == NULL) - return MHD_NO; - - response = MHD_create_response_from_data(strlen(t), (void *) t, - MHD_YES, MHD_NO); - ret = MHD_queue_response(connection, - MHD_HTTP_INTERNAL_SERVER_ERROR, response); - MHD_destroy_response(response); - return ret; - } - else - { - LOG_DEBUG("Tcl OK"); - /* FIX!!! how to handle mime types??? */ - const char *result; - int reslen; - result = Jim_GetString(Jim_GetResult(interp), &reslen); - - response = MHD_create_response_from_data(reslen, (void *) result, - MHD_NO, MHD_YES); - ret = MHD_queue_response(connection, - MHD_HTTP_INTERNAL_SERVER_ERROR, response); - MHD_destroy_response(response); - return ret; - } - } - else - { - void *data; - size_t len; - - int retval = loadFile(url, &data, &len); - if (retval != ERROR_OK) - { - printf("Did not find %s\n", url); - - response = MHD_create_response_from_data(strlen(PAGE_NOT_FOUND), - (void *) PAGE_NOT_FOUND, MHD_NO, MHD_NO); - ret = MHD_queue_response(connection, MHD_HTTP_NOT_FOUND, response); - MHD_destroy_response(response); - return ret; - } - - LOG_DEBUG("Serving %s length=%zu", url, len); - /* serve file directly */ - response = MHD_create_response_from_data(len, data, MHD_YES, MHD_NO); - /* Should we expose mimetype via tcl here or just let the browser - guess? - MHD_add_response_header(response, "Content-Type", "image/png"); - */ - - ret = MHD_queue_response(connection, MHD_HTTP_OK, response); - MHD_destroy_response(response); - - //free(data); - return ret; - } -} - -static int ahc_echo_inner(void * cls, struct MHD_Connection * connection, - const char * url, const char * method, const char * version, - const char * upload_data, size_t * upload_data_size, void ** ptr) -{ - Jim_Interp *interp = (Jim_Interp *)cls; - int post = 0; - - if (0 == strcmp(method, "POST")) - { - post = 1; - } - else if (0 == strcmp(method, "GET")) - { - } - else - { - return MHD_NO; /* unexpected method */ - } - - struct httpd_request *r; - if (*ptr == NULL) - { - /* The first time only the headers are valid, - do not respond in the first round... */ - - *ptr = malloc(sizeof(struct httpd_request)); - if (*ptr == NULL) - return MHD_NO; - memset(*ptr, 0, sizeof(struct httpd_request)); - - r = (struct httpd_request *) *ptr; - r->interp = interp; - r->post = post; - Jim_SetVariableStr(interp, "httppostdata", Jim_NewDictObj(interp, NULL, 0)); - - /* fill in url query strings in dictionary */ - MHD_get_connection_values(connection, MHD_GET_ARGUMENT_KIND, - record_arg, r); - - if (r->post) - { - r->postprocessor = MHD_create_post_processor(connection, 2048 - * 1024, &iterate_post, r); - } - - return MHD_YES; - } - - r = (struct httpd_request *) *ptr; - - if (r->post) - { - /* consume post data */ - if (*upload_data_size) - { - MHD_post_process(r->postprocessor, upload_data, *upload_data_size); - *upload_data_size = 0; - return MHD_YES; - } - else - { - } - } else - { - } - - /* hand over to request who will be using it. */ - // r->dict = NULL; - - - /* FIX!!!! we need more advanced handling of url's to avoid them - * being subverted to evil purposes - */ - - const char *httpd_dir = PKGDATADIR "/httpd"; - - if (*url=='/') - { - url++; /* skip '/' */ - } - if (!*url) - url="index.tcl"; - - const char *file_name = alloc_printf("%s/%s", httpd_dir, url); - int result = handle_request(interp, connection, file_name); - free((void *)file_name); - return result; -} - - -static int ahc_echo(void * cls, struct MHD_Connection * connection, - const char * url, const char * method, const char * version, - const char * upload_data, size_t * upload_data_size, void ** ptr) -{ - int result; - - openocd_sleep_postlude(); - - result = ahc_echo_inner(cls, connection, url, method, version, upload_data, upload_data_size, ptr); - - openocd_sleep_prelude(); - - return result; -} - -static struct MHD_Daemon * d; - -static const struct command_registration httpd_command_handlers[] = { - { - .name = "formfetch", - .jim_handler = httpd_Jim_Command_formfetch, - .mode = COMMAND_EXEC, - .usage = "parameter_name", - .help = "Reads a posted form value.", - }, - { - .name = "writeform", - .jim_handler = httpd_Jim_Command_writeform, - .mode = COMMAND_EXEC, - .usage = "parameter_name filename", - .help = "Writes a form value to a file.", - }, - COMMAND_REGISTRATION_DONE -}; - -int httpd_start(struct command_context *cmd_ctx) -{ - pthread_mutexattr_t attr; - pthread_mutexattr_init(&attr); - pthread_mutex_init(&mutex, &attr); - - int port = 8888; - LOG_USER("Launching httpd server on port %d", port); - d = MHD_start_daemon(MHD_USE_SELECT_INTERNALLY, port, NULL, NULL, - &ahc_echo, cmd_ctx->interp, - MHD_OPTION_NOTIFY_COMPLETED, request_completed, NULL, /* Closure... what's that??? */ - MHD_OPTION_END); - if (d == NULL) - return ERROR_FAIL; - - return register_commands(cmd_ctx, NULL, httpd_command_handlers); -} - -void httpd_stop(void) -{ - MHD_stop_daemon(d); - pthread_mutex_destroy(&mutex); -} - diff --git a/src/server/httpd.h b/src/server/httpd.h deleted file mode 100644 index 0502deb1..00000000 --- a/src/server/httpd.h +++ /dev/null @@ -1,28 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2009 Zachary T Welch * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - * This program is distributed in the hope that it will be useful, * - * but WITHOUT ANY WARRANTY; without even the implied warranty of * - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * - * GNU General Public License for more details. * - * * - * You should have received a copy of the GNU General Public License * - * along with this program; if not, write to the * - * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * - ***************************************************************************/ - -#ifndef OPENOCD_SERVER_HTTPD_H -#define OPENOCD_SERVER_HTTPD_H - -struct command_context; - -int httpd_start(struct command_context *cmd_ctx); -void httpd_stop(void); - -#endif // OPENOCD_SERVER_HTTPD_H diff --git a/src/server/httpd/Stylizer.class b/src/server/httpd/Stylizer.class deleted file mode 100755 index ffa08ce7e2a2f6cb8382bfcff3dc5c11727c6a2c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4493 zcmbVQYj_k_8GcW)$!sQ*kOl%>l(JY0NeEdWw6q%pDHM$4)+9tCZQ99ZvKiQ$GqcIk zs;Hn=i?%z>J%**gC(v+2pVC7yJrND{jU6!}4lj%+Bk8!2;N!~f zq!kTKcSJ(t$#`gQcE3}gdWV@Xot*-e%`L+MzCFotLq#QOH7M{4EbBHCMsGSkW>`b| zSj-S;>`q4X*syMy@;$rhb0$q&K<&<9B5PkrSgoBcMFef-@(<+8NX&6p0 z6OT=pF(a5vJE^oYZdxi{hBXRaF0kB%RLWJubyzE)q@zIaSvSJf&#skV zw`kak4tkX0b0Lw%Cvd~npy*U_BepBJNnqWQI%~KYw+K|ZCJ|VlH7?*D578P3 zbZV$VwI8pdOQwx6+jI;!($jQ5EgYp@yRciqs|5lw&h?ZYnKVL~l41pTLUZ1j}*P@EUY6JP0^0 z!>OxONmrJN1L#rEO^Xyv=vaEfo=95p&`|EFBxrgCT1y;sC4x=`{Q?`xakt%c3VB&I zm`qy{+OiJ=GDZdku379O2KfOT)G&ELn*iWo4MN63}g zDzi4^7#XLzMY{H|hC6U4D~0E~K}LGakj4|Z`Tz7DZE}~uDv8J|nqFbbhQA*=vvQA{ zOm1GO7)7WS^jlY5DOeX@kL_ijU$k1s@Z* zaS8h|JtoX(nnq{4xh)ehQu0B=$7NWmgw$i$vO!CZPiXiAKItV${wnjYBteEIt>m;E zDj49O#*+$Wa(&tzYx2h$KI4uiZl7lBiyWm|5yOwqF>Xt=bfI|)s`!G`>x(7bIq$dP zGMmRINuE$~2G1xsOV%=1WKXx*+Xr_a%HNZ^J-b+${3(^0mCDSOD3d={aZa9|7icfo zJ2y2jE;&7vH?)c`OTw?@*fLkU`toeqbaX4qL|$HI`r?c;;SC^cBSj&Z6T4^_$OZ~W zI<+udG4Z@q&-HIPZ|aUNOE>wCd2^1y^-J@YvtrEc#ie6vu8Z*In-wVq0D>k}y7qwLGOBr(t*hD-;r76m@ z3WuzVqpP6ZP+_LY2P`Qn?F>m)yS^=#XS`A@tb{Zr71>;*NG_JIltNObnIvK1BcmvV zc&d6mQ_iOXb-7OrH&L;UgJ~r{$LLl$o${%I&-`fOZw=oxJsau)kvF#az&m!EoV;(!hRh2hY&)~^GRa5mj?5#jpna69x z{sr`nw9Vo6a81A;sF}r3SPdwRhvxD6a4iKbV05JM?m3JFYR@4eSj@~>#9iU35%Qjc z71kDz9&r&=ZOvYr!}J{P3D+&)-jP7v9NrYJ52%fA$uoIdKn-Yt`dQpJgSzmtK;0}( z1(rSMt|zNSQ+1%~96liM_rQPeVBmSX7Q0cnzmlPKK=sya_Ob& zpPIp)F4<=5HO;mm*ZW!C<@zA2bp;&`yo3(^t|9$eIzEU-eo3z6*VuK~fEIoaZsTtl zt=Pjss|W2E#AZ&69f4B(HSeHhe$Bs^Y-B?H2ERomHSQp; r-*ay)zc)oc`~iRDUdG+~6YrfO#y{gP+&j&uztXxg!~aeVD{$$5;$<07 diff --git a/src/server/httpd/Stylizer.java b/src/server/httpd/Stylizer.java deleted file mode 100755 index 721e84ca..00000000 --- a/src/server/httpd/Stylizer.java +++ /dev/null @@ -1,114 +0,0 @@ -import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.OutputStream; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.Transformer; -import javax.xml.transform.TransformerConfigurationException; -import javax.xml.transform.TransformerException; -import javax.xml.transform.TransformerFactory; -import javax.xml.transform.dom.DOMSource; -import javax.xml.transform.stream.StreamResult; -import javax.xml.transform.stream.StreamSource; - -import org.apache.xpath.XPathAPI; -import org.w3c.dom.Document; -import org.w3c.dom.Node; -import org.w3c.dom.NodeList; -import org.xml.sax.SAXException; - -/** used to generate .tcl files from */ -public class Stylizer -{ - // Global value so it can be ref'd by the tree-adapter - static Document document; - public static void main(String argv[]) - { - if (argv.length != 3) - { - System.err.println("Usage: java Stylizer stylesheet xmlfile outputdir"); - System.exit(1); - } - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); - try - { - System.err.println("Starting conversion..."); - - File stylesheet = new File(argv[0]); - File datafile = new File(argv[1]); - DocumentBuilder builder = factory.newDocumentBuilder(); - document = builder.parse(datafile); - - NodeList list = XPathAPI.selectNodeList(document, "website/language/page"); - - for (int i=0; i - -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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100755 index 8824debf..00000000 --- a/src/server/httpd/build.sh +++ /dev/null @@ -1,5 +0,0 @@ -set e -java -classpath ../../../../zy1000/build/xalan.jar\;. Stylizer menu.xsl menu.xml . -find . -regex ".*\.tcl" -type f -exec sh html2tcl.sh {} {} \; -echo "Copy .tcl files to /usr/local/lib/openocd/httpd/" -cp *.tcl /usr/local/lib/openocd/httpd/ \ No newline at end of file diff --git a/src/server/httpd/downloadmem.tcl b/src/server/httpd/downloadmem.tcl deleted file mode 100644 index e6127aea..00000000 --- a/src/server/httpd/downloadmem.tcl +++ /dev/null @@ -1,366 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100644 index e27bc053..00000000 --- a/src/server/httpd/editconfigs.tcl +++ /dev/null @@ -1,462 +0,0 @@ -# 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 deleted file mode 100644 index 6a393263..00000000 --- a/src/server/httpd/editfile.tcl +++ /dev/null @@ -1,436 +0,0 @@ -# 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 deleted file mode 100644 index a63ef37b..00000000 --- a/src/server/httpd/erase.tcl +++ /dev/null @@ -1,387 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100644 index 3ad9772f..00000000 --- a/src/server/httpd/flash.tcl +++ /dev/null @@ -1,459 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100644 index 8e9f3e25..00000000 --- a/src/server/httpd/flashinfo.tcl +++ /dev/null @@ -1,382 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100644 index 804bfe42..00000000 --- a/src/server/httpd/guiupload.tcl +++ /dev/null @@ -1,336 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100755 index 3eb5c393..00000000 --- a/src/server/httpd/html2tcl.sh +++ /dev/null @@ -1,128 +0,0 @@ -#!/bin/bash -# restart using a Tcl shell \ - exec sh -c 'for tclshell in tclsh tclsh83 cygtclsh80 ; do \ - ( echo | $tclshell ) 2> /dev/null && exec $tclshell "`( cygpath -w \"$0\" ) 2> /dev/null || echo $0`" "$@" ; \ - done ; \ - echo "file2c.tcl: cannot find Tcl shell" ; exit 1' "$0" "$@" - -#=============================================================================== -# -# file2c.tcl -# -# Convert a file into a header that can be #included from C. -# -#=============================================================================== -#####ECOSGPLCOPYRIGHTBEGIN#### -## ------------------------------------------- -## This file is part of eCos, the Embedded Configurable Operating System. -## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. -## -## eCos is free software; you can redistribute it and/or modify it under -## the terms of the GNU General Public License as published by the Free -## Software Foundation; either version 2 or (at your option) any later version. -## -## eCos is distributed in the hope that it will be useful, but WITHOUT ANY -## WARRANTY; without even the implied warranty of MERCHANTABILITY or -## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -## for more details. -## -## You should have received a copy of the GNU General Public License along -## with eCos; if not, write to the Free Software Foundation, Inc., -## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. -## -## As a special exception, if other files instantiate templates or use macros -## or inline functions from this file, or you compile this file and link it -## with other works to produce a work based on this file, this file does not -## by itself cause the resulting work to be covered by the GNU General Public -## License. However the source code for this file must still be made available -## in accordance with section (3) of the GNU General Public License. -## -## This exception does not invalidate any other reasons why a work based on -## this file might be covered by the GNU General Public License. -## -## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc. -## at http://sources.redhat.com/ecos/ecos-license/ -## ------------------------------------------- -#####ECOSGPLCOPYRIGHTEND#### -#=============================================================================== -######DESCRIPTIONBEGIN#### -# -# Author(s): jlarmour,bartv -# Contact(s): -# Date: 2001-07-20 -# Purpose: -# Description: -# Usage: file2c.tcl -# -#####DESCRIPTIONEND#### -#=============================================================================== - -if { $argc != 2 } { - puts "Usage: html2tcl.tcl " - exit 1 -} -set infile [lindex $argv 0] -set outfile [lindex $argv 1] - -set infilefd [open $infile "r"] -set data [read $infilefd] -close $infilefd - - - - -if [string match *\.tcl $infile]==0 { - puts "Not .tcl file, skipping $infile" - exit 0 -} - -set outfilefd [ open $outfile "w" ] -if [regexp -start 0 {^\s* $data $pos] - if $start==-1 { - # We're done... - set done 1 - set start [string length $data] - set end $start - } else { - set end [string first $data $start] - if $end==-1 { - # uh-oh, not closed - puts " not closed!" - exit 1 - } - } - #puts "done $done start $start end $end" - # Dump HTML into resulting file. - append result "append buffer {" - append result [string range $data $pos [expr $start-1]] - #puts [string range $data $pos $start] - append result "}\n" - - # Dump TCL into resulting file. - append result "[string range $data [expr $start+5] [expr $end-1]]\n" - - set pos [expr $end+6] -} - -append result "start_chunked \"html\"\n" -append result {write_chunked $buffer} "\n" -append result "end_chunked\n" - -puts $outfilefd $result -close $outfilefd diff --git a/src/server/httpd/httpd.tcl b/src/server/httpd/httpd.tcl deleted file mode 100644 index dfa9e335..00000000 --- a/src/server/httpd/httpd.tcl +++ /dev/null @@ -1,100 +0,0 @@ -# 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 -} - - -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 deleted file mode 100644 index 35c5cc79..00000000 --- a/src/server/httpd/index.tcl +++ /dev/null @@ -1,376 +0,0 @@ -# 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 -
-
- -
-
-
-   -
-
-

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 deleted file mode 100644 index 703a06d3..00000000 --- a/src/server/httpd/log.tcl +++ /dev/null @@ -1,343 +0,0 @@ -# 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 deleted file mode 100644 index be144641..00000000 --- a/src/server/httpd/menu.xml +++ /dev/null @@ -1,973 +0,0 @@ - - - - - - - - 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. - ]]> - - - - - - - - - - diff --git a/src/server/httpd/menu.xsl b/src/server/httpd/menu.xsl deleted file mode 100644 index b54f16c7..00000000 --- a/src/server/httpd/menu.xsl +++ /dev/null @@ -1,298 +0,0 @@ - -]> - - - - - - - - - - - - - - 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/menu_cuts/center_bottom.png b/src/server/httpd/menu_cuts/center_bottom.png deleted file mode 100644 index cfa583959033059f57619b2e4cea4abcece7c471..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 309 zcmeAS@N?(olHy`uVBq!ia0y~yU=jziZp&E8DfOsJ4 z2rGkv9-Jy<1oMDY2R8!)gaYaQ|4L1dp}{L0C=&AOC@Vw2%PV~kWf&Tmrsq683*@HG z<^`I(V#9g9%dJ2|>kLzN=X~C^u|$pG!1P@?bLZaA@8V`i=-XHMZ--?qlV#fX^Xzg= aJPe2SiyJcY8U}fi7AzZCsS>Jif(wiIEGZ*dUI_fS5tyW+d~t9IZ@2l7npLitaHrZy0wer zpmm1OuFhx6^cF9@rl|!Bux2uuj?`#C!XmPSXF$r*<5FaQ4h02d+FppVmg5oz4bpc~VZvHfb79;4J4@ trt*v}k(EP%1qCrOaX`@5Tfq&C40lT<-DfY_)eH0^gQu&X%Q~loCIA}~c>DkW diff --git a/src/server/httpd/menu_cuts/h_tab2.png b/src/server/httpd/menu_cuts/h_tab2.png deleted file mode 100644 index c0fb6dfb2d5a34bc22bb27cc44df4015aa188aab..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 349 zcmeAS@N?(olHy`uVBq!ia0vp^DL^dC!3HE_&Yz40Qj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>JivD}LIEGZ*dNb3S>yU$p>tv10T-NA=hukGG~RE{5s{3sVTek z(Lr^Irwe4J_HOE3bV7vxr>o+mL{^=tda`v>=Ne6$^7!xJ1q#WFHo714-yr*b{apLJ zj<_?X%f5tgap#_Tqvm4Nwkz(U_sSlX)VJ!MLa&~!F?q2h#LvrmN1dnQ;+k34T1AB} zw;CS_^KjumcVV;Bt1l0Dc(s?f@t+f5D|sNs;mD!DqWD4YYWjcY23|%pAiHaV&gqOs sFuP$wy+BgWLe>@rCjqAS1%e3->%_wYm%dP&2n-4aPgg&ebxsLQ05qY7`2YX_ diff --git a/src/server/httpd/menu_cuts/h_tab2_selected.png b/src/server/httpd/menu_cuts/h_tab2_selected.png deleted file mode 100644 index 4a26124d2c03d34e0314372e23792d6ee030e3cf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 330 zcmeAS@N?(olHy`uVBq!ia0vp^DL^dC!3HE_&Yz40Qj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>Jir#p-IEGZ*dNXY!S5p9kYw*FXrUkqrQB4Xjq+6CPSZ1fR zqJPEy46Te;#!)%Jiob+6{&rBx>8Z)LVAor}<)w_=ldGk7vxCK47bLIK-4Y?4?Z{uZ z@X|ZC^<@{=6;29yD_{9mp(~L|W~(OO|5Luv+Fn0@UdTUs| zgW!U_%O?XxI14-?iy0WWg+Z8+Vb&Z8pdfpRr>`sf4HhAGeFL7w!bLz++&oHaDarHf7FXtS|y@Y^)W099~g_wVY2!uz&5vr>9d%hZi>(^o+gD-Z?28+W*M*a)rJ}`cHs;R~O;7YmLQ?4m2>JIO^O(xAxk@%@J_q4B3%nv15AoZno zV&4-r$tqb(4|&%hm4zN%Dk7d5laxADlxjVFjn>pow0o*1Ic=Xue$iwe{e2$6J3ZT0 z>IbpvJXN>iUT{n5d%=&H t#f@TXR&FdkIIGoet?rLFj$2Lj%*WsOER^SK+6fF~22WQ%mvv4FO#n?6ugd@c diff --git a/src/server/httpd/menu_cuts/logo_bottom.png b/src/server/httpd/menu_cuts/logo_bottom.png deleted file mode 100644 index 8e0bf3e5c1088d7155af667e4550096178df8a65..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 960 zcmV;x13&zUP)K`_84DwR;RquNUK?qrD3!bb8X86B1@IMVCG1ks0<`gp z?Nx;?uas+7HQG`o@6*TjJ8WezE~;NHncZSaT3$&b87Lvyp2A^v#qYcC(L}akOVotZ zF4Qm!gHE5w?Ag|UCDRPcZ)%Ui2C$*9opMcr>wdKu9tUH0z6Ee@>A{`JbC^i6IA=g5 zC_0GRBzpfh0ZtuYLS-gXMs3yy&1Q^9F6C1pUYHBiXZvnG&iu0*AeiYNzCfR}mh z_8fI*vp@yX|a%)q?*<=XR)WzBw4 zP~95K`a-<+`B4=Z`QxMTgO4%tn+E2tfi_PCA=*W!q7v=JCC}ICkEZCJmq;Z( zfj=ZsBu2zpAQDww8AeKtRjR)Nj(>{{fHQAfO1joy0*9qmd*omu*eK>Vw{TNkdA(s{ zF!(_Wm$y4o*Ys9Rq@*=Mcu}~YB29!PQbIzUmBJj2V`UL)lj7DQ`x4w+Tq4TZ7QcSc z7%(YP&eke^BDpmLMiz82aau%xa54K`z`De0CBf%C>I)b9ViM_g1YoD&9-hhZ9Rt&h zW{4s|jx)-H_RP_5fJa6a86`p#oe}n>#IeuVKO&JOC6S22YucxTfoV=5ESteUm9TDF zIL4&%&j7qf1bG1vHrhI1dyn%2l6GPMH^T8Hu9un^teAFvho$x^iPb;xznQQY7#0J= iVqjPd46F0{E5HD@=p#g;xbAuY0000sqF1wv7ZzzEWUG)1vcMhHW1($s_qNa#T&Kq%5n072RaB0~`*2r3|u z(47Yoduu^U1z%8oA#i}%tLl9su80bcrO%L3g=R=}E*v^wXQTZnUAgYG+cKSX1PYYeD zi{Z?M@eL~%D4j*(Z08o_%~iTFn1{9iFrV(w|>kx|Xy65^7X)+?Nm>@!2};No)z`XD_MHa#)5UWkiFWVabiD1x7eC z$=xkd(z+tY59-{*jDp8`mJv|(tnavWdEvJ4YSet;YQ8eob@Sy*1NK(GW7M;~m*1DS z{C)0WPq(B)QAJ%J0zb%>H~hw`wSD`2k8ND2uesCSUTnx@S+KsBV(mu>)(gbl33t8`?A15RobgoSD?-qWkpz zZ8nN8^KODs^V>O_56T*n9e;kQ%z0s;t7BtbzQVdUFf{w{!^^=UBCysRO)oa`7ilyK zaC5$j#tIlQOV#qBj7-jXZCPR6>yNe0o5!d2-EB?v<{#)K$Geoe9Oa5ECA5Debv2es zbG&0-dSHq)v&c3VUOe3!#(Hlh9oDleDszyJ-%YH5z!q)H)AR>!4zzNw>K8=GXjjh3 z(MhiLw9Gge0Ln9|t~hC+$9{Kq{DMoy8cIQX;`|q z$v|IlkH_F0#DREj11yX>a!3tLf@=(KypOTH`8;mvt$KG3?UzN6w$A;?>pny$ax~>Q zq7KP>;d5C|64IENZ8g!$afQTGHUV8NIriB3^+m(46-tj=I*+8a^kDlnwVXO5UCYrV z6Zr)259IeZto;?c_gw8cxkj(mB6!BCE8<7v+HAnVt&&HSw)2owbZc)%CmtPoH!@I{ zJO5?~s$zn#Dh*#5ZR9hIaeaOjHl;{oOStC(9#dmCfm(}}FJoTahid^_JyoNDY`Du`Uot@V2w^lgO94T!GLvtg^2bmBsRxM#R2U_~17cTQY{Qd1n!=0&|x@|54dQ zt9D-&GSDqZL{T>)-S+i{IPQDP&ZJ63!z@-=t5?)MiLps{NLCO+N~A*%g;0GX)L)_^ zzzVsX{mt6xGLJ+!`vbgQB}#PMmPp3DJJ@gICf|#pD>uL+<+N?)z;_x0n)h>N2UA<^vwnlscb$LEQznOi?kF*B2-hZV^^AJOus|MVk`qg_+;Xc8ET=y zXKuvgd$dOy+=LNkb@)z&JQo~n^dlMbOhd+dy8TsVNAP;45UOT^l0Y%$3wOFtXUl=Q zmlYX(#lm-$CA`Zu&1sgWcqTEHAW)RXZ;(^C#T;5xB{^5NX*oTJhDxjiZ75EiU7u07 zUJl-R9oL%aftTwczoRGCAwO72{UM2(I>CmKJHm-~YFJ*}YPSAlv5R*=-yJs(ww}zh z^q6;CuiFS=ZkdW$FSr6n*nB>r&(cKT&q!NWh59DEN*_`&=+;$G%n;mRN>FxK{?Kt| z_>}1b$CSrI{wR8il8y9E;)Boq2Nk+F)z$WfYvW@keLsL}h&;8C+-fUnn+eq`uicJ( z(Y01alc{a+I(0deCyz?8uDQP?qE)B29MQS;gvC5AoQq<785H2|Qq=GnYwB9`@bBok7>gorhc%0N$IOz~cuZ=1fQBYw0VkQurV5E=&{HR!0pMZNjxyvqe8y+x)~61%$%nt%$RfTKw)X;R7vxgi$ReHc zymK_v@bj+_HdK_p2RQS*nc?Oug(Qhfr2TW;6QpeTws6Mzd2gx#{1k+b$^Y=tIhuHF z&DthB+ngySx7>$7nx8Y8pg-FW<*f_53>gzTYaGTlc!-4!(|2-dY|qC7d8Gx| zR((ba+Wz{csu&r7oK8B?ztEBP{r;5P>)0RU>khJ6cC3n_)w>#5^+}R8F#=Bdgmxph>R$yxFe9UE>uRJbNUEMG|B z?a+3%JKLDGTg>mKB9e)Tu*{s=&dpja3;ltJturV*CDf)-^SH2wH?iUBL%x9qOQmlj z#rx5)ZYLPVN?TVJC6*hUt#@$h_hUTl`n_%SZ=<~N&|S1fuYN0fZyfq%yI|I%gxs`) zSy1zfa-%dmIzQ>ZO2H_J92L5%=uxuF-f)V%>y5&B+BB zI5=8u*Ox0dh7G4TM5KocH<6&eeL_Us*P@|u%$w%RZuT>(XpwnOD%sMO#hkb#%md#gY zyRS2MJk_P6p;z#}^H)Y~OTN9GoE!rVw6&hRq)UIJKV0Vbv&_*#9`A?Ub{c`aT6{7K z0>W330We!A7Nv0vD>u>e98k+-6kHs{A}=!mC=z4V5R80>Y?hI_G+v4rO({VR1Taj> zZ_iYPW0vNU(7H7fFE2126gto@bkvkNpT?)|wYxc(3M2>u07-a~QR2eap#?u%G&iI1 z0a1+O|4Tn_{#*TD(q!ZTz|XUPq`!>+QvXK(81~;${u4G)PSXIf0C5YZcBDXSSw<#c Mq-Ul}(6*2K7hm(M?*IS* diff --git a/src/server/httpd/menu_cuts/right_bottom.png b/src/server/httpd/menu_cuts/right_bottom.png deleted file mode 100644 index c6011ef6aa5fa3a484b6fd5b122464bb626ad1cd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 351 zcmeAS@N?(olHy`uVBq!ia0vp^Ux8STgAGW2F^W(DQj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS=07#JBnT^vIyZoRo{n8g$*(C~1D`U%Y|$4)merK{{}tNYVR@Us#BJV| z=ehgE_b%J{PkU`{EdS$=a>g6=cVw@g@%%^IzhA!}`d-Ps(OhA3)F=6vVgEPwa>exv oKC^GM$*Om|V6Of;o{^2=(P5oQ6^*45zz}2bboFyt=akR{06dD2ng9R* diff --git a/src/server/httpd/menu_cuts/right_top.png b/src/server/httpd/menu_cuts/right_top.png deleted file mode 100644 index aaeed10c0ea9a39a3d658d871c322a164fdbfe5b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 281 zcmeAS@N?(olHy`uVBq!ia0vp^Ux8STgAGW2F^W(DQj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>JigtUtIEGZ*dUJgv=OG7)w!~ybi{`Zn2jU9Yq7UjhbLc7V z=$x8-BV)RC!PEuyntTdRo>xA|J`~EX?>_6&_xGFzY|d{aS8vRIvn}iP!|wsgSrTij z*K}`q{r&jL>c)$=j>v7DvUr7Jf8`sY#QCngJLf39X|B&Y@l-UrdZl82YL0%^iBxqU z)&^olAXdxraJ!| zgW!U_%O?XxI14-?iy0WWg+Z8+Vb&Z8pdfpRr>`sf4Q3&31FiOj2Oj~2Iz3$+Lo)8Y zy}pr?$x*=JVtv}R1g$%Vo;I1z;7SuKOb|X)nv^1`HtVj=jZ+I(-Z;qjzxA*i^Zdl! zGoJHLirT=Szktd7!M*95{@B0jiORahZ1H{RmHQ7*?e#c&i}Adaq14tX$E9Xu9l5$< zX^fufqbKvDPCe!2iObUL*DWx~(wyEL=)LnzZ`7&O&#dll@@siFR&4<~iow&>&t;uc GLK6T0yJJWI diff --git a/src/server/httpd/menu_cuts/top_right.png b/src/server/httpd/menu_cuts/top_right.png deleted file mode 100644 index d1ed656b6c035c51678634005f75515443a56db8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 352 zcmeAS@N?(olHy`uVBq!ia0y~yU=#zgr8wAtWYLe}1|Y>)9OUlAui(P=vFf5e$ipIH`vD($mz98MLe7R=Ha0O;G+aP*Z_v*4+H<=<1 zuDhj^+!Gmln>pg(SBYf3(BvN9(q!QW(s|!>U%uF2vbV-IKIE|50r9i1{J(zx`XJWf z*&Ow&?_XVsJD~n<^=iXohaWy{H=k_ze8ss{pI`0xm1>`mfBWCWZM*L7zr63G{CW;e Vhs1ri?*jeG;OXk;vd$@?2>=Ezgunm* diff --git a/src/server/httpd/menu_cuts/v_1.png b/src/server/httpd/menu_cuts/v_1.png deleted file mode 100644 index 2f23cfc0e8c3fd02fc2fdac38937f12e3a719920..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 305 zcmeAS@N?(olHy`uVBq!ia0vp^JwU9?!3HGVx*o9tDajJoh?3y^w370~qErUQl>DSr z1<%~X^wgl##FWaylc_d9MVCEY978H@y}549b%;U4)lpbjH>RPL4w?1Zr$Y9&(r_R+?G3eS>~k|3M*G--CDoy z_3=lR+FeTer;Ylb+ssS9+5Y|o^UkAY=T7eap3t|kSf^a7jDSr z1<%~X^wgl##FWaylc_d9Mc$q+jv*Dd-dytLYB1n&4ZJM%-M)0?PxCVNb1e584@kFr zhnC8Jh@R;wXt;~nX!FlGyWhXA?c!Li_5Ins>jzFh;ALUvU=!e}IUzopr0IkA0Hvj+t diff --git a/src/server/httpd/menu_cuts/v_3.png b/src/server/httpd/menu_cuts/v_3.png deleted file mode 100644 index cf8fa37bff864c19e64635931af015371b2789f2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2289 zcma)8X*3j!8Xo&LmY5hL$v$ah%@q1$m(_m1X0;R6{a?hBGbv>pL?U>95*jdCn8%ZgpaND4OG~gkoBd;3zxL z{kb5UUsLr5-O#gVz&NTcYoe4g2wTJnH2(i3l-cmV!~ZK8_+HZ?AZhMfZFbA%8&PbL zuAgYvfHtncHWrV{so(FdT@SN~Ra=Q-6fTvrF0x*6d$e(^irKj^em2#-v)kqI;^noy zgTm~Tqqhmv{Mb&J`WZb~Gldm;|NEB#mLLU0%L`!1i`D0q)#VM5=qx5)te+$dZD5G--*x$zfEIz=dO}sd6&#!wsc2$;h1XbtZ-e~V zDtfR-dr4(Gd1RDtZq($e;wtBSu9m@FW_bLw+v%DEn^BBULuoo6JT`w{t7)BY10aVQ zH-xbwMil8#D{*SDS%q`=*N-v_2*+v5M0%)m_@k2~@8COjF-?m*3^wKwK)-Ai6RdZ2 z>jHjV=)+uo@w~9$XF26EV^g*uP0K;2c_eW{Y2c!&o4y$W@@Mg^@7liLYU~500Z|ap zN=vnewalRBrvPnZwst@|IW%q0n==Ku@+Rr?n@Cx!tAgNow780IE6DB)p+W1tDRC<- zp`W$uf@U~{?J=I#j>!o{Z(yllsT@gf3XYF2S|YCdQwaZQ;(#sH??NJRf$2an9}dzu zg5-NK!zn0SeUQ(SYMfHMcSve#fDm{DX4x1y&EefOdE{cl4mlU^jqb_`X&)S4kvmi& zz+ehi06=;Fdx}W>ZxOYzkX#pu>`OKc@0gCA$F}xu5dH#yXUD}NlV};K=B+ycELQm> zl95V(TEI$E1T#D%Q*-C2N8Q<6@1!3>tO|Yhlv52fJjdxR9kO$}fqJ*ku6?Lb4J5{`TF+mLL zhX5;Hi(y3`sR-#MQFMWQ5dy{os@CfR8w924R_qcADpWo^e(mNy&jCs2>+;PrTXoEY zIlrU2TJuQ7n;z4n?a4??p{+oe?yfgn?};6?uumY0epi&ii70=2Pr(6Gy)qY(Ps$U!v!6H- z8+>Hg5v+fzsyUE~+I`rzR*^t2a}$w{9q*g)pQz(McAy;Em_P?^@|IXx42v>$b*rSD zB4RrIQao_ZWM|k=Q|&j3s%DA?AHlZPIPz6{-gr&r_L!4w2F-Uqktj2=TE4i~NP)3; z#(Bw~dfv2^no>N^D|;v2n#=NRDR(W(3~%#tme>e`M@AE53eu^|9(fs`Uk2pu$$38g z)x?FY3!(nZ<;mJP%ozXG^f8-w@gK)hU9YM2cZI7Tw8V)!PeX{X6qFZyDA#u0cWBVU z`dedm#@TcITBdPjkLaGjb-6F^7N}_~$>Ps(ecFc?TeHaOS~nyb;R4;T%5M?5!X{#( zvKONV42@kujD z-eO`G6Kgka(;EF<4fU`^6uEuhxbpZ1Bc$i?gCAfTLWt&Df*t1;DAdW~)V?{)bpHC> zL_yf#PK_4qW3_{SQ1A>ibp^v|$)Gt*A--w0DlDA&%*$8ubPt(J+~>ZgR5(`JgH*?A z+JArTAgB7ei&k#+vK=qU#W$yrT5#1pCTb{pYjJkTH5cSlTz+Id+gLU!VB*9LobF=W zJMn;yh-W;-)yfe9GwbPrTqT#7*n{R;7*+D~;5h<9YvvB(feyr|Eb#>yuP{k$kWINP z4$dU?MLgP#0?8k%YHW`Pnp~=SdKV6MuNdL!y|)wm6Cw?CCtI2%(z(UJ8qsa#st9uM z>Rw#p%r7ubEVEP=$t?%i5l@r$2l_7+6Yt^6(`QUy{s*6h276wvn-n=r~t zDmoh0riY&p4EJZUGja9t^LM>`Cd?2RB{MgpWX0H?=+$(7m5Uveixe<#v2|}L8yG0j zoE`E`Q&O{GugTHug`=#{AIj=uNnAq5JYRPJzsSn`!thf^_lANS8AZYJ3{RXh$!1P* zOjo>2!;4ooB+*L&a1#`HQ$ExxKS)bYaI;E%-x>Z};3A-4@%M5h8td#EfzQ1>HwJMZUcT(3m3+h}}k}@bLC<;I8R(Sqs zQP@~KcCn?mhg&np@sV5Fr>#&m5cE>B_+Tw_n3w{L7PQaXR6f3VGnBBbZm%ktq&ky^22 zoB=|2C%{_Kse_zbd|J(j|5WUstd`Ud*Ixm4{*6i!ETznSGY^2zxs_v*!)d1aJ#lX12j$S^7$$bW?-HGc29M_&r#}q9+}PTv+5i#vH_xL%`~Uy| diff --git a/src/server/httpd/menu_cuts/v_tab.png b/src/server/httpd/menu_cuts/v_tab.png deleted file mode 100644 index ad39319e97c1964265ac353bd72c9348f60e8b15..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 390 zcmeAS@N?(olHy`uVBq!ia0vp^JwU9?!3HGVx*o9tDajJoh?3y^w370~qErUQl>DSr z1<%~X^wgl##FWaylc_cg42&9{E{-7;x8BS#%wlqsaEmQvHk;%Y)VZ@kz3bFpL?s~`N+gKd2aGt`CF#(i0A_mVe@7HO)D%qE0VA?EdPmku|tNz zywI;p3ePYp9u)Z$toLMI=7PRm_99lNmdczKznT5vwa1Ddf(Z=!c&s+o-g(pj3|IzF LS3j3^P6DSr z1<%~X^wgl##FWaylc_cg42`|c3oft?+rGlJS7DV#_xh2 zTHzB8xh}cHx`W3vb@r`mW@jtrOU_P|xR;yrr_O@s^Qpt8Mf>U#wJEYY zdv$IZ|0!N(o9;Tn`H7$H3!|5N@|D~-El4}`Mmc(FLPz25!!~YlR~n@f*FCQ6y0e1W z)cVXUof90JgP4sD>0E8-F)%h&*!;yT%OUL$LknY~gMzrjXSHg+x#d|L#@$vn z - -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 deleted file mode 100644 index 8308deb4..00000000 --- a/src/server/httpd/preconfig.tcl +++ /dev/null @@ -1,429 +0,0 @@ -# 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 deleted file mode 100644 index 7c5ba635..00000000 --- a/src/server/httpd/production.tcl +++ /dev/null @@ -1,392 +0,0 @@ -# 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 deleted file mode 100644 index 7bc80e66..00000000 --- a/src/server/httpd/readme.txt +++ /dev/null @@ -1,24 +0,0 @@ -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 deleted file mode 100644 index 5d68ce32..00000000 --- a/src/server/httpd/reload.tcl +++ /dev/null @@ -1,322 +0,0 @@ -# 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 deleted file mode 100644 index 689b1608..00000000 --- a/src/server/httpd/run.tcl +++ /dev/null @@ -1,382 +0,0 @@ -# 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 deleted file mode 100644 index 31502197..00000000 --- a/src/server/httpd/support.tcl +++ /dev/null @@ -1,431 +0,0 @@ -# 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 deleted file mode 100644 index 4a12dde5..00000000 --- a/src/server/httpd/targets.tcl +++ /dev/null @@ -1,560 +0,0 @@ -# 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 deleted file mode 100644 index c6cc05f6..00000000 --- a/src/server/httpd/terminal.tcl +++ /dev/null @@ -1,364 +0,0 @@ -# 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 deleted file mode 100644 index 11a73d3e..00000000 --- a/src/server/httpd/upgrade.tcl +++ /dev/null @@ -1,418 +0,0 @@ -# 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 - diff --git a/src/server/httpd_stubs.c b/src/server/httpd_stubs.c deleted file mode 100644 index 0360fe61..00000000 --- a/src/server/httpd_stubs.c +++ /dev/null @@ -1,33 +0,0 @@ -/*************************************************************************** - * Copyright (C) 2009 Zachary T Welch * - * * - * This program is free software; you can redistribute it and/or modify * - * it under the terms of the GNU General Public License as published by * - * the Free Software Foundation; either version 2 of the License, or * - * (at your option) any later version. * - * * - * This program is distributed in the hope that it will be useful, * - * but WITHOUT ANY WARRANTY; without even the implied warranty of * - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * - * GNU General Public License for more details. * - * * - * You should have received a copy of the GNU General Public License * - * along with this program; if not, write to the * - * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * - ***************************************************************************/ - -#ifdef HAVE_CONFIG_H -#include -#endif -#include "httpd.h" -#include - -int httpd_start(struct command_context *cmd_ctx) -{ - LOG_DEBUG("libocdserver was built without HTTPD support"); - return ERROR_OK; -} -void httpd_stop(void) -{ -} diff --git a/src/server/server.h b/src/server/server.h index face1386..2afd7125 100644 --- a/src/server/server.h +++ b/src/server/server.h @@ -89,11 +89,11 @@ int connection_write(struct connection *connection, const void *data, int len); int connection_read(struct connection *connection, void *data, int len); /** - * Used by server_loop(), defined in server_stubs.c, httpd.c, or ecosboard.c + * Used by server_loop(), defined in server_stubs.c or ecosboard.c */ void openocd_sleep_prelude(void); /** - * Used by server_loop(), defined in server_stubs.c, httpd.c, or ecosboard.c + * Used by server_loop(), defined in server_stubs.c or ecosboard.c */ void openocd_sleep_postlude(void); -- 2.39.5