I am using the latest Marlin firmware (1.1.9). Bed leveling isn't working. I've wasted weeks trying to get it to work. So now I'm changing my tactic.
I have printed some parts which allow me to attach a digital micrometer to the effector of my printer. Additionally I have written a program which samples the bed plate at 81 points (of my own choosing). So now I have very precise XYZ data for 81 points (X & Y coordinates were selected by me, not the Marlin firmware). The experiment revealed some very interesting info, but that's not the point of this topic.
I can find GCODE which allows modifying the Z data of an existing mesh point. But I want to go beyond that and redefine the X & Y of the mesh points, essentially redefining a completely new 81 point mesh and loading it into the firmware programatically.
Question #1: Is this possible using only Marlin GCODE? I cannot find any way to do it.
Question #2: Assuming the answer to question #1 is NO, I'm willing to customize the Marlin firmware to get the job done. Personally, I find the firmware code to be almost incomprehensible - so little documentation, and such an arcane style of programming. Nevertheless, I have been successful in the past adding a few additional custom commands to the GCODE library. But after hours searching for the code which defines the X & Y coordinates of the bed leveling mesh, I am still clueless. Define the number of points? Easy, configuration.h. But where in the code are the actual X & Y coordinates of the mesh determined? I'm using BILINEAR.
Any help with this would be greatly appreciated. My goal is to create a GCODE command which accepts XYZ data (to be called 81 times in a loop) which completely replaces the existing mesh in the firmware, redefining all three axes for each point. Thanks in advance.