jneilliii / OctoPrint-BedLevelVisualizer

MIT License
372 stars 82 forks source link

[BUG]: Home button causes previous results to display #288

Closed KenLucke closed 4 years ago

KenLucke commented 4 years ago

First off, LOVE LOVE LOVE the new version, with the ability to change scale and colors!!!

Describe the bug Clicking "Home" in display causes a previous bed level probe's results to appear as view is homed.
1) probe bed, display results 2) Probe bed again, display results 3) click "home" in display - view changes to home, but with previous results. No matter how many times you probe the bed and do this, it always returns to the same results, which [so far with testing] appear to be the first one that was created when that instance of OctoPrint started, or possibly the one that was in EEPROM when OP was started. 4) click "Update Mesh Now" - view returns to the last (correct) result display. 5) repeat until you get tired of doing it :)

Note: I have Bed Visualizer set with a gcode of "M420 C V" - I do my actual probes either from a macro button, Terminal Tabs Extended button, or manually via the Terminal. I only use BV to read the results.

Expected behavior Should just return view to home view with latest results

Debug Log log at end (below)

Screenshots Immediately after second scan: CR-10v2 (Blue) LAN  OctoPrint  2020-08-30 11-09-14

Then clicking "Home": CR-10v2 (Blue) LAN  OctoPrint  2020-08-30 11-09-41

Clicking "Update Mesh Now": CR-10v2 (Blue) LAN  OctoPrint  2020-08-30 11-09-14

BV Settings: CR-10 v2 (Yellow) LAN  OctoPrint  2020-08-30 12-24-03

Firmware and Version OctoPrint 1.4.2 Python 2.7.16 OctoPi 0.17.0 Bed Visualizer 0.1.14 Marlin 2.05.4 (custom, but the only change to anything mesh related is increasing to 9x9 grid)

Debug log (note, this is not from the same sequence as the screenshots above):

