Jump to content

Z axis homing inconsistent on UM2: workaround and patch


stevegt

Recommended Posts

Posted · Z axis homing inconsistent on UM2: workaround and patch

Hi Anders,

Okay, tried again; I think I'm seeing something. I printed exactly one ring of my leveling rings, so adjoining rings wouldn't overflow onto it (basically just a single 150mm diameter G2, .3mm thick, for anyone keeping score at home).

I leveled the build plate using two feeler gauges .05 and .1 mm, as a go and no-go gauge respectively. This should have given me a bed height of about .075 mm.

I printed one .3 mm thick ring immediately after running the build plate leveling routine, and got a ring thickness ranging from .15 to .22 mm, depending on where on the ring I measured. (I'm sure this .7 mm variation is just because I didn't do a great job with the relative thumbscrew heights.)

Without powering off, I peeled that ring off the build plate, printed one ring again, got the same results.

I cycled the power, printed one ring again. This time it's .28 to .35 thick. (Again note the .7mm variation, so that part is consistent.)

So, the thickness difference between post-leveling and post-power-cycle is .28 - .15 = .13 mm.

Anders, is that consistent with what you're seeing?

I have no idea what could be causing this. If this does turn out to be easily reproducible (I've only tried it this way once), I think it's worth starting a new topic to get it narrowed down.

Steve

 

  • Link to post
    Share on other sites

    • Replies 116
    • Created
    • Last Reply

    Top Posters In This Topic

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    I have no idea what could be causing this. If this does turn out to be easily reproducible (I've only tried it this way once), I think it's worth starting a new topic to get it narrowed down.

     

    Huh. Maybe this is it: https://github.com/Ultimaker/Ultimaker2Marlin/blob/da85f524b507bd522f30cecc85176967428fc3b5/Marlin/UltiLCD2_menu_first_run.cpp#L262.

    That line doesn't look right in the first place -- why are we adding .2 mm when we're telling everyone to use a ".1 mm piece of paper" for leveling?

    Either way, I don't see that .2 mm taken back out of the "add_homeing" [sic] array after leveling is complete, unless I'm not understanding something about how the code works. As far as I can tell, the only way to clear that would be to reset the controller.

    I'll do some more experimenting, and if this turns out to be true I'll build a patched version and start a new topic, referenced from here.

    Steve

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Steve -

    The '0.1mm' number that is quoted comes from a reply that Daid gave on here shortly after the Ultimaker² was launched. Looking at the code that you pointed out, it seems that in fact it assumes a 0.2mm thickness - and indeed, it only applies that correction to the currently 'live' version of the homing offset, when bed leveling is completed (when the second pass of the front-right leveling has been done). By then, the homing offset has already been stored in EEPROM - that happens after the second pass at the back-center leveling.

    Therefore, for the rest of the session after running a bed leveling, the bed homes to 0.2mm closer to the nozzle than the height set in the bed-leveling - i.e., about 0.1mm too high, if the paper used really was 0.1mm thick.

    Conversely, after power-cycling, the 0.2mm offset is gone, and now bed homes too far from the nozzle, by the thickness of the paper used during leveling.

    I'll put in a patch for this, along with the changes I'm working on to finish fixing the start-up sequence.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Thanks Simon. I was just coming back here to say "Oh, yeah, it's absolutely broken."

    Good catch, Anders.

    I found an easy way to duplicate this tonight: Connect with pronterface, run the leveling routine, then issue a G28 followed by an M114. The M114 shows a Z height of 215.60 mm. After controller reset, it shows 215.40. Doh.

     

    For a double-check, I rigged a dial indicator to the printhead, leveled, issued a G0X115Y115Z.2, zeroed the dial indicator, then power cycled, and issued a G0X115Y115Z.2 again. The dial indicator shows 0.18 mm lower after the power cycle.

    The dial indicator is an econo version, and there's some flex in my mounting of it as well, which might explain why it's only showing a .18 mm difference instead of .2 mm.

    I messed around with feeler gauges for a while, trying to prove or disprove the .2 mm high, {paper_thickness} low numbers -- it looks close. Someone might have better luck by using something thicker than paper -- I ran out of time and am turning into a pumpkin now.

    Sooo... We've all been printing {paper_thickness} thicker first layers than we thought? That might explain why I always seemed to have better luck when using a .05 mm feeler gauge instead of paper... :wink:

    Steve

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Excellent!

    Your findings in the code seems consistent with what I have been measuring with my digital caliper the past weeks.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Here's a more detailed procedure for duplicating the post-leveling bug, using a combination of feeler gauges and dial indicator. I'm still not able to prove or disprove the exact numbers we should expect from reading the 14.06.1 code, but I'm pasting this here for future reference anyway -- maybe someone else can see why the numbers aren't quite adding up. At worst, this will help with verifying Simon's patch:

     

    1. connect pronterface
    2. level bed at about 75 microns (50 micron feeler gauge slips freely, 100 micron won't fit, so this is 75 +/- 25 microns)
    3. G28
    4. attach dial indicator to head (mcmaster part #s 20715A76, 20625A135, 5148A15, 20645A51)
    5. G0X115Y115
    6. find true zero using G0Z1, G0Z.2, G0Z.15, G0Z.1, G0Z.05, watching dial indicator until bed movement stops
    7. decide that G0Z.1 is where nozzle contacts glass
    8. zero the dial indicator here, where nozzle contacts glass; z resolution appears to be about 20 microns, so dial indicator is now calibrated to true zero +/- 20 microns
    9. disconnect and reconnect pronterface to cause controller reset
    10. G28
    11. G0X115Y115
    12. G0z.1
    13. observe dial indicator now shows 165 microns

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    I've tested my new code, leveling to a sheet of paper that is about 0.1mm, and then printing a single 0.25mm layer. Before the fix I initially got a layer that was 0.1mm too thin, and after power cycle, I got one that was thicker than it should be.

    With the fix, the initial layer is about where it should be and stays the same before and after power cycling.

    This also has the fix for the start of print priming, and the also does the 20mm retraction at the end of printing (and now as an added bonus doesn't try to do the retract if you abort during the heat up phase).

    The code is here:

    https://github.com/illuminarti/SecretMarlin/commit/4079f0f2d690e5330f6f41311dce439ece52506b

    A hex file to test is here:

    https://www.dropbox.com/s/muppb7wev5afjs7/Marlin_UM2_Leveling_Fix.hex

    Thanks to Steve and Anders for doing most of the heavy lifting on this one.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    (UPDATE: Edited some numbers to correct my math)

     

    (UPDATE2: Most of this thick-shim test can be disregarded, I think. A thick shim will always cause results similar to these -- the code doesn't know the actual shim thickness, so it will always throw the bed height off by (actual_thickness - expected_thickness). About the only interesting result here is the 855-565=290 micron difference between pre and post-reset heights. That's pretty close to the result we would expect: .2 mm too high before reset + .1 mm low after reset = .3 mm.)

     

    Hi Simon,

     

    I've fetched and built your 4079f0f' checkin, but haven't tested it yet. Hope to do that tonight. I wanted to get one more test out of the way before leaving 14.06.1 -- this test uses a much thicker shim for bed leveling. It turns out that the shim thickness appears to be be a major factor in how high the bed is both before and after reset -- for instance, using an 0.865 mm shim causes .565 mm bed height post-leveling, and about 0.855 mm bed height after reset. I haven't tried too hard yet to figure out why.

     

    1. connect pronterface
    2. level bed at about 790+75=865 microns (.79mm plastic shim + 50 micron feeler gauge slips freely, 100 micron won't fit, so this is 865 +/- 25 microns)
    3. G28
    4. attach dial indicator to head (mcmaster part #s 20715A76, 20625A135, 5148A15, 20645A51)
    5. G0X115Y115
    6. G0Z0
    7. observe glass bed is nowhere near nozzle
    8. put shim and feeler gauges under nozzle, and using G0Z.5, G0Z.3, etc, find that, when controller thinks we're at Z.28, we're actually at 865 +/- 25 microns.
    9. Do the math and realize that, when controller thinks we're at Z0, we're actually at 865-280=565 microns.
    10. scratch head
    11. G0Z0
    12. zero the dial indicator here, at 565 microns actual
    13. disconnect and reconnect pronterface to cause controller reset
    14. G28
    15. G0X115Y115
    16. G0z0
    17. observe dial indicator now shows 1.42 mm
    18. subtract 1.42 - .565 = .855 bed height, which about what I'm seeing with the shim + feeler gauges.
    19. take a break and think

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Okay Simon, here are my test results with 4079f0f'. Looks good! I leveled by feeler gauge at 75 microns, left LEVELING_OFFSET = 0.1 and got bed contact at about z0.025 both before and after reset. Haven't printed anything yet.

     

    1. connect pronterface
    2. level bed at about 75 microns (50 micron feeler gauge slips freely, 100 micron won't fit, so this is 75 +/- 25 microns)
    3. G28
    4. attach dial indicator to head (mcmaster part #s 20715A76, 20625A135, 5148A15, 20645A51)
    5. G0X115Y115
    6. find true zero using G0Z1, G0Z.2, G0Z.1, G0Z.05, G0Z.03, etc. watching dial indicator until bed movement stops
    7. decide that G0Z.025 is about where nozzle contacts glass (This agrees with a .075 feeler gauge and LEVELING_OFFSET of 0.1. Woo hoo!)
    8. zero the dial indicator here, where nozzle contacts glass; z resolution appears to be about 20 microns, so dial indicator is now calibrated to true zero +/- 20 microns
    9. disconnect and reconnect pronterface to cause controller reset
    10. G28
    11. G0X115Y115
    12. G0z.025
    13. observe dial indicator now shows 0 microns (same as before reset), with nozzle barely in contact with glass (again, consistent with a .075 feeler gauge and LEVELING_OFFSET of 0.1)

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Thanks for checking it out, Steve. I submitted a pull request to integrate the changes into Ultimaker's fork.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    I've tested my new code, leveling to a sheet of paper that is about 0.1mm, and then printing a single 0.25mm layer. Before the fix I initially got a layer that was 0.1mm too thin, and after power cycle, I got one that was thicker than it should be.

    With the fix, the initial layer is about where it should be and stays the same before and after power cycling.

    This also has the fix for the start of print priming, and the also does the 20mm retraction at the end of printing (and now as an added bonus doesn't try to do the retract if you abort during the heat up phase).

    The code is here:

    https://github.com/illuminarti/SecretMarlin/commit/4079f0f2d690e5330f6f41311dce439ece52506b

    A hex file to test is here:

    https://www.dropbox.com/s/muppb7wev5afjs7/Marlin_UM2_Leveling_Fix.hex

    Thanks to Steve and Anders for doing most of the heavy lifting on this one.

     

    So this is the final update?

    will it be included in next Cura version?

    Thanks for sharing.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Daid has already pulled this code into the official Marlin source, but I don't think a new release has been made yet. So for now, the hex file on post #108, above, is the latest greatest version.

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Thank you also from my side, illuminarti. I uploaded the fixed version today and the next print looked much better on the bottom! However, also with the new priming sequence I got one skipped step of the feeder motor (instead of two before).

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    I begun to have this problem when I started to use 0,1mm first layer height. I don't understand now: how can I patch my firmware in order to resolve this tedious problem?

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    Download this file:

    https://www.dropbox.com/s/muppb7wev5afjs7/Marlin_UM2_Leveling_Fix.hex

    Then From Cura Go to Machine -> Install Custom Firmware and select the hex file above

    Plug in your printer to the pc and it will update

     

  • Link to post
    Share on other sites

    Posted · Z axis homing inconsistent on UM2: workaround and patch

    I have been using the latest firmware for some time now and it works really well.

    The improved priming works perfect for both Ultimaker and Velleman ABS and I can use filament which is close to 3 mm now when the grinding when priming is gone.

    I am also quite happy with the leveling, however I have one more question regarding this.

    The calibration cycle uses 0.05 mm steps for both the coarse and the fine tuning.

    Is there some particular reason not to decrease the step size when fine tuning to lets say 0.02 mm ?

    I feel that the mechanics of the UM2 is precise enough to take advantage of a smaller step size, potentially improving the quality of the first layer even more.

    0.05 mm step size really is a bit coarse when using a 0.1 mm paper and printing 0.2 mm initial layers.

    Personally I would prefer 0.04 mm (one full step) for coarse tuning and 0.01 mm (1/4 step) for fine tuning.

     

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

    • Our picks

      • UltiMaker Cura 5.7 stable released
        Cura 5.7 is here and it brings a handy new workflow improvement when using Thingiverse and Cura together, as well as additional capabilities for Method series printers, and a powerful way of sharing print settings using new printer-agnostic project files! Read on to find out about all of these improvements and more. 
         
          • Like
        • 18 replies
      • S-Line Firmware 8.3.0 was released Nov. 20th on the "Latest" firmware branch.
        (Sorry, was out of office when this released)

        This update is for...
        All UltiMaker S series  
        New features
         
        Temperature status. During print preparation, the temperatures of the print cores and build plate will be shown on the display. This gives a better indication of the progress and remaining wait time. Save log files in paused state. It is now possible to save the printer's log files to USB if the currently active print job is paused. Previously, the Dump logs to USB option was only enabled if the printer was in idle state. Confirm print removal via Digital Factory. If the printer is connected to the Digital Factory, it is now possible to confirm the removal of a previous print job via the Digital Factory interface. This is useful in situations where the build plate is clear, but the operator forgot to select Confirm removal on the printer’s display. Visit this page for more information about this feature.
          • Like
        • 0 replies
    ×
    ×
    • Create New...