One fewer G29 error string
This commit is contained in:
parent
543fc4c117
commit
39f1222060
1 changed files with 3 additions and 8 deletions
|
@ -1737,25 +1737,20 @@
|
||||||
* use cases for the users. So we can wait and see what to do with it.
|
* use cases for the users. So we can wait and see what to do with it.
|
||||||
*/
|
*/
|
||||||
void unified_bed_leveling::g29_compare_current_mesh_to_stored_mesh() {
|
void unified_bed_leveling::g29_compare_current_mesh_to_stored_mesh() {
|
||||||
int16_t a = settings.calc_num_meshes();
|
const int16_t a = settings.calc_num_meshes();
|
||||||
|
|
||||||
if (!a) {
|
if (!a) {
|
||||||
SERIAL_ECHOLNPGM("?EEPROM storage not available.");
|
SERIAL_ECHOLNPGM("?EEPROM storage not available.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!parser.has_value()) {
|
if (!parser.has_value() || !WITHIN(g29_storage_slot, 0, a - 1)) {
|
||||||
SERIAL_ECHOLNPAIR("?Storage slot # required.\n?Use 0 to ", a - 1);
|
SERIAL_ECHOLNPAIR("?Invalid storage slot.\n?Use 0 to ", a - 1);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
g29_storage_slot = parser.value_int();
|
g29_storage_slot = parser.value_int();
|
||||||
|
|
||||||
if (!WITHIN(g29_storage_slot, 0, a - 1)) {
|
|
||||||
SERIAL_ECHOLNPAIR("?Invalid storage slot.\n?Use 0 to ", a - 1);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
float tmp_z_values[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
|
float tmp_z_values[GRID_MAX_POINTS_X][GRID_MAX_POINTS_Y];
|
||||||
settings.load_mesh(g29_storage_slot, &tmp_z_values);
|
settings.load_mesh(g29_storage_slot, &tmp_z_values);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue