+ send_text(s, "<img src=\"/cgi-bin/lcd\" height=\"234\" width=\"320\">\n");
+ send_text(s, "<br>\n");
+ send_text(s, "<form method=\"get\" action=\"\">\n");
+ send_text(s, "<input type=\"text\" name=\"cmd\" value=\"");
+ if (param) {
+ if (strncmp(param, "cmd=", 4) == 0)
+ param += 4;
+
+ send_text(s, param);
+ }
+ send_text(s, "\">\n");
+ send_text(s, "<input type=\"submit\">\n");
+ send_text(s, "</form>\n");
+ if (param) {
+ unsigned char buf[1024*1024];
+ int res;
+
+ claimscope(sc);
+ if (strchr (param, '?')) {
+ res = sendscpi(sc, param, buf, sizeof(buf));
+ send_text(s, "<pre>< ");
+ send_text(s, param);
+ send_text(s, "\n> ");
+ send_binary(s, (char*)buf, res);
+ send_text(s, "</pre>\n");
+ } else {
+ sendscpi(sc, param, NULL, 0);
+ }
+ releasescope(sc);
+ }