HomeAll.G content cleanup



  • I'm in the process of cleaning up my system files. I had been using the homeall.g generated by the config creation tool.

    Question is, is there a good reason NOT to replace homeall.g with the G28 for X Y and Z and leave it at that? Assuming the homex/y/z.g files are all correct, this seems a much more modular/efficient approach.

    Thoughts?


  • administrators

    @adamx said in HomeAll.G content cleanup:

    Question is, is there a good reason NOT to replace homeall.g with the G28 for X Y and Z and leave it at that? Assuming the homex/y/z.g files are all correct, this seems a much more modular/efficient approach.

    You mustn't use G28 commands inside homing files, although you can use M98 to call other homing files if you want. But here are two reasons not to:

    1. Typically you will raise Z by a few mm at the start of homex.g and homey.g to avoid scraping the nozzle over the bed if it is at Z=0. Then if you are using a Z probe to home Z, in homez.g you will probably raise it again prior to doing a G30 move. If your homeall.g file calls homez.g, homey.g and homez.g, then you will end up raising Z three times and lowering it twice, but you only need to raise it once.

    2. On Cartesian and CoreXY machines, you can home X and Y simultaneously.



  • Interesting... So substitute in a "G98 homez.g" and the like? I thought G28 Z (for example) just called the homez.g file?



  • @adamx said in HomeAll.G content cleanup:

    Interesting... So substitute in a "G98 homez.g" and the like? I thought G28 Z (for example) just called the homez.g file?

    That is why I split the "hop" & "unhop" (ca. 10mm in z in my case) from the homing movements with currentreduction while homing, so to "hop" & "unhop" only 1 time no matter if only/and/or x/y/z. Drawback on this, you end up with 9 files: 1)homeall 2)...x 3)...y 4)...z 5)hop 6)unhop 7) actual-x-home-mvmnt 8)actual-y-home-mvmnt 9)actual-z-home-mvmnt

    Long story short: This way I could tune each individual movement/behaviour/current-reduction, but it gets a bit confusing also... because the 1)-4) are actually "empty" files calling the other submacros 5)-9)...



  • @lb that makes sense - but I'm still not tracking on why a G28 shouldn't/can't be called from homeall.g?


  • administrators

    @adamx said in HomeAll.G content cleanup:

    @lb that makes sense - but I'm still not tracking on why a G28 shouldn't/can't be called from homeall.g?

    It's because G28 uses some global flags to track which axes still need to be homed. So you might end up with fewer axes being homed than you wanted, or recursion, or something like that.



  • @dc42 Aha, perfect! Thanks! I always like to know and... understand, so to speak 🙂


 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.