mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-08-01 07:12:07 +00:00
ENH: add warning info when bed temperature is too high
Add bed temperature checker in gcode processer. And save slice warning into GcodeProcessorResult. Signed-off-by: salt.wei <salt.wei@bambulab.com> Change-Id: Iee96e4ab165a3171a5a1e165450bfc360401647f
This commit is contained in:
@@ -464,7 +464,7 @@ void PlateData::parse_filament_info(GCodeProcessorResult *result)
|
||||
}
|
||||
|
||||
/* only for test
|
||||
GCodeProcessorResult::SliceWarnings sw;
|
||||
GCodeProcessorResult::SliceWarning sw;
|
||||
sw.msg = BED_TEMP_TOO_HIGH_THAN_FILAMENT;
|
||||
sw.level = 1;
|
||||
result->warnings.push_back(sw);
|
||||
@@ -3226,7 +3226,7 @@ void PlateData::parse_filament_info(GCodeProcessorResult *result)
|
||||
if (m_curr_plater) {
|
||||
std::string msg = bbs_get_attribute_value_string(attributes, num_attributes, WARNING_MSG_TAG);
|
||||
std::string lvl_str = bbs_get_attribute_value_string(attributes, num_attributes, "level");
|
||||
GCodeProcessorResult::SliceWarnings sw;
|
||||
GCodeProcessorResult::SliceWarning sw;
|
||||
sw.msg = msg;
|
||||
try {
|
||||
sw.level = atoi(lvl_str.c_str());
|
||||
|
||||
Reference in New Issue
Block a user