Editing Config.g and it completely deletes itself...

  • Hi, still having problems settings the Z axis offset. I was editing the G31 in my Config.g file. Saved it and the system didn't ask to reboot, so I went back into the Config.g

    Somehow it had completely deleted itself and there is nothing there at all now, I backed up my files but had anyone else had this issue? I also can't seem to get the Z axis offset correct for the life of me...

    I have followed these steps and then I try a print and it still print I would guess 3mm off the bed... Please help me, I haven't had anything but trouble trying to set this game Z axis offset. Hasn't worked, and then wifi disconnects and now this random deletion...

    Make sure there is no filament stuck to the nozzle (you may want to do this test with the nozzle hot)
    Cancel any existing bed compensation by sending M561
    Send M208 S1 Z-3 to temporarily allow Z moves down to Z=-3mm. This is to ensure that you can lower the nozzle all the way to the bed in step 5.
    Command the print head to the coordinates you want to probe. To probe the center, send G1 Z1.
    Command the print head down in small steps until the nozzle just touches the bed or just grips a sheet of paper. You may need to send M564 S0 to allow movement lower than where the firmware thinks Z=0 is. You may also wish to create a macro to lower the head by e.g. 0.02mm to get greater accuracy (G91 followed by G1 Z-0.02).
    Send G92 Z0 to define that height as Z=0
    Command the nozzle up 5mm (G1 Z5)
    Send G30 S-1 to probe the bed without resetting the Z=0 position
    Read off the Z height from the web interface. That is the trigger height.
    Repeat the previous two steps a couple of times to make sure you are getting a consistent result
    Repeat steps 4-10 for the other XY positions you want to check.
    On a delta printer, it can be quite hard to achieve a consistent trigger height. Z probes that are mounted on the effector are sensitive to any tilting of the effector, because it affects the relative heights of the Z probe and the nozzle. You can reduce this effect by mounting the probe as close to the nozzle as possible. Probing solutions that use the nozzle itself as the probe are usually not affected by effector tilt, but some types are sensitive to the XY position of the nozzle for other reasons.

    Once you are satisfied with your trigger height result (should be between 0 and 1mm, depending on your printer), open your config.g file (this can be found in your DuetWebControl), find the G31 command and enter your trigger height as a negative value in the Z parameter (ex. G31 X0 Y0 Z-.43).

  • Sounds like a corrupted or semi corrupted SD card to me.

    Try a physically different one.

  • @Danal Maybe that is what has been causing the disconnects of my duet from the wifi/DWC? Do you know of a guide to reformat the sd card and starting fresh?

  • There is no "pre-built image"... but there is very close here:

    https://github.com/T3P3/Duet/tree/master/Duet2/SD Card Contents

    Format a card, FAT32, add all the directories found in the above link (but not the readme, etc.) Add your existing config.g to that (in the /sys directory), get it up and connected, and upgrade firmware to something recent. I'm running 2.02RC5(RTOS) (2018-11-28b1)

    There is information about the folders, and update instructions, here:


  • @Danal Was trying to use my roommates old 64gb card and windows 10 wouldnt let me format in FAT32...

  • administrators

    @underdonesushi said in Editing Config.g and it completely deletes itself...:

    @Danal Was trying to use my roommates old 64gb card and windows 10 wouldnt let me format in FAT32...

    Use a 32Gb or smaller card, or see https://www.makeuseof.com/tag/format-large-hard-drive-fat-fat32/.

  • @dc42 Okay I was wondering if that was the problem, thank you DC42 for the response. I have a 32gb coming in the mail. Any ideas on the random wifi disconnects? It doesn't seem to be using an IP address similar to any other device. I wasn't having any problems like this before.

  • administrators

    The disconnects are probably caused by low WiFi signal strength at the Duet and/or interference. See https://duet3d.dozuki.com/Wiki/WiFi_disconnections_and_AJAX_timeout_errors. Recent firmware versions to automatic reconnects.

Log in to reply