mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-16 18:12:10 +00:00
FIX: [STUDIO-4207] use t_utc from device message
Change-Id: I380d10fb14621c3dd6cec5001e298e915f221189 Jira: STUDIO-4207
This commit is contained in:
@@ -2685,6 +2685,10 @@ int MachineObject::parse_json(std::string payload)
|
||||
j = j_pre;
|
||||
}
|
||||
|
||||
uint64_t t_utc = j.value("t_utc", 0);
|
||||
if (t_utc > 0)
|
||||
last_update_time = std::chrono::system_clock::time_point(t_utc * 1ms);
|
||||
|
||||
BOOST_LOG_TRIVIAL(trace) << "parse_json: dev_id=" << dev_id << ", playload=" << j.dump(4);
|
||||
|
||||
// Parse version info first, as if version arrive or change, 'print' need parse again with new compatible settings
|
||||
@@ -2944,7 +2948,7 @@ int MachineObject::parse_json(std::string payload)
|
||||
|
||||
if (jj["command"].get<std::string>() == "push_status") {
|
||||
m_push_count++;
|
||||
last_push_time = std::chrono::system_clock::now();
|
||||
last_push_time = last_update_time;
|
||||
#pragma region printing
|
||||
// U0 firmware
|
||||
if (jj.contains("print_type")) {
|
||||
|
||||
Reference in New Issue
Block a user