Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    cnc z probe problem

    Scheduled Pinned Locked Moved Solved
    My Duet controlled machine
    3
    12
    876
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Ian 0undefined
      Ian 0
      last edited by

      Hi, I have a home-built cnc machine (mpcnc) with a Duet2 wifi card running Reprap. I am having great difficulty in setting up a simple Z height probe. I have attached the probe - a crocodile clip to go on the tool and a flat metal plate to sit on the workpiece to the Z-Probe connector with one part going to the Z_PROBE_IN and the other to 3.3V. I have tried to define the probe by 'M558 K0 P4 C"zprobe.in" H5 F500 T500' but when I do a G31, I get an error saying 'ERROR:G31:Invalid Probe Index' and I get the same error with G38.2. I also tried 'M558 K0 P4 C"Z_PROBE_IN" H5 F500 T500', and tried changing the C".... parameter to C4".... , all with the same result.
      I have been messing with this for over a year now, on and off, as my wife has been very ill so time has been limited but it is really getting to me now and I hope someone might be able to help. Thanks

      Nightowlundefined 1 Reply Last reply Reply Quote 0
      • Nightowlundefined
        Nightowl @Ian 0
        last edited by

        @ian-0
        I appreciate this must becoming frustrating for you, but it would help if you could give us a bit more information, particularly your config.g file.

        If you click the </> icon above, then paste the entire text of your config.g file, that would be a great start.

        Thank you.

        Few things are more dangerous than taking the advice of someone who thinks he knows what he's doing.
        I'm still on my learning curve, so take everything I say with caution!

        RatRig 1075, Duet3 MB6HC, Sorotec SFM 1000 PV-ER milling motor, Hobbyist

        Ian 0undefined 1 Reply Last reply Reply Quote 1
        • Ian 0undefined
          Ian 0 @Nightowl
          last edited by

          @nightowl ```
          ; Configuration file for Duet
          ; executed by the firmware on start-up
          ; WorkBee Firmware Version 1.1

          global systemSettingsVersion={1.2}

          M575 P1 S1 B57600

          ; Configuration files
          M98 P"config-network.g"
          M98 P"config-drives.g"
          M98 P"config-axes.g"
          M98 P"config-axes-limits.g"
          M98 P"config-axes-calibration.g"
          M98 P"config-axes-endstops.g"
          M98 P"config-probe.g"
          M98 P"config-spindle.g"
          M98 P"config-laser.g"

          ; Other Settings
          M453 ; Put the machine into CNC Modes
          G90 ; Set absolute coordinates
          M140 H-1 ; Disable heated bed
          M564 S1 H1 ; Disable jog commands when not homed
          M911 S21.0 R23 P"G91 G1 Z3 F1000" ; Configure power loss resume

          ; User Configuration files
          M98 P"config-user-settings.g"

          I did do a bit more trawling around the net and tried changing the config-probe again to :
          M558 K1 P5 C"^zprobe" H5 F500 T500     but this still gives me an error of :
          g31
          Error: G31: Invalid Z probe index    when I run the G31
          1 Reply Last reply Reply Quote 0
          • Stormundefined
            Storm
            last edited by

            Depending on your version of RRF, I don't think P4 is supported anymore.
            Try P8 like below

            M558 K0 P8 C"zprobe.in" H5 F500 T500
            

            You might want to slow your probe speed down a bit as well but that's personal preference.

            Ian 0undefined 2 Replies Last reply Reply Quote 0
            • Ian 0undefined
              Ian 0 @Storm
              last edited by

              @storm Thanks, That appears to be finding a probe but whether the touch plate is touched or not gives me the same answer to G31 - g31
              Z probe 0: current reading 1000, threshold 500, trigger height 0.700, offsets X0.0 Y0.0
              Should that be the case? I assumed I should get a different reading.

              Ian 0undefined Stormundefined 2 Replies Last reply Reply Quote 0
              • Ian 0undefined
                Ian 0 @Storm
                last edited by

                @storm My Reprap version is 3.3

                1 Reply Last reply Reply Quote 0
                • Ian 0undefined
                  Ian 0 @Ian 0
                  last edited by

                  A thought I had is, the two probe wires are currently connected to Z_PROBE_IN and 3.3v on the probe port - should they be connected to Z_PROBE_IN and Ground with the pullup resistor activated? I also can't remember where I set the thickness of the touch plate to 0.7mm and I can't see it in any of the system files.... any idea? Thanks.

                  1 Reply Last reply Reply Quote 0
                  • Stormundefined
                    Storm @Ian 0
                    last edited by

                    @ian-0 Yes you should be getting a different reading.
                    For me I get a Probe status of 0 when it's not touching and 1000 when it hits the plate. If you are getting 1000 when it's in the air then you may need to invert the pin with a !

                    My z probe input is inverted and looks like

                    M558 K0 P8 C"!io8.in" H10 F120 T3000
                    

                    and my G31 output is

                    Z probe 0: current reading 0, threshold 500, trigger height 10.000, offsets X0.0 Y0.0 U0.0
                    

                    The thickness of the touch plate is dealt with during the probing sequence. I have a Macro that I run for Z probing which is a file called Z-Probe.g in the Macros directory, the code for which is below

                    ; Z probe.g
                    ; called to find workpiece Z via G38.2
                    ;
                    
                    var ProbeThickness = 9;
                    var CoordSystem	= 20;
                     
                    ; If the printer hasn't been homed, home it
                    if !move.axes[0].homed || !move.axes[1].homed || !move.axes[2].homed
                    	G28
                     
                    ; Display message without time-out and allow to position the bit
                    M291 T-1 S3 X1 Y1 Z1 P"Make sure the bit is positioned above the Z probe" R"Touch probe"
                    
                    ; With bit above center of probe
                    G91									; relative positioning
                     
                    ; Probe Z component
                    G38.2 Z{move.axes[2].userPosition - (var.ProbeThickness + 2.25)}	; seek until the probe circuit is closed
                    G0 Z5									; rapid move Z axis 5 mm
                     
                    G10 P1 L{var.CoordSystem} Z{var.ProbeThickness + 5}			; store relative probe offset for coordinates system 1
                     
                    G90									; Absolute positioning
                    
                    Ian 0undefined 1 Reply Last reply Reply Quote 0
                    • Ian 0undefined
                      Ian 0 @Storm
                      last edited by

                      @storm Thanks, I'll try that.

                      Ian 0undefined 1 Reply Last reply Reply Quote 0
                      • Ian 0undefined
                        Ian 0 @Ian 0
                        last edited by

                        @ian-0 I changed the probe file to invert the pin and it did give me 'current reading 0"' - unfortunately it also gave me 0 when the crocodile clip was clipped to the plate! I dabbed a multimeter round the pins of the Z-Probe port and I got 4.65v on the Z_PROBE_IN pin, 4.3v on the GND pin, )v on the Z_PROBE_MOD pin, and 3.3v on the 3.3v pin. I'm beginning to wonder whether the probe port is duff... can I put the probe onto another input - say E6_STOP on the expansion header and then to either 3.3v or GND on the same port? Should that then work as M558 K0 P8 C"!E6_STOP" H10 F120 T3000? Thanks.

                        Ian 0undefined 1 Reply Last reply Reply Quote 0
                        • Ian 0undefined
                          Ian 0 @Ian 0
                          last edited by

                          @ian-0 That should have been 0v on the Z_PROBE_MOD pin..... dohhh!

                          Ian 0undefined 1 Reply Last reply Reply Quote 0
                          • Ian 0undefined
                            Ian 0 @Ian 0
                            last edited by

                            @ian-0 I have now - finally - got it sorted.. I am now using the E6STOP input on the expansion port connector and GND pin with pullup and inversion applied. M558 K0 P8 C"!^exp.E6_STOP" H0.7 F120 T3000 . Thanks for all your help.

                            1 Reply Last reply Reply Quote 0
                            • Phaedruxundefined Phaedrux marked this topic as a question
                            • Phaedruxundefined Phaedrux has marked this topic as solved
                            • First post
                              Last post
                            Unless otherwise noted, all forum content is licensed under CC-BY-SA