Using Octoprint's Bed Visualizer with Klipper

I’m using Octoprint with Klipper and am really struggling to get good first layers and I’m beginning to wonder if my bed mesh is working, so I installed “Bed Visualizer” to try and see if I can tell.

I have run the command “BUILD_MESH” followed by “SAVE_CONFIG” several times and see I have a 7x7 matrix of points in the comments of my printer.cfg file under the heading [bed_mesh default]

The Bed Visualizer instructions say to add these lines to the configuration, which I have done:

@BEDLEVELVISUALIZER	; instruct plugin to start recording responses from printer.
BED_MESH_OUTPUT		; report the bed leveling mesh points.

However, when I click “Update Mesh Now” it just says “Please wait, retrieving current mesh.” but never shows anything. There is a message in the main window that says “Bed has not been probed” that makes me thing something isn’t working.

Does anyone know how Bed Visualizer is meant to work, and how I can check if my mesh is correct and being used?

No problem at all.

Here is the script I use in Bed Visualizer:

@BEDLEVELVISUALIZER
BED_MESH_CLEAR
G28
G28 Z
BED_MESH_CALIBRATE
G28 Z
BED_MESH_OUTPUT PGP=0

If the mesh is already loaded:

@BEDLEVELVISUALIZER
BED_MESH_OUTPUT PGP=0

The plugin shows the topographic of the bed surface.
You get shown the minimum and maximum deviation from zero.

Also see here:

1 Like

Thanks @EddyMI3D

I first tried adding PGP=0 to me BED_MESH_OUTPUT but nothing changed, so I tried replacing with your code above (with the G28 commands) and when I ran it my tool started reporting “-56.8°C” and has shutdown with an error:

This generally occurs when a heater temperature exceeds
its configured min_temp or max_temp.
Once the underlying issue is corrected, use the
"FIRMWARE_RESTART" command to reset the firmware, reload the
config, and restart the host software.
Printer is shutdown

This may just be a coincidence but it happened right after I clicked “Update Mesh Now” once I changed the code. Reverting the code and restarting the system doesn’t seem to bring it back. KLIPPY.LOG file attached
klippy.log (107.5 KB)

See ADC out of range

Okay, somewhat surprisingly it seems it was just a coincidence.

I turned the printer around and discovered that one of the thermometer weirs had indeed come out of the back of the plug, and it just so happened to do so right at the time I was running the above code. It took a bit of finagling to get back in but it’s all operational again: :slightly_smiling_face:

So, sorry about that little diversion…

Anyway, after running the code above the bed is probed again and I do indeed get a visualisation of the bed:

And the visualisation does indeed seem to imply that my bed is high in the centre (and by an entire layer height if I understand what I’m looking at correctly), which could explain the 1st layer issues I’m having.

Given the BED_MESH_OUTPUT command seems to be failing for me is there any way I can determine if my prints are actually using this mesh information?

What printer do you have?

It’s a corexy printer by SecKit called the SK-Tank.

It’s not a very well known printer but is meant to be of utmost quality –though I’ve had no end of trouble with it: :pensive:

Can you remove the bed surface (magnetic) ?

Indeed I can.

While removing the surface sheet may give more accurate probing results the thing I’m trying to workout is if the prints are even using the bed mesh data at all though??

The problem I am having is that when the nozzle travels over parts of the first layer after they have been printed it has a tendency to drag that bit free:

The perimeter of that square was laid down perfectly well to begin with but when the nozzle came to pass over it later to “fill it in” it pulled it up on the way over.

After seeing a visualisation of the bed I see that the centre seems to be 0.2mm higher than the front and back, which seems consistent with the problem.

Close up of that middle square:


(Because new users can only add one image per post)

Check if Axis Twist Compensation - Klipper documentation brings an improvement.

Thanks @Sineos

It seems unlikely that I would have axis twist issues.

Really, all I’m wanting to do at this stage is verify that prints are using the mesh provided. If I still have issues after verifying that the mesh is being used then I’ll start looking at what problems there could be with the mesh but at the moment I’m just wanting to simply verify that it’s being used in the first place.

In the last half year the bed mesh topic and its implications have been discussed rather intensively and no indication has been found that

On the contrary, it has been identified that often twisted axes or other mechanical issues lead to situations that the algorithm cannot compensate, mainly due to the offset between probe and nozzle.

This offset leads to location-biased effects, e.g. imagine a twisted or distorted axis / linear movement:
The entire printing carriage is at location A for probing and at location B for printing. If there is a Z relevant difference between the locations A and B then the mesh will not work as expected.

YMMV.

Sure, that might be the case but I still want to verify that it is actually using the mesh in the first place. Are you saying I’m silly for wanting to verify this?

On the contrary. I have provided you above with the link to the relevant documentation, with which you can check which mesh is loaded and with what values.
If the printer is generally using this Z compensation can be easily done via visually inspecting your z-stepper during regular X/Y movements across the bed

Yes, this is exactly what I am trying to do.

As I say I’ve tried using the commands “Bed Visualiser” suggest, being:

@BEDLEVELVISUALIZER	; instruct plugin to start recording responses from printer.
BED_MESH_OUTPUT		; report the bed leveling mesh points.

As well as the commands @EddyMI3D suggested, being:

@BEDLEVELVISUALIZER
BED_MESH_OUTPUT PGP=0

But these both produce the warning “Bed has not been probed”, which seems suspicious.

I feel like I’m just repeating my first post here but as I say I have also run the commands “BUILD_MESH” followed by “SAVE_CONFIG” several times and see a commented 7x7 matrix of values in my printer.cfg but still get “Bed has not been probed” when I run the commands suggested.

This is how I thought it should work but clearly I’m doing something wrong and I am trying to work out what I should be doing differently.

No, you actively have to run a bed_mesh_calibration before.

Or you use the other script I sent.

TBH, I do not care at all what some bed mesh plugin in Octoprint is telling you.

If the console commands return the relevant information, then everything is valid:

You only have a default mesh, so it would be

BED_MESH_PROFILE LOAD="default"
1 Like