diff --git a/README.md b/README.md
index 7328d1f4..f71c7a38 100644
--- a/README.md
+++ b/README.md
@@ -49,9 +49,13 @@ In other cases you can contact the developer via email:
filename.c_str());
+// printf("Push %s\n", zw->filename.c_str());
result.push_back(zw);
}
- printf("größe: %d\n", result.size());
+// printf("größe: %d\n", result.size());
return result;
}
diff --git a/code/components/jomjol_flowcontroll/ClassFlowControll.cpp b/code/components/jomjol_flowcontroll/ClassFlowControll.cpp
index f827bcec..aac8c8e3 100644
--- a/code/components/jomjol_flowcontroll/ClassFlowControll.cpp
+++ b/code/components/jomjol_flowcontroll/ClassFlowControll.cpp
@@ -74,7 +74,7 @@ std::string ClassFlowControll::TranslateAktstatus(std::string _input)
}
-std::vector ClassFlowControll::GetAllDigital()
+std::vector ClassFlowControll::GetAllDigital()
{
if (flowdigit)
{
@@ -240,8 +240,8 @@ void ClassFlowControll::InitFlow(std::string config)
}
-std::string ClassFlowControll::getActStatus(){
- return aktstatus;
+std::string* ClassFlowControll::getActStatus(){
+ return &aktstatus;
}
void ClassFlowControll::doFlowMakeImageOnly(string time){
@@ -554,66 +554,60 @@ esp_err_t ClassFlowControll::GetJPGStream(std::string _fn, httpd_req_t *req)
{
_send = flowalignment->ImageBasis;
}
-
-
-
- if (_fn == "alg_roi.jpg")
+ else
{
- CImageBasis* _imgzw = new CImageBasis(flowalignment->ImageBasis);
- flowalignment->DrawRef(_imgzw);
- if (flowdigit) flowdigit->DrawROI(_imgzw);
- if (flowanalog) flowanalog->DrawROI(_imgzw);
+ if (_fn == "alg_roi.jpg")
+ {
+ CImageBasis* _imgzw = new CImageBasis(flowalignment->ImageBasis);
+ flowalignment->DrawRef(_imgzw);
+ if (flowdigit) flowdigit->DrawROI(_imgzw);
+ if (flowanalog) flowanalog->DrawROI(_imgzw);
+ _send = _imgzw;
+ Dodelete = true;
+ }
+ else
+ {
+ std::vector htmlinfo;
+ htmlinfo = GetAllDigital();
+ for (int i = 0; i < htmlinfo.size(); ++i)
+ {
+ if (_fn == htmlinfo[i]->filename)
+ {
+ if (htmlinfo[i]->image)
+ _send = htmlinfo[i]->image;
+ }
+ if (_fn == htmlinfo[i]->filename_org)
+ {
+ if (htmlinfo[i]->image_org)
+ _send = htmlinfo[i]->image_org;
+ }
+ delete htmlinfo[i];
+ }
+ htmlinfo.clear();
-/*/////////////////////////////////////
- cimg_library::CImg cimg(_imgzw->rgb_image, _imgzw->bpp, _imgzw->width, _imgzw->height, 1);
-
- //Convert cimg type
-// cimg.permute_axes("yzcx");
- cimg.draw_text(300, 300, "Dies ist ein Test", "black");
+ if (!_send)
+ {
+ htmlinfo = GetAllAnalog();
+ for (int i = 0; i < htmlinfo.size(); ++i)
+ {
+ if (_fn == htmlinfo[i]->filename)
+ {
+ if (htmlinfo[i]->image)
+ _send = htmlinfo[i]->image;
+ }
+ if (_fn == htmlinfo[i]->filename_org)
+ {
+ if (htmlinfo[i]->image_org)
+ _send = htmlinfo[i]->image_org;
+ }
+ delete htmlinfo[i];
+ }
+ htmlinfo.clear();
-
- //Convert back to stb type to save
-// cimg.permute_axes("cxyz");
-*////////////////////////////////////
- _send = _imgzw;
- Dodelete = true;
+ }
+ }
}
- std::vector htmlinfo;
- htmlinfo = GetAllDigital();
- for (int i = 0; i < htmlinfo.size(); ++i)
- {
- if (_fn == htmlinfo[i]->filename)
- {
- if (htmlinfo[i]->image)
- _send = htmlinfo[i]->image;
- }
- if (_fn == htmlinfo[i]->filename_org)
- {
- if (htmlinfo[i]->image_org)
- _send = htmlinfo[i]->image_org;
- }
- delete htmlinfo[i];
- }
- htmlinfo.clear();
-
- htmlinfo = GetAllAnalog();
- for (int i = 0; i < htmlinfo.size(); ++i)
- {
- if (_fn == htmlinfo[i]->filename)
- {
- if (htmlinfo[i]->image)
- _send = htmlinfo[i]->image;
- }
- if (_fn == htmlinfo[i]->filename_org)
- {
- if (htmlinfo[i]->image_org)
- _send = htmlinfo[i]->image_org;
- }
- delete htmlinfo[i];
- }
- htmlinfo.clear();
-
if (_send)
{
ESP_LOGI(TAG, "Sending file : %s ...", _fn.c_str());
diff --git a/code/components/jomjol_flowcontroll/ClassFlowControll.h b/code/components/jomjol_flowcontroll/ClassFlowControll.h
index fbc1195f..904259ef 100644
--- a/code/components/jomjol_flowcontroll/ClassFlowControll.h
+++ b/code/components/jomjol_flowcontroll/ClassFlowControll.h
@@ -60,7 +60,7 @@ public:
bool isAutoStart(long &_intervall);
- std::string getActStatus();
+ std::string* getActStatus();
std::vector GetAllDigital();
std::vector GetAllAnalog();
diff --git a/code/components/jomjol_tfliteclass/CTfLiteClass.cpp b/code/components/jomjol_tfliteclass/CTfLiteClass.cpp
index f6957e06..b97a122f 100644
--- a/code/components/jomjol_tfliteclass/CTfLiteClass.cpp
+++ b/code/components/jomjol_tfliteclass/CTfLiteClass.cpp
@@ -69,32 +69,6 @@ int CTfLiteClass::GetOutClassification(int _von, int _bis)
return (zw_class - _von);
}
-/*
-int CTfLiteClass::GetOutClassification()
-{
- TfLiteTensor* output2 = interpreter->output(0);
-
- float zw_max = 0;
- float zw;
- int zw_class = -1;
-
- if (output2 == NULL)
- return -1;
-
- int numeroutput = output2->dims->data[1];
- for (int i = 0; i < numeroutput; ++i)
- {
- zw = output2->data.f[i];
- if (zw > zw_max)
- {
- zw_max = zw;
- zw_class = i;
- }
- }
- return zw_class;
-}
-*/
-
void CTfLiteClass::GetInputDimension(bool silent = false)
{
TfLiteTensor* input2 = this->interpreter->input(0);
@@ -283,7 +257,7 @@ CTfLiteClass::CTfLiteClass()
this->interpreter = nullptr;
this->input = nullptr;
this->output = nullptr;
- this->kTensorArenaSize = 200 * 1024; /// laut testfile: 108000 - bisher 600
+ this->kTensorArenaSize = 800 * 1024; /// laut testfile: 108000 - bisher 600;; 2021-09-11: 200 * 1024
this->tensor_arena = new uint8_t[kTensorArenaSize];
}
diff --git a/code/components/jomjol_tfliteclass/server_tflite.cpp b/code/components/jomjol_tfliteclass/server_tflite.cpp
index 458e169d..354f9250 100644
--- a/code/components/jomjol_tfliteclass/server_tflite.cpp
+++ b/code/components/jomjol_tfliteclass/server_tflite.cpp
@@ -28,9 +28,6 @@ ClassFlowControll tfliteflow;
TaskHandle_t xHandleblink_task_doFlow = NULL;
TaskHandle_t xHandletask_autodoFlow = NULL;
-
-
-
bool flowisrunning = false;
long auto_intervall = 0;
@@ -506,35 +503,6 @@ esp_err_t handler_editflow(httpd_req_t *req)
httpd_resp_sendstr_chunk(req, zw.c_str());
}
-/*
- if (_task.compare("test_analog") == 0)
- {
- std::string _host = "";
- if (httpd_query_key_value(_query, "host", _valuechar, 30) == ESP_OK) {
- _host = std::string(_valuechar);
- }
-// printf("Parameter host: "); printf(_host.c_str()); printf("\n");
-// string zwzw = "Do " + _task + " start\n"; printf(zwzw.c_str());
- std::string zw = tfliteflow.doSingleStep("[Analog]", _host);
- httpd_resp_sendstr_chunk(req, zw.c_str());
- }
-*/
-/*
- if (_task.compare("test_digits") == 0)
- {
- std::string _host = "";
- if (httpd_query_key_value(_query, "host", _valuechar, 30) == ESP_OK) {
- _host = std::string(_valuechar);
- }
-// printf("Parameter host: "); printf(_host.c_str()); printf("\n");
-
-// string zwzw = "Do " + _task + " start\n"; printf(zwzw.c_str());
- std::string zw = tfliteflow.doSingleStep("[Digits]", _host);
- httpd_resp_sendstr_chunk(req, zw.c_str());
- }
-*/
-
-
/* Respond with an empty chunk to signal HTTP response completion */
httpd_resp_sendstr_chunk(req, NULL);
@@ -553,15 +521,13 @@ esp_err_t handler_statusflow(httpd_req_t *req)
#endif
const char* resp_str;
- string zw;
#ifdef DEBUG_DETAIL_ON
printf("handler_prevalue:\n"); printf(req->uri); printf("\n");
#endif
- zw = tfliteflow.getActStatus();
-
- resp_str = zw.c_str();
+ string* zw = tfliteflow.getActStatus();
+ resp_str = zw->c_str();
httpd_resp_set_hdr(req, "Access-Control-Allow-Origin", "*");
httpd_resp_send(req, resp_str, strlen(resp_str));
diff --git a/code/main/server_main.cpp b/code/main/server_main.cpp
index b06eca6a..e1150e1b 100644
--- a/code/main/server_main.cpp
+++ b/code/main/server_main.cpp
@@ -47,6 +47,8 @@ esp_err_t info_get_handler(httpd_req_t *req)
}
};
+ httpd_resp_set_hdr(req, "Access-Control-Allow-Origin", "*");
+
if (_task.compare("GitBranch") == 0)
{
std::string zw;
@@ -400,15 +402,15 @@ httpd_handle_t start_webserver(void)
httpd_config_t config = { };
config.task_priority = tskIDLE_PRIORITY+5;
- config.stack_size = 32768; // bei 32k stürzt das Programm beim Bilderaufnehmen ab
+ config.stack_size = 32768; //20210921 --> vorher 32768 // bei 32k stürzt das Programm beim Bilderaufnehmen ab
config.core_id = tskNO_AFFINITY;
config.server_port = 80;
config.ctrl_port = 32768;
- config.max_open_sockets = 7;
+ config.max_open_sockets = 5; //20210921 --> vorher 7
config.max_uri_handlers = 24;
config.max_resp_headers = 8;
config.backlog_conn = 5;
- config.lru_purge_enable = true; // dadurch werden alter Verbindungen gekappt, falls neue benögt werden.
+ config.lru_purge_enable = true; // dadurch werden alte Verbindungen gekappt, falls neue benögt werden.
config.recv_wait_timeout = 30; // default: 5
config.send_wait_timeout = 30; // default: 5
config.global_user_ctx = NULL;
diff --git a/code/main/version.cpp b/code/main/version.cpp
index 88cccde1..b26b4b83 100644
--- a/code/main/version.cpp
+++ b/code/main/version.cpp
@@ -1,4 +1,4 @@
-const char* GIT_REV="c033db9";
+const char* GIT_REV="9b3665b";
const char* GIT_TAG="";
const char* GIT_BRANCH="rolling";
-const char* BUILD_TIME="2021-09-21 18:28";
\ No newline at end of file
+const char* BUILD_TIME="2021-09-22 21:16";
\ No newline at end of file
diff --git a/code/sdkconfig b/code/sdkconfig
index bf0da769..71eeba50 100644
--- a/code/sdkconfig
+++ b/code/sdkconfig
@@ -389,7 +389,7 @@ CONFIG_ESP_INT_WDT_TIMEOUT_MS=300
CONFIG_ESP_INT_WDT_CHECK_CPU1=y
CONFIG_ESP_TASK_WDT=y
# CONFIG_ESP_TASK_WDT_PANIC is not set
-CONFIG_ESP_TASK_WDT_TIMEOUT_S=3
+CONFIG_ESP_TASK_WDT_TIMEOUT_S=6
CONFIG_ESP_TASK_WDT_CHECK_IDLE_TASK_CPU0=y
CONFIG_ESP_TASK_WDT_CHECK_IDLE_TASK_CPU1=y
# CONFIG_ESP_PANIC_HANDLER_IRAM is not set
@@ -1107,7 +1107,7 @@ CONFIG_INT_WDT_TIMEOUT_MS=300
CONFIG_INT_WDT_CHECK_CPU1=y
CONFIG_TASK_WDT=y
# CONFIG_TASK_WDT_PANIC is not set
-CONFIG_TASK_WDT_TIMEOUT_S=3
+CONFIG_TASK_WDT_TIMEOUT_S=6
CONFIG_TASK_WDT_CHECK_IDLE_TASK_CPU0=y
CONFIG_TASK_WDT_CHECK_IDLE_TASK_CPU1=y
# CONFIG_EVENT_LOOP_PROFILING is not set
diff --git a/code/sdkconfig.old b/code/sdkconfig.old
index fff6566a..6e728c9a 100644
--- a/code/sdkconfig.old
+++ b/code/sdkconfig.old
@@ -138,7 +138,8 @@ CONFIG_COMPILER_OPTIMIZATION_SIZE=y
CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE=y
# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT is not set
# CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE is not set
-# CONFIG_COMPILER_CXX_EXCEPTIONS is not set
+CONFIG_COMPILER_CXX_EXCEPTIONS=y
+CONFIG_COMPILER_CXX_EXCEPTIONS_EMG_POOL_SIZE=0
# CONFIG_COMPILER_CXX_RTTI is not set
CONFIG_COMPILER_STACK_CHECK_MODE_NONE=y
# CONFIG_COMPILER_STACK_CHECK_MODE_NORM is not set
diff --git a/code/version.cpp b/code/version.cpp
index 546c7509..b26b4b83 100644
--- a/code/version.cpp
+++ b/code/version.cpp
@@ -1,4 +1,4 @@
-const char* GIT_REV="c033db9";
+const char* GIT_REV="9b3665b";
const char* GIT_TAG="";
const char* GIT_BRANCH="rolling";
-const char* BUILD_TIME="2021-09-21 18:27";
\ No newline at end of file
+const char* BUILD_TIME="2021-09-22 21:16";
\ No newline at end of file
diff --git a/firmware/bootloader.bin b/firmware/bootloader.bin
index 1e2b77a3..9cb7c92e 100644
Binary files a/firmware/bootloader.bin and b/firmware/bootloader.bin differ
diff --git a/firmware/firmware.bin b/firmware/firmware.bin
index a33cba70..07319e74 100644
Binary files a/firmware/firmware.bin and b/firmware/firmware.bin differ
diff --git a/firmware/html.zip b/firmware/html.zip
index 7601707f..5f97fee9 100644
Binary files a/firmware/html.zip and b/firmware/html.zip differ
diff --git a/sd-card/html/gethost.js b/sd-card/html/gethost.js
index 26a5520d..66d5145c 100644
--- a/sd-card/html/gethost.js
+++ b/sd-card/html/gethost.js
@@ -9,7 +9,7 @@ function getbasepath(){
{
// host = "http://192.168.2.219"; // jomjol interner test
// host = "http://192.168.178.46"; // jomjol interner test
- host = "http://192.168.178.22"; // jomjol interner Real
+ host = "http://192.168.178.74"; // jomjol interner Real
// host = "http://192.168.43.191";
// host = "."; // jomjol interner localhost
diff --git a/sd-card/html/index.html b/sd-card/html/index.html
index 3212111e..5613fbae 100644
--- a/sd-card/html/index.html
+++ b/sd-card/html/index.html
@@ -73,7 +73,7 @@ li.dropdown {
-Digitizer - AI on the edge
+Digitizer - AI on the edge
An ESP32 all inclusive neural network recognition system for meter digitalization
@@ -102,5 +102,37 @@ li.dropdown {
+
+
+
+
+
+
+