Fix for Marlin embedded and M503 new output

This commit is contained in:
Luc
2019-06-23 18:25:37 +02:00
parent e697423fb2
commit 0751ec467f
4 changed files with 7 additions and 5 deletions

View File

Binary file not shown.

View File

@@ -6,7 +6,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ESP3D WebUI</title>
<script>var target_firmware="";</script>
<script>var web_ui_version="2.1b40";</script>
<script>var web_ui_version="2.1b41";</script>
<script>var direct_sd=false;</script>
<script>var fw_version="";</script>
<script>var primary_sd= "/ext/";</script>

View File

@@ -633,9 +633,11 @@ function process_socket_response(msg){
}
if (target_firmware == "marlin-embedded" ) {
if (socket_is_settings && !(msg.startsWith("echo:Unknown command:") || msg.startsWith("echo:enqueueing"))) socket_response+=msg;
if (!socket_is_settings && msg.startsWith("echo:enqueueing \"M503\"")){
if (!socket_is_settings && (msg.startsWith(" G21")|| msg.startsWith(" G20"))){
socket_is_settings = true;
socket_response="";
socket_response=msg;
//to stop waiting for data
SendGetHttp("/command?commandText=echo");
}
if (msg.startsWith("ok T:")){
process_Temperatures(msg);
@@ -643,7 +645,7 @@ function process_socket_response(msg){
if (msg.startsWith("X:")){
process_Position(msg);
}
if (msg.startsWith("echo:Unknown command: \"*\"")) {
if (msg.startsWith("echo:Unknown command: \"echo\"")) {
if (socket_is_settings) {
//update settings
console.log(socket_response);

View File

@@ -77,7 +77,7 @@ function Monitor_output_Update(message){
m = "<font color='red'><b>" + m.toUpperCase() + translate_text_item(m.trim()) +"</b></font>\n";
}
if ((m.startsWith("echo:") || m.startsWith("Config:")) && !isverbosefilter)continue;
if (m.startsWith("echo:Unknown command: \"*\"") || (m.startsWith("echo:enqueueing \"*\""))) continue;
if (m.startsWith("echo:Unknown command: \"echo\"") || (m.startsWith("echo:enqueueing \"*\""))) continue;
output += m ;
}
document.getElementById("cmd_content").innerHTML = output;