[2020-08-30 12:26:29,379] DEBUG: mesh collection started
[2020-08-30 12:26:29,413] DEBUG: [u'+0.128', u'+0.062', u'+0.039', u'+0.030', u'+0.035', u'+0.033', u'+0.022', u'+0.052', u'+0.028']
[2020-08-30 12:26:29,419] DEBUG: [u'+0.131', u'+0.056', u'+0.030', u'+0.014', u'+0.005', u'-0.006', u'-0.008', u'+0.004', u'-0.029']
[2020-08-30 12:26:29,423] DEBUG: [u'+0.112', u'+0.033', u'+0.013', u'-0.001', u'-0.005', u'-0.023', u'-0.042', u'-0.032', u'-0.076']
[2020-08-30 12:26:29,427] DEBUG: [u'+0.106', u'+0.030', u'+0.007', u'-0.010', u'-0.016', u'-0.032', u'-0.047', u'-0.043', u'-0.103']
[2020-08-30 12:26:29,430] DEBUG: [u'+0.095', u'+0.019', u'+0.006', u'-0.019', u'-0.024', u'-0.046', u'-0.066', u'-0.068', u'-0.131']
[2020-08-30 12:26:29,433] DEBUG: [u'+0.071', u'+0.005', u'-0.003', u'-0.021', u'-0.030', u'-0.051', u'-0.072', u'-0.063', u'-0.129']
[2020-08-30 12:26:29,436] DEBUG: [u'+0.039', u'-0.012', u'-0.017', u'-0.026', u'-0.022', u'-0.036', u'-0.049', u'-0.049', u'-0.090']
[2020-08-30 12:26:29,439] DEBUG: [u'+0.020', u'-0.022', u'-0.020', u'-0.032', u'-0.025', u'-0.036', u'-0.051', u'-0.044', u'-0.090']
[2020-08-30 12:26:29,443] DEBUG: [u'+0.023', u'-0.022', u'-0.005', u'-0.002', u'+0.008', u'-0.011', u'-0.032', u'-0.013', u'-0.065']
[2020-08-30 12:26:29,450] DEBUG: {'z_min': 0, 'y_min': 0, 'x_max': 310.0, 'x_min': 0, 'type': 'rectangular', 'y_max': 310.0, 'z_max': 400.0}
[2020-08-30 12:26:29,450] DEBUG: stopping mesh collection
[2020-08-30 12:26:29,452] DEBUG: using relative offsets
[2020-08-30 12:26:29,452] DEBUG: using center origin
[2020-08-30 12:26:29,454] DEBUG: [[0.152, 0.086, 0.063, 0.054, 0.059000000000000004, 0.057, 0.046, 0.076, 0.052000000000000005], [0.155, 0.08, 0.054, 0.038, 0.029, 0.018000000000000002, 0.016, 0.028, -0.005000000000000001], [0.136, 0.057, 0.037, 0.023, 0.019, 0.0010000000000000009, -0.018000000000000002, -0.008, -0.052], [0.13, 0.054, 0.031, 0.014, 0.008, -0.008, -0.023, -0.018999999999999996, -0.07899999999999999], [0.119, 0.043, 0.03, 0.005000000000000001, 0.0, -0.022, -0.042, -0.044000000000000004, -0.10700000000000001], [0.095, 0.029, 0.021, 0.002999999999999999, -0.005999999999999998, -0.026999999999999996, -0.047999999999999994, -0.039, -0.10500000000000001], [0.063, 0.012, 0.006999999999999999, -0.0019999999999999983, 0.0020000000000000018, -0.011999999999999997, -0.025, -0.025, -0.066], [0.044, 0.0020000000000000018, 0.004, -0.008, -0.0010000000000000009, -0.011999999999999997, -0.026999999999999996, -0.019999999999999997, -0.066], [0.047, 0.0020000000000000018, 0.019, 0.022, 0.032, 0.013000000000000001, -0.008, 0.011000000000000001, -0.041]]
[2020-08-30 12:28:37,601] DEBUG: mesh collection started
[2020-08-30 12:28:37,623] DEBUG: [u'+0.128', u'+0.062', u'+0.039', u'+0.030', u'+0.035', u'+0.033', u'+0.022', u'+0.052', u'+0.028']
[2020-08-30 12:28:37,631] DEBUG: [u'+0.131', u'+0.056', u'+0.030', u'+0.014', u'+0.005', u'-0.006', u'-0.008', u'+0.004', u'-0.029']
[2020-08-30 12:28:37,635] DEBUG: [u'+0.112', u'+0.033', u'+0.013', u'-0.001', u'-0.005', u'-0.023', u'-0.042', u'-0.032', u'-0.076']
[2020-08-30 12:28:37,644] DEBUG: [u'+0.106', u'+0.030', u'+0.007', u'-0.010', u'-0.016', u'-0.032', u'-0.047', u'-0.043', u'-0.103']
[2020-08-30 12:28:37,648] DEBUG: [u'+0.095', u'+0.019', u'+0.006', u'-0.019', u'-0.024', u'-0.046', u'-0.066', u'-0.068', u'-0.131']
[2020-08-30 12:28:37,652] DEBUG: [u'+0.071', u'+0.005', u'-0.003', u'-0.021', u'-0.030', u'-0.051', u'-0.072', u'-0.063', u'-0.129']
[2020-08-30 12:28:37,655] DEBUG: [u'+0.039', u'-0.012', u'-0.017', u'-0.026', u'-0.022', u'-0.036', u'-0.049', u'-0.049', u'-0.090']
[2020-08-30 12:28:37,660] DEBUG: [u'+0.020', u'-0.022', u'-0.020', u'-0.032', u'-0.025', u'-0.036', u'-0.051', u'-0.044', u'-0.090']
[2020-08-30 12:28:37,664] DEBUG: [u'+0.023', u'-0.022', u'-0.005', u'-0.002', u'+0.008', u'-0.011', u'-0.032', u'-0.013', u'-0.065']
[2020-08-30 12:28:37,674] DEBUG: {'z_min': 0, 'y_min': 0, 'x_max': 310.0, 'x_min': 0, 'type': 'rectangular', 'y_max': 310.0, 'z_max': 400.0}
[2020-08-30 12:28:37,675] DEBUG: stopping mesh collection
[2020-08-30 12:28:37,676] DEBUG: using relative offsets
[2020-08-30 12:28:37,677] DEBUG: using center origin
[2020-08-30 12:28:37,679] DEBUG: [[0.152, 0.086, 0.063, 0.054, 0.059000000000000004, 0.057, 0.046, 0.076, 0.052000000000000005], [0.155, 0.08, 0.054, 0.038, 0.029, 0.018000000000000002, 0.016, 0.028, -0.005000000000000001], [0.136, 0.057, 0.037, 0.023, 0.019, 0.0010000000000000009, -0.018000000000000002, -0.008, -0.052], [0.13, 0.054, 0.031, 0.014, 0.008, -0.008, -0.023, -0.018999999999999996, -0.07899999999999999], [0.119, 0.043, 0.03, 0.005000000000000001, 0.0, -0.022, -0.042, -0.044000000000000004, -0.10700000000000001], [0.095, 0.029, 0.021, 0.002999999999999999, -0.005999999999999998, -0.026999999999999996, -0.047999999999999994, -0.039, -0.10500000000000001], [0.063, 0.012, 0.006999999999999999, -0.0019999999999999983, 0.0020000000000000018, -0.011999999999999997, -0.025, -0.025, -0.066], [0.044, 0.0020000000000000018, 0.004, -0.008, -0.0010000000000000009, -0.011999999999999997, -0.026999999999999996, -0.019999999999999997, -0.066], [0.047, 0.0020000000000000018, 0.019, 0.022, 0.032, 0.013000000000000001, -0.008, 0.011000000000000001, -0.041]]
[2020-08-30 12:34:44,795] DEBUG: mesh collection started
[2020-08-30 12:34:48,536] DEBUG: [u'+0.074', u'+0.026', u'+0.018', u'+0.007', u'+0.028', u'+0.026', u'+0.038', u'+0.074', u'+0.056']
[2020-08-30 12:34:48,540] DEBUG: [u'+0.081', u'+0.008', u'+0.008', u'-0.007', u'+0.011', u'+0.006', u'+0.012', u'+0.045', u'+0.015']
[2020-08-30 12:34:48,544] DEBUG: [u'+0.067', u'+0.001', u'+0.001', u'-0.023', u'-0.002', u'-0.011', u'-0.011', u'+0.004', u'-0.024']
[2020-08-30 12:34:48,548] DEBUG: [u'+0.061', u'-0.005', u'-0.011', u'-0.025', u'-0.009', u'-0.025', u'-0.019', u'-0.013', u'-0.039']
[2020-08-30 12:34:48,552] DEBUG: [u'+0.051', u'-0.004', u'-0.012', u'-0.024', u'-0.016', u'-0.031', u'-0.034', u'-0.028', u'-0.081']
[2020-08-30 12:34:48,557] DEBUG: [u'+0.041', u'-0.015', u'-0.016', u'-0.038', u'-0.025', u'-0.035', u'-0.038', u'-0.025', u'-0.069']
[2020-08-30 12:34:48,560] DEBUG: [u'-0.002', u'-0.034', u'-0.021', u'-0.026', u'-0.009', u'-0.014', u'-0.018', u'-0.002', u'-0.041']
[2020-08-30 12:34:48,564] DEBUG: [u'-0.004', u'-0.054', u'-0.034', u'-0.031', u'-0.009', u'-0.018', u'-0.009', u'+0.006', u'-0.034']
[2020-08-30 12:34:48,567] DEBUG: [u'-0.025', u'-0.047', u'-0.012', u'-0.004', u'+0.021', u'+0.009', u'+0.002', u'+0.023', u'-0.016']
[2020-08-30 12:34:48,575] DEBUG: {'z_min': 0, 'y_min': 0, 'x_max': 310.0, 'x_min': 0, 'type': 'rectangular', 'y_max': 310.0, 'z_max': 400.0}
[2020-08-30 12:34:48,575] DEBUG: stopping mesh collection
[2020-08-30 12:34:48,576] DEBUG: using relative offsets
[2020-08-30 12:34:48,577] DEBUG: using center origin
[2020-08-30 12:34:48,578] DEBUG: [[0.09, 0.041999999999999996, 0.034, 0.023, 0.044, 0.041999999999999996, 0.054, 0.09, 0.07200000000000001], [0.097, 0.024, 0.024, 0.009000000000000001, 0.027, 0.022, 0.028, 0.061, 0.031], [0.083, 0.017, 0.017, -0.006999999999999999, 0.014, 0.005000000000000001, 0.005000000000000001, 0.02, -0.008], [0.077, 0.011, 0.005000000000000001, -0.009000000000000001, 0.007000000000000001, -0.009000000000000001, -0.002999999999999999, 0.003000000000000001, -0.023], [0.067, 0.012, 0.004, -0.008, 0.0, -0.015, -0.018000000000000002, -0.012, -0.065], [0.057, 0.0010000000000000009, 0.0, -0.022, -0.009000000000000001, -0.019000000000000003, -0.022, -0.009000000000000001, -0.053000000000000005], [0.014, -0.018000000000000002, -0.005000000000000001, -0.009999999999999998, 0.007000000000000001, 0.002, -0.0019999999999999983, 0.014, -0.025], [0.012, -0.038, -0.018000000000000002, -0.015, 0.007000000000000001, -0.0019999999999999983, 0.007000000000000001, 0.022, -0.018000000000000002], [-0.009000000000000001, -0.031, 0.004, 0.012, 0.037000000000000005, 0.025, 0.018000000000000002, 0.039, 0.0]]
[2020-08-30 12:37:19,073] DEBUG: mesh collection started
[2020-08-30 12:37:19,101] DEBUG: [u'+0.074', u'+0.026', u'+0.018', u'+0.007', u'+0.028', u'+0.026', u'+0.038', u'+0.074', u'+0.056']
[2020-08-30 12:37:19,104] DEBUG: [u'+0.081', u'+0.008', u'+0.008', u'-0.007', u'+0.011', u'+0.006', u'+0.012', u'+0.045', u'+0.015']
[2020-08-30 12:37:19,107] DEBUG: [u'+0.067', u'+0.001', u'+0.001', u'-0.023', u'-0.002', u'-0.011', u'-0.011', u'+0.004', u'-0.024']
[2020-08-30 12:37:19,111] DEBUG: [u'+0.061', u'-0.005', u'-0.011', u'-0.025', u'-0.009', u'-0.025', u'-0.019', u'-0.013', u'-0.039']
[2020-08-30 12:37:19,114] DEBUG: [u'+0.051', u'-0.004', u'-0.012', u'-0.024', u'-0.016', u'-0.031', u'-0.034', u'-0.028', u'-0.081']
[2020-08-30 12:37:19,118] DEBUG: [u'+0.041', u'-0.015', u'-0.016', u'-0.038', u'-0.025', u'-0.035', u'-0.038', u'-0.025', u'-0.069']
[2020-08-30 12:37:19,122] DEBUG: [u'-0.002', u'-0.034', u'-0.021', u'-0.026', u'-0.009', u'-0.014', u'-0.018', u'-0.002', u'-0.041']
[2020-08-30 12:37:19,125] DEBUG: [u'-0.004', u'-0.054', u'-0.034', u'-0.031', u'-0.009', u'-0.018', u'-0.009', u'+0.006', u'-0.034']
[2020-08-30 12:37:19,127] DEBUG: [u'-0.025', u'-0.047', u'-0.012', u'-0.004', u'+0.021', u'+0.009', u'+0.002', u'+0.023', u'-0.016']
[2020-08-30 12:37:19,133] DEBUG: {'z_min': 0, 'y_min': 0, 'x_max': 310.0, 'x_min': 0, 'type': 'rectangular', 'y_max': 310.0, 'z_max': 400.0}
[2020-08-30 12:37:19,134] DEBUG: stopping mesh collection
[2020-08-30 12:37:19,135] DEBUG: using relative offsets
[2020-08-30 12:37:19,136] DEBUG: using center origin
[2020-08-30 12:37:19,137] DEBUG: [[0.09, 0.041999999999999996, 0.034, 0.023, 0.044, 0.041999999999999996, 0.054, 0.09, 0.07200000000000001], [0.097, 0.024, 0.024, 0.009000000000000001, 0.027, 0.022, 0.028, 0.061, 0.031], [0.083, 0.017, 0.017, -0.006999999999999999, 0.014, 0.005000000000000001, 0.005000000000000001, 0.02, -0.008], [0.077, 0.011, 0.005000000000000001, -0.009000000000000001, 0.007000000000000001, -0.009000000000000001, -0.002999999999999999, 0.003000000000000001, -0.023], [0.067, 0.012, 0.004, -0.008, 0.0, -0.015, -0.018000000000000002, -0.012, -0.065], [0.057, 0.0010000000000000009, 0.0, -0.022, -0.009000000000000001, -0.019000000000000003, -0.022, -0.009000000000000001, -0.053000000000000005], [0.014, -0.018000000000000002, -0.005000000000000001, -0.009999999999999998, 0.007000000000000001, 0.002, -0.0019999999999999983, 0.014, -0.025], [0.012, -0.038, -0.018000000000000002, -0.015, 0.007000000000000001, -0.0019999999999999983, 0.007000000000000001, 0.022, -0.018000000000000002], [-0.009000000000000001, -0.031, 0.004, 0.012, 0.037000000000000005, 0.025, 0.018000000000000002, 0.039, 0.0]]
jneilliii commented 4 years ago

duplicate of #265