From 54d5e9df8f5b6667465b22a41d146225f7783c8e Mon Sep 17 00:00:00 2001 From: tao wang Date: Mon, 14 Aug 2023 18:36:57 +0800 Subject: [PATCH] FIX:fixed some unsupported HMS messages that cannot be displayed Change-Id: Ib5acffb1e2c94bae56aed89fbb71a7a15a660485 --- src/slic3r/GUI/DeviceManager.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/slic3r/GUI/DeviceManager.cpp b/src/slic3r/GUI/DeviceManager.cpp index ff8b7f7cc..df1dbc4cc 100644 --- a/src/slic3r/GUI/DeviceManager.cpp +++ b/src/slic3r/GUI/DeviceManager.cpp @@ -273,10 +273,7 @@ bool HMSItem::parse_hms_info(unsigned attr, unsigned code) { bool result = true; unsigned int model_id_int = (attr >> 24) & 0xFF; - if (model_id_int < (unsigned) MODULE_MAX) - this->module_id = (ModuleID)model_id_int; - else - this->module_id = MODULE_UKNOWN; + this->module_id = (ModuleID)model_id_int; this->module_num = (attr >> 16) & 0xFF; this->part_id = (attr >> 8) & 0xFF; this->reserved = (attr >> 0) & 0xFF;