mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 06:57:36 -06:00
ENH:display error msg when connecting to the printer fails
Change-Id: I483d6c00bdd623e34bce5b087bfbcb9a5e876fa3
This commit is contained in:
parent
4fd8a2b957
commit
6f2839b641
25 changed files with 378 additions and 127 deletions
|
@ -1406,12 +1406,17 @@ void MachineObject::parse_version_func()
|
|||
is_support_ams_humidity = true;
|
||||
}
|
||||
|
||||
if (firmware_type == PrinterFirmwareType::FIRMWARE_TYPE_ENGINEER) {
|
||||
/*if (firmware_type == PrinterFirmwareType::FIRMWARE_TYPE_ENGINEER) {
|
||||
local_use_ssl_for_mqtt = false;
|
||||
local_use_ssl_for_ftp = true;
|
||||
}else {
|
||||
}
|
||||
else {
|
||||
local_use_ssl_for_mqtt = ota_version->second.sw_ver.compare("01.03.01.04") >= 0;
|
||||
local_use_ssl_for_ftp = true;
|
||||
}*/
|
||||
|
||||
if (firmware_type == PrinterFirmwareType::FIRMWARE_TYPE_PRODUCTION) {
|
||||
local_use_ssl_for_mqtt = ota_version->second.sw_ver.compare("01.03.01.04") >= 0;
|
||||
}
|
||||
|
||||
is_support_remote_tunnel = true;
|
||||
|
@ -1422,14 +1427,6 @@ void MachineObject::parse_version_func()
|
|||
file_proto = 2;
|
||||
}
|
||||
} else if (printer_type == "C11") {
|
||||
if (firmware_type == PrinterFirmwareType::FIRMWARE_TYPE_ENGINEER) {
|
||||
local_use_ssl_for_mqtt = false;
|
||||
local_use_ssl_for_ftp = false;
|
||||
} else {
|
||||
local_use_ssl_for_mqtt = true;
|
||||
local_use_ssl_for_ftp = true;
|
||||
}
|
||||
|
||||
is_cloud_print_only = true;
|
||||
if (ota_version != module_vers.end()) {
|
||||
is_support_send_to_sdcard = ota_version->second.sw_ver.compare("01.02.00.00") >= 0;
|
||||
|
@ -4444,7 +4441,11 @@ bool DeviceManager::set_selected_machine(std::string dev_id, bool need_disconnec
|
|||
if (m_agent) {
|
||||
if (!need_disconnect) {m_agent->disconnect_printer();}
|
||||
it->second->reset();
|
||||
#if !BBL_RELEASE_TO_PUBLIC
|
||||
it->second->connect(false, Slic3r::GUI::wxGetApp().app_config->get("enable_ssl_for_mqtt") == "true" ? true : false);
|
||||
#else
|
||||
it->second->connect(false, it->second->local_use_ssl_for_mqtt);
|
||||
#endif
|
||||
it->second->set_lan_mode_connection_state(true);
|
||||
}
|
||||
}
|
||||
|
@ -4460,7 +4461,12 @@ bool DeviceManager::set_selected_machine(std::string dev_id, bool need_disconnec
|
|||
}
|
||||
} else {
|
||||
it->second->reset();
|
||||
|
||||
#if !BBL_RELEASE_TO_PUBLIC
|
||||
it->second->connect(false, Slic3r::GUI::wxGetApp().app_config->get("enable_ssl_for_mqtt") == "true" ? true : false);
|
||||
#else
|
||||
it->second->connect(false, it->second->local_use_ssl_for_mqtt);
|
||||
#endif
|
||||
it->second->set_lan_mode_connection_state(true);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